4 次代碼提交 372a493e73 ... 527f03122e

作者 SHA1 備註 提交日期
  fanghuisheng 527f03122e 工作报告代码合并/公共配置优化/人脸识别模块优化 1 月之前
  fanghuisheng 32b0adb828 Merge branch 'master' of http://47.111.81.118:3000/uskycloud/usky-web-mobile into fanghuisheng 1 月之前
  gez c34eb6e3ea Merge branch 'ming' of uskycloud/usky-web-mobile into master 1 月之前
  ming db5bfc46ac 修复工作报告,已发送或定时编辑时,抄送人不会显异常 1 月之前

+ 30 - 50
src/components/oa-calendar/uni-calendar.vue

@@ -11,28 +11,24 @@
         </view>
       </view>
       <view class="uni-calendar__header">
-        <!-- <view class="uni-calendar__header-btn-box" @click.stop="pre">
-					<view class="uni-calendar__header-btn uni-calendar--left"></view>
-				</view> -->
+        <view class="uni-calendar__header-btn-box" v-if="false" @click.stop="pre">
+          <view class="uni-calendar__header-btn uni-calendar--left"></view>
+        </view>
+
         <picker mode="date" :value="date" fields="month" @change="bindDateChange">
           <text class="uni-calendar__header-text">{{ (nowDate.year || "") + " 年 " + (nowDate.month || "") + " 月" }}</text>
         </picker>
-        <!-- <view class="uni-calendar__header-btn-box" @click.stop="next">
-					<view class="uni-calendar__header-btn uni-calendar--right"></view>
-				</view> -->
-        <!-- <text class="uni-calendar__backtoday" @click="backtoday">{{todayText}}</text> -->
 
-        <view style="margin: auto"></view>
+        <view style="margin: auto">
+          <text class="uni-calendar__backtoday" v-if="false" @click="backtoday">{{ todayText }}</text>
+        </view>
 
         <view class="uni-calendar__header-right">
-          <view class="item">
-            <span class="item_title">巡检</span>
-            <span class="item_cont" style="color: #00cdac">{{ JSON.stringify(currentDateList) === "{}" ? 0 : currentDateList.patrolledCount }}</span>
-          </view>
-          <view class="item">
-            <span class="item_title">漏检</span>
-            <span class="item_cont" style="color: #f07d28">{{ JSON.stringify(currentDateList) === "{}" ? 0 : currentDateList.undetectedCount }}</span>
-          </view>
+          <slot name="headerRight"> </slot>
+        </view>
+
+        <view class="uni-calendar__header-btn-box" v-if="false" @click.stop="next">
+          <view class="uni-calendar__header-btn uni-calendar--right"></view>
         </view>
       </view>
       <view class="uni-calendar__box">
@@ -88,8 +84,6 @@ const { t } = initVueI18n(messages);
  * @property {String} endDate 日期选择范围-结束日期
  * @property {Boolean} range 范围选择
  * @property {Boolean} insert = [true|false] 插入模式,默认为false
- * 	@value true 弹窗模式
- * 	@value false 插入模式
  * @property {Boolean} clearDate = [true|false] 弹窗模式是否清空上次选择内容
  * @property {Array} selected 打点,期待格式[{date: '2019-06-27', info: '签到', data: { custom: '自定义信息', name: '自定义消息头',xxx:xxx... }}]
  * @property {Boolean} showMonth 是否选择月份为背景
@@ -145,10 +139,6 @@ export default {
       type: Boolean,
       default: true,
     },
-    currentDate: {
-      type: Object,
-      default: {},
-    },
   },
   data() {
     return {
@@ -157,7 +147,6 @@ export default {
       calendar: {},
       nowDate: "",
       aniMaskShow: false,
-      currentDateList: {},
     };
   },
   computed: {
@@ -215,9 +204,6 @@ export default {
       this.cale.setSelectInfo(this.nowDate.fullDate, newVal);
       this.weeks = this.cale.weeks;
     },
-    currentDate(obj) {
-      this.currentDateList = obj;
-    },
   },
   created() {
     // 获取日历方法实例
@@ -413,7 +399,7 @@ $uni-bg-color-mask: rgba(
 $uni-border-color: #ededed;
 $uni-text-color: #333;
 $uni-bg-color-hover: #f1f1f1;
-$uni-font-size-sm:12px;
+$uni-font-size-sm: 12px;
 $uni-font-size-base: 14px;
 $uni-text-color-placeholder: #808080;
 $uni-color-subtitle: #555555;
@@ -497,20 +483,14 @@ $uni-text-color-grey: #999;
 
 .uni-calendar--fixed-width {
   width: 50px;
-  // padding: 0 15px;
 }
 
 .uni-calendar__backtoday {
-  position: absolute;
-  right: 0;
-  top: 25rpx;
-  padding: 0 5px;
-  padding-left: 10px;
+  padding: 0 10px;
   height: 25px;
   line-height: 25px;
   font-size: $uni-font-size-sm;
-  border-top-left-radius: 25px;
-  border-bottom-left-radius: 25px;
+  border-radius: 25px;
   color: $uni-text-color;
   background-color: $uni-bg-color-hover;
 }
@@ -522,19 +502,19 @@ $uni-text-color-grey: #999;
   color: $uni-text-color;
 }
 
-.uni-calendar__header-right {
-  display: flex;
-
-  .item {
-    font-size: $uni-font-size-base;
-    .item_title {
-      margin-right: 5px;
+:deep() {
+  .uni-calendar__header-right {
+    display: flex;
+    .item {
+      font-size: $uni-font-size-base;
+      + .item {
+        margin-left: 10px;
+      }
+      .item_title {
+        margin-right: 5px;
+      }
     }
   }
-
-  .item + .item {
-    margin-left: 10px;
-  }
 }
 
 .uni-calendar__header-btn-box {
@@ -544,8 +524,8 @@ $uni-text-color-grey: #999;
   flex-direction: row;
   align-items: center;
   justify-content: center;
-  width: 50px;
-  height: 50px;
+  width: 20px;
+  height: 10px;
 }
 
 .uni-calendar__header-btn {
@@ -553,10 +533,10 @@ $uni-text-color-grey: #999;
   height: 10px;
   border-left-color: $uni-text-color-placeholder;
   border-left-style: solid;
-  border-left-width: 2px;
+  border-left-width: 1.5px;
   border-top-color: $uni-color-subtitle;
   border-top-style: solid;
-  border-top-width: 2px;
+  border-top-width: 1.5px;
 }
 
 .uni-calendar--left {

+ 14 - 1
src/components/oa-scroll/index.vue

@@ -142,7 +142,20 @@ const props = defineProps({
   },
 });
 
-const { pageSize, total, scrollTop, customClass, customStyle, refresherLoad, refresherEnabled, refresherEnabledTitle, refresherThreshold, refresherDefaultStyle, refresherBackground } = toRefs(props);
+const {
+  pageSize,
+  total,
+  scrollTop,
+  customClass,
+  customStyle,
+  refresherLoad,
+  refresherLoadTitle,
+  refresherEnabled,
+  refresherEnabledTitle,
+  refresherThreshold,
+  refresherDefaultStyle,
+  refresherBackground,
+} = toRefs(props);
 
 const state = reactive({
   StatusBarHeight: computed(() => {

+ 149 - 158
src/manifest.json

@@ -1,46 +1,46 @@
 {
-    "name": "综合智慧云",
-    "appid": "__UNI__36DE3A0",
-    "description": "综合智慧云APP,是一款助力于企业数字化的应用平台,帮助企业提升办公效率,实现组织数字化和业务数字化。",
-    "versionName": "2.1.9",
-    "versionCode": 19,
-    "transformPx": false,
-    "app-plus": {
-        "compatible": {
-            "ignoreVersion": true
+    "name" : "综合智慧云",
+    "appid" : "__UNI__36DE3A0",
+    "description" : "综合智慧云APP,是一款助力于企业数字化的应用平台,帮助企业提升办公效率,实现组织数字化和业务数字化。",
+    "versionName" : "2.2.4",
+    "versionCode" : 24,
+    "transformPx" : false,
+    "app-plus" : {
+        "compatible" : {
+            "ignoreVersion" : true
         },
-        "kernel": {
-            "ios": "WKWebview"
+        "kernel" : {
+            "ios" : "WKWebview"
         },
-        "usingComponents": true,
-        "nvueStyleCompiler": "uni-app",
-        "compilerVersion": 3,
-        "splashscreen": {
-            "alwaysShowBeforeRender": true,
-            "waiting": true,
-            "autoclose": true,
-            "delay": 0
+        "usingComponents" : true,
+        "nvueStyleCompiler" : "uni-app",
+        "compilerVersion" : 3,
+        "splashscreen" : {
+            "alwaysShowBeforeRender" : true,
+            "waiting" : true,
+            "autoclose" : true,
+            "delay" : 0
         },
-        "screenOrientation": [
+        "screenOrientation" : [
             "portrait-primary",
             "portrait-secondary",
             "landscape-primary",
             "landscape-secondary"
         ],
-        "modules": {
-            "VideoPlayer": {},
-            "iBeacon": {},
-            "Geolocation": {},
-            "Maps": {},
-            "Barcode": {},
-            "Fingerprint": {},
-            "Push": {},
-            "Camera": {},
-            "LivePusher": {}
+        "modules" : {
+            "VideoPlayer" : {},
+            "iBeacon" : {},
+            "Geolocation" : {},
+            "Maps" : {},
+            "Barcode" : {},
+            "Fingerprint" : {},
+            "Push" : {},
+            "Camera" : {},
+            "LivePusher" : {}
         },
-        "distribute": {
-            "android": {
-                "permissions": [
+        "distribute" : {
+            "android" : {
+                "permissions" : [
                     "<uses-feature android:name=\"android.hardware.camera\"/>",
                     "<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
                     "<uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\"/>",
@@ -80,165 +80,156 @@
                     "<uses-permission android:name=\"android.permission.RECEIVE_BOOT_COMPLETED\"/>",
                     "<uses-permission android:name=\"android.permission.SYSTEM_ALERT_WINDOW\"/>"
                 ],
-                "minSdkVersion": "",
-                "abiFilters": [
-                    "armeabi-v7a",
-                    "arm64-v8a"
-                ],
-                "targetSdkVersion": 30
+                "minSdkVersion" : "",
+                "abiFilters" : [ "armeabi-v7a", "arm64-v8a" ],
+                "targetSdkVersion" : 30
             },
-            "ios": {
-                "dSYMs": false,
-                "privacyDescription": {
-                    "NSPhotoLibraryUsageDescription": "该应用需要读取你的相册,用于上传头像",
-                    "NSPhotoLibraryAddUsageDescription": "该应用需要读取你的相册,用于拍照保存图片",
-                    "NSCameraUsageDescription": "该应用需要你的相机,用于你拍摄上传头像信息",
-                    "NSMicrophoneUsageDescription": "该应用需要使用你的麦克风,用于语音播放",
-                    "NSLocationWhenInUseUsageDescription": "该应用需要你的地理位置,用于天气、签到等功能",
-                    "NSLocationAlwaysUsageDescription": "该应用需要持续获取用户地理位置,用于天气、签到等功能",
-                    "NSLocationAlwaysAndWhenInUseUsageDescription": "该应用需要你的地理位置,用于天气、签到等功能",
-                    "NSCalendarsUsageDescription": "该应用需要获取你的日历,以便更好的体验",
-                    "NSContactsUsageDescription": "该应用需要读取你的通讯录,以便联系同事",
-                    "NSBluetoothPeripheralUsageDescription": "该应用需要你的蓝牙,以便读取相关蓝牙设备",
-                    "NFCReaderUsageDescription": "",
-                    "NSBluetoothAlwaysUsageDescription": "该应用需要你的蓝牙,以便读取相关蓝牙设备"
+            "ios" : {
+                "dSYMs" : false,
+                "privacyDescription" : {
+                    "NSPhotoLibraryUsageDescription" : "该应用需要读取你的相册,用于上传头像",
+                    "NSPhotoLibraryAddUsageDescription" : "该应用需要读取你的相册,用于拍照保存图片",
+                    "NSCameraUsageDescription" : "该应用需要你的相机,用于你拍摄上传头像信息",
+                    "NSMicrophoneUsageDescription" : "该应用需要使用你的麦克风,用于语音播放",
+                    "NSLocationWhenInUseUsageDescription" : "该应用需要你的地理位置,用于天气、签到等功能",
+                    "NSLocationAlwaysUsageDescription" : "该应用需要持续获取用户地理位置,用于天气、签到等功能",
+                    "NSLocationAlwaysAndWhenInUseUsageDescription" : "该应用需要你的地理位置,用于天气、签到等功能",
+                    "NSCalendarsUsageDescription" : "该应用需要获取你的日历,以便更好的体验",
+                    "NSContactsUsageDescription" : "该应用需要读取你的通讯录,以便联系同事",
+                    "NSBluetoothPeripheralUsageDescription" : "该应用需要你的蓝牙,以便读取相关蓝牙设备",
+                    "NFCReaderUsageDescription" : "",
+                    "NSBluetoothAlwaysUsageDescription" : "该应用需要你的蓝牙,以便读取相关蓝牙设备"
                 },
-                "UIBackgroundModes": ""
+                "UIBackgroundModes" : ""
             },
-            "sdkConfigs": {
-                "ad": {},
-                "maps": {
-                    "amap": {
-                        "appkey_ios": "fb35d03fbb17cbf7a8743a522da3c7fc",
-                        "appkey_android": "ffc71dfd4e576596027f8f45a1b8fb2f",
-                        "name": "amapBOujshtbA"
+            "sdkConfigs" : {
+                "ad" : {},
+                "maps" : {
+                    "amap" : {
+                        "appkey_ios" : "fb35d03fbb17cbf7a8743a522da3c7fc",
+                        "appkey_android" : "ffc71dfd4e576596027f8f45a1b8fb2f",
+                        "name" : "amapBOujshtbA"
                     }
                 },
-                "geolocation": {
-                    "system": {
-                        "__platform__": [
-                            "ios",
-                            "android"
-                        ]
+                "geolocation" : {
+                    "system" : {
+                        "__platform__" : [ "ios", "android" ]
                     },
-                    "amap": {
-                        "__platform__": [
-                            "ios",
-                            "android"
-                        ],
-                        "appkey_ios": "fb35d03fbb17cbf7a8743a522da3c7fc",
-                        "appkey_android": "ffc71dfd4e576596027f8f45a1b8fb2f",
-                        "name": "amapBOujshtbA"
+                    "amap" : {
+                        "__platform__" : [ "ios", "android" ],
+                        "appkey_ios" : "fb35d03fbb17cbf7a8743a522da3c7fc",
+                        "appkey_android" : "ffc71dfd4e576596027f8f45a1b8fb2f",
+                        "name" : "amapBOujshtbA"
                     }
                 },
-                "push": {
-                    "unipush": {
-                        "version": "2",
-                        "offline": true,
-                        "icons": {
-                            "small": {
-                                "hdpi": "unpackage/res/push/36x36.png",
-                                "ldpi": "unpackage/res/push/18x18.png",
-                                "mdpi": "unpackage/res/push/24x24.png",
-                                "xhdpi": "unpackage/res/push/48x48.png",
-                                "xxhdpi": "unpackage/res/push/72x72.png"
+                "push" : {
+                    "unipush" : {
+                        "version" : "2",
+                        "offline" : true,
+                        "icons" : {
+                            "small" : {
+                                "hdpi" : "unpackage/res/push/36x36.png",
+                                "ldpi" : "unpackage/res/push/18x18.png",
+                                "mdpi" : "unpackage/res/push/24x24.png",
+                                "xhdpi" : "unpackage/res/push/48x48.png",
+                                "xxhdpi" : "unpackage/res/push/72x72.png"
                             }
                         }
                     }
                 }
             },
-            "icons": {
-                "android": {
-                    "hdpi": "unpackage/res/icons/72x72.png",
-                    "xhdpi": "unpackage/res/icons/96x96.png",
-                    "xxhdpi": "unpackage/res/icons/144x144.png",
-                    "xxxhdpi": "unpackage/res/icons/192x192.png"
+            "icons" : {
+                "android" : {
+                    "hdpi" : "unpackage/res/icons/72x72.png",
+                    "xhdpi" : "unpackage/res/icons/96x96.png",
+                    "xxhdpi" : "unpackage/res/icons/144x144.png",
+                    "xxxhdpi" : "unpackage/res/icons/192x192.png"
                 },
-                "ios": {
-                    "appstore": "unpackage/res/icons/1024x1024.png",
-                    "ipad": {
-                        "app": "unpackage/res/icons/76x76.png",
-                        "app@2x": "unpackage/res/icons/152x152.png",
-                        "notification": "unpackage/res/icons/20x20.png",
-                        "notification@2x": "unpackage/res/icons/40x40.png",
-                        "proapp@2x": "unpackage/res/icons/167x167.png",
-                        "settings": "unpackage/res/icons/29x29.png",
-                        "settings@2x": "unpackage/res/icons/58x58.png",
-                        "spotlight": "unpackage/res/icons/40x40.png",
-                        "spotlight@2x": "unpackage/res/icons/80x80.png"
+                "ios" : {
+                    "appstore" : "unpackage/res/icons/1024x1024.png",
+                    "ipad" : {
+                        "app" : "unpackage/res/icons/76x76.png",
+                        "app@2x" : "unpackage/res/icons/152x152.png",
+                        "notification" : "unpackage/res/icons/20x20.png",
+                        "notification@2x" : "unpackage/res/icons/40x40.png",
+                        "proapp@2x" : "unpackage/res/icons/167x167.png",
+                        "settings" : "unpackage/res/icons/29x29.png",
+                        "settings@2x" : "unpackage/res/icons/58x58.png",
+                        "spotlight" : "unpackage/res/icons/40x40.png",
+                        "spotlight@2x" : "unpackage/res/icons/80x80.png"
                     },
-                    "iphone": {
-                        "app@2x": "unpackage/res/icons/120x120.png",
-                        "app@3x": "unpackage/res/icons/180x180.png",
-                        "notification@2x": "unpackage/res/icons/40x40.png",
-                        "notification@3x": "unpackage/res/icons/60x60.png",
-                        "settings@2x": "unpackage/res/icons/58x58.png",
-                        "settings@3x": "unpackage/res/icons/87x87.png",
-                        "spotlight@2x": "unpackage/res/icons/80x80.png",
-                        "spotlight@3x": "unpackage/res/icons/120x120.png"
+                    "iphone" : {
+                        "app@2x" : "unpackage/res/icons/120x120.png",
+                        "app@3x" : "unpackage/res/icons/180x180.png",
+                        "notification@2x" : "unpackage/res/icons/40x40.png",
+                        "notification@3x" : "unpackage/res/icons/60x60.png",
+                        "settings@2x" : "unpackage/res/icons/58x58.png",
+                        "settings@3x" : "unpackage/res/icons/87x87.png",
+                        "spotlight@2x" : "unpackage/res/icons/80x80.png",
+                        "spotlight@3x" : "unpackage/res/icons/120x120.png"
                     }
                 }
             },
-            "splashscreen": {
-                "androidStyle": "default",
-                "android": {
-                    "hdpi": "src/static/images/wt/bg.png"
+            "splashscreen" : {
+                "androidStyle" : "default",
+                "android" : {
+                    "hdpi" : "src/static/images/wt/bg.png"
                 },
-                "iosStyle": "common"
+                "iosStyle" : "common"
             }
         },
-        "nativePlugins": {},
-        "safearea": {
-            "offset": "none"
+        "nativePlugins" : {},
+        "safearea" : {
+            "offset" : "none"
         }
     },
-    "quickapp": {},
-    "mp-weixin": {
-        "appid": "",
-        "setting": {
-            "urlCheck": false,
-            "checkSiteMap": false
+    "quickapp" : {},
+    "mp-weixin" : {
+        "appid" : "",
+        "setting" : {
+            "urlCheck" : false,
+            "checkSiteMap" : false
         },
-        "usingComponents": true
+        "usingComponents" : true
     },
-    "mp-alipay": {
-        "usingComponents": true
+    "mp-alipay" : {
+        "usingComponents" : true
     },
-    "mp-baidu": {
-        "usingComponents": true
+    "mp-baidu" : {
+        "usingComponents" : true
     },
-    "mp-toutiao": {
-        "usingComponents": true
+    "mp-toutiao" : {
+        "usingComponents" : true
     },
-    "uniStatistics": {
-        "enable": false
+    "uniStatistics" : {
+        "enable" : false
     },
-    "h5": {
-        "publicPath": "./",
-        "title": "综合智慧云",
-        "router": {
-            "mode": "hash"
+    "h5" : {
+        "publicPath" : "./",
+        "title" : "综合智慧云",
+        "router" : {
+            "mode" : "hash"
         },
-        "devServer": {
-            "https": false,
-            "proxy": {}
+        "devServer" : {
+            "https" : false,
+            "proxy" : {}
         },
-        "sdkConfigs": {
-            "maps": {
-                "amap": {
-                    "key": "d4d73a7d572b6ff6028d5f67de62029a",
-                    "securityJsCode": "be916fcd16d0b33d228c49f0ff096b17",
-                    "serviceHost": ""
+        "sdkConfigs" : {
+            "maps" : {
+                "amap" : {
+                    "key" : "d4d73a7d572b6ff6028d5f67de62029a",
+                    "securityJsCode" : "be916fcd16d0b33d228c49f0ff096b17",
+                    "serviceHost" : ""
                 }
             }
         },
-        "optimization": {
-            "treeShaking": {
-                "enable": true
+        "optimization" : {
+            "treeShaking" : {
+                "enable" : true
             }
         },
-        "template": "index.html"
+        "template" : "index.html"
     },
-    "vueVersion": "3",
-    "locale": "zh-Hans"
-}
+    "vueVersion" : "3",
+    "locale" : "zh-Hans"
+}

+ 13 - 11
src/pages/business/common/projectMange/list/addEdit.vue

@@ -14,7 +14,7 @@
     :isSticky="false"
     :customStyle="{
       //#ifdef APP-PLUS || MP-WEIXIN
-      height: 'calc(100vh - 44px)',
+      height: `calc(100vh - (44px + ${proxy.$settingStore.StatusBarHeight}))`,
       //#endif
     }"
     :refresherLoad="false"
@@ -68,7 +68,9 @@
             disabledColor="transparent"
             disabled
           />
-          <u-button class="mt20" type="primary" style="width: 100px; height: 25px" @click="handleAction('公开状态', project_displayType)" shape="circle" icon="plus" size="mini"> 选择公开状态 </u-button>
+          <u-button class="mt20" type="primary" style="width: 100px; height: 25px" @click="handleAction('公开状态', project_displayType)" shape="circle" icon="plus" size="mini">
+            选择公开状态
+          </u-button>
         </view>
         <view class="content-area-item mt10 p10 bg-white">
           <view class="font14 weight mb10 required">项目负责人</view>
@@ -140,7 +142,7 @@ import { storageSystem } from "@/utils/storage"; // 公共方法引用
 /*----------------------------------公共变量-----------------------------------*/
 const systemStore = systemStores();
 const { proxy } = getCurrentInstance();
-const { project_status, project_type, project_ascription,project_displayType } = proxy.useDict("project_status", "project_type", "project_ascription","project_displayType");
+const { project_status, project_type, project_ascription, project_displayType } = proxy.useDict("project_status", "project_type", "project_ascription", "project_displayType");
 const props = defineProps({
   id: {
     type: String,
@@ -179,13 +181,14 @@ const { pageTitle, projectHeadList, projectMemberList, form, rules, actionShow,
 /** 添加人员按钮事件 */
 function insertUsers(key) {
   state.projectKey = key;
-  //将人员选中数据传入store中
-  systemStore.mallList.activeUserList = state[key];
   if (key === "projectHeadList") {
-    proxy.$tab.navigateTo(`/pages/business/common/projectMange/mall/index?number=1&type=1`);
+    proxy.$tab.navigateTo(`/pages/business/common/projectMange/mall/index?number=1&title=选择项目负责人`);
   } else if (key === "projectMemberList") {
-    proxy.$tab.navigateTo(`/pages/business/common/projectMange/mall/index?number=50&type=2`);
+    proxy.$tab.navigateTo(`/pages/business/common/projectMange/mall/index?number=50&title=选择项目成员`);
   }
+  setTimeout(() => {
+    uni.$emit("FathertuSon__UserMall", state[key]); //将值存储监听器
+  }, 500);
 }
 
 /** 删除人员按钮事件 */
@@ -211,7 +214,7 @@ function selectAction(e) {
   if (state.actionTitle == "项目类型") {
     state.form.projectType = e.value[0].value;
   } else if (state.actionTitle == "项目状态") {
-    state.form.projectStatus = e.value[0].value; 
+    state.form.projectStatus = e.value[0].value;
   } else if (state.actionTitle == "公开状态") {
     state.form.visibleRange = e.value[0].value;
   }
@@ -369,14 +372,13 @@ onShow(() => {
   proxy.$settingStore.systemThemeColor([1]);
 
   //监听组件返回数据
-  uni.$on("UserMall", function (value) {
-    console.log(value);
+  uni.$on("SontoFather__UserMall", function (value) {
     state[state.projectKey] = value;
   });
 });
 
 onUnload(() => {
-  uni.$off("UserMall"); //将值删除监听器
+  uni.$off("SontoFather__UserMall"); //将值删除监听器
 });
 </script>
 

+ 15 - 0
src/pages/business/common/projectMange/mall/components/mall-list.vue

@@ -179,6 +179,21 @@ export default {
       });
     },
   },
+  watch: {
+    activeUserList: {
+      handler(val, oldVal) {
+        if (val) {
+          val.forEach((e) => {
+            this.checkboxList.push(e.id);
+            this.checkboxUserData.push(e);
+            this.checkboxUserList.push(e.label);
+          });
+        }
+      },
+      immediate: false, //刷新加载 立马触发一次handler
+      deep: true, // 可以深度检测,里面每个值改变都会通知数据更新。
+    },
+  },
 };
 </script>
 

+ 17 - 12
src/pages/business/common/projectMange/mall/index.vue

@@ -19,7 +19,10 @@
     :isSticky="false"
     :customStyle="{
       //#ifdef APP-PLUS || MP-WEIXIN
-      height: 'calc(100vh - 44px)',
+      height: `calc(100vh - (44px + 48px + 60px + ${proxy.$settingStore.StatusBarHeight}))`,
+      //#endif
+      //#ifdef H5
+      height: 'calc(100vh - (0px + 48px + 60px))',
       //#endif
     }"
     :refresherLoad="false"
@@ -66,18 +69,17 @@ const state = reactive({
   activeUserNumber: undefined,
   pageTitle: "",
 });
-const { defaultHeadList, userList, activeUserList, activeUserNumber,pageTitle } = toRefs(state);
+const { defaultHeadList, userList, activeUserList, activeUserNumber, pageTitle } = toRefs(state);
 
 function init() {
   deptUserTreeSelect({ pageNum: "1", pageSize: "10000" }).then((res) => {
     state.userList = JSON.parse(JSON.stringify(res.data).replace(/value/g, "id"))[0].children;
   });
-  state.activeUserList = systemStore.mallList.activeUserList;
 }
 
 function handleSubmit(event) {
   proxy.$tab.navigateBack(1); //返回到需要执行方法的页面
-  uni.$emit("UserMall", event); //将值存储监听器
+  uni.$emit("SontoFather__UserMall", event); //将值存储监听器
 }
 
 function handleChange() {}
@@ -87,22 +89,25 @@ onReady(() => {});
 onShow(() => {});
 
 onLoad((options) => {
+  // 监听组件返回数据
+  uni.$on("FathertuSon__UserMall", function (value) {
+    state.activeUserList = value;
+  });
+
   if ("number" in options) {
     state.activeUserNumber = parseInt(options.number);
   }
-  init();
 
-  if (options.type==1) {
-    state.pageTitle = "选择项目负责人";
-  } else if (options.type==2) {
-    state.pageTitle = "选择项目成员";
-  }else{
-    state.pageTitle = "选择抄送人"
+  if ("title" in options) {
+    state.pageTitle = options.title;
   }
 
+  init();
 });
 
-onUnload(() => {});
+onUnload(() => {
+  uni.$off("FathertuSon__UserMall"); //将值删除监听器
+});
 </script>
 
 <style></style>

+ 4 - 7
src/pages/business/common/projectMange/record/details.vue

@@ -13,9 +13,6 @@
       //#ifdef APP-PLUS || MP-WEIXIN
       height: `calc(100vh - (44px + ${proxy.$settingStore.StatusBarHeight}))`,
       //#endif
-      //#ifdef H5
-      height: 'calc(100vh - (44px))',
-      //#endif
     }"
     :refresherLoad="false"
     :refresherEnabled="false"
@@ -62,7 +59,7 @@
         </view>
         <view class="content-area-center mb10">
           <view class="content-area-center-top">图片</view>
-          <view class="imageBox" v-if="JSON.parse(item.reportImage)&&JSON.parse(item.reportImage).length>0">
+          <view class="imageBox" v-if="JSON.parse(item.reportImage) && JSON.parse(item.reportImage).length > 0">
             <image class="image m5" style="width: 50px" mode="widthFix" v-for="(a, index) in JSON.parse(item.reportImage)" :key="index" :src="a.url" @click="previewImage(index)" />
           </view>
           <view class="imageBox" v-else>无</view>
@@ -70,7 +67,7 @@
 
         <view class="content-area-center mb10">
           <view class="content-area-center-top">附件 </view>
-          <view v-if="JSON.parse(item.reportFile)&&JSON.parse(item.reportFile).length>0">
+          <view v-if="JSON.parse(item.reportFile) && JSON.parse(item.reportFile).length > 0">
             <uni-link v-for="(file, index) in JSON.parse(item.reportFile)" :key="index" :href="file.url" text="file.url" style="color: rgba(0, 0, 0, 0.7)">{{ file.name }}</uni-link>
           </view>
           <view v-else>无</view>
@@ -179,8 +176,8 @@ function init() {
         dataList.value = requset.data.records;
         state.loading = false;
         pmReportReaders.value = requset.data.records[0].pmReportReaders;
-        state.tabsList[0].name=state.tabsList[0].name+'('+pmReportReaders.value.read+')';
-        state.tabsList[1].name=state.tabsList[1].name+'('+pmReportReaders.value.unRead+')';
+        state.tabsList[0].name = state.tabsList[0].name + "(" + pmReportReaders.value.read + ")";
+        state.tabsList[1].name = state.tabsList[1].name + "(" + pmReportReaders.value.unRead + ")";
         reportDetailData.value.treeSelectNodes = proxy.$common.findTreeNodes(tree.value, tabsCurrent.value == 0 ? pmReportReaders.value.readAlready : pmReportReaders.value.readNotAlready);
         var imgs = JSON.parse(dataList.value[0].reportImage);
         var files = JSON.parse(dataList.value[0].reportFile);

+ 36 - 50
src/pages/business/common/projectMange/record/timingLog.vue

@@ -1,22 +1,19 @@
 <template>
   <u-sticky class="shadow-default" bgColor="#fff" style="top: 0">
-    <u-navbar :titleStyle="{ color: '#000' }" :autoBack="true" title="定时日志" :placeholder="true" :safeAreaInsetTop="true" bgColor="#fff">
-     
-    </u-navbar>
-   
+    <u-navbar :titleStyle="{ color: '#000' }" :autoBack="true" title="定时日志" :placeholder="true" :safeAreaInsetTop="true" bgColor="#fff"> </u-navbar>
   </u-sticky>
 
   <oa-scroll
     customClass="record-container scroll-height"
     :pageSize="pageSize"
     :total="total"
-    :isSticky="true"
+    :isSticky="false"
     :customStyle="{
       //#ifdef APP-PLUS || MP-WEIXIN
-      height: 'calc(100vh - 40px)',
+      height: `calc(100vh - (44px + ${proxy.$settingStore.StatusBarHeight}))`,
       //#endif
       //#ifdef H5
-      height: 'calc(100vh - 40px)',
+      height: 'calc(100vh - (44px))',
       //#endif
     }"
     :refresherLoad="true"
@@ -30,14 +27,13 @@
     :data-theme="'theme-' + proxy.$settingStore.themeColor.name"
   >
     <template #default>
-
       <u-loading-page :loading="state.loading" fontSize="16" style="z-index: 99"></u-loading-page>
       <view class="content-area" v-for="(group, date) in proxy.$common.groupedItems(state.timedList, 'submitDate')" :key="date">
         <view class="content-area-time font14">{{ proxy.$time.jktTimes(date, "否") }}</view>
         <view class="content-area-center bg-white" v-for="(el, ind) in group" :key="ind">
-          <view class="content-area-top menu-item" style="float:right;padding:10px 0px">
+          <view class="content-area-top menu-item" style="float: right; padding: 10px 0px">
             <view class="content-area-top-time"> </view>
-            <u-icon  class="content-area-top-icon" name="more-dot-fill" size="20" color="#000" @click="moreClick(el)"></u-icon>
+            <u-icon class="content-area-top-icon" name="more-dot-fill" size="20" color="#000" @click="moreClick(el)"></u-icon>
           </view>
           <view class="flex mb10" @click="goContentDetails(el)">
             <u-avatar
@@ -57,17 +53,15 @@
           <view class="mb5" @click="goContentDetails(el)">
             <u-text :text="el.contentText.length >= 100 ? el.contentText.slice(0, 100) + '···' : el.contentText" color="#666666" size="14"></u-text>
           </view>
-          <view style="font-size:12px;color:#a7a4a4">
-            <u-button size="mini" style="width:50px;float:left;margin-right:5px;line-height:18px;height:18px">定时日志</u-button>
+          <view style="font-size: 12px; color: #a7a4a4">
+            <u-button size="mini" style="width: 50px; float: left; margin-right: 5px; line-height: 18px; height: 18px">定时日志</u-button>
             将于 {{ el.timingTime.replace("T", " ").slice(0, 16) }} 发布
           </view>
-        
         </view>
       </view>
     </template>
   </oa-scroll>
 
-
   <u-popup :show="popup.show" mode="bottom" bgColor="#fff" :round="10" @close="popup.show = false">
     <view
       :style="{
@@ -76,7 +70,6 @@
         overflow: 'hidden',
       }"
     >
-     
       <u-button
         class="custom-style"
         type="info"
@@ -121,13 +114,8 @@
     </view>
   </u-popup>
 
-  
-
-
-
   <uni-popup ref="alertDialog" type="dialog">
-    <uni-popup-dialog :type="state.tip.type" cancelText="取消" confirmText="确定" title="操作提醒" :content="state.tip.content" @confirm="dialogConfirm"
-      @close="dialogClose"></uni-popup-dialog>
+    <uni-popup-dialog :type="state.tip.type" cancelText="取消" confirmText="确定" title="操作提醒" :content="state.tip.content" @confirm="dialogConfirm" @close="dialogClose"></uni-popup-dialog>
   </uni-popup>
 
   <u-modal
@@ -140,7 +128,6 @@
     @cancel="modal.show = false"
     @close="modal.show = false"
   ></u-modal>
-
 </template>
 
 <script setup>
@@ -174,17 +161,16 @@ const state = reactive({
   },
   eventList: {}, //数据存储
 
-
-  tip:{
-    type:undefined,//弹框类型
-    content:"",//提示信息
-    data:{},//带入数据
-    operation:undefined,//操作类型
+  tip: {
+    type: undefined, //弹框类型
+    content: "", //提示信息
+    data: {}, //带入数据
+    operation: undefined, //操作类型
   },
-  timedList:[]
+  timedList: [],
 });
 
-const {pageSize, current, total,popup,eventList,modal,timedList} = toRefs(state);
+const { pageSize, current, total, popup, eventList, modal, timedList } = toRefs(state);
 /**
  * 操作弹框提醒
  * @param type  弹框类型
@@ -192,20 +178,20 @@ const {pageSize, current, total,popup,eventList,modal,timedList} = toRefs(state)
  * @param item 带入数据
  * @param operation 操作类型
  */
- function tips(type,content,item,operation){
-  state.tip.type=type
-  state.tip.content=content
-  state.tip.data=item
-  state.tip.operation=operation
-  proxy.$refs.alertDialog.open()
+function tips(type, content, item, operation) {
+  state.tip.type = type;
+  state.tip.content = content;
+  state.tip.data = item;
+  state.tip.operation = operation;
+  proxy.$refs.alertDialog.open();
 }
 /**弹框确定操作 */
-function dialogConfirm(){
-  if(state.tip.operation =='delete'){
-    handleSubmit('delete',state.tip.data)
+function dialogConfirm() {
+  if (state.tip.operation == "delete") {
+    handleSubmit("delete", state.tip.data);
   }
-  if(state.tip.operation=='exit'){
-    handleSubmit('exit',state.tip.data)
+  if (state.tip.operation == "exit") {
+    handleSubmit("exit", state.tip.data);
   }
 }
 /**
@@ -213,8 +199,8 @@ function dialogConfirm(){
  */
 function init() {
   projectApi()
-    .TimedReports({
-     }).then((requset) => {
+    .TimedReports({})
+    .then((requset) => {
       state.timedList = requset.data;
       requset.data.forEach((el) => {
         el.contentText = "";
@@ -224,10 +210,10 @@ function init() {
       });
       state.total = requset.data.length;
       state.loading = false;
-     })
+    })
     .catch((err) => {
       state.loading = false;
-    })
+    });
 }
 
 /**
@@ -265,7 +251,7 @@ function handleModal(type, content) {
 }
 
 /** 编辑、删除日报*/
-function handleSubmit(type,item) {
+function handleSubmit(type, item) {
   if (type === "update") {
     proxy.$tab.navigateTo(`/pages/business/common/projectMange/write/insert?templateId=1&id=${item.id}`);
     state.modal.show = false;
@@ -281,7 +267,7 @@ function handleSubmit(type,item) {
       .catch((errors) => {
         proxy.$modal.msg(errors);
       });
-  } 
+  }
 }
 
 onReady(() => {});
@@ -335,12 +321,12 @@ onUnload(() => {
   }
 }
 
-.pp{
+.pp {
   text-align: left;
 }
 </style>
 <style>
-.pp .u-modal__content{
-  justify-content: left !important
+.pp .u-modal__content {
+  justify-content: left !important;
 }
 </style>

+ 113 - 141
src/pages/business/common/projectMange/write/components/template1.vue

@@ -1,6 +1,6 @@
 <template>
   <view class="content-area">
-    <view class="content-area-title font12 mtb5 plr10" v-if="!state.form.id">{{state.form.id}}实时保存,保存时间 {{ saveTime }}</view>
+    <view class="content-area-title font12 mtb5 plr10" v-if="!state.form.id">{{ state.form.id }}实时保存,保存时间 {{ saveTime }}</view>
 
     <view class="content-area-item p10 bg-white">
       <view class="font14 weight mb10 required">工作内容</view>
@@ -67,30 +67,29 @@
     </view>
     <view class="content-area-item mt10 p10 bg-white">
       <view class="font14 weight mb10">图片上传</view>
-      <view style="color:#f56c6c;font-size:11px;margin-bottom:10px">( 注:不可同步钉钉,最多上传5张 )</view>
+      <view style="color: #f56c6c; font-size: 11px; margin-bottom: 10px">( 注:不可同步钉钉,最多上传5张 )</view>
       <oa-upload :uploadCount="5" :uploadList="reportImage1" :uploadListSrc="'url'" @uploadSuccessChange="uploadSuccessChange" @uploadDeleteChange="uploadDeleteChange"></oa-upload>
     </view>
     <view class="content-area-item mt10 p10 bg-white">
       <view class="font14 weight mb10">附件上传</view>
-      <view style="color:#f56c6c;font-size:11px;margin-bottom:10px">( 注:不可同步钉钉,最多上传5个 )</view>
-      <uni-file-picker limit="5" 
-        @select='selectUpload' 
-          v-model="reportFile1"
-					:auto-upload='false' 
-					file-extname='git,pdf,docx,doc,xls,xlsx,ppt,pptx,txt,zip,rar,7z,gz,bz2,tar,tgz,tbz,txz,apk,ipa,mp3,mp4,avi,flv,rmvb,wmv,mkv,mov,wma,aac,m4a,amr,ogg,flac,wav,amr,ape,m4r,aac,ac3,dts,m4b,m4p,m4v,mp2,mpe,mpeg,mpg,mpv,ogv,rm,swf,vob,wmv,3gp,3g2,asf,asx,avi,flv,m2ts,m4v,mkv,mov,mp4,mpg,mpeg,rm,swf,vob,wmv,3gp,3g2,asf,asx,avi,' 
-					file-mediatype="all" 
-		  >
+      <view style="color: #f56c6c; font-size: 11px; margin-bottom: 10px">( 注:不可同步钉钉,最多上传5个 )</view>
+      <uni-file-picker
+        limit="5"
+        @select="selectUpload"
+        v-model="reportFile1"
+        :auto-upload="false"
+        file-extname="git,pdf,docx,doc,xls,xlsx,ppt,pptx,txt,zip,rar,7z,gz,bz2,tar,tgz,tbz,txz,apk,ipa,mp3,mp4,avi,flv,rmvb,wmv,mkv,mov,wma,aac,m4a,amr,ogg,flac,wav,amr,ape,m4r,aac,ac3,dts,m4b,m4p,m4v,mp2,mpe,mpeg,mpg,mpv,ogv,rm,swf,vob,wmv,3gp,3g2,asf,asx,avi,flv,m2ts,m4v,mkv,mov,mp4,mpg,mpeg,rm,swf,vob,wmv,3gp,3g2,asf,asx,avi,"
+        file-mediatype="all"
+      >
       </uni-file-picker>
-       <!-- 文件列表回显 -->
-       <br>
-      <view v-for="(file, index) in reportFile1" :key="index" style="border-bottom:1px solid #eee;margin:6px;padding:6px;font-size:12px">
-       <uni-link :href="file.url" text="file.url">{{file.name}}</uni-link>
-        <uni-icons type="closeempty" size="12" style="float:right" @click="delectFile(file)"></uni-icons>
+      <!-- 文件列表回显 -->
+      <br />
+      <view v-for="(file, index) in reportFile1" :key="index" style="border-bottom: 1px solid #eee; margin: 6px; padding: 6px; font-size: 12px">
+        <uni-link :href="file.url" text="file.url">{{ file.name }}</uni-link>
+        <uni-icons type="closeempty" size="12" style="float: right" @click="delectFile(file)"></uni-icons>
       </view>
     </view>
 
-    
-
     <view class="content-area-item mt10 p10 bg-white">
       <view class="font14 weight mb10">抄送到人</view>
       <avatarList :userList="userList" @deleteUsers="deleteUsers" />
@@ -144,51 +143,38 @@
     <view class="app-button-padding"></view>
     <view class="app-button-fixed">
       <!-- {{ form }} -->
-      <u-button class="app-buttom" type="primary" @click="handleSubmit('提交')" shape="circle"> {{ form.isRegularlySend == 1 &&form.reportStatus!=1 ?  "保 存" : "确 定" }} </u-button>
+      <u-button class="app-buttom" type="primary" @click="handleSubmit('提交')" shape="circle"> {{ form.isRegularlySend == 1 && form.reportStatus != 1 ? "保 存" : "确 定" }} </u-button>
     </view>
   </view>
 
   <u-datetime-picker :show="timeShow" v-model="timeValue" mode="datetime" :closeOnClickOverlay="true" @cancel="timeShow = false" @confirm="timeConfirm"></u-datetime-picker>
 
   <u-modal :show="modalShow" title="" :confirmText="'确定'" :cancelText="'取消'" :zoom="false" :showCancelButton="true" @confirm="modalConfirm" @cancel="modalShow = false">
-    <view class="slot-content" style="max-height: 45vh;overflow:auto">
-     
-    <view v-if="projectsList.length > 0">
-    
-      <u-checkbox-group v-model="projectsCheck" placement="row" :size="14" style="max-height: 100%; overflow: auto">
-        <view class="checkbox-group-title">最近使用</view>
-        <block  v-for="(item, index) in projectsList">
-          <u-checkbox v-if="item.submissions>0"
-            :customStyle="{ marginBottom: '8px', width: '50%' }"
-            :label="item.projectName+' ('+item.submissions+'次)'"
-            :name="item.id"
-            :activeColor="proxy.$settingStore.themeColor.color"
-          >
-          </u-checkbox>
-        </block>
-				<u-line class="u-line"  color="info" style="margin:10px 0"></u-line>
-
-
-        <view  class="checkbox-group-title">其他</view>
-  
-        <block  v-for="(item, index) in projectsList">
-          <u-checkbox v-if="!item.submissions"
-            :customStyle="{ marginBottom: '8px', width: '50%' }"
-            :label="item.projectName"
-            :name="item.id"
-            :activeColor="proxy.$settingStore.themeColor.color"
-          >
-        </u-checkbox>
-       
-  
-           
-       
-        </block>
-
-       
-      </u-checkbox-group>
- 
-      <!-- <u-checkbox-group v-else v-model="projectsCheck" placement="row" :size="14"  style="max-height: 100%; overflow: auto">
+    <view class="slot-content" style="max-height: 45vh; overflow: auto">
+      <view v-if="projectsList.length > 0">
+        <u-checkbox-group v-model="projectsCheck" placement="row" :size="14" style="max-height: 100%; overflow: auto">
+          <view class="checkbox-group-title">最近使用</view>
+          <block v-for="(item, index) in projectsList">
+            <u-checkbox
+              v-if="item.submissions > 0"
+              :customStyle="{ marginBottom: '8px', width: '50%' }"
+              :label="item.projectName + ' (' + item.submissions + '次)'"
+              :name="item.id"
+              :activeColor="proxy.$settingStore.themeColor.color"
+            >
+            </u-checkbox>
+          </block>
+          <u-line class="u-line" color="info" style="margin: 10px 0"></u-line>
+
+          <view class="checkbox-group-title">其他</view>
+
+          <block v-for="(item, index) in projectsList">
+            <u-checkbox v-if="!item.submissions" :customStyle="{ marginBottom: '8px', width: '50%' }" :label="item.projectName" :name="item.id" :activeColor="proxy.$settingStore.themeColor.color">
+            </u-checkbox>
+          </block>
+        </u-checkbox-group>
+
+        <!-- <u-checkbox-group v-else v-model="projectsCheck" placement="row" :size="14"  style="max-height: 100%; overflow: auto">
         <u-checkbox
           :customStyle="{ marginBottom: '8px', width: '50%' }"
           v-for="(item, index) in projectsList"
@@ -199,8 +185,8 @@
         >
         </u-checkbox>
       </u-checkbox-group> -->
-    </view>
-      
+      </view>
+
       <view v-else>请联系项目管理人员给您分配项目后重试!</view>
     </view>
   </u-modal>
@@ -255,8 +241,8 @@ const state = reactive({
   userDate: [],
   saveTime: "",
 });
-const reportImage1=ref([])//图片
-const reportFile1=ref([])//附件
+const reportImage1 = ref([]); //图片
+const reportFile1 = ref([]); //附件
 const { timeShow, timeValue, modalShow } = toRefs(modal);
 const { form, projectsCheck, projectsList, userList, userDate, saveTime } = toRefs(state);
 
@@ -264,11 +250,9 @@ const { form, projectsCheck, projectsList, userList, userDate, saveTime } = toRe
  * @初始化
  */
 function init() {
-  dUserList().then((res) => {
-    state.userDate = res.data;
-  });
-
-
+  // dUserList().then((res) => {
+  //   state.userDate = res.data;
+  // });
 }
 
 /** 时间选择器确定按钮点击事件 */
@@ -288,10 +272,11 @@ function switchChage(e, key) {
 
 /** 添加人员按钮事件 */
 function insertUsers() {
-  //将人员选中数据传入store中
-  systemStore.mallList.activeUserList = state.userList;
- 
-  proxy.$tab.navigateTo(`/pages/business/common/projectMange/mall/index?number=200&type=3`);
+  proxy.$tab.navigateTo(`/pages/business/common/projectMange/mall/index?number=200&title=选择抄送人`).then(() => {
+    setTimeout(() => {
+      uni.$emit("FathertuSon__UserMall", state.userList); //将值存储监听器
+    }, 500);
+  });
 }
 
 /** 删除人员按钮事件 */
@@ -316,7 +301,7 @@ function insertProjects() {
 
 /** 实时保存填写数据 */
 function realTimeSaving() {
-  if(!state.form.id){
+  if (!state.form.id) {
     state.saveTime = proxy.$time.formatterDate(new Date(), "hh:mm");
     storageSystem.set("project", state);
   }
@@ -352,57 +337,52 @@ function modalConfirm() {
 /**
  * @图片上传成功回调
  */
- function uploadSuccessChange(e) {
+function uploadSuccessChange(e) {
   reportImage1.value.push({
     name: e.name,
     url: e.url,
-  })
-  reportImage1.value=reportImage1.value.slice(0,5)
-  realTimeSaving()
+  });
+  reportImage1.value = reportImage1.value.slice(0, 5);
+  realTimeSaving();
 }
 /**
  * @图片删除回调
  */
- function uploadDeleteChange(e) {
+function uploadDeleteChange(e) {
   reportImage1.value = e;
-  realTimeSaving()
+  realTimeSaving();
 }
 
-
-
-
-
 /**
  * @文件删除
  */
-function delectFile(param){
+function delectFile(param) {
   reportFile1.value = reportFile1.value.filter(function (item) {
-    return item.name!=param.name;
+    return item.name != param.name;
   });
-  realTimeSaving()
+  realTimeSaving();
 }
 
-
 /**
  * @文件上传
  */
 function selectUpload(e) {
   // console.log('上传:', e)
 
-    e.tempFilePaths.forEach((item,index) => {
-      uni.uploadFile({
-        url: config.baseUrl+'/service-file/upload', 
-        filePath: item,
-        name: 'file',
-        success: (uploadFileRes) => {
-          reportFile1.value.push(JSON.parse(uploadFileRes.data).data)
-          realTimeSaving()
-        },
-        fail: (err) => {
-          console.log(err);
-        }
-      })
-   })
+  e.tempFilePaths.forEach((item, index) => {
+    uni.uploadFile({
+      url: config.baseUrl + "/service-file/upload",
+      filePath: item,
+      name: "file",
+      success: (uploadFileRes) => {
+        reportFile1.value.push(JSON.parse(uploadFileRes.data).data);
+        realTimeSaving();
+      },
+      fail: (err) => {
+        console.log(err);
+      },
+    });
+  });
 }
 // function delectUpload(e){
 //   console.log(e)
@@ -414,8 +394,6 @@ function selectUpload(e) {
 // 	console.log('上传失败:', e)
 // }
 
-
-
 /** 提交 */
 function handleSubmit() {
   state.form.sendDingTalk == true ? 1 : 0;
@@ -425,27 +403,26 @@ function handleSubmit() {
   state.form.workContents.forEach((e) => {
     e.workTime = Number(e.workTime);
   });
-  state.form.reportImage=JSON.stringify(reportImage1.value);
-  state.form.reportFile=JSON.stringify(reportFile1.value);
+  state.form.reportImage = JSON.stringify(reportImage1.value);
+  state.form.reportFile = JSON.stringify(reportFile1.value);
   projectApi()
     .ReportInsert(state.form)
     .then((requset) => {
       proxy.$tab.redirectTo("/pages/business/common/projectMange/record/index"); //返回到需要执行方法的页面
 
       // storageSystem.set("project", state);
-    }).catch((err) => {
-     
-    });;
+    })
+    .catch((err) => {});
 }
 watch(
   () => reportFile1.value.length,
   (val) => {
-    var element = document.querySelector('.files-button');
-   if(reportFile1.value.length>=5){
-    element.style.display = 'none';
-   }else{
-    element.style.display = 'block';
-   }
+    var element = document.querySelector(".files-button");
+    if (reportFile1.value.length >= 5) {
+      element.style.display = "none";
+    } else {
+      element.style.display = "block";
+    }
   }
 );
 
@@ -457,18 +434,19 @@ watch(
     state.projectsList = [];
     state.form.reportImage = [];
     state.form.reportFile = [];
-   
+
     Object.keys(props.projectList).forEach((key) => {
       state.form[key] = props.projectList[key];
     });
- 
-    reportImage1.value=state.form.reportImage?JSON.parse(state.form.reportImage):[];
-    reportFile1.value=state.form.reportFile?JSON.parse(state.form.reportFile):[];
+
+    reportImage1.value = state.form.reportImage ? JSON.parse(state.form.reportImage) : [];
+    reportFile1.value = state.form.reportFile ? JSON.parse(state.form.reportFile) : [];
     state.form.workContents.forEach((e) => {
       state.projectsCheck.push(e.projectId);
     });
     var ccTo = state.form.ccTo.length > 0 ? state.form.ccTo.split(",").map((num) => Number(num)) : [];
-    // setTimeout(function () {
+    dUserList().then((res) => {
+      state.userDate = res.data;
       state.userDate.forEach((e) => {
         if (ccTo.includes(e.userId)) {
           state.userList.push({
@@ -487,44 +465,38 @@ watch(
           });
         }
       });
-    // }, 300);
+    });
 
-    if(!state.form.id){
-        storageSystem.set("project", state);
-      }
+    if (!state.form.id) {
+      storageSystem.set("project", state);
+    }
   }
 );
 
 onReady(() => {});
 
 onShow(() => {
-
   init();
 
-
   //循环将缓存数据遍历
 
-  if(!state.form.id){
+  if (!state.form.id) {
     var storages = storageSystem.get("project");
     Object.keys(storages).forEach((key) => {
       state[key] = storages[key];
     });
   }
-  
-  
 
   // 监听组件返回数据
-  uni.$on("UserMall", function (value) {
+  uni.$on("SontoFather__UserMall", function (value) {
     state.userList = value;
-    if(!state.form.id){
+    if (!state.form.id) {
       realTimeSaving();
     }
-   
   });
 });
 
 onLoad((options) => {
-
   if (options.id) {
     state.form.id = options.id;
   } else {
@@ -533,24 +505,24 @@ onLoad((options) => {
 });
 
 onUnload(() => {
-  uni.$off("UserMall"); //将值删除监听器
+  uni.$off("SontoFather__UserMall"); //将值删除监听器
 });
 </script>
-<style lang="scss" >
- :deep(.uni-file-picker__lists, .is-text-box){
-  display:none!important;
-  opacity:0!important;
-  height:0!important;
+<style lang="scss">
+:deep(.uni-file-picker__lists, .is-text-box) {
+  display: none !important;
+  opacity: 0 !important;
+  height: 0 !important;
 }
 </style>
 <style lang="scss" scoped>
-
-.checkbox-group-title{
-  display:block;width:100%;
-  font-size:16px;
-  font-weight:bold;
+.checkbox-group-title {
+  display: block;
+  width: 100%;
+  font-size: 16px;
+  font-weight: bold;
   note-color: #909399;
-  margin-bottom:10px;
+  margin-bottom: 10px;
 }
 :deep() {
   .u-cell__body {

+ 1 - 1
src/pages/business/common/projectMange/write/index.vue

@@ -19,7 +19,7 @@
     :isSticky="true"
     :customStyle="{
       //#ifdef APP-PLUS || MP-WEIXIN
-      height: 'calc(100vh - 88px)',
+      height: `calc(100vh - (88px + ${proxy.$settingStore.StatusBarHeight}))`,
       //#endif
     }"
     :refresherLoad="false"

+ 7 - 10
src/pages/business/common/projectMange/write/insert.vue

@@ -6,7 +6,7 @@
           <u-icon name="arrow-left" size="20" color="#000"></u-icon>
         </view>
       </template>
-      <template #right v-if="state.pageTitle=='报告填写'">
+      <template #right v-if="state.pageTitle == '报告填写'">
         <view class="u-navbar__content__right__item">
           <u-icon name="more-dot-fill" size="20" color="#000" @click="moreClick()"></u-icon>
         </view>
@@ -19,7 +19,7 @@
     :isSticky="false"
     :customStyle="{
       //#ifdef APP-PLUS || MP-WEIXIN
-      height: 'calc(100vh - 44px)',
+      height: `calc(100vh - (44px + ${proxy.$settingStore.StatusBarHeight}))`,
       //#endif
     }"
     :refresherLoad="false"
@@ -67,18 +67,17 @@ const state = reactive({
   newProjectList: {},
   pageTitle: "",
 });
-const { modalShow, newProjectList,pageTitle } = toRefs(state);
+const { modalShow, newProjectList, pageTitle } = toRefs(state);
 
 function moreClick() {
   state.modalShow = true;
 }
 
-
 /**
  * @列表查询
  * @api接口查询
  */
- function selectListApi() {
+function selectListApi() {
   projectApi()
     .ProjectsWeekList({
       id: parseInt(props.id),
@@ -86,8 +85,8 @@ function moreClick() {
     .then((requset) => {
       if (requset.data.length > 0) {
         const data = requset.data[1].weekData[0];
-        state.newProjectList =data
-        console.log(state.newProjectList)
+        state.newProjectList = data;
+        console.log(state.newProjectList);
       }
     })
     .catch((err) => {});
@@ -119,7 +118,6 @@ function handleSubmit(type, id) {
       });
   }
   if (type === "update") {
-
   }
 }
 
@@ -141,9 +139,8 @@ onLoad((options) => {
     selectListApi();
   } else {
     state.pageTitle = "报告填写";
-    state.newProjectList={}
+    state.newProjectList = {};
   }
-
 });
 
 onUnload(() => {});

+ 1 - 2
src/pages/business/fireIot/facilitiesGather/mapGather.vue

@@ -20,13 +20,12 @@ const commonStore = commonStores(); //全局公共Store
 
 const { proxy } = getCurrentInstance();
 
-const pages = getCurrentPages();
-
 const dataArray = commonStore.facilitiesGatherArray;
 const dataType = commonStore.facilitiesGatherType;
 
 // #ifdef APP-PLUS
 setTimeout(() => {
+  var pages = getCurrentPages();
   var currentWebview = pages[pages.length - 1].$getAppWebview();
   var wv = currentWebview.children()[0];
   wv.evalJS(`receiveData(${JSON.stringify({ dataArray: dataArray, dataType: dataType })})`);

+ 1 - 1
src/pages/business/fireIot/facilitiesManage/mapFacilitiesView.vue

@@ -21,7 +21,6 @@ import { baseFacilityType, baseGgpFacilityList } from "@/api/business/fireIot/fa
 const commonStore = commonStores(); //全局公共Store
 
 const { proxy } = getCurrentInstance();
-const pages = getCurrentPages();
 
 const dataArray = ref();
 const typeCode = ref("");
@@ -92,6 +91,7 @@ function analysisData(data) {
  */
 function handleChildren(data) {
   // #ifdef APP-PLUS
+  var pages = getCurrentPages();
   var currentWebview = pages[pages.length - 1].$getAppWebview();
   var wv = currentWebview.children()[0];
   wv.evalJS(`receiveData(${JSON.stringify(data)})`);

+ 13 - 2
src/pages/business/zhaf/xunJian/plan/index.vue

@@ -11,7 +11,18 @@
   >
     <template #default>
       <!-- 日历组件 -->
-      <oa-calendar class="uni-calendar--hook" :selected="info.selected" :showMonth="false" @change="change" @monthSwitch="monthSwitch" :currentDate="currentDateList" />
+      <oa-calendar class="uni-calendar--hook" :selected="info.selected" :showMonth="false" @change="change" @monthSwitch="monthSwitch">
+        <template #headerRight>
+          <view class="item">
+            <span class="item_title">巡检</span>
+            <span class="item_cont" style="color: #00cdac">{{ JSON.stringify(currentDateList) === "{}" ? 0 : currentDateList.patrolledCount }}</span>
+          </view>
+          <view class="item">
+            <span class="item_title">漏检</span>
+            <span class="item_cont" style="color: #f07d28">{{ JSON.stringify(currentDateList) === "{}" ? 0 : currentDateList.undetectedCount }}</span>
+          </view>
+        </template>
+      </oa-calendar>
 
       <!-- 分段器组件 -->
       <view class="app-subsection">
@@ -321,7 +332,7 @@ function activitiesApi() {
  * @统计
  * @api接口请求
  */
-const currentDate = ref(proxy.$time.getDate().year + "-" + proxy.$time.getDate().month + "-" + proxy.$time.getDate().dates); //统计时间数据存储
+const currentDate = ref(proxy.$dayjs().format("YYYY-MM-DD")); //统计时间数据存储
 const currentDatevalue = ref(new Date());
 const currentDateList = ref({}); //统计list数据存储
 function currentApi() {

+ 1 - 1
src/pages/business/zhaf/xunJian/xunJian.vue

@@ -53,7 +53,7 @@ const xunJianStore = xunJianStores(); //全局变量值Store
 /*----------------------------------变量声明-----------------------------------*/
 const inspectList = proxy.$constData.xunJianList; //九宫格json数据
 
-const currentDate = proxy.$time.getDate().year + "-" + proxy.$time.getDate().month + "-" + proxy.$time.getDate().dates;
+const currentDate = proxy.$dayjs().format("YYYY-MM-DD");
 const currentDateList = ref([]);
 
 function navItemClick(url, id) {

+ 61 - 55
src/pages/common/face/index.vue

@@ -1,5 +1,7 @@
 <template>
-  <web-view ref="faceView" id="faceView" class="faceView" src="/static/face/index.html" bindmessage="receiveMessage" :webview-styles="webviewStyles" @message="onMessage"></web-view>
+  <web-view v-show="!modal.show" ref="faceView" id="faceView" class="faceView" src="/static/face/index.html" bindmessage="receiveMessage" :webview-styles="webviewStyles" @message="onMessage">
+  </web-view>
+
   <u-modal
     :show="modal.show"
     title="配置服务器"
@@ -97,28 +99,34 @@ const state = reactive({
     meetingId: undefined,
     meetingName: undefined,
   },
+  inter: {
+    interMeeting: null,
+  },
 });
-const { webviewStyles, meetingRoomList, modal, picker, form } = toRefs(state);
+const { webviewStyles, meetingRoomList, modal, picker, form, inter } = toRefs(state);
 
 // 初始化
 function init() {
+  uni.chooseImage({
+    sourceType: ["camera"],
+    success(res) {
+      console.log(res);
+    },
+  });
+
   var storage = uni.getStorageSync("storage_face");
   if (storage) {
     state.form.linkUrl = storage.linkUrl.indexOf(":") != -1 ? storage.linkUrl.split(":")[0] : storage.linkUrl;
     state.form.port = storage.port ? storage.port : "";
     state.form.meetingId = storage.meetingId || undefined;
     state.form.meetingName = storage.meetingName || undefined;
-    meetingInit();
   }
-}
 
-/**
- * @会议信息初始化
- * @method domain 服务器地址
- */
-function meetingInit() {
   getMeetingRoomList();
   getMeetingRoomReservationList();
+  inter.interMeeting = setInterval(() => {
+    getMeetingRoomReservationList();
+  }, 1000 * 5);
 }
 
 /**
@@ -151,6 +159,31 @@ function getMeetingRoomList() {
  * @会议室详情列表
  */
 function getMeetingRoomReservationList() {
+  for (let i = 0; i <= 23.5; i += 0.5) {
+    var time = "";
+    if (i % 1 === 0.5) {
+      if (i < 10) {
+        time = "0" + (i - 0.5) + ":30";
+      } else {
+        time = i - 0.5 + ":30";
+      }
+    } else {
+      if (i < 10) {
+        time = "0" + i + ":00";
+      } else {
+        time = i + ":00";
+      }
+    }
+
+    state.meetingTimeList.push({
+      startTime: time,
+      endTime: time,
+      isEnd: 0,
+      isHave: 0,
+      isReservation: 0,
+    });
+  }
+
   var domain = "";
   if (state.form.linkUrl) {
     domain = state.form.linkUrl;
@@ -159,10 +192,6 @@ function getMeetingRoomReservationList() {
     }
   }
 
-  if (!state.form.meetingId) {
-    return;
-  }
-
   meetingApi()
     .GetMeetingRoomReservationList({
       domain: domain,
@@ -170,31 +199,6 @@ function getMeetingRoomReservationList() {
       date: proxy.$dayjs().format("YYYY-MM-DD") + " 00:00:00",
     })
     .then((requset) => {
-      for (let i = 0; i <= 23.5; i += 0.5) {
-        var time = "";
-        if (i % 1 === 0.5) {
-          if (i < 10) {
-            time = "0" + (i - 0.5) + ":30";
-          } else {
-            time = i - 0.5 + ":30";
-          }
-        } else {
-          if (i < 10) {
-            time = "0" + i + ":00";
-          } else {
-            time = i + ":00";
-          }
-        }
-
-        state.meetingTimeList.push({
-          startTime: time,
-          endTime: time,
-          isEnd: 0,
-          isHave: 0,
-          isReservation: 0,
-        });
-      }
-
       if (requset.data.length > 0) {
         state.meetingReservaList.dataAll = requset.data[0];
         state.meetingReservaList.dataAll.dmMeetingList.forEach((e, index) => {
@@ -211,20 +215,16 @@ function getMeetingRoomReservationList() {
         });
 
         state.meetingReservaList.timeList = showTimeSegments(state.meetingTimeList);
-
-        setTimeout(() => {
-          handleChildren({
-            funcName: "初始化",
-            data: JSON.stringify(state.meetingReservaList),
-          });
-        }, 0);
+        handleChildren({
+          funcName: "初始化数据",
+          data: JSON.stringify(state.meetingReservaList),
+        });
       } else {
-        setTimeout(() => {
-          handleChildren({
-            funcName: "初始化",
-            data: JSON.stringify(state.meetingReservaList),
-          });
-        }, 0);
+        state.meetingReservaList.timeList = state.meetingTimeList;
+        handleChildren({
+          funcName: "初始化数据",
+          data: JSON.stringify(state.meetingReservaList),
+        });
       }
     });
 }
@@ -234,8 +234,9 @@ function showTimeSegments(times) {
   const timesXleList = JSON.parse(JSON.stringify(times));
 
   for (var i = 0; i < timesXleList.length; i++) {
+    const timeValue = new Date(`${proxy.$dayjs().format("YYYY-MM-DD")}T${timesXleList[i].startTime}`);
+
     state.meetingReservaList.dataAll.meetingRoomUsage.forEach((item) => {
-      const timeValue = new Date(`${proxy.$dayjs().format("YYYY-MM-DD")}T${timesXleList[i].startTime}`);
       const timeList = proxy.$time.timeRestructuring(item);
       const startValue = new Date(`${proxy.$dayjs().format("YYYY-MM-DD")}T${timeList.startTime}`);
       const endValue = new Date(`${proxy.$dayjs().format("YYYY-MM-DD")}T${timeList.endTime}`);
@@ -358,7 +359,6 @@ function handlePicker(value, index, ind) {
     state.picker.list = [state.meetingRoomList];
     state.picker.defaultIndex = 0;
   }
-
   state.picker.show = true;
 }
 
@@ -370,7 +370,6 @@ function pickerConfirm(e) {
     state.form.meetingId = e.value[0].value;
     state.form.meetingName = e.value[0].name;
   }
-
   state.picker.show = false;
 }
 
@@ -379,6 +378,9 @@ function pickerConfirm(e) {
  */
 function modalCancel() {
   state.modal.show = false;
+  //#ifdef APP-PLUS
+  proxy.$keyListen.quitApp();
+  //#endif
 }
 
 /**
@@ -400,6 +402,7 @@ function analysisData(event) {
  */
 function handleChildren(data) {
   // #ifdef APP-PLUS
+  var pages = getCurrentPages();
   var currentWebview = pages[pages.length - 1].$getAppWebview();
   var wv = currentWebview.children()[0];
   wv.evalJS(`receiveData(${JSON.stringify(data)})`);
@@ -427,6 +430,10 @@ onLoad((options) => {
   init();
 });
 
+onUnload(() => {
+  clearInterval(inter.interMeeting); //销毁之前定时器
+});
+
 watch(
   () => [state.form.linkUrl, state.form.port],
   (val) => {
@@ -439,7 +446,6 @@ watch(
     if (!/^[a-zA-Z0-9][a-zA-Z0-9-]{1,61}(?:\.[a-zA-Z0-9]{2,})+$/.test(state.form.linkUrl)) {
       return;
     }
-
     getMeetingRoomList();
   }
 );

+ 1 - 1
src/pages/index.vue

@@ -33,7 +33,7 @@
         <!-- 右侧弹窗 -->
         <u-transition :show="dialogFlag" :duration="200" mode="fade">
           <view class="transition" @click="rightButtonClick()">
-            <view class="transition-section" :style="{ top: '44px' + proxy.$settingStore.StatusBarHeight }">
+            <view class="transition-section" :style="{ top: `calc(44px + ${proxy.$settingStore.StatusBarHeight})` }">
               <view class="transition-section-content" @click="scanCode()">
                 <text class="transition-section-content-icon iconfont oaIcon-saoyisao"></text>
                 <view class="transition-section-content-text"> 扫一扫 </view>

+ 205 - 191
src/static/face/index.html

@@ -7,8 +7,9 @@
     <script type="text/javascript" src="./js/tracking-min.js"></script>
     <script type="text/javascript" src="./js/face-min.js"></script>
     <script type="text/javascript" src="./js/jquery-2.2.1.min.js"></script>
+    <!-- VUE3 的 SDK -->
+    <script type="text/javascript" src="./js/vue.global.prod.js"></script>
     <!-- uni 的 SDK -->
-    <!-- 需要把 uni.webview.1.5.4.js 下载到自己的服务器 -->
     <script type="text/javascript" src="./js/uni.webview.1.5.4.js"></script>
     <style>
         html,
@@ -173,210 +174,223 @@
 
 <body>
     <div id="face-container" class="face-container home-card-two">
-        <div id="home-card-left" class="home-card-left"></div>
-        <div id="home-card-right" class="home-card-right"></div>
-        <div id="home-card-bottom" class="home-card-bottom"></div>
-    </div>
-
-    <script type="text/javascript">
-        var state = {
-            dataAll: {},
-            thisVenueData: [],
-            thisVenueTime: {},
-            nextSceneData: [],
-            nextSceneTime: {},
-            timeList: []
-        }
-        var timeOutEvent = 0;
-
-
-        // 初始化
-        function initData() {
-            $(`#home-card-left`).append(`
-                <image id="home-card-left-image" class="home-card-left-image" src="./img/logo.png" width="125px" height="60px" mode="aspectFill"></image>
-                <div class="home-card-left-header">${state.dataAll?.roomName || "请配置会议室"}</div>
-                <div class="home-card-left-content" style="margin-bottom: 20px;">
-                    <div>本场会议</div>
-                    <div>${state.thisVenueData[0]?.meetingName || "空闲中"}</div>
-                    <div>${state.thisVenueTime.startTime || "00:00"} — ${state.thisVenueTime.endTime || "00:00"}</div>
+        <div id="home-card-left" class="home-card-left">
+            <image id="home-card-left-image" class="home-card-left-image" src="./img/logo.png" width="125px"
+                height="60px" mode="aspectFill"></image>
+            <div class="home-card-left-header">{{state.dataAll?.roomName || "请配置会议室"}}</div>
+            <div class="home-card-left-content" style="margin-bottom: 20px;">
+                <div>本场会议</div>
+                <div>{{state.thisVenueData[0]?.meetingName || "空闲中"}}</div>
+                <div>{{state.thisVenueTime.startTime || "00:00"}} — {{state.thisVenueTime.endTime || "00:00"}}
                 </div>
+            </div>
 
-                <div class="home-card-left-content">
-                    <div>下场会议</div>
-                    <div>${state.nextSceneData[0]?.meetingName || "空闲中"}</div>
-                    <div>${state.nextSceneTime.startTime || "00:00"} — ${state.nextSceneTime.endTime || "00:00"}</div>
+            <div class="home-card-left-content">
+                <div>下场会议</div>
+                <div>{{state.nextSceneData[0]?.meetingName || "空闲中"}}</div>
+                <div>{{state.nextSceneTime.startTime || "00:00"}} — {{state.nextSceneTime.endTime || "00:00"}}
                 </div>
-            `)
-
-            $(`#home-card-right`).append(`
-                <div class="home-card-right-header">
-                    <div class="home-card-right-header-center">
-                        <span style="padding: 0 5px 0 0; border-right: 1px #fff solid">温度:80℃</span>
-                        <span style="padding: 0px 5px; border-right: 1px #fff solid">湿度:80%</span>
-                        <span style="padding: 0px 5px; border-right: 1px #fff solid">PM2.5:10μg/m3</span>
-                        <span style="padding: 0 0 0 5px">甲醛:0ppm</span>
-                    </div>
-                    <div class="home-card-right-header-title">${state.thisVenueData[0] ? "&nbsp;&nbsp;会议进行中" : "&nbsp;"}</div>
+            </div>
+        </div>
+        <div id="home-card-right" class="home-card-right">
+            <div class="home-card-right-header">
+                <div class="home-card-right-header-center">
+                    <span style="padding: 0 5px 0 0; border-right: 1px #fff solid">温度:80℃</span>
+                    <span style="padding: 0px 5px; border-right: 1px #fff solid">湿度:80%</span>
+                    <span style="padding: 0px 5px; border-right: 1px #fff solid">PM2.5:10μg/m3</span>
+                    <span style="padding: 0 0 0 5px">甲醛:0ppm</span>
                 </div>
-                <div class="home-card-right-content">
-                    <div style="font-size: 20px; margin-bottom: 15px;">${state.thisVenueData[0]?.meetingName || "空闲中"}</div>
-                    <div style="font-size: 18px; margin-bottom: 15px;">
-                        ${state.thisVenueTime.startTime || "00:00"} — ${state.thisVenueTime.endTime || "00:00"}
-                    </div>
-                    <div style="font-size: 14px; margin-bottom: 15px;">${state.msg || "&nbsp;"}</div>
+                <div class="home-card-right-header-title">{{state.thisVenueData[0] ? "&nbsp;&nbsp;会议进行中" :
+                    "&nbsp;"}}</div>
+            </div>
+            <div class="home-card-right-content">
+                <div style="font-size: 20px; margin-bottom: 15px;">{{state.thisVenueData[0]?.meetingName || "空闲中"}}
                 </div>
-                <div class="home-card-right-footer" id="home-card-right-footer">
-                    <video id="video" width="320" height="240" preload autoplay loop muted></video>
-                    <canvas id="canvas" width="320" height="240"></canvas>
+                <div style="font-size: 18px; margin-bottom: 15px;">
+                    {{state.thisVenueTime.startTime || "00:00"}} — {{state.thisVenueTime.endTime || "00:00"}}
                 </div>
-            `)
-
-            var html = ``
-            state.timeList.forEach((item, timeIndex) => {
-                html += `
-                    <div id="timeScorll${timeIndex}" style="background-color: ${item.isEnd === 1 ? "#909399" : item.isHave === 1 ? "#fa3534" : item.isReservation === 1 ? "#ff9900" : "#409eff"}">
-                      ${item.isEnd != 0 || item.isHave != 0 || item.isReservation != 0 ? item.startTime + " —— " + item.endTime : item.startTime}  
-                    </div >
-                `
-            });
-            $(`#home-card-bottom`).append(html)
-
-            var video = document.getElementById("video");//视频dom
-            video.style.transform = 'scaleX(-1)';//视频翻转(1.水平翻转-scaleX(-1) 2.垂直翻转-scaleY(-1))
-            var canvas = document.getElementById('canvas');//画布dom
-            canvas.style.transform = 'scaleX(-1)';//画布翻转(1.水平翻转-scaleX(-1) 2.垂直翻转-scaleY(-1))
-            var context = canvas.getContext('2d');
-            var time = 5000;
-            var tracker = new tracking.ObjectTracker('face');
-            tracker.setInitialScale(4); //设置识别的放大比例
-            tracker.setStepSize(2);//设置步长
-            tracker.setEdgesDensity(0.1);//边缘密度
-            //启动摄像头,并且识别视频内容
-            var trackerTask = tracking.track('#video', tracker, {
-                camera: true
-            });
-
-            var flag = true;
-            tracker.on('track', function (event) {
-                if (event.data.length === 0) {
-                    // console.log('未检测到人脸')
-                    context.clearRect(0, 0, canvas.width, canvas.height);
-                } else if (event.data.length > 1) {
-                    // console.log('检测到多张人脸')
-                } else {
-                    context.clearRect(0, 0, canvas.width, canvas.height);
-                    event.data.forEach(function (rect) {
-                        context.strokeStyle = '#409eff';
-                        context.strokeRect(rect.x, rect.y, rect.width, rect.height);
-                        context.fillStyle = "#409eff";
-                        context.lineWidth = 1.5;
+                <div style="font-size: 14px; margin-bottom: 15px;">{{state.msg || "&nbsp;"}}</div>
+            </div>
+            <div class="home-card-right-footer" id="home-card-right-footer">
+                <video id="video" width="320" height="240" preload autoplay loop muted></video>
+                <canvas id="canvas" width="320" height="240"></canvas>
+            </div>
+
+        </div>
+        <div id="home-card-bottom" class="home-card-bottom"></div>
+    </div>
+    <script>
+        // 创建Vue实例
+        Vue.createApp({
+            components: {},
+            emits: [],
+            props: {},
+            data() {
+                return {
+                    state: {
+                        dataAll: {},
+                        thisVenueData: [],
+                        thisVenueTime: {},
+                        nextSceneData: [],
+                        nextSceneTime: {},
+                        timeList: []
+                    },
+                    timeOutEvent: 0
+                };
+            },
+            computed: {},
+            methods: {
+                // 初始化数据
+                initData() {
+                    var that = this
+
+                    var html = ``
+                    this.state.timeList.forEach((item, timeIndex) => {
+                        html += `
+                            <div id="timeScorll${timeIndex}" style="background-color: ${item.isEnd === 1 ? "#909399" : item.isHave === 1 ? "#fa3534" : item.isReservation === 1 ? "#ff9900" : "#409eff"}">
+                            ${item.isEnd != 0 || item.isHave != 0 || item.isReservation != 0 ? item.startTime + " —— " + item.endTime : item.startTime}  
+                            </div>
+                        `
                     });
-                    if (flag) {
-                        console.log("拍照");
-                        context.drawImage(video, 0, 0, video.width, video.height);
-                        saveAsLocalImage();
-                        context.clearRect(0, 0, canvas.width, canvas.height);
-                        flag = false;
-                        setTimeout(function () {
-                            flag = true;
-                        }, time);
-                    } else {
-                        //console.log("冷却中");
-                    }
-                }
-            });
+                    $(`#home-card-bottom`).append(html)
 
-            $("#home-card-left-image").on({
-                touchstart: function (e) {
-                    timeOutEvent = setTimeout("longPress()", 500);
-                    e.preventDefault();
-                },
-                touchmove: function () {
-                    clearTimeout(timeOutEvent);
-                    timeOutEvent = 0;
                 },
-                touchend: function () {
-                    clearTimeout(timeOutEvent);
-                    if (timeOutEvent != 0) {
-                        console.log("你这是点击,不是长按");
-                    }
-                    return false;
-                }
-            })
-        }
+                // 初始化摄像头
+                initVido() {
+                    var that = this;
+
+                    var video = document.getElementById("video");//视频dom
+                    video.style.transform = 'scaleX(-1)';//视频翻转(1.水平翻转-scaleX(-1) 2.垂直翻转-scaleY(-1))
+                    var canvas = document.getElementById('canvas');//画布dom
+                    canvas.style.transform = 'scaleX(-1)';//画布翻转(1.水平翻转-scaleX(-1) 2.垂直翻转-scaleY(-1))
+                    var context = canvas.getContext('2d');
+                    var time = 5000;
+                    var tracker = new tracking.ObjectTracker('face');
+                    tracker.setInitialScale(4); //设置识别的放大比例
+                    tracker.setStepSize(2);//设置步长
+                    tracker.setEdgesDensity(0.1);//边缘密度
+                    //启动摄像头,并且识别视频内容
+                    var trackerTask = tracking.track('#video', tracker, {
+                        camera: true
+                    });
 
-        // 长按事件
-        function longPress() {
-            timeOutEvent = 0
-            parentMessage('打开配置')
-        }
+                    var flag = true;
+                    tracker.on('track', function (event) {
+                        if (event.data.length === 0) {
+                            // console.log('未检测到人脸')
+                            context.clearRect(0, 0, canvas.width, canvas.height);
+                        } else if (event.data.length > 1) {
+                            // console.log('检测到多张人脸')
+                        } else {
+                            context.clearRect(0, 0, canvas.width, canvas.height);
+                            event.data.forEach(function (rect) {
+                                context.strokeStyle = '#409eff';
+                                context.strokeRect(rect.x, rect.y, rect.width, rect.height);
+                                context.fillStyle = "#409eff";
+                                context.lineWidth = 1.5;
+                            });
+                            if (flag) {
+                                console.log("拍照");
+                                context.drawImage(video, 0, 0, video.width, video.height);
+                                that.saveAsLocalImage();//调用获取图片bold
+                                context.clearRect(0, 0, canvas.width, canvas.height);
+                                flag = false;
+                                setTimeout(function () {
+                                    flag = true;
+                                }, time);
+                            } else {
+                                //console.log("冷却中");
+                            }
+                        }
+                    });
 
-        /**
-         * 解析数据
-         */
-        function analysisData(event) {
-            console.log(event.funcName)
-            if ("funcName" in event) {
-                if (event.funcName == "初始化") {
-                    $(`#home-card-left`).empty();//删除dom下的所有子元素
-                    $("#home-card-right").empty();//删除dom下的所有子元素
-                    $(`#home-card-bottom`).empty();//删除dom下的所有子元素
-
-                    state.dataAll = JSON.parse(event.data).dataAll
-                    state.thisVenueData = JSON.parse(event.data).thisVenueData
-                    state.thisVenueTime = JSON.parse(event.data).thisVenueTime
-                    state.nextSceneData = JSON.parse(event.data).nextSceneData
-                    state.nextSceneTime = JSON.parse(event.data).nextSceneTime
-                    state.timeList = JSON.parse(event.data).timeList
-
-                    initData();
-                } else if (event.funcName == "撒点") {
+                    $("#home-card-left-image").on({
+                        touchstart: function (e) {
+                            that.timeOutEvent = setTimeout(() => {
+                                that.longPress()
+                            }, 2000);
+                            e.preventDefault();
+                        },
+                        touchmove: function () {
+                            clearTimeout(that.timeOutEvent);
+                            that.timeOutEvent = 0;
+                        },
+                        touchend: function () {
+                            clearTimeout(that.timeOutEvent);
+                            if (that.timeOutEvent != 0) {
+                                console.log("你这是点击,不是长按");
+                            }
+                            return false;
+                        }
+                    })
+                },
+                // 向父页面推送数据
+                parentMessage(type, data) {
+                    var message = {
+                        funcName: type,
+                        data: data,
+                    };
+
+                    //APP-PLUS
+                    uni.postMessage({
+                        data: message
+                    });
 
+                    //H5
+                    if (window.parent) {
+                        window.parent.postMessage(message, '*');
+                    }
+                },
+                // 获取图片bold
+                saveAsLocalImage() {
+                    var myCanvas = document.getElementById("canvas");
+                    var image = myCanvas.toDataURL("image/png").replace("image/png", "image/octet-stream");
+                    this.parentMessage('人脸识别', { imageBase: image })
+                },
+                // 解析数据
+                analysisData(event) {
+                    console.log(event.funcName)
+                    if ("funcName" in event) {
+                        if (event.funcName == "初始化数据") {
+                            $(`#home-card-bottom`).empty();//删除dom下的所有子元素
+                            this.state.dataAll = JSON.parse(event.data).dataAll
+                            this.state.thisVenueData = JSON.parse(event.data).thisVenueData
+                            this.state.thisVenueTime = JSON.parse(event.data).thisVenueTime
+                            this.state.nextSceneData = JSON.parse(event.data).nextSceneData
+                            this.state.nextSceneTime = JSON.parse(event.data).nextSceneTime
+                            this.state.timeList = JSON.parse(event.data).timeList
+                            this.initData();
+                        } else if (event.funcName == "撒点") {
+
+                        }
+                    }
+                },
+                // 长按事件
+                longPress() {
+                    this.parentMessage('打开配置')
+                    this.timeOutEvent = 0
                 }
-            }
-        }
-
-        // 获取图片bold
-        function saveAsLocalImage() {
-            var myCanvas = document.getElementById("canvas");
-            var image = myCanvas.toDataURL("image/png").replace("image/png", "image/octet-stream");
-            parentMessage('人脸识别', { imageBase: image })
-        }
-
-        // 向父页面发送数据
-        function parentMessage(type, data) {
-            var message = {
-                funcName: type,
-                data: data,
-            };
-
-            //APP-PLUS
-            uni.postMessage({
-                data: message
-            });
-
-            //H5
-            if (window.parent) {
-                window.parent.postMessage(message, '*');
-            }
-        }
-
-        /**
-         * APP-PLUS || H5
-         * 接收父页面传过来的值
-         */
-        window.receiveData = function (msg) {
-            analysisData(msg)
-        }
-        window.addEventListener("message", function (event) {
-            analysisData(event.data)
-        });
-
-        window.onload = function () {
-            initData();
-        };
+            },
+            created() {
+                var that = this
+                // APP-PLUS || H5(接收父页面传过来的值)
+                window.receiveData = (msg) => {
+                    that.analysisData(msg)
+                }
+                window.addEventListener("message", function (event) {
+                    that.analysisData(event.data)
+                });
+            },
+            mounted() {
+                this.initVido();//调用初始化摄像头
+            },
+            beforeDestroy() {
+                // 移除window方法
+                window.receiveData = null;
+            },
+            watch: {},
+        }).mount('#face-container');
     </script>
-
 </body>
 
 </html>

File diff suppressed because it is too large
+ 5 - 0
src/static/face/js/vue.global.prod.js


+ 1 - 1
src/static/scss/colorui.css

@@ -35,7 +35,7 @@ image {
 }
 
 .radius {
-  border-radius: 6upx;
+  border-radius: 10upx;
 }
 
 /* ==================

+ 32 - 0
src/static/scss/index.scss

@@ -46,6 +46,38 @@
 
 /* 外边距、内边距全局样式
 ------------------------------- */
+@each $val in auto {
+    .m-#{$val} {
+        margin: $val;
+    }
+
+    .mt-#{$val} {
+        margin-top: $val;
+    }
+
+    .mr-#{$val} {
+        margin-right: $val;
+    }
+
+    .mb-#{$val} {
+        margin-bottom: $val;
+    }
+
+    .ml-#{$val} {
+        margin-left: $val;
+    }
+
+    .mlr-#{$val} {
+        margin-left: $val;
+        margin-right: $val;
+    }
+
+    .mtb-#{$val} {
+        margin-top: $val;
+        margin-bottom: $val;
+    }
+}
+
 @for $i from 0 through 100 {
 
     // margin

+ 19 - 63
unpackage/config/setting.js

@@ -13,8 +13,8 @@ filesToModify.forEach((file) => {
                 state.name = '综合智慧云'
                 state.appid = '__UNI__36DE3A0'
                 state.description = '综合智慧云APP,是一款助力于企业数字化的应用平台,帮助企业提升办公效率,实现组织数字化和业务数字化。'
-                state.versionName = "2.1.9"
-                state.versionCode = 19
+                state.versionName = "2.2.4"
+                state.versionCode = 24
                 state.h5.title = '综合智慧云'
             } else if (args === 'xunJian') {
                 state.name = '智能巡更'
@@ -32,74 +32,30 @@ filesToModify.forEach((file) => {
                 state.h5.title = '智能会议'
             }
         } else if ('./src/pages.json') {
-            state.pages = [
-                {
-                    "path": "pages/index",
-                    "style": {
-                        "navigationStyle": "custom",
-                        "navigationBarTitleText": "工作台",
-                        "app-plus": {
-                            "bounce": "none",
-                            "titleNView": false
+            state.pages.forEach((e, index) => {
+                if (args === 'zhiHuiYun') {
+                    if (e.style.navigationBarTitleText === "工作台") {
+                        if (index != 0) {
+                            state.pages.splice(0, 1, ...state.pages.splice(index, 1, state.pages[0]))
                         }
                     }
-                },
-                {
-                    "path": "pages/login",
-                    "style": {
-                        "navigationBarTitleText": "登录",
-                        "navigationStyle": "custom",
-                        "navigationBarTextStyle": "black"
-                    }
-                },
-                {
-                    "path": "pages/register",
-                    "style": {
-                        "navigationBarTitleText": "注册",
-                        "navigationStyle": "custom",
-                        "navigationBarTextStyle": "black"
-                    }
-                },
-                {
-                    "path": "pages/serveConfigSelect",
-                    "style": {
-                        "navigationBarTitleText": "服务器配置",
-                        "navigationStyle": "custom",
-                        "navigationBarTextStyle": "black"
-                    }
-                },
-                {
-                    "path": "pages/serveConfig",
-                    "style": {
-                        "navigationBarTitleText": "服务器配置",
-                        "navigationStyle": "custom",
-                        "navigationBarTextStyle": "black"
-                    }
-                },
-                {
-                    "path": "pages/info",
-                    "style": {
-                        "navigationBarTitleText": "消息",
-                        "navigationStyle": "custom",
-                        "enablePullDownRefresh": false,
-                        "app-plus": {
-                            "bounce": "none",
-                            "titleNView": false
+                    state.condition.list[0].path = "pages/login"
+                } else if (args === 'xunJian') {
+                    if (e.style.navigationBarTitleText === "工作台") {
+                        if (index != 0) {
+                            state.pages.splice(0, 1, ...state.pages.splice(index, 1, state.pages[0]))
                         }
                     }
-                },
-                {
-                    "path": "pages/mine",
-                    "style": {
-                        "navigationBarTitleText": "我的",
-                        "navigationStyle": "custom",
-                        "app-plus": {
-                            "bounce": "none",
-                            "titleNView": false
+                    state.condition.list[0].path = "pages/login"
+                } else if (args === 'huiYi') {
+                    if (e.style.navigationBarTitleText === "人脸识别") {
+                        if (index != 0) {
+                            state.pages.splice(0, 1, ...state.pages.splice(index, 1, state.pages[0]))
                         }
                     }
+                    state.condition.list[0].path = "pages/common/face/index"
                 }
-            ]
+            })
         }
 
         // 将修改后的对象转换回JSON字符串

Some files were not shown because too many files changed in this diff