123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- import 'liveConsultation.m.dart';
- class DeployPlatServerInfoDTO extends BaseDTO{
- String? id;
- String? serverID;
- String? name;
- bool isMaster;
- String? masterServerId;
- String? remoteAccountId;
- String? remotePassword;
- DeployPlatServerInfoDTO({
- this.id,
- this.serverID,
- this.name,
- this.isMaster = false,
- this.masterServerId,
- this.remoteAccountId,
- this.remotePassword,
- DateTime? createTime,
- DateTime? updateTime,
- }) : super(
- createTime: createTime,
- updateTime: updateTime,
- );
- factory DeployPlatServerInfoDTO.fromJson(Map<String, dynamic> map) {
- return DeployPlatServerInfoDTO(
- id: map['Id'],
- serverID: map['ServerID'],
- name: map['Name'],
- isMaster: map['IsMaster'],
- masterServerId: map['MasterServerId'],
- remoteAccountId: map['RemoteAccountId'],
- remotePassword: map['RemotePassword'],
- createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
- updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
- );
- }
- Map<String, dynamic> toJson() {
- final map = super.toJson();
- if(id != null)
- map['Id'] = id;
- if(serverID != null)
- map['ServerID'] = serverID;
- if(name != null)
- map['Name'] = name;
- map['IsMaster'] = isMaster;
- if(masterServerId != null)
- map['MasterServerId'] = masterServerId;
- if(remoteAccountId != null)
- map['RemoteAccountId'] = remoteAccountId;
- if(remotePassword != null)
- map['RemotePassword'] = remotePassword;
- return map;
- }
- }
|