Преглед изворни кода

泰国的OA的Labour Review 和Job List

liukai пре 1 месец
родитељ
комит
41ed0c4322
71 измењених фајлова са 625 додато и 8427 уклоњено
  1. 8 5
      app/ios/Runner/Base.lproj/Main.storyboard
  2. 4 4
      app/ios/Runner/Info.plist
  3. 0 158
      packages/cpt_th/lib/modules/job/applied_staff_detail/applied_staff_detail_controller.dart
  4. 0 139
      packages/cpt_th/lib/modules/job/applied_staff_detail/applied_staff_detail_page.dart
  5. 0 15
      packages/cpt_th/lib/modules/job/applied_staff_detail/applied_staff_detail_state.dart
  6. 0 295
      packages/cpt_th/lib/modules/job/applied_staff_detail/staff_detail_widget.dart
  7. 0 333
      packages/cpt_th/lib/modules/job/applied_staff_detail/staff_labour_history_item.dart
  8. 0 108
      packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_controller.dart
  9. 0 151
      packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_item.dart
  10. 0 162
      packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_page.dart
  11. 0 10
      packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_state.dart
  12. 0 98
      packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_controller.dart
  13. 0 228
      packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_item.dart
  14. 0 102
      packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_page.dart
  15. 0 10
      packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_state.dart
  16. 0 247
      packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_controller.dart
  17. 0 329
      packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_item.dart
  18. 0 173
      packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_page.dart
  19. 0 187
      packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_reject_dialog.dart
  20. 0 12
      packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_state.dart
  21. 0 430
      packages/cpt_th/lib/modules/job/job_applied/applied_staff_item.dart
  22. 0 398
      packages/cpt_th/lib/modules/job/job_applied/job_applied_controller.dart
  23. 0 210
      packages/cpt_th/lib/modules/job/job_applied/job_applied_page.dart
  24. 0 14
      packages/cpt_th/lib/modules/job/job_applied/job_applied_state.dart
  25. 0 178
      packages/cpt_th/lib/modules/job/job_applied_edit/job_applied_edit_controller.dart
  26. 0 515
      packages/cpt_th/lib/modules/job/job_applied_edit/job_applied_edit_page.dart
  27. 0 40
      packages/cpt_th/lib/modules/job/job_applied_edit/job_applied_edit_state.dart
  28. 0 204
      packages/cpt_th/lib/modules/job/job_list/job_list_controller.dart
  29. 0 360
      packages/cpt_th/lib/modules/job/job_list/job_list_filter.dart
  30. 0 210
      packages/cpt_th/lib/modules/job/job_list/job_list_item.dart
  31. 0 143
      packages/cpt_th/lib/modules/job/job_list/job_list_page.dart
  32. 0 18
      packages/cpt_th/lib/modules/job/job_list/job_list_state.dart
  33. 0 42
      packages/cpt_th/lib/modules/job/job_list_detail/job_list_detail_controller.dart
  34. 0 240
      packages/cpt_th/lib/modules/job/job_list_detail/job_list_detail_page.dart
  35. 0 30
      packages/cpt_th/lib/modules/job/job_list_detail/job_list_detail_state.dart
  36. 0 203
      packages/cpt_th/lib/modules/job/sign_in_sign_out/sign_in_sign_out_controller.dart
  37. 0 440
      packages/cpt_th/lib/modules/job/sign_in_sign_out/sign_in_sign_out_page.dart
  38. 0 10
      packages/cpt_th/lib/modules/job/sign_in_sign_out/sign_in_sign_out_state.dart
  39. 0 342
      packages/cpt_th/lib/modules/job/widget/applied_add_staff.dart
  40. 0 131
      packages/cpt_th/lib/modules/job/widget/applied_add_staff_controller.dart
  41. 0 241
      packages/cpt_th/lib/modules/job/widget/applied_butch_modify.dart
  42. 0 313
      packages/cpt_th/lib/modules/job/widget/applied_staff_reviews.dart
  43. 0 160
      packages/cpt_th/lib/modules/job/widget/attendance_sign_in_out.dart
  44. 1 1
      packages/cpt_th/lib/modules/job_er/applied_er_workflow/applied_er_workflow_page.dart
  45. 1 0
      packages/cpt_th/lib/modules/labour/labour_request_add/labour_request_add_controller.dart
  46. 3 2
      packages/cpt_th/lib/modules/labour/labour_request_add/labour_request_add_page.dart
  47. 1 0
      packages/cpt_th/lib/modules/labour/labour_request_add/labour_request_add_state.dart
  48. 19 13
      packages/cpt_th/lib/modules/labour/labour_request_list/labour_request_item.dart
  49. 3 3
      packages/cpt_th/lib/modules/labour/labour_request_list/labour_request_list_controller.dart
  50. 0 196
      packages/cpt_th/lib/modules/labour/labour_review_edit/labour_review_edit_controller.dart
  51. 0 357
      packages/cpt_th/lib/modules/labour/labour_review_edit/labour_review_edit_page.dart
  52. 0 41
      packages/cpt_th/lib/modules/labour/labour_review_edit/labour_review_edit_state.dart
  53. 42 34
      packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_controller.dart
  54. 5 5
      packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_filter.dart
  55. 24 28
      packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_item.dart
  56. 3 3
      packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_page.dart
  57. 2 2
      packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_state.dart
  58. 1 1
      packages/cpt_th/lib/modules/labour/labour_review_workflow/labour_request_workflow_page.dart
  59. 3 3
      packages/cpt_th/lib/modules/labour/labour_review_workflow/labour_review_workflow_controller.dart
  60. 4 4
      packages/cpt_th/lib/modules/labour_er/labour_request_er/labour_request_item.dart
  61. 3 3
      packages/cpt_th/lib/modules/main/main_controller.dart
  62. 1 1
      packages/cpt_th/lib/modules/main/main_item_module.dart
  63. 14 86
      packages/cpt_th/lib/router/th_router.dart
  64. 16 0
      packages/cs_domain/lib/constants/api_constants.dart
  65. 70 0
      packages/cs_domain/lib/entity/response/t_h_o_a_labour_review_table_entity.dart
  66. 9 0
      packages/cs_domain/lib/generated/json/base/json_convert_content.dart
  67. 163 0
      packages/cs_domain/lib/generated/json/t_h_o_a_labour_review_table_entity.g.dart
  68. 150 1
      packages/cs_domain/lib/repository/th_oa_repository.dart
  69. 2 0
      packages/cs_plugin_basic/lib/service/app_config_service.dart
  70. 70 4
      packages/cs_plugin_platform/lib/engine/network/network_engine.dart
  71. 3 1
      packages/cs_router/lib/path/router_path.dart

+ 8 - 5
app/ios/Runner/Base.lproj/Main.storyboard

@@ -1,8 +1,10 @@
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
+<?xml version="1.0" encoding="UTF-8"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="21701" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
+    <device id="retina6_12" orientation="portrait" appearance="light"/>
     <dependencies>
         <deployment identifier="iOS"/>
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
+        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="21679"/>
+        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
     </dependencies>
     <scenes>
         <!--Flutter View Controller-->
@@ -14,13 +16,14 @@
                         <viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/>
                     </layoutGuides>
                     <view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
-                        <rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
+                        <rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
                         <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
-                        <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
+                        <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
                     </view>
                 </viewController>
                 <placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
             </objects>
+            <point key="canvasLocation" x="-26" y="-76"/>
         </scene>
     </scenes>
 </document>

+ 4 - 4
app/ios/Runner/Info.plist

@@ -22,8 +22,6 @@
 	<string>$(MARKETING_VERSION)</string>
 	<key>CFBundleSignature</key>
 	<string>????</string>
-	<key>NSMicrophoneUsageDescription</key>
-	<string>&quot;YY Employers&quot; wants to access your Microphone to sign in or sign out</string>
 	<key>CFBundleURLTypes</key>
 	<array>
 		<dict>
@@ -75,10 +73,12 @@
 	<string>YY Employers needs your location to recommend nearby jobs</string>
 	<key>NSLocationWhenInUseUsageDescription</key>
 	<string>YY Employers needs your location to recommend nearby jobs.</string>
+	<key>NSMicrophoneUsageDescription</key>
+	<string>"YY Employers" wants to access your Microphone to sign in or sign out</string>
 	<key>NSPhotoLibraryAddUsageDescription</key>
-	<string>&quot;YY Employers&quot; wants to access your photos for image upload, image saving and other functions.</string>
+	<string>"YY Employers" wants to access your photos for image upload, image saving and other functions.</string>
 	<key>NSPhotoLibraryUsageDescription</key>
-	<string>&quot;YY Employers&quot; wants to access your photos for image upload, image saving and other functions.</string>
+	<string>"YY Employers" wants to access your photos for image upload, image saving and other functions.</string>
 	<key>NSUserTrackingUsageDescription</key>
 	<string>This identifier will be used to deliver personalized job to you.</string>
 	<key>UIApplicationSupportsIndirectInputEvents</key>

+ 0 - 158
packages/cpt_th/lib/modules/job/applied_staff_detail/applied_staff_detail_controller.dart

@@ -1,158 +0,0 @@
-import 'package:domain/entity/response/staff_detail_entity.dart';
-import 'package:domain/entity/response/staff_labour_history_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/engine/loading/loading_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:plugin_platform/http/http_result.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/widget_export.dart';
-
-import '../applied_staff_reviews/applied_staff_reviews_page.dart';
-import 'applied_staff_detail_state.dart';
-
-class AppliedStaffDetailController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final AppliedStaffDetailState state = AppliedStaffDetailState();
-
-  var _curPage = 1;
-  var _isSearch = false;
-  var _needShowPlaceholder = true;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: true,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    _curPage = 1;
-    fetchStaffDetail();
-  }
-
-  // Refresh 加载事件
-  Future loadMore() async {
-    _curPage++;
-    fetchStaffDetail();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _curPage = 1;
-    _needShowPlaceholder = true;
-    fetchStaffDetail();
-  }
-
-  /// 获取列表数据
-  Future fetchStaffDetail() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    } else if (_isSearch) {
-      LoadingEngine.show();
-    }
-
-    // 并发执行两个请求
-    var futures = [
-      _jobRepository.fetchStaffLabourHistory(
-        state.memberId,
-        state.keyword,
-        curPage: _curPage,
-        cancelToken: cancelToken,
-      ),
-      state.detail == null
-          ? _jobRepository.fetchStaffDetail(state.memberId, cancelToken: cancelToken)
-          : Future(() => HttpResult(isSuccess: true).convert(data: state.detail!)),
-    ];
-
-    //拿到结果
-    var results = await Future.wait(futures);
-    var listResult = results[0] as HttpResult<StaffLabourHistoryEntity>;
-    var detailResult = results[1] as HttpResult<StaffDetailEntity>;
-
-    //详情数据
-    if (state.detail == null && detailResult.isSuccess) {
-      state.detail = detailResult.data!;
-    }
-
-    // 处理数据
-    if (listResult.isSuccess) {
-      handleList(listResult.data?.rows);
-    } else {
-      errorMessage = listResult.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-    }
-
-    _isSearch = false;
-    LoadingEngine.dismiss();
-    // 最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<StaffLabourHistoryRows>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      if (_curPage == 1) {
-        //刷新的方式
-        state.datas.clear();
-        state.datas.addAll(list);
-        refreshController.finishRefresh();
-
-        //更新展示的状态
-        changeLoadingState(LoadState.State_Success);
-      } else {
-        //加载更多
-        state.datas.addAll(list);
-        refreshController.finishLoad();
-        update();
-      }
-    } else {
-      if (_curPage == 1) {
-        //展示无数据的布局
-        state.datas.clear();
-        changeLoadingState(LoadState.State_Empty);
-        refreshController.finishRefresh();
-      } else {
-        //展示加载完成,没有更多数据了
-        refreshController.finishLoad(IndicatorResult.noMore);
-      }
-    }
-  }
-
-  // 执行搜索
-  void doSearch(String keyword) {
-    state.keyword = keyword;
-    //赋值之后刷新
-    // refreshController.callRefresh();
-    _isSearch = true;
-    onRefresh();
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchStaffDetail();
-  }
-
-  @override
-  void onClose() {
-    super.onClose();
-  }
-
-  // 去员工的评论列表页面
-  void gotoRemarkHistoryPage() {
-    AppliedStaffReviewsPage.startInstance(state.memberId,state.detail?.name,state.detail?.remRate,state.detail?.remNum.toString());
-  }
-
-}

+ 0 - 139
packages/cpt_th/lib/modules/job/applied_staff_detail/applied_staff_detail_page.dart

@@ -1,139 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:flutter/material.dart';
-import 'package:get/get.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/search_app_bar.dart';
-import 'package:widgets/widget_export.dart';
-import 'applied_staff_detail_controller.dart';
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/my_appbar.dart';
-
-import 'applied_staff_detail_state.dart';
-import 'staff_detail_widget.dart';
-import 'staff_labour_history_item.dart';
-
-class AppliedStaffDetailPage extends BaseStatefulPage<AppliedStaffDetailController> {
-  AppliedStaffDetailPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance(String? memberId) {
-    return Get.start(RouterPath.jobAppliedStaffDetail, arguments: {'memberId': memberId});
-  }
-
-  @override
-  AppliedStaffDetailController createRawController() {
-    return AppliedStaffDetailController();
-  }
-
-  @override
-  State<AppliedStaffDetailPage> createState() => _AppliedStaffDetailState();
-}
-
-class _AppliedStaffDetailState extends BaseState<AppliedStaffDetailPage, AppliedStaffDetailController> {
-  late AppliedStaffDetailState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-    state.memberId = Get.arguments['memberId'];
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top:ScreenUtil.getStatusBarH(context)),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Column(
-              children: [
-                MyAppBar.titleBar(context, "Staff Detail".tr),
-
-                EasyRefresh(
-                  controller: controller.refreshController,
-                  onRefresh: controller.onRefresh,
-                  onLoad: controller.loadMore,
-                  child: LoadStateLayout(
-                    state: controller.loadingState,
-                    errorMessage: controller.errorMessage,
-                    errorRetry: () {
-                      controller.retryRequest();
-                    },
-                    successSliverWidget: [
-                      //顶部用户信息
-                      SliverToBoxAdapter(
-                        child: StaffDetailWidget(detail: state.detail,onRemarkAction: (){
-                          controller.gotoRemarkHistoryPage();
-                        }),
-                      ),
-
-                      //中间搜索布局
-                      SliverToBoxAdapter(
-                        child: _buildSearchWidget(),
-                      ),
-
-                      //底部工作历史列表
-                      SliverList(
-                          delegate: SliverChildBuilderDelegate(
-                        (context, index) {
-                          return StaffLabourHistoryItem(index: index, item: state.datas[index]);
-                        },
-                        childCount: state.datas.length,
-                      ))
-                    ],
-                  ),
-                ).marginOnly(top: 5,bottom: 5).expanded(),
-              ],
-            ),
-          ),
-        );
-    });
-  }
-
-  // 搜索的布局
-  Widget _buildSearchWidget() {
-    return Column(
-      crossAxisAlignment: CrossAxisAlignment.start,
-      children: [
-        MyTextView(
-          "Job History",
-          marginLeft: 15,
-          marginTop: 10,
-          fontSize: 17,
-          textColor: ColorConstants.white,
-          isFontMedium: true,
-        ),
-        SearchAppBar(
-          value: state.keyword,
-          searchBarHeight: 38,
-          onSearch: (keyword) {
-            controller.doSearch(keyword);
-          },
-          hintText: "Job Title".tr,
-        ).marginOnly(left: 16.5, right: 1.5, bottom: 10, top: 10),
-      ],
-    );
-  }
-}

+ 0 - 15
packages/cpt_th/lib/modules/job/applied_staff_detail/applied_staff_detail_state.dart

@@ -1,15 +0,0 @@
-import 'package:domain/entity/response/staff_detail_entity.dart';
-import 'package:domain/entity/response/staff_labour_history_entity.dart';
-import 'package:flutter/cupertino.dart';
-
-class AppliedStaffDetailState {
-
-  TextEditingController? searchController;
-
-  String? memberId;
-  String keyword = "";
-
-  StaffDetailEntity? detail;
-  List<StaffLabourHistoryRows> datas = [];
-
-}

+ 0 - 295
packages/cpt_th/lib/modules/job/applied_staff_detail/staff_detail_widget.dart

@@ -1,295 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:domain/entity/response/staff_detail_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:plugin_platform/engine/image/image_preview.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-
-/*
- * 员工的信息
- */
-class StaffDetailWidget extends StatelessWidget {
-  final StaffDetailEntity? detail;
-  final void Function() onRemarkAction;
-
-  StaffDetailWidget({
-    required this.detail,
-    required this.onRemarkAction,
-  });
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      margin: const EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 10),
-      decoration: BoxDecoration(
-        color: const Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children: [
-          //头像
-          Center(
-              child: Hero(
-            tag: '112cc8a34e13',
-            child: MyLoadImage(
-              detail?.avatar,
-              width: 100,
-              height: 100,
-            ),
-          )).onTap(() {
-            if (Utils.isNotEmpty(detail?.avatar)) {
-              ImagePreviewEngine.singleImagePreview(context, detail!.avatar!, heroTag: '112cc8a34e13');
-            }
-          }).marginOnly(top: 25, bottom: 15),
-
-          //姓名
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "Name:".tr,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.name ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22),
-
-          //性别
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "${"Gender".tr}:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.sex ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //生日
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "DOB:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.dob ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //身份证
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "${"NRIC".tr}:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.nric ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //评分
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "${"Reviews".tr}:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                "${detail?.remRate.toString() ?? "-"} (${detail?.remNum.toString() ?? "0"} Reviews)",
-                marginLeft: 5,
-                textColor: ColorConstants.textGreen0AC074,
-                fontSize: 14,
-                onClick: onRemarkAction,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //电话号码
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "${"Mobile".tr}:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.mobile ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //邮箱
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "${"Email".tr}:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.email ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //国籍
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "Nationality:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.natl ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //语言
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "Language:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.lang ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //地址
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "Address:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.address ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //紧急联系人
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "Emergency Name:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.emerName ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10),
-
-          //紧急联系人电话
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyTextView(
-                "Emergency Phone:",
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-                isFontRegular: true,
-              ),
-              MyTextView(
-                detail?.emerPhone ?? "-",
-                marginLeft: 5,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ).marginOnly(left: 22, right: 22, top: 10, bottom: 26),
-        ],
-      ),
-    );
-  }
-}

+ 0 - 333
packages/cpt_th/lib/modules/job/applied_staff_detail/staff_labour_history_item.dart

@@ -1,333 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/staff_labour_history_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-
-/**
- * 员工的做工记录
- */
-class StaffLabourHistoryItem extends StatelessWidget {
-  final int index;
-  final StaffLabourHistoryRows item;
-
-  StaffLabourHistoryItem({
-    required this.index,
-    required this.item,
-  });
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      padding: EdgeInsets.symmetric(vertical: 23, horizontal: 21),
-      margin: EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        mainAxisSize: MainAxisSize.max,
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children: [
-          //工作日期
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Job Date".tr+":",
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //日期
-              MyTextView(
-                item.jobDate ?? "-",
-                isFontRegular: true,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                marginLeft: 5,
-                marginRight: 5,
-              ).expanded(),
-
-            ],
-          ),
-
-          //员工姓名
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Staff Name:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //姓名
-              MyTextView(
-                item.staffName ?? "-",
-                isFontRegular: true,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                marginLeft: 5,
-                marginRight: 5,
-              ).expanded(),
-
-            ],
-          ).marginOnly(top: 12),
-
-          //工作标题(模板)
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Job Title:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //标题
-              MyTextView(
-                item.jobTitle ?? "-",
-                isFontRegular: true,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                marginLeft: 5,
-                marginRight: 5,
-              ).expanded(),
-
-            ],
-          ).marginOnly(top: 12),
-
-          //部门
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Outlet:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //部门
-              MyTextView(
-                item.outletName ?? "-",
-                isFontRegular: true,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                marginLeft: 5,
-                marginRight: 5,
-              ).expanded(),
-
-            ],
-          ).marginOnly(top: 12),
-
-          // 工作开始时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Start Time:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.startTime ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 门卫签到时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Security In:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.securityIn?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.securityIn?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 工作地签到时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Work In:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.workIn?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.workIn?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          //工作结束时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "End Time:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.endTime ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 工作地签出时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Work Out:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.workOut?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.workOut?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 门卫签出时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Security Out:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.securityOut?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.securityOut?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 申请时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Applied At:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //发布状态
-              MyTextView(
-                item.appliedAt ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 状态
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Status:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //发布状态
-              MyTextView(
-                item.statusShow ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: "Completed" == item.statusShow
-                    ? ColorConstants.textGreen05DC82
-                    : "Cancelled" == item.statusShow || "Rejected" == item.statusShow
-                        ? ColorConstants.textRedFF6262
-                        : "Revised" == item.statusShow || "Pending" == item.statusShow || "Approve" == item.statusShow
-                            ? ColorConstants.textYellowFFBB1B
-                            : ColorConstants.textBlue06D9FF,  //默认蓝色
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-        ],
-      ),
-    );
-  }
-}

+ 0 - 108
packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_controller.dart

@@ -1,108 +0,0 @@
-import 'package:domain/entity/response/staff_remark_history_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'applied_staff_reviews_state.dart';
-
-class AppliedStaffReviewsController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final AppliedStaffReviewsState state = AppliedStaffReviewsState();
-
-  var _curPage = 1;
-  var _needShowPlaceholder = true;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: true,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    _curPage = 1;
-    fetchStaffReviews();
-  }
-
-  // Refresh 加载事件
-  Future loadMore() async {
-    _curPage++;
-    fetchStaffReviews();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _curPage = 1;
-    _needShowPlaceholder = true;
-    fetchStaffReviews();
-  }
-
-  /// 获取列表数据
-  Future fetchStaffReviews() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    }
-
-    var listResult = await _jobRepository.fetchStaffRemarkHistory(state.memberId, curPage: _curPage, cancelToken: cancelToken);
-
-    // 处理数据
-    if (listResult.isSuccess) {
-      handleList(listResult.data?.rows);
-    } else {
-      errorMessage = listResult.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-    }
-
-    // 最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<StaffRemarkHistoryRows>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      if (_curPage == 1) {
-        //刷新的方式
-        state.datas.clear();
-        state.datas.addAll(list);
-        refreshController.finishRefresh();
-
-        //更新展示的状态
-        changeLoadingState(LoadState.State_Success);
-      } else {
-        //加载更多
-        state.datas.addAll(list);
-        refreshController.finishLoad();
-        update();
-      }
-    } else {
-      if (_curPage == 1) {
-        //展示无数据的布局
-        state.datas.clear();
-        changeLoadingState(LoadState.State_Empty);
-        refreshController.finishRefresh();
-      } else {
-        //展示加载完成,没有更多数据了
-        refreshController.finishLoad(IndicatorResult.noMore);
-      }
-    }
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchStaffReviews();
-  }
-}

+ 0 - 151
packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_item.dart

@@ -1,151 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/staff_remark_history_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/shatter/rating_widget.dart';
-
-/**
- * 员工的评价记录
- */
-class StaffReviewsItem extends StatelessWidget {
-  final int index;
-  final StaffRemarkHistoryRows item;
-
-  StaffReviewsItem({
-    required this.index,
-    required this.item,
-  });
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      padding: EdgeInsets.only(bottom: 25, left: 21,right: 21,top: 18.5),
-      margin: EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children: [
-          MyTextView(
-            item.company ?? "",
-            isFontRegular: true,
-            textColor: Colors.white,
-            fontSize: 17,
-          ),
-
-          //态度评分
-          Row(
-            children: [
-              MyTextView(
-                "Attitude".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 15,
-              ).expanded(flex: 2),
-              RatingWidget(
-                nomalImage: Assets.baseServiceRatingUnselected,
-                selectImage: Assets.baseServiceRatingSelected,
-                size: 21,
-                padding: 5,
-                selectAble: false,
-                integerOnly: true,
-                value: item.attitudeRate,
-                onRatingUpdate: (value) {},
-              ).expanded(flex: 3)
-            ],
-          ).marginOnly(top: 15),
-
-          //表现评分
-          Row(
-            children: [
-              MyTextView(
-                "Performance".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 15,
-              ).expanded(flex: 2),
-              RatingWidget(
-                nomalImage: Assets.baseServiceRatingUnselected,
-                selectImage: Assets.baseServiceRatingSelected,
-                size: 21,
-                padding: 5,
-                selectAble: false,
-                integerOnly: true,
-                value: item.performanceRate,
-                onRatingUpdate: (value) {},
-              ).expanded(flex: 3)
-            ],
-          ).marginOnly(top: 15),
-
-          //经验评分
-          Row(
-            children: [
-              MyTextView(
-                "Experience".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 15,
-              ).expanded(flex: 2),
-              RatingWidget(
-                nomalImage: Assets.baseServiceRatingUnselected,
-                selectImage: Assets.baseServiceRatingSelected,
-                size: 21,
-                padding: 5,
-                selectAble: false,
-                integerOnly: true,
-                value: item.experienceRate,
-                onRatingUpdate: (value) {},
-              ).expanded(flex: 3)
-            ],
-          ).marginOnly(top: 15),
-
-          //着装评分
-          Row(
-            children: [
-              MyTextView(
-                "Grooming".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 15,
-              ).expanded(flex: 2),
-              RatingWidget(
-                nomalImage: Assets.baseServiceRatingUnselected,
-                selectImage: Assets.baseServiceRatingSelected,
-                size: 21,
-                padding: 5,
-                selectAble: false,
-                integerOnly: true,
-                value: item.groomingRate,
-                onRatingUpdate: (value) {},
-              ).expanded(flex: 3)
-            ],
-          ).marginOnly(top: 15),
-
-          MyTextView(
-            item.feedback ?? "",
-            textColor: Colors.white,
-            fontSize: 15,
-            isFontRegular: true,
-            borderColor: Color(0XFF6D92BA),
-            borderWidth: 0.5,
-            boxHeight: 130,
-            boxWidth: double.infinity,
-            paddingTop: 15,
-            paddingLeft: 12.5,
-            paddingRight: 12.5,
-            paddingBottom: 15,
-            marginTop: 18,
-          ),
-
-        ],
-      ),
-    );
-  }
-}

+ 0 - 162
packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_page.dart

@@ -1,162 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:flutter/material.dart';
-import 'package:get/get.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/shatter/rating_widget.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'applied_staff_reviews_controller.dart';
-
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/my_appbar.dart';
-
-import 'applied_staff_reviews_item.dart';
-import 'applied_staff_reviews_state.dart';
-
-/**
- * 员工的评论页面
- */
-class AppliedStaffReviewsPage extends BaseStatefulPage<AppliedStaffReviewsController> {
-  AppliedStaffReviewsPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance(String? memberId, String? staffName, double? reviews, String? reviewCount) {
-    return Get.start(
-      RouterPath.jobAppliedStaffReviews,
-      arguments: {'memberId': memberId, 'staffName': staffName, 'reviews': reviews, 'reviewCount': reviewCount},
-    );
-  }
-
-  @override
-  AppliedStaffReviewsController createRawController() {
-    return AppliedStaffReviewsController();
-  }
-
-  @override
-  State<AppliedStaffReviewsPage> createState() => _AppliedStaffReviewsState();
-}
-
-class _AppliedStaffReviewsState extends BaseState<AppliedStaffReviewsPage, AppliedStaffReviewsController> {
-  late AppliedStaffReviewsState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-    state.memberId = Get.arguments['memberId'];
-    state.staffName = Get.arguments['staffName'];
-    state.reviews = Get.arguments['reviews'];
-    state.reviewCount = Get.arguments['reviewCount'];
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-        top: false,
-        child: Container(
-          width: double.infinity,
-          height: double.infinity,
-          padding: EdgeInsets.only(top: ScreenUtil.getStatusBarH(context)),
-          decoration: const BoxDecoration(
-            gradient: LinearGradient(
-              colors: [
-                Color(0xFF091D44),
-                Color(0xFF245A8A),
-                Color(0xFF7F7CEC),
-              ],
-              begin: Alignment.topCenter,
-              end: Alignment.bottomCenter,
-            ),
-          ),
-          child: Column(
-            crossAxisAlignment: CrossAxisAlignment.start,
-            mainAxisSize: MainAxisSize.max,
-            children: [
-              MyAppBar.titleBar(context, "Staff Detail".tr),
-              EasyRefresh(
-                controller: controller.refreshController,
-                onRefresh: controller.onRefresh,
-                onLoad: controller.loadMore,
-                child: LoadStateLayout(
-                  state: controller.loadingState,
-                  errorMessage: controller.errorMessage,
-                  errorRetry: () {
-                    controller.retryRequest();
-                  },
-                  successSliverWidget: [
-                    //顶部用户信息
-                    SliverToBoxAdapter(
-                      child: _buildRemarkWidget(),
-                    ),
-
-                    //底部工作历史列表
-                    SliverList(
-                        delegate: SliverChildBuilderDelegate(
-                      (context, index) {
-                        return StaffReviewsItem(index: index, item: state.datas[index]);
-                      },
-                      childCount: state.datas.length,
-                    ))
-                  ],
-                ),
-              ).expanded(),
-            ],
-          ),
-        ),
-      );
-    });
-  }
-
-  Widget _buildRemarkWidget() {
-    return Container(
-      padding: EdgeInsets.only(bottom: 22, left: 21, right: 21, top: 18.5),
-      margin: EdgeInsets.only(left: 15, right: 15, top: 14.5, bottom: 5),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children: [
-          MyTextView(
-            state.staffName ?? "-",
-            fontSize: 17,
-            textColor: ColorConstants.white,
-            isFontMedium: true,
-            marginBottom: 8,
-          ),
-          Row(
-            children: [
-              RatingWidget(
-                nomalImage: Assets.baseServiceRatingUnselected,
-                selectImage: Assets.baseServiceRatingSelected,
-                size: 21,
-                padding: 5,
-                selectAble: false,
-                integerOnly: false,
-                value: state.reviews ?? 0,
-                onRatingUpdate: (value) {},
-              ),
-              MyTextView(
-                "${state.reviews.toString()} (${state.reviewCount} Reviews)",
-                fontSize: 14,
-                marginLeft: 12,
-                textColor: ColorConstants.textYellowF8AE00,
-                isFontMedium: true,
-              ).expanded(),
-            ],
-          ),
-        ],
-      ),
-    );
-  }
-}

+ 0 - 10
packages/cpt_th/lib/modules/job/applied_staff_reviews/applied_staff_reviews_state.dart

@@ -1,10 +0,0 @@
-import 'package:domain/entity/response/staff_remark_history_entity.dart';
-
-class AppliedStaffReviewsState {
-  String? memberId;
-  String? staffName;
-  double? reviews;
-  String? reviewCount;
-
-  List<StaffRemarkHistoryRows> datas = [];
-}

+ 0 - 98
packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_controller.dart

@@ -1,98 +0,0 @@
-import 'package:domain/entity/response/job_list_applied_work_flow_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'applied_workflow_state.dart';
-
-/*
- * 已申请的员工状态审核流
- */
-class  AppliedWorkflowController extends GetxController with DioCancelableMixin{
-  final JobRepository _jobRepository = Get.find();
-  final AppliedWorkflowState state = AppliedWorkflowState();
-
-  var _needShowPlaceholder = true;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: false,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    fetchWorkFlowList();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _needShowPlaceholder = true;
-    fetchWorkFlowList();
-  }
-
-  /// 获取服务器数据,成员考勤列表
-  Future fetchWorkFlowList() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    }
-
-    //获取到数据
-    var result = await _jobRepository.fetchAppliedWorkFlow(
-      state.appliedId,
-      cancelToken: cancelToken,
-    );
-
-    //处理数据
-    if (result.isSuccess) {
-      handleList(result.data?.records);
-      refreshController.finishRefresh(IndicatorResult.success);
-    } else {
-      errorMessage = result.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-      refreshController.finishRefresh(IndicatorResult.fail);
-    }
-
-    //最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<JobListAppliedWorkFlowRecords>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      state.datas.clear();
-      state.datas.addAll(list);
-      //更新状态
-      changeLoadingState(LoadState.State_Success);
-    } else {
-      //展示无数据的布局
-      state.datas.clear();
-      changeLoadingState(LoadState.State_Empty);
-    }
-  }
-
-  @override
-  void onReady() async {
-    super.onReady();
-    fetchWorkFlowList();
-  }
-
-  @override
-  void onClose() {
-    super.onClose();
-    state.datas.clear();
-  }
-}

+ 0 - 228
packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_item.dart

@@ -1,228 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:domain/entity/response/job_list_applied_work_flow_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_text_view.dart';
-
-/**
- * 用工请求的工作流列表Item
- */
-class AppliedWorkFlowItem extends StatelessWidget {
-  final int index;
-  final JobListAppliedWorkFlowRecords item;
-
-  AppliedWorkFlowItem({
-    required this.index,
-    required this.item,
-  });
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      padding: EdgeInsets.symmetric(vertical: 23, horizontal: 21),
-      margin: EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        mainAxisSize: MainAxisSize.max,
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children: [
-          //Node
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Node:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              MyTextView(
-                item.nodeName ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ),
-
-          // assigneeType
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Type:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //日期时间
-              MyTextView(
-                item.assigneeTypeShow ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // Designation
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Designation:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //人数
-              MyTextView(
-                item.designationShow ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // 状态
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Status:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //状态
-              MyTextView(
-                item.statusShow == null ? "" : item.statusShow!.tr,
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: "Approved" == item.statusShow
-                    ? ColorConstants.textGreen05DC82
-                    : "Rejected" == item.statusShow
-                    ? ColorConstants.textRedFF6262
-                    : "Recall" == item.statusShow
-                    ? ColorConstants.textYellowFFBB1B
-                    : ColorConstants.textBlue06D9FF,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // Operator
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Operator:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //发布状态
-              MyTextView(
-                item.auditName ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // 操作时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Audit Time:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.auditTime ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // 创建时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Created At:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.createdAt ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // Remark
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Remark:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.auditMark ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-        ],
-      ),
-    );
-  }
-}

+ 0 - 102
packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_page.dart

@@ -1,102 +0,0 @@
-
-import 'package:flutter/material.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_appbar.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'applied_workflow_controller.dart';
-import 'applied_workflow_state.dart';
-import 'applied_workflow_item.dart';
-
-/**
- * 已申请的员工-状态工作流列表
- */
-class AppliedWorkflowPage extends BaseStatefulPage<AppliedWorkflowController> {
-  AppliedWorkflowPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance(String? appliedId) {
-    return Get.start(RouterPath.jobAppliedStaffWorkflow,arguments: {'appliedId': appliedId});
-  }
-
-  @override
-  AppliedWorkflowController createRawController() {
-    return AppliedWorkflowController();
-  }
-
-  @override
-  State<AppliedWorkflowPage> createState() => _AppliedWorkflowState();
-
-}
-
-class _AppliedWorkflowState extends BaseState<AppliedWorkflowPage, AppliedWorkflowController> {
-
-  late AppliedWorkflowState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-    state.appliedId = Get.arguments['appliedId'];
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return  SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top:ScreenUtil.getStatusBarH(context)),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Column(
-              children: [
-                MyAppBar.titleBar(context, "Workflow".tr),
-
-                EasyRefresh(
-                  controller: controller.refreshController,
-                  onRefresh: controller.onRefresh,
-                  child: LoadStateLayout(
-                    state: controller.loadingState,
-                    errorMessage: controller.errorMessage,
-                    errorRetry: () {
-                      controller.retryRequest();
-                    },
-                    successSliverWidget: [
-                      SliverList(
-                          delegate: SliverChildBuilderDelegate((context, index) {
-                              return AppliedWorkFlowItem(index: index,item: state.datas[index]);
-                            },
-                            childCount: state.datas.length,
-                          ))
-                    ],
-                  ),
-                ).marginOnly(top: 5,bottom: 5).expanded(),
-              ],
-            ).marginOnly(top: 10),
-          ),
-        );
-    });
-  }
-}
-
-

+ 0 - 10
packages/cpt_th/lib/modules/job/applied_workflow/applied_workflow_state.dart

@@ -1,10 +0,0 @@
-import 'package:domain/entity/response/job_list_applied_work_flow_entity.dart';
-
-class AppliedWorkflowState {
-
-  String? appliedId;
-
-  //页面的列表数据
-  List<JobListAppliedWorkFlowRecords> datas = [];
-
-}

+ 0 - 247
packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_controller.dart

@@ -1,247 +0,0 @@
-import 'package:domain/entity/response/attendance_review_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/engine/dialog/dialog_engine.dart';
-import 'package:plugin_platform/engine/notify/notify_engine.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-
-import 'package:shared/utils/log_utils.dart';
-import 'package:widgets/dialog/app_default_dialog.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'attendance_review_reject_dialog.dart';
-import 'attendance_review_state.dart';
-
-class AttendanceReviewController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final AttendanceReviewState state = AttendanceReviewState();
-
-  var _curPage = 1;
-  var _needShowPlaceholder = true;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: true,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    _curPage = 1;
-    fetchAppliedStaffList();
-  }
-
-  // Refresh 加载事件
-  Future loadMore() async {
-    _curPage++;
-    fetchAppliedStaffList();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _curPage = 1;
-    _needShowPlaceholder = true;
-    fetchAppliedStaffList();
-  }
-
-  /// 获取服务器数据,通知消息列表
-  Future fetchAppliedStaffList() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    }
-
-    // 并发执行两个请求
-    final listResult = await _jobRepository.fetchAttendanceReviewList(
-      state.keyword,
-      curPage: _curPage,
-      cancelToken: cancelToken,
-    );
-
-    // 处理数据
-    if (listResult.isSuccess) {
-      handleList(listResult.data?.rows);
-    } else {
-      errorMessage = listResult.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-    }
-
-    // 最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<AttendanceReviewRows>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      if (_curPage == 1) {
-        //刷新的方式
-        state.datas.clear();
-        state.datas.addAll(list);
-        refreshController.finishRefresh();
-
-        //更新展示的状态
-        changeLoadingState(LoadState.State_Success);
-      } else {
-        //加载更多
-        state.datas.addAll(list);
-        refreshController.finishLoad();
-        update();
-      }
-    } else {
-      if (_curPage == 1) {
-        //展示无数据的布局
-        state.datas.clear();
-        changeLoadingState(LoadState.State_Empty);
-        refreshController.finishRefresh();
-      } else {
-        //展示加载完成,没有更多数据了
-        refreshController.finishLoad(IndicatorResult.noMore);
-      }
-    }
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchAppliedStaffList();
-  }
-
-  @override
-  void onClose() {
-    state.datas.clear();
-    super.onClose();
-  }
-
-  /// 搜索
-  void doSearch(String keyword) {
-    state.keyword = keyword;
-    //赋值之后刷新
-    refreshController.callRefresh();
-  }
-
-  /// 清空筛选条件
-  void resetFiltering() {
-    state.keyword = "";
-    state.searchController.text = "";
-
-    //赋值之后刷新
-    refreshController.callRefresh();
-  }
-
-  /// Item选中与未选中设置
-  void doSelectedOrNot(AttendanceReviewRows data) {
-    data.isSelected = !data.isSelected;
-    Log.d("isSelected:${data.isSelected}");
-    update();
-  }
-
-  /// 执行批量同意
-  void _requestBatchApprove(String recordIds) async {
-    //执行请求
-    var result = await _jobRepository.approveAttendanceReviews(
-      recordIds,
-      cancelToken: cancelToken,
-    );
-
-    if (result.isSuccess) {
-      NotifyEngine.showSuccess("Successful".tr);
-
-      //调用接口刷新指定的Staff的信息
-      _removeItemsByList(recordIds);
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-      return;
-    }
-  }
-
-  /// 执行批量拒绝
-  void _requestBatchReject(String recordIds, String? reason) async {
-    //执行请求
-    var result = await _jobRepository.rejectLabourReviews(
-      recordIds,
-      reason,
-      cancelToken: cancelToken,
-    );
-
-    if (result.isSuccess) {
-      NotifyEngine.showSuccess("Successful".tr);
-
-      //调用接口刷新指定的Staff的信息
-      _removeItemsByList(recordIds);
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-      return;
-    }
-  }
-
-  /// 批准的操作
-  void operationApprove() async {
-    //找出已经选中的员工(只有状态为3 Approve的状态才能修改)
-    var selectedList = state.datas.where((element) => element.isSelected).toList(growable: false);
-    if (selectedList.isNotEmpty) {
-      var ids = selectedList.map((e) => e.recordId.toString()).toList(growable: false);
-      var recordIds = ids.join(',');
-
-      // Are you sure 的弹窗
-      DialogEngine.show(
-        widget: AppDefaultDialog(
-          title: "Message".tr,
-          message: "Are you sure you want to setting approved?".tr,
-          confirmAction: () {
-            _requestBatchApprove(recordIds);
-          },
-        ),
-      );
-    } else {
-      ToastEngine.show("Please select the record".tr);
-    }
-  }
-
-  /// 拒绝的操作
-  void operationReject() async {
-    //找出已经选中的员工(只有状态为3 Approve的状态才能修改)
-    var selectedList = state.datas.where((element) => element.isSelected).toList(growable: false);
-    if (selectedList.isNotEmpty) {
-      var ids = selectedList.map((e) => e.recordId.toString()).toList(growable: false);
-      var recordIds = ids.join(',');
-
-      // Are you sure 的弹窗
-      DialogEngine.show(
-        widget: AttendaceReviewRejectDialog(
-          confirmAction: (reason) {
-            //请求接口,提交评论
-            _requestBatchReject(recordIds, reason);
-          },
-        ),
-      );
-    } else {
-      ToastEngine.show("Please select the record".tr);
-    }
-  }
-
-  /// 删除对应的recordId的Item数据
-  void _removeItemsByList(String recordIds) {
-    // 将逗号分隔的字符串转换为数组
-    List<String> recordIdList = recordIds.split(',');
-
-    // 移除列表中符合条件的项
-    state.datas.removeWhere((e) => recordIdList.contains(e.recordId));
-
-    update();
-  }
-
-  /// 去用工审核流程页面
-  void gotoStatusViewPage(AttendanceReviewRows data) {}
-}

+ 0 - 329
packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_item.dart

@@ -1,329 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/attendance_review_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-
-/*
- * 用工审核的列表Item
- */
-class AttendanceReviewItem extends StatelessWidget {
-  final int index;
-  final AttendanceReviewRows item;
-  final VoidCallback? onStatusAction;
-  final VoidCallback? onItemAction;
-
-  AttendanceReviewItem({
-    required this.index,
-    required this.item,
-    this.onStatusAction,
-    this.onItemAction,
-  });
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      padding: const EdgeInsets.symmetric(vertical: 23, horizontal: 21),
-      margin: const EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5),
-      decoration: BoxDecoration(
-        color: const Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        mainAxisSize: MainAxisSize.max,
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children:[
-          //员工姓名
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Staff Name:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //姓名
-              MyTextView(
-                item.staffName ?? "-",
-                isFontRegular: true,
-                textColor: ColorConstants.white,
-                fontSize: 14,
-                marginLeft: 5,
-                marginRight: 5,
-              ).expanded(),
-
-              //是否选中
-              MyAssetImage(
-                item.isSelected ? Assets.baseServiceItemSelectedIcon : Assets.baseServiceItemUnselectedIcon,
-                width: 20.5,
-                height: 20.5,
-              ),
-            ],
-          ),
-
-          // 工作标题
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "${"Title".tr}:",
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              MyTextView(
-                item.jobTitle ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 部门
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "${"Outlet".tr}:",
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              MyTextView(
-                item.departmentName ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 工作时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "DateTime:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              MyTextView(
-                item.jobTime ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          //考勤时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "${"Clock Time".tr}:",
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                "${item.clockIn} - ${item.clockOut}",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-
-          // + - Hours
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "+/- Hours:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //小时
-              MyTextView(
-                Utils.isNotEmpty(item.adjustShow) ? item.adjustShow! : "0",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // Total Hours
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "${"Total (Hrs/Rms)".tr}:",
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //小时
-              MyTextView(
-                item.totalShow.toString(),
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 状态
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Status:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //发布状态
-              MyTextView(
-                item.statusShow ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: "Completed" == item.statusShow
-                    ? ColorConstants.textGreen05DC82
-                    : "Cancelled" == item.statusShow || "Rejected" == item.statusShow
-                    ? ColorConstants.textRedFF6262
-                    : "Revised" == item.statusShow || "Pending" == item.statusShow || "Approve" == item.statusShow
-                    ? ColorConstants.textYellowFFBB1B
-                    : ColorConstants.textBlue06D9FF,  //默认蓝色
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 创建时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Created At:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              MyTextView(
-                item.createdAt ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // //按钮组
-          // Visibility(
-          //   visible: item.actionList?.isNotEmpty ?? false,
-          //   child: Row(
-          //     mainAxisSize: MainAxisSize.max,
-          //     mainAxisAlignment: MainAxisAlignment.end,
-          //     crossAxisAlignment: CrossAxisAlignment.center,
-          //     children: [
-          //       //编辑按钮
-          //       Visibility(
-          //         visible: item.actionList?.contains("edit") ?? false,
-          //         child: MyButton(
-          //           onPressed: () {
-          //             FocusScope.of(context).unfocus();
-          //             onEditAction?.call();
-          //           },
-          //           text: "Edit".tr,
-          //           textColor: ColorConstants.white,
-          //           backgroundColor: hexToColor(
-          //             "#FFBB1B",
-          //           ),
-          //           radius: 17.25,
-          //           minWidth: 60,
-          //           minHeight: 35,
-          //         ).marginOnly(left: 12),
-          //       ),
-          //
-          //       //状态工作流按钮
-          //       Visibility(
-          //         visible: item.actionList?.contains("status") ?? false,
-          //         child: MyButton(
-          //           onPressed: () {
-          //             FocusScope.of(context).unfocus();
-          //             onStatusAction?.call();
-          //           },
-          //           text: "Status".tr,
-          //           textColor: ColorConstants.white,
-          //           backgroundColor: hexToColor("#0AC074"),
-          //           radius: 17.25,
-          //           minWidth: 60,
-          //           minHeight: 35,
-          //         ).marginOnly(left: 12),
-          //       ),
-          //
-          //       //Remark按钮
-          //       Visibility(
-          //         visible: item.actionList?.contains("remarks") ?? false,
-          //         child: MyButton(
-          //           onPressed: () {
-          //             FocusScope.of(context).unfocus();
-          //             onRemarkAction?.call();
-          //           },
-          //           text: "Remarks".tr,
-          //           textColor: ColorConstants.white,
-          //           backgroundColor: hexToColor("#56AAFF"),
-          //           radius: 17.25,
-          //           minWidth: 60,
-          //           minHeight: 35,
-          //         ).marginOnly(left: 12),
-          //       ),
-          //     ],
-          //   ).marginOnly(top: 15),
-          // ),
-        ],
-      ),
-    ).onTap(() {
-      onItemAction?.call();
-    });
-  }
-}

+ 0 - 173
packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_page.dart

@@ -1,173 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:get/get.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'attendance_review_item.dart';
-import 'attendance_review_controller.dart';
-
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/my_appbar.dart';
-import 'attendance_review_state.dart';
-
-/*
- * 工作考勤的审核列表
- */
-class AttendanceReviewPage extends BaseStatefulPage<AttendanceReviewController> {
-  AttendanceReviewPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance() {
-    return Get.start(RouterPath.jobAttendanceReviewList);
-  }
-
-  @override
-  AttendanceReviewController createRawController() {
-    return AttendanceReviewController();
-  }
-
-  @override
-  State<AttendanceReviewPage> createState() => _LabourReviewState();
-}
-
-class _LabourReviewState extends BaseState<AttendanceReviewPage, AttendanceReviewController> {
-  late AttendanceReviewState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-        top: false,
-        child: Container(
-          width: double.infinity,
-          height: double.infinity,
-          padding: EdgeInsets.only(top: ScreenUtil.getStatusBarH(context)),
-          decoration: const BoxDecoration(
-            gradient: LinearGradient(
-              colors: [
-                Color(0xFF091D44),
-                Color(0xFF245A8A),
-                Color(0xFF7F7CEC),
-              ],
-              begin: Alignment.topCenter,
-              end: Alignment.bottomCenter,
-            ),
-          ),
-          child: Column(
-            children: [
-              MyAppBar.searchTitleBar(
-                context,
-                value: state.keyword,
-                hintText: 'Title'.tr,
-                controller: state.searchController,
-                onSearch: (keyword) {
-                  controller.doSearch(keyword);
-                },
-                actions: [
-                  //重置按钮
-                  MyButton(
-                    onPressed: () {
-                      FocusScope.of(context).unfocus();
-                      controller.resetFiltering();
-                    },
-                    text: "Reset".tr,
-                    textColor: ColorConstants.white,
-                    backgroundColor: hexToColor("#2BA9F9", opacity: 0.5),
-                    radius: 17.25,
-                    minWidth: 60,
-                    minHeight: 35,
-                  ).marginOnly(right: 15),
-
-                ],
-              ),
-
-              //底部的列表
-              EasyRefresh(
-                controller: controller.refreshController,
-                onRefresh: controller.onRefresh,
-                onLoad: controller.loadMore,
-                child: LoadStateLayout(
-                  state: controller.loadingState,
-                  errorMessage: controller.errorMessage,
-                  errorRetry: () {
-                    controller.retryRequest();
-                  },
-                  successSliverWidget: [
-                    SliverList(
-                        delegate: SliverChildBuilderDelegate(
-                      (context, index) {
-                        return AttendanceReviewItem(
-                          index: index,
-                          item: state.datas[index],
-                          onStatusAction: () {
-
-                          },
-                          onItemAction: () {
-                            controller.doSelectedOrNot(state.datas[index]);
-                          },
-                        );
-                      },
-                      childCount: state.datas.length,
-                    ))
-                  ],
-                ),
-              ).expanded(),
-
-              Row(
-                mainAxisSize: MainAxisSize.max,
-                children: [
-                  //批量Approve
-                  MyTextView(
-                    "Batch Confirm".tr,
-                    fontSize: 17,
-                    isFontMedium: true,
-                    boxHeight: 48,
-                    onClick: () {
-                      controller.operationApprove();
-                    },
-                    alignment: Alignment.center,
-                    textAlign: TextAlign.center,
-                    textColor: Colors.white,
-                    backgroundColor: ColorConstants.textGreen0AC074,
-                  ).expanded(),
-
-                  //批量修改时间
-                  MyTextView(
-                    "Batch Reject".tr,
-                    fontSize: 17,
-                    isFontMedium: true,
-                    boxHeight: 48,
-                    onClick: () {
-                      controller.operationReject();
-                    },
-                    alignment: Alignment.center,
-                    textAlign: TextAlign.center,
-                    textColor: Colors.white,
-                    backgroundColor: ColorConstants.textRedFF6262,
-                  ).expanded(),
-                ],
-              ),
-            ],
-          ),
-        ),
-      );
-    });
-  }
-}

+ 0 - 187
packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_reject_dialog.dart

@@ -1,187 +0,0 @@
-import 'dart:ui';
-
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/widget_export.dart';
-
-/*
- * 拒绝的弹窗
- */
-class AttendaceReviewRejectDialog extends StatefulWidget {
-
-  void Function(String reason)? confirmAction;
-
-  AttendaceReviewRejectDialog({this.confirmAction});
-
-  @override
-  State<AttendaceReviewRejectDialog> createState() => _AttendaceReviewRejectDialogState();
-}
-
-class _AttendaceReviewRejectDialogState extends State<AttendaceReviewRejectDialog> {
-
-  late TextEditingController _controller;
-  late FocusNode _focusNode;
-
-  @override
-  void initState() {
-    super.initState();
-    _controller = TextEditingController();
-    _focusNode = FocusNode();
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return Column(
-      crossAxisAlignment: CrossAxisAlignment.center,
-      mainAxisAlignment: MainAxisAlignment.center,
-      children: [
-        //Title (如果使用 Container 为最外层容器则默认为 match_parent 的效果,除非我们限制宽度和最大高度最小高度)
-        Container(
-          width: double.infinity,
-          decoration: const BoxDecoration(
-            color: Colors.white,
-            borderRadius: BorderRadius.all(Radius.circular(15)),
-          ),
-          child: Column(
-            crossAxisAlignment: CrossAxisAlignment.start,
-            children: [
-              Center(
-                child: MyTextView(
-                  "Reason for refusal".tr,
-                  fontSize: 19,
-                  isFontMedium: true,
-                  textColor: ColorConstants.black,
-                  marginTop: 23,
-                  marginLeft: 22,
-                  marginRight: 22,
-                ),
-              ),
-
-              IgnoreKeyboardDismiss(
-                child: Container(
-                  height: 130,
-                  margin: const EdgeInsets.symmetric(vertical: 19, horizontal: 22),
-                  padding: const EdgeInsets.symmetric(vertical: 15, horizontal: 15),
-                  decoration: BoxDecoration(
-                    color: const Color(0xFFF0F0F0),
-                    border: Border.all(
-                      color: const Color(0xFFD8D8D8),
-                      width: 0.5,
-                    ),
-                  ),
-                  child: TextField(
-                    cursorColor: ColorConstants.black66,
-                    cursorWidth: 1.5,
-                    autofocus: false,
-                    enabled: true,
-                    focusNode: _focusNode,
-                    controller: _controller,
-                    // 装饰
-                    decoration: InputDecoration(
-                      isDense: true,
-                      isCollapsed: true,
-                      border: InputBorder.none,
-                      hintText: "Enter...".tr,
-                      hintStyle: const TextStyle(
-                        color: ColorConstants.black66,
-                        fontSize: 15.0,
-                        fontWeight: FontWeight.w400,
-                      ),
-                    ),
-                    style: const TextStyle(
-                      color: ColorConstants.black,
-                      fontSize: 15.0,
-                      fontWeight: FontWeight.w400,
-                    ),
-                    // 键盘动作右下角图标
-                    textInputAction: TextInputAction.done,
-                    onSubmitted: (value) {
-                      doCallbackAction();
-                    },
-                  ),
-                ),
-              ),
-
-              // 分割线
-              Container(
-                color: const Color(0XFFCECECE),
-                height: 0.5,
-              ),
-
-              //按钮组
-              Row(
-                children: [
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () {
-                          onCancel();
-                        },
-                        child: MyTextView(
-                          "Cancel".tr,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: const Color(0XFF0085C4),
-                          cornerRadius: 3,
-                          borderWidth: 1,
-                        ),
-                      )),
-                  Container(
-                    color: const Color(0xff09141F).withOpacity(0.13),
-                    width: 0.5,
-                  ),
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () {
-                          doCallbackAction();
-                        },
-                        child: MyTextView(
-                          "Submit".tr,
-                          marginLeft: 10,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: const Color(0XFF0085C4),
-                          cornerRadius: 3,
-                        ),
-                      )),
-                ],
-              ).constrained(height: 46),
-            ],
-          ),
-        ),
-      ],
-    ).constrained(width: 285);
-  }
-
-  //取消弹框
-  void onCancel() async {
-    SmartDialog.dismiss();
-  }
-
-  //执行回调
-  void doCallbackAction() {
-    _focusNode.unfocus();
-
-    final content = _controller.text.toString();
-
-    if (Utils.isEmpty(content)) {
-      ToastEngine.show("Please Enter Reason".tr);
-      return;
-    }
-
-    onCancel();
-
-    widget.confirmAction?.call(content);
-  }
-}

+ 0 - 12
packages/cpt_th/lib/modules/job/attendance_review_list/attendance_review_state.dart

@@ -1,12 +0,0 @@
-import 'package:domain/entity/response/attendance_review_entity.dart';
-import 'package:flutter/material.dart';
-
-class AttendanceReviewState {
-  //筛选条件
-  final TextEditingController searchController = TextEditingController();
-  String keyword = "";
-
-  //页面的列表数据
-  List<AttendanceReviewRows> datas = [];
-
-}

+ 0 - 430
packages/cpt_th/lib/modules/job/job_applied/applied_staff_item.dart

@@ -1,430 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/job_list_applied_info_entity.dart';
-import 'package:domain/entity/response/job_list_applied_staff_list_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-
-/**
- * 已申请的员工列表Item
- */
-class AppliedStaffItem extends StatelessWidget {
-  final int index;
-  final JobListAppliedInfoEntity? jobInfo;
-  final JobListAppliedStaffListRows item;
-  final VoidCallback? onStatusAction;
-  final VoidCallback? onEditAction;
-  final VoidCallback? onRemarkAction;
-  final VoidCallback? onItemAction;
-  final VoidCallback? onMemberAction;
-
-  AppliedStaffItem({
-    required this.index,
-    required this.item,
-    required this.jobInfo,
-    this.onStatusAction,
-    this.onRemarkAction,
-    this.onEditAction,
-    this.onItemAction,
-    this.onMemberAction,
-  });
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      padding: EdgeInsets.symmetric(vertical: 23, horizontal: 21),
-      margin: EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        mainAxisSize: MainAxisSize.max,
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children: [
-          //员工姓名
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Staff Name:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //姓名
-              MyTextView(
-                item.staffName ?? "-",
-                isFontMedium: true,
-                textColor: ColorConstants.textYellowFFBB1B,
-                fontSize: 14,
-                marginLeft: 5,
-                marginRight: 5,
-                textDecoration: TextDecoration.underline,
-                decorationColor: ColorConstants.textYellowFFBB1B,
-                // 可选,设置下划线的颜色
-                decorationThickness: 2.0,
-                // 可选,设置下划线的粗细
-                decorationStyle: TextDecorationStyle.solid,
-                onClick: onMemberAction,
-              ).expanded(),
-
-              //是否选中
-              Visibility(
-                visible: item.status == 3,
-                child: MyAssetImage(
-                  item.isSelected ? Assets.baseServiceItemSelectedIcon : Assets.baseServiceItemUnselectedIcon,
-                  width: 20.5,
-                  height: 20.5,
-                ),
-              ),
-            ],
-          ),
-
-          // 工作开始时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Start Time:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.startTime ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 门卫签到时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Security In:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.securityIn?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.securityIn?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 工作地签到时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Work In:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.workIn?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.workIn?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          //工作结束时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "End Time:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.endTime ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 工作地签出时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Work Out:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.workOut?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.workOut?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 门卫签出时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Security Out:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //时间
-              MyTextView(
-                item.securityOut?.time ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: item.securityOut?.changed == 1 ? ColorConstants.textRedFF6262 : Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // + - Hours
-          Visibility(
-            visible: jobInfo?.jobUnit == "hour",
-            child: Row(
-              mainAxisSize: MainAxisSize.max,
-              crossAxisAlignment: CrossAxisAlignment.center,
-              children: [
-                MyTextView(
-                  "+/- Hours:".tr,
-                  isFontRegular: true,
-                  textColor: ColorConstants.textGrayAECAE5,
-                  fontSize: 14,
-                ),
-
-                //小时
-                MyTextView(
-                  Utils.isNotEmpty(item.adjustShow) ? item.adjustShow! : "0",
-                  marginLeft: 5,
-                  isFontRegular: true,
-                  textColor: Colors.white,
-                  fontSize: 14,
-                ).expanded(),
-              ],
-            ).marginOnly(top: 12),
-          ),
-
-          // Total Hours
-          Visibility(
-            visible: jobInfo?.jobUnit == "hour",
-            child: Row(
-              mainAxisSize: MainAxisSize.max,
-              crossAxisAlignment: CrossAxisAlignment.center,
-              children: [
-                MyTextView(
-                  "Total Hours:".tr,
-                  isFontRegular: true,
-                  textColor: ColorConstants.textGrayAECAE5,
-                  fontSize: 14,
-                ),
-
-                //小时
-                MyTextView(
-                  item.totalShow.toString(),
-                  marginLeft: 5,
-                  isFontRegular: true,
-                  textColor: Colors.white,
-                  fontSize: 14,
-                ).expanded(),
-              ],
-            ).marginOnly(top: 12),
-          ),
-
-          // Total Rooms
-          Visibility(
-            visible: jobInfo?.jobUnit != "hour",
-            child: Row(
-              mainAxisSize: MainAxisSize.max,
-              crossAxisAlignment: CrossAxisAlignment.center,
-              children: [
-                MyTextView(
-                  "Total Rooms:".tr,
-                  isFontRegular: true,
-                  textColor: ColorConstants.textGrayAECAE5,
-                  fontSize: 14,
-                ),
-
-                //小时
-                MyTextView(
-                  item.totalRooms.toString(),
-                  marginLeft: 5,
-                  isFontRegular: true,
-                  textColor: Colors.white,
-                  fontSize: 14,
-                ).expanded(),
-              ],
-            ).marginOnly(top: 12),
-          ),
-
-          // 申请时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Applied At:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //发布状态
-              MyTextView(
-                item.appliedAt ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          // 状态
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Status:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //发布状态
-              MyTextView(
-                item.statusShow ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: "Completed" == item.statusShow
-                    ? ColorConstants.textGreen05DC82
-                    : "Cancelled" == item.statusShow || "Rejected" == item.statusShow
-                        ? ColorConstants.textRedFF6262
-                        : "Revised" == item.statusShow || "Pending" == item.statusShow || "Approve" == item.statusShow
-                            ? ColorConstants.textYellowFFBB1B
-                            : ColorConstants.textBlue06D9FF,  //默认蓝色
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 12),
-
-          //按钮组
-          Visibility(
-            visible: item.actionList?.isNotEmpty ?? false,
-            child: Row(
-              mainAxisSize: MainAxisSize.max,
-              mainAxisAlignment: MainAxisAlignment.end,
-              crossAxisAlignment: CrossAxisAlignment.center,
-              children: [
-                //编辑按钮
-                Visibility(
-                  visible: item.actionList?.contains("edit") ?? false,
-                  child: MyButton(
-                    onPressed: () {
-                      FocusScope.of(context).unfocus();
-                      onEditAction?.call();
-                    },
-                    text: "Edit".tr,
-                    textColor: ColorConstants.white,
-                    backgroundColor: hexToColor(
-                      "#FFBB1B",
-                    ),
-                    radius: 17.25,
-                    minWidth: 60,
-                    minHeight: 35,
-                  ).marginOnly(left: 12),
-                ),
-
-                //状态工作流按钮
-                Visibility(
-                  visible: item.actionList?.contains("status") ?? false,
-                  child: MyButton(
-                    onPressed: () {
-                      FocusScope.of(context).unfocus();
-                      onStatusAction?.call();
-                    },
-                    text: "Status".tr,
-                    textColor: ColorConstants.white,
-                    backgroundColor: hexToColor("#0AC074"),
-                    radius: 17.25,
-                    minWidth: 60,
-                    minHeight: 35,
-                  ).marginOnly(left: 12),
-                ),
-
-                //Remark按钮
-                Visibility(
-                  visible: item.actionList?.contains("remarks") ?? false,
-                  child: MyButton(
-                    onPressed: () {
-                      FocusScope.of(context).unfocus();
-                      onRemarkAction?.call();
-                    },
-                    text: "Remarks".tr,
-                    textColor: ColorConstants.white,
-                    backgroundColor: hexToColor("#56AAFF"),
-                    radius: 17.25,
-                    minWidth: 60,
-                    minHeight: 35,
-                  ).marginOnly(left: 12),
-                ),
-              ],
-            ).marginOnly(top: 15),
-          ),
-        ],
-      ).onTap(() {
-        onItemAction?.call();
-      }),
-    );
-  }
-}

+ 0 - 398
packages/cpt_th/lib/modules/job/job_applied/job_applied_controller.dart

@@ -1,398 +0,0 @@
-
-import 'package:domain/entity/response/job_list_applied_staff_list_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/constants/app_constant.dart';
-import 'package:plugin_platform/engine/dialog/dialog_engine.dart';
-import 'package:plugin_platform/engine/notify/notify_engine.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:shared/utils/event_bus.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/dialog/app_default_dialog.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/widget_export.dart';
-
-import '../applied_staff_detail/applied_staff_detail_page.dart';
-import '../applied_workflow/applied_workflow_page.dart';
-import '../job_applied_edit/job_applied_edit_page.dart';
-import '../widget/applied_add_staff.dart';
-import '../widget/applied_butch_modify.dart';
-import '../widget/applied_staff_reviews.dart';
-import 'job_applied_state.dart';
-
-class JobAppliedController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final JobAppliedState state = JobAppliedState();
-
-  var _curPage = 1;
-  var _needShowPlaceholder = true;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: true,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    _curPage = 1;
-    fetchAppliedStaffList();
-  }
-
-  // Refresh 加载事件
-  Future loadMore() async {
-    _curPage++;
-    fetchAppliedStaffList();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _curPage = 1;
-    _needShowPlaceholder = true;
-    fetchAppliedStaffList();
-  }
-
-  /// 获取服务器数据,通知消息列表
-  Future fetchAppliedStaffList() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    }
-
-    if (state.jobInfo == null) {
-      //不是并发的,顺序执行接口
-      var jobInfoResult = await _jobRepository.fetchJobAppliedInfo(
-        state.jobId,
-        cancelToken: cancelToken,
-      );
-
-      if (jobInfoResult.isSuccess) {
-        state.jobInfo = jobInfoResult.data;
-        update();
-      } else {
-        errorMessage = jobInfoResult.errorMsg;
-        changeLoadingState(LoadState.State_Error);
-        return;
-      }
-    }
-
-    // 获取 Applied 列表
-    var listResult = await _jobRepository.fetchJobAppliedStaffs(
-      state.jobId,
-      state.keyword,
-      curPage: _curPage,
-      cancelToken: cancelToken,
-    );
-
-    // 处理数据
-    if (listResult.isSuccess) {
-      handleList(listResult.data?.rows);
-    } else {
-      errorMessage = listResult.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-    }
-
-    // 最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<JobListAppliedStaffListRows>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      if (_curPage == 1) {
-        //刷新的方式
-        state.datas.clear();
-        state.datas.addAll(list);
-        refreshController.finishRefresh();
-
-        //更新展示的状态
-        changeLoadingState(LoadState.State_Success);
-      } else {
-        //加载更多
-        state.datas.addAll(list);
-        refreshController.finishLoad();
-        update();
-      }
-    } else {
-      if (_curPage == 1) {
-        //展示无数据的布局
-        state.datas.clear();
-        changeLoadingState(LoadState.State_Empty);
-        refreshController.finishRefresh();
-      } else {
-        //展示加载完成,没有更多数据了
-        refreshController.finishLoad(IndicatorResult.noMore);
-      }
-    }
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchAppliedStaffList();
-    registerEventBus();
-  }
-
-  @override
-  void onClose() {
-    unregisterEventBus();
-    state.datas.clear();
-    super.onClose();
-  }
-
-  // EventBus 的事件接收
-  Subscription? subscribe;
-
-  void registerEventBus() {
-    subscribe = bus.on(AppConstant.eventAppliedListRefresh, (arg) {
-      var appliedId = arg as String;
-      if (Utils.isNotEmpty(appliedId)) {
-        fetchItemByIdAndRefreshItem(appliedId);
-      } else {
-        refreshController.callRefresh();
-      }
-    });
-  }
-
-  void unregisterEventBus() {
-    bus.off(AppConstant.eventAppliedListRefresh, subscribe);
-  }
-
-  /// 搜索员工
-  void doSearch(String keyword) {
-    state.keyword = keyword;
-    //赋值之后刷新
-    refreshController.callRefresh();
-  }
-
-  /// 清空筛选条件
-  void resetFiltering() {
-    state.keyword = "";
-    state.searchController.text = "";
-    //赋值之后刷新
-    refreshController.callRefresh();
-  }
-
-  /// 展示添加员工的弹窗
-  void showAddStaffDialog() {
-    DialogEngine.show(
-      widget: AppliedAddStaff(
-        jobId: state.jobId!,
-        confirmAction: (selectedIds) {
-          //调用接口添加员工
-          _requestAddStaff2Applied(selectedIds);
-        },
-      ),
-    );
-  }
-
-  //调用接口添加员工
-  void _requestAddStaff2Applied(String selectedIds) async {
-    var result = await _jobRepository.addStaff2Job(state.jobId, selectedIds, cancelToken: cancelToken);
-
-    if (result.isSuccess) {
-      var addStaffEntity = result.data;
-      List<String> filteredMessages = [];
-      if (addStaffEntity != null && addStaffEntity.resultList?.isNotEmpty == true) {
-        filteredMessages = addStaffEntity.resultList!
-            .where((resultList) => resultList.result == false && Utils.isNotEmpty(resultList.msg))
-            .map((resultList) => '${resultList.name} : ${resultList.msg!}')
-            .toList();
-      }
-
-      if (filteredMessages.isNotEmpty) {
-        //有错误信息
-        NotifyEngine.showFailure(filteredMessages.join(" , "));
-      } else {
-        //无错误信息
-        NotifyEngine.showSuccess("Successful".tr);
-        //添加成功之后刷新页面
-        refreshController.callRefresh();
-      }
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-      return;
-    }
-  }
-
-  /// 去编辑员工信息页面
-  void gotoAppliedEditPage(JobListAppliedStaffListRows data) {
-    JobAppliedEditPage.startInstance(data.appliedId.toString());
-  }
-
-  /// 展示评论的弹窗
-  void showRemarkDialog(JobListAppliedStaffListRows data) async {
-    //请求接口获取到已评论的数据
-    var result = await _jobRepository.fetchAppliedStaffReviewView(data.appliedId.toString());
-
-    if (result.isSuccess) {
-      //接口数据获取成功,展示弹窗
-      DialogEngine.show(
-        widget: AppliedStaffReviews(
-          appliedReviews: result.data!,
-          confirmAction: (attitudeRate, performanceRate, experienceRate, groomingRate, content) async {
-            //请求接口,提交评论
-            var submitResult = await _jobRepository.remarkAppliedSingleStaffSubmit(
-              data.appliedId.toString(),
-              attitudeRate,
-              groomingRate,
-              performanceRate,
-              experienceRate,
-              content,
-            );
-
-            if (submitResult.isSuccess) {
-              NotifyEngine.showSuccess("Successful".tr);
-            } else {
-              ToastEngine.show(submitResult.errorMsg ?? "Network Load Error".tr);
-            }
-          },
-        ),
-      );
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-      return;
-    }
-  }
-
-  /// 去展示员工状态的审核流程页面
-  void gotoAppliedWorkflowPage(JobListAppliedStaffListRows data) {
-    AppliedWorkflowPage.startInstance(data.appliedId.toString());
-  }
-
-  /// 去查看员工详情页面
-  void gotoStaffDetailPage(JobListAppliedStaffListRows data) {
-    AppliedStaffDetailPage.startInstance(data.memberId.toString());
-  }
-
-  /// Item选中与未选中设置
-  void doSelectedOrNot(JobListAppliedStaffListRows data) {
-    //只有 Approve = 3 的状态才能选中
-    if (data.status == 3) {
-      data.isSelected = !data.isSelected;
-      update();
-    }
-  }
-
-  /// 批量修改的弹窗
-  void showBatchModifyDialog() async {
-    if (state.jobInfo == null) return;
-    //找出已经选中的员工(只有状态为3 Approve的状态才能修改)
-    var selectedList = state.datas.where((element) => element.isSelected && element.status == 3).toList(growable: false);
-    if (selectedList.isNotEmpty) {
-      var ids = selectedList.map((e) => e.appliedId.toString()).toList(growable: false);
-      var separatedIds = ids.join(',');
-
-      DialogEngine.show(
-          widget: AppliedButchModify(
-              selectedStartDate: DateTimeUtils.getDateTime(state.jobInfo?.startTime ?? ""),
-              selectedEndDate: DateTimeUtils.getDateTime(state.jobInfo?.endTime ?? ""),
-              confirmAction: (start, end) {
-                _requestBatchModify(start, end, separatedIds);
-              }));
-    } else {
-      ToastEngine.show("Please select the applied record".tr);
-    }
-  }
-
-  /// 执行批量修改的请求
-  void _requestBatchModify(DateTime start, DateTime end, String separatedIds) async {
-    //执行请求
-    var result = await _jobRepository.batchEditStaffCheckTime(
-      state.jobId,
-      separatedIds,
-      DateTimeUtils.formatDate(start),
-      DateTimeUtils.formatDate(end),
-      cancelToken: cancelToken,
-    );
-
-    if (result.isSuccess) {
-      NotifyEngine.showSuccess("Successful".tr);
-
-      //调用接口刷新指定的Staff的信息
-      fetchItemByIdAndRefreshItem(separatedIds);
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-      return;
-    }
-  }
-
-  /// 批准的操作
-  void operationApprove() async {
-    //找出已经选中的员工(只有状态为3 Approve的状态才能修改)
-    var selectedList = state.datas.where((element) => element.isSelected && element.status == 3).toList(growable: false);
-    if (selectedList.isNotEmpty) {
-      var ids = selectedList.map((e) => e.appliedId.toString()).toList(growable: false);
-      var separatedIds = ids.join(',');
-
-      // Are you sure 的弹窗
-      DialogEngine.show(
-        widget: AppDefaultDialog(
-          title: "Message".tr,
-          message: "Are you sure you want to setting approved?".tr,
-          confirmAction: () async {
-            //执行请求
-            var result = await _jobRepository.submitBatchStaffApprove(separatedIds, cancelToken: cancelToken);
-
-            if (result.isSuccess) {
-              NotifyEngine.showSuccess("Successful".tr);
-
-              //调用接口刷新指定的Staff的信息
-              fetchItemByIdAndRefreshItem(separatedIds);
-            } else {
-              ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-              return;
-            }
-          },
-        ),
-      );
-    } else {
-      ToastEngine.show("Please select the applied record".tr);
-    }
-  }
-
-  /// 根据ID获取Item对象,用于刷新
-  void fetchItemByIdAndRefreshItem(String appliedIds) async {
-    var result = await _jobRepository.fetchItemByAppliedIds(
-      state.jobId,
-      appliedIds,
-      cancelToken: cancelToken,
-    );
-
-    //处理数据
-    if (result.isSuccess) {
-      var data = result.data;
-      if (data != null && data.rows != null && data.rows!.isNotEmpty) {
-        List<JobListAppliedStaffListRows> newItem = data.rows!;
-
-        // 创建一个 Map 来加速查找
-        Map<int, JobListAppliedStaffListRows> newItemMap = {for (var item in newItem) item.appliedId: item};
-
-        // 遍历 state.datas 进行替换
-        for (int i = 0; i < state.datas.length; i++) {
-          if (newItemMap.containsKey(state.datas[i].appliedId)) {
-            state.datas[i] = newItemMap[state.datas[i].appliedId]!;
-          }
-        }
-
-        //刷新
-        update();
-      }
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-    }
-  }
-
-}

+ 0 - 210
packages/cpt_th/lib/modules/job/job_applied/job_applied_page.dart

@@ -1,210 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:get/get.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/search_app_bar.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'applied_staff_item.dart';
-import 'job_applied_controller.dart';
-
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/my_appbar.dart';
-import 'job_applied_state.dart';
-
-/**
- * 已申请的页面,可以签到签出、加人、修改状态、评论等操作
- */
-class JobAppliedPage extends BaseStatefulPage<JobAppliedController> {
-  JobAppliedPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance(String? jobId) {
-    return Get.start(RouterPath.jobAppliedStaffList, arguments: {'jobId': jobId});
-  }
-
-  @override
-  JobAppliedController createRawController() {
-    return JobAppliedController();
-  }
-
-  @override
-  State<JobAppliedPage> createState() => _JobAppliedState();
-}
-
-class _JobAppliedState extends BaseState<JobAppliedPage, JobAppliedController> {
-  late JobAppliedState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-    state.jobId = Get.arguments['jobId'];
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return  SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top: ScreenUtil.getStatusBarH(context)),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Column(
-              children: [
-                MyAppBar.titleBar(
-                  context,
-                  state.jobInfo?.jobTitle ?? "Title".tr,
-                  subTitle: "(${state.jobInfo?.jobDate ?? "-"})",
-                  subTitleColor: ColorConstants.textGrayAECAE5,
-                ),
-
-                //搜索的条件
-                Row(
-                  children: [
-                    SearchAppBar(
-                      value: state.keyword,
-                      onSearch: (keyword) {
-                        controller.doSearch(keyword);
-                      },
-                      hintText: "Staff Name".tr,
-                      controller: state.searchController,
-                    ).expanded(),
-                    MyButton(
-                      onPressed: () {
-                        FocusScope.of(context).unfocus();
-                        controller.resetFiltering();
-                      },
-                      text: "Reset".tr,
-                      textColor: ColorConstants.white,
-                      backgroundColor: hexToColor("#2BA9F9", opacity: 0.5),
-                      radius: 20,
-                      minWidth: 60,
-                      minHeight: 35,
-                    ),
-                  ],
-                ).marginOnly(top: 10, left: 15, right: 15, bottom: 5),
-
-                // 添加按钮
-                Visibility(
-                  visible: state.jobInfo?.canAppend == true,
-                  child: MyButton(
-                    type: ClickType.throttle,
-                    milliseconds: 500,
-                    onPressed: () {
-                      FocusScope.of(context).unfocus();
-                      controller.showAddStaffDialog();
-                    },
-                    text: "Add Staff".tr,
-                    textColor: ColorConstants.white,
-                    fontSize: 16,
-                    radius: 20,
-                    backgroundColor: hexToColor("#FFBB1B"),
-                    fontWeight: FontWeight.w500,
-                  ).marginOnly(left: 15, right: 15, top: 5, bottom: 10),
-                ),
-
-                //底部的列表
-                EasyRefresh(
-                  controller: controller.refreshController,
-                  onRefresh: controller.onRefresh,
-                  onLoad: controller.loadMore,
-                  child: LoadStateLayout(
-                    state: controller.loadingState,
-                    errorMessage: controller.errorMessage,
-                    errorRetry: () {
-                      controller.retryRequest();
-                    },
-                    successSliverWidget: [
-                      SliverList(
-                          delegate: SliverChildBuilderDelegate(
-                        (context, index) {
-                          return AppliedStaffItem(
-                            index: index,
-                            jobInfo: state.jobInfo,
-                            item: state.datas[index],
-                            onEditAction: () {
-                              controller.gotoAppliedEditPage(state.datas[index]);
-                            },
-                            onRemarkAction: () {
-                              controller.showRemarkDialog(state.datas[index]);
-                            },
-                            onStatusAction: () {
-                              controller.gotoAppliedWorkflowPage(state.datas[index]);
-                            },
-                            onItemAction: () {
-                              controller.doSelectedOrNot(state.datas[index]);
-                            },
-                            onMemberAction: (){
-                              controller.gotoStaffDetailPage(state.datas[index]);
-                            },
-                          );
-                        },
-                        childCount: state.datas.length,
-                      ))
-                    ],
-                  ),
-                ).expanded(),
-
-                Row(
-                  mainAxisSize: MainAxisSize.max,
-                  children: [
-                    //批量Approve
-                    MyTextView(
-                      "Operation Approve".tr,
-                      fontSize: 17,
-                      isFontMedium: true,
-                      boxHeight: 48,
-                      onClick: () {
-                        controller.operationApprove();
-                      },
-                      alignment: Alignment.center,
-                      textAlign: TextAlign.center,
-                      textColor: Colors.white,
-                      backgroundColor: Color(0XFF0AC074),
-                    ).expanded(),
-
-                    //批量修改时间
-                    MyTextView(
-                      "Batch Modify".tr,
-                      fontSize: 17,
-                      isFontMedium: true,
-                      boxHeight: 48,
-                      onClick: () {
-                        controller.showBatchModifyDialog();
-                      },
-                      alignment: Alignment.center,
-                      textAlign: TextAlign.center,
-                      textColor: Colors.white,
-                      backgroundColor: Color(0XFFFFBB1B),
-                    ).expanded(),
-                  ],
-                ),
-              ],
-            ),
-          ),
-        );
-    });
-  }
-}

+ 0 - 14
packages/cpt_th/lib/modules/job/job_applied/job_applied_state.dart

@@ -1,14 +0,0 @@
-import 'package:domain/entity/response/job_list_applied_info_entity.dart';
-import 'package:domain/entity/response/job_list_applied_staff_list_entity.dart';
-import 'package:flutter/material.dart';
-
-class JobAppliedState {
-  //筛选条件
-  final TextEditingController searchController = TextEditingController();
-  String keyword = "";
-
-  String? jobId;
-  JobListAppliedInfoEntity? jobInfo; //指定工作的简短信息
-
-  List<JobListAppliedStaffListRows> datas = []; //Applied的员工列表
-}

+ 0 - 178
packages/cpt_th/lib/modules/job/job_applied_edit/job_applied_edit_controller.dart

@@ -1,178 +0,0 @@
-import 'package:domain/repository/job_repository.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/constants/app_constant.dart';
-import 'package:plugin_platform/engine/notify/notify_engine.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:shared/utils/event_bus.dart';
-import 'package:widgets/picker/date_picker_util.dart';
-
-import 'job_applied_edit_state.dart';
-
-class JobAppliedEditController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final JobAppliedEditState state = JobAppliedEditState();
-
-  // 获取编辑的详情
-  void fetchAppliedEditView() async {
-    var result = await _jobRepository.fetchAppliedEditView(state.appliedId, cancelToken: cancelToken);
-
-    if (result.isSuccess) {
-      state.appliedEditView = result.data;
-
-      var addHourController = state.formData['add_hours']!['controller'];
-      var totalRoomController = state.formData['total_room']!['controller'];
-      var reasonController = state.formData['reason']!['controller'];
-
-      addHourController.text = state.appliedEditView?.adjustHours ?? "0";
-      totalRoomController.text = state.appliedEditView?.totalRooms.toString();
-      reasonController.text = state.appliedEditView?.coReason ?? "";
-
-      update();
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-      return;
-    }
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchAppliedEditView();
-  }
-
-  /// 选择时间
-  void pickStartTime() {
-    if (state.appliedEditView == null) return;
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: DateTimeUtils.getDateTime(state.appliedEditView!.startTime ?? ""),
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.appliedEditView!.startTime = DateTimeUtils.formatDate(date);
-        update();
-      },
-      title: "Start Time".tr,
-    );
-  }
-
-  /// 选择时间
-  void pickEndTime() {
-    if (state.appliedEditView == null) return;
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: DateTimeUtils.getDateTime(state.appliedEditView!.endTime ?? ""),
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.appliedEditView!.endTime = DateTimeUtils.formatDate(date);
-        update();
-      },
-      title: "End Time".tr,
-    );
-  }
-
-  /// 选择时间
-  void pickSecurityInTime() {
-    if (state.appliedEditView == null) return;
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: DateTimeUtils.getDateTime(state.appliedEditView!.securityIn ?? ""),
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.appliedEditView!.securityIn = DateTimeUtils.formatDate(date);
-        update();
-      },
-      title: "Security In".tr,
-    );
-  }
-
-  /// 选择时间
-  void pickSecurityOutTime() {
-    if (state.appliedEditView == null) return;
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: DateTimeUtils.getDateTime(state.appliedEditView!.securityOut ?? ""),
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.appliedEditView!.securityOut = DateTimeUtils.formatDate(date);
-        update();
-      },
-      title: "Security Out".tr,
-    );
-  }
-
-  /// 选择时间
-  void pickWorkInTime() {
-    if (state.appliedEditView == null) return;
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: DateTimeUtils.getDateTime(state.appliedEditView!.workIn ?? ""),
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.appliedEditView!.workIn = DateTimeUtils.formatDate(date);
-        update();
-      },
-      title: "Work In".tr,
-    );
-  }
-
-  /// 选择时间
-  void pickWorkOutTime() {
-    if (state.appliedEditView == null) return;
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: DateTimeUtils.getDateTime(state.appliedEditView!.workOut ?? ""),
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.appliedEditView!.workOut = DateTimeUtils.formatDate(date);
-        update();
-      },
-      title: "Work Out".tr,
-    );
-  }
-
-  /// 提交修改
-  void doSubmit() async {
-    if (state.appliedEditView == null) return;
-
-    //输入框的数据赋值
-    TextEditingController totalRoomController = state.formData['total_room']!['controller'];
-    TextEditingController addHourController = state.formData['add_hours']!['controller'];
-    TextEditingController reasonController = state.formData['reason']!['controller'];
-    // 获取文本并尝试转换为整数
-    String totalRoomText = totalRoomController.text;
-    if (totalRoomText.isNotEmpty) {
-      try {
-        // 尝试将文本转换为整数
-        int totalRooms = int.parse(totalRoomText);
-        // 赋值给 state.appliedEditView!.totalRooms
-        state.appliedEditView!.totalRooms = totalRooms;
-      } catch (e) {
-        // 如果转换失败,可以进行错误处理
-        print('Error parsing totalRooms: $e');
-      }
-    } else {
-      // 文本为空时的处理逻辑,例如设置默认值或提示用户
-      print('Total rooms input is empty');
-    }
-
-    state.appliedEditView!.adjustHours = addHourController.text.toString();
-    state.appliedEditView!.coReason = reasonController.text.toString();
-
-    //请求网络提交修改
-    var result = await _jobRepository.editAppliedSingleStaffInfo(state.appliedId, state.appliedEditView!);
-
-    if (result.isSuccess) {
-      NotifyEngine.showSuccess("Successful".tr);
-
-      bus.emit(AppConstant.eventAppliedListRefresh, state.appliedId);
-
-      Get.back();
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-      return;
-    }
-  }
-}

+ 0 - 515
packages/cpt_th/lib/modules/job/job_applied_edit/job_applied_edit_page.dart

@@ -1,515 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/services.dart';
-import 'package:get/get.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/no_shadow_scroll_behavior.dart';
-import 'package:widgets/shatter/custom_radio_check.dart';
-import 'package:widgets/shatter/form_require_text.dart';
-import 'package:widgets/shatter/round_my_text_field.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'job_applied_edit_controller.dart';
-
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/my_appbar.dart';
-
-import 'job_applied_edit_state.dart';
-
-/**
- * Applied列表中,编辑用户的此次工作打卡信息
- */
-class JobAppliedEditPage extends BaseStatefulPage<JobAppliedEditController> {
-  JobAppliedEditPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance(String? appliedId) {
-    return Get.start(RouterPath.jobAppliedStaffEdit, arguments: {'appliedId': appliedId});
-  }
-
-  @override
-  JobAppliedEditController createRawController() {
-    return JobAppliedEditController();
-  }
-
-  @override
-  State<JobAppliedEditPage> createState() => _JobAppliedEditState();
-}
-
-class _JobAppliedEditState extends BaseState<JobAppliedEditPage, JobAppliedEditController> {
-  late JobAppliedEditState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-    state.appliedId = Get.arguments['appliedId'];
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return Scaffold(
-        extendBodyBehindAppBar: true,
-        appBar: MyAppBar.appBar(context, "Edit".tr),
-        body: SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top: kToolbarHeight + ScreenUtil.getStatusBarH(context) + 1),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Scrollbar(
-              child: ScrollConfiguration(
-                behavior: NoShadowScrollBehavior(),
-                child: SingleChildScrollView(
-                  scrollDirection: Axis.vertical,
-                  physics: const BouncingScrollPhysics(),
-                  child: Column(
-                    crossAxisAlignment: CrossAxisAlignment.start,
-                    children: [
-                      //工作标题,选择模板
-                      MyTextView(
-                        "Staff Name".tr,
-                        textColor: Colors.white,
-                        fontSize: 15,
-                        marginTop: 15,
-                        isFontRegular: true,
-                      ),
-
-                      //工作标题
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.5),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.appliedEditView?.memberName ?? "-",
-                              fontSize: 15,
-                              hint: "Choose Job Title".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                          ],
-                        ),
-                      ),
-
-                      //开始时间
-                      FormRequireText(
-                        text: "Start Time".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.appliedEditView?.startTime ?? "-",
-                              fontSize: 14,
-                              hint: "Job Start Time".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickStartTime();
-                      }),
-
-                      //门卫签到时间
-                      MyTextView(
-                        "Security In".tr,
-                        textColor: Colors.white,
-                        fontSize: 15,
-                        marginTop: 15,
-                        isFontRegular: true,
-                      ),
-
-                      //门卫签到时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.appliedEditView?.securityIn ?? "-",
-                              fontSize: 14,
-                              hint: "Security In".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickSecurityInTime();
-                      }),
-
-                      //工作地签到时间
-                      MyTextView(
-                        "Work In".tr,
-                        textColor: Colors.white,
-                        fontSize: 15,
-                        marginTop: 15,
-                        isFontRegular: true,
-                      ),
-
-                      //工作地签到时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.appliedEditView?.workIn ?? "-",
-                              fontSize: 14,
-                              hint: "Work In".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickWorkInTime();
-                      }),
-
-                      //结束时间
-                      FormRequireText(
-                        text: "End Time".tr,
-                      ).marginOnly(top: 15),
-
-                      //结束时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.appliedEditView?.endTime ?? "-",
-                              fontSize: 14,
-                              hint: "Job End Time".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-
-                            //下拉选图标
-                            MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickEndTime();
-                      }),
-
-                      //门卫签出时间
-                      MyTextView(
-                        "Security Out".tr,
-                        textColor: Colors.white,
-                        fontSize: 15,
-                        marginTop: 15,
-                        isFontRegular: true,
-                      ),
-
-                      //门卫签出时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.appliedEditView?.securityOut ?? "-",
-                              fontSize: 14,
-                              hint: "Security Out".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickSecurityOutTime();
-                      }),
-
-                      //工作地签出时间
-                      MyTextView(
-                        "Work Out".tr,
-                        textColor: Colors.white,
-                        fontSize: 15,
-                        marginTop: 15,
-                        isFontRegular: true,
-                      ),
-
-                      //工作地签出时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.appliedEditView?.workOut ?? "-",
-                              fontSize: 14,
-                              hint: "Work Out".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickWorkOutTime();
-                      }),
-
-                      // + - 小时
-                      Visibility(
-                        visible: state.appliedEditView?.jobUnit == "hour",
-                        child: MyTextView(
-                          "+/- Hours".tr,
-                          textColor: Colors.white,
-                          fontSize: 15,
-                          marginTop: 15,
-                          isFontRegular: true,
-                        ),
-                      ),
-
-                      //+ - 小时输入框
-                      Visibility(
-                        visible: state.appliedEditView?.jobUnit == "hour",
-                        child: CustomTextField(
-                          formKey: "add_hours",
-                          marginLeft: 0,
-                          marginRight: 0,
-                          paddingTop: 0,
-                          paddingBottom: 0,
-                          height: 45,
-                          fillBackgroundColor: Color(0xFF4DCFF6).withOpacity(0.2),
-                          enabled: true,
-                          textInputType: TextInputType.number,
-                          formData: state.formData,
-                          textInputAction: TextInputAction.done,
-                          onSubmit: (key, value) {
-                            FocusScope.of(context).unfocus();
-                          },
-                          marginTop: 10,
-                        ),
-                      ),
-
-                      // 房间计费,房间数量
-                      Visibility(
-                        visible: state.appliedEditView?.jobUnit != "hour",
-                        child: MyTextView(
-                          "Total Rooms".tr,
-                          textColor: Colors.white,
-                          fontSize: 15,
-                          marginTop: 15,
-                          isFontRegular: true,
-                        ),
-                      ),
-
-                      // 房间计费,房间数量输入框
-                      Visibility(
-                        visible: state.appliedEditView?.jobUnit != "hour",
-                        child: CustomTextField(
-                          formKey: "total_room",
-                          marginLeft: 0,
-                          marginRight: 0,
-                          paddingTop: 0,
-                          paddingBottom: 0,
-                          height: 45,
-                          fillBackgroundColor: Color(0xFF4DCFF6).withOpacity(0.2),
-                          enabled: true,
-                          inputFormatters: <TextInputFormatter>[FilteringTextInputFormatter.digitsOnly],
-                          textInputType: TextInputType.number,
-                          formData: state.formData,
-                          textInputAction: TextInputAction.done,
-                          onSubmit: (key, value) {
-                            FocusScope.of(context).unfocus();
-                          },
-                          marginTop: 10,
-                        ),
-                      ),
-
-                      // 修改的理由
-                      MyTextView(
-                        "Reason".tr,
-                        textColor: Colors.white,
-                        fontSize: 15,
-                        marginTop: 15,
-                        isFontRegular: true,
-                      ),
-
-                      //理由的单选
-                      state.appliedEditView != null
-                          ? CustomRadioCheck(
-                              options: state.appliedEditView!.reasonList!.map((e) => e.txt).whereType<String>().toList(), //后台返回的数据展示,并且根据后台的数据匹配索引
-                              selectedPosition: state.appliedEditView!.reasonList!.indexWhere((element) => element.value == state.appliedEditView!.reasonType),
-                              onOptionSelected: (index, text) {
-                                //修改内存的值
-                                state.appliedEditView!.reasonType = state.appliedEditView!.reasonList![index].value;
-                              },
-                            ).marginOnly(top: 15, bottom: 20)
-                          : CircularProgressIndicator(),
-
-                      IgnoreKeyboardDismiss(
-                        child: Container(
-                          height: 130,
-                          padding: EdgeInsets.symmetric(vertical: 15, horizontal: 15),
-                          decoration: BoxDecoration(
-                            color: Color(0xFF4DCFF6).withOpacity(0.2),
-                            borderRadius: const BorderRadius.all(Radius.circular(5)),
-                          ),
-                          child: TextField(
-                            cursorColor: ColorConstants.white,
-                            cursorWidth: 1.5,
-                            autofocus: false,
-                            controller: state.formData["reason"]!['controller'],
-                            focusNode: state.formData["reason"]!['focusNode'],
-                            obscureText: state.formData["reason"]!['obsecure'],
-                            // 装饰
-                            decoration: InputDecoration(
-                              isDense: true,
-                              isCollapsed: true,
-                              border: InputBorder.none,
-                              hintText: state.formData["reason"]!['hintText'],
-                              hintStyle: TextStyle(
-                                color: ColorConstants.white,
-                                fontSize: 15.0,
-                                fontWeight: FontWeight.w400,
-                              ),
-                            ),
-                            style: TextStyle(
-                              color: ColorConstants.white,
-                              fontSize: 15.0,
-                              fontWeight: FontWeight.w400,
-                            ),
-                            // 键盘动作右下角图标
-                            textInputAction: TextInputAction.done,
-                            onSubmitted: (value) {
-                              FocusScope.of(context).unfocus();
-                            },
-                          ),
-                        ),
-                      ),
-
-                      //提交按钮
-                      MyButton(
-                        type: ClickType.throttle,
-                        milliseconds: 500,
-                        onPressed: () {
-                          FocusScope.of(context).unfocus();
-                          controller.doSubmit();
-                        },
-                        text: "Submit".tr,
-                        textColor: ColorConstants.white,
-                        fontSize: 16,
-                        radius: 22.5,
-                        backgroundColor: hexToColor("#FFBB1B"),
-                        fontWeight: FontWeight.w500,
-                      ).marginSymmetric(horizontal: 0, vertical: 30),
-                    ],
-                  ).paddingOnly(left: 15, right: 15),
-                ),
-              ),
-            ),
-          ),
-        ),
-      );
-    });
-  }
-}

+ 0 - 40
packages/cpt_th/lib/modules/job/job_applied_edit/job_applied_edit_state.dart

@@ -1,40 +0,0 @@
-import 'package:domain/entity/response/job_list_applied_edit_entity.dart';
-import 'package:flutter/material.dart';
-import 'package:plugin_basic/basic_export.dart';
-
-class JobAppliedEditState {
-  //表单的校验与数据
-  Map<String, Map<String, dynamic>> formData = {
-    'add_hours': {
-      'value': '',
-      'controller': TextEditingController(),
-      'focusNode': FocusNode(),
-      'hintText': '0',
-      'obsecure': false,
-    },
-    'total_room': {
-      'value': '',
-      'controller': TextEditingController(),
-      'focusNode': FocusNode(),
-      'hintText': '0',
-      'obsecure': false,
-    },
-    'reason': {
-      'value': '',
-      'controller': TextEditingController(),
-      'focusNode': FocusNode(),
-      'hintText': 'Enter...'.tr,
-      'obsecure': false,
-    },
-  };
-
-  JobListAppliedEditEntity? appliedEditView;
-
-  String? appliedId;
-
-  //功能选项
-  final editOption = ['None'.tr, 'Forgot to clock in/out'.tr, 'Technical issue'.tr, 'Others'.tr];
-
-  //选项默认选中索引为0
-  int editOptionPosition = 0;
-}

+ 0 - 204
packages/cpt_th/lib/modules/job/job_list/job_list_controller.dart

@@ -1,204 +0,0 @@
-import 'package:domain/entity/response/job_list_entity.dart';
-import 'package:domain/entity/response/job_list_index_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/engine/dialog/dialog_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:plugin_platform/http/http_result.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/widget_export.dart';
-
-import '../job_applied/job_applied_page.dart';
-import '../job_list_detail/job_list_detail_page.dart';
-import 'job_list_filter.dart';
-import 'job_list_state.dart';
-
-class JobListController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final JobListState state = JobListState();
-
-  var _curPage = 1;
-  var _needShowPlaceholder = true;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: true,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    _curPage = 1;
-    fetchNotifyList();
-  }
-
-  // Refresh 加载事件
-  Future loadMore() async {
-    _curPage++;
-    fetchNotifyList();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _curPage = 1;
-    _needShowPlaceholder = true;
-    fetchNotifyList();
-  }
-
-  /// 获取服务器数据,通知消息列表
-  Future fetchNotifyList() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    }
-
-    // 并发执行两个请求
-    var futures = [
-      _jobRepository.fetchJobListTable(
-        state.keyword,
-        DateTimeUtils.formatDate(state.selectedStartDate, format: "yyyy-MM-dd"),
-        DateTimeUtils.formatDate(state.selectedEndDate, format: "yyyy-MM-dd"),
-        state.selectedStatusId,
-        state.selectedDepartmentId,
-        curPage: _curPage,
-        cancelToken: cancelToken,
-      ),
-      state.indexOptions == null
-          ? _jobRepository.fetchJobListIndex(
-              cancelToken: cancelToken,
-            )
-          : Future(() => HttpResult(isSuccess: true).convert(data: state.indexOptions!)),
-    ];
-
-    //拿到结果
-    var results = await Future.wait(futures);
-    var listResult = results[0] as HttpResult<JobListEntity>;
-    var optionResult = results[1] as HttpResult<JobListIndexEntity>;
-
-    //选项数据
-    if (state.indexOptions == null && optionResult.isSuccess) {
-      state.indexOptions = optionResult.data!;
-    }
-
-    // 处理数据
-    if (listResult.isSuccess) {
-      handleList(listResult.data?.rows);
-    } else {
-      errorMessage = listResult.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-    }
-
-    // 最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<JobListRows>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      if (_curPage == 1) {
-        //刷新的方式
-        state.datas.clear();
-        state.datas.addAll(list);
-        refreshController.finishRefresh();
-
-        //更新展示的状态
-        changeLoadingState(LoadState.State_Success);
-      } else {
-        //加载更多
-        state.datas.addAll(list);
-        refreshController.finishLoad();
-        update();
-      }
-    } else {
-      if (_curPage == 1) {
-        //展示无数据的布局
-        state.datas.clear();
-        changeLoadingState(LoadState.State_Empty);
-        refreshController.finishRefresh();
-      } else {
-        //展示加载完成,没有更多数据了
-        refreshController.finishLoad(IndicatorResult.noMore);
-      }
-    }
-  }
-
-  // 执行搜索
-  void doSearch(String keyword) {
-    state.keyword = keyword;
-    //赋值之后刷新
-    refreshController.callRefresh();
-  }
-
-  // 清空搜索条件
-  void resetFiltering() {
-    state.keyword = "";
-    state.searchController.text = "";
-
-    state.selectedStartDate = null;
-    state.selectedEndDate = null;
-    state.selectedStatusId = null;
-    state.selectedDepartmentId = null;
-
-    //赋值之后刷新
-    refreshController.callRefresh();
-  }
-
-  //展示筛选的弹窗
-  void showFilterDialog() {
-    if (state.indexOptions != null) {
-      DialogEngine.show(
-        widget: JobListFilter(
-          optionResult: state.indexOptions!,
-          selectedStartDate: state.selectedStartDate,
-          selectedEndDate: state.selectedEndDate,
-          selectedStatusId: state.selectedStatusId,
-          selectedDepartmentId: state.selectedDepartmentId,
-          onFilterAction: (startDate, endDate, statusId, departmentId) {
-            state.selectedStartDate = startDate;
-            state.selectedEndDate = endDate;
-            state.selectedStatusId = statusId;
-            state.selectedDepartmentId = departmentId;
-
-            //赋值之后刷新
-            refreshController.callRefresh();
-          },
-        ),
-        position: DialogPosition.top,
-        animType: DialogAnimation.fade,
-      );
-    }
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchNotifyList();
-  }
-
-  @override
-  void onClose() {
-    state.datas.clear();
-    super.onClose();
-  }
-
-  /// 去详情页面
-  void gotoJobDetailPage(JobListRows data) {
-    JobListDetailPage.startInstance(data.jobId.toString());
-  }
-
-  /// 去已申请的成员列表
-  void gotoJobAppliedPage(JobListRows data) {
-    JobAppliedPage.startInstance(data.jobId.toString());
-  }
-}

+ 0 - 360
packages/cpt_th/lib/modules/job/job_list/job_list_filter.dart

@@ -1,360 +0,0 @@
-import 'dart:ui';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/job_list_index_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
-import 'package:get/get.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/picker/date_picker_util.dart';
-import 'package:widgets/picker/option_pick_util.dart';
-import 'package:widgets/widget_export.dart';
-
-/**
- * 用工请求列表的筛选
- */
-class JobListFilter extends StatefulWidget {
-  void Function(DateTime? selectedStartDate, DateTime? selectedEndDate, String? selectedStatusId, String? selectedDepartmentId)? onFilterAction;
-  JobListIndexEntity optionResult;
-  DateTime? selectedStartDate;
-  DateTime? selectedEndDate;
-  String? selectedStatusId;
-  String? selectedDepartmentId;
-
-  JobListFilter({
-    required this.optionResult,
-    required this.selectedStartDate,
-    required this.selectedEndDate,
-    required this.selectedStatusId,
-    required this.selectedDepartmentId,
-    this.onFilterAction,
-  });
-
-  @override
-  State<JobListFilter> createState() => _JobListFilterState();
-}
-
-class _JobListFilterState extends State<JobListFilter> {
-  DateTime? selectedStartDate;
-  DateTime? selectedEndDate;
-  String? selectedStatusId;
-  String? selectedDepartmentId;
-
-  @override
-  void initState() {
-    super.initState();
-    this.selectedStartDate = widget.selectedStartDate;
-    this.selectedEndDate = widget.selectedEndDate;
-    this.selectedStatusId = widget.selectedStatusId;
-    this.selectedDepartmentId = widget.selectedDepartmentId;
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return Column(
-      crossAxisAlignment: CrossAxisAlignment.start,
-      mainAxisAlignment: MainAxisAlignment.start,
-      children: [
-        SizedBox(
-          height: kToolbarHeight + ScreenUtil.getStatusBarH(context) + 1,
-        ),
-        Container(
-          padding: const EdgeInsets.only(left: 15, right: 15, top: 17.5, bottom: 20),
-          width: double.infinity,
-          decoration: const BoxDecoration(
-            color: Colors.white,
-          ),
-          child: Column(
-            crossAxisAlignment: CrossAxisAlignment.start,
-            children: [
-              //部门
-              MyTextView(
-                "Outlet".tr,
-                fontSize: 14,
-                isFontMedium: true,
-                textColor: ColorConstants.black33,
-              ),
-
-              //选择部门
-              Container(
-                padding: const EdgeInsets.only(left: 16, right: 10),
-                margin: const EdgeInsets.only(top: 10),
-                height: 45,
-                decoration: const BoxDecoration(
-                  color: ColorConstants.grayECECEC,
-                  borderRadius: BorderRadius.all(Radius.circular(5)),
-                ),
-                child: Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  mainAxisAlignment: MainAxisAlignment.start,
-                  children: [
-                    MyTextView(
-                      selectedDepartmentId == null || selectedDepartmentId == "0"
-                          ? ""
-                          : widget.optionResult.departmentList!.firstWhere((element) => element.value.toString() == selectedDepartmentId).txt!,
-                      hint: "Choose Outlet".tr,
-                      textHintColor: ColorConstants.textBlackHint,
-                      fontSize: 14,
-                      isFontMedium: true,
-                      textColor: ColorConstants.black33,
-                    ).expanded(),
-                    const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                  ],
-                ),
-              ).onTap(() {
-                pickerOutlet();
-              }),
-
-              //状态
-              MyTextView(
-                "Status".tr,
-                fontSize: 14,
-                isFontMedium: true,
-                marginTop: 11,
-                textColor: ColorConstants.black33,
-              ),
-
-              //选择状态
-              Container(
-                padding: const EdgeInsets.only(left: 16, right: 10),
-                margin: const EdgeInsets.only(top: 10),
-                height: 45,
-                decoration: const BoxDecoration(
-                  color: ColorConstants.grayECECEC,
-                  borderRadius: BorderRadius.all(Radius.circular(5)),
-                ),
-                child: Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  mainAxisAlignment: MainAxisAlignment.start,
-                  children: [
-                    MyTextView(
-                      selectedStatusId == null || selectedStatusId == "0"
-                          ? ""
-                          : widget.optionResult.statusList!.firstWhere((element) => element.value.toString() == selectedStatusId).txt!,
-                      fontSize: 14,
-                      hint: "Choose Status".tr,
-                      textHintColor: ColorConstants.textBlackHint,
-                      isFontMedium: true,
-                      textColor: ColorConstants.black33,
-                    ).expanded(),
-                    const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                  ],
-                ),
-              ).onTap(() {
-                pickerStatus();
-              }),
-
-              //开始时间
-              MyTextView(
-                "Start Date".tr,
-                fontSize: 14,
-                isFontMedium: true,
-                marginTop: 11,
-                textColor: ColorConstants.black33,
-              ),
-
-              //选择时间
-              Container(
-                padding: const EdgeInsets.only(left: 16, right: 10),
-                margin: const EdgeInsets.only(top: 10),
-                height: 45,
-                decoration: const BoxDecoration(
-                  color: ColorConstants.grayECECEC,
-                  borderRadius: BorderRadius.all(Radius.circular(5)),
-                ),
-                child: Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  mainAxisAlignment: MainAxisAlignment.start,
-                  children: [
-                    MyTextView(
-                      selectedStartDate == null ? "" : DateTimeUtils.formatDate(selectedStartDate, format: "yyyy-MM-dd"),
-                      fontSize: 14,
-                      hint: "Choose Start Date".tr,
-                      textHintColor: ColorConstants.textBlackHint,
-                      isFontMedium: true,
-                      textColor: ColorConstants.black33,
-                    ).expanded(),
-                    const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                  ],
-                ),
-              ).onTap(() {
-                pickerStartDate();
-              }),
-
-              //结束日期
-              MyTextView(
-                "End Date".tr,
-                fontSize: 14,
-                marginTop: 11,
-                isFontMedium: true,
-                textColor: ColorConstants.black33,
-              ),
-
-              //选择结束日期
-              Container(
-                padding: const EdgeInsets.only(left: 16, right: 10),
-                margin: const EdgeInsets.only(top: 10),
-                height: 45,
-                decoration: const BoxDecoration(
-                  color: ColorConstants.grayECECEC,
-                  borderRadius: BorderRadius.all(Radius.circular(5)),
-                ),
-                child: Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  mainAxisAlignment: MainAxisAlignment.start,
-                  children: [
-                    MyTextView(
-                      selectedEndDate == null ? "" : DateTimeUtils.formatDate(selectedEndDate, format: "yyyy-MM-dd"),
-                      fontSize: 14,
-                      hint: "Choose End Date".tr,
-                      textHintColor: ColorConstants.textBlackHint,
-                      isFontMedium: true,
-                      textColor: ColorConstants.black33,
-                    ).expanded(),
-                    const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                  ],
-                ),
-              ).onTap(() {
-                pickerEndDate();
-              }),
-
-              //按钮组
-              Row(
-                children: [
-                  MyButton(
-                    onPressed: () {
-                      //只是Reset当前的弹窗筛选选项
-                      widget.selectedStartDate = null;
-                      widget.selectedEndDate = null;
-                      widget.selectedStatusId = null;
-                      widget.selectedDepartmentId = null;
-
-                      setState(() {
-                        selectedStartDate = null;
-                        selectedEndDate = null;
-                        selectedStatusId = null;
-                        selectedDepartmentId = null;
-                      });
-                    },
-                    text: "Reset".tr,
-                    textColor: ColorConstants.white,
-                    backgroundColor: hexToColor("#FFBB1B"),
-                    radius: 17.25,
-                    minWidth: 60,
-                    minHeight: 36,
-                  ).expanded(),
-                  SizedBox(width: 15),
-                  MyButton(
-                    onPressed: () {
-                      onCancel();
-                      widget.onFilterAction?.call(selectedStartDate, selectedEndDate, selectedStatusId, selectedDepartmentId);
-                    },
-                    text: "Filter".tr,
-                    textColor: ColorConstants.white,
-                    backgroundColor: hexToColor("#0AC074"),
-                    radius: 17.25,
-                    minWidth: 60,
-                    minHeight: 36,
-                  ).expanded(),
-                ],
-              ).marginOnly(top: 20),
-            ],
-          ),
-        ),
-        Center(child: MyAssetImage(Assets.baseServiceDialogDeleteIcon, width: 26.5, height: 26.5).marginOnly(top: 35)).onTap(() {
-          onCancel();
-        }),
-      ],
-    );
-  }
-
-  //取消弹框
-  void onCancel() async {
-    SmartDialog.dismiss();
-  }
-
-  /// 筛选开始日期
-  void pickerStartDate() {
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: selectedStartDate,
-      onDateTimeChanged: (date) {
-        setState(() {
-          selectedStartDate = date;
-        });
-      },
-      title: "Start Date".tr,
-    );
-  }
-
-  /// 筛选结束日期
-  void pickerEndDate() {
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: selectedEndDate ?? selectedStartDate,
-      onDateTimeChanged: (date) {
-        setState(() {
-          selectedEndDate = date;
-        });
-      },
-      title: "End Date".tr,
-    );
-  }
-
-  /// 筛选部门
-  void pickerOutlet() {
-    int selectedDepartmentIndex;
-    if (selectedDepartmentId == null) {
-      selectedDepartmentIndex = 0;
-    } else {
-      selectedDepartmentIndex = widget.optionResult.departmentList!.indexWhere((department) => department.value.toString() == selectedDepartmentId);
-    }
-
-    if (selectedDepartmentIndex < 0) {
-      selectedDepartmentIndex = 0;
-    }
-
-    OptionPickerUtil.showCupertinoOptionPicker(
-      items: widget.optionResult.departmentList!.map((e) => e.txt!).toList(growable: false),
-      initialSelectIndex: selectedDepartmentIndex,
-      onPickerChanged: (_, index) {
-        setState(() {
-          selectedDepartmentId = widget.optionResult.departmentList![index].value!.toString();
-        });
-      },
-    );
-  }
-
-  /// 筛选状态
-  void pickerStatus() {
-    int selectedStatusIndex;
-    if (selectedStatusId == null) {
-      selectedStatusIndex = 0;
-    } else {
-      selectedStatusIndex = widget.optionResult.statusList!.indexWhere((department) => department.value.toString() == selectedStatusId);
-    }
-
-    if (selectedStatusIndex < 0) {
-      selectedStatusIndex = 0;
-    }
-
-    OptionPickerUtil.showCupertinoOptionPicker(
-      items: widget.optionResult.statusList!.map((e) => e.txt!).toList(growable: false),
-      initialSelectIndex: selectedStatusIndex,
-      onPickerChanged: (_, index) {
-        setState(() {
-          selectedStatusId = widget.optionResult.statusList![index].value!.toString();
-        });
-      },
-    );
-  }
-}

+ 0 - 210
packages/cpt_th/lib/modules/job/job_list/job_list_item.dart

@@ -1,210 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:domain/entity/response/job_list_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_text_view.dart';
-
-/**
- * 用工请求的主页面列表Item
- */
-class JobListItem extends StatelessWidget {
-  final int index;
-  final JobListRows item;
-  final VoidCallback? onDetailAction;
-  final VoidCallback? onAppliedAction;
-
-  JobListItem({
-    required this.index,
-    required this.item,
-    this.onDetailAction,
-    this.onAppliedAction,
-  });
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      padding: EdgeInsets.symmetric(vertical: 23, horizontal: 21),
-      margin: EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        mainAxisSize: MainAxisSize.max,
-        crossAxisAlignment: CrossAxisAlignment.start,
-        children: [
-          //工作标题
-          MyTextView(
-            item.jobTitle ?? "-",
-            isFontMedium: true,
-            textColor: ColorConstants.textYellowFFBB1B,
-            fontSize: 14,
-            textDecoration: TextDecoration.underline,
-            decorationColor: ColorConstants.textYellowFFBB1B,
-            // 可选,设置下划线的颜色
-            decorationThickness: 2.0,
-            // 可选,设置下划线的粗细
-            decorationStyle: TextDecorationStyle.solid, // 可选,设置下划线的样式
-          ),
-
-          // 部门
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Outlet:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //部门
-              MyTextView(
-                item.departmentName ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // 工作日期时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Datetime:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //日期时间
-              MyTextView(
-                item.jobTime ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // 人数
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "No. of Staff:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //人数
-              MyTextView(
-                item.staffShow ?? "",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: ColorConstants.textYellowFFBB1B,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // 状态
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Status:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //状态
-              MyTextView(
-                item.statusShow == null ? "" : item.statusShow!.tr,
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: "Completed" == item.statusShow
-                    ? ColorConstants.textGreen05DC82
-                    : "Cancelled" == item.statusShow
-                        ? ColorConstants.textRedFF6262
-                        : "Revised" == item.statusShow || "Pending" == item.statusShow
-                            ? ColorConstants.textYellowFFBB1B
-                            : ColorConstants.textBlue06D9FF,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          // 创建时间
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Created At:".tr,
-                isFontRegular: true,
-                textColor: ColorConstants.textGrayAECAE5,
-                fontSize: 14,
-              ),
-
-              //发布状态
-              MyTextView(
-                item.createdAt ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Colors.white,
-                fontSize: 14,
-              ).expanded(),
-            ],
-          ).marginOnly(top: 15),
-
-          //按钮组
-          Visibility(
-            visible: item.actionList?.isNotEmpty ?? false,
-            child: Row(
-              mainAxisSize: MainAxisSize.max,
-              mainAxisAlignment: MainAxisAlignment.end,
-              crossAxisAlignment: CrossAxisAlignment.center,
-              children: [
-                //详情按钮
-                Visibility(
-                  visible: item.actionList?.contains("detail") ?? false,
-                  child: MyButton(
-                    onPressed: () {
-                      FocusScope.of(context).unfocus();
-                      onDetailAction?.call();
-                    },
-                    text: "Detail".tr,
-                    textColor: ColorConstants.white,
-                    backgroundColor: hexToColor(
-                      "#56AAFF",
-                    ),
-                    radius: 17.25,
-                    minWidth: 60,
-                    minHeight: 35,
-                  ).marginOnly(left: 12),
-                ),
-              ],
-            ).marginOnly(top: 18, bottom: 2),
-          ),
-        ],
-      ),
-    ).onTap(() {
-      onAppliedAction?.call();
-    });
-  }
-}

+ 0 - 143
packages/cpt_th/lib/modules/job/job_list/job_list_page.dart

@@ -1,143 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:flutter/material.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_appbar.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'job_list_item.dart';
-import 'job_list_controller.dart';
-import 'job_list_state.dart';
-
-/**
- * 用工请求的主页列表
- */
-class JobListPage extends BaseStatefulPage<JobListController> {
-  JobListPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance() {
-    return Get.start(RouterPath.jobList);
-  }
-
-  @override
-  JobListController createRawController() {
-    return JobListController();
-  }
-
-  @override
-  State<JobListPage> createState() => _JobListState();
-}
-
-class _JobListState extends BaseState<JobListPage, JobListController> {
-  late JobListState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top: ScreenUtil.getStatusBarH(context)),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Column(
-              children: [
-                MyAppBar.searchTitleBar(
-                  context,
-                  value: state.keyword,
-                  hintText: 'Title'.tr,
-                  controller: state.searchController,
-                  onSearch: (keyword) {
-                    controller.doSearch(keyword);
-                  },
-                  actions: [
-                    //重置按钮
-                    MyButton(
-                      onPressed: () {
-                        FocusScope.of(context).unfocus();
-                        controller.resetFiltering();
-                      },
-                      text: "Reset".tr,
-                      textColor: ColorConstants.white,
-                      backgroundColor: hexToColor("#2BA9F9", opacity: 0.5),
-                      radius: 17.25,
-                      minWidth: 60,
-                      minHeight: 35,
-                    ).marginOnly(right: 15),
-
-                    //筛选图标
-                    MyAssetImage(
-                      Assets.baseServiceTitleBarFilterIcon,
-                      width: 24,
-                      height: 16.5,
-                    ).onTap(() {
-                      FocusScope.of(context).unfocus();
-                      controller.showFilterDialog();
-                    }).marginOnly(right: 15),
-                  ],
-                ),
-                //底部的列表
-                EasyRefresh(
-                  controller: controller.refreshController,
-                  onRefresh: controller.onRefresh,
-                  onLoad: controller.loadMore,
-                  child: LoadStateLayout(
-                    state: controller.loadingState,
-                    errorMessage: controller.errorMessage,
-                    errorRetry: () {
-                      controller.retryRequest();
-                    },
-                    successSliverWidget: [
-                      SliverList(delegate: SliverChildBuilderDelegate(
-                        (context, index) {
-                          return JobListItem(
-                            index: index,
-                            item: state.datas[index],
-                            onDetailAction: (){
-                              controller.gotoJobDetailPage(state.datas[index]);
-                            },
-                            onAppliedAction: (){
-                              controller.gotoJobAppliedPage(state.datas[index]);
-                            },
-                          );
-                        },
-                        childCount: state.datas.length,
-                      ))
-                    ],
-                  ),
-                ).marginOnly(top: 5,bottom: 5).expanded(),
-              ],
-            ),
-          ),
-        );
-    });
-  }
-}

+ 0 - 18
packages/cpt_th/lib/modules/job/job_list/job_list_state.dart

@@ -1,18 +0,0 @@
-import 'package:domain/entity/response/job_list_entity.dart';
-import 'package:domain/entity/response/job_list_index_entity.dart';
-
-import 'package:flutter/material.dart';
-
-class JobListState {
-  //筛选条件
-  final TextEditingController searchController = TextEditingController();
-  String keyword = "";
-  DateTime? selectedStartDate;
-  DateTime? selectedEndDate;
-  String? selectedStatusId;
-  String? selectedDepartmentId;
-
-  //页面的列表数据
-  List<JobListRows> datas = [];
-  JobListIndexEntity? indexOptions;
-}

+ 0 - 42
packages/cpt_th/lib/modules/job/job_list_detail/job_list_detail_controller.dart

@@ -1,42 +0,0 @@
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'job_list_detail_state.dart';
-
-class JobListDetailController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final JobListDetailState state = JobListDetailState();
-
-
-  /// 获取工作详情数据
-  void fetchJobListDetail() async {
-    var result = await _jobRepository.fetchJobListDetail(
-      state.jobId,
-      cancelToken: cancelToken,
-    );
-
-    //处理数据
-    if (result.isSuccess) {
-      state.jobListDetail = result.data;
-      state.selectedStartTime = state.jobListDetail?.startTime;
-      state.selectedEndTime = state.jobListDetail?.endTime;
-      state.noStaff = state.jobListDetail?.needNum.toString() == "0" ? "" : state.jobListDetail?.needNum.toString();
-      var needNumController = state.formData['no_of_staff']!['controller'];
-      needNumController.text = state.noStaff;
-      state.selectedJobTitle = state.jobListDetail?.jobTitle;
-      state.selectedDepartmentId = state.jobListDetail?.departmentId;
-
-      update();
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-    }
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchJobListDetail();
-  }
-
-}

+ 0 - 240
packages/cpt_th/lib/modules/job/job_list_detail/job_list_detail_page.dart

@@ -1,240 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/job_list_detail_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/services.dart';
-import 'package:flutter/widgets.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_appbar.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/no_shadow_scroll_behavior.dart';
-import 'package:widgets/shatter/form_require_text.dart';
-import 'package:widgets/shatter/round_my_text_field.dart';
-
-import 'job_list_detail_controller.dart';
-import 'job_list_detail_state.dart';
-
-class JobListDetailPage extends BaseStatefulPage<JobListDetailController> {
-  JobListDetailPage({Key? key}) : super(key: key);
-
-  //启动当前页面
-  static void startInstance(String? jobId) {
-    return Get.start(RouterPath.jobListDetail, arguments: {'jobId': jobId});
-  }
-
-  @override
-  JobListDetailController createRawController() {
-    return JobListDetailController();
-  }
-
-  @override
-  State<JobListDetailPage> createState() => _JobListDetailState();
-}
-
-class _JobListDetailState extends BaseState<JobListDetailPage, JobListDetailController> {
-  late JobListDetailState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-    state.jobId = Get.arguments['jobId'];
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return Scaffold(
-        extendBodyBehindAppBar: true,
-        appBar: MyAppBar.appBar(context, "Job Detail".tr),
-        body: SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top: kToolbarHeight + ScreenUtil.getStatusBarH(context) + 1),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Scrollbar(
-              child: ScrollConfiguration(
-                behavior: NoShadowScrollBehavior(),
-                child: SingleChildScrollView(
-                  scrollDirection: Axis.vertical,
-                  physics: const BouncingScrollPhysics(),
-                  child: Column(
-                    crossAxisAlignment: CrossAxisAlignment.start,
-                    children: [
-                      //工作标题,选择模板
-                      FormRequireText(
-                        text: "Job Title".tr,
-                      ).marginOnly(top: 15),
-
-                      //工作标题
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.5),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedJobTitle ?? "-",
-                              fontSize: 14,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                          ],
-                        ),
-                      ),
-
-                      //开始时间
-                      FormRequireText(
-                        text: "Start Time".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.5),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedStartTime ?? "-",
-                              fontSize: 14,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                          ],
-                        ),
-                      ),
-
-                      //结束时间
-                      FormRequireText(
-                        text: "End Time".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择时间
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.5),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedEndTime ?? "-",
-                              fontSize: 14,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                          ],
-                        ),
-                      ),
-
-                      //工作选择部门
-                      FormRequireText(
-                        text: "Outlet".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择部门
-                      Container(
-                        padding: EdgeInsets.only(left: 16, right: 10),
-                        margin: EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: Color(0xFF4DCFF6).withOpacity(0.5),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedDepartmentId == null || state.selectedDepartmentId == "0"
-                                  ? ""
-                                  : state.jobListDetail!.departmentList?.firstWhere((element) {
-                                        return element.value.toString() == state.selectedDepartmentId!;
-                                      }, orElse: () => JobListDetailDepartmentList()).txt ?? "",
-                              fontSize: 14,
-                              hint: "Choose Outlet".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                          ],
-                        ),
-                      ),
-
-                      //需要的人数
-                      FormRequireText(
-                        text: "No. of Staff".tr,
-                      ).marginOnly(top: 15),
-
-                      //输入框(只允许输入数字)
-                      CustomTextField(
-                        formKey: "no_of_staff",
-                        marginLeft: 0,
-                        marginRight: 0,
-                        paddingTop: 0,
-                        paddingBottom: 0,
-                        height: 45,
-                        fillBackgroundColor: Color(0xFF4DCFF6).withOpacity(0.5),
-                        enabled: false,
-                        inputFormatters: <TextInputFormatter>[FilteringTextInputFormatter.digitsOnly],
-                        textInputType: TextInputType.number,
-                        formData: state.formData,
-                        textInputAction: TextInputAction.done,
-                        onSubmit: (key, value) {
-                          FocusScope.of(context).unfocus();
-                        },
-                        marginTop: 10,
-                      ),
-                    ],
-                  ).paddingOnly(left: 15, right: 15),
-                ),
-              ),
-            ),
-          ),
-        ),
-      );
-    });
-  }
-}

+ 0 - 30
packages/cpt_th/lib/modules/job/job_list_detail/job_list_detail_state.dart

@@ -1,30 +0,0 @@
-import 'package:domain/entity/response/job_list_detail_entity.dart';
-import 'package:flutter/material.dart';
-import 'package:plugin_basic/basic_export.dart';
-
-class JobListDetailState {
-
-  String? jobId;  //编辑和详情需要用到ID
-
-  //页面对应的详情数据
-  JobListDetailEntity? jobListDetail;
-
-  //页面对应的选择的条件
-  String? selectedJobTitle;
-  String? selectedStartTime;
-  String? selectedEndTime;
-  String? selectedDepartmentId;
-  String? noStaff;  //成员数量
-
-  //表单的校验与数据
-  Map<String, Map<String, dynamic>> formData = {
-    'no_of_staff': {
-      'value': '',
-      'controller': TextEditingController(),
-      'focusNode': FocusNode(),
-      'hintText': 'Enter No. of Staff'.tr,
-      'obsecure': false,
-    },
-  };
-
-}

+ 0 - 203
packages/cpt_th/lib/modules/job/sign_in_sign_out/sign_in_sign_out_controller.dart

@@ -1,203 +0,0 @@
-import 'dart:typed_data';
-
-import 'package:domain/entity/response/attendance_entity.dart';
-import 'package:domain/entity/response/check_success_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/service/user_service.dart';
-import 'package:plugin_platform/engine/dialog/dialog_engine.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/picker/date_picker_util.dart';
-import 'package:widgets/widget_export.dart';
-
-import '../widget/attendance_sign_in_out.dart';
-import 'sign_in_sign_out_state.dart';
-
-class SignInSignOutController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-  final SignInSignOutState state = SignInSignOutState();
-
-  var _needShowPlaceholder = true;
-
-  //页面的列表数据
-  List<AttendanceList> datas = [];
-  String keyword = "";
-  Rx<DateTime> startDate = DateTime.now().obs;
-  Rx<DateTime> endDate = DateTime.now().obs;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: false,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    fetchAttendanceList();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _needShowPlaceholder = true;
-    fetchAttendanceList();
-  }
-
-  /// 获取服务器数据,成员考勤列表
-  Future fetchAttendanceList() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    }
-
-    //获取到数据
-    var result = await _jobRepository.fetchAttendanceList(
-      keyword,
-      DateTimeUtils.formatDate(startDate.value, format: "yyyy-MM-dd"),
-      DateTimeUtils.formatDate(endDate.value, format: "yyyy-MM-dd"),
-      cancelToken: cancelToken,
-    );
-
-    //处理数据
-    if (result.isSuccess) {
-      handleList(result.data?.rows);
-      refreshController.finishRefresh(IndicatorResult.success);
-    } else {
-      errorMessage = result.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-      refreshController.finishRefresh(IndicatorResult.fail);
-    }
-
-    //最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<AttendanceList>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      datas.clear();
-      datas.addAll(list);
-      //更新状态
-      changeLoadingState(LoadState.State_Success);
-    } else {
-      //展示无数据的布局
-      datas.clear();
-      changeLoadingState(LoadState.State_Empty);
-    }
-  }
-
-  /// 签到签出
-  void requestCheckInCheckOut(bool isCheckIn, AttendanceList item, ByteData byteData) async {
-    //请求接口
-
-    var result = await _jobRepository.submitCheckInOut(
-      item.appliedId.toString(),
-      byteData,
-      isCheckIn: isCheckIn,
-      cancelToken: cancelToken,
-    );
-
-    if (result.isSuccess) {
-      CheckSuccessEntity entity = result.data!;
-      if (isCheckIn) {
-        item.checkInImg = entity.checkImg;
-        item.checkInTime = entity.checkTime;
-      } else {
-        item.checkOutImg = entity.checkImg;
-        item.checkOutTime = entity.checkTime;
-      }
-      //更新状态
-      update();
-    } else {
-      errorMessage = result.errorMsg;
-      ToastEngine.show(errorMessage ?? "Network Load Error".tr);
-    }
-  }
-
-  //执行搜索
-  void doSearch(String keyword) {
-    this.keyword = keyword;
-    refreshController.callRefresh();
-  }
-
-  @override
-  void onReady() async {
-    super.onReady();
-    fetchAttendanceList();
-  }
-
-  @override
-  void onClose() {
-    super.onClose();
-    datas.clear();
-  }
-
-  /// 用户签到
-  void userSignIn(AttendanceList item) {
-    DialogEngine.show(
-      widget: AttendanceSignInOut(
-        confirmAction: (byteData) {
-          requestCheckInCheckOut(true, item, byteData);
-        },
-      ),
-    );
-  }
-
-  /// 用户签出
-  void userSignOut(AttendanceList item) {
-    DialogEngine.show(
-      widget: AttendanceSignInOut(
-        confirmAction: (byteData) {
-          requestCheckInCheckOut(false, item, byteData);
-        },
-      ),
-    );
-  }
-
-  /// 重置筛选条件
-  void resetFiltering() {
-    keyword = "";
-    state.searchController.text = "";
-    startDate.value = DateTime.now();
-    endDate.value = DateTime.now();
-    update();
-
-    refreshController.callRefresh();
-  }
-
-  /// 筛选开始日期
-  void pickerStartDate() {
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: startDate.value,
-      onDateTimeChanged: (date) {
-        startDate.value = date;
-        refreshController.callRefresh();
-      },
-      title: "Start Date".tr,
-    );
-  }
-
-  /// 筛选结束日期
-  void pickerEndDate() {
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: endDate.value,
-      onDateTimeChanged: (date) {
-        endDate.value = date;
-        refreshController.callRefresh();
-      },
-      title: "End Date".tr,
-    );
-  }
-}

+ 0 - 440
packages/cpt_th/lib/modules/job/sign_in_sign_out/sign_in_sign_out_page.dart

@@ -1,440 +0,0 @@
-import 'dart:ui';
-
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/src/services/predictive_back_event.dart';
-import 'package:flutter/widgets.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/mixin_state_lifecycle.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:shared/utils/log_utils.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_appbar.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/widget_export.dart';
-import 'sign_in_sign_out_controller.dart';
-import 'sign_in_sign_out_state.dart';
-
-/*
-   工作的签到页面
- */
-class SignInSignOutPage extends BaseStatefulPage<SignInSignOutController> {
-  SignInSignOutPage({super.key});
-
-  //启动当前页面
-  static void startInstance() {
-    return Get.start(RouterPath.jobSignInSignOut);
-  }
-
-  @override
-  State<SignInSignOutPage> createState() => _SignInSignOutPageState();
-
-  @override
-  SignInSignOutController createRawController() {
-    return SignInSignOutController();
-  }
-}
-
-class _SignInSignOutPageState extends BaseState<SignInSignOutPage, SignInSignOutController> with StateLifecycle {
-  late SignInSignOutState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-  }
-
-  @override
-  void dispose() {
-    Get.delete<SignInSignOutController>();
-    super.dispose();
-  }
-
-  @override
-  void onResume() {
-    super.onResume();
-    Log.d("SignInSignOutPage Lifecycle - onResume");
-  }
-
-  @override
-  void onPause() {
-    super.onPause();
-    Log.d("SignInSignOutPage Lifecycle - onPause");
-  }
-
-  @override
-  void onStop() {
-    super.onStop();
-    Log.d("SignInSignOutPage Lifecycle - onStop");
-  }
-
-  @override
-  void onStart() {
-    super.onStart();
-    Log.d("SignInSignOutPage Lifecycle - onStart");
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    Log.d("SignInSignOutPage Lifecycle - build走了一遍");
-
-    return autoCtlGetBuilder(
-      builder: (controller) {
-        return SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top: ScreenUtil.getStatusBarH(context)),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Column(
-              children: [
-                //顶部的搜索标题布局
-                MyAppBar.searchTitleBar(
-                  context,
-                  value: controller.keyword,
-                  hintText: 'Name/Mobile'.tr,
-                  controller: state.searchController,
-                  onSearch: (keyword) {
-                    controller.doSearch(keyword);
-                  },
-                  actions: [
-                    MyButton(
-                      onPressed: () {
-                        controller.resetFiltering();
-                      },
-                      text: "Reset".tr,
-                      textColor: ColorConstants.white,
-                      backgroundColor: hexToColor("#2BA9F9", opacity: 0.5),
-                      radius: 17.25,
-                      minWidth: 60,
-                      minHeight: 35,
-                    ).marginOnly(right: 15)
-                  ],
-                ),
-
-                _buildFilterDateWidget(),
-
-                EasyRefresh(
-                  controller: controller.refreshController,
-                  onRefresh: controller.onRefresh,
-                  child: LoadStateLayout(
-                    state: controller.loadingState,
-                    errorMessage: controller.errorMessage,
-                    errorRetry: () {
-                      controller.retryRequest();
-                    },
-                    successSliverWidget: [
-                      SliverList(
-                          delegate: SliverChildBuilderDelegate(
-                        (context, index) {
-                          return _buildAttendanceItem(controller, index, () {});
-                        },
-                        childCount: controller.datas.length,
-                      ))
-                    ],
-                  ),
-                ).expanded(),
-              ],
-            ),
-          ),
-        );
-      },
-    );
-  }
-
-  /// 时间筛选布局
-  Widget _buildFilterDateWidget() {
-    return Container(
-      width: double.infinity,
-      height: 36,
-      margin: EdgeInsets.only(left: 15, right: 15, top: 15, bottom: 10),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(17.25), // 设置圆角
-      ),
-      child: Row(
-        mainAxisSize: MainAxisSize.max,
-        crossAxisAlignment: CrossAxisAlignment.center,
-        children: [
-          Obx(() {
-            return MyTextView(
-              DateTimeUtils.formatDate(controller.startDate.value, format: "yyyy-MM-dd"),
-              fontSize: 16,
-              textAlign: TextAlign.center,
-              isFontRegular: true,
-              textColor: ColorConstants.white,
-              onClick: () {
-                controller.pickerStartDate();
-              },
-            );
-          }).expanded(),
-          Container(color: Color(0XFF52739C), width: 0.5, height: 21.5),
-          Obx(() {
-            return MyTextView(
-              DateTimeUtils.formatDate(controller.endDate.value, format: "yyyy-MM-dd"),
-              fontSize: 16,
-              textAlign: TextAlign.center,
-              isFontRegular: true,
-              textColor: ColorConstants.white,
-              onClick: () {
-                controller.pickerEndDate();
-              },
-            );
-          }).expanded(),
-        ],
-      ),
-    );
-  }
-
-  /// Item列表
-  Widget _buildAttendanceItem(SignInSignOutController controller, int index, void Function() callback) {
-    final item = controller.datas[index];
-
-    return Container(
-      padding: EdgeInsets.only(left: 23, right: 12),
-      margin: EdgeInsets.only(left: 15, right: 15, top: 5, bottom: 5),
-      decoration: BoxDecoration(
-        color: Color(0xFF4DCFF6).withOpacity(0.2), // 设置背景颜色和不透明度
-        borderRadius: BorderRadius.circular(5), // 设置圆角
-      ),
-      child: Column(
-        children: [
-          Row(
-            mainAxisSize: MainAxisSize.max,
-            crossAxisAlignment: CrossAxisAlignment.center,
-            children: [
-              MyTextView(
-                "Name:".tr,
-                isFontRegular: true,
-                textColor: Color(0XFFAECAE5),
-                fontSize: 14,
-              ),
-
-              //姓名
-              MyTextView(
-                item.staffName ?? "-",
-                marginLeft: 5,
-                isFontRegular: true,
-                textColor: Color(0XFFAECAE5),
-                fontSize: 14,
-              ).expanded(),
-
-              MyAssetImage(item.isExpended ? Assets.cptJobArrawUpIcon : Assets.cptJobArrawDownIcon, width: 15, height: 7),
-            ],
-          ).paddingOnly(top: 19, bottom: 19),
-
-          //显示隐藏的布局
-          Visibility(
-            visible: item.isExpended,
-            child: Column(
-              children: [
-                //工作日期
-                Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  children: [
-                    MyTextView(
-                      "Job Date".tr+":",
-                      isFontRegular: true,
-                      textColor: Color(0XFFAECAE5),
-                      fontSize: 14,
-                    ),
-
-                    //姓名
-                    MyTextView(
-                      item.jobDate ?? "-",
-                      marginLeft: 5,
-                      isFontRegular: true,
-                      textColor: Color(0XFFAECAE5),
-                      fontSize: 14,
-                    ).expanded(),
-                  ],
-                ),
-
-                //开始时间
-                Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  children: [
-                    MyTextView(
-                      "Start Time:",
-                      isFontRegular: true,
-                      textColor: Color(0XFFAECAE5),
-                      fontSize: 14,
-                    ),
-
-                    //姓名
-                    MyTextView(
-                      item.startTime ?? "-",
-                      marginLeft: 5,
-                      isFontRegular: true,
-                      textColor: Color(0XFFAECAE5),
-                      fontSize: 14,
-                    ).expanded(),
-                  ],
-                ).marginOnly(top: 16),
-
-                //结束时间
-                Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  children: [
-                    MyTextView(
-                      "End Time:".tr,
-                      isFontRegular: true,
-                      textColor: Color(0XFFAECAE5),
-                      fontSize: 14,
-                    ),
-
-                    //姓名
-                    MyTextView(
-                      item.endTime ?? "-",
-                      marginLeft: 5,
-                      isFontRegular: true,
-                      textColor: Color(0XFFAECAE5),
-                      fontSize: 14,
-                    ).expanded(),
-                  ],
-                ).marginOnly(top: 16),
-
-                //签到的控件
-                Row(
-                  crossAxisAlignment: CrossAxisAlignment.start,
-                  mainAxisAlignment: MainAxisAlignment.start,
-                  children: [
-                    //开始签到
-                    Column(
-                      mainAxisAlignment: MainAxisAlignment.start,
-                      crossAxisAlignment: CrossAxisAlignment.center,
-                      children: [
-                        Container(
-                          width: 90,
-                          height: 35,
-                          margin: EdgeInsets.only(top: 18),
-                          decoration: BoxDecoration(
-                            color: Utils.isEmpty(item.checkInImg) ? Color(0xFF56AAFF) : ColorConstants.white,
-                            borderRadius: BorderRadius.circular(17.25), // 设置圆角
-                          ),
-                          child: Stack(
-                            alignment: Alignment.center,
-                            children: [
-                              Visibility(
-                                visible: Utils.isEmpty(item.checkInImg),
-                                child: MyTextView(
-                                  "Check In".tr,
-                                  isFontMedium: true,
-                                  textColor: ColorConstants.white,
-                                  fontSize: 14,
-                                ),
-                              ),
-                              Visibility(
-                                visible: !Utils.isEmpty(item.checkInImg),
-                                child: MyLoadImage(item.checkInImg, width: 71.5, height: 25, fit: BoxFit.cover),
-                              ),
-                            ],
-                          ).onTap(() {
-                            if (Utils.isEmpty(item.checkInImg)) {
-                              controller.userSignIn(item);
-                            }
-                          }),
-                        ),
-                        Visibility(
-                          visible: !Utils.isEmpty(item.checkInTime),
-                          child: MyTextView(
-                            marginTop: 9,
-                            item.checkInTime ?? "-",
-                            textColor: ColorConstants.white,
-                            fontSize: 14,
-                            isFontRegular: true,
-                          ),
-                        ),
-                      ],
-                    ),
-
-                    //结束签到
-                    Column(
-                      mainAxisAlignment: MainAxisAlignment.start,
-                      crossAxisAlignment: CrossAxisAlignment.center,
-                      children: [
-                        Container(
-                          width: 90,
-                          height: 35,
-                          margin: EdgeInsets.only(top: 18),
-                          decoration: BoxDecoration(
-                            color: Utils.isEmpty(item.checkOutImg) ? Color(0xFF56AAFF) : ColorConstants.white,
-                            borderRadius: BorderRadius.circular(17.25), // 设置圆角
-                          ),
-                          child: Stack(
-                            alignment: Alignment.center,
-                            children: [
-                              Visibility(
-                                visible: Utils.isEmpty(item.checkOutImg),
-                                child: MyTextView(
-                                  "Check Out".tr,
-                                  isFontMedium: true,
-                                  textColor: ColorConstants.white,
-                                  fontSize: 14,
-                                ),
-                              ),
-                              Visibility(
-                                visible: !Utils.isEmpty(item.checkOutImg),
-                                child: MyLoadImage(item.checkOutImg, width: 71.5, height: 25, fit: BoxFit.cover),
-                              ),
-                            ],
-                          ).onTap(() {
-                            if (Utils.isEmpty(item.checkOutImg)) {
-                              controller.userSignOut(item);
-                            }
-                          }),
-                        ),
-                        Visibility(
-                          visible: !Utils.isEmpty(item.checkOutTime),
-                          child: MyTextView(
-                            marginTop: 9,
-                            item.checkOutTime ?? "-",
-                            textColor: ColorConstants.white,
-                            fontSize: 14,
-                            isFontRegular: true,
-                          ),
-                        ),
-                      ],
-                    ).marginOnly(left: 10),
-                  ],
-                ),
-
-                SizedBox(height: 18),
-              ],
-            ),
-          ),
-        ],
-      ),
-    ).onTap(() {
-      //切换展开收起
-      item.isExpended = !item.isExpended;
-      controller.update();
-    });
-  }
-}

+ 0 - 10
packages/cpt_th/lib/modules/job/sign_in_sign_out/sign_in_sign_out_state.dart

@@ -1,10 +0,0 @@
-
-
-import 'package:flutter/material.dart';
-import 'package:plugin_basic/basic_export.dart';
-
-class SignInSignOutState {
-
-  final TextEditingController searchController = TextEditingController();
-
-}

+ 0 - 342
packages/cpt_th/lib/modules/job/widget/applied_add_staff.dart

@@ -1,342 +0,0 @@
-import 'dart:ui';
-
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/job_list_applied_staff_search_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
-import 'package:get/get.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/search_app_bar.dart';
-import 'package:widgets/widget_export.dart';
-
-import 'applied_add_staff_controller.dart';
-
-/**
- * 添加员工的弹窗
- */
-class AppliedAddStaff extends StatefulWidget {
-  String jobId;
-  void Function(String selectIds)? confirmAction;
-
-  AppliedAddStaff({required this.jobId, this.confirmAction});
-
-  @override
-  State<AppliedAddStaff> createState() => _AppliedAddStaffState();
-}
-
-class _AppliedAddStaffState extends State<AppliedAddStaff> {
-  @override
-  void initState() {
-    super.initState();
-    Get.put(AppliedAddStaffController());
-  }
-
-  @override
-  void dispose() {
-    super.dispose();
-    Get.delete<AppliedAddStaffController>();
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return GetBuilder<AppliedAddStaffController>(
-      assignId: true,
-      builder: (controller) {
-        return Container(
-          width: 300,
-          height: 555,
-          decoration: BoxDecoration(
-            color: Color(0XFFF7F7F7),
-            borderRadius: const BorderRadius.all(Radius.circular(15)),
-          ),
-          child: Column(
-            crossAxisAlignment: CrossAxisAlignment.start,
-            children: [
-              Center(
-                child: MyTextView(
-                  "Choose Staff".tr,
-                  fontSize: 19,
-                  isFontMedium: true,
-                  textColor: ColorConstants.black,
-                  marginTop: 22,
-                  marginBottom: 15,
-                  marginLeft: 22,
-                  marginRight: 22,
-                ),
-              ),
-
-              SearchAppBar(
-                value: controller.keyword,
-                searchBarHeight: 38,
-                searchBarBgColor: Colors.white,
-                searchBarBorderRadius: 15,
-                searchBarBorder: Border.all(
-                  color: Color(0XFFC3C3C3), // 设置边框颜色为灰色
-                  width: 0.5, // 设置边框宽度
-                ),
-                textHintColor: Color(0XFFAFB3B7),
-                textColor: ColorConstants.black33,
-                onSearch: (keyword) {
-                  controller.doSearch(keyword);
-                },
-                hintText: "Staff Name/ID/Phone".tr,
-                controller: controller.searchController,
-              ).marginOnly(left: 16.5, right: 1.5, bottom: 15.5),
-
-              Container(
-                color: Colors.white,
-                child: EasyRefresh(
-                  header: ClassicHeader(
-                    dragText: 'Pull to refresh'.tr,
-                    armedText: 'Release ready'.tr,
-                    readyText: 'Refreshing...'.tr,
-                    processingText: 'Refreshing...'.tr,
-                    processedText: 'Succeeded'.tr,
-                    noMoreText: 'No more'.tr,
-                    failedText: 'Failed'.tr,
-                    messageText: 'Last updated at %T'.tr,
-                    textStyle: const TextStyle(color: ColorConstants.black66, fontSize: 14),
-                    messageStyle: const TextStyle(color: ColorConstants.black66, fontSize: 12),
-                    iconTheme: const IconThemeData(color: ColorConstants.black66),
-                    backgroundColor: Colors.transparent,
-                  ),
-                  footer: ClassicFooter(
-                    dragText: 'Pull to load'.tr,
-                    armedText: 'Release ready'.tr,
-                    readyText: 'Loading...'.tr,
-                    processingText: 'Loading...'.tr,
-                    processedText: 'Succeeded'.tr,
-                    noMoreText: 'No more'.tr,
-                    failedText: 'Failed'.tr,
-                    showMessage: false,
-                    triggerOffset: 50,
-                    iconDimension: 22,
-                    textStyle: const TextStyle(color: ColorConstants.black66, fontSize: 14),
-                    messageStyle: const TextStyle(color: ColorConstants.black66, fontSize: 12),
-                    iconTheme: const IconThemeData(color: ColorConstants.black66),
-                    backgroundColor: Colors.transparent,
-                  ),
-                  controller: controller.refreshController,
-                  onRefresh: controller.onRefresh,
-                  onLoad: controller.loadMore,
-                  child: LoadStateLayout(
-                    themeColor: ColorConstants.black66,
-                    state: controller.loadingState,
-                    errorMessage: controller.errorMessage,
-                    errorRetry: () {
-                      controller.retryRequest();
-                    },
-                    successSliverWidget: [
-                      SliverList(
-                          delegate: SliverChildBuilderDelegate(
-                        (context, index) {
-                          return _buildStaffItem(controller.datas[index], () {
-                            /// Item选中与未选中设置
-                            controller.datas[index].isSelected = !controller.datas[index].isSelected;
-                            controller.update();
-                          });
-                        },
-                        childCount: controller.datas.length,
-                      ))
-                    ],
-                  ),
-                ),
-              ).expanded(),
-
-              //按钮组
-              Row(
-                children: [
-                  //取消按钮
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () {
-                          onCancel();
-                        },
-                        child: MyTextView(
-                          "Cancel".tr,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: Color(0XFF0085C4),
-                          cornerRadius: 3,
-                          borderWidth: 1,
-                        ),
-                      )),
-
-                  //垂直分割线
-                  Container(
-                    color: Color(0xff09141F).withOpacity(0.13),
-                    width: 0.5,
-                  ),
-
-                  //同意按钮
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () {
-                          doCallbackAction(controller);
-                        },
-                        child: MyTextView(
-                          "Submit".tr,
-                          marginLeft: 10,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: Color(0XFF0085C4),
-                          cornerRadius: 3,
-                        ),
-                      )),
-                ],
-              ).constrained(height: 46),
-            ],
-          ),
-        );
-      },
-    );
-  }
-
-  //取消弹框
-  void onCancel() async {
-    SmartDialog.dismiss();
-  }
-
-  //执行回调
-  void doCallbackAction(AppliedAddStaffController controller) {
-    onCancel();
-
-    //找到当前选中的
-    var selectedList = controller.datas.where((element) => element.isSelected).toList(growable: false);
-    if (selectedList.isNotEmpty) {
-      var ids = selectedList.map((e) => e.id.toString()).toList(growable: false);
-      String separatedIds = ids.join(',');
-
-      widget.confirmAction?.call(separatedIds);
-    }
-
-  }
-
-  Widget _buildStaffItem(JobListAppliedStaffSearchRows item, VoidCallback callback) {
-    return Stack(
-      children: [
-        Column(
-          children: [
-            //姓名
-            Row(
-              children: [
-                MyTextView(
-                  "Staff:",
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  marginRight: 3,
-                  isFontRegular: true,
-                ),
-                MyTextView(
-                  item.name ?? "-",
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  isFontRegular: true,
-                ),
-              ],
-            ),
-
-            //头像
-            Row(
-              children: [
-                MyTextView(
-                  "Avatar:",
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  marginRight: 3,
-                  isFontRegular: true,
-                ),
-                MyLoadImage(
-                  item.avatar ?? "",
-                  width: 25,
-                  height: 25,
-                ),
-              ],
-            ).marginOnly(top: 5),
-
-            //性别
-            Row(
-              children: [
-                MyTextView(
-                  "Gender:",
-                  marginRight: 3,
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  isFontRegular: true,
-                ),
-                MyTextView(
-                  item.sex ?? "-",
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  isFontRegular: true,
-                ),
-              ],
-            ).marginOnly(top: 5),
-
-            //身份证
-            Row(
-              children: [
-                MyTextView(
-                  "NRIC:",
-                  marginRight: 3,
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  isFontRegular: true,
-                ),
-                MyTextView(
-                  item.nric ?? "-",
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  isFontRegular: true,
-                ),
-              ],
-            ).marginOnly(top: 5),
-
-            //电话
-            Row(
-              children: [
-                MyTextView(
-                  "Phone:",
-                  marginRight: 3,
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  isFontRegular: true,
-                ),
-                MyTextView(
-                  item.phone ?? "-",
-                  textColor: ColorConstants.black66,
-                  fontSize: 13,
-                  isFontRegular: true,
-                ),
-              ],
-            ).marginOnly(top: 5),
-
-            Container(
-              margin: EdgeInsets.only(top: 19),
-              width: double.infinity,
-              height: 1,
-              color: Color(0XFFF7F7F7),
-            )
-          ],
-        ).paddingOnly(left: 19, right: 20, top: 17),
-
-        //是否勾选
-        MyAssetImage(
-          item.isSelected ? Assets.baseServiceItemSelectedIcon : Assets.baseServiceItemUnselectedGrayIcon,
-          width: 20.5,
-          height: 20.5,
-        ).alignRight().marginOnly(right: 20, top: 17.5),
-      ],
-    ).onTap(callback);
-  }
-}

+ 0 - 131
packages/cpt_th/lib/modules/job/widget/applied_add_staff_controller.dart

@@ -1,131 +0,0 @@
-import 'package:domain/entity/response/job_list_applied_staff_search_entity.dart';
-import 'package:domain/repository/job_repository.dart';
-import 'package:flutter/material.dart';
-import 'package:plugin_basic/basic_export.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:shared/utils/log_utils.dart';
-import 'package:widgets/load_state_layout.dart';
-import 'package:widgets/widget_export.dart';
-
-class AppliedAddStaffController extends GetxController with DioCancelableMixin {
-  final JobRepository _jobRepository = Get.find();
-
-  TextEditingController searchController = TextEditingController();
-
-  var _curPage = 1;
-  var _needShowPlaceholder = true;
-
-  //页面PlaceHolder的展示
-  LoadState loadingState = LoadState.State_Success;
-  String? errorMessage;
-
-  String keyword = "";
-  String? jobId = null;
-  List<JobListAppliedStaffSearchRows> datas = [];
-
-  //刷新页面状态
-  void changeLoadingState(LoadState state) {
-    loadingState = state;
-    update();
-  }
-
-  // Refresh 控制器
-  final EasyRefreshController refreshController = EasyRefreshController(
-    controlFinishRefresh: true,
-    controlFinishLoad: true,
-  );
-
-  // Refresh 刷新事件
-  Future onRefresh() async {
-    _curPage = 1;
-    fetchAllStaffList();
-  }
-
-  // Refresh 加载事件
-  Future loadMore() async {
-    _curPage++;
-    fetchAllStaffList();
-  }
-
-  // 重试请求
-  Future retryRequest() async {
-    _curPage = 1;
-    _needShowPlaceholder = true;
-    fetchAllStaffList();
-  }
-
-  /// 获取列表数据
-  Future fetchAllStaffList() async {
-    if (_needShowPlaceholder) {
-      changeLoadingState(LoadState.State_Loading);
-    }
-
-    // 获取 Staff 列表
-    var listResult = await _jobRepository.searchStaffList(
-      jobId,
-      keyword,
-      curPage: _curPage,
-      cancelToken: cancelToken,
-    );
-
-    // 处理数据
-    if (listResult.isSuccess) {
-      handleList(listResult.data?.rows);
-    } else {
-      errorMessage = listResult.errorMsg;
-      changeLoadingState(LoadState.State_Error);
-    }
-
-    // 最后赋值
-    _needShowPlaceholder = false;
-  }
-
-  // 处理数据与展示的逻辑
-  void handleList(List<JobListAppliedStaffSearchRows>? list) {
-    if (list != null && list.isNotEmpty) {
-      //有数据,判断是刷新还是加载更多的数据
-      if (_curPage == 1) {
-        //刷新的方式
-        datas.clear();
-        datas.addAll(list);
-        refreshController.finishRefresh();
-
-        //更新展示的状态
-        changeLoadingState(LoadState.State_Success);
-      } else {
-        //加载更多
-        datas.addAll(list);
-        refreshController.finishLoad();
-        update();
-      }
-    } else {
-      if (_curPage == 1) {
-        //展示无数据的布局
-        datas.clear();
-        changeLoadingState(LoadState.State_Empty);
-        refreshController.finishRefresh();
-      } else {
-        //展示加载完成,没有更多数据了
-        refreshController.finishLoad(IndicatorResult.noMore);
-      }
-    }
-  }
-
-  //搜索
-  void doSearch(String keyword) {
-    this.keyword = keyword;
-    refreshController.callRefresh();
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchAllStaffList();
-  }
-
-  @override
-  void onClose() {
-    datas.clear();
-    super.onClose();
-  }
-}

+ 0 - 241
packages/cpt_th/lib/modules/job/widget/applied_butch_modify.dart

@@ -1,241 +0,0 @@
-import 'dart:typed_data';
-import 'dart:ui';
-
-import 'package:cs_resources/generated/assets.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/picker/date_picker_util.dart';
-import 'package:widgets/shatter/form_require_text.dart';
-import 'package:widgets/widget_export.dart';
-
-/*
- * 批量操作修改时间的弹窗
- */
-class AppliedButchModify extends StatefulWidget {
-  DateTime? selectedStartDate;
-  DateTime? selectedEndDate;
-  void Function(DateTime startTime, DateTime endTime)? confirmAction;
-
-  AppliedButchModify({this.selectedStartDate, this.selectedEndDate, this.confirmAction});
-
-  @override
-  State<AppliedButchModify> createState() => _AppliedButchModifyState();
-}
-
-class _AppliedButchModifyState extends State<AppliedButchModify> {
-  DateTime? selectedStartDate;
-  DateTime? selectedEndDate;
-
-  @override
-  void initState() {
-    super.initState();
-    selectedStartDate = widget.selectedStartDate;
-    selectedEndDate = widget.selectedEndDate;
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return Column(
-      crossAxisAlignment: CrossAxisAlignment.center,
-      mainAxisAlignment: MainAxisAlignment.center,
-      children: [
-        //Title (如果使用 Container 为最外层容器则默认为 match_parent 的效果,除非我们限制宽度和最大高度最小高度)
-        Container(
-          padding: const EdgeInsets.symmetric(horizontal: 16.5),
-          width: double.infinity,
-          decoration: const BoxDecoration(
-            color: Colors.white,
-            borderRadius: BorderRadius.all(Radius.circular(15)),
-          ),
-          child: Column(
-            crossAxisAlignment: CrossAxisAlignment.start,
-            children: [
-              Center(
-                child: MyTextView(
-                  "Batch Modify".tr,
-                  fontSize: 19,
-                  isFontMedium: true,
-                  textColor: ColorConstants.black,
-                  marginTop: 22,
-                  marginBottom: 20,
-                ),
-              ),
-
-              FormRequireText(
-                fontSize: 14,
-                textColor: ColorConstants.black33,
-                fontWeight: FontWeight.w400,
-                text: "Job Start Time".tr,
-              ),
-
-              //选择时间
-              Container(
-                padding: const EdgeInsets.only(left: 16, right: 10),
-                margin: const EdgeInsets.only(top: 10),
-                height: 45,
-                decoration: const BoxDecoration(
-                  color: ColorConstants.grayECECEC,
-                  borderRadius: BorderRadius.all(Radius.circular(5)),
-                ),
-                child: Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  mainAxisAlignment: MainAxisAlignment.start,
-                  children: [
-                    MyTextView(
-                      selectedStartDate == null ? "" : DateTimeUtils.formatDate(selectedStartDate),
-                      fontSize: 14,
-                      hint: "Choose Start Date".tr,
-                      textHintColor: ColorConstants.textBlackHint,
-                      isFontMedium: true,
-                      textColor: ColorConstants.black33,
-                    ).expanded(),
-                    MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                  ],
-                ),
-              ).onTap(() {
-                pickerStartDate();
-              }),
-
-              //结束日期
-              FormRequireText(
-                fontSize: 14,
-                textColor: ColorConstants.black33,
-                fontWeight: FontWeight.w400,
-                text: "Job End Time".tr,
-              ).marginOnly(top: 11),
-
-              //选择结束日期
-              Container(
-                padding: const EdgeInsets.only(left: 16, right: 10),
-                margin: const EdgeInsets.only(top: 10),
-                height: 45,
-                decoration: const BoxDecoration(
-                  color: ColorConstants.grayECECEC,
-                  borderRadius: BorderRadius.all(Radius.circular(5)),
-                ),
-                child: Row(
-                  mainAxisSize: MainAxisSize.max,
-                  crossAxisAlignment: CrossAxisAlignment.center,
-                  mainAxisAlignment: MainAxisAlignment.start,
-                  children: [
-                    MyTextView(
-                      selectedEndDate == null ? "" : DateTimeUtils.formatDate(selectedEndDate),
-                      fontSize: 14,
-                      hint: "Choose End Date".tr,
-                      textHintColor: ColorConstants.textBlackHint,
-                      isFontMedium: true,
-                      textColor: ColorConstants.black33,
-                    ).expanded(),
-                    MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                  ],
-                ),
-              ).onTap(() {
-                pickerEndDate();
-              }),
-
-              Container(
-                margin: const EdgeInsets.only(top: 25),
-                color: const Color(0XFFCECECE),
-                height: 0.5,
-              ),
-              Row(
-                children: [
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () {
-                          onCancel();
-                        },
-                        child: MyTextView(
-                          "Cancel".tr,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: Color(0XFF0085C4),
-                          cornerRadius: 3,
-                          borderWidth: 1,
-                        ),
-                      )),
-                  Container(
-                    color: Color(0xff09141F).withOpacity(0.13),
-                    width: 0.5,
-                  ),
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () async {
-                          if (selectedStartDate == null) {
-                            ToastEngine.show("Choose Start Date".tr);
-                            return;
-                          }
-
-                          if (selectedEndDate == null) {
-                            ToastEngine.show("Choose End Date".tr);
-                            return;
-                          }
-
-                          widget.confirmAction?.call(selectedStartDate!, selectedEndDate!);
-                          onCancel();
-                        },
-                        child: MyTextView(
-                          "Submit".tr,
-                          marginLeft: 10,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: const Color(0XFF0085C4),
-                          cornerRadius: 3,
-                        ),
-                      )),
-                ],
-              ).constrained(height: 46),
-            ],
-          ),
-        ),
-      ],
-    ).constrained(width: 285);
-  }
-
-  /// 筛选开始日期
-  void pickerStartDate() {
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: selectedStartDate,
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        setState(() {
-          selectedStartDate = date;
-        });
-      },
-      title: "Start Date".tr,
-    );
-  }
-
-  /// 筛选结束日期
-  void pickerEndDate() {
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: selectedEndDate ?? selectedStartDate,
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        setState(() {
-          selectedEndDate = date;
-        });
-      },
-      title: "End Date".tr,
-    );
-  }
-
-  //取消弹框
-  void onCancel() async {
-    SmartDialog.dismiss();
-  }
-}

+ 0 - 313
packages/cpt_th/lib/modules/job/widget/applied_staff_reviews.dart

@@ -1,313 +0,0 @@
-import 'dart:ui';
-
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/job_list_remark_view_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
-import 'package:get/get.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/shatter/rating_widget.dart';
-import 'package:widgets/widget_export.dart';
-
-/*
- * 员工的评价弹窗
- */
-class AppliedStaffReviews extends StatefulWidget {
-  JobListRemarkViewEntity appliedReviews;
-  void Function(String attitudeRate, String performanceRate, String experienceRate, String groomingRate, String content)? confirmAction;
-
-  AppliedStaffReviews({required this.appliedReviews, this.confirmAction});
-
-  @override
-  State<AppliedStaffReviews> createState() => _AppliedStaffReviewsState();
-}
-
-class _AppliedStaffReviewsState extends State<AppliedStaffReviews> {
-  late JobListRemarkViewEntity reviews;
-  late String attitudeRate;
-  late String groomingRate;
-  late String performanceRate;
-  late String experienceRate;
-  late String content;
-  late TextEditingController _controller;
-  late FocusNode _focusNode;
-
-  @override
-  void initState() {
-    super.initState();
-    _controller = TextEditingController();
-    _focusNode = FocusNode();
-
-    reviews = widget.appliedReviews;
-    attitudeRate = reviews.attitudeRate.toString();
-    groomingRate = reviews.groomingRate.toString();
-    performanceRate = reviews.performanceRate.toString();
-    experienceRate = reviews.experienceRate.toString();
-    _controller.text = reviews.content ?? "";
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return Column(
-      crossAxisAlignment: CrossAxisAlignment.center,
-      mainAxisAlignment: MainAxisAlignment.center,
-      children: [
-        //Title (如果使用 Container 为最外层容器则默认为 match_parent 的效果,除非我们限制宽度和最大高度最小高度)
-        Container(
-          width: double.infinity,
-          decoration: const BoxDecoration(
-            color: Colors.white,
-            borderRadius: BorderRadius.all(Radius.circular(15)),
-          ),
-          child: Column(
-            crossAxisAlignment: CrossAxisAlignment.start,
-            children: [
-              Center(
-                child: MyTextView(
-                  "Remarks".tr,
-                  fontSize: 19,
-                  isFontMedium: true,
-                  textColor: ColorConstants.black,
-                  marginTop: 23,
-                  marginBottom: 19,
-                  marginLeft: 22,
-                  marginRight: 22,
-                ),
-              ),
-
-              MyTextView(
-                reviews.memberName ?? "",
-                isFontRegular: true,
-                textColor: Colors.black,
-                marginLeft: 22,
-                marginRight: 22,
-                fontSize: 17,
-              ),
-
-              //态度评分
-              Row(
-                children: [
-                  MyTextView(
-                    "Attitude".tr,
-                    isFontRegular: true,
-                    textColor: ColorConstants.black66,
-                    fontSize: 15,
-                  ).expanded(),
-                  RatingWidget(
-                    nomalImage: Assets.baseServiceRatingUnselected,
-                    selectImage: Assets.baseServiceRatingSelected,
-                    size: 21,
-                    padding: 5,
-                    selectAble: Utils.isEmpty(reviews.content),
-                    integerOnly: true,
-                    value: reviews.attitudeRate,
-                    onRatingUpdate: (value) {
-                      attitudeRate = value;
-                    },
-                  )
-                ],
-              ).marginOnly(top: 15, left: 22, right: 22),
-
-              //表现评分
-              Row(
-                children: [
-                  MyTextView(
-                    "Performance".tr,
-                    isFontRegular: true,
-                    textColor: ColorConstants.black66,
-                    fontSize: 15,
-                  ).expanded(),
-                  RatingWidget(
-                    nomalImage: Assets.baseServiceRatingUnselected,
-                    selectImage: Assets.baseServiceRatingSelected,
-                    size: 21,
-                    padding: 5,
-                    selectAble: Utils.isEmpty(reviews.content),
-                    integerOnly: true,
-                    value: reviews.performanceRate,
-                    onRatingUpdate: (value) {
-                      performanceRate = value;
-                    },
-                  )
-                ],
-              ).marginOnly(top: 15, left: 22, right: 22),
-
-              //经验评分
-              Row(
-                children: [
-                  MyTextView(
-                    "Experience".tr,
-                    isFontRegular: true,
-                    textColor: ColorConstants.black66,
-                    fontSize: 15,
-                  ).expanded(),
-                  RatingWidget(
-                    nomalImage: Assets.baseServiceRatingUnselected,
-                    selectImage: Assets.baseServiceRatingSelected,
-                    size: 21,
-                    padding: 5,
-                    selectAble: Utils.isEmpty(reviews.content),
-                    integerOnly: true,
-                    value: reviews.experienceRate,
-                    onRatingUpdate: (value) {
-                      experienceRate = value;
-                    },
-                  )
-                ],
-              ).marginOnly(top: 15, left: 22, right: 22),
-
-              //着装评分
-              Row(
-                children: [
-                  MyTextView(
-                    "Grooming".tr,
-                    isFontRegular: true,
-                    textColor: ColorConstants.black66,
-                    fontSize: 15,
-                  ).expanded(),
-                  RatingWidget(
-                    nomalImage: Assets.baseServiceRatingUnselected,
-                    selectImage: Assets.baseServiceRatingSelected,
-                    size: 21,
-                    padding: 5,
-                    selectAble: Utils.isEmpty(reviews.content),
-                    integerOnly: true,
-                    value: reviews.groomingRate,
-                    onRatingUpdate: (value) {
-                      groomingRate = value;
-                    },
-                  )
-                ],
-              ).marginOnly(top: 15, left: 22, right: 22),
-
-              IgnoreKeyboardDismiss(
-                child: Container(
-                  height: 130,
-                  margin: const EdgeInsets.symmetric(vertical: 19, horizontal: 22),
-                  padding: const EdgeInsets.symmetric(vertical: 15, horizontal: 15),
-                  decoration: BoxDecoration(
-                    color: const Color(0xFFF0F0F0),
-                    border: Border.all(
-                      color: const Color(0xFFD8D8D8),
-                      width: 0.5,
-                    ),
-                  ),
-                  child: TextField(
-                    cursorColor: ColorConstants.black66,
-                    cursorWidth: 1.5,
-                    autofocus: false,
-                    enabled: Utils.isEmpty(reviews.content),
-                    focusNode: _focusNode,
-                    controller: _controller,
-                    // 装饰
-                    decoration: InputDecoration(
-                      isDense: true,
-                      isCollapsed: true,
-                      border: InputBorder.none,
-                      hintText: "Enter...".tr,
-                      hintStyle: const TextStyle(
-                        color: ColorConstants.black66,
-                        fontSize: 15.0,
-                        fontWeight: FontWeight.w400,
-                      ),
-                    ),
-                    style: const TextStyle(
-                      color: ColorConstants.black,
-                      fontSize: 15.0,
-                      fontWeight: FontWeight.w400,
-                    ),
-                    // 键盘动作右下角图标
-                    textInputAction: TextInputAction.done,
-                    onSubmitted: (value) {
-                      doCallbackAction();
-                    },
-                  ),
-                ),
-              ),
-
-              // 分割线
-              Container(
-                color: const Color(0XFFCECECE),
-                height: 0.5,
-              ),
-
-              //按钮组
-              Row(
-                children: [
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () {
-                          onCancel();
-                        },
-                        child: MyTextView(
-                          "Cancel".tr,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: Color(0XFF0085C4),
-                          cornerRadius: 3,
-                          borderWidth: 1,
-                        ),
-                      )),
-                  Container(
-                    color: Color(0xff09141F).withOpacity(0.13),
-                    width: 0.5,
-                  ),
-                  Expanded(
-                      flex: 1,
-                      child: InkWell(
-                        onTap: () {
-                          doCallbackAction();
-                        },
-                        child: MyTextView(
-                          "Submit".tr,
-                          marginLeft: 10,
-                          fontSize: 17.5,
-                          isFontMedium: true,
-                          textAlign: TextAlign.center,
-                          textColor: Color(0XFF0085C4),
-                          cornerRadius: 3,
-                        ),
-                      )),
-                ],
-              ).constrained(height: 46),
-            ],
-          ),
-        ),
-      ],
-    ).constrained(width: 285);
-  }
-
-  //取消弹框
-  void onCancel() async {
-    SmartDialog.dismiss();
-  }
-
-  //执行回调
-  void doCallbackAction() {
-    _focusNode.unfocus();
-
-    content = _controller.text.toString();
-
-    if (attitudeRate == "0" || experienceRate == "0" || performanceRate == "0" || groomingRate == "0") {
-      ToastEngine.show("Rate First");
-      return;
-    }
-
-    if (Utils.isEmpty(content)) {
-      ToastEngine.show("Please Enter Remark".tr);
-      return;
-    }
-
-    onCancel();
-
-    widget.confirmAction?.call(attitudeRate, performanceRate, experienceRate, groomingRate, content);
-  }
-}

+ 0 - 160
packages/cpt_th/lib/modules/job/widget/attendance_sign_in_out.dart

@@ -1,160 +0,0 @@
-import 'dart:typed_data';
-import 'dart:ui';
-
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/widgets.dart';
-import 'package:flutter_smart_dialog/flutter_smart_dialog.dart';
-import 'package:get/get.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/widget_export.dart';
-
-/**
- * 签到签出的签名弹窗
- */
-class AttendanceSignInOut extends StatelessWidget {
-  VoidCallback? cancelAction;
-  void Function(ByteData byteData)? confirmAction;
-
-  //签名版配置
-  HandSignatureControl handSignatureControl = HandSignatureControl(
-    threshold: 3.0,
-    smoothRatio: 200 / 240,
-    velocityRange: 2.0,
-  );
-
-  AttendanceSignInOut({this.cancelAction, this.confirmAction});
-
-  @override
-  Widget build(BuildContext context) {
-    return Container(
-      width: 283,
-      height: 320,
-      decoration: BoxDecoration(
-        color: Colors.white, // 设置背景颜色
-        borderRadius: BorderRadius.circular(15), // 设置圆角
-      ),
-      child: Column(
-        children: [
-          MyTextView(
-            "Sign Here".tr,
-            fontSize: 19,
-            isFontMedium: true,
-            textColor: ColorConstants.black,
-            marginTop: 15,
-            marginBottom: 12,
-          ),
-
-          Stack(
-            children: [
-              //签名
-              Center(
-                child: Container(
-                  width: 240,
-                  height: 200,
-                  color: Color(0XFFF0F0F0),
-                  child: HandSignature(
-                    control: handSignatureControl,
-                    color: ColorConstants.black404A5B,
-                    width: 1.0,
-                    maxWidth: 3.5,
-                    type: SignatureDrawType.shape,
-                  ),
-                ),
-              ),
-
-              //清除签名
-              Align(
-                alignment: Alignment.bottomLeft,
-                child: MyTextView(
-                  "Clean".tr,
-                  fontSize: 12,
-                  textColor: ColorConstants.white,
-                  cornerRadius: 10.37,
-                  backgroundColor: Color(0XFFFFBB1B),
-                  paddingTop: 4,
-                  paddingBottom: 4,
-                  paddingLeft: 11,
-                  paddingRight: 11,
-                  margin: 10,
-                  onClick: () {
-                    handSignatureControl.clear();
-                  },
-                ),
-              ),
-            ],
-          ).constrained(
-            width: 240,
-            height: 200,
-          ),
-
-          Container(
-            color: Color(0XFFCECECE),
-            height: 0.5,
-            margin: EdgeInsets.only(top: 18),
-          ),
-
-          //Buttons
-          Row(
-            children: [
-              Expanded(
-                  flex: 1,
-                  child: InkWell(
-                    onTap: () {
-                      onCancel();
-                      cancelAction?.call();
-                    },
-                    child: MyTextView(
-                      "Cancel".tr,
-                      fontSize: 17.5,
-                      isFontMedium: true,
-                      textAlign: TextAlign.center,
-                      textColor: Color(0XFF0085C4),
-                      cornerRadius: 3,
-                      borderWidth: 1,
-                    ),
-                  )),
-              Container(
-                color: Color(0XFFCECECE),
-                width: 0.5,
-              ),
-              Expanded(
-                  flex: 1,
-                  child: InkWell(
-                    onTap: () async {
-                      //签名数据
-                      var byteData = await handSignatureControl.toImage(
-                        format: ImageByteFormat.png,
-                        border: 0,
-                        width: 240,
-                        height: 200,
-                        background: Colors.white,
-                      ) as ByteData;
-
-                      onCancel();
-                      confirmAction?.call(byteData);
-                    },
-                    child: MyTextView(
-                      "Confirm".tr,
-                      marginLeft: 10,
-                      fontSize: 17.5,
-                      isFontMedium: true,
-                      textAlign: TextAlign.center,
-                      textColor: Color(0XFF0085C4),
-                      cornerRadius: 3,
-                    ),
-                  )),
-            ],
-          ).expanded(),
-        ],
-      ),
-    );
-  }
-
-  //取消弹框
-  void onCancel() async {
-    SmartDialog.dismiss();
-  }
-}

+ 1 - 1
packages/cpt_th/lib/modules/job_er/applied_er_workflow/applied_er_workflow_page.dart

@@ -23,7 +23,7 @@ class AppliedErWorkflowPage extends BaseStatefulPage<AppliedErWorkflowController
 
   //启动当前页面
   static void startInstance(String? appliedId) {
-    return Get.start(RouterPath.THJobAppliedStaffWorkflow,arguments: {'appliedId': appliedId});
+    return Get.start(RouterPath.THJobAppliedStaffWorkflowER,arguments: {'appliedId': appliedId});
   }
 
   @override

+ 1 - 0
packages/cpt_th/lib/modules/labour/labour_request_add/labour_request_add_controller.dart

@@ -208,6 +208,7 @@ class LabourRequestAddController extends GetxController with DioCancelableMixin
     if (state.pageType == 1 && Utils.isNotEmpty(state.requestId)) {
       //编辑
       result = await _thRepository.editLabourRequestSubmit(
+        isReviewEdit: state.isReviewEdit,
         requestId: state.requestId,
         jobTitleId: state.selectedJobTitleId,
         startTime: DateTimeUtils.formatDate(state.selectedStartTime),

+ 3 - 2
packages/cpt_th/lib/modules/labour/labour_request_add/labour_request_add_page.dart

@@ -28,8 +28,8 @@ class LabourRequestAddPage extends BaseStatefulPage<LabourRequestAddController>
   LabourRequestAddPage({Key? key}) : super(key: key);
 
   //启动当前页面,pageType 0 是新增  1是编辑  2是详情
-  static void startInstance(int pageType, String? appliedId, void Function(dynamic value)? cb) {
-    return Get.start(RouterPath.THLabourRequestAddOA, arguments: {'pageType': pageType, 'appliedId': appliedId, 'cb': cb});
+  static void startInstance(int pageType, String? appliedId, bool isReviewEdit, void Function(dynamic value)? cb) {
+    return Get.start(RouterPath.THLabourRequestAddOA, arguments: {'pageType': pageType, 'appliedId': appliedId, 'isReviewEdit': isReviewEdit, 'cb': cb});
   }
 
   @override
@@ -50,6 +50,7 @@ class _LabourRequestAddState extends BaseState<LabourRequestAddPage, LabourReque
     state = controller.state;
     state.pageType = Get.arguments['pageType'];
     state.requestId = Get.arguments['appliedId'];
+    state.isReviewEdit = Get.arguments['isReviewEdit'];
     state.cb = Get.arguments['cb'] as void Function(dynamic)?;
   }
 

+ 1 - 0
packages/cpt_th/lib/modules/labour/labour_request_add/labour_request_add_state.dart

@@ -81,6 +81,7 @@ class LabourRequestAddState {
 
   int pageType = 0; // 0 是新增  1是编辑  2是详情
   String? requestId;  //编辑和详情需要用到ID
+  bool isReviewEdit = false;  //编辑状态下判断是否是Review中跳转过来的
   void Function(dynamic value)? cb;
 
   List<String> genderOptions = ["Gender Unlimited".tr, "Gender Limited".tr];

+ 19 - 13
packages/cpt_th/lib/modules/labour/labour_request_list/labour_request_item.dart

@@ -260,9 +260,10 @@ class LabourRequestItem extends StatelessWidget {
                     textColor: ColorConstants.white,
                     backgroundColor: hexToColor("#56AAFF"),
                     radius: 17.25,
-                    minWidth: 60,
+                    padding: const EdgeInsets.symmetric(horizontal: 10),
+                    minWidth: 50,
                     minHeight: 35,
-                  ).marginOnly(left: 12),
+                  ).marginOnly(left: 10),
                 ),
 
                 Visibility(
@@ -276,9 +277,10 @@ class LabourRequestItem extends StatelessWidget {
                     textColor: ColorConstants.white,
                     backgroundColor: hexToColor("#56AAFF"),
                     radius: 17.25,
-                    minWidth: 60,
+                    padding: const EdgeInsets.symmetric(horizontal: 10),
+                    minWidth: 50,
                     minHeight: 35,
-                  ).marginOnly(left: 12),
+                  ).marginOnly(left: 10),
                 ),
 
                 //Att 附件
@@ -291,11 +293,12 @@ class LabourRequestItem extends StatelessWidget {
                     },
                     text: "Att(${item.attNum})",
                     textColor: ColorConstants.white,
-                    backgroundColor: hexToColor("#0AC074"),
+                    backgroundColor: hexToColor("#CA28E4"),
                     radius: 17.25,
-                    minWidth: 60,
+                    padding: const EdgeInsets.symmetric(horizontal: 10),
+                    minWidth: 50,
                     minHeight: 35,
-                  ).marginOnly(left: 12),
+                  ).marginOnly(left: 10),
                 ),
 
                 //Recall按钮 (Pending)
@@ -310,9 +313,10 @@ class LabourRequestItem extends StatelessWidget {
                     textColor: ColorConstants.white,
                     backgroundColor: hexToColor("#FFBB1B"),
                     radius: 17.25,
-                    minWidth: 60,
+                    padding: const EdgeInsets.symmetric(horizontal: 10),
+                    minWidth: 50,
                     minHeight: 35,
-                  ).marginOnly(left: 12),
+                  ).marginOnly(left: 10),
                 ),
 
                 //Edit按钮 (Recall)
@@ -327,9 +331,10 @@ class LabourRequestItem extends StatelessWidget {
                     textColor: ColorConstants.white,
                     backgroundColor: hexToColor("#FFBB1B"),
                     radius: 17.25,
-                    minWidth: 60,
+                    padding: const EdgeInsets.symmetric(horizontal: 10),
+                    minWidth: 50,
                     minHeight: 35,
-                  ).marginOnly(left: 12),
+                  ).marginOnly(left: 10),
                 ),
 
                 //状态工作流按钮
@@ -344,9 +349,10 @@ class LabourRequestItem extends StatelessWidget {
                     textColor: ColorConstants.white,
                     backgroundColor: hexToColor("#0AC074"),
                     radius: 17.25,
-                    minWidth: 60,
+                    padding: const EdgeInsets.symmetric(horizontal: 10),
+                    minWidth: 50,
                     minHeight: 35,
-                  ).marginOnly(left: 12),
+                  ).marginOnly(left: 10),
                 ),
               ],
             ).marginOnly(top: 18, bottom: 2),

+ 3 - 3
packages/cpt_th/lib/modules/labour/labour_request_list/labour_request_list_controller.dart

@@ -300,19 +300,19 @@ class LabourRequestListController extends GetxController with DioCancelableMixin
 
   //跳转到添加页面
   void gotoAddLabourPage() {
-    LabourRequestAddPage.startInstance(0, "", (result) {
+    LabourRequestAddPage.startInstance(0, "", false, (result) {
       refreshController.callRefresh();
     });
   }
 
   //去详情页面
   void gotoDetailPage(THOALabourTableRows data) {
-    LabourRequestAddPage.startInstance(2, data.id.toString(), null);
+    LabourRequestAddPage.startInstance(2, data.id.toString(), false, null);
   }
 
   //去编辑页面
   void gotoEditPage(THOALabourTableRows data) {
-    LabourRequestAddPage.startInstance(1, data.id.toString(), (result) {
+    LabourRequestAddPage.startInstance(1, data.id.toString(), false, (result) {
       fetchItemByIdAndRefreshItem(data.id.toString());
     });
   }

+ 0 - 196
packages/cpt_th/lib/modules/labour/labour_review_edit/labour_review_edit_controller.dart

@@ -1,196 +0,0 @@
-import 'package:domain/entity/response/labour_request_edit_index_entity.dart';
-import 'package:domain/repository/labour_repository.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/constants/app_constant.dart';
-import 'package:plugin_platform/engine/notify/notify_engine.dart';
-import 'package:plugin_platform/engine/toast/toast_engine.dart';
-import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
-import 'package:plugin_platform/http/http_result.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:shared/utils/event_bus.dart';
-import 'package:shared/utils/util.dart';
-import 'package:widgets/picker/date_picker_util.dart';
-import 'package:widgets/picker/option_pick_util.dart';
-
-import 'labour_review_edit_state.dart';
-
-class LabourReviewEditController extends GetxController with DioCancelableMixin {
-  final LabourRepository _labourRepository = Get.find();
-  final LabourReviewEditState state = LabourReviewEditState();
-
-  /// 获取首页的数据
-  void fetchRequestDetail() async {
-    //获取到数据
-
-    final taskFuture = _labourRepository.fetchLabourReviewDetail(state.requestId, cancelToken: cancelToken);
-
-    var result = await taskFuture;
-
-    //处理数据
-    if (result.isSuccess) {
-      state.labReqOption = result.data;
-      state.selectedStartTime = state.labReqOption?.jobStart == null ? null : DateTimeUtils.getDateTime(state.labReqOption!.jobStart!);
-      state.selectedEndTime = state.labReqOption?.jobEnd == null ? null : DateTimeUtils.getDateTime(state.labReqOption!.jobEnd!);
-      state.noStaff = state.labReqOption?.needNum.toString() == "0" ? "" : state.labReqOption?.needNum.toString();
-      var needNumController = state.formData['no_of_staff']!['controller'];
-      needNumController.text = state.noStaff;
-      var amountController = state.formData['amount']!['controller'];
-      amountController.text = state.labReqOption?.amount ?? "";
-      state.selectedTemplateId = state.labReqOption?.templateId;
-      state.selectedDepartmentId = state.labReqOption?.departmentId;
-
-      state.chargeOptionId = state.labReqOption?.chargeList.firstWhere((element) => element.checked == "checked").value;
-
-      update();
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-    }
-  }
-
-  @override
-  void onReady() {
-    super.onReady();
-    fetchRequestDetail();
-  }
-
-  /// 提交
-  void doSubmit() async {
-    var needNumController = state.formData['no_of_staff']!['controller'];
-    var amountController = state.formData['amount']!['controller'];
-    String needNum = needNumController.text.toString();
-    String amount = amountController.text.toString();
-
-    if (Utils.isEmpty(state.selectedTemplateId)) {
-      ToastEngine.show("Choose Job Title".tr);
-      return;
-    } else if (state.selectedStartTime == null) {
-      ToastEngine.show("Choose Start Date".tr);
-      return;
-    } else if (state.selectedEndTime == null) {
-      ToastEngine.show("Choose End Date".tr);
-      return;
-    } else if (Utils.isEmpty(state.selectedDepartmentId)) {
-      ToastEngine.show("Choose Outlet".tr);
-      return;
-    } else if (Utils.isEmpty(needNum)) {
-      ToastEngine.show("Enter No. of Staff".tr);
-      return;
-    } else if (state.labReqOption?.serviceType == 1 && Utils.isEmpty(amount)) {
-      ToastEngine.show("Enter Amount".tr);
-      return;
-    }
-
-
-    var result = await _labourRepository.editLabourReviewSubmit(
-      state.requestId,
-      state.selectedTemplateId,
-      DateTimeUtils.formatDate(state.selectedStartTime),
-      DateTimeUtils.formatDate(state.selectedEndTime),
-      state.selectedDepartmentId,
-      needNum,
-      state.chargeOptionId,
-      state.labReqOption?.serviceType == 1 ? amount : null,
-    );
-
-    //处理数据
-    if (result.isSuccess) {
-      NotifyEngine.showSuccess("Successful".tr);
-
-      //根据类型刷新
-      state.cb?.call(state.requestId ?? "");
-
-      Get.back();
-    } else {
-      ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
-    }
-  }
-
-  // 筛选工作模板
-  void pickJobTitle() {
-    if (state.labReqOption == null || state.pageType == 2) {
-      return;
-    }
-
-    int selectedTemplateIndex;
-    if (state.selectedTemplateId == null) {
-      selectedTemplateIndex = 0;
-    } else {
-      selectedTemplateIndex = state.labReqOption!.templateList.indexWhere((department) => department.value.toString() == state.selectedTemplateId);
-    }
-
-    if (selectedTemplateIndex < 0) {
-      selectedTemplateIndex = 0;
-    }
-
-    OptionPickerUtil.showCupertinoOptionPicker(
-      items: state.labReqOption!.templateList.map((e) => e.txt!).toList(growable: false),
-      initialSelectIndex: selectedTemplateIndex,
-      onPickerChanged: (_, index) {
-        state.selectedTemplateId = state.labReqOption!.templateList[index].value!.toString();
-        update();
-      },
-    );
-  }
-
-  //选择开始时间
-  void pickStartTime() {
-    if (state.labReqOption == null || state.pageType == 2) {
-      return;
-    }
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: state.selectedStartTime,
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.selectedStartTime = date;
-        update();
-      },
-      title: "Start Time".tr,
-    );
-  }
-
-  // 选择结束时间
-  void pickEndTime() {
-    if (state.labReqOption == null || state.pageType == 2) {
-      return;
-    }
-
-    DatePickerUtil.showCupertinoDatePicker(
-      selectedDateTime: state.selectedEndTime ?? state.selectedStartTime,
-      mode: CupertinoDatePickerMode.dateAndTime,
-      onDateTimeChanged: (date) {
-        state.selectedEndTime = date;
-        update();
-      },
-      title: "End Time".tr,
-    );
-  }
-
-  // 筛选部门
-  void pickDepartment() {
-    if (state.labReqOption == null || state.pageType == 2) {
-      return;
-    }
-
-    int selectedDepartmentIndex;
-    if (state.selectedDepartmentId == null) {
-      selectedDepartmentIndex = 0;
-    } else {
-      selectedDepartmentIndex = state.labReqOption!.departmentList.indexWhere((department) => department.value.toString() == state.selectedDepartmentId);
-    }
-
-    if (selectedDepartmentIndex < 0) {
-      selectedDepartmentIndex = 0;
-    }
-
-    OptionPickerUtil.showCupertinoOptionPicker(
-      items: state.labReqOption!.departmentList.map((e) => e.txt!).toList(growable: false),
-      initialSelectIndex: selectedDepartmentIndex,
-      onPickerChanged: (_, index) {
-        state.selectedDepartmentId = state.labReqOption!.departmentList[index].value!.toString();
-        update();
-      },
-    );
-  }
-}

+ 0 - 357
packages/cpt_th/lib/modules/labour/labour_review_edit/labour_review_edit_page.dart

@@ -1,357 +0,0 @@
-import 'package:cs_resources/constants/color_constants.dart';
-import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/labour_request_edit_index_entity.dart';
-import 'package:flutter/cupertino.dart';
-import 'package:flutter/material.dart';
-import 'package:flutter/services.dart';
-import 'package:flutter/widgets.dart';
-import 'package:get/get.dart';
-import 'package:plugin_basic/base/base_state.dart';
-import 'package:plugin_basic/base/base_stateful_page.dart';
-import 'package:plugin_basic/utils/ext_get_nav.dart';
-import 'package:router/path/router_path.dart';
-import 'package:shared/utils/date_time_utils.dart';
-import 'package:shared/utils/screen_util.dart';
-import 'package:widgets/ext/ex_widget.dart';
-import 'package:widgets/my_appbar.dart';
-import 'package:widgets/my_button.dart';
-import 'package:widgets/my_load_image.dart';
-import 'package:widgets/my_text_view.dart';
-import 'package:widgets/no_shadow_scroll_behavior.dart';
-import 'package:widgets/shatter/custom_radio_check.dart';
-import 'package:widgets/shatter/form_require_text.dart';
-import 'package:widgets/shatter/round_my_text_field.dart';
-
-import 'labour_review_edit_controller.dart';
-import 'labour_review_edit_state.dart';
-
-class LabourReviewEditPage extends BaseStatefulPage<LabourReviewEditController> {
-  LabourReviewEditPage({Key? key}) : super(key: key);
-
-  //启动当前页面,pageType  1是编辑  2是详情
-  static void startInstance(int pageType, String? requestId,void Function(dynamic value)? cb) {
-    return Get.start(RouterPath.labourReviewEdit, arguments: {'pageType': pageType, 'requestId': requestId,'cb': cb});
-  }
-
-  @override
-  LabourReviewEditController createRawController() {
-    return LabourReviewEditController();
-  }
-
-  @override
-  State<LabourReviewEditPage> createState() => _LabourReviewEditState();
-}
-
-class _LabourReviewEditState extends BaseState<LabourReviewEditPage, LabourReviewEditController> {
-  late LabourReviewEditState state;
-
-  @override
-  void initState() {
-    super.initState();
-    state = controller.state;
-    state.pageType = Get.arguments['pageType'];
-    state.requestId = Get.arguments['requestId'];
-    state.cb = Get.arguments['cb'] as void Function(dynamic)?;
-  }
-
-  @override
-  Widget build(BuildContext context) {
-    return autoCtlGetBuilder(builder: (controller) {
-      return Scaffold(
-        extendBodyBehindAppBar: true,
-        appBar: MyAppBar.appBar(context, state.pageType == 1 ? "Edit Labour Requisition".tr : "Labour Requisition".tr),
-        body: SafeArea(
-        bottom: MediaQuery.of(context).padding.bottom > 38,
-          top: false,
-          child: Container(
-            width: double.infinity,
-            height: double.infinity,
-            padding: EdgeInsets.only(top: kToolbarHeight + ScreenUtil.getStatusBarH(context) + 1),
-            decoration: const BoxDecoration(
-              gradient: LinearGradient(
-                colors: [
-                  Color(0xFF091D44),
-                  Color(0xFF245A8A),
-                  Color(0xFF7F7CEC),
-                ],
-                begin: Alignment.topCenter,
-                end: Alignment.bottomCenter,
-              ),
-            ),
-            child: Scrollbar(
-              child: ScrollConfiguration(
-                behavior: NoShadowScrollBehavior(),
-                child: SingleChildScrollView(
-                  scrollDirection: Axis.vertical,
-                  physics: const BouncingScrollPhysics(),
-                  child: Column(
-                    crossAxisAlignment: CrossAxisAlignment.start,
-                    children: [
-                      //工作标题,选择模板
-                      FormRequireText(
-                        text: "Job Title".tr,
-                      ).marginOnly(top: 15),
-
-                      //工作标题
-                      Container(
-                        padding: const EdgeInsets.only(left: 16, right: 10),
-                        margin: const EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: const Color(0xFF4DCFF6).withOpacity(state.pageType == 2 ? 0.5 : 0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedTemplateId == null || state.selectedTemplateId == "0"
-                                  ? ""
-                                  : state.labReqOption!.templateList
-                                          .firstWhere((element) => element.value.toString() == state.selectedTemplateId,
-                                              orElse: () => LabourRequestEditIndexTemplateList())
-                                          .txt ??
-                                      "",
-                              fontSize: 14,
-                              hint: "Choose Job Title".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-
-                            //下拉选图标
-                            Visibility(
-                              visible: state.pageType != 2,
-                              child: const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                            ),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickJobTitle();
-                      }),
-
-                      //开始时间
-                      FormRequireText(
-                        text: "Start Time".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择时间
-                      Container(
-                        padding: const EdgeInsets.only(left: 16, right: 10),
-                        margin: const EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: const Color(0xFF4DCFF6).withOpacity(state.pageType == 2 ? 0.5 : 0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedStartTime == null ? "" : DateTimeUtils.formatDate(state.selectedStartTime),
-                              fontSize: 14,
-                              hint: "Job Start Time".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            Visibility(
-                              visible: state.pageType != 2,
-                              child: const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                            ),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickStartTime();
-                      }),
-
-                      //结束时间
-                      FormRequireText(
-                        text: "End Time".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择时间
-                      Container(
-                        padding: const EdgeInsets.only(left: 16, right: 10),
-                        margin: const EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: const Color(0xFF4DCFF6).withOpacity(state.pageType == 2 ? 0.5 : 0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedEndTime == null ? "" : DateTimeUtils.formatDate(state.selectedEndTime),
-                              fontSize: 14,
-                              hint: "Job End Time".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            Visibility(
-                              visible: state.pageType != 2,
-                              child: const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                            ),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickEndTime();
-                      }),
-
-                      //工作选择部门
-                      FormRequireText(
-                        text: "Outlet".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择部门
-                      Container(
-                        padding: const EdgeInsets.only(left: 16, right: 10),
-                        margin: const EdgeInsets.only(top: 10),
-                        height: 45,
-                        decoration: BoxDecoration(
-                          color: const Color(0xFF4DCFF6).withOpacity(state.pageType == 2 ? 0.5 : 0.2),
-                          borderRadius: const BorderRadius.all(Radius.circular(5)),
-                        ),
-                        child: Row(
-                          mainAxisSize: MainAxisSize.max,
-                          crossAxisAlignment: CrossAxisAlignment.center,
-                          mainAxisAlignment: MainAxisAlignment.start,
-                          children: [
-                            MyTextView(
-                              state.selectedDepartmentId == null || state.selectedDepartmentId == "0"
-                                  ? ""
-                                  : state.labReqOption!.departmentList
-                                          .firstWhere((element) => element.value.toString() == state.selectedDepartmentId,
-                                              orElse: () => LabourRequestEditIndexDepartmentList())
-                                          .txt ??
-                                      "",
-                              fontSize: 14,
-                              hint: "Choose Outlet".tr,
-                              textHintColor: ColorConstants.textGrayAECAE5,
-                              isFontMedium: true,
-                              textColor: ColorConstants.white,
-                            ).expanded(),
-                            //下拉选图标
-                            Visibility(
-                              visible: state.pageType != 2,
-                              child: const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
-                            ),
-                          ],
-                        ),
-                      ).onTap(() {
-                        FocusScope.of(context).unfocus();
-                        controller.pickDepartment();
-                      }),
-
-                      //需要的人数
-                      FormRequireText(
-                        text: "No. of Staff".tr,
-                      ).marginOnly(top: 15),
-
-                      //输入框(只允许输入数字)
-                      CustomTextField(
-                        formKey: "no_of_staff",
-                        marginLeft: 0,
-                        marginRight: 0,
-                        paddingTop: 0,
-                        paddingBottom: 0,
-                        height: 45,
-                        fillBackgroundColor: const Color(0xFF4DCFF6).withOpacity(state.pageType == 2 ? 0.5 : 0.2),
-                        enabled: state.pageType != 2,
-                        inputFormatters: <TextInputFormatter>[FilteringTextInputFormatter.digitsOnly],
-                        textInputType: TextInputType.number,
-                        formData: state.formData,
-                        textInputAction: TextInputAction.done,
-                        onSubmit: (key, value) {
-                          FocusScope.of(context).unfocus();
-                        },
-                        marginTop: 10,
-                      ),
-
-                      FormRequireText(
-                        text: "Salary By".tr,
-                      ).marginOnly(top: 15),
-
-                      //选择计费类型
-                      state.labReqOption != null
-                          ? CustomRadioCheck(
-                              options: state.labReqOption!.chargeList.map((e) => e.txt).whereType<String>().toList(), //后台返回的数据展示,并且根据后台的数据匹配索引
-                              selectedPosition: state.labReqOption!.chargeList.indexWhere((element) => element.checked == "checked"),
-                              onOptionSelected: (index, text) {
-                                //修改内存的值
-                                state.chargeOptionId = state.labReqOption!.chargeList[index].value;
-                              },
-                            ).marginOnly(top: 15)
-                          : const CircularProgressIndicator(),
-
-                      //选择是否需要输入金额
-                      Visibility(
-                        visible: state.labReqOption?.serviceType == 1,
-                        child: FormRequireText(
-                          text: "Amount".tr,
-                        ).marginOnly(top: 15),
-                      ),
-
-                      Visibility(
-                        visible: state.labReqOption?.serviceType == 1,
-                        child: CustomTextField(
-                          formKey: "amount",
-                          marginLeft: 0,
-                          marginRight: 0,
-                          paddingTop: 0,
-                          paddingBottom: 0,
-                          height: 45,
-                          fillBackgroundColor: const Color(0xFF4DCFF6).withOpacity(state.pageType == 2 ? 0.5 : 0.2),
-                          enabled: state.pageType != 2,
-                          textInputType: TextInputType.number,
-                          formData: state.formData,
-                          textInputAction: TextInputAction.done,
-                          onSubmit: (key, value) {
-                            FocusScope.of(context).unfocus();
-                          },
-                          marginTop: 10,
-                        ),
-                      ),
-
-                      //提交按钮
-                      Visibility(
-                        visible: state.pageType != 2,
-                        child: MyButton(
-                          type: ClickType.throttle,
-                          milliseconds: 500,
-                          onPressed: () {
-                            FocusScope.of(context).unfocus();
-                            controller.doSubmit();
-                          },
-                          text: "Submit".tr,
-                          textColor: ColorConstants.white,
-                          fontSize: 16,
-                          radius: 22.5,
-                          backgroundColor: hexToColor("#FFBB1B"),
-                          fontWeight: FontWeight.w500,
-                        ).marginSymmetric(horizontal: 0, vertical: 30),
-                      ),
-                    ],
-                  ).paddingOnly(left: 15, right: 15),
-                ),
-              ),
-            ),
-          ),
-        ),
-      );
-    });
-  }
-}

+ 0 - 41
packages/cpt_th/lib/modules/labour/labour_review_edit/labour_review_edit_state.dart

@@ -1,41 +0,0 @@
-import 'package:domain/entity/response/labour_request_edit_index_entity.dart';
-import 'package:flutter/material.dart';
-import 'package:plugin_basic/basic_export.dart';
-
-class LabourReviewEditState {
-
-  int pageType = 2;  //页面的状态 1是编辑  2是详情
-  String? requestId;  //编辑和详情需要用到ID
-  void Function(dynamic value)? cb;
-
-  //页面对应的详情数据
-  LabourRequestEditIndexEntity? labReqOption;
-
-  //页面对应的选择的条件
-  DateTime? selectedStartTime;
-  DateTime? selectedEndTime;
-  String? selectedTemplateId;
-  String? selectedDepartmentId;
-  String? noStaff;  //成员数量
-
-  String? chargeOptionId;
-
-  //表单的校验与数据
-  Map<String, Map<String, dynamic>> formData = {
-    'no_of_staff': {
-      'value': '',
-      'controller': TextEditingController(),
-      'focusNode': FocusNode(),
-      'hintText': 'Enter No. of Staff'.tr,
-      'obsecure': false,
-    },
-    'amount': {
-      'value': '',
-      'controller': TextEditingController(),
-      'focusNode': FocusNode(),
-      'hintText': 'Enter Amount'.tr,
-      'obsecure': false,
-    },
-  };
-
-}

+ 42 - 34
packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_controller.dart

@@ -1,6 +1,6 @@
 import 'package:domain/entity/response/labour_request_index_entity.dart';
-import 'package:domain/entity/response/labour_review_list_entity.dart';
-import 'package:domain/repository/labour_repository.dart';
+import 'package:domain/entity/response/t_h_o_a_labour_review_table_entity.dart';
+import 'package:domain/repository/th_oa_repository.dart';
 import 'package:get/get.dart';
 import 'package:plugin_platform/engine/dialog/dialog_engine.dart';
 import 'package:plugin_platform/engine/notify/notify_engine.dart';
@@ -9,19 +9,18 @@ import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
 import 'package:plugin_platform/http/http_result.dart';
 import 'package:shared/utils/date_time_utils.dart';
 import 'package:shared/utils/log_utils.dart';
-import 'package:shared/utils/util.dart';
 import 'package:widgets/dialog/app_default_dialog.dart';
 import 'package:widgets/load_state_layout.dart';
 import 'package:widgets/widget_export.dart';
-
-import '../labour_review_edit/labour_review_edit_page.dart';
+import '../labour_request_add/labour_request_add_page.dart';
+import '../labour_request_list/dialog/oa_attach_list_dialog.dart';
 import '../labour_review_workflow/labour_request_workflow_page.dart';
 import 'labour_review_filter.dart';
 import 'labour_review_reject_dialog.dart';
 import 'labour_review_state.dart';
 
 class LabourReviewController extends GetxController with DioCancelableMixin {
-  final LabourRepository _labourRepository = Get.find();
+  final THOARepository _thRepository = Get.find();
   final LabourReviewState state = LabourReviewState();
 
   var _curPage = 1;
@@ -70,7 +69,7 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
 
     // 并发执行两个请求
     var futures = [
-      _labourRepository.fetchLabourReviewList(
+      _thRepository.fetchLabourReviewList(
         state.keyword,
         DateTimeUtils.formatDate(state.selectedStartDate, format: "yyyy-MM-dd"),
         DateTimeUtils.formatDate(state.selectedEndDate, format: "yyyy-MM-dd"),
@@ -79,7 +78,7 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
         cancelToken: cancelToken,
       ),
       state.indexOptions == null
-          ? _labourRepository.fetchLabourReviewIndex(
+          ? _thRepository.fetchLabourReviewIndex(
               cancelToken: cancelToken,
             )
           : Future(() => HttpResult(isSuccess: true).convert(data: state.indexOptions!)),
@@ -87,7 +86,7 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
 
     //拿到结果
     var results = await Future.wait(futures);
-    var listResult = results[0] as HttpResult<LabourReviewListEntity>;
+    var listResult = results[0] as HttpResult<THOALabourReviewTableEntity>;
     var optionResult = results[1] as HttpResult<LabourRequestIndexEntity>;
 
     //选项数据
@@ -108,7 +107,7 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
   }
 
   // 处理数据与展示的逻辑
-  void handleList(List<LabourReviewListRows>? list) {
+  void handleList(List<THOALabourReviewTableRows>? list) {
     if (list != null && list.isNotEmpty) {
       //有数据,判断是刷新还是加载更多的数据
       if (_curPage == 1) {
@@ -169,7 +168,7 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
   }
 
   /// Item选中与未选中设置
-  void doSelectedOrNot(LabourReviewListRows data) {
+  void doSelectedOrNot(THOALabourReviewTableRows data) {
     data.isSelected = !data.isSelected;
     Log.d("isSelected:${data.isSelected}");
     update();
@@ -177,16 +176,16 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
 
   /// 执行批量同意
   void _requestBatchApprove(String recordIds) async {
-    //执行请求
-    var result = await _labourRepository.approveLabourReviews(
-      recordIds,
+    // //执行请求
+    var result = await _thRepository.batchActionLabourReviews(
+      recordIds: recordIds,
+      type: 'approve',
       cancelToken: cancelToken,
     );
 
     if (result.isSuccess) {
       NotifyEngine.showSuccess("Successful".tr);
 
-      //调用接口刷新指定的Staff的信息
       _removeItemsByList(recordIds);
     } else {
       ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
@@ -196,17 +195,17 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
 
   /// 执行批量拒绝
   void _requestBatchReject(String recordIds, String? reason) async {
-    //执行请求
-    var result = await _labourRepository.rejectLabourReviews(
-      recordIds,
-      reason,
+    // //执行请求
+    var result = await _thRepository.batchActionLabourReviews(
+      recordIds: recordIds,
+      type: 'reject',
+      auditMark: reason,
       cancelToken: cancelToken,
     );
 
     if (result.isSuccess) {
       NotifyEngine.showSuccess("Successful".tr);
 
-      //调用接口刷新指定的Staff的信息
       _removeItemsByList(recordIds);
     } else {
       ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
@@ -295,28 +294,26 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
   }
 
   /// 去详情页面
-  void gotoDetailPage(LabourReviewListRows data) {
-    LabourReviewEditPage.startInstance(2, data.requestId, null);
+  void gotoDetailPage(THOALabourReviewTableRows data) {
+    LabourRequestAddPage.startInstance(2, data.requestId.toString(), true, null);
   }
 
   /// 去编辑页面
-  void gotoEditPage(LabourReviewListRows data) {
-    LabourReviewEditPage.startInstance(1, data.requestId, (result) {
-      if (Utils.isNotEmpty(result)) {
-        fetchItemByIdAndRefreshItem(data.recordId);
-      }
+  void gotoEditPage(THOALabourReviewTableRows data) {
+    LabourRequestAddPage.startInstance(1, data.requestId.toString(), true, (result) {
+      fetchItemByIdAndRefreshItem(data.requestId.toString());
     });
   }
 
   /// 去用工审核流程页面
-  void gotoStatusViewPage(LabourReviewListRows data) {
-    LabourReviewWorkflowPage.startInstance(data.requestId);
+  void gotoStatusViewPage(THOALabourReviewTableRows data) {
+    LabourReviewWorkflowPage.startInstance(data.orderId);
   }
 
   /// 根据ID获取Item对象,用于刷新
-  void fetchItemByIdAndRefreshItem(String? recordId) async {
-    var result = await _labourRepository.fetchItemByRecordId(
-      recordId,
+  void fetchItemByIdAndRefreshItem(String? requestId) async {
+    var result = await _thRepository.fetchItemByRecordId(
+      requestId,
       cancelToken: cancelToken,
     );
 
@@ -324,10 +321,10 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
     if (result.isSuccess) {
       var data = result.data;
       if (data != null && data.rows.isNotEmpty) {
-        List<LabourReviewListRows> newItem = data.rows;
+        List<THOALabourReviewTableRows> newItem = data.rows;
 
         // 创建一个 Map 来加速查找
-        Map<String, LabourReviewListRows> newItemMap = {for (var item in newItem) item.recordId ?? "": item};
+        Map<String, THOALabourReviewTableRows> newItemMap = {for (var item in newItem) item.recordId ?? "": item};
 
         // 遍历 state.datas 进行替换
         for (int i = 0; i < state.datas.length; i++) {
@@ -343,4 +340,15 @@ class LabourReviewController extends GetxController with DioCancelableMixin {
       ToastEngine.show(result.errorMsg ?? "Network Load Error".tr);
     }
   }
+
+  /// 展示附件弹窗
+  void showAttachmentDialog(THOALabourReviewTableRows data) {
+    DialogEngine.show(
+      widget: OaAttachListDialog(
+        requestId: data.requestId.toString(),
+        jobTitle: data.jobTitle ?? "-",
+        jobDate: data.jobDate ?? "-",
+      ),
+    );
+  }
 }

+ 5 - 5
packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_filter.dart

@@ -98,14 +98,14 @@ class _LabourReviewFilterState extends State<LabourReviewFilter> {
                     MyTextView(
                       selectedDepartmentId == null || selectedDepartmentId == "0"
                           ? ""
-                          : widget.optionResult.departmentList!.firstWhere((element) => element.value.toString() == selectedDepartmentId).txt!,
+                          : widget.optionResult.outletList!.firstWhere((element) => element.value.toString() == selectedDepartmentId).txt!,
                       hint: "Choose Outlet".tr,
                       textHintColor: ColorConstants.textBlackHint,
                       fontSize: 14,
                       isFontMedium: true,
                       textColor: ColorConstants.black33,
                     ).expanded(),
-                    MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
+                    const MyAssetImage(Assets.baseServiceTriangleDropDownIcon, width: 11.5, height: 6.28),
                   ],
                 ),
               ).onTap(() {
@@ -274,7 +274,7 @@ class _LabourReviewFilterState extends State<LabourReviewFilter> {
     if (selectedDepartmentId == null) {
       selectedDepartmentIndex = 0;
     } else {
-      selectedDepartmentIndex = widget.optionResult.departmentList!.indexWhere((department) => department.value.toString() == selectedDepartmentId);
+      selectedDepartmentIndex = widget.optionResult.outletList!.indexWhere((department) => department.value.toString() == selectedDepartmentId);
     }
 
     if (selectedDepartmentIndex < 0) {
@@ -282,11 +282,11 @@ class _LabourReviewFilterState extends State<LabourReviewFilter> {
     }
 
     OptionPickerUtil.showCupertinoOptionPicker(
-      items: widget.optionResult.departmentList!.map((e) => e.txt!).toList(growable: false),
+      items: widget.optionResult.outletList!.map((e) => e.txt!).toList(growable: false),
       initialSelectIndex: selectedDepartmentIndex,
       onPickerChanged: (_, index) {
         setState(() {
-          selectedDepartmentId = widget.optionResult.departmentList![index].value!.toString();
+          selectedDepartmentId = widget.optionResult.outletList![index].value!.toString();
         });
       },
     );

+ 24 - 28
packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_item.dart

@@ -1,13 +1,10 @@
 import 'package:cs_resources/constants/color_constants.dart';
 import 'package:cs_resources/generated/assets.dart';
-import 'package:domain/entity/response/job_list_applied_info_entity.dart';
-import 'package:domain/entity/response/job_list_applied_staff_list_entity.dart';
-import 'package:domain/entity/response/labour_review_list_entity.dart';
+import 'package:domain/entity/response/t_h_o_a_labour_review_table_entity.dart';
 import 'package:flutter/cupertino.dart';
 import 'package:flutter/material.dart';
 import 'package:flutter/widgets.dart';
 import 'package:plugin_basic/basic_export.dart';
-import 'package:shared/utils/util.dart';
 import 'package:widgets/ext/ex_widget.dart';
 import 'package:widgets/my_button.dart';
 import 'package:widgets/my_load_image.dart';
@@ -18,10 +15,10 @@ import 'package:widgets/my_text_view.dart';
  */
 class LabourReviewItem extends StatelessWidget {
   final int index;
-  final LabourReviewListRows item;
+  final THOALabourReviewTableRows item;
   final VoidCallback? onStatusAction;
   final VoidCallback? onEditAction;
-  final VoidCallback? onDetailAction;
+  final VoidCallback? onAttAction;
   final VoidCallback? onItemAction;
 
   LabourReviewItem({
@@ -29,7 +26,7 @@ class LabourReviewItem extends StatelessWidget {
     required this.item,
     this.onStatusAction,
     this.onEditAction,
-    this.onDetailAction,
+    this.onAttAction,
     this.onItemAction,
   });
 
@@ -90,7 +87,7 @@ class LabourReviewItem extends StatelessWidget {
 
               //部门
               MyTextView(
-                item.departmentName ?? "-",
+                item.outletName ?? "-",
                 marginLeft: 5,
                 isFontRegular: true,
                 textColor: Colors.white,
@@ -105,7 +102,7 @@ class LabourReviewItem extends StatelessWidget {
             crossAxisAlignment: CrossAxisAlignment.center,
             children: [
               MyTextView(
-                "Datetime:".tr,
+                "Job Time:".tr,
                 isFontRegular: true,
                 textColor: ColorConstants.textGrayAECAE5,
                 fontSize: 14,
@@ -113,7 +110,7 @@ class LabourReviewItem extends StatelessWidget {
 
               //日期时间
               MyTextView(
-                item.jobTime ?? "-",
+                "${item.jobDate} ${item.startTime}~${item.endTime}",
                 marginLeft: 5,
                 isFontRegular: true,
                 textColor: Colors.white,
@@ -128,7 +125,7 @@ class LabourReviewItem extends StatelessWidget {
             crossAxisAlignment: CrossAxisAlignment.center,
             children: [
               MyTextView(
-                "No. of Staff:".tr,
+                "${"Manpower Needed".tr}:",
                 isFontRegular: true,
                 textColor: ColorConstants.textGrayAECAE5,
                 fontSize: 14,
@@ -136,7 +133,7 @@ class LabourReviewItem extends StatelessWidget {
 
               //人数
               MyTextView(
-                item.needNum.toString(),
+                item.hiringNum.toString(),
                 marginLeft: 5,
                 isFontRegular: true,
                 textColor: Colors.white,
@@ -151,7 +148,7 @@ class LabourReviewItem extends StatelessWidget {
             crossAxisAlignment: CrossAxisAlignment.center,
             children: [
               MyTextView(
-                "${"Salary".tr}:",
+                "${"Hourly Rate".tr}:",
                 isFontRegular: true,
                 textColor: ColorConstants.textGrayAECAE5,
                 fontSize: 14,
@@ -159,7 +156,7 @@ class LabourReviewItem extends StatelessWidget {
 
               //发布状态
               MyTextView(
-                item.salaryShow ?? "-",
+                item.hourlyRate ?? "-",
                 marginLeft: 5,
                 isFontRegular: true,
                 textColor: Colors.white,
@@ -222,42 +219,41 @@ class LabourReviewItem extends StatelessWidget {
 
           //按钮组
           Visibility(
-            visible: item.btnList?.isNotEmpty ?? false,
+            visible: true,
             child: Row(
               mainAxisSize: MainAxisSize.max,
               mainAxisAlignment: MainAxisAlignment.end,
               crossAxisAlignment: CrossAxisAlignment.center,
               children: [
-                //详情按钮
+
+                //Edit按钮
                 Visibility(
-                  visible: item.btnList?.contains("detail") ?? false,
+                  visible: true,
                   child: MyButton(
                     onPressed: () {
                       FocusScope.of(context).unfocus();
-                      onDetailAction?.call();
+                      onEditAction?.call();
                     },
-                    text: "Detail".tr,
+                    text: "Edit".tr,
                     textColor: ColorConstants.white,
-                    backgroundColor: hexToColor(
-                      "#56AAFF",
-                    ),
+                    backgroundColor: hexToColor("#FFBB1B"),
                     radius: 17.25,
                     minWidth: 60,
                     minHeight: 35,
                   ).marginOnly(left: 12),
                 ),
 
-                //Edit按钮
+                //Att 附件
                 Visibility(
-                  visible: item.btnList.contains("edit") ?? false,
+                  visible: true,
                   child: MyButton(
                     onPressed: () {
                       FocusScope.of(context).unfocus();
-                      onEditAction?.call();
+                      onAttAction?.call();
                     },
-                    text: "Edit".tr,
+                    text: "Att(${item.attNum})",
                     textColor: ColorConstants.white,
-                    backgroundColor: hexToColor("#FFBB1B"),
+                    backgroundColor: hexToColor("#CA28E4"),
                     radius: 17.25,
                     minWidth: 60,
                     minHeight: 35,
@@ -266,7 +262,7 @@ class LabourReviewItem extends StatelessWidget {
 
                 //状态工作流按钮
                 Visibility(
-                  visible: item.btnList.contains("status") ?? false,
+                  visible: true,
                   child: MyButton(
                     onPressed: () {
                       FocusScope.of(context).unfocus();

+ 3 - 3
packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_page.dart

@@ -29,7 +29,7 @@ class LabourReviewPage extends BaseStatefulPage<LabourReviewController> {
 
   //启动当前页面
   static void startInstance() {
-    return Get.start(RouterPath.labourReviewList);
+    return Get.start(RouterPath.THLabourReviewOA);
   }
 
   @override
@@ -126,8 +126,8 @@ class _LabourReviewState extends BaseState<LabourReviewPage, LabourReviewControl
                         return LabourReviewItem(
                           index: index,
                           item: state.datas[index],
-                          onDetailAction: () {
-                            controller.gotoDetailPage(state.datas[index]);
+                          onAttAction: () {
+                            controller.showAttachmentDialog(state.datas[index]);
                           },
                           onEditAction: () {
                             controller.gotoEditPage(state.datas[index]);

+ 2 - 2
packages/cpt_th/lib/modules/labour/labour_review_list/labour_review_state.dart

@@ -1,5 +1,5 @@
 import 'package:domain/entity/response/labour_request_index_entity.dart';
-import 'package:domain/entity/response/labour_review_list_entity.dart';
+import 'package:domain/entity/response/t_h_o_a_labour_review_table_entity.dart';
 import 'package:flutter/material.dart';
 
 class LabourReviewState {
@@ -11,6 +11,6 @@ class LabourReviewState {
   String? selectedDepartmentId;
 
   //页面的列表数据
-  List<LabourReviewListRows> datas = [];
+  List<THOALabourReviewTableRows> datas = [];
   LabourRequestIndexEntity? indexOptions;
 }

+ 1 - 1
packages/cpt_th/lib/modules/labour/labour_review_workflow/labour_request_workflow_page.dart

@@ -23,7 +23,7 @@ class LabourReviewWorkflowPage extends BaseStatefulPage<LabourReviewWorkflowCont
 
   //启动当前页面
   static void startInstance(String? requestId) {
-    return Get.start(RouterPath.labourReviewWorkflow,arguments: {'requestId': requestId});
+    return Get.start(RouterPath.THLabourReviewWorkflowOA,arguments: {'requestId': requestId});
   }
 
   @override

+ 3 - 3
packages/cpt_th/lib/modules/labour/labour_review_workflow/labour_review_workflow_controller.dart

@@ -1,5 +1,5 @@
 import 'package:domain/entity/response/labour_review_status_entity.dart';
-import 'package:domain/repository/labour_repository.dart';
+import 'package:domain/repository/th_oa_repository.dart';
 import 'package:get/get.dart';
 import 'package:plugin_platform/http/dio/dio_cancelable_mixin.dart';
 import 'package:widgets/load_state_layout.dart';
@@ -9,7 +9,7 @@ import 'labour_request_workflow_state.dart';
 
 
 class LabourReviewWorkflowController extends GetxController with DioCancelableMixin{
-  final LabourRepository _labourRepository = Get.find();
+  final THOARepository _thRepository = Get.find();
   final LabourReviewWorkflowState state = LabourReviewWorkflowState();
 
   var _needShowPlaceholder = true;
@@ -48,7 +48,7 @@ class LabourReviewWorkflowController extends GetxController with DioCancelableMi
     }
 
     //获取到数据
-    var result = await _labourRepository.fetchLabourReviewStatusView(
+    var result = await _thRepository.fetchLabourReviewStatusView(
       state.requestId,
       cancelToken: cancelToken,
     );

+ 4 - 4
packages/cpt_th/lib/modules/labour_er/labour_request_er/labour_request_item.dart

@@ -55,7 +55,7 @@ class LabourRequestItem extends StatelessWidget {
                 textAlign: TextAlign.center,
                 paddingBottom: 15,
                 isFontBold: true,
-              ).expanded(flex: 1),
+              ).expanded(flex: 55),
 
               //类型
               MyTextView(
@@ -66,7 +66,7 @@ class LabourRequestItem extends StatelessWidget {
                 textAlign: TextAlign.center,
                 paddingTop: 15,
                 paddingBottom: 15,
-              ).expanded(flex: 1),
+              ).expanded(flex: 45),
             ],
           ),
 
@@ -89,7 +89,7 @@ class LabourRequestItem extends StatelessWidget {
                       textAlign: TextAlign.center,
                       paddingBottom: 6,
                       isFontRegular: true,
-                    ).expanded(flex: 1),
+                    ).expanded(flex: 55),
 
                     //类型
                     MyTextView(
@@ -108,7 +108,7 @@ class LabourRequestItem extends StatelessWidget {
                       decorationColor: ColorConstants.textYellowFFBB1B,
                       decorationThickness: 2.0,
                       decorationStyle: TextDecorationStyle.solid, // 可选,设置下划线的样式
-                    ).expanded(flex: 1),
+                    ).expanded(flex: 45),
                   ],
                 ),
               );

+ 3 - 3
packages/cpt_th/lib/modules/main/main_controller.dart

@@ -11,8 +11,6 @@ import 'package:router/componentRouter/component_router_service.dart';
 import 'package:shared/utils/event_bus.dart';
 import 'package:widgets/load_state_layout.dart';
 import 'package:widgets/widget_export.dart';
-
-import '../job/job_list/job_list_page.dart';
 import '../labour/labour_request_list/labour_request_list_page.dart';
 import '../labour/labour_review_list/labour_review_page.dart';
 import '../labour/labour_template_list/labour_template_list_page.dart';
@@ -127,13 +125,15 @@ class MainController extends GetxController {
         LabourRequestERListPage.startInstance();
         break;
       case 'er/jobs':
+        ConfigService.to.isTHOAType = false;
         JobListERPage.startInstance(null, null);
         break;
       case 'oa/lab-req':
         LabourRequestListPage.startInstance();
         break;
       case 'oa/jobs':
-        JobListPage.startInstance();
+        ConfigService.to.isTHOAType = true;
+        JobListERPage.startInstance(null, null);
         break;
       case 'oa/lab-req/review':
         LabourReviewPage.startInstance();

+ 1 - 1
packages/cpt_th/lib/modules/main/main_item_module.dart

@@ -31,7 +31,7 @@ class ModuleItem extends StatelessWidget {
               maxLines: 2,
               isFontBold: true,
               marginLeft: 20,
-              marginRight: 20,
+              marginRight: 10,
               marginTop: 20,
               fontSize: 17,
             ),

+ 14 - 86
packages/cpt_th/lib/router/th_router.dart

@@ -1,14 +1,6 @@
 import 'package:cpt_th/modules/job_er/applied_er_edit/applied_er_edit_page.dart';
 import 'package:get/get.dart';
 import 'package:router/path/router_path.dart';
-
-import '../modules/job/applied_staff_detail/applied_staff_detail_page.dart';
-import '../modules/job/applied_staff_reviews/applied_staff_reviews_page.dart';
-import '../modules/job/applied_workflow/applied_workflow_page.dart';
-import '../modules/job/attendance_review_list/attendance_review_page.dart';
-import '../modules/job/job_applied/job_applied_page.dart';
-import '../modules/job/job_applied_edit/job_applied_edit_page.dart';
-import '../modules/job/job_list/job_list_page.dart';
 import '../modules/job_er/applied_er/applied_er_page.dart';
 import '../modules/job_er/applied_er_staff_detail/applied_er_staff_detail_page.dart';
 import '../modules/job_er/applied_er_staff_reviews/applied_er_staff_reviews_page.dart';
@@ -17,12 +9,9 @@ import '../modules/job_er/job_list_er/job_list_er_page.dart';
 import '../modules/labour_er/labour_request_er/labour_request_list_page.dart';
 import '../modules/labour_er/labour_request_er_add/labour_request_er_add_page.dart';
 import '../modules/main/main_page.dart';
-import '../modules/job/job_list_detail/job_list_detail_page.dart';
-import '../modules/job/sign_in_sign_out/sign_in_sign_out_page.dart';
 import '../modules/labour/labour_request_add/labour_request_add_page.dart';
 import '../modules/labour/labour_request_list/labour_request_list_page.dart';
 import '../modules/labour/labour_request_workflow/labour_request_workflow_page.dart';
-import '../modules/labour/labour_review_edit/labour_review_edit_page.dart';
 import '../modules/labour/labour_review_list/labour_review_page.dart';
 import '../modules/labour/labour_review_workflow/labour_request_workflow_page.dart';
 import '../modules/labour/labour_template_add/labour_template_add_page.dart';
@@ -57,90 +46,18 @@ class THPageRouter {
       page: () => LabourRequestWorkflowPage(),
     ),
 
-    //用工请求状态修改工作流
-    GetPage(
-      name: RouterPath.labourTemplateList,
-      page: () => LabourTemplateListPage(),
-    ),
-
-    //用工请求状态修改工作流
-    GetPage(
-      name: RouterPath.labourTemplateAdd,
-      page: () => LabourTemplateAddPage(),
-    ),
-
     //用工请求审核列表
     GetPage(
-      name: RouterPath.labourReviewList,
+      name: RouterPath.THLabourReviewOA,
       page: () => LabourReviewPage(),
     ),
 
-    //用工请求审核编辑
-    GetPage(
-      name: RouterPath.labourReviewEdit,
-      page: () => LabourReviewEditPage(),
-    ),
-
     //用工请求审核工作流
     GetPage(
-      name: RouterPath.labourReviewWorkflow,
+      name: RouterPath.THLabourReviewWorkflowOA,
       page: () => LabourReviewWorkflowPage(),
     ),
 
-    //签到签出
-    GetPage(
-      name: RouterPath.jobSignInSignOut,
-      page: () => SignInSignOutPage(),
-    ),
-
-    //工作列表
-    GetPage(
-      name: RouterPath.jobList,
-      page: () => JobListPage(),
-    ),
-
-    //工作列表详情
-    GetPage(
-      name: RouterPath.jobListDetail,
-      page: () => JobListDetailPage(),
-    ),
-
-    //工作已申请列表
-    GetPage(
-      name: RouterPath.jobAppliedStaffList,
-      page: () => JobAppliedPage(),
-    ),
-
-    //工作已申请列表
-    GetPage(
-      name: RouterPath.jobAppliedStaffWorkflow,
-      page: () => AppliedWorkflowPage(),
-    ),
-
-    //编辑申请
-    GetPage(
-      name: RouterPath.jobAppliedStaffEdit,
-      page: () => JobAppliedEditPage(),
-    ),
-
-    //员工详情
-    GetPage(
-      name: RouterPath.jobAppliedStaffDetail,
-      page: () => AppliedStaffDetailPage(),
-    ),
-
-    //员工评价
-    GetPage(
-      name: RouterPath.jobAppliedStaffReviews,
-      page: () => AppliedStaffReviewsPage(),
-    ),
-
-    //工作考勤的审核列表
-    GetPage(
-      name: RouterPath.jobAttendanceReviewList,
-      page: () => AttendanceReviewPage(),
-    ),
-
     //用工请求列表 ER
     GetPage(
       name: RouterPath.THLabourRequestER,
@@ -185,10 +102,21 @@ class THPageRouter {
 
     //ER 已申请列表,员工详情评价页面
     GetPage(
-      name: RouterPath.THJobAppliedStaffWorkflow,
+      name: RouterPath.THJobAppliedStaffWorkflowER,
       page: () => AppliedErWorkflowPage(),
     ),
 
+    //用工请求状态修改工作流
+    GetPage(
+      name: RouterPath.labourTemplateList,
+      page: () => LabourTemplateListPage(),
+    ),
+
+    //用工请求状态修改工作流
+    GetPage(
+      name: RouterPath.labourTemplateAdd,
+      page: () => LabourTemplateAddPage(),
+    ),
 
   ];
 }

+ 16 - 0
packages/cs_domain/lib/constants/api_constants.dart

@@ -630,4 +630,20 @@ class ApiConstants {
 
   //OA 附件删除
   static const apiOAAttachmentDeleteTH = "/index.php/api/oa/lab-req/att-delete";
+
+  //OA 用工审核列表选项
+  static const apiOALabourReviewOptionTH = "/index.php/api/oa/lab-req/review/index";
+
+  //OA 用工审核列表
+  static const apiOALabourReviewTableTH = "/index.php/api/oa/lab-req/review/table";
+
+  //OA 用工审核编辑提交
+  static const apiOALabourReviewEditSubmitTH = "/index.php/api/oa/lab-req/review/edit-submit";
+
+  //OA 用工审核的批量操作
+  static const apiOALabourReviewBatchTH = "/index.php/api/oa/lab-req/review/batch-audit";
+
+  //OA 用工审核工作流
+  static const apiOALabourReviewWorkflowTH = "/index.php/api/oa/lab-req/review/view-status";
+
 }

+ 70 - 0
packages/cs_domain/lib/entity/response/t_h_o_a_labour_review_table_entity.dart

@@ -0,0 +1,70 @@
+import 'package:domain/generated/json/base/json_field.dart';
+import 'package:domain/generated/json/t_h_o_a_labour_review_table_entity.g.dart';
+import 'dart:convert';
+export 'package:domain/generated/json/t_h_o_a_labour_review_table_entity.g.dart';
+
+@JsonSerializable()
+class THOALabourReviewTableEntity {
+	int total = 0;
+	List<THOALabourReviewTableRows> rows = [];
+
+	THOALabourReviewTableEntity();
+
+	factory THOALabourReviewTableEntity.fromJson(Map<String, dynamic> json) => $THOALabourReviewTableEntityFromJson(json);
+
+	Map<String, dynamic> toJson() => $THOALabourReviewTableEntityToJson(this);
+
+	@override
+	String toString() {
+		return jsonEncode(this);
+	}
+}
+
+@JsonSerializable()
+class THOALabourReviewTableRows {
+	@JSONField(name: "record_id")
+	String? recordId;
+	@JSONField(name: "order_id")
+	String? orderId;
+	@JSONField(name: "request_id")
+	String? requestId;
+	@JSONField(name: "status_show")
+	String? statusShow;
+	@JSONField(name: "created_at")
+	String? createdAt;
+	@JSONField(name: "source_show")
+	String? sourceShow;
+	@JSONField(name: "job_date")
+	String? jobDate;
+	@JSONField(name: "outlet_name")
+	String? outletName;
+	@JSONField(name: "job_title")
+	String? jobTitle;
+	@JSONField(name: "hourly_rate")
+	String? hourlyRate;
+	@JSONField(name: "start_time")
+	String? startTime;
+	@JSONField(name: "end_time")
+	String? endTime;
+	@JSONField(name: "hiring_num")
+	int? hiringNum;
+	@JSONField(name: "att_num")
+	int? attNum;
+	@JSONField(name: "position_name")
+	String? positionName;
+	@JSONField(name: "is_ot")
+	int? isOt;
+
+	bool isSelected = false;
+
+	THOALabourReviewTableRows();
+
+	factory THOALabourReviewTableRows.fromJson(Map<String, dynamic> json) => $THOALabourReviewTableRowsFromJson(json);
+
+	Map<String, dynamic> toJson() => $THOALabourReviewTableRowsToJson(this);
+
+	@override
+	String toString() {
+		return jsonEncode(this);
+	}
+}

+ 9 - 0
packages/cs_domain/lib/generated/json/base/json_convert_content.dart

@@ -93,6 +93,7 @@ import 'package:domain/entity/response/t_h_employee_detail_entity.dart';
 import 'package:domain/entity/response/t_h_employee_remarks_entity.dart';
 import 'package:domain/entity/response/t_h_o_a_attachment_entity.dart';
 import 'package:domain/entity/response/t_h_o_a_labour_detail_entity.dart';
+import 'package:domain/entity/response/t_h_o_a_labour_review_table_entity.dart';
 import 'package:domain/entity/response/t_h_o_a_labour_table_entity.dart';
 import 'package:domain/entity/response/t_h_upload_file_entity.dart';
 import 'package:domain/entity/response/u_k_attendance_entity.dart';
@@ -797,6 +798,12 @@ class JsonConvert {
     if (<THOALabourDetailLabourRequest>[] is M) {
       return data.map<THOALabourDetailLabourRequest>((Map<String, dynamic> e) => THOALabourDetailLabourRequest.fromJson(e)).toList() as M;
     }
+    if (<THOALabourReviewTableEntity>[] is M) {
+      return data.map<THOALabourReviewTableEntity>((Map<String, dynamic> e) => THOALabourReviewTableEntity.fromJson(e)).toList() as M;
+    }
+    if (<THOALabourReviewTableRows>[] is M) {
+      return data.map<THOALabourReviewTableRows>((Map<String, dynamic> e) => THOALabourReviewTableRows.fromJson(e)).toList() as M;
+    }
     if (<THOALabourTableEntity>[] is M) {
       return data.map<THOALabourTableEntity>((Map<String, dynamic> e) => THOALabourTableEntity.fromJson(e)).toList() as M;
     }
@@ -1070,6 +1077,8 @@ class JsonConvertClassCollection {
     (THOAAttachmentRows).toString(): THOAAttachmentRows.fromJson,
     (THOALabourDetailEntity).toString(): THOALabourDetailEntity.fromJson,
     (THOALabourDetailLabourRequest).toString(): THOALabourDetailLabourRequest.fromJson,
+    (THOALabourReviewTableEntity).toString(): THOALabourReviewTableEntity.fromJson,
+    (THOALabourReviewTableRows).toString(): THOALabourReviewTableRows.fromJson,
     (THOALabourTableEntity).toString(): THOALabourTableEntity.fromJson,
     (THOALabourTableRows).toString(): THOALabourTableRows.fromJson,
     (THUploadFileEntity).toString(): THUploadFileEntity.fromJson,

+ 163 - 0
packages/cs_domain/lib/generated/json/t_h_o_a_labour_review_table_entity.g.dart

@@ -0,0 +1,163 @@
+import 'package:domain/generated/json/base/json_convert_content.dart';
+import 'package:domain/entity/response/t_h_o_a_labour_review_table_entity.dart';
+
+THOALabourReviewTableEntity $THOALabourReviewTableEntityFromJson(Map<String, dynamic> json) {
+  final THOALabourReviewTableEntity tHOALabourReviewTableEntity = THOALabourReviewTableEntity();
+  final int? total = jsonConvert.convert<int>(json['total']);
+  if (total != null) {
+    tHOALabourReviewTableEntity.total = total;
+  }
+  final List<THOALabourReviewTableRows>? rows = (json['rows'] as List<dynamic>?)?.map(
+          (e) => jsonConvert.convert<THOALabourReviewTableRows>(e) as THOALabourReviewTableRows).toList();
+  if (rows != null) {
+    tHOALabourReviewTableEntity.rows = rows;
+  }
+  return tHOALabourReviewTableEntity;
+}
+
+Map<String, dynamic> $THOALabourReviewTableEntityToJson(THOALabourReviewTableEntity entity) {
+  final Map<String, dynamic> data = <String, dynamic>{};
+  data['total'] = entity.total;
+  data['rows'] = entity.rows.map((v) => v.toJson()).toList();
+  return data;
+}
+
+extension THOALabourReviewTableEntityExtension on THOALabourReviewTableEntity {
+  THOALabourReviewTableEntity copyWith({
+    int? total,
+    List<THOALabourReviewTableRows>? rows,
+  }) {
+    return THOALabourReviewTableEntity()
+      ..total = total ?? this.total
+      ..rows = rows ?? this.rows;
+  }
+}
+
+THOALabourReviewTableRows $THOALabourReviewTableRowsFromJson(Map<String, dynamic> json) {
+  final THOALabourReviewTableRows tHOALabourReviewTableRows = THOALabourReviewTableRows();
+  final String? recordId = jsonConvert.convert<String>(json['record_id']);
+  if (recordId != null) {
+    tHOALabourReviewTableRows.recordId = recordId;
+  }
+  final String? orderId = jsonConvert.convert<String>(json['order_id']);
+  if (orderId != null) {
+    tHOALabourReviewTableRows.orderId = orderId;
+  }
+  final String? requestId = jsonConvert.convert<String>(json['request_id']);
+  if (requestId != null) {
+    tHOALabourReviewTableRows.requestId = requestId;
+  }
+  final String? statusShow = jsonConvert.convert<String>(json['status_show']);
+  if (statusShow != null) {
+    tHOALabourReviewTableRows.statusShow = statusShow;
+  }
+  final String? createdAt = jsonConvert.convert<String>(json['created_at']);
+  if (createdAt != null) {
+    tHOALabourReviewTableRows.createdAt = createdAt;
+  }
+  final String? sourceShow = jsonConvert.convert<String>(json['source_show']);
+  if (sourceShow != null) {
+    tHOALabourReviewTableRows.sourceShow = sourceShow;
+  }
+  final String? jobDate = jsonConvert.convert<String>(json['job_date']);
+  if (jobDate != null) {
+    tHOALabourReviewTableRows.jobDate = jobDate;
+  }
+  final String? outletName = jsonConvert.convert<String>(json['outlet_name']);
+  if (outletName != null) {
+    tHOALabourReviewTableRows.outletName = outletName;
+  }
+  final String? jobTitle = jsonConvert.convert<String>(json['job_title']);
+  if (jobTitle != null) {
+    tHOALabourReviewTableRows.jobTitle = jobTitle;
+  }
+  final String? hourlyRate = jsonConvert.convert<String>(json['hourly_rate']);
+  if (hourlyRate != null) {
+    tHOALabourReviewTableRows.hourlyRate = hourlyRate;
+  }
+  final String? startTime = jsonConvert.convert<String>(json['start_time']);
+  if (startTime != null) {
+    tHOALabourReviewTableRows.startTime = startTime;
+  }
+  final String? endTime = jsonConvert.convert<String>(json['end_time']);
+  if (endTime != null) {
+    tHOALabourReviewTableRows.endTime = endTime;
+  }
+  final int? hiringNum = jsonConvert.convert<int>(json['hiring_num']);
+  if (hiringNum != null) {
+    tHOALabourReviewTableRows.hiringNum = hiringNum;
+  }
+  final int? attNum = jsonConvert.convert<int>(json['att_num']);
+  if (attNum != null) {
+    tHOALabourReviewTableRows.attNum = attNum;
+  }
+  final String? positionName = jsonConvert.convert<String>(json['position_name']);
+  if (positionName != null) {
+    tHOALabourReviewTableRows.positionName = positionName;
+  }
+  final int? isOt = jsonConvert.convert<int>(json['is_ot']);
+  if (isOt != null) {
+    tHOALabourReviewTableRows.isOt = isOt;
+  }
+  return tHOALabourReviewTableRows;
+}
+
+Map<String, dynamic> $THOALabourReviewTableRowsToJson(THOALabourReviewTableRows entity) {
+  final Map<String, dynamic> data = <String, dynamic>{};
+  data['record_id'] = entity.recordId;
+  data['order_id'] = entity.orderId;
+  data['request_id'] = entity.requestId;
+  data['status_show'] = entity.statusShow;
+  data['created_at'] = entity.createdAt;
+  data['source_show'] = entity.sourceShow;
+  data['job_date'] = entity.jobDate;
+  data['outlet_name'] = entity.outletName;
+  data['job_title'] = entity.jobTitle;
+  data['hourly_rate'] = entity.hourlyRate;
+  data['start_time'] = entity.startTime;
+  data['end_time'] = entity.endTime;
+  data['hiring_num'] = entity.hiringNum;
+  data['att_num'] = entity.attNum;
+  data['position_name'] = entity.positionName;
+  data['is_ot'] = entity.isOt;
+  return data;
+}
+
+extension THOALabourReviewTableRowsExtension on THOALabourReviewTableRows {
+  THOALabourReviewTableRows copyWith({
+    String? recordId,
+    String? orderId,
+    String? requestId,
+    String? statusShow,
+    String? createdAt,
+    String? sourceShow,
+    String? jobDate,
+    String? outletName,
+    String? jobTitle,
+    String? hourlyRate,
+    String? startTime,
+    String? endTime,
+    int? hiringNum,
+    int? attNum,
+    String? positionName,
+    int? isOt,
+  }) {
+    return THOALabourReviewTableRows()
+      ..recordId = recordId ?? this.recordId
+      ..orderId = orderId ?? this.orderId
+      ..requestId = requestId ?? this.requestId
+      ..statusShow = statusShow ?? this.statusShow
+      ..createdAt = createdAt ?? this.createdAt
+      ..sourceShow = sourceShow ?? this.sourceShow
+      ..jobDate = jobDate ?? this.jobDate
+      ..outletName = outletName ?? this.outletName
+      ..jobTitle = jobTitle ?? this.jobTitle
+      ..hourlyRate = hourlyRate ?? this.hourlyRate
+      ..startTime = startTime ?? this.startTime
+      ..endTime = endTime ?? this.endTime
+      ..hiringNum = hiringNum ?? this.hiringNum
+      ..attNum = attNum ?? this.attNum
+      ..positionName = positionName ?? this.positionName
+      ..isOt = isOt ?? this.isOt;
+  }
+}

+ 150 - 1
packages/cs_domain/lib/repository/th_oa_repository.dart

@@ -1,5 +1,6 @@
 import 'package:domain/entity/response/t_h_o_a_attachment_entity.dart';
 import 'package:domain/entity/response/t_h_o_a_labour_detail_entity.dart';
+import 'package:domain/entity/response/t_h_o_a_labour_review_table_entity.dart';
 import 'package:domain/entity/response/t_h_o_a_labour_table_entity.dart';
 import 'package:domain/entity/response/t_h_upload_file_entity.dart';
 import 'package:get/get.dart';
@@ -10,6 +11,7 @@ import 'package:shared/utils/util.dart';
 import '../constants/api_constants.dart';
 import '../entity/response/labour_request_index_entity.dart';
 import '../entity/response/labour_request_work_flow_entity.dart';
+import '../entity/response/labour_review_status_entity.dart';
 
 /// 泰国的 OA 的数据仓库
 class THOARepository extends GetxService {
@@ -291,6 +293,7 @@ class THOARepository extends GetxService {
 
   /// 编辑用工请求提交
   Future<HttpResult> editLabourRequestSubmit({
+    required bool isReviewEdit,
     required String? requestId,
     required String? jobTitleId,
     required String? startTime,
@@ -340,7 +343,7 @@ class THOARepository extends GetxService {
     params['est_cost'] = estCost ?? "";
 
     final result = await httpProvider.requestNetResult(
-      ApiConstants.apiOALabourRequestEditSubmitTH,
+      isReviewEdit ? ApiConstants.apiOALabourReviewEditSubmitTH : ApiConstants.apiOALabourRequestEditSubmitTH,
       method: HttpMethod.POST,
       params: params,
       networkDebounce: true,
@@ -462,4 +465,150 @@ class THOARepository extends GetxService {
     return result.convert();
   }
 
+  // ===================================  用工审核  ↓  ===================================
+
+  /// 用工审核选项
+  Future<HttpResult<LabourRequestIndexEntity>> fetchLabourReviewIndex({
+    CancelToken? cancelToken,
+  }) async {
+    final result = await httpProvider.requestNetResult(
+      ApiConstants.apiOALabourReviewOptionTH,
+      cancelToken: cancelToken,
+    );
+
+    if (result.isSuccess) {
+      final json = result.getDataJson();
+      var data = LabourRequestIndexEntity.fromJson(json!);
+      return result.convert<LabourRequestIndexEntity>(data: data);
+    }
+    return result.convert();
+  }
+
+  /// 用工审核列表
+  Future<HttpResult<THOALabourReviewTableEntity>> fetchLabourReviewList(
+    String? keyword,
+    String? startDate,
+    String? endDate,
+    String? outletId, {
+    required int curPage,
+    CancelToken? cancelToken,
+  }) async {
+    //参数
+    Map<String, String> params = {};
+    params["cur_page"] = curPage.toString();
+    params["page_size"] = "10";
+
+    if (!Utils.isEmpty(keyword)) {
+      params["job_title"] = keyword!;
+    }
+    if (!Utils.isEmpty(startDate)) {
+      params["job_start"] = startDate!;
+    }
+    if (!Utils.isEmpty(endDate)) {
+      params["job_end"] = endDate!;
+    }
+    if (!Utils.isEmpty(outletId)) {
+      params["outlet_id"] = outletId!;
+    }
+
+    final result = await httpProvider.requestNetResult(
+      ApiConstants.apiOALabourReviewTableTH,
+      params: params,
+      cancelToken: cancelToken,
+    );
+
+    if (result.isSuccess) {
+      final json = result.getDataJson();
+      var data = THOALabourReviewTableEntity.fromJson(json!);
+      return result.convert<THOALabourReviewTableEntity>(data: data);
+    }
+    return result.convert();
+  }
+
+  /// 根据ID获取主列表的Item数据,用于刷新审核列表Item
+  Future<HttpResult<THOALabourReviewTableEntity>> fetchItemByRecordId(
+    String? requestId, {
+    CancelToken? cancelToken,
+  }) async {
+    //参数
+    Map<String, String> params = {};
+    params["cur_page"] = "1";
+    params["page_size"] = "1";
+
+    if (!Utils.isEmpty(requestId)) {
+      params["request_id"] = requestId!;
+    }
+
+    final result = await httpProvider.requestNetResult(
+      ApiConstants.apiOALabourReviewTableTH,
+      params: params,
+      isShowLoadingDialog: true,
+      cancelToken: cancelToken,
+    );
+
+    //根据返回的结果,封装原始数据为Bean/Entity对象
+    if (result.isSuccess) {
+      //重新赋值data或list
+      final json = result.getDataJson();
+      var data = THOALabourReviewTableEntity.fromJson(json!);
+      //重新赋值data或list
+      return result.convert<THOALabourReviewTableEntity>(data: data);
+    }
+    return result.convert();
+  }
+
+  ///OA 用工审核工作流
+  Future<HttpResult<LabourReviewStatusEntity>> fetchLabourReviewStatusView(
+    String? orderId, {
+    CancelToken? cancelToken,
+  }) async {
+    //参数
+    Map<String, String> params = {};
+    if (!Utils.isEmpty(orderId)) {
+      params["order_id"] = orderId!;
+    }
+
+    final result = await httpProvider.requestNetResult(
+      ApiConstants.apiOALabourReviewWorkflowTH,
+      params: params,
+      cancelToken: cancelToken,
+    );
+
+    if (result.isSuccess) {
+      final json = result.getDataJson();
+      var data = LabourReviewStatusEntity.fromJson(json!);
+      return result.convert<LabourReviewStatusEntity>(data: data);
+    }
+    return result.convert();
+  }
+
+  /// OA用工审核的批量操作
+  Future<HttpResult> batchActionLabourReviews({
+    required String? recordIds,
+    required String? type,
+    String? auditMark,
+    CancelToken? cancelToken,
+  }) async {
+    //参数
+    Map<String, String> params = {};
+    params['record_ids'] = recordIds ?? "";
+    params['type'] = type ?? "";
+    if (Utils.isNotEmpty(auditMark)){
+      params['audit_mark'] = auditMark!;
+    }
+
+    final result = await httpProvider.requestNetResult(
+      ApiConstants.apiOALabourReviewBatchTH,
+      method: HttpMethod.POST,
+      params: params,
+      networkDebounce: true,
+      isShowLoadingDialog: true,
+      cancelToken: cancelToken,
+    );
+
+    if (result.isSuccess) {
+      return result.convert();
+    }
+    return result.convert();
+  }
 }

+ 2 - 0
packages/cs_plugin_basic/lib/service/app_config_service.dart

@@ -24,6 +24,8 @@ class ConfigService extends GetxService {
   //选择的国家,默认新加坡
   RxInt selectCountry = 1.obs;  //0 越南  1 新加坡  2 英国  3马来  4荷兰  5泰国
 
+  bool isTHOAType = false;  //泰国的模块当前选择的是ER还是OA类型,默认为ER类型
+
   // 设备信息
   /// android 设备信息
   AndroidDeviceInfo? androidDeviceInfo;

+ 70 - 4
packages/cs_plugin_platform/lib/engine/network/network_engine.dart

@@ -94,7 +94,7 @@ class NetworkEngine {
           final key = entry.key;
           final value = entry.value;
 
-          if (value.isNotEmpty && RegCheckUtils.isLocalImagePath(value)) {
+          if (value.isNotEmpty && RegCheckUtils.isLocalImagePath(value) && _isImageFile(value)) {
             // 以文件的方式压缩,获取到流对象
             Uint8List? stream = await FlutterImageCompress.compressWithFile(
               value,
@@ -106,10 +106,13 @@ class NetworkEngine {
             //传入压缩之后的流对象
             if (stream != null) {
               map[key] = MultipartFile.fromBytes(stream, filename: "file");
-            }else {
+            } else {
               //如果压缩失败使用原始路径File
               map[key] = MultipartFile.fromFileSync(value, filename: "file");
             }
+          } else {
+            //如果不是图片使用原始路径File
+            map[key] = MultipartFile.fromFileSync(value, filename: "file");
           }
         }
       }
@@ -120,7 +123,7 @@ class NetworkEngine {
           final key = entry.key;
           final value = entry.value;
 
-          if (value.isNotEmpty) {
+          if (value.isNotEmpty && _isImage(value)) {
             // 以流方式压缩,获取到流对象
             Uint8List stream = await FlutterImageCompress.compressWithList(
               value,
@@ -132,10 +135,13 @@ class NetworkEngine {
             //传入压缩之后的流对象
             if (stream != null) {
               map[key] = MultipartFile.fromBytes(stream, filename: "file_stream");
-            }else {
+            } else {
               //如果压缩失败使用原始流
               map[key] = MultipartFile.fromBytes(value, filename: "file_stream");
             }
+          } else {
+            //如果不是图片使用原始流
+            map[key] = MultipartFile.fromBytes(value, filename: "file_stream");
           }
         }
       }
@@ -199,4 +205,64 @@ class NetworkEngine {
       callback?.call(false, savePath);
     }
   }
+
+  //检查该路径的文件是否是图片类型
+  bool _isImageFile(String path) {
+    // 定义支持的图片扩展名
+    const List<String> imageExtensions = [
+      'jpg',
+      'jpeg',
+      'png',
+      'bmp',
+      'webp',
+    ];
+
+    if (!path.contains('.')) return false;
+
+    // 提取文件扩展名
+    final String extension = path.split('.').last.toLowerCase();
+    return imageExtensions.contains(extension);
+  }
+
+  //校验文件流是否是图片类型
+  bool _isImage(Uint8List bytes) {
+    if (bytes.length < 8) return false; // 确保有足够数据检测
+
+    // 检测常见图片格式
+    return _isJPEG(bytes) || _isPNG(bytes) || _isWebP(bytes) || _isBMP(bytes);
+  }
+
+  bool _isJPEG(Uint8List bytes) {
+    return bytes.length >= 2 && bytes[0] == 0xFF && bytes[1] == 0xD8;
+  }
+
+  bool _isPNG(Uint8List bytes) {
+    return bytes.length >= 8 &&
+        bytes[0] == 0x89 &&
+        bytes[1] == 0x50 && // P
+        bytes[2] == 0x4E && // N
+        bytes[3] == 0x47 && // G
+        bytes[4] == 0x0D && // CR
+        bytes[5] == 0x0A && // LF
+        bytes[6] == 0x1A && // EOF
+        bytes[7] == 0x0A; // LF
+  }
+
+  bool _isWebP(Uint8List bytes) {
+    return bytes.length >= 12 &&
+        bytes[0] == 0x52 && // R
+        bytes[1] == 0x49 && // I
+        bytes[2] == 0x46 && // F
+        bytes[3] == 0x46 && // F
+        bytes[8] == 0x57 && // W
+        bytes[9] == 0x45 && // E
+        bytes[10] == 0x42 && // B
+        bytes[11] == 0x50; // P
+  }
+
+  bool _isBMP(Uint8List bytes) {
+    return bytes.length >= 2 &&
+        bytes[0] == 0x42 && // B
+        bytes[1] == 0x4D; // M
+  }
 }

+ 3 - 1
packages/cs_router/lib/path/router_path.dart

@@ -150,6 +150,8 @@ class RouterPath {
   static const THLabourRequestOA = '/th/labour/request/oa';  //泰国的用工请求页面
   static const THLabourRequestAddOA = '/th/labour/request/add/oa';  //泰国的用工请求添加
   static const THLabourRequestWorkflowOA = '/th/labour/request/workflow/oa';  //泰国的用工状态流
+  static const THLabourReviewOA = '/th/labour/request/review/oa';  //泰国的用工审核
+  static const THLabourReviewWorkflowOA = '/th/labour/request/review/workflow/oa';  //泰国的用工审核
   static const THLabourRequestER = '/th/labour/request/er';  //泰国的用工请求 ER
   static const THLabourRequestERAdd = '/th/labour/request/er/add';  //泰国的用工请求添加 ER
   static const THJobListER = '/th/job/list/er';  //泰国的用工请求添加 ER
@@ -157,7 +159,7 @@ class RouterPath {
   static const THJobAppliedEditER = '/th/job/applied/edit/er';  //泰国的已申请列表修改员工考勤信息
   static const THJobAppliedEmployeeER = '/th/job/applied/employee/er';  //泰国的已申请列表员工详情信息
   static const THJobAppliedEmployeeRemarkER = '/th/job/applied/employee/remark/er';  //泰国的已申请列表员工的评价列表
-  static const THJobAppliedStaffWorkflow = '/th/job/applied/employee/workflow/er';  //泰国的已申请列表员工的评价列表
+  static const THJobAppliedStaffWorkflowER = '/th/job/applied/employee/workflow/er';  //泰国的已申请列表员工的评价列表
 
   //Runalone
   static const runAloneMain = '/runalone/main'; //独立运行的入口页面