|
@@ -1,1160 +1,650 @@
|
|
|
-import 'package:fis_jsonrpc/utils.dart';
|
|
|
-
|
|
|
-import 'package:fis_common/json_convert.dart';
|
|
|
-
|
|
|
-class AdminAccountInfo {
|
|
|
- String? adminCode;
|
|
|
- String? fatherCode;
|
|
|
- String? adminName;
|
|
|
- String? secretPassword;
|
|
|
- String? headImageToken;
|
|
|
- String? licenseKey;
|
|
|
- String? lastIP;
|
|
|
- String? phone;
|
|
|
- String? email;
|
|
|
-
|
|
|
- AdminAccountInfo({
|
|
|
- this.adminCode,
|
|
|
- this.fatherCode,
|
|
|
- this.adminName,
|
|
|
- this.secretPassword,
|
|
|
- this.headImageToken,
|
|
|
- this.licenseKey,
|
|
|
- this.lastIP,
|
|
|
- this.phone,
|
|
|
- this.email,
|
|
|
- });
|
|
|
-
|
|
|
- factory AdminAccountInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return AdminAccountInfo(
|
|
|
- adminCode: map['AdminCode'],
|
|
|
- fatherCode: map['FatherCode'],
|
|
|
- adminName: map['AdminName'],
|
|
|
- secretPassword: map['SecretPassword'],
|
|
|
- headImageToken: map['HeadImageToken'],
|
|
|
- licenseKey: map['LicenseKey'],
|
|
|
- lastIP: map['LastIP'],
|
|
|
- phone: map['Phone'],
|
|
|
- email: map['Email'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(adminCode != null)
|
|
|
- map['AdminCode'] = adminCode;
|
|
|
- if(fatherCode != null)
|
|
|
- map['FatherCode'] = fatherCode;
|
|
|
- if(adminName != null)
|
|
|
- map['AdminName'] = adminName;
|
|
|
- if(secretPassword != null)
|
|
|
- map['SecretPassword'] = secretPassword;
|
|
|
- if(headImageToken != null)
|
|
|
- map['HeadImageToken'] = headImageToken;
|
|
|
- if(licenseKey != null)
|
|
|
- map['LicenseKey'] = licenseKey;
|
|
|
- if(lastIP != null)
|
|
|
- map['LastIP'] = lastIP;
|
|
|
- if(phone != null)
|
|
|
- map['Phone'] = phone;
|
|
|
- if(email != null)
|
|
|
- map['Email'] = email;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class PageCollection<T> {
|
|
|
- int currentPage;
|
|
|
- int pageSize;
|
|
|
- int dataCount;
|
|
|
- List<T>? pageData;
|
|
|
-
|
|
|
- PageCollection({
|
|
|
- this.currentPage = 0,
|
|
|
- this.pageSize = 0,
|
|
|
- this.dataCount = 0,
|
|
|
- this.pageData,
|
|
|
- });
|
|
|
-
|
|
|
- factory PageCollection.fromJson(Map<String, dynamic> map) {
|
|
|
- List<T> pageDataList = [];
|
|
|
- if (map['PageData'] != null) {
|
|
|
- pageDataList.addAll(
|
|
|
- (map['PageData'] as List).map((e) => FJsonConvert.fromJson<T>(e)!));
|
|
|
- }
|
|
|
- return PageCollection(
|
|
|
- currentPage: map['CurrentPage'],
|
|
|
- pageSize: map['PageSize'],
|
|
|
- dataCount: map['DataCount'],
|
|
|
- pageData: pageDataList,
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- map['CurrentPage'] = currentPage;
|
|
|
- map['PageSize'] = pageSize;
|
|
|
- map['DataCount'] = dataCount;
|
|
|
- if(pageData != null)
|
|
|
- map['PageData'] = pageData;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class BaseEntity {
|
|
|
- DateTime? createTime;
|
|
|
- DateTime? updateTime;
|
|
|
-
|
|
|
- BaseEntity({
|
|
|
- this.createTime,
|
|
|
- this.updateTime,
|
|
|
- });
|
|
|
-
|
|
|
- factory BaseEntity.fromJson(Map<String, dynamic> map) {
|
|
|
- return BaseEntity(
|
|
|
- createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
- updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(createTime != null)
|
|
|
- map['CreateTime'] = JsonRpcUtils.dateFormat(createTime!);
|
|
|
- if(updateTime != null)
|
|
|
- map['UpdateTime'] = JsonRpcUtils.dateFormat(updateTime!);
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-enum UserInfoStateEnum {
|
|
|
- Nonactivated,
|
|
|
- Activated,
|
|
|
-}
|
|
|
-
|
|
|
-enum ApplyStateEnum {
|
|
|
- NotApply,
|
|
|
- Applying,
|
|
|
- Refused,
|
|
|
- Passed,
|
|
|
-}
|
|
|
-
|
|
|
-class UserInfo extends BaseEntity{
|
|
|
- String? userCode;
|
|
|
- String? userName;
|
|
|
- String? phone;
|
|
|
- String? email;
|
|
|
- String? nickName;
|
|
|
- String? fullName;
|
|
|
- String? headImageUrl;
|
|
|
- String? organizationCode;
|
|
|
- String? rootOrganizationCode;
|
|
|
- List<String>? authorityGroups;
|
|
|
- List<String>? bindDevices;
|
|
|
- String? lastIP;
|
|
|
- int logintimes;
|
|
|
- UserInfoStateEnum userState;
|
|
|
- List<String>? roleCodes;
|
|
|
- List<String>? rankCodes;
|
|
|
- List<String>? positionCodes;
|
|
|
- ApplyStateEnum applyState;
|
|
|
-
|
|
|
- UserInfo({
|
|
|
- this.userCode,
|
|
|
- this.userName,
|
|
|
- this.phone,
|
|
|
- this.email,
|
|
|
- this.nickName,
|
|
|
- this.fullName,
|
|
|
- this.headImageUrl,
|
|
|
- this.organizationCode,
|
|
|
- this.rootOrganizationCode,
|
|
|
- this.authorityGroups,
|
|
|
- this.bindDevices,
|
|
|
- this.lastIP,
|
|
|
- this.logintimes = 0,
|
|
|
- this.userState = UserInfoStateEnum.Nonactivated,
|
|
|
- this.roleCodes,
|
|
|
- this.rankCodes,
|
|
|
- this.positionCodes,
|
|
|
- this.applyState = ApplyStateEnum.NotApply,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory UserInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return UserInfo(
|
|
|
- userCode: map['UserCode'],
|
|
|
- userName: map['UserName'],
|
|
|
- phone: map['Phone'],
|
|
|
- email: map['Email'],
|
|
|
- nickName: map['NickName'],
|
|
|
- fullName: map['FullName'],
|
|
|
- headImageUrl: map['HeadImageUrl'],
|
|
|
- organizationCode: map['OrganizationCode'],
|
|
|
- rootOrganizationCode: map['RootOrganizationCode'],
|
|
|
- authorityGroups: map['AuthorityGroups'].cast<String>().toList(),
|
|
|
- bindDevices: map['BindDevices'].cast<String>().toList(),
|
|
|
- lastIP: map['LastIP'],
|
|
|
- logintimes: map['Logintimes'],
|
|
|
- userState: UserInfoStateEnum.values.firstWhere((e) => e.index == map['UserState']),
|
|
|
- roleCodes: map['RoleCodes'].cast<String>().toList(),
|
|
|
- rankCodes: map['RankCodes'].cast<String>().toList(),
|
|
|
- positionCodes: map['PositionCodes'].cast<String>().toList(),
|
|
|
- applyState: ApplyStateEnum.values.firstWhere((e) => e.index == map['ApplyState']),
|
|
|
- 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(userCode != null)
|
|
|
- map['UserCode'] = userCode;
|
|
|
- if(userName != null)
|
|
|
- map['UserName'] = userName;
|
|
|
- if(phone != null)
|
|
|
- map['Phone'] = phone;
|
|
|
- if(email != null)
|
|
|
- map['Email'] = email;
|
|
|
- if(nickName != null)
|
|
|
- map['NickName'] = nickName;
|
|
|
- if(fullName != null)
|
|
|
- map['FullName'] = fullName;
|
|
|
- if(headImageUrl != null)
|
|
|
- map['HeadImageUrl'] = headImageUrl;
|
|
|
- if(organizationCode != null)
|
|
|
- map['OrganizationCode'] = organizationCode;
|
|
|
- if(rootOrganizationCode != null)
|
|
|
- map['RootOrganizationCode'] = rootOrganizationCode;
|
|
|
- if(authorityGroups != null)
|
|
|
- map['AuthorityGroups'] = authorityGroups;
|
|
|
- if(bindDevices != null)
|
|
|
- map['BindDevices'] = bindDevices;
|
|
|
- if(lastIP != null)
|
|
|
- map['LastIP'] = lastIP;
|
|
|
- map['Logintimes'] = logintimes;
|
|
|
- map['UserState'] = userState.index;
|
|
|
- if(roleCodes != null)
|
|
|
- map['RoleCodes'] = roleCodes;
|
|
|
- if(rankCodes != null)
|
|
|
- map['RankCodes'] = rankCodes;
|
|
|
- if(positionCodes != null)
|
|
|
- map['PositionCodes'] = positionCodes;
|
|
|
- map['ApplyState'] = applyState.index;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class ManageUserInfo extends UserInfo{
|
|
|
- String? roleName;
|
|
|
- String? rankName;
|
|
|
- String? departmentName;
|
|
|
- String? hospitalName;
|
|
|
- String? identityApplyCode;
|
|
|
- List<String>? identityCard;
|
|
|
- List<String>? licenseCard;
|
|
|
-
|
|
|
- ManageUserInfo({
|
|
|
- this.roleName,
|
|
|
- this.rankName,
|
|
|
- this.departmentName,
|
|
|
- this.hospitalName,
|
|
|
- this.identityApplyCode,
|
|
|
- this.identityCard,
|
|
|
- this.licenseCard,
|
|
|
- String? userCode,
|
|
|
- String? userName,
|
|
|
- String? phone,
|
|
|
- String? email,
|
|
|
- String? nickName,
|
|
|
- String? fullName,
|
|
|
- String? headImageUrl,
|
|
|
- String? organizationCode,
|
|
|
- String? rootOrganizationCode,
|
|
|
- List<String>? authorityGroups,
|
|
|
- List<String>? bindDevices,
|
|
|
- String? lastIP,
|
|
|
- int logintimes = 0,
|
|
|
- UserInfoStateEnum userState = UserInfoStateEnum.Nonactivated,
|
|
|
- List<String>? roleCodes,
|
|
|
- List<String>? rankCodes,
|
|
|
- List<String>? positionCodes,
|
|
|
- ApplyStateEnum applyState = ApplyStateEnum.NotApply,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- userCode: userCode,
|
|
|
- userName: userName,
|
|
|
- phone: phone,
|
|
|
- email: email,
|
|
|
- nickName: nickName,
|
|
|
- fullName: fullName,
|
|
|
- headImageUrl: headImageUrl,
|
|
|
- organizationCode: organizationCode,
|
|
|
- rootOrganizationCode: rootOrganizationCode,
|
|
|
- authorityGroups: authorityGroups,
|
|
|
- bindDevices: bindDevices,
|
|
|
- lastIP: lastIP,
|
|
|
- logintimes: logintimes,
|
|
|
- userState: userState,
|
|
|
- roleCodes: roleCodes,
|
|
|
- rankCodes: rankCodes,
|
|
|
- positionCodes: positionCodes,
|
|
|
- applyState: applyState,
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory ManageUserInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- final identityCardData = map['IdentityCard'];
|
|
|
- final licenseCardData = map['LicenseCard'];
|
|
|
- return ManageUserInfo(
|
|
|
- roleName: map['RoleName'],
|
|
|
- rankName: map['RankName'],
|
|
|
- departmentName: map['DepartmentName'],
|
|
|
- hospitalName: map['HospitalName'],
|
|
|
- identityApplyCode: map['IdentityApplyCode'],
|
|
|
- identityCard: identityCardData != null ? (identityCardData as List).map((e) => e as String).toList(): null,
|
|
|
- licenseCard: licenseCardData != null ? (licenseCardData as List).map((e) => e as String).toList(): null,
|
|
|
- userCode: map['UserCode'],
|
|
|
- userName: map['UserName'],
|
|
|
- phone: map['Phone'],
|
|
|
- email: map['Email'],
|
|
|
- nickName: map['NickName'],
|
|
|
- fullName: map['FullName'],
|
|
|
- headImageUrl: map['HeadImageUrl'],
|
|
|
- organizationCode: map['OrganizationCode'],
|
|
|
- rootOrganizationCode: map['RootOrganizationCode'],
|
|
|
- authorityGroups: map['AuthorityGroups'].cast<String>().toList(),
|
|
|
- bindDevices: map['BindDevices'].cast<String>().toList(),
|
|
|
- lastIP: map['LastIP'],
|
|
|
- logintimes: map['Logintimes'],
|
|
|
- userState: UserInfoStateEnum.values.firstWhere((e) => e.index == map['UserState']),
|
|
|
- roleCodes: map['RoleCodes'].cast<String>().toList(),
|
|
|
- rankCodes: map['RankCodes'].cast<String>().toList(),
|
|
|
- positionCodes: map['PositionCodes'].cast<String>().toList(),
|
|
|
- applyState: ApplyStateEnum.values.firstWhere((e) => e.index == map['ApplyState']),
|
|
|
- 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(roleName != null)
|
|
|
- map['RoleName'] = roleName;
|
|
|
- if(rankName != null)
|
|
|
- map['RankName'] = rankName;
|
|
|
- if(departmentName != null)
|
|
|
- map['DepartmentName'] = departmentName;
|
|
|
- if(hospitalName != null)
|
|
|
- map['HospitalName'] = hospitalName;
|
|
|
- if(identityApplyCode != null)
|
|
|
- map['IdentityApplyCode'] = identityApplyCode;
|
|
|
- if(identityCard != null)
|
|
|
- map['IdentityCard'] = identityCard;
|
|
|
- if(licenseCard != null)
|
|
|
- map['LicenseCard'] = licenseCard;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class BaseSessionRequest {
|
|
|
- String? sessionId;
|
|
|
-
|
|
|
- BaseSessionRequest({
|
|
|
- this.sessionId,
|
|
|
- });
|
|
|
-
|
|
|
- factory BaseSessionRequest.fromJson(Map<String, dynamic> map) {
|
|
|
- return BaseSessionRequest(
|
|
|
- sessionId: map['SessionId'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(sessionId != null)
|
|
|
- map['SessionId'] = sessionId;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class BasePagingRequest extends BaseSessionRequest{
|
|
|
- int page;
|
|
|
- int limit;
|
|
|
-
|
|
|
- BasePagingRequest({
|
|
|
- this.page = 0,
|
|
|
- this.limit = 0,
|
|
|
- String? sessionId,
|
|
|
- }) : super(
|
|
|
- sessionId: sessionId,
|
|
|
- );
|
|
|
-
|
|
|
- factory BasePagingRequest.fromJson(Map<String, dynamic> map) {
|
|
|
- return BasePagingRequest(
|
|
|
- page: map['Page'],
|
|
|
- limit: map['Limit'],
|
|
|
- sessionId: map['SessionId'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = super.toJson();
|
|
|
- map['Page'] = page;
|
|
|
- map['Limit'] = limit;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class UserInfoListQueryRequest extends BasePagingRequest{
|
|
|
- String? queryType;
|
|
|
- String? keyword;
|
|
|
- String? queryState;
|
|
|
-
|
|
|
- UserInfoListQueryRequest({
|
|
|
- this.queryType,
|
|
|
- this.keyword,
|
|
|
- this.queryState,
|
|
|
- int page = 0,
|
|
|
- int limit = 0,
|
|
|
- String? sessionId,
|
|
|
- }) : super(
|
|
|
- page: page,
|
|
|
- limit: limit,
|
|
|
- sessionId: sessionId,
|
|
|
- );
|
|
|
-
|
|
|
- factory UserInfoListQueryRequest.fromJson(Map<String, dynamic> map) {
|
|
|
- return UserInfoListQueryRequest(
|
|
|
- queryType: map['QueryType'],
|
|
|
- keyword: map['Keyword'],
|
|
|
- queryState: map['QueryState'],
|
|
|
- page: map['Page'],
|
|
|
- limit: map['Limit'],
|
|
|
- sessionId: map['SessionId'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = super.toJson();
|
|
|
- if(queryType != null)
|
|
|
- map['QueryType'] = queryType;
|
|
|
- if(keyword != null)
|
|
|
- map['Keyword'] = keyword;
|
|
|
- if(queryState != null)
|
|
|
- map['QueryState'] = queryState;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class ReportInfo {
|
|
|
- String? reportCode;
|
|
|
- String? snapShotReportTemplate;
|
|
|
- String? reportValuesJson;
|
|
|
- String? recordCode;
|
|
|
- String? reportUser;
|
|
|
- String? tags;
|
|
|
- String? reportImageUrl;
|
|
|
- String? reportHtmlRaw;
|
|
|
-
|
|
|
- ReportInfo({
|
|
|
- this.reportCode,
|
|
|
- this.snapShotReportTemplate,
|
|
|
- this.reportValuesJson,
|
|
|
- this.recordCode,
|
|
|
- this.reportUser,
|
|
|
- this.tags,
|
|
|
- this.reportImageUrl,
|
|
|
- this.reportHtmlRaw,
|
|
|
- });
|
|
|
-
|
|
|
- factory ReportInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return ReportInfo(
|
|
|
- reportCode: map['ReportCode'],
|
|
|
- snapShotReportTemplate: map['SnapShotReportTemplate'],
|
|
|
- reportValuesJson: map['ReportValuesJson'],
|
|
|
- recordCode: map['RecordCode'],
|
|
|
- reportUser: map['ReportUser'],
|
|
|
- tags: map['Tags'],
|
|
|
- reportImageUrl: map['ReportImageUrl'],
|
|
|
- reportHtmlRaw: map['ReportHtmlRaw'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(reportCode != null)
|
|
|
- map['ReportCode'] = reportCode;
|
|
|
- if(snapShotReportTemplate != null)
|
|
|
- map['SnapShotReportTemplate'] = snapShotReportTemplate;
|
|
|
- if(reportValuesJson != null)
|
|
|
- map['ReportValuesJson'] = reportValuesJson;
|
|
|
- if(recordCode != null)
|
|
|
- map['RecordCode'] = recordCode;
|
|
|
- if(reportUser != null)
|
|
|
- map['ReportUser'] = reportUser;
|
|
|
- if(tags != null)
|
|
|
- map['Tags'] = tags;
|
|
|
- if(reportImageUrl != null)
|
|
|
- map['ReportImageUrl'] = reportImageUrl;
|
|
|
- if(reportHtmlRaw != null)
|
|
|
- map['ReportHtmlRaw'] = reportHtmlRaw;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-enum RecordTypeEnum {
|
|
|
- Ultrasound,
|
|
|
- Electrocardio,
|
|
|
-}
|
|
|
-
|
|
|
-enum CheckTypeEnum {
|
|
|
- Default,
|
|
|
-}
|
|
|
-
|
|
|
-enum RecordStatusEnum {
|
|
|
- Default,
|
|
|
-}
|
|
|
-
|
|
|
-class RecordInfo extends BaseEntity{
|
|
|
- String? recordCode;
|
|
|
- String? patientCode;
|
|
|
- String? patientName;
|
|
|
- String? orgName;
|
|
|
- RecordTypeEnum recordType;
|
|
|
- CheckTypeEnum checkType;
|
|
|
- String? localRecordCode;
|
|
|
- RecordStatusEnum recordStatus;
|
|
|
- String? recordRemark;
|
|
|
- String? tags;
|
|
|
-
|
|
|
- RecordInfo({
|
|
|
- this.recordCode,
|
|
|
- this.patientCode,
|
|
|
- this.patientName,
|
|
|
- this.orgName,
|
|
|
- this.recordType = RecordTypeEnum.Ultrasound,
|
|
|
- this.checkType = CheckTypeEnum.Default,
|
|
|
- this.localRecordCode,
|
|
|
- this.recordStatus = RecordStatusEnum.Default,
|
|
|
- this.recordRemark,
|
|
|
- this.tags,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory RecordInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return RecordInfo(
|
|
|
- recordCode: map['RecordCode'],
|
|
|
- patientCode: map['PatientCode'],
|
|
|
- patientName: map['PatientName'],
|
|
|
- orgName: map['OrgName'],
|
|
|
- recordType: RecordTypeEnum.values.firstWhere((e) => e.index == map['RecordType']),
|
|
|
- checkType: CheckTypeEnum.values.firstWhere((e) => e.index == map['CheckType']),
|
|
|
- localRecordCode: map['LocalRecordCode'],
|
|
|
- recordStatus: RecordStatusEnum.values.firstWhere((e) => e.index == map['RecordStatus']),
|
|
|
- recordRemark: map['RecordRemark'],
|
|
|
- tags: map['Tags'],
|
|
|
- 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(recordCode != null)
|
|
|
- map['RecordCode'] = recordCode;
|
|
|
- if(patientCode != null)
|
|
|
- map['PatientCode'] = patientCode;
|
|
|
- if(patientName != null)
|
|
|
- map['PatientName'] = patientName;
|
|
|
- if(orgName != null)
|
|
|
- map['OrgName'] = orgName;
|
|
|
- map['RecordType'] = recordType.index;
|
|
|
- map['CheckType'] = checkType.index;
|
|
|
- if(localRecordCode != null)
|
|
|
- map['LocalRecordCode'] = localRecordCode;
|
|
|
- map['RecordStatus'] = recordStatus.index;
|
|
|
- if(recordRemark != null)
|
|
|
- map['RecordRemark'] = recordRemark;
|
|
|
- if(tags != null)
|
|
|
- map['Tags'] = tags;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-enum DeviceDataTypeEnum {
|
|
|
- Default,
|
|
|
-}
|
|
|
-
|
|
|
-class DeviceData extends BaseEntity{
|
|
|
- String? deviceDataCode;
|
|
|
- String? deviceCode;
|
|
|
- String? deviceFileCode;
|
|
|
- String? recordCode;
|
|
|
- String? patientCode;
|
|
|
- String? previewImageToken;
|
|
|
- String? dataToken;
|
|
|
- DeviceDataTypeEnum deviceDataType;
|
|
|
- String? processResult;
|
|
|
-
|
|
|
- DeviceData({
|
|
|
- this.deviceDataCode,
|
|
|
- this.deviceCode,
|
|
|
- this.deviceFileCode,
|
|
|
- this.recordCode,
|
|
|
- this.patientCode,
|
|
|
- this.previewImageToken,
|
|
|
- this.dataToken,
|
|
|
- this.deviceDataType = DeviceDataTypeEnum.Default,
|
|
|
- this.processResult,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory DeviceData.fromJson(Map<String, dynamic> map) {
|
|
|
- return DeviceData(
|
|
|
- deviceDataCode: map['DeviceDataCode'],
|
|
|
- deviceCode: map['DeviceCode'],
|
|
|
- deviceFileCode: map['DeviceFileCode'],
|
|
|
- recordCode: map['RecordCode'],
|
|
|
- patientCode: map['PatientCode'],
|
|
|
- previewImageToken: map['PreviewImageToken'],
|
|
|
- dataToken: map['DataToken'],
|
|
|
- deviceDataType: DeviceDataTypeEnum.values.firstWhere((e) => e.index == map['DeviceDataType']),
|
|
|
- processResult: map['ProcessResult'],
|
|
|
- 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(deviceDataCode != null)
|
|
|
- map['DeviceDataCode'] = deviceDataCode;
|
|
|
- if(deviceCode != null)
|
|
|
- map['DeviceCode'] = deviceCode;
|
|
|
- if(deviceFileCode != null)
|
|
|
- map['DeviceFileCode'] = deviceFileCode;
|
|
|
- if(recordCode != null)
|
|
|
- map['RecordCode'] = recordCode;
|
|
|
- if(patientCode != null)
|
|
|
- map['PatientCode'] = patientCode;
|
|
|
- if(previewImageToken != null)
|
|
|
- map['PreviewImageToken'] = previewImageToken;
|
|
|
- if(dataToken != null)
|
|
|
- map['DataToken'] = dataToken;
|
|
|
- map['DeviceDataType'] = deviceDataType.index;
|
|
|
- if(processResult != null)
|
|
|
- map['ProcessResult'] = processResult;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-enum GenderTypeEnum {
|
|
|
- Male,
|
|
|
- Female,
|
|
|
-}
|
|
|
-
|
|
|
-enum PatientTypeEnum {
|
|
|
- Default,
|
|
|
-}
|
|
|
-
|
|
|
-class PatientInfo extends BaseEntity{
|
|
|
- String? patientCode;
|
|
|
- String? firstName;
|
|
|
- String? lastName;
|
|
|
- String? patientCardNo;
|
|
|
- DateTime? birthday;
|
|
|
- GenderTypeEnum genderType;
|
|
|
- String? patientCaseHistory;
|
|
|
- String? patientPhone;
|
|
|
- PatientTypeEnum patientType;
|
|
|
-
|
|
|
- PatientInfo({
|
|
|
- this.patientCode,
|
|
|
- this.firstName,
|
|
|
- this.lastName,
|
|
|
- this.patientCardNo,
|
|
|
- this.birthday,
|
|
|
- this.genderType = GenderTypeEnum.Male,
|
|
|
- this.patientCaseHistory,
|
|
|
- this.patientPhone,
|
|
|
- this.patientType = PatientTypeEnum.Default,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory PatientInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return PatientInfo(
|
|
|
- patientCode: map['PatientCode'],
|
|
|
- firstName: map['FirstName'],
|
|
|
- lastName: map['LastName'],
|
|
|
- patientCardNo: map['PatientCardNo'],
|
|
|
- birthday: map['Birthday'] != null ? DateTime.parse(map['Birthday']) : null,
|
|
|
- genderType: GenderTypeEnum.values.firstWhere((e) => e.index == map['GenderType']),
|
|
|
- patientCaseHistory: map['PatientCaseHistory'],
|
|
|
- patientPhone: map['PatientPhone'],
|
|
|
- patientType: PatientTypeEnum.values.firstWhere((e) => e.index == map['PatientType']),
|
|
|
- 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(patientCode != null)
|
|
|
- map['PatientCode'] = patientCode;
|
|
|
- if(firstName != null)
|
|
|
- map['FirstName'] = firstName;
|
|
|
- if(lastName != null)
|
|
|
- map['LastName'] = lastName;
|
|
|
- if(patientCardNo != null)
|
|
|
- map['PatientCardNo'] = patientCardNo;
|
|
|
- if(birthday != null)
|
|
|
- map['Birthday'] = JsonRpcUtils.dateFormat(birthday!);
|
|
|
- map['GenderType'] = genderType.index;
|
|
|
- if(patientCaseHistory != null)
|
|
|
- map['PatientCaseHistory'] = patientCaseHistory;
|
|
|
- if(patientPhone != null)
|
|
|
- map['PatientPhone'] = patientPhone;
|
|
|
- map['PatientType'] = patientType.index;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class MenuInfo {
|
|
|
- String? menuCode;
|
|
|
- String? menuName;
|
|
|
- String? menuType;
|
|
|
- String? menuShowName;
|
|
|
- int menuSort;
|
|
|
- String? menuFatherCode;
|
|
|
-
|
|
|
- MenuInfo({
|
|
|
- this.menuCode,
|
|
|
- this.menuName,
|
|
|
- this.menuType,
|
|
|
- this.menuShowName,
|
|
|
- this.menuSort = 0,
|
|
|
- this.menuFatherCode,
|
|
|
- });
|
|
|
-
|
|
|
- factory MenuInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return MenuInfo(
|
|
|
- menuCode: map['MenuCode'],
|
|
|
- menuName: map['MenuName'],
|
|
|
- menuType: map['MenuType'],
|
|
|
- menuShowName: map['MenuShowName'],
|
|
|
- menuSort: map['MenuSort'],
|
|
|
- menuFatherCode: map['MenuFatherCode'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(menuCode != null)
|
|
|
- map['MenuCode'] = menuCode;
|
|
|
- if(menuName != null)
|
|
|
- map['MenuName'] = menuName;
|
|
|
- if(menuType != null)
|
|
|
- map['MenuType'] = menuType;
|
|
|
- if(menuShowName != null)
|
|
|
- map['MenuShowName'] = menuShowName;
|
|
|
- map['MenuSort'] = menuSort;
|
|
|
- if(menuFatherCode != null)
|
|
|
- map['MenuFatherCode'] = menuFatherCode;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class UserAuthorityGroupInfo extends BaseEntity{
|
|
|
- String? userGroupCode;
|
|
|
- String? description;
|
|
|
- List<String>? adminCodes;
|
|
|
- List<String>? features;
|
|
|
-
|
|
|
- UserAuthorityGroupInfo({
|
|
|
- this.userGroupCode,
|
|
|
- this.description,
|
|
|
- this.adminCodes,
|
|
|
- this.features,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory UserAuthorityGroupInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return UserAuthorityGroupInfo(
|
|
|
- userGroupCode: map['UserGroupCode'],
|
|
|
- description: map['Description'],
|
|
|
- adminCodes: map['AdminCodes'].cast<String>().toList(),
|
|
|
- features: map['Features'].cast<String>().toList(),
|
|
|
- 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(userGroupCode != null)
|
|
|
- map['UserGroupCode'] = userGroupCode;
|
|
|
- if(description != null)
|
|
|
- map['Description'] = description;
|
|
|
- if(adminCodes != null)
|
|
|
- map['AdminCodes'] = adminCodes;
|
|
|
- if(features != null)
|
|
|
- map['Features'] = features;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class BaseUserFeatureItem<T> {
|
|
|
- String? id;
|
|
|
- String? label;
|
|
|
- String? fatherCode;
|
|
|
- List<T>? children;
|
|
|
-
|
|
|
- BaseUserFeatureItem({
|
|
|
- this.id,
|
|
|
- this.label,
|
|
|
- this.fatherCode,
|
|
|
- this.children,
|
|
|
- });
|
|
|
-
|
|
|
- factory BaseUserFeatureItem.fromJson(Map<String, dynamic> map) {
|
|
|
- List<T> childrenList = [];
|
|
|
- if (map['Children'] != null) {
|
|
|
- childrenList.addAll(
|
|
|
- (map['Children'] as List).map((e) => FJsonConvert.fromJson<T>(e)!));
|
|
|
- }
|
|
|
- return BaseUserFeatureItem(
|
|
|
- id: map['Id'],
|
|
|
- label: map['Label'],
|
|
|
- fatherCode: map['FatherCode'],
|
|
|
- children: childrenList,
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(id != null)
|
|
|
- map['Id'] = id;
|
|
|
- if(label != null)
|
|
|
- map['Label'] = label;
|
|
|
- if(fatherCode != null)
|
|
|
- map['FatherCode'] = fatherCode;
|
|
|
- if(children != null)
|
|
|
- map['Children'] = children;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class UserFeatureItem extends BaseUserFeatureItem<UserFeatureItem>{
|
|
|
-
|
|
|
- UserFeatureItem({
|
|
|
- String? id,
|
|
|
- String? label,
|
|
|
- String? fatherCode,
|
|
|
- List<UserFeatureItem>? children,
|
|
|
- }) : super(
|
|
|
- id: id,
|
|
|
- label: label,
|
|
|
- fatherCode: fatherCode,
|
|
|
- children: children,
|
|
|
- );
|
|
|
-
|
|
|
- factory UserFeatureItem.fromJson(Map<String, dynamic> map) {
|
|
|
- List<UserFeatureItem> childrenList = [];
|
|
|
- if (map['Children'] != null) {
|
|
|
- childrenList.addAll(
|
|
|
- (map['Children'] as List).map((e) => FJsonConvert.fromJson<UserFeatureItem>(e)!));
|
|
|
- }
|
|
|
- return UserFeatureItem(
|
|
|
- id: map['Id'],
|
|
|
- label: map['Label'],
|
|
|
- fatherCode: map['FatherCode'],
|
|
|
- children: childrenList,
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = super.toJson();
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class UserFeatureInfo {
|
|
|
- String? featureCode;
|
|
|
- String? featureName;
|
|
|
- String? fatherCode;
|
|
|
-
|
|
|
- UserFeatureInfo({
|
|
|
- this.featureCode,
|
|
|
- this.featureName,
|
|
|
- this.fatherCode,
|
|
|
- });
|
|
|
-
|
|
|
- factory UserFeatureInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return UserFeatureInfo(
|
|
|
- featureCode: map['FeatureCode'],
|
|
|
- featureName: map['FeatureName'],
|
|
|
- fatherCode: map['FatherCode'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(featureCode != null)
|
|
|
- map['FeatureCode'] = featureCode;
|
|
|
- if(featureName != null)
|
|
|
- map['FeatureName'] = featureName;
|
|
|
- if(fatherCode != null)
|
|
|
- map['FatherCode'] = fatherCode;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class SelectItem {
|
|
|
- String? key;
|
|
|
- String? value;
|
|
|
-
|
|
|
- SelectItem({
|
|
|
- this.key,
|
|
|
- this.value,
|
|
|
- });
|
|
|
-
|
|
|
- factory SelectItem.fromJson(Map<String, dynamic> map) {
|
|
|
- return SelectItem(
|
|
|
- key: map['Key'],
|
|
|
- value: map['Value'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(key != null)
|
|
|
- map['Key'] = key;
|
|
|
- if(value != null)
|
|
|
- map['Value'] = value;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-enum RoleShowTypeEnum {
|
|
|
- NotShow,
|
|
|
- ISShow,
|
|
|
-}
|
|
|
-
|
|
|
-enum RoleQualificationEnum {
|
|
|
- NoNeed,
|
|
|
- ID,
|
|
|
- DocLicense,
|
|
|
- Both,
|
|
|
-}
|
|
|
-
|
|
|
-class RoleInfo extends BaseEntity{
|
|
|
- String? roleCode;
|
|
|
- String? roleName;
|
|
|
- RoleShowTypeEnum roleShowType;
|
|
|
- String? description;
|
|
|
- String? iConUrl;
|
|
|
- String? colorStart;
|
|
|
- String? colorEnd;
|
|
|
- RoleQualificationEnum roleQualification;
|
|
|
-
|
|
|
- RoleInfo({
|
|
|
- this.roleCode,
|
|
|
- this.roleName,
|
|
|
- this.roleShowType = RoleShowTypeEnum.NotShow,
|
|
|
- this.description,
|
|
|
- this.iConUrl,
|
|
|
- this.colorStart,
|
|
|
- this.colorEnd,
|
|
|
- this.roleQualification = RoleQualificationEnum.NoNeed,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory RoleInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return RoleInfo(
|
|
|
- roleCode: map['RoleCode'],
|
|
|
- roleName: map['RoleName'],
|
|
|
- roleShowType: RoleShowTypeEnum.values.firstWhere((e) => e.index == map['RoleShowType']),
|
|
|
- description: map['Description'],
|
|
|
- iConUrl: map['IConUrl'],
|
|
|
- colorStart: map['ColorStart'],
|
|
|
- colorEnd: map['ColorEnd'],
|
|
|
- roleQualification: RoleQualificationEnum.values.firstWhere((e) => e.index == map['RoleQualification']),
|
|
|
- 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(roleCode != null)
|
|
|
- map['RoleCode'] = roleCode;
|
|
|
- if(roleName != null)
|
|
|
- map['RoleName'] = roleName;
|
|
|
- map['RoleShowType'] = roleShowType.index;
|
|
|
- if(description != null)
|
|
|
- map['Description'] = description;
|
|
|
- if(iConUrl != null)
|
|
|
- map['IConUrl'] = iConUrl;
|
|
|
- if(colorStart != null)
|
|
|
- map['ColorStart'] = colorStart;
|
|
|
- if(colorEnd != null)
|
|
|
- map['ColorEnd'] = colorEnd;
|
|
|
- map['RoleQualification'] = roleQualification.index;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class ManageRoleInfo extends RoleInfo{
|
|
|
- List<String>? featuresCodeList;
|
|
|
-
|
|
|
- ManageRoleInfo({
|
|
|
- this.featuresCodeList,
|
|
|
- String? roleCode,
|
|
|
- String? roleName,
|
|
|
- RoleShowTypeEnum roleShowType = RoleShowTypeEnum.NotShow,
|
|
|
- String? description,
|
|
|
- String? iConUrl,
|
|
|
- String? colorStart,
|
|
|
- String? colorEnd,
|
|
|
- RoleQualificationEnum roleQualification = RoleQualificationEnum.NoNeed,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- roleCode: roleCode,
|
|
|
- roleName: roleName,
|
|
|
- roleShowType: roleShowType,
|
|
|
- description: description,
|
|
|
- iConUrl: iConUrl,
|
|
|
- colorStart: colorStart,
|
|
|
- colorEnd: colorEnd,
|
|
|
- roleQualification: roleQualification,
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory ManageRoleInfo.fromJson(Map<String, dynamic> map) {
|
|
|
- return ManageRoleInfo(
|
|
|
- featuresCodeList: map['FeaturesCodeList'].cast<String>().toList(),
|
|
|
- roleCode: map['RoleCode'],
|
|
|
- roleName: map['RoleName'],
|
|
|
- roleShowType: RoleShowTypeEnum.values.firstWhere((e) => e.index == map['RoleShowType']),
|
|
|
- description: map['Description'],
|
|
|
- iConUrl: map['IConUrl'],
|
|
|
- colorStart: map['ColorStart'],
|
|
|
- colorEnd: map['ColorEnd'],
|
|
|
- roleQualification: RoleQualificationEnum.values.firstWhere((e) => e.index == map['RoleQualification']),
|
|
|
- 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(featuresCodeList != null)
|
|
|
- map['FeaturesCodeList'] = featuresCodeList;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class FeatureDetail {
|
|
|
- String? id;
|
|
|
-
|
|
|
- FeatureDetail({
|
|
|
- this.id,
|
|
|
- });
|
|
|
-
|
|
|
- factory FeatureDetail.fromJson(Map<String, dynamic> map) {
|
|
|
- return FeatureDetail(
|
|
|
- id: map['Id'],
|
|
|
- );
|
|
|
- }
|
|
|
-
|
|
|
- Map<String, dynamic> toJson() {
|
|
|
- final map = Map<String, dynamic>();
|
|
|
- if(id != null)
|
|
|
- map['Id'] = id;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-class ManageRoleDetail extends RoleInfo{
|
|
|
- List<FeatureDetail>? featureList;
|
|
|
-
|
|
|
- ManageRoleDetail({
|
|
|
- this.featureList,
|
|
|
- String? roleCode,
|
|
|
- String? roleName,
|
|
|
- RoleShowTypeEnum roleShowType = RoleShowTypeEnum.NotShow,
|
|
|
- String? description,
|
|
|
- String? iConUrl,
|
|
|
- String? colorStart,
|
|
|
- String? colorEnd,
|
|
|
- RoleQualificationEnum roleQualification = RoleQualificationEnum.NoNeed,
|
|
|
- DateTime? createTime,
|
|
|
- DateTime? updateTime,
|
|
|
- }) : super(
|
|
|
- roleCode: roleCode,
|
|
|
- roleName: roleName,
|
|
|
- roleShowType: roleShowType,
|
|
|
- description: description,
|
|
|
- iConUrl: iConUrl,
|
|
|
- colorStart: colorStart,
|
|
|
- colorEnd: colorEnd,
|
|
|
- roleQualification: roleQualification,
|
|
|
- createTime: createTime,
|
|
|
- updateTime: updateTime,
|
|
|
- );
|
|
|
-
|
|
|
- factory ManageRoleDetail.fromJson(Map<String, dynamic> map) {
|
|
|
- return ManageRoleDetail(
|
|
|
- featureList: map['FeatureList'].map((e)=>FeatureDetail.fromJson(e as Map<String,dynamic>)).toList(),
|
|
|
- roleCode: map['RoleCode'],
|
|
|
- roleName: map['RoleName'],
|
|
|
- roleShowType: RoleShowTypeEnum.values.firstWhere((e) => e.index == map['RoleShowType']),
|
|
|
- description: map['Description'],
|
|
|
- iConUrl: map['IConUrl'],
|
|
|
- colorStart: map['ColorStart'],
|
|
|
- colorEnd: map['ColorEnd'],
|
|
|
- roleQualification: RoleQualificationEnum.values.firstWhere((e) => e.index == map['RoleQualification']),
|
|
|
- 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(featureList != null)
|
|
|
- map['FeatureList'] = featureList;
|
|
|
- return map;
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
+import 'package:fis_jsonrpc/utils.dart';
import 'package:fis_common/json_convert.dart';
|
|
|
+
|
|
|
+class AdminAccountInfo {
|
|
|
+ String? adminCode;
|
|
|
+ String? fatherCode;
|
|
|
+ String? adminName;
|
|
|
+ String? secretPassword;
|
|
|
+ String? headImageToken;
|
|
|
+ String? licenseKey;
|
|
|
+ String? lastIP;
|
|
|
+ String? phone;
|
|
|
+ String? email;
|
|
|
+
|
|
|
+ AdminAccountInfo({
|
|
|
+ this.adminCode,
|
|
|
+ this.fatherCode,
|
|
|
+ this.adminName,
|
|
|
+ this.secretPassword,
|
|
|
+ this.headImageToken,
|
|
|
+ this.licenseKey,
|
|
|
+ this.lastIP,
|
|
|
+ this.phone,
|
|
|
+ this.email,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory AdminAccountInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return AdminAccountInfo(
|
|
|
+ adminCode: map['AdminCode'],
|
|
|
+ fatherCode: map['FatherCode'],
|
|
|
+ adminName: map['AdminName'],
|
|
|
+ secretPassword: map['SecretPassword'],
|
|
|
+ headImageToken: map['HeadImageToken'],
|
|
|
+ licenseKey: map['LicenseKey'],
|
|
|
+ lastIP: map['LastIP'],
|
|
|
+ phone: map['Phone'],
|
|
|
+ email: map['Email'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(adminCode != null)
|
|
|
+ map['AdminCode'] = adminCode;
|
|
|
+ if(fatherCode != null)
|
|
|
+ map['FatherCode'] = fatherCode;
|
|
|
+ if(adminName != null)
|
|
|
+ map['AdminName'] = adminName;
|
|
|
+ if(secretPassword != null)
|
|
|
+ map['SecretPassword'] = secretPassword;
|
|
|
+ if(headImageToken != null)
|
|
|
+ map['HeadImageToken'] = headImageToken;
|
|
|
+ if(licenseKey != null)
|
|
|
+ map['LicenseKey'] = licenseKey;
|
|
|
+ if(lastIP != null)
|
|
|
+ map['LastIP'] = lastIP;
|
|
|
+ if(phone != null)
|
|
|
+ map['Phone'] = phone;
|
|
|
+ if(email != null)
|
|
|
+ map['Email'] = email;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class PageCollection<T> {
|
|
|
+ int currentPage;
|
|
|
+ int pageSize;
|
|
|
+ int dataCount;
|
|
|
+ List<T>? pageData;
|
|
|
+
|
|
|
+ PageCollection({
|
|
|
+ this.currentPage=0,
|
|
|
+ this.pageSize=0,
|
|
|
+ this.dataCount=0,
|
|
|
+ this.pageData,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory PageCollection.fromJson(Map<String, dynamic> map) {
|
|
|
+ List<T> pageDataList = [];
|
|
|
+ if (map['PageData'] != null) {
|
|
|
+ pageDataList.addAll(
|
|
|
+ (map['PageData'] as List).map((e) => FJsonConvert.fromJson<T>(e)!));
|
|
|
+ }
|
|
|
+ return PageCollection(
|
|
|
+ currentPage: map['CurrentPage'],
|
|
|
+ pageSize: map['PageSize'],
|
|
|
+ dataCount: map['DataCount'],
|
|
|
+ pageData: pageDataList,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ map['CurrentPage'] = currentPage;
|
|
|
+ map['PageSize'] = pageSize;
|
|
|
+ map['DataCount'] = dataCount;
|
|
|
+ if(pageData != null)
|
|
|
+ map['PageData'] = pageData;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+enum UserInfoStateEnum {
|
|
|
+ Nonactivated,
|
|
|
+ Activated,
|
|
|
+}
|
|
|
+
|
|
|
+enum ApplyStateEnum {
|
|
|
+ Applying,
|
|
|
+ Refused,
|
|
|
+ Passed,
|
|
|
+}
|
|
|
+
|
|
|
+class UserInfo {
|
|
|
+ String? userCode;
|
|
|
+ String? userName;
|
|
|
+ String? phone;
|
|
|
+ String? email;
|
|
|
+ String? nickName;
|
|
|
+ String? fullName;
|
|
|
+ String? headImageUrl;
|
|
|
+ String? organizationCode;
|
|
|
+ List<String>? authorityGroups;
|
|
|
+ List<String>? bindDevices;
|
|
|
+ String? lastIP;
|
|
|
+ int logintimes;
|
|
|
+ UserInfoStateEnum userState;
|
|
|
+ List<String>? roleCodes;
|
|
|
+ List<String>? rankCodes;
|
|
|
+ ApplyStateEnum applyState;
|
|
|
+ String? roleName;
|
|
|
+ DateTime? createTime;
|
|
|
+ DateTime? updateTime;
|
|
|
+
|
|
|
+ UserInfo({
|
|
|
+ this.userCode,
|
|
|
+ this.userName,
|
|
|
+ this.phone,
|
|
|
+ this.email,
|
|
|
+ this.nickName,
|
|
|
+ this.fullName,
|
|
|
+ this.headImageUrl,
|
|
|
+ this.organizationCode,
|
|
|
+ this.authorityGroups,
|
|
|
+ this.bindDevices,
|
|
|
+ this.lastIP,
|
|
|
+ this.logintimes=0,
|
|
|
+ this.userState=UserInfoStateEnum.Nonactivated,
|
|
|
+ this.roleCodes,
|
|
|
+ this.rankCodes,
|
|
|
+ this.applyState=ApplyStateEnum.Applying,
|
|
|
+ this.roleName,
|
|
|
+ this.createTime,
|
|
|
+ this.updateTime,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory UserInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return UserInfo(
|
|
|
+ userCode: map['UserCode'],
|
|
|
+ userName: map['UserName'],
|
|
|
+ phone: map['Phone'],
|
|
|
+ email: map['Email'],
|
|
|
+ nickName: map['NickName'],
|
|
|
+ fullName: map['FullName'],
|
|
|
+ headImageUrl: map['HeadImageUrl'],
|
|
|
+ organizationCode: map['OrganizationCode'],
|
|
|
+ authorityGroups: map['AuthorityGroups'].cast<String>().toList(),
|
|
|
+ bindDevices: map['BindDevices'].cast<String>().toList(),
|
|
|
+ lastIP: map['LastIP'],
|
|
|
+ logintimes: map['Logintimes'],
|
|
|
+ userState: UserInfoStateEnum.values.firstWhere((e) => e.index == map['UserState']),
|
|
|
+ roleCodes: map['RoleCodes'].cast<String>().toList(),
|
|
|
+ rankCodes: map['RankCodes'].cast<String>().toList(),
|
|
|
+ applyState: ApplyStateEnum.values.firstWhere((e) => e.index == map['ApplyState']),
|
|
|
+ roleName: map['RoleName'],
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(userCode != null)
|
|
|
+ map['UserCode'] = userCode;
|
|
|
+ if(userName != null)
|
|
|
+ map['UserName'] = userName;
|
|
|
+ if(phone != null)
|
|
|
+ map['Phone'] = phone;
|
|
|
+ if(email != null)
|
|
|
+ map['Email'] = email;
|
|
|
+ if(nickName != null)
|
|
|
+ map['NickName'] = nickName;
|
|
|
+ if(fullName != null)
|
|
|
+ map['FullName'] = fullName;
|
|
|
+ if(headImageUrl != null)
|
|
|
+ map['HeadImageUrl'] = headImageUrl;
|
|
|
+ if(organizationCode != null)
|
|
|
+ map['OrganizationCode'] = organizationCode;
|
|
|
+ if(authorityGroups != null)
|
|
|
+ map['AuthorityGroups'] = authorityGroups;
|
|
|
+ if(bindDevices != null)
|
|
|
+ map['BindDevices'] = bindDevices;
|
|
|
+ if(lastIP != null)
|
|
|
+ map['LastIP'] = lastIP;
|
|
|
+ map['Logintimes'] = logintimes;
|
|
|
+ map['UserState'] = userState.index;
|
|
|
+ if(roleCodes != null)
|
|
|
+ map['RoleCodes'] = roleCodes;
|
|
|
+ if(rankCodes != null)
|
|
|
+ map['RankCodes'] = rankCodes;
|
|
|
+ map['ApplyState'] = applyState.index;
|
|
|
+ if(roleName != null)
|
|
|
+ map['RoleName'] = roleName;
|
|
|
+ if(createTime != null)
|
|
|
+ map['CreateTime'] = JsonRpcUtils.dateFormat(createTime!);
|
|
|
+ if(updateTime != null)
|
|
|
+ map['UpdateTime'] = JsonRpcUtils.dateFormat(updateTime!);
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class UserInfoListQueryRequest {
|
|
|
+ String? queryType;
|
|
|
+ String? keyword;
|
|
|
+ String? queryState;
|
|
|
+ int page;
|
|
|
+ int limit;
|
|
|
+ String? sessionId;
|
|
|
+
|
|
|
+ UserInfoListQueryRequest({
|
|
|
+ this.queryType,
|
|
|
+ this.keyword,
|
|
|
+ this.queryState,
|
|
|
+ this.page=0,
|
|
|
+ this.limit=0,
|
|
|
+ this.sessionId,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory UserInfoListQueryRequest.fromJson(Map<String, dynamic> map) {
|
|
|
+ return UserInfoListQueryRequest(
|
|
|
+ queryType: map['QueryType'],
|
|
|
+ keyword: map['Keyword'],
|
|
|
+ queryState: map['QueryState'],
|
|
|
+ page: map['Page'],
|
|
|
+ limit: map['Limit'],
|
|
|
+ sessionId: map['SessionId'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(queryType != null)
|
|
|
+ map['QueryType'] = queryType;
|
|
|
+ if(keyword != null)
|
|
|
+ map['Keyword'] = keyword;
|
|
|
+ if(queryState != null)
|
|
|
+ map['QueryState'] = queryState;
|
|
|
+ map['Page'] = page;
|
|
|
+ map['Limit'] = limit;
|
|
|
+ if(sessionId != null)
|
|
|
+ map['SessionId'] = sessionId;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class ReportInfo {
|
|
|
+ String? reportCode;
|
|
|
+ String? snapShotReportTemplate;
|
|
|
+ String? reportValuesJson;
|
|
|
+ String? recordCode;
|
|
|
+ String? reportUser;
|
|
|
+ String? tags;
|
|
|
+ String? reportImageUrl;
|
|
|
+ String? reportHtmlRaw;
|
|
|
+
|
|
|
+ ReportInfo({
|
|
|
+ this.reportCode,
|
|
|
+ this.snapShotReportTemplate,
|
|
|
+ this.reportValuesJson,
|
|
|
+ this.recordCode,
|
|
|
+ this.reportUser,
|
|
|
+ this.tags,
|
|
|
+ this.reportImageUrl,
|
|
|
+ this.reportHtmlRaw,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory ReportInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return ReportInfo(
|
|
|
+ reportCode: map['ReportCode'],
|
|
|
+ snapShotReportTemplate: map['SnapShotReportTemplate'],
|
|
|
+ reportValuesJson: map['ReportValuesJson'],
|
|
|
+ recordCode: map['RecordCode'],
|
|
|
+ reportUser: map['ReportUser'],
|
|
|
+ tags: map['Tags'],
|
|
|
+ reportImageUrl: map['ReportImageUrl'],
|
|
|
+ reportHtmlRaw: map['ReportHtmlRaw'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(reportCode != null)
|
|
|
+ map['ReportCode'] = reportCode;
|
|
|
+ if(snapShotReportTemplate != null)
|
|
|
+ map['SnapShotReportTemplate'] = snapShotReportTemplate;
|
|
|
+ if(reportValuesJson != null)
|
|
|
+ map['ReportValuesJson'] = reportValuesJson;
|
|
|
+ if(recordCode != null)
|
|
|
+ map['RecordCode'] = recordCode;
|
|
|
+ if(reportUser != null)
|
|
|
+ map['ReportUser'] = reportUser;
|
|
|
+ if(tags != null)
|
|
|
+ map['Tags'] = tags;
|
|
|
+ if(reportImageUrl != null)
|
|
|
+ map['ReportImageUrl'] = reportImageUrl;
|
|
|
+ if(reportHtmlRaw != null)
|
|
|
+ map['ReportHtmlRaw'] = reportHtmlRaw;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+enum RecordTypeEnum {
|
|
|
+ Ultrasound,
|
|
|
+ Electrocardio,
|
|
|
+}
|
|
|
+
|
|
|
+enum CheckTypeEnum {
|
|
|
+ Default,
|
|
|
+}
|
|
|
+
|
|
|
+enum RecordStatusEnum {
|
|
|
+ Default,
|
|
|
+}
|
|
|
+
|
|
|
+class RecordInfo {
|
|
|
+ String? recordCode;
|
|
|
+ String? patientCode;
|
|
|
+ String? patientName;
|
|
|
+ String? orgName;
|
|
|
+ RecordTypeEnum recordType;
|
|
|
+ CheckTypeEnum checkType;
|
|
|
+ String? localRecordCode;
|
|
|
+ RecordStatusEnum recordStatus;
|
|
|
+ String? recordRemark;
|
|
|
+ String? tags;
|
|
|
+ DateTime? createTime;
|
|
|
+ DateTime? updateTime;
|
|
|
+
|
|
|
+ RecordInfo({
|
|
|
+ this.recordCode,
|
|
|
+ this.patientCode,
|
|
|
+ this.patientName,
|
|
|
+ this.orgName,
|
|
|
+ this.recordType=RecordTypeEnum.Ultrasound,
|
|
|
+ this.checkType=CheckTypeEnum.Default,
|
|
|
+ this.localRecordCode,
|
|
|
+ this.recordStatus=RecordStatusEnum.Default,
|
|
|
+ this.recordRemark,
|
|
|
+ this.tags,
|
|
|
+ this.createTime,
|
|
|
+ this.updateTime,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory RecordInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return RecordInfo(
|
|
|
+ recordCode: map['RecordCode'],
|
|
|
+ patientCode: map['PatientCode'],
|
|
|
+ patientName: map['PatientName'],
|
|
|
+ orgName: map['OrgName'],
|
|
|
+ recordType: RecordTypeEnum.values.firstWhere((e) => e.index == map['RecordType']),
|
|
|
+ checkType: CheckTypeEnum.values.firstWhere((e) => e.index == map['CheckType']),
|
|
|
+ localRecordCode: map['LocalRecordCode'],
|
|
|
+ recordStatus: RecordStatusEnum.values.firstWhere((e) => e.index == map['RecordStatus']),
|
|
|
+ recordRemark: map['RecordRemark'],
|
|
|
+ tags: map['Tags'],
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(recordCode != null)
|
|
|
+ map['RecordCode'] = recordCode;
|
|
|
+ if(patientCode != null)
|
|
|
+ map['PatientCode'] = patientCode;
|
|
|
+ if(patientName != null)
|
|
|
+ map['PatientName'] = patientName;
|
|
|
+ if(orgName != null)
|
|
|
+ map['OrgName'] = orgName;
|
|
|
+ map['RecordType'] = recordType.index;
|
|
|
+ map['CheckType'] = checkType.index;
|
|
|
+ if(localRecordCode != null)
|
|
|
+ map['LocalRecordCode'] = localRecordCode;
|
|
|
+ map['RecordStatus'] = recordStatus.index;
|
|
|
+ if(recordRemark != null)
|
|
|
+ map['RecordRemark'] = recordRemark;
|
|
|
+ if(tags != null)
|
|
|
+ map['Tags'] = tags;
|
|
|
+ if(createTime != null)
|
|
|
+ map['CreateTime'] = JsonRpcUtils.dateFormat(createTime!);
|
|
|
+ if(updateTime != null)
|
|
|
+ map['UpdateTime'] = JsonRpcUtils.dateFormat(updateTime!);
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+enum DeviceDataTypeEnum {
|
|
|
+ Default,
|
|
|
+}
|
|
|
+
|
|
|
+class DeviceData {
|
|
|
+ String? deviceDataCode;
|
|
|
+ String? deviceCode;
|
|
|
+ String? deviceFileCode;
|
|
|
+ String? recordCode;
|
|
|
+ String? patientCode;
|
|
|
+ String? previewImageToken;
|
|
|
+ String? dataToken;
|
|
|
+ DeviceDataTypeEnum deviceDataType;
|
|
|
+ String? processResult;
|
|
|
+ DateTime? createTime;
|
|
|
+ DateTime? updateTime;
|
|
|
+
|
|
|
+ DeviceData({
|
|
|
+ this.deviceDataCode,
|
|
|
+ this.deviceCode,
|
|
|
+ this.deviceFileCode,
|
|
|
+ this.recordCode,
|
|
|
+ this.patientCode,
|
|
|
+ this.previewImageToken,
|
|
|
+ this.dataToken,
|
|
|
+ this.deviceDataType=DeviceDataTypeEnum.Default,
|
|
|
+ this.processResult,
|
|
|
+ this.createTime,
|
|
|
+ this.updateTime,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory DeviceData.fromJson(Map<String, dynamic> map) {
|
|
|
+ return DeviceData(
|
|
|
+ deviceDataCode: map['DeviceDataCode'],
|
|
|
+ deviceCode: map['DeviceCode'],
|
|
|
+ deviceFileCode: map['DeviceFileCode'],
|
|
|
+ recordCode: map['RecordCode'],
|
|
|
+ patientCode: map['PatientCode'],
|
|
|
+ previewImageToken: map['PreviewImageToken'],
|
|
|
+ dataToken: map['DataToken'],
|
|
|
+ deviceDataType: DeviceDataTypeEnum.values.firstWhere((e) => e.index == map['DeviceDataType']),
|
|
|
+ processResult: map['ProcessResult'],
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(deviceDataCode != null)
|
|
|
+ map['DeviceDataCode'] = deviceDataCode;
|
|
|
+ if(deviceCode != null)
|
|
|
+ map['DeviceCode'] = deviceCode;
|
|
|
+ if(deviceFileCode != null)
|
|
|
+ map['DeviceFileCode'] = deviceFileCode;
|
|
|
+ if(recordCode != null)
|
|
|
+ map['RecordCode'] = recordCode;
|
|
|
+ if(patientCode != null)
|
|
|
+ map['PatientCode'] = patientCode;
|
|
|
+ if(previewImageToken != null)
|
|
|
+ map['PreviewImageToken'] = previewImageToken;
|
|
|
+ if(dataToken != null)
|
|
|
+ map['DataToken'] = dataToken;
|
|
|
+ map['DeviceDataType'] = deviceDataType.index;
|
|
|
+ if(processResult != null)
|
|
|
+ map['ProcessResult'] = processResult;
|
|
|
+ if(createTime != null)
|
|
|
+ map['CreateTime'] = JsonRpcUtils.dateFormat(createTime!);
|
|
|
+ if(updateTime != null)
|
|
|
+ map['UpdateTime'] = JsonRpcUtils.dateFormat(updateTime!);
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+enum GenderTypeEnum {
|
|
|
+ Male,
|
|
|
+ Female,
|
|
|
+}
|
|
|
+
|
|
|
+enum PatientTypeEnum {
|
|
|
+ Default,
|
|
|
+}
|
|
|
+
|
|
|
+class PatientInfo {
|
|
|
+ String? patientCode;
|
|
|
+ String? firstName;
|
|
|
+ String? lastName;
|
|
|
+ String? patientCardNo;
|
|
|
+ DateTime? birthday;
|
|
|
+ GenderTypeEnum genderType;
|
|
|
+ String? patientCaseHistory;
|
|
|
+ String? patientPhone;
|
|
|
+ PatientTypeEnum patientType;
|
|
|
+ DateTime? createTime;
|
|
|
+ DateTime? updateTime;
|
|
|
+
|
|
|
+ PatientInfo({
|
|
|
+ this.patientCode,
|
|
|
+ this.firstName,
|
|
|
+ this.lastName,
|
|
|
+ this.patientCardNo,
|
|
|
+ this.birthday,
|
|
|
+ this.genderType=GenderTypeEnum.Male,
|
|
|
+ this.patientCaseHistory,
|
|
|
+ this.patientPhone,
|
|
|
+ this.patientType=PatientTypeEnum.Default,
|
|
|
+ this.createTime,
|
|
|
+ this.updateTime,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory PatientInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return PatientInfo(
|
|
|
+ patientCode: map['PatientCode'],
|
|
|
+ firstName: map['FirstName'],
|
|
|
+ lastName: map['LastName'],
|
|
|
+ patientCardNo: map['PatientCardNo'],
|
|
|
+ birthday: map['Birthday'] != null ? DateTime.parse(map['Birthday']) : null,
|
|
|
+ genderType: GenderTypeEnum.values.firstWhere((e) => e.index == map['GenderType']),
|
|
|
+ patientCaseHistory: map['PatientCaseHistory'],
|
|
|
+ patientPhone: map['PatientPhone'],
|
|
|
+ patientType: PatientTypeEnum.values.firstWhere((e) => e.index == map['PatientType']),
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(patientCode != null)
|
|
|
+ map['PatientCode'] = patientCode;
|
|
|
+ if(firstName != null)
|
|
|
+ map['FirstName'] = firstName;
|
|
|
+ if(lastName != null)
|
|
|
+ map['LastName'] = lastName;
|
|
|
+ if(patientCardNo != null)
|
|
|
+ map['PatientCardNo'] = patientCardNo;
|
|
|
+ if(birthday != null)
|
|
|
+ map['Birthday'] = JsonRpcUtils.dateFormat(birthday!);
|
|
|
+ map['GenderType'] = genderType.index;
|
|
|
+ if(patientCaseHistory != null)
|
|
|
+ map['PatientCaseHistory'] = patientCaseHistory;
|
|
|
+ if(patientPhone != null)
|
|
|
+ map['PatientPhone'] = patientPhone;
|
|
|
+ map['PatientType'] = patientType.index;
|
|
|
+ if(createTime != null)
|
|
|
+ map['CreateTime'] = JsonRpcUtils.dateFormat(createTime!);
|
|
|
+ if(updateTime != null)
|
|
|
+ map['UpdateTime'] = JsonRpcUtils.dateFormat(updateTime!);
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class MenuInfo {
|
|
|
+ String? menuCode;
|
|
|
+ String? menuName;
|
|
|
+ String? menuType;
|
|
|
+ String? menuShowName;
|
|
|
+ int menuSort;
|
|
|
+ String? menuFatherCode;
|
|
|
+
|
|
|
+ MenuInfo({
|
|
|
+ this.menuCode,
|
|
|
+ this.menuName,
|
|
|
+ this.menuType,
|
|
|
+ this.menuShowName,
|
|
|
+ this.menuSort=0,
|
|
|
+ this.menuFatherCode,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory MenuInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return MenuInfo(
|
|
|
+ menuCode: map['MenuCode'],
|
|
|
+ menuName: map['MenuName'],
|
|
|
+ menuType: map['MenuType'],
|
|
|
+ menuShowName: map['MenuShowName'],
|
|
|
+ menuSort: map['MenuSort'],
|
|
|
+ menuFatherCode: map['MenuFatherCode'],
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(menuCode != null)
|
|
|
+ map['MenuCode'] = menuCode;
|
|
|
+ if(menuName != null)
|
|
|
+ map['MenuName'] = menuName;
|
|
|
+ if(menuType != null)
|
|
|
+ map['MenuType'] = menuType;
|
|
|
+ if(menuShowName != null)
|
|
|
+ map['MenuShowName'] = menuShowName;
|
|
|
+ map['MenuSort'] = menuSort;
|
|
|
+ if(menuFatherCode != null)
|
|
|
+ map['MenuFatherCode'] = menuFatherCode;
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+class FrontAuthorityGroupInfo {
|
|
|
+ String? frontGroupCode;
|
|
|
+ String? description;
|
|
|
+ List<String>? adminCodes;
|
|
|
+ List<String>? features;
|
|
|
+ DateTime? createTime;
|
|
|
+ DateTime? updateTime;
|
|
|
+
|
|
|
+ FrontAuthorityGroupInfo({
|
|
|
+ this.frontGroupCode,
|
|
|
+ this.description,
|
|
|
+ this.adminCodes,
|
|
|
+ this.features,
|
|
|
+ this.createTime,
|
|
|
+ this.updateTime,
|
|
|
+ });
|
|
|
+
|
|
|
+ factory FrontAuthorityGroupInfo.fromJson(Map<String, dynamic> map) {
|
|
|
+ return FrontAuthorityGroupInfo(
|
|
|
+ frontGroupCode: map['FrontGroupCode'],
|
|
|
+ description: map['Description'],
|
|
|
+ adminCodes: map['AdminCodes'].cast<String>().toList(),
|
|
|
+ features: map['Features'].cast<String>().toList(),
|
|
|
+ createTime: map['CreateTime'] != null ? DateTime.parse(map['CreateTime']) : null,
|
|
|
+ updateTime: map['UpdateTime'] != null ? DateTime.parse(map['UpdateTime']) : null,
|
|
|
+ );
|
|
|
+ }
|
|
|
+
|
|
|
+ Map<String, dynamic> toJson() {
|
|
|
+ final map = Map<String, dynamic>();
|
|
|
+ if(frontGroupCode != null)
|
|
|
+ map['FrontGroupCode'] = frontGroupCode;
|
|
|
+ if(description != null)
|
|
|
+ map['Description'] = description;
|
|
|
+ if(adminCodes != null)
|
|
|
+ map['AdminCodes'] = adminCodes;
|
|
|
+ if(features != null)
|
|
|
+ map['Features'] = features;
|
|
|
+ if(createTime != null)
|
|
|
+ map['CreateTime'] = JsonRpcUtils.dateFormat(createTime!);
|
|
|
+ if(updateTime != null)
|
|
|
+ map['UpdateTime'] = JsonRpcUtils.dateFormat(updateTime!);
|
|
|
+ return map;
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+
|