Browse Source

temp commit for deploy system

arthur.wu 2 years ago
parent
commit
dc52ffab1d

+ 0 - 1
Tools/Flyinsono.Deployment/lib/ApprovalConsultationScreen.dart

@@ -1 +0,0 @@
-// TODO Implement this library.

+ 5 - 87
Tools/Flyinsono.Deployment/lib/AutoTestView.dart

@@ -1,9 +1,9 @@
 import 'package:autocomplete_textfield/autocomplete_textfield.dart';
 import 'package:flutter/material.dart';
 import 'package:get_it/get_it.dart';
-import 'package:ustest/ConsultationList.dart';
+import 'package:ustest/BuildHistoryList.dart';
 
-import 'Services/ConsultationService.dart';
+import 'Services/BuildService.dart';
 import 'Services/NotificationReceivedArgs.dart';
 
 class AutoTestView extends StatefulWidget {
@@ -28,7 +28,7 @@ class _AutoTestView extends State<AutoTestView> {
     } else {
       selectedState = 2;
     }
-    Future<List<Consultation>> future = fetchConsultations(selectedState);
+
     GlobalKey<AutoCompleteTextFieldState<String>> typeKey = GlobalKey();
     GlobalKey listKey = GlobalKey();
     return Scaffold(
@@ -36,12 +36,7 @@ class _AutoTestView extends State<AutoTestView> {
         child: Column(
           children: [
             Row(
-              children: [
-                TextButton.icon(
-                    onPressed: () => onApplyConsultation(context),
-                    icon: Icon(Icons.add),
-                    label: Text("Apply")),
-              ],
+              children: [],
             ),
             Padding(
                 padding: const EdgeInsets.all(8.0),
@@ -67,87 +62,10 @@ class _AutoTestView extends State<AutoTestView> {
                     label: Text("Search")),
               ],
             ),
-            Expanded(
-                child: Center(
-              child: FutureBuilder<List<Consultation>>(
-                key: listKey,
-                future: future,
-                builder: (context, snapshot) {
-                  if (snapshot.hasError) {
-                    return const Center(
-                      child: Text('An error has occurred!'),
-                    );
-                  } else if (snapshot.hasData) {
-                    return ConsultationList(
-                        token: "accessToken", consultations: snapshot.data!);
-                  } else {
-                    return const Center(
-                      child: CircularProgressIndicator(),
-                    );
-                  }
-                },
-              ),
-            )),
+            Expanded(child: Center()),
           ],
         ),
       ),
     );
   }
-
-  Future<List<Consultation>> fetchConsultations(int? selectedType) async {
-    try {
-      var service = GetIt.instance.get<ConsultationService>();
-
-      var list = await service.FindConsultationsByPageAsync('id', selectedType);
-      return list;
-    } catch (ex) {
-      print('QueryExam.to ex' + ex.toString());
-      return List.empty();
-    }
-  }
-
-  void onApplyConsultation(context) {
-    print("onApplyConsultation click");
-    Navigator.of(context).pushNamed('/applyconsultation');
-  }
-}
-
-class ConnectionNotification {
-  NotificationTypeEnum notificationType;
-  ConnectionNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory ConnectionNotification.fromJson(Map<String, dynamic> map) {
-    return ConnectionNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class DisconnectNotification {
-  NotificationTypeEnum notificationType;
-  DisconnectNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory DisconnectNotification.fromJson(Map<String, dynamic> map) {
-    return DisconnectNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class FinishNotifyRecordsMessage {
-  NotificationTypeEnum notificationType;
-  List<String>? codes;
-  FinishNotifyRecordsMessage(
-      {this.notificationType = NotificationTypeEnum.Unknown, this.codes});
-  factory FinishNotifyRecordsMessage.fromJson(Map<String, dynamic> map) {
-    return FinishNotifyRecordsMessage(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-      codes: map['Codes'] != null ? map['Codes'].cast<String>().toList() : null,
-    );
-  }
 }

+ 151 - 0
Tools/Flyinsono.Deployment/lib/BuildHistoryList.dart

@@ -0,0 +1,151 @@
+import 'package:flutter/material.dart';
+import 'package:get_it/get_it.dart';
+import 'package:ustest/Services/UserService.dart';
+import 'package:ustest/tool.dart';
+import 'Services/BuildService.dart';
+
+class BuildHistoryList extends StatefulWidget {
+  BuildHistoryList({Key? key, required this.token, required this.histories})
+      : super();
+  final String token;
+  final List<BuildHistory> histories;
+
+  @override
+  _ConsultationListState createState() => _ConsultationListState();
+}
+
+class _ConsultationListState extends State<BuildHistoryList> {
+  @override
+  void initState() {
+    var service = GetIt.instance.get<UserService>();
+    service.NotificationReceived.subscribe((args) {
+      if (args == null) {
+        return;
+      }
+    });
+    super.initState();
+  }
+
+  @override
+  void dispose() {
+    var service = GetIt.instance.get<UserService>();
+    service.NotificationReceived.unsubscribe((args) {});
+    super.dispose();
+  }
+
+  void showConfirmDialog(BuildContext context, String content,
+      Function confirmCallback, Function rejectCallback) {
+    showDialog(
+        context: context,
+        builder: (context) {
+          return new AlertDialog(
+            title: new Text("提示"),
+            content: new Text(content),
+            actions: <Widget>[
+              new TextButton(
+                onPressed: () {
+                  confirmCallback();
+                  Navigator.of(context).pop();
+                },
+                child: new Text("接受"),
+              ),
+              new TextButton(
+                onPressed: () {
+                  Navigator.of(context).pop();
+                },
+                child: new Text("拒絕"),
+              ),
+            ],
+          );
+        });
+  }
+
+  @override
+  Widget build(BuildContext context) {
+    return Scaffold(
+        body: Container(
+      height: 600,
+      child: Row(
+        children: [
+          Container(
+            height: 500,
+            width: 400,
+            child: ListView(
+              restorationId: 'list_demo_list_view',
+              padding: const EdgeInsets.symmetric(vertical: 0),
+              children: [
+                for (int index = 0; index < widget.histories.length; index++)
+                  Row(
+                    children: [
+                      Expanded(
+                          child: Container(
+                        child: ListTile(
+                          leading: ExcludeSemantics(
+                            child: Icon(Icons.person),
+                          ),
+                          title: Text(widget.histories[index].id),
+                          onTap: (() =>
+                              onTabPatient(widget.histories[index].id)),
+                        ),
+                      )),
+                      Row(
+                        children: [Offstage()],
+                      ),
+                      Container(
+                          alignment: Alignment.topRight,
+                          child: Container(
+                            child: Column(
+                              children: [
+                                ClipRRect(
+                                    borderRadius: BorderRadius.circular(2),
+                                    child: Container(
+                                        color: Colors.amber[50],
+                                        child: Row(children: [
+                                          Icon(
+                                            Icons.star,
+                                            color: Colors.amber[500],
+                                            size: 12,
+                                          ),
+                                          Text(
+                                            "5.0",
+                                            style: TextStyle(
+                                                color: Colors.amber[900],
+                                                fontSize: 9),
+                                          ),
+                                        ]))),
+                                Container(
+                                    child: Row(
+                                  children: [
+                                    TextButton(
+                                        child: Text("Start"),
+                                        onPressed: (() =>
+                                            OnStartLiveConsultation(
+                                                widget.histories[index].id))),
+                                  ],
+                                ))
+                              ],
+                            ),
+                          )),
+                    ],
+                  ),
+              ],
+            ),
+          ),
+        ],
+      ),
+    ));
+  }
+
+  void onTabPatient(String id) async {}
+
+  void OnStartLiveConsultation(id) async {
+    try {
+      //var service = GetIt.instance.get<ConsultationService>();
+
+      Navigator.of(context).pushNamed('/meeting');
+    } catch (ex) {
+      print('OnStartLiveConsultation.to ex:$ex');
+      MeetingTool.toast(ex.toString(), context);
+    }
+  }
+}

+ 60 - 86
Tools/Flyinsono.Deployment/lib/BuildView.dart

@@ -1,10 +1,10 @@
 import 'package:autocomplete_textfield/autocomplete_textfield.dart';
+import 'package:colorize_logger/colorize_logger.dart';
 import 'package:flutter/material.dart';
 import 'package:get_it/get_it.dart';
-import 'package:ustest/ConsultationList.dart';
+import 'package:ustest/BuildHistoryList.dart';
 
-import 'Services/ConsultationService.dart';
-import 'Services/NotificationReceivedArgs.dart';
+import 'Services/BuildService.dart';
 
 class BuildView extends StatefulWidget {
   @override
@@ -15,21 +15,14 @@ class BuildView extends StatefulWidget {
 }
 
 class _BuildView extends State<BuildView> {
-  String? selectedType = "我申请的";
-
+  final platforms = ["Windows", "Linux", "IOS"];
+  String? selectedPlatform;
+  GlobalKey<AutoCompleteTextFieldState<String>> platformKey =
+      GlobalKey<AutoCompleteTextFieldState<String>>();
   @override
   Widget build(BuildContext context) {
-    final items = <String>["我申请的", "我组织的", "我参与的"];
-    int selectedState = 0;
-    if (selectedType == "我申请的") {
-      selectedState = 0;
-    } else if (selectedType == "我组织的") {
-      selectedState = 1;
-    } else {
-      selectedState = 2;
-    }
-    Future<List<Consultation>> future = fetchConsultations(selectedState);
-    GlobalKey<AutoCompleteTextFieldState<String>> typeKey = GlobalKey();
+    Future<List<BuildHistory>> future = fetchBuildHistories();
+
     GlobalKey listKey = GlobalKey();
     return Scaffold(
       body: Center(
@@ -37,28 +30,46 @@ class _BuildView extends State<BuildView> {
           children: [
             Row(
               children: [
+                Text(
+                  'Platform:',
+                  style: TextStyle(backgroundColor: Colors.lightBlueAccent),
+                  textAlign: TextAlign.center,
+                ),
+                SizedBox(
+                    width: 136,
+                    child: Expanded(
+                      child: DropdownButtonFormField<String>(
+                        decoration: InputDecoration(
+                            hintText: "Select an platform",
+                            contentPadding: EdgeInsets.all(0.0)),
+                        onChanged: (item) {
+                          setState(() => this.selectedPlatform = item);
+                        },
+                        key: platformKey,
+                        value: selectedPlatform,
+                        items: platforms
+                            .map((e) => DropdownMenuItem<String>(
+                                  child: Container(
+                                    child: Text(e),
+                                    width: 100,
+                                  ),
+                                  value: e,
+                                ))
+                            .toList(),
+                      ),
+                    )),
                 TextButton.icon(
-                    onPressed: () => onApplyConsultation(context),
-                    icon: Icon(Icons.add),
-                    label: Text("Apply")),
+                    style: ButtonStyle(
+                        backgroundColor:
+                            MaterialStateProperty.all(Colors.lightBlueAccent)),
+                    onPressed: () => onBuild(context),
+                    icon: Icon(Icons.rule_rounded),
+                    label: Text(
+                      "Build",
+                      style: TextStyle(color: Colors.white),
+                    )),
               ],
             ),
-            Padding(
-                padding: const EdgeInsets.all(8.0),
-                child: DropdownButtonFormField<String>(
-                  key: typeKey,
-                  value: selectedType,
-                  decoration: InputDecoration(hintText: "Select one state"),
-                  items: items
-                      .map((e) => DropdownMenuItem<String>(
-                            child: Text(e),
-                            value: e,
-                          ))
-                      .toList(),
-                  onChanged: (value) {
-                    selectedType = value;
-                  },
-                )),
             Row(
               children: [
                 TextButton.icon(
@@ -69,7 +80,7 @@ class _BuildView extends State<BuildView> {
             ),
             Expanded(
                 child: Center(
-              child: FutureBuilder<List<Consultation>>(
+              child: FutureBuilder<List<BuildHistory>>(
                 key: listKey,
                 future: future,
                 builder: (context, snapshot) {
@@ -78,8 +89,8 @@ class _BuildView extends State<BuildView> {
                       child: Text('An error has occurred!'),
                     );
                   } else if (snapshot.hasData) {
-                    return ConsultationList(
-                        token: "accessToken", consultations: snapshot.data!);
+                    return BuildHistoryList(
+                        token: "accessToken", histories: snapshot.data!);
                   } else {
                     return const Center(
                       child: CircularProgressIndicator(),
@@ -94,60 +105,23 @@ class _BuildView extends State<BuildView> {
     );
   }
 
-  Future<List<Consultation>> fetchConsultations(int? selectedType) async {
+  Future<List<BuildHistory>> fetchBuildHistories() async {
     try {
-      var service = GetIt.instance.get<ConsultationService>();
+      var service = GetIt.instance.get<BuildService>();
 
-      var list = await service.FindConsultationsByPageAsync('id', selectedType);
-      return list;
+      return List.empty();
     } catch (ex) {
-      print('QueryExam.to ex' + ex.toString());
+      Logger.error('fetchBuildHistories ex:' + ex.toString());
       return List.empty();
     }
   }
 
-  void onApplyConsultation(context) {
-    print("onApplyConsultation click");
-    Navigator.of(context).pushNamed('/applyconsultation');
-  }
-}
-
-class ConnectionNotification {
-  NotificationTypeEnum notificationType;
-  ConnectionNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory ConnectionNotification.fromJson(Map<String, dynamic> map) {
-    return ConnectionNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class DisconnectNotification {
-  NotificationTypeEnum notificationType;
-  DisconnectNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory DisconnectNotification.fromJson(Map<String, dynamic> map) {
-    return DisconnectNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class FinishNotifyRecordsMessage {
-  NotificationTypeEnum notificationType;
-  List<String>? codes;
-  FinishNotifyRecordsMessage(
-      {this.notificationType = NotificationTypeEnum.Unknown, this.codes});
-  factory FinishNotifyRecordsMessage.fromJson(Map<String, dynamic> map) {
-    return FinishNotifyRecordsMessage(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-      codes: map['Codes'] != null ? map['Codes'].cast<String>().toList() : null,
-    );
+  void onBuild(context) {
+    try {
+      var service = GetIt.instance.get<BuildService>();
+      service.Run();
+    } catch (ex) {
+      Logger.error("onBuild ex:${ex}");
+    }
   }
 }

+ 0 - 291
Tools/Flyinsono.Deployment/lib/ConsultationList.dart

@@ -1,291 +0,0 @@
-import 'package:flutter/material.dart';
-import 'package:get_it/get_it.dart';
-import 'package:ustest/Services/NotificationReceivedArgs.dart';
-import 'package:ustest/Services/UserService.dart';
-import 'package:ustest/tool.dart';
-import 'Services/ConsultationService.dart';
-
-class ConsultationList extends StatefulWidget {
-  ConsultationList({Key? key, required this.token, required this.consultations})
-      : super();
-  final String token;
-  final List<Consultation> consultations;
-
-  @override
-  _ConsultationListState createState() => _ConsultationListState();
-}
-
-class _ConsultationListState extends State<ConsultationList> {
-  @override
-  void initState() {
-    var service = GetIt.instance.get<UserService>();
-    service.NotificationReceived.subscribe((args) {
-      if (args == null) {
-        return;
-      }
-      NotificationTypeEnum type = args.type;
-      switch (type) {
-        case NotificationTypeEnum.InviteLiveConsultationNotification:
-          var code = args.jsonMessage['ConsultationCode'];
-          showConfirmDialog(context, "xxx请求会诊,要接吗?", () {
-            OnAcceptLiveConsultation(code);
-          }, () {
-            OnRejectLiveConsultation(code);
-          });
-          break;
-        default:
-        //TDOO
-      }
-    });
-    super.initState();
-  }
-
-  @override
-  void dispose() {
-    var service = GetIt.instance.get<UserService>();
-    service.NotificationReceived.unsubscribe((args) {});
-    super.dispose();
-  }
-
-  void showConfirmDialog(BuildContext context, String content,
-      Function confirmCallback, Function rejectCallback) {
-    showDialog(
-        context: context,
-        builder: (context) {
-          return new AlertDialog(
-            title: new Text("提示"),
-            content: new Text(content),
-            actions: <Widget>[
-              new TextButton(
-                onPressed: () {
-                  confirmCallback();
-                  Navigator.of(context).pop();
-                },
-                child: new Text("接受"),
-              ),
-              new TextButton(
-                onPressed: () {
-                  Navigator.of(context).pop();
-                },
-                child: new Text("拒絕"),
-              ),
-            ],
-          );
-        });
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return Scaffold(
-        body: Container(
-      height: 600,
-      child: Row(
-        children: [
-          Container(
-            height: 500,
-            width: 400,
-            child: ListView(
-              restorationId: 'list_demo_list_view',
-              padding: const EdgeInsets.symmetric(vertical: 0),
-              children: [
-                for (int index = 0;
-                    index < widget.consultations.length;
-                    index++)
-                  Row(
-                    children: [
-                      Expanded(
-                          child: Container(
-                        child: ListTile(
-                          leading: ExcludeSemantics(
-                            child: Icon(Icons.person),
-                          ),
-                          title: Text(widget.consultations[index].id +
-                              " - " +
-                              widget.consultations[index].expertUserCode),
-                          subtitle: Text(
-                              widget.consultations[index].patientName +
-                                  getStatusDesc(widget.consultations[index]
-                                      .consultationStatus)),
-                          onTap: (() =>
-                              onTabPatient(widget.consultations[index].id)),
-                        ),
-                      )),
-                      Row(
-                        children: [
-                          Offstage(
-                              offstage: widget.consultations[index]
-                                      .consultationStatus !=
-                                  1,
-                              child: TextButton.icon(
-                                  onPressed: () => onApprovalConsultation(
-                                      context, widget.consultations[index]),
-                                  icon: Icon(Icons.update),
-                                  label: Text("批准")))
-                        ],
-                      ),
-                      Container(
-                          alignment: Alignment.topRight,
-                          child: Container(
-                            child: Column(
-                              children: [
-                                ClipRRect(
-                                    borderRadius: BorderRadius.circular(2),
-                                    child: Container(
-                                        color: Colors.amber[50],
-                                        child: Row(children: [
-                                          Icon(
-                                            Icons.star,
-                                            color: Colors.amber[500],
-                                            size: 12,
-                                          ),
-                                          Text(
-                                            "5.0",
-                                            style: TextStyle(
-                                                color: Colors.amber[900],
-                                                fontSize: 9),
-                                          ),
-                                        ]))),
-                                Container(
-                                    child: Row(
-                                  children: [
-                                    TextButton(
-                                        child: Text("Start"),
-                                        onPressed: (() =>
-                                            OnStartLiveConsultation(widget
-                                                .consultations[index].id))),
-                                    TextButton(
-                                        child: Text("Cancel"),
-                                        onPressed: (() =>
-                                            OnCancelLiveConsultation(widget
-                                                .consultations[index].id)))
-                                  ],
-                                ))
-                              ],
-                            ),
-                          )),
-                    ],
-                  ),
-              ],
-            ),
-          ),
-        ],
-      ),
-    ));
-  }
-
-  void onTabPatient(String id) async {}
-
-  void OnStartLiveConsultation(id) async {
-    try {
-      var service = GetIt.instance.get<ConsultationService>();
-
-      Navigator.of(context).pushNamed('/meeting');
-    } catch (ex) {
-      print('OnStartLiveConsultation.to ex:$ex');
-      MeetingTool.toast(ex.toString(), context);
-    }
-  }
-
-  void OnCancelLiveConsultation(String id) async {
-    try {
-      var service = GetIt.instance.get<ConsultationService>();
-      var result = await service.CancelLiveConsultationAsync(id);
-    } catch (ex) {
-      print('OnCancelLiveConsultation.to ex:$ex');
-      MeetingTool.toast(ex.toString(), context);
-    }
-  }
-
-  void OnAcceptLiveConsultation(id) async {
-    try {
-      var service = GetIt.instance.get<ConsultationService>();
-
-      Navigator.of(context).pushNamed('/meeting');
-    } catch (ex) {
-      print('OnAcceptLiveConsultation.to ex' + ex.toString());
-    }
-  }
-
-  void OnRejectLiveConsultation(id) async {
-    try {
-      var service = GetIt.instance.get<ConsultationService>();
-
-      var result = await service.RejectLiveConsultationAsync(id);
-      print("RejectLiveConsultationAsync");
-    } catch (ex) {
-      print('OnRejectLiveConsultation.to ex' + ex.toString());
-    }
-  }
-
-  String getStatusDesc(status) {
-    if (status == 1) {
-      return "已申请";
-    } else if (status == 2) {
-      return "已撤回";
-    } else if (status == 3) {
-      return "已拒绝";
-    } else if (status == 4) {
-      return "待开始(即申请已同意)";
-    } else if (status == 5) {
-      return "进行中";
-    } else if (status == 6) {
-      return "待报告";
-    } else if (status == 7) {
-      return "已结束(即会诊报告已提交)";
-    }
-    return "";
-  }
-
-  void onApprovalConsultation(context, Consultation model) {
-    print("onApprovalConsultation click");
-    //Navigator.of(context).pushNamed('/approvalconsultation',arguments: model);
-
-    //Navigator.push(
-    //context,
-    //MaterialPageRoute(
-    //builder: (context) => ApprovalConsultationScreen(model: model)));
-  }
-}
-
-class Consultation {
-  final String id;
-  final String patientName;
-  final int consultationStatus;
-  final String expertUserCode;
-  final String applyUserCode;
-
-  Consultation(
-      {required this.id,
-      required this.patientName,
-      required this.consultationStatus,
-      required this.expertUserCode,
-      required this.applyUserCode});
-
-  factory Consultation.fromJson(Map<String, dynamic> json) {
-    var item = Consultation(
-        id: json['ConsultationCode'] as String,
-        //expertUserCode: json['ExpertUserCode'] as String,
-        //applyUserCode: json['ApplyUserCode'] as String,
-        //patientName: json['PatientName'] as String,
-        //consultationStatus: json['ConsultationStatus'] as int);
-        expertUserCode: '',
-        applyUserCode: '',
-        patientName: '',
-        consultationStatus: json['ConsultationStatus']);
-
-    return item;
-  }
-
-  Map<String, dynamic> toMap() {
-    return {
-      'ConsultationCode': id,
-      'PatientName': patientName,
-      'ExpertUserCode': expertUserCode,
-    };
-  }
-
-  @override
-  String toString() {
-    return 'Patient{id: $id}';
-  }
-}

+ 7 - 7
Tools/Flyinsono.Deployment/lib/MainScreen.dart

@@ -82,14 +82,14 @@ class _MainScreenState extends State<MainScreen> with RestorationMixin {
                 _selectedIndex.value = index;
               });
             },
-            labelType: NavigationRailLabelType.selected,
+            labelType: NavigationRailLabelType.all,
             destinations: [
               NavigationRailDestination(
                 icon: const Icon(
-                  Icons.list_outlined,
+                  Icons.build_outlined,
                 ),
                 selectedIcon: const Icon(
-                  Icons.list_alt_rounded,
+                  Icons.build_rounded,
                 ),
                 label: Text(
                   AppLocalizations.of(context)!.build,
@@ -97,10 +97,10 @@ class _MainScreenState extends State<MainScreen> with RestorationMixin {
               ),
               NavigationRailDestination(
                 icon: const Icon(
-                  Icons.list_outlined,
+                  Icons.badge_outlined,
                 ),
                 selectedIcon: const Icon(
-                  Icons.list_alt_rounded,
+                  Icons.badge_rounded,
                 ),
                 label: Text(
                   AppLocalizations.of(context)!.package,
@@ -108,10 +108,10 @@ class _MainScreenState extends State<MainScreen> with RestorationMixin {
               ),
               NavigationRailDestination(
                 icon: const Icon(
-                  Icons.list_outlined,
+                  Icons.publish_outlined,
                 ),
                 selectedIcon: const Icon(
-                  Icons.list_alt_rounded,
+                  Icons.publish_rounded,
                 ),
                 label: Text(
                   AppLocalizations.of(context)!.publish,

+ 4 - 76
Tools/Flyinsono.Deployment/lib/PackageView.dart

@@ -1,9 +1,9 @@
 import 'package:autocomplete_textfield/autocomplete_textfield.dart';
 import 'package:flutter/material.dart';
 import 'package:get_it/get_it.dart';
-import 'package:ustest/ConsultationList.dart';
+import 'package:ustest/BuildHistoryList.dart';
 
-import 'Services/ConsultationService.dart';
+import 'Services/BuildService.dart';
 import 'Services/NotificationReceivedArgs.dart';
 
 class PackageView extends StatefulWidget {
@@ -28,7 +28,7 @@ class _PackageView extends State<PackageView> {
     } else {
       selectedState = 2;
     }
-    Future<List<Consultation>> future = fetchConsultations(selectedState);
+
     GlobalKey<AutoCompleteTextFieldState<String>> typeKey = GlobalKey();
     GlobalKey listKey = GlobalKey();
     return Scaffold(
@@ -67,87 +67,15 @@ class _PackageView extends State<PackageView> {
                     label: Text("Search")),
               ],
             ),
-            Expanded(
-                child: Center(
-              child: FutureBuilder<List<Consultation>>(
-                key: listKey,
-                future: future,
-                builder: (context, snapshot) {
-                  if (snapshot.hasError) {
-                    return const Center(
-                      child: Text('An error has occurred!'),
-                    );
-                  } else if (snapshot.hasData) {
-                    return ConsultationList(
-                        token: "accessToken", consultations: snapshot.data!);
-                  } else {
-                    return const Center(
-                      child: CircularProgressIndicator(),
-                    );
-                  }
-                },
-              ),
-            )),
+            Expanded(child: Center()),
           ],
         ),
       ),
     );
   }
 
-  Future<List<Consultation>> fetchConsultations(int? selectedType) async {
-    try {
-      var service = GetIt.instance.get<ConsultationService>();
-
-      var list = await service.FindConsultationsByPageAsync('id', selectedType);
-      return list;
-    } catch (ex) {
-      print('QueryExam.to ex' + ex.toString());
-      return List.empty();
-    }
-  }
-
   void onApplyConsultation(context) {
     print("onApplyConsultation click");
     Navigator.of(context).pushNamed('/applyconsultation');
   }
 }
-
-class ConnectionNotification {
-  NotificationTypeEnum notificationType;
-  ConnectionNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory ConnectionNotification.fromJson(Map<String, dynamic> map) {
-    return ConnectionNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class DisconnectNotification {
-  NotificationTypeEnum notificationType;
-  DisconnectNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory DisconnectNotification.fromJson(Map<String, dynamic> map) {
-    return DisconnectNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class FinishNotifyRecordsMessage {
-  NotificationTypeEnum notificationType;
-  List<String>? codes;
-  FinishNotifyRecordsMessage(
-      {this.notificationType = NotificationTypeEnum.Unknown, this.codes});
-  factory FinishNotifyRecordsMessage.fromJson(Map<String, dynamic> map) {
-    return FinishNotifyRecordsMessage(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-      codes: map['Codes'] != null ? map['Codes'].cast<String>().toList() : null,
-    );
-  }
-}

+ 4 - 76
Tools/Flyinsono.Deployment/lib/PublishView.dart

@@ -1,9 +1,9 @@
 import 'package:autocomplete_textfield/autocomplete_textfield.dart';
 import 'package:flutter/material.dart';
 import 'package:get_it/get_it.dart';
-import 'package:ustest/ConsultationList.dart';
+import 'package:ustest/BuildHistoryList.dart';
 
-import 'Services/ConsultationService.dart';
+import 'Services/BuildService.dart';
 import 'Services/NotificationReceivedArgs.dart';
 
 class PublishView extends StatefulWidget {
@@ -28,7 +28,7 @@ class _PublishView extends State<PublishView> {
     } else {
       selectedState = 2;
     }
-    Future<List<Consultation>> future = fetchConsultations(selectedState);
+
     GlobalKey<AutoCompleteTextFieldState<String>> typeKey = GlobalKey();
     GlobalKey listKey = GlobalKey();
     return Scaffold(
@@ -67,87 +67,15 @@ class _PublishView extends State<PublishView> {
                     label: Text("Search")),
               ],
             ),
-            Expanded(
-                child: Center(
-              child: FutureBuilder<List<Consultation>>(
-                key: listKey,
-                future: future,
-                builder: (context, snapshot) {
-                  if (snapshot.hasError) {
-                    return const Center(
-                      child: Text('An error has occurred!'),
-                    );
-                  } else if (snapshot.hasData) {
-                    return ConsultationList(
-                        token: "accessToken", consultations: snapshot.data!);
-                  } else {
-                    return const Center(
-                      child: CircularProgressIndicator(),
-                    );
-                  }
-                },
-              ),
-            )),
+            Expanded(child: Center()),
           ],
         ),
       ),
     );
   }
 
-  Future<List<Consultation>> fetchConsultations(int? selectedType) async {
-    try {
-      var service = GetIt.instance.get<ConsultationService>();
-
-      var list = await service.FindConsultationsByPageAsync('id', selectedType);
-      return list;
-    } catch (ex) {
-      print('QueryExam.to ex' + ex.toString());
-      return List.empty();
-    }
-  }
-
   void onApplyConsultation(context) {
     print("onApplyConsultation click");
     Navigator.of(context).pushNamed('/applyconsultation');
   }
 }
-
-class ConnectionNotification {
-  NotificationTypeEnum notificationType;
-  ConnectionNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory ConnectionNotification.fromJson(Map<String, dynamic> map) {
-    return ConnectionNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class DisconnectNotification {
-  NotificationTypeEnum notificationType;
-  DisconnectNotification({
-    this.notificationType = NotificationTypeEnum.Unknown,
-  });
-  factory DisconnectNotification.fromJson(Map<String, dynamic> map) {
-    return DisconnectNotification(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-    );
-  }
-}
-
-class FinishNotifyRecordsMessage {
-  NotificationTypeEnum notificationType;
-  List<String>? codes;
-  FinishNotifyRecordsMessage(
-      {this.notificationType = NotificationTypeEnum.Unknown, this.codes});
-  factory FinishNotifyRecordsMessage.fromJson(Map<String, dynamic> map) {
-    return FinishNotifyRecordsMessage(
-      notificationType: NotificationTypeEnum.values
-          .firstWhere((e) => e.index == map['NotificationType']),
-      codes: map['Codes'] != null ? map['Codes'].cast<String>().toList() : null,
-    );
-  }
-}

+ 1 - 0
Tools/Flyinsono.Deployment/lib/Services/AutoTestService.dart

@@ -0,0 +1 @@
+class AutoTestService {}

+ 70 - 0
Tools/Flyinsono.Deployment/lib/Services/BuildService.dart

@@ -0,0 +1,70 @@
+import 'dart:convert';
+import 'package:colorize_logger/colorize_logger.dart';
+import 'package:get_it/get_it.dart';
+import 'dart:typed_data';
+
+import 'UserService.dart';
+
+class BuildService {
+  Future<BuildHistory> LoadDataAsync() async {
+    var userService = GetIt.instance.get<UserService>();
+    final user = await userService.getCurrentUser();
+    final token = user?.accessToken;
+
+    dynamic datas = []; //TODO
+    var list =
+        datas.map<BuildHistory>((json) => BuildHistory.fromJson(json)).toList();
+    return list;
+  }
+
+  decodeResponseBody(String logTag, Uint8List bodyBytes) {
+    var utfString = utf8.decode(bodyBytes);
+    Logger.info('$logTag response.body' + utfString);
+    final parsed = jsonDecode(utfString);
+    return parsed;
+  }
+}
+
+class BuildHistory {
+  final String id;
+  final String platform;
+  final DateTime createTime;
+  final String userName;
+  BuildHistory(
+      {required this.id,
+      required this.platform,
+      required this.createTime,
+      required this.userName});
+  factory BuildHistory.fromJson(Map<String, dynamic> json) {
+    return BuildHistory(
+      id: json['id'] as String,
+      platform: json['platform'] as String,
+      createTime: json['createTime'] as DateTime,
+      userName: json['userName'] as String,
+    );
+  }
+  Map<String, dynamic> toJson() => {
+        "id": id,
+        "userName": userName,
+        "platform": platform,
+        "createTime": createTime
+      };
+}
+
+class Platform {
+  final String id;
+  final String name;
+
+  Platform({required this.id, required this.name});
+  factory Platform.fromJson(Map<String, dynamic> json) {
+    return Platform(
+      id: json['id'] as String,
+      name: json['name'] as String,
+    );
+  }
+
+  Map<String, dynamic> toJson() => {
+        "id": id,
+        "name": name,
+      };
+}

+ 0 - 382
Tools/Flyinsono.Deployment/lib/Services/ConsultationService.dart

@@ -1,382 +0,0 @@
-import 'dart:convert';
-import 'package:colorize_logger/colorize_logger.dart';
-import 'package:get_it/get_it.dart';
-import 'package:http/http.dart' as http;
-import 'package:ustest/ConsultationList.dart';
-import 'dart:typed_data';
-
-import 'AppSettings.dart';
-import 'UserService.dart';
-import 'package:intl/intl.dart';
-
-class ConsultationService {
-  Future<AppConsultationDataModel> LoadDataAsync() async {
-    var userService = GetIt.instance.get<UserService>();
-    final user = await userService.getCurrentUser();
-    final token = user?.accessToken;
-    final orgCode = user?.organizationCode;
-
-    var client = http.Client();
-
-    var body =
-        '{"jsonrpc": "2.0", "method": "GetPersonDeviceDropdownListAsync", "params": [{"Token": "$token"}], "id": 1 }';
-    Logger.info('QueryExam http.Client()' + body);
-    var response = await client
-        .post(Uri.parse(AppSettings.host + '/IDeviceService'), body: body);
-
-    var parsed = decodeResponseBody(
-        'GetPersonDeviceDropdownListAsync', response.bodyBytes);
-    var datas = parsed['result'];
-    final devices = datas.map<Device>((json) => Device.fromJson(json)).toList();
-
-    body =
-        '{"jsonrpc": "2.0", "method": "FindOrganizationExpertsAsync", "params": [{"Token": "$token", "OrganizationCode": "$orgCode"}], "id": 1 }';
-    Logger.info('QueryExam http.Client()' + body);
-    response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-
-    //final response = await post(client, "ILiveConsultationService",
-    //    "FindOrganizationExpertsAsync", args);
-    Logger.info('FindOrganizationExpertsAsync response.body' + response.body);
-    parsed = jsonDecode(response.body);
-    datas = parsed['result'];
-    final experts = datas.map<Expert>((json) => Expert.fromJson(json)).toList()
-        as List<Expert>;
-
-    body =
-        '{"jsonrpc": "2.0", "method": "FindScanPositionsAsync", "params": [{"Token": "$token"}], "id": 1 }';
-    Logger.info('FindScanPositionsAsync http.Client()' + body);
-    response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-    parsed = decodeResponseBody('FindScanPositionsAsync', response.bodyBytes);
-    //var data = jsonDecode(parsed['result']);
-    var organSource = parsed['result'];
-
-    var organs = organSource.map<String>((json) => json.toString()).toList()
-        as List<String>;
-
-    body =
-        '{"jsonrpc": "2.0", "method": "GetUserListAsync", "params": [{"Token": "$token", "OrganizationCode": "$orgCode","OrganizationQueryType":3,"ExceptSelf":true}], "id": 1 }';
-    Logger.info('GetUserListAsync http.Client()' + body);
-    response = await client.post(Uri.parse(AppSettings.host + '/IUserService'),
-        body: body);
-
-    Logger.info('GetUserListAsync response.body' + response.body);
-    parsed = jsonDecode(response.body);
-    datas = parsed['result'];
-    final users = datas.map<Expert>((json) => Expert.fromJson(json)).toList()
-        as List<Expert>;
-
-    var model = new AppConsultationDataModel(experts, devices, organs, users);
-    return model;
-  }
-
-  decodeResponseBody(String logTag, Uint8List bodyBytes) {
-    var utfString = utf8.decode(bodyBytes);
-    Logger.info('$logTag response.body' + utfString);
-    final parsed = jsonDecode(utfString);
-    return parsed;
-  }
-
-  Future<List<Consultation>> FindConsultationsByPageAsync(
-      String id, int? selectedType) async {
-    try {
-      var userService = GetIt.instance.get<UserService>();
-      var user = await userService.getCurrentUser();
-      if (user == null) {
-        return List.empty();
-      }
-      var token = user?.accessToken;
-      var client = http.Client();
-
-      var body =
-          '{"jsonrpc": "2.0", "method": "FindConsultationsByPageAsync", "params": [{"Token": "$token",  "PageIndex": 1, "PageSize": 10,"ConsultationQueryType": $selectedType}], "id": 1 }';
-      Logger.info('GetRecordInfoPagesAsync http.Client()' + body);
-      final response = await client.post(
-          Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-          body: body);
-      Logger.info('FindConsultationsByPageAsync response.body' + response.body);
-      final parsed = jsonDecode(response.body);
-      var datas = parsed['result']['PageData'];
-      var list = datas
-          .map<Consultation>((json) => Consultation.fromJson(json))
-          .toList();
-      return list;
-    } catch (ex) {
-      Logger.info('FindConsultationsByPageAsync.to ex' + ex.toString());
-    }
-
-    return List.empty();
-  }
-
-  Future<bool> ApplyConsultationAsync(
-      String expertCode, String deviceCode, String organ, DateTime time) async {
-    var userService = GetIt.instance.get<UserService>();
-    var user = await userService.getCurrentUser();
-    var token = user?.accessToken;
-    var client = http.Client();
-    var patientCode = "2D6DA689ECC54F52A17F20A05BDF5C27"; //TODO should from UI
-    var organizationCode = "Organization_20221020115006aAjF6l";
-    DateFormat inputFormat = DateFormat("yyyy-MM-ddTHH:mm:ss");
-    var utcTime = inputFormat.format(time.toUtc()).toString();
-    var body =
-        '{"jsonrpc": "2.0", "method": "FindPatientByCodeAsync", "params": [{"Token": "$token", "Code":"$patientCode"}], "id": 1 }';
-    Logger.info('FindPatientByCodeAsync http.Client()' + body);
-    var response = await client
-        .post(Uri.parse(AppSettings.host + '/IPatientService'), body: body);
-    var parsed =
-        decodeResponseBody('FindPatientByCodeAsync', response.bodyBytes);
-    var data = parsed['result']['PatientData'];
-    var list =
-        data.map<DataItemDTO>((json) => DataItemDTO.fromJson(json)).toList();
-    var patientDatas = jsonEncode(list);
-    body =
-        '{"jsonrpc": "2.0", "method": "ApplyConsultationAsync", "params": [{"Token": "$token","ApplyUserCode":"3C135B470E6448F6854974D46022F7FD", "PatientCode":"$patientCode", "ExpertOrganizationCode":"$organizationCode", "PatientDatas":$patientDatas, "ExpertUserCode": "$expertCode", "DeviceCode": "$deviceCode", "ScanPosition": "$organ", "ConsultationTime":"$utcTime"}], "id": 1 }';
-    Logger.info('ApplyConsultationAsync http.Client()' + body);
-    response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-    parsed = decodeResponseBody('ApplyConsultationAsync', response.bodyBytes);
-
-    return true;
-  }
-
-  Future<dynamic> InitiateLiveConsultationAsync(String consultationCode) async {
-    var userService = GetIt.instance.get<UserService>();
-    var user = await userService.getCurrentUser();
-    var token = user?.accessToken;
-    var client = http.Client();
-
-    var body =
-        '{"jsonrpc": "2.0", "method": "InitiateLiveConsultationAsync", "params": [{"Token": "$token", "ConsultationCode":"$consultationCode"}], "id": 1 }';
-    print('InitiateLiveConsultationAsync http.Client()' + body);
-    final response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-    var parsed =
-        decodeResponseBody('InitiateLiveConsultationAsync', response.bodyBytes);
-    var data = parsed['result'];
-
-    return data;
-  }
-
-  Future<dynamic> CancelLiveConsultationAsync(String consultationCode) async {
-    var userService = GetIt.instance.get<UserService>();
-    var user = await userService.getCurrentUser();
-    var token = user?.accessToken;
-    var client = http.Client();
-
-    var body =
-        '{"jsonrpc": "2.0", "method": "CancelLiveConsultationAsync", "params": [{"Token": "$token", "ConsultationCode":"$consultationCode"}], "id": 1 }';
-    print('CancelLiveConsultationAsync http.Client()' + body);
-    final response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-    var parsed =
-        decodeResponseBody('CancelLiveConsultationAsync', response.bodyBytes);
-    var data = parsed['result'];
-
-    return data;
-  }
-
-  Future<dynamic> AcceptLiveConsultationAsync(String consultationCode) async {
-    var userService = GetIt.instance.get<UserService>();
-    var user = await userService.getCurrentUser();
-    var token = user?.accessToken;
-    var client = http.Client();
-
-    var body =
-        '{"jsonrpc": "2.0", "method": "AcceptLiveConsultationAsync", "params": [{"Token": "$token", "ConsultationCode":"$consultationCode"}], "id": 1 }';
-    Logger.info('AcceptLiveConsultationAsync http.Client()' + body);
-    final response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-    var parsed =
-        decodeResponseBody('AcceptLiveConsultationAsync', response.bodyBytes);
-    var data = parsed['result'];
-    return data;
-  }
-
-  Future<dynamic> RejectLiveConsultationAsync(String consultationCode) async {
-    var userService = GetIt.instance.get<UserService>();
-    var user = await userService.getCurrentUser();
-    var token = user?.accessToken;
-    var client = http.Client();
-
-    var body =
-        '{"jsonrpc": "2.0", "method": "RejectLiveConsultationAsync", "params": [{"Token": "$token", "ConsultationCode":"$consultationCode"}], "id": 1 }';
-    Logger.info('RejectLiveConsultationAsync http.Client()' + body);
-    final response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-    var parsed =
-        decodeResponseBody('RejectLiveConsultationAsync', response.bodyBytes);
-    var data = parsed['result'];
-    return data;
-  }
-
-  Future<bool> ApprovalConsultationAsync(
-      ApprovalConsultationRequest model) async {
-    String consultationCode = model.consultationCode;
-    String expertUserCode = model.expertUserCode;
-    DateTime consultationTime = model.consultationTime;
-    List<String> consultationMemberCodes = <String>[];
-    model.consultationMemberCodes.forEach((element) {
-      consultationMemberCodes.add('"' + element + '"');
-    });
-    var userService = GetIt.instance.get<UserService>();
-    var user = await userService.getCurrentUser();
-    var token = user?.accessToken;
-    var client = http.Client();
-    DateFormat inputFormat = DateFormat("yyyy-MM-ddTHH:mm:ss");
-    var utcTime = inputFormat.format(consultationTime.toUtc()).toString();
-    var utcEndTime = inputFormat
-        .format(consultationTime.add(const Duration(hours: 2)).toUtc())
-        .toString();
-    var body =
-        '{"jsonrpc": "2.0", "method": "ApprovalConsultationAsync", "params": [{"Token": "$token","ConsultationCode":"$consultationCode", "ExpertUserCode":"$expertUserCode", "ConsultationTime":"$utcTime", "ConsultationTimeEnd":"$utcEndTime","ConsultationMemberCodes":$consultationMemberCodes }], "id": 1 }';
-    Logger.info('ApprovalConsultationAsync http.Client()' + body);
-    var response = await client.post(
-        Uri.parse(AppSettings.host + '/ILiveConsultationService'),
-        body: body);
-    var parsed =
-        decodeResponseBody('ApprovalConsultationAsync', response.bodyBytes);
-    var data = parsed['result'];
-    return data;
-  }
-}
-
-class AppConsultationDataModel {
-  final List<Expert> experts;
-  final List<Device> devices;
-  final List<String> organs;
-  final List<Expert> users;
-
-  AppConsultationDataModel(this.experts, this.devices, this.organs, this.users);
-}
-
-class TokenRequest {
-  String token;
-  TokenRequest(this.token);
-}
-
-class DataItemDTO {
-  final String key;
-  final String value;
-  DataItemDTO({required this.key, required this.value});
-
-  factory DataItemDTO.fromJson(Map<String, dynamic> json) {
-    return DataItemDTO(
-      key: json['Key'] as String,
-      value: json['Value'] as String,
-    );
-  }
-
-  Map<String, dynamic> toJson() => {
-        "Key": key,
-        "Value": value,
-      };
-}
-
-class ApplyConsultationRequest extends TokenRequest {
-  String expertUserCode;
-
-  String deviceCode;
-
-  String scanPosition;
-
-  DateTime consultationTime;
-
-  List<DataItemDTO> patientDatas;
-
-  String patientCode;
-
-  ApplyConsultationRequest(
-      this.expertUserCode,
-      this.deviceCode,
-      this.scanPosition,
-      this.consultationTime,
-      this.patientDatas,
-      this.patientCode,
-      String token)
-      : super(token);
-}
-
-class Expert {
-  final String code;
-  final String userName;
-
-  Expert({required this.code, required this.userName});
-  @override
-  bool operator ==(Object other) => other is Expert && other.code == code;
-  factory Expert.fromJson(Map<String, dynamic> json) {
-    return Expert(
-      code: json['UserCode'] as String,
-      userName: json['UserName'] as String,
-    );
-  }
-
-  Map<String, dynamic> toJson() => {
-        "UserCode": code,
-        "UserName": userName,
-      };
-}
-
-class Device {
-  final String code;
-  final String deviceName;
-
-  Device({required this.code, required this.deviceName});
-  bool operator ==(Object other) => other is Device && other.code == code;
-  factory Device.fromJson(Map<String, dynamic> json) {
-    return Device(
-      code: json['Key'] as String,
-      deviceName: json['Value'] as String,
-    );
-  }
-
-  Map<String, dynamic> toJson() => {
-        "Key": code,
-        "Value": deviceName,
-      };
-}
-
-class Organ {
-  final String code;
-  final String orgName;
-
-  Organ({required this.code, required this.orgName});
-  factory Organ.fromJson(Map<String, dynamic> json) {
-    return Organ(
-      code: json['Key'] as String,
-      orgName: json['Value'] as String,
-    );
-  }
-
-  Map<String, dynamic> toJson() => {
-        "Key": code,
-        "Value": orgName,
-      };
-}
-
-class ApprovalConsultationRequest extends TokenRequest {
-  String consultationCode;
-
-  String expertUserCode;
-
-  DateTime consultationTime;
-
-  List<String> consultationMemberCodes;
-
-  ApprovalConsultationRequest(this.consultationCode, this.expertUserCode,
-      this.consultationTime, this.consultationMemberCodes, String token)
-      : super(token);
-
-  @override
-  String toString() {
-    // TODO: implement toString
-    return 'consultationCode: $consultationCode,expertUserCode:$expertUserCode,consultationTime:$consultationTime,consultationMemberCodes:$consultationMemberCodes';
-  }
-}

+ 1 - 0
Tools/Flyinsono.Deployment/lib/Services/PackageService.dart

@@ -0,0 +1 @@
+class PackageService {}

+ 1 - 0
Tools/Flyinsono.Deployment/lib/Services/PublishService.dart

@@ -0,0 +1 @@
+class PublishService {}

+ 8 - 2
Tools/Flyinsono.Deployment/lib/main.dart

@@ -9,7 +9,10 @@ import 'package:ustest/SignInScreen.dart';
 import 'package:ustest/MainScreen.dart';
 import 'package:get_it/get_it.dart';
 import 'package:colorize_logger/colorize_logger.dart';
-import 'Services/ConsultationService.dart';
+import 'Services/AutoTestService.dart';
+import 'Services/BuildService.dart';
+import 'Services/PackageService.dart';
+import 'Services/PublishService.dart';
 import 'Utilities/PlatformUtils.dart';
 import 'package:flutter_gen/gen_l10n/app_localizations.dart';
 
@@ -73,7 +76,10 @@ Future<void> initialize() async {
     getIt.registerSingleton<LocalStorageService>(LocalStorageService(isWeb));
     var userService = new UserService();
     getIt.registerSingleton<UserService>(userService);
-    getIt.registerSingleton<ConsultationService>(ConsultationService());
+    getIt.registerSingleton<BuildService>(new BuildService());
+    getIt.registerSingleton<PackageService>(new PackageService());
+    getIt.registerSingleton<PublishService>(new PublishService());
+    getIt.registerSingleton<AutoTestService>(new AutoTestService());
     await userService.UpdateCurrentUserDetail();
     runApp(const MyApp());
   } catch (ex) {