fanghuisheng 2 years ago
parent
commit
d6e2285cd1
42 changed files with 2398 additions and 1182 deletions
  1. 68 68
      package.json
  2. 3 0
      src/App.vue
  3. 2 3
      src/colorui/main.css
  4. 1 3
      src/common/common.scss
  5. 106 22
      src/common/public.scss
  6. 103 95
      src/components/calendar/calendar.vue
  7. 4 4
      src/data/json.js
  8. 8 2
      src/main.js
  9. 7 5
      src/manifest.json
  10. 68 27
      src/pages.json
  11. 6 2
      src/pages/analyse/analyse.vue
  12. 1 1
      src/pages/export/export.vue
  13. 20 20
      src/pages/index/index.vue
  14. 1 1
      src/pages/info/fireBase/fireBase.vue
  15. 76 86
      src/pages/info/fireBashDetail/fireBashDetail.vue
  16. 60 62
      src/pages/info/info.vue
  17. 2 2
      src/pages/info/pushList/pushList.vue
  18. 93 136
      src/pages/login/login.vue
  19. 2 2
      src/pages/setting/building/building.vue
  20. 2 2
      src/pages/setting/funReport/funReport.vue
  21. 69 77
      src/pages/setting/setting.vue
  22. 146 0
      src/pages/xunJian/collect/components/collectDetail.vue
  23. 173 0
      src/pages/xunJian/collect/components/collectRecord.vue
  24. 283 0
      src/pages/xunJian/collect/index.vue
  25. 33 19
      src/pages/xunJian/components/echarts/chart.vue
  26. 187 95
      src/pages/xunJian/plan/components/content.vue
  27. 21 22
      src/pages/xunJian/plan/components/drawer.vue
  28. 192 95
      src/pages/xunJian/plan/components/report.vue
  29. 113 96
      src/pages/xunJian/plan/components/siteDetails.vue
  30. 244 149
      src/pages/xunJian/plan/index.vue
  31. 90 70
      src/pages/xunJian/record/record.vue
  32. 159 0
      src/pages/xunJian/record/recordDetail/index.vue
  33. 10 8
      src/pages/xunJian/xunJian.vue
  34. BIN
      src/static/alarming-kr.png
  35. BIN
      src/static/building1.png
  36. BIN
      src/static/building2.png
  37. BIN
      src/static/fail.png
  38. 6 8
      src/static/iconfont/iconfont.css
  39. 39 0
      src/static/iconfont/uciconfont/iconfont.css
  40. BIN
      src/static/iconfont/uciconfont/iconfont.ttf
  41. BIN
      src/static/iconfont/uciconfont/iconfont.woff
  42. BIN
      src/static/iconfont/uciconfont/iconfont.woff2

+ 68 - 68
package.json

@@ -1,70 +1,70 @@
 {
-  "name": "uni-preset-vue",
-  "version": "0.0.0",
-  "scripts": {
-    "dev:app": "uni -p app",
-    "dev:custom": "uni -p",
-    "dev:h5": "uni",
-    "dev:h5:ssr": "uni --ssr",
-    "dev:mp-alipay": "uni -p mp-alipay",
-    "dev:mp-baidu": "uni -p mp-baidu",
-    "dev:mp-kuaishou": "uni -p mp-kuaishou",
-    "dev:mp-lark": "uni -p mp-lark",
-    "dev:mp-qq": "uni -p mp-qq",
-    "dev:mp-toutiao": "uni -p mp-toutiao",
-    "dev:mp-weixin": "uni -p mp-weixin",
-    "dev:quickapp-webview": "uni -p quickapp-webview",
-    "dev:quickapp-webview-huawei": "uni -p quickapp-webview-huawei",
-    "dev:quickapp-webview-union": "uni -p quickapp-webview-union",
-    "build:app": "uni build -p app",
-    "build:custom": "uni build -p",
-    "build:h5": "uni build",
-    "build:h5:ssr": "uni build --ssr",
-    "build:mp-alipay": "uni build -p mp-alipay",
-    "build:mp-baidu": "uni build -p mp-baidu",
-    "build:mp-kuaishou": "uni build -p mp-kuaishou",
-    "build:mp-lark": "uni build -p mp-lark",
-    "build:mp-qq": "uni build -p mp-qq",
-    "build:mp-toutiao": "uni build -p mp-toutiao",
-    "build:mp-weixin": "uni build -p mp-weixin",
-    "build:quickapp-webview": "uni build -p quickapp-webview",
-    "build:quickapp-webview-huawei": "uni build -p quickapp-webview-huawei",
-    "build:quickapp-webview-union": "uni build -p quickapp-webview-union"
-  },
-  "dependencies": {
-    "@dcloudio/uni-app": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-app-plus": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-components": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-h5": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-mp-alipay": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-mp-baidu": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-mp-kuaishou": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-mp-lark": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-mp-qq": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-mp-toutiao": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-mp-weixin": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-quickapp-webview": "3.0.0-alpha-3050320220729001",
-    "@element-plus/icons-vue": "^2.0.9",
-    "echarts": "^5.3.3",
-    "element-plus": "^2.2.12",
-    "node-sass": "^7.0.1",
-    "pinia": "^2.0.17",
-    "pinia-plugin-persistedstate": "^2.1.1",
-    "vue": "^3.2.37",
-    "vue-echarts": "^6.2.3",
-    "vue-i18n": "^9.1.9",
-    "vue-json-excel": "^0.3.0",
-    "vuex": "^4.0.2",
-    "weixin-js-sdk": "^1.6.0"
-  },
-  "devDependencies": {
-    "@dcloudio/types": "^3.0.7",
-    "@dcloudio/uni-automator": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-cli-shared": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/uni-stacktracey": "3.0.0-alpha-3050320220729001",
-    "@dcloudio/vite-plugin-uni": "3.0.0-alpha-3050320220729001",
-    "@vitejs/plugin-vue": "^2.3.3",
-    "sass": "^1.54.3",
-    "vite": "^2.9.14"
-  }
+    "name": "uni-preset-vue",
+    "version": "0.0.0",
+    "scripts": {
+        "dev:app": "uni -p app",
+        "dev:custom": "uni -p",
+        "dev:h5": "uni",
+        "dev:h5:ssr": "uni --ssr",
+        "dev:mp-alipay": "uni -p mp-alipay",
+        "dev:mp-baidu": "uni -p mp-baidu",
+        "dev:mp-kuaishou": "uni -p mp-kuaishou",
+        "dev:mp-lark": "uni -p mp-lark",
+        "dev:mp-qq": "uni -p mp-qq",
+        "dev:mp-toutiao": "uni -p mp-toutiao",
+        "dev:mp-weixin": "uni -p mp-weixin",
+        "dev:quickapp-webview": "uni -p quickapp-webview",
+        "dev:quickapp-webview-huawei": "uni -p quickapp-webview-huawei",
+        "dev:quickapp-webview-union": "uni -p quickapp-webview-union",
+        "build:app": "uni build -p app",
+        "build:custom": "uni build -p",
+        "build:h5": "uni build",
+        "build:h5:ssr": "uni build --ssr",
+        "build:mp-alipay": "uni build -p mp-alipay",
+        "build:mp-baidu": "uni build -p mp-baidu",
+        "build:mp-kuaishou": "uni build -p mp-kuaishou",
+        "build:mp-lark": "uni build -p mp-lark",
+        "build:mp-qq": "uni build -p mp-qq",
+        "build:mp-toutiao": "uni build -p mp-toutiao",
+        "build:mp-weixin": "uni build -p mp-weixin",
+        "build:quickapp-webview": "uni build -p quickapp-webview",
+        "build:quickapp-webview-huawei": "uni build -p quickapp-webview-huawei",
+        "build:quickapp-webview-union": "uni build -p quickapp-webview-union"
+    },
+    "dependencies": {
+        "@dcloudio/uni-app": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-app-plus": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-components": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-h5": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-mp-alipay": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-mp-baidu": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-mp-kuaishou": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-mp-lark": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-mp-qq": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-mp-toutiao": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-mp-weixin": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-quickapp-webview": "3.0.0-alpha-3050320220729001",
+        "@element-plus/icons-vue": "^2.0.9",
+        "echarts": "^5.3.3",
+        "element-plus": "^2.2.12",
+        "node-sass": "^7.0.1",
+        "pinia": "^2.0.17",
+        "pinia-plugin-persistedstate": "^2.1.1",
+        "vue": "^3.2.37",
+        "vue-echarts": "^6.2.3",
+        "vue-i18n": "^9.1.9",
+        "vue-json-excel": "^0.3.0",
+        "vuex": "^4.0.2",
+        "weixin-js-sdk": "^1.6.0"
+    },
+    "devDependencies": {
+        "@dcloudio/types": "^3.0.7",
+        "@dcloudio/uni-automator": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-cli-shared": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/uni-stacktracey": "3.0.0-alpha-3050320220729001",
+        "@dcloudio/vite-plugin-uni": "3.0.0-alpha-3050320220729001",
+        "@vitejs/plugin-vue": "^2.3.3",
+        "sass": "^1.54.3",
+        "vite": "^2.9.15"
+    }
 }

+ 3 - 0
src/App.vue

@@ -19,6 +19,7 @@ onHide(() => {
 @import "colorui/main.css";
 @import "colorui/icon.css";
 @import "static/iconfont/iconfont.css";
+@import "static/iconfont/uciconfont/iconfont.css";
 
 /* 解决头条小程序组件内引入字体不生效的问题 */
 /* #ifdef MP-TOUTIAO */
@@ -33,6 +34,7 @@ onHide(() => {
 <style lang="scss">
 @import "common/common.scss";
 @import "common/public.scss";
+@import "./uni_modules/uview-plus/index.scss";
 
 uni-page-body,
 uni-page-refresh {
@@ -40,3 +42,4 @@ uni-page-refresh {
 }
 </style>
 
+

+ 2 - 3
src/colorui/main.css

@@ -11,7 +11,7 @@
         初始化
  ==================== */
 body {
-	background-color: #fff;
+	background: rgb(241, 241, 241);
 	font-size: 28upx;
 	color: #333333;
 	font-family: Helvetica Neue, Helvetica, sans-serif;
@@ -3913,5 +3913,4 @@ scroll-view.cu-steps .cu-item {
 .line-white,
 .lines-white {
 	color: #ffffff;
-}
-
+}

+ 1 - 3
src/common/common.scss

@@ -647,9 +647,7 @@ select {
 }
 
 input {
-	border: 1px solid #EDEDED !important;
-
-
+	border: 0px solid #EDEDED !important;
 }
 
 input,

+ 106 - 22
src/common/public.scss

@@ -43,6 +43,14 @@ th {
     padding: 0px 15px
 }
 
+#planTimeline1 {
+    padding: 0px 15px;
+
+    .u-steps-item__wrapper {
+        background-color: #f1f1f1
+    }
+}
+
 /*
  * @时间线样式 结束
  */
@@ -110,26 +118,75 @@ th {
  * @消息弹出框样式 结束
  */
 
+/*
+ * @uni-textarea 文本域样式 开始
+ */
+
+uni-textarea {
+    border: 0px solid #EDEDED;
+    padding: 0;
+}
+
+/*
+ * @uni-textarea 文本域样式 结束
+ */
+
+/*
+ * @全局input样式 开始
+ */
+uni-input {
+    background-color: transparent;
+}
+
+/*
+ * @全局input样式 结束
+ */
 
 /*
  * @login input样式 开始
  */
 #login-input {
-    .el-input {
+    .u-input {
+        height: 48px;
+        border-radius: 24px;
+        padding: 5px 12px !important;
+        background-color: rgba(255, 255, 255, 0.1) !important;
+    }
+
+    .uni-input-wrapper {
+        font-size: 18px;
+    }
 
-        .el-input__wrapper {
-            border-radius: 24px;
-            padding: 5px 15px !important;
-            background-color: rgba(255, 255, 255, 0.1) !important;
+    uni-input {
+        color: #fff !important;
+        background-color: rgba(255, 255, 255, 0) !important;
+        border: 0px solid #EDEDED !important;
+        padding-left: 0 !important;
+    }
 
-            .el-input__inner {
-                color: #fff;
-                caret-color: #fff; // 设置光标颜色
-                background-color: rgba(255, 255, 255, 0) !important;
-            }
-        }
+    .u-icon__icon {
+        font-size: 24px !important;
+        line-height: 24px !important;
+        color: #a8abb2 !important;
     }
 
+    .iconfont {
+        color: #a8abb2 !important;
+    }
+
+    .u-button {
+        width: 35%;
+        height: 48px;
+        line-height: 48px;
+        color: #fff;
+        border-radius: 24px;
+        margin: 0 0 0 5%;
+        font-size: 17px !important;
+        white-space: nowrap;
+        background-color: rgba(255, 255, 255, 0.1) !important;
+    }
+
+
     :-webkit-autofill {
         caret-color: #fff; // 设置光标颜色
         -webkit-text-fill-color: #ededed !important;
@@ -138,23 +195,50 @@ th {
         background-image: none;
         transition: background-color 50000s ease-in-out 0s; //背景色透明  生效时长  过渡效果  启用时延迟的时间
     }
+}
+
+/*
+ * @login input样式 结束
+ */
 
 
-    .el-input--large {
-        font-size: 18px;
+
+
+
+/*
+ * 页面样式 开始
+ * @/pages/xunJian/plan/components/siteDetails.vue
+ * @/pages/xunJian/plan/components/content.vue
+ */
+
+.siteHeader {
+    .u-icon__icon {
+        font-size: 14px !important;
+        line-height: 14px !important;
+        margin: auto !important;
     }
 
-    .el-button {
-        width: 35%;
-        height: 48px;
-        color: #fff;
-        font-size: 18px;
-        border-radius: 24px;
-        margin: -10px 0 0 5%;
-        background-color: rgba(255, 255, 255, 0.1) !important;
+    .uni-section .uni-section-header {
+        padding: 0 !important;
+
+
+        .uni-section-header__decoration {
+            height: 14px !important;
+            background-color: #149eff;
+        }
+
+        .uni-section-header__content {
+            uni-text {
+                font-size: 15px !important;
+                color: #149eff !important;
+                font-weight: 600 !important;
+            }
+        }
     }
 }
 
 /*
- * @login input样式 结束
+ * 页面样式 结束
+ * @/pages/xunJian/plan/components/siteDetails.vue
+ * @/pages/xunJian/plan/components/content.vue
  */

+ 103 - 95
src/components/calendar/calendar.vue

@@ -1,108 +1,116 @@
 <template>
-	<view class="leave_cont">
-		<view class="ul">
-			<view class="li">
-				<view class="flex1">
-					<picker mode="date" :value="start_date" :start="start_date" :end="other" @change="bindDateChange">
-						<view class="date">{{start_date}}</view>
-					</picker>
-				</view>
-			</view>
-			~
-			<view class="li">
-				<view class="flex1">
-					<picker mode="date" :value="start_date" :start="start_date" @change="bindDateChange2">
-						<view class="date">{{end_date}}</view>
-					</picker>
-				</view>
-			</view>
-			<image class="canlendar-icon" src="../../static/calendar.png" ></image>
-		</view>
-	</view>
+  <view class="leave_cont">
+    <view class="ul">
+      <view class="li">
+        <view class="flex1">
+          <picker
+            mode="date"
+            :value="start_date"
+            :start="start_date"
+            :end="other"
+            @change="bindDateChange"
+          >
+            <view class="date">{{ start_date }}</view>
+          </picker>
+        </view>
+      </view>
+      ~
+      <view class="li">
+        <view class="flex1">
+          <picker
+            mode="date"
+            :value="start_date"
+            :start="start_date"
+            @change="bindDateChange2"
+          >
+            <view class="date">{{ end_date }}</view>
+          </picker>
+        </view>
+      </view>
+      <image class="canlendar-icon" src="@/static/images/calendar.png"></image>
+    </view>
+  </view>
 </template>
 
 <script>
-	export default {
-		data() {
-			const currentDate = this.getDate({
-				format: true
-			})
-			return {
-				start_date: '请选择开始日期',
-				end_date: '请选择结束日期',
-				other: '请输入'
-			}
-		},
-		computed: {
+export default {
+  data() {
+    const currentDate = this.getDate({
+      format: true,
+    });
+    return {
+      start_date: "请选择开始日期",
+      end_date: "请选择结束日期",
+      other: "请输入",
+    };
+  },
+  computed: {},
+  methods: {
+    // 选择日期
+    bindDateChange: function (e) {
+      this.start_date = e.target.value;
+    },
+    bindDateChange2: function (e) {
+      this.end_date = e.target.value;
+      this.other = this.end_date;
+    },
+    // 获取当前时间
+    getDate(type) {
+      const date = new Date();
+      let year = date.getFullYear();
+      let month = date.getMonth() + 1;
+      let day = date.getDate();
 
-		},
-		methods: {
-			// 选择日期
-			bindDateChange: function(e) {
-				this.start_date = e.target.value
-
-			},
-			bindDateChange2: function(e) {
-				this.end_date = e.target.value;
-				this.other = this.end_date;
-			},
-			// 获取当前时间
-			getDate(type) {
-				const date = new Date();
-				let year = date.getFullYear();
-				let month = date.getMonth() + 1;
-				let day = date.getDate();
-
-				if (type === 'start') {
-					year = year - 60;
-				} else if (type === 'end') {
-					year = year + 2;
-				}
-				month = month > 9 ? month : '0' + month;;
-				day = day > 9 ? day : '0' + day;
-				return `${year}-${month}-${day}`;
-			},
-		}
-	}
+      if (type === "start") {
+        year = year - 60;
+      } else if (type === "end") {
+        year = year + 2;
+      }
+      month = month > 9 ? month : "0" + month;
+      day = day > 9 ? day : "0" + day;
+      return `${year}-${month}-${day}`;
+    },
+  },
+};
 </script>
 
 <style>
-	.leave_cont .ul {
-		border: 1px solid red;
-		margin: 24rpx 24rpx;
-		border: 1px solid #E8F1FF;
-		border-radius: 36rpx;
-		line-height: 70rpx;
-		position:relative;
-	}
+.leave_cont .ul {
+  border: 1px solid red;
+  margin: 24rpx 24rpx;
+  border: 1px solid #e8f1ff;
+  border-radius: 36rpx;
+  line-height: 70rpx;
+  position: relative;
+}
 
-	.leave_cont .ul .li {
-		display: inline-block;
-		text-align: center;
-		width: 35%
-	}
+.leave_cont .ul .li {
+  display: inline-block;
+  text-align: center;
+  width: 35%;
+}
 
-	.leave_cont .ul .li text {
-		padding: 40rpx 0;
-		font-size: 30rpx;
-		color: #666666;
-		text-align:center;
-	}
+.leave_cont .ul .li text {
+  padding: 40rpx 0;
+  font-size: 30rpx;
+  color: #666666;
+  text-align: center;
+}
 
-	.leave_cont .ul .li .flex1 {
-		flex: 1;
-		color: #999999;
-		font-size: 32rpx;
-	}
+.leave_cont .ul .li .flex1 {
+  flex: 1;
+  color: #999999;
+  font-size: 32rpx;
+}
 
-	.date {
-		height: 42rpx;
-	}
-	.canlendar-icon{
-		width:36rpx;
-		height:36rpx;
-		position:absolute;
-		right:30rpx;
-		top:16rpx;
-	}
+.date {
+  height: 42rpx;
+}
+.canlendar-icon {
+  width: 36rpx;
+  height: 36rpx;
+  position: absolute;
+  right: 30rpx;
+  top: 16rpx;
+}
 </style>

+ 4 - 4
src/data/json.js

@@ -1,12 +1,12 @@
 // 本地模拟json数据
 // 首页九宫格
 let cuIconList = [{
-	imgUrl: '../../static/square-xj.png',
+	imgUrl: '/static/images/square/square-xj.png',
 	badge: 0,
 	name: '巡检',
 	redirectUrl: '/pages/xunJian/xunJian'
 }, {
-	imgUrl: '../../static/square-xf.png',
+	imgUrl: '/static/images/square/square-xf.png',
 	badge: 0,
 	name: '未开发',
 	redirectUrl: ''
@@ -39,7 +39,7 @@ let staticData = {
 let xunJianList = [{
 	id: 1,
 	title: "巡检任务",
-	num: "100",
+	num: "0",
 	imgUrl: "/static/inspection/xunJian-icon1.png",
 	redirectUrl: '/pages/xunJian/plan/index'
 }, {
@@ -53,7 +53,7 @@ let xunJianList = [{
 	title: "巡检采集",
 	num: "0",
 	imgUrl: "/static/inspection/xunJian-icon3.png",
-	redirectUrl: ''
+	redirectUrl: '/pages/xunJian/collect/index'
 }];
 
 let xunJianRecord = [{

+ 8 - 2
src/main.js

@@ -1,4 +1,6 @@
-import { createSSRApp } from "vue";
+import {
+	createSSRApp
+} from "vue";
 
 import App from "./App.vue";
 import store from './store'
@@ -21,12 +23,16 @@ import JsonExcel from 'vue-json-excel'
 // 引入微信js-sdk
 // import jweixin from 'weixin-js-sdk'
 
+import uviewPlus from './uni_modules/uview-plus';
+
 // 引入ElementPlus
 import ElementPlus from 'element-plus'
 import locale from 'element-plus/lib/locale/lang/zh-cn' // 中文语言
 import 'element-plus/theme-chalk/index.css'
 import * as Elicons from "@element-plus/icons-vue";
 
+
+
 export function createApp() {
 	const app = createSSRApp(App);
 
@@ -57,7 +63,7 @@ export function createApp() {
 	// 使用element-plus
 	app.use(ElementPlus, {
 		locale: locale,
-	}).use(store).use(initApp)
+	}).use(store).use(initApp).use(uviewPlus)
 
 	return {
 		app,

+ 7 - 5
src/manifest.json

@@ -1,7 +1,7 @@
 {
-    "name" : "智慧电力app",
-    "appid" : "__UNI__945DA73",
-    "description" : "伍继app升级",
+    "name" : "智慧消防",
+    "appid" : "__UNI__36DE3A0",
+    "description" : "智慧消防",
     "versionName" : "2.0",
     "versionCode" : 2,
     "transformPx" : false,
@@ -51,7 +51,9 @@
                 ]
             },
             /* ios打包配置 */
-            "ios" : {},
+            "ios" : {
+                "dSYMs" : false
+            },
             /* SDK配置 */
             "sdkConfigs" : {
                 "ad" : {},
@@ -97,7 +99,7 @@
             "splashscreen" : {
                 "androidStyle" : "default",
                 "android" : {
-                    "hdpi" : "static/startUp.png"
+                    "hdpi" : "src/static/wt/bg.png"
                 }
             }
         }

+ 68 - 27
src/pages.json

@@ -10,25 +10,24 @@
         {
             "path": "pages/index/index",
             "style": {
-                "navigationBarTitleText": "虹泾总部园",
+                "navigationBarTitleText": "",
                 "app-plus": {
                     "titleNView": {
-                        "buttons": [
-                            {
+                        "buttons": [{
                                 "text": "\ue607",
                                 "fontSize": "18px",
                                 // "redDot": true,
                                 "float": "right",
                                 "fontSrc": "/static/iconfont/iconfont.ttf",
                                 "width": "auto"
-                            },
-                            {
-                                "text": "\ue63d",
-                                "fontSize": "18px",
-                                "float": "left",
-                                "fontSrc": "/static/iconfont/iconfont.ttf",
-                                "width": "auto"
                             }
+                            // {
+                            //     "text": "\ue63d",
+                            //     "fontSize": "18px",
+                            //     "float": "left",
+                            //     "fontSrc": "/static/iconfont/iconfont.ttf",
+                            //     "width": "auto"
+                            // }
                         ]
                     }
                 }
@@ -121,12 +120,57 @@
             }
         },
         {
-            "path": "pages/xunJian/recordDetail/recordDetail",
+            "path": "pages/xunJian/record/recordDetail/index",
             "style": {
                 "navigationBarTitleText": "巡检记录详情",
                 "enablePullDownRefresh": false
             }
         },
+        {
+            "path": "pages/xunJian/collect/index",
+            "style": {
+                "navigationBarTitleText": "点位采集",
+                "enablePullDownRefresh": false,
+                "app-plus": {
+                    "titleNView": {
+                        "buttons": [{
+                            "text": "采集记录",
+                            "fontSize": "12px",
+                            // "redDot": true,
+                            "float": "right",
+                            "fontSrc": "/static/iconfont/iconfont.ttf",
+                            "width": "auto"
+                        }]
+                    }
+                }
+            }
+        },
+        {
+            "path": "pages/xunJian/collect/components/collectDetail",
+            "style": {
+                "navigationBarTitleText": "采集上报",
+                "enablePullDownRefresh": false
+            }
+        },
+        {
+            "path": "pages/xunJian/collect/components/collectRecord",
+            "style": {
+                "navigationBarTitleText": "采集记录",
+                "enablePullDownRefresh": false,
+                "app-plus": {
+                    "titleNView": {
+                        "buttons": [{
+                            "text": "\ue7c7",
+                            "fontSize": "18px",
+                            // "redDot": true,
+                            "float": "right",
+                            "fontSrc": "/static/iconfont/uciconfont/iconfont.ttf",
+                            "width": "auto"
+                        }]
+                    }
+                }
+            }
+        },
         /**
          * @巡检模块 结束
          */
@@ -223,21 +267,20 @@
         "navigationBarTitleText": "uni-app",
         "navigationBarBackgroundColor": "#149EFF",
         "backgroundColor": "#F8F8F8"
-        // "enablePullDownRefresh":true
+            // "enablePullDownRefresh":true
     },
     "tabBar": {
         "borderStyle": "white",
-        "list": [
-            {
+        "list": [{
                 "pagePath": "pages/index/index",
-                "iconPath": "static/home.png",
-                "selectedIconPath": "static/home-selected.png",
+                "iconPath": "static/images/home.png",
+                "selectedIconPath": "static/images/home-selected.png",
                 "text": "主页"
             },
             {
                 "pagePath": "pages/info/info",
-                "iconPath": "static/info.png",
-                "selectedIconPath": "static/info-selected.png",
+                "iconPath": "static/images/info.png",
+                "selectedIconPath": "static/images/info-selected.png",
                 "text": "消息"
             },
             {
@@ -248,20 +291,18 @@
             },
             {
                 "pagePath": "pages/setting/setting",
-                "iconPath": "static/setting.png",
-                "selectedIconPath": "static/setting-selected.png",
+                "iconPath": "static/images/setting.png",
+                "selectedIconPath": "static/images/setting-selected.png",
                 "text": "设置"
             }
         ]
     },
     "condition": { //模式配置,仅开发期间生效
         "current": 0, //当前激活的模式(list 的索引项)
-        "list": [
-            {
-                "name": "", //模式名称
-                "path": "pages/index/index", //启动页面,必选
-                "query": "" //启动参数,在页面的onLoad函数里面得到
-            }
-        ]
+        "list": [{
+            "name": "", //模式名称
+            "path": "pages/index/index", //启动页面,必选
+            "query": "" //启动参数,在页面的onLoad函数里面得到
+        }]
     }
 }

+ 6 - 2
src/pages/analyse/analyse.vue

@@ -6,7 +6,7 @@
     <view class="cu-list menu-avatar padding-lr">
       <view class="cu-item shadow" @tap="goMonthReport()">
         <view class="cu-avatar">
-          <image class="image-bg" src="/static/yb-icon.png" />
+          <image class="image-bg" src="@/static/images/yb-icon.png" />
         </view>
         <view class="content">
           <view class="">月报</view>
@@ -21,7 +21,7 @@
       </view>
       <view class="cu-item shadow" @tap="goBuildingCheck()">
         <view class="cu-avatar">
-          <image class="image-bg" src="/static/build-icon.png" />
+          <image class="image-bg" src="@/static/images/build-icon.png" />
         </view>
         <view class="content">
           <view class="">建筑体检</view>
@@ -57,7 +57,11 @@ export default {
   },
 };
 </script>
+
 <style>
+body {
+  background: #fff;
+}
 .shadow {
   box-shadow: 1px 1px 4px rgb(26 26 26 / 10%);
 }

+ 1 - 1
src/pages/export/export.vue

@@ -15,7 +15,7 @@
 					<view class="cu-item" v-for="(item,index) in getExportData" :key="index">
 						<view class="cu-avatar lg">
 							<image class="image-bg"
-								:src="item.clzt==0?'/static/process-icon.png':'/static/processed-icon.png'" />
+								:src="item.clzt==0?'@/static/images/process-icon.png':'@/static/images/processed-icon.png'" />
 						</view>
 						<view class="content">
 							<view class="pro-title">

+ 20 - 20
src/pages/index/index.vue

@@ -2,7 +2,7 @@
   <scroll-view scroll-x>
     <view style="margin-bottom: 50px" class="padding-sm">
       <!-- 下拉选择 -->
-      <view class="searchSelect shadow" v-if="flag">
+      <!-- <view class="searchSelect shadow" v-if="flag">
         <view class="cu-bar search bg-white">
           <view class="search-form round" style="margin-top: 0">
             <input
@@ -34,11 +34,11 @@
             >{{ item.owner_name }}</view
           >
         </view>
-      </view>
+      </view> -->
       <!-- 下拉选择 end -->
 
       <!-- 图表 -->
-      <view class="section1 section bg-white padding-xs">
+      <!-- <view class="section1 section bg-white padding-xs">
         <view
           class="
             static-tabs
@@ -106,7 +106,7 @@
             </ul>
           </view>
         </view>
-      </view>
+      </view> -->
       <!-- 图表 end-->
 
       <!-- 宫格列表 -->
@@ -180,19 +180,23 @@ export default {
   },
 
   onLoad(option) {
-    var res = uni.getStorageSync("selectedCode");
-    var res2 = uni.getStorageSync("selectedName");
-    if (res) {
-      uni.setNavigationBarTitle({
-        title: res2,
-      });
-    }
-
-    // 图表切换渲染
-    this.hackReset = false;
-    this.$nextTick(() => {
-      this.hackReset = true;
+    //获取首页标题
+    uni.setNavigationBarTitle({
+      title: uni.getStorageSync("homeTitle")
     });
+    // var res = uni.getStorageSync("selectedCode");
+    // var res2 = uni.getStorageSync("selectedName");
+    // if (res) {
+    //   uni.setNavigationBarTitle({
+    //     title: res2,
+    //   });
+    // }
+
+    // // 图表切换渲染
+    // this.hackReset = false;
+    // this.$nextTick(() => {
+    //   this.hackReset = true;
+    // });
   },
   methods: {
     //登录请求
@@ -424,10 +428,6 @@ export default {
 </script>
 
 <style>
-body {
-  background: #f1f1f1 !important;
-}
-
 .select-items {
   overflow: auto;
   height: 80vh;

+ 1 - 1
src/pages/info/fireBase/fireBase.vue

@@ -7,7 +7,7 @@
 					<view class="cu-item" v-for="(item,index) in this.getData" :key="index"  @tap="goDetail(item)">
 						
 						<view class="cu-avatar">
-							<image class="image-bg" src="/static/fire-base1.png" />
+							<image class="image-bg" src="@/static/images/fire-base1.png" />
 						</view>
 						
 						<view class="content">

+ 76 - 86
src/pages/info/fireBashDetail/fireBashDetail.vue

@@ -1,37 +1,38 @@
 <template>
-	<view class="padding fireBashDetailWrapper">
-		<view class="margin-bottom fireD-tit">{{this.getData.title}}</view>
-		<view class="flex justify-between align-center">
-			<view>
-				<!-- <view class="cu-avatar round" style="background-image:url(../../static/fireBase.png)"></view> -->
-				
-				<image class=" cu-avatar round" src="/static/fireBase.png" />
-				
-				<text class="margin-left-sm margin-right-sm text-sm">{{this.getData.author}}</text>
-				<text>{{this.getData.release_time}}</text>
-			</view>
-			<view style="color:#999">阅读:{{this.getData.frequency}}</view>
-		</view>
-
-		<view class="fireD-content margin-top padding-top-xs">
-			<view class="">
-				<view v-html="this.getData.content"></view>
-			</view>
-		</view>
-
-		<view class="preAndNext" style="display:none">
-			<view class="flex align-top">
-				<view style="width:120rpx">上一篇:</view>
-				<view style="width:calc(100% - 120rpx)">火灾逃生十大要诀</view>
-			</view>
-			<view class="flex align-top">
-				<view style="width:120rpx">下一篇:</view>
-				<view style="width:calc(100% - 120rpx)">火灾逃生十大要诀</view>
-			</view>
-		</view>
-
-
-		<!-- <view class="share grid col-3">
+  <view class="padding fireBashDetailWrapper">
+    <view class="margin-bottom fireD-tit">{{ this.getData.title }}</view>
+    <view class="flex justify-between align-center">
+      <view>
+        <!-- <view class="cu-avatar round" style="background-image:url(@/static/images/fireBase.png)"></view> -->
+
+        <image class="cu-avatar round" src="@/static/images/fireBase.png" />
+
+        <text class="margin-left-sm margin-right-sm text-sm">{{
+          this.getData.author
+        }}</text>
+        <text>{{ this.getData.release_time }}</text>
+      </view>
+      <view style="color: #999">阅读:{{ this.getData.frequency }}</view>
+    </view>
+
+    <view class="fireD-content margin-top padding-top-xs">
+      <view class="">
+        <view v-html="this.getData.content"></view>
+      </view>
+    </view>
+
+    <view class="preAndNext" style="display: none">
+      <view class="flex align-top">
+        <view style="width: 120rpx">上一篇:</view>
+        <view style="width: calc(100% - 120rpx)">火灾逃生十大要诀</view>
+      </view>
+      <view class="flex align-top">
+        <view style="width: 120rpx">下一篇:</view>
+        <view style="width: calc(100% - 120rpx)">火灾逃生十大要诀</view>
+      </view>
+    </view>
+
+    <!-- <view class="share grid col-3">
 			<view class="share-item align">
 				<text class="icon iconfont margin-right-xs margin-left-lg">&#xe60c;</text>
 				分享
@@ -39,63 +40,52 @@
 			<view class="share-item" @click="clickPraise()" :class="[praise?'active':'']"><text class="icon iconfont margin-right-xs margin-left-lg"  >&#xe62a;</text>收藏</view>
 			<view class="share-item"  @click="clickZan()" :class="[zan?'active':'']"><text class="icon iconfont margin-right-xs margin-left-lg">&#xe600;</text>点赞</view>
 		</view> -->
-
-
-
-
-	</view>
-
+  </view>
 </template>
 
 <script>
-	export default {
-		data() {
-			return {
-				praise: false,
-				zan: false,
-				getData: {}
-			}
-		},
-
-		onLoad: function(option) {
-			this.getFireBaseDetail({
-				'company_code': uni.getStorageSync('selectedCode'),
-				"id": option.id
-			})
-			console.log('option')
-			console.log(option)
-			uni.setNavigationBarTitle({
-				title:option.title
-			});
-		},
-
-		methods: {
-
-			// 详情页数据请求
-			async getFireBaseDetail(params = {}) {
-				const res = await this.$myRequest({
-					url: 'KnowledgeBase/getKnowledgeBaseDetails',
-					data: params,
-					showLoading: true
-				})
-				this.getData = res.data.data[0];
-				console.log(this.getData)
-			},
-
-
-			clickPraise() {
-
-				this.praise = !this.praise;
-			},
-			clickZan() {
-
-				this.zan = !this.zan;
-			},
-
-		}
-	}
+export default {
+  data() {
+    return {
+      praise: false,
+      zan: false,
+      getData: {},
+    };
+  },
+
+  onLoad: function (option) {
+    this.getFireBaseDetail({
+      company_code: uni.getStorageSync("selectedCode"),
+      id: option.id,
+    });
+    console.log("option");
+    console.log(option);
+    uni.setNavigationBarTitle({
+      title: option.title,
+    });
+  },
+
+  methods: {
+    // 详情页数据请求
+    async getFireBaseDetail(params = {}) {
+      const res = await this.$myRequest({
+        url: "KnowledgeBase/getKnowledgeBaseDetails",
+        data: params,
+        showLoading: true,
+      });
+      this.getData = res.data.data[0];
+      console.log(this.getData);
+    },
+
+    clickPraise() {
+      this.praise = !this.praise;
+    },
+    clickZan() {
+      this.zan = !this.zan;
+    },
+  },
+};
 </script>
 
 <style>
-
 </style>

+ 60 - 62
src/pages/info/info.vue

@@ -1,25 +1,28 @@
 <template>
-	<view class="analyse-wrapper info-wrapper" >
-		<view class="top-banner justify-center align-center text-center">
-			<image class="image-bg" src="/static/images/info-bg.png"/>
-		</view>
-		<view class="cu-list menu-avatar padding-lr">
-			<view class="cu-item shadow" @tap="goFireBase()">
-				
-				<view class="cu-avatar " >
-					<image class="image-bg" src="/static/fireBase.png"/>
-				</view>
-				<view class="content">
-					<view class="">消防知识库</view>
-				</view>
-				<view class="nav-right">
-					<view class="text-grey">
-						<text class="icon iconfont margin-right-xs margin-left-lg">&#xe629;</text>
-					</view>
-				</view>
-			</view>
-			<!-- <view class="cu-item  shadow" @tap="goPushList()">
-				<view class="cu-avatar " style="background-image:url(../../static/pushList.png)"></view>
+  <view class="analyse-wrapper info-wrapper">
+    <view class="top-banner justify-center align-center text-center">
+      <image class="image-bg" src="/static/images/info-bg.png" />
+    </view>
+
+    <scroll-view scroll-y>
+      <view class="cu-list menu-avatar padding-lr">
+        <view class="cu-item shadow" @tap="goFireBase()">
+          <view class="cu-avatar">
+            <image class="image-bg" src="@/static/images/fireBase.png" />
+          </view>
+          <view class="content">
+            <view class="">消防知识库</view>
+          </view>
+          <view class="nav-right">
+            <view class="text-grey">
+              <text class="icon iconfont margin-right-xs margin-left-lg">
+                &#xe629;
+              </text>
+            </view>
+          </view>
+        </view>
+        <!-- <view class="cu-item  shadow" @tap="goPushList()">
+				<view class="cu-avatar " style="background-image:url(@/static/images/pushList.png)"></view>
 				<view class="content">
 					<view class="">消息推送</view>
 				</view>
@@ -29,51 +32,46 @@
 					</view>
 				</view>
 			</view> -->
-			
-		</view>
-		
-	</view>
+      </view>
+    </scroll-view>
+  </view>
 </template>
 
 <script>
-	import indexBackgroundImage from "@/static/fireBase.png"
-
-	export default {
-		data() {
-			return {
-				indexBackgroundImage:indexBackgroundImage
+import indexBackgroundImage from "@/static/images/fireBase.png";
 
-			}
-		},
-		methods: {
-			
-			goFireBase() {
-				uni.navigateTo({
-					url: '/pages/info/fireBase/fireBase',
-					success: res => {},
-					fail: () => {},
-					complete: () => {}
-				});
-			},
-			goPushList() {
-				uni.navigateTo({
-					url: '/pages/info/pushList/pushList',
-					success: res => {},
-					fail: () => {},
-					complete: () => {}
-				});
-			},
-			
-
-		}
-	}
+export default {
+  data() {
+    return {
+      indexBackgroundImage: indexBackgroundImage,
+    };
+  },
+  methods: {
+    goFireBase() {
+      uni.navigateTo({
+        url: "/pages/info/fireBase/fireBase",
+        success: (res) => {},
+        fail: () => {},
+        complete: () => {},
+      });
+    },
+    goPushList() {
+      uni.navigateTo({
+        url: "/pages/info/pushList/pushList",
+        success: (res) => {},
+        fail: () => {},
+        complete: () => {},
+      });
+    },
+  },
+};
 </script>
-<style>
-	.shadow {
-		box-shadow: 1px 1px 4px rgb(26 26 26 / 10%);
-	}
-</style>
-
-<style lang="scss">  
 
+<style>
+body {
+  background: #fff;
+}
+.shadow {
+  box-shadow: 1px 1px 4px rgb(26 26 26 / 10%);
+}
 </style>

+ 2 - 2
src/pages/info/pushList/pushList.vue

@@ -17,7 +17,7 @@
 			<view class="" style="margin-top:0">
 				<view class="cu-list menu-avatar ">
 					<view class="cu-item" v-for="(item,index) in unporcessList" :key="index" @tap="goFireBaseDetail">
-						<view class="cu-avatar" style="background-image:url(../../../static/push-list.png);"></view>
+						<view class="cu-avatar" style="background-image:url(@/static/images/push-list.png);"></view>
 						<view class="content">
 							<view class="pro-title">
 								<view class="cut">{{item.title}}</view>
@@ -38,7 +38,7 @@
 			<view class="" style="margin-top:0">
 				<view class="cu-list menu-avatar ">
 					<view class="cu-item" v-for="(item,index) in unporcessList" :key="index" @tap="goFireBaseDetail">
-						<view class="cu-avatar" style="background-image:url(../../../static/push-list.png);"></view>
+						<view class="cu-avatar" style="background-image:url(@/static/images/push-list.png);"></view>
 						<view class="content">
 							<view class="pro-title">
 								<view class="cut">{{item.title}}</view>

+ 93 - 136
src/pages/login/login.vue

@@ -5,8 +5,8 @@
       <image class="bgImage" src="@/static/wt/bg.png" v-if="!bg" />
     </view>
     <view class="top">
-      <image class="logo" src="@/static/wt/logo.png" mode="widthFix" />
-      <!-- <text class="title">{{title}}</text> -->
+      <image class="logo" :src="logo" mode="widthFix" v-if="logo"/>
+      <text class="title">{{title}}</text>
     </view>
     <view class="middle login">
       <view
@@ -14,30 +14,28 @@
         style="margin-top: 20px"
         v-if="switchText == '账号密码登录'"
       >
-        <el-input
+        <u-input
           v-model="phone"
-          size="large"
+          prefixIcon="phone"
           placeholder="请输入手机号码"
-          :prefix-icon="Cellphone"
         />
       </view>
 
       <view
         id="login-input"
-        style="margin-top: 20px"
+        style="display: flex; margin-top: 20px"
         v-if="switchText == '账号密码登录'"
       >
-        <el-input
+        <u-input
           style="width: 60%"
           v-model="verify"
-          size="large"
+          prefixIcon="search"
           placeholder="请输入验证码"
-          :prefix-icon="Lock"
         />
 
-        <el-button @click="getVerifyCode">{{
+        <u-button @click="getVerifyCode">{{
           !codeTime ? "获取验证码" : codeTime + "s"
-        }}</el-button>
+        }}</u-button>
       </view>
 
       <view
@@ -45,34 +43,45 @@
         style="margin-top: 20px"
         v-if="switchText == '验证码登录'"
       >
-        <el-input
+        <u-input
+          type="text"
           v-model="username"
-          size="large"
+          prefixIcon="lock"
           placeholder="请输入账号"
-          :prefix-icon="User"
-          :readonly="false"
         />
 
-        <el-input
+        <u-input
           style="margin-top: 20px"
-          type="password"
           v-model="password"
-          class="w-50 m-2"
-          size="large"
+          prefixIcon="search"
           placeholder="请输入密码"
-          :prefix-icon="Lock"
-          show-password
-        />
+          :password="inputIconBool"
+        >
+          <template #suffix>
+            <text
+              class="iconfont ucicon-eye"
+              @click="inputIcon()"
+              v-if="!inputIconBool"
+            ></text>
+            <text
+              class="iconfont ucicon-eye-close"
+              @click="inputIcon()"
+              v-if="inputIconBool"
+            ></text>
+          </template>
+        </u-input>
       </view>
 
-      <view class="switchText" @click="switchMode"
-        ><text>{{ switchText }}</text></view
-      >
+      <!--  -->
+
+      <view class="switchText" @click="switchMode">
+        <text>{{ switchText }}</text>
+      </view>
       <button class="submit" @click="submitRes">登 录</button>
     </view>
     <view class="bottom">
-        <text class="title">{{bottomTitle}}</text>
-    </view> 
+      <div class="title">{{ bottomTitle }}</div>
+    </view>
   </view>
 </template>
 
@@ -85,42 +94,25 @@ import { Lock, User, Cellphone } from "@element-plus/icons-vue";
 const myRequest = inject("$myRequest"); //api请求方法
 const data = reactive({
   /** saas数据 */
-  bg:"/static/wt/bg.png",
-  logo:"/static/wt/logo.png",
-  title:"SaaS平台移动端登录",
-  bottomTitle:"永天科技提供技术支持",
+  bg: "/static/wt/bg.png",
+  logo: undefined,
+  title: undefined,
+  bottomTitle: undefined,
   /** login数据 */
-  phone:undefined,
-  verify:undefined,
-  codeTime:0,
-  switchText:"验证码登录",
-  tenantId:undefined,
-  username:undefined,
-  password:undefined,
+  phone: undefined,
+  verify: undefined,
+  codeTime: 0,
+  switchText: "验证码登录",
+  tenantId: undefined,
+  username: undefined,
+  password: undefined,
+  inputIconBool: true,
 
   // VerificationCodeOne
-<<<<<<< HEAD
 
 })
 const { title, bgc, bottomTitle, logo, 
 phone, verify, codeTime, switchText, username, password, tenantId } = toRefs(data)
-=======
-});
-
-const {
-  title,
-  bg,
-  bottomTitle,
-  logo,
-  phone,
-  verify,
-  codeTime,
-  switchText,
-  username,
-  password,
-  tenantId,
-} = toRefs(data);
->>>>>>> 820ea7e (巡检模块)
 /**登录方式切换 */
 function switchMode(){
   if(switchText.value == "验证码登录"){
@@ -145,6 +137,7 @@ function getVerifyCode() {
     });
     return;
   }
+  verify.value = undefined
   getSendSms({
     phone: phone.value,
   });
@@ -171,24 +164,19 @@ async function getSendSms(params) {
   const res = await myRequest({
     url: '/system/SendSms/noteSending',
     header: {
-      "Content-Type": "multipart/form-data",
+      "Content-Type": "application/json;charset=utf-8",
     },
     method: "GET",
     data: params,
     showLoading: true,
   });
-  if (res.data.data.length > 0) {
-    let data = res.data.data[0];
-    bg.value = data.loginBackUrl;
-    bottomTitle.value = data.loginFooter;
-  }
 }
  /** 获取登录页数据 */ 
 async function getMobileTenantConfig(params) {
   const res = await myRequest({
     url: '/system/sysMobileTenantConfig/getMobileTenantConfig',
     header: {
-      "Content-Type": "multipart/form-data",
+      "Content-Type": "application/json;charset=utf-8",
     },
     method: "GET",
     data: params,
@@ -197,11 +185,28 @@ async function getMobileTenantConfig(params) {
   if (res.data.data.length > 0) {
     let data = res.data.data[0];
     bg.value = data.loginBackUrl;
+    title.value = data.loginTitle
+
     bottomTitle.value = data.loginFooter;
     tenantId.value = data.tenantId;
+    uni.setStorageSync("homeTitle", data.loginTitle);
   }
 }
-getMobileTenantConfig({ url: "172.16.1.47:3000" });
+/**
+ * 判断运行环境
+ */
+function env(){
+  const u = navigator.userAgent
+  //https://blog.csdn.net/weixin_42659644/article/details/126294231  
+  if(u.indexOf('saas')>-1){ //指定app内 获取app识别号
+  }else{
+    //getMobileTenantConfig({ url: "172.16.1.47:3000" })
+    getMobileTenantConfig({ url: window.location.host});
+  }
+  
+}
+env()
+//getMobileTenantConfig({ url: "172.16.1.47:3000" }) // 测试
 /** 点击提交按钮 */
 async function submitRes() {
   if(switchText.value == "账号密码登录"){
@@ -233,6 +238,7 @@ async function submitRes() {
     login({
       phone: phone.value,
       verify: verify.value,
+      tenantId: tenantId.value,
     });
   }else{
      if (!username.value) {
@@ -262,7 +268,7 @@ async function login(data) {
   const res = await myRequest({
     url: '/system/appLogin',
     header: {
-      "Content-Type": "application/json",
+      "Content-Type": "application/json;charset=utf-8",
     },
     method: "post",
     data:data,
@@ -275,9 +281,12 @@ async function login(data) {
 }
 
 /**
- * @inputChange
+ * @密码显示隐藏icon图标事件
+ * @icon点击事件
  */
-function inputChange(e) {}
+function inputIcon() {
+  inputIconBool.value = !inputIconBool.value;
+}
 
 /**
  * @onLoad
@@ -324,81 +333,19 @@ onLoad(() => {
       width:100%;
       position: absolute;
       z-index: 1;
-      font-size: 18px;
+      font-size: 20px;
       text-align: center;
-      color:#fff;
-      
+      color: #fff;
+      font-weight: 700;
     }
   }
   .middle{
     position: absolute;
     z-index: 1;
-    width:calc(100% - 64px);
-    margin:20px 32px 0;
-    .inputWrap{
-      position: relative;
-      input{
-        color:#fff;
-        height:48px;
-        line-height:48px;
-        border-radius: 24px;
-        border:1px solid #fff !important;
-        background: rgba(255,255,255,0.2);
-        padding:0 45px;
-        font-size: 18px;
-        margin-top:25px;
-      }
-      .inputIcon{
-        position: absolute;
-        top:16px;
-        width:15px;
-        left:0px;
-        margin:0px 20px;
-      }
-    }
-    .verifyWrap{
-      margin:0px auto 0px;
-      overflow: hidden !important;
-      .verify{
-        display: inline-block;
-        width:60%;
-        position: relative;
-        vertical-align: middle;
-        input{
-          height:48px;
-          line-height:48px;
-          border-radius: 24px;
-          border:1px solid #fff !important;
-          background: rgba(255,255,255,0.2);
-          padding:0 45px;
-          font-size: 18px;
-        }
-      }
-      
-      .getVerifyCode{
-        height:48px;
-        line-height:48px;
-        border-radius: 24px;
-        border:1px solid #fff;
-        background: rgba(255,255,255,0.2);
-        width:35%;
-        margin:25px 0 0 5%;
-        display: inline-block;
-        vertical-align: middle;
-        .verify2{
-          color:#fff;
-          font-size: 18px;
-          width:100%;
-          text-align: center !important;
-          overflow: hidden;
-          display: block;
-          margin-top:-2px;
-        }
-        
-      }
-    }
-    .switchText{
-      color:#fff;
+    width: calc(100% - 64px);
+    margin: 40px 32px 0;
+    .switchText {
+      color: #fff;
       font-size: 18px;
       margin-top:19px;
       width:100%;
@@ -414,6 +361,16 @@ onLoad(() => {
         margin-top:45px;
     }
   }
+  .bottom{
+    position: absolute;
+    width:100%;
+    bottom:10px;
+    .title{
+      text-align: center;
+      color:#fff;
+      font-size: 14px;
+    }
+  }
 }
 ::placeholder{
   color:#fff;

+ 2 - 2
src/pages/setting/building/building.vue

@@ -99,7 +99,7 @@
         <image
           v-if="!this.getDetailData.build_plan && this.dataRes == 1"
           mode="widthFix"
-          src="/static/defaultImg.jpg"
+          src="@/static/images/defaultImg.jpg"
         />
         <image v-else mode="widthFix" :src="this.getDetailData.layout_plan" />
       </view>
@@ -114,7 +114,7 @@
         <image
           v-if="!this.getDetailData.build_plan && this.dataRes == 1"
           mode="widthFix"
-          src="/static/defaultImg.jpg"
+          src="@/static/images/defaultImg.jpg"
         />
         <image v-else :src="this.getDetailData.build_plan" mode="widthFix" />
       </view>

+ 2 - 2
src/pages/setting/funReport/funReport.vue

@@ -20,7 +20,7 @@
 					@touchmove="ListTouchMove" @touchend="ListTouchEnd" :data-target="'move-box-' + index"
 					>
 					<view class="cu-avatar round lg">
-						<image class="image-bg" src="/static/funcList.png"/>
+						<image class="image-bg" src="@/static/images/funcList.png"/>
 					</view>
 					<view class="content">
 						<view class="pro-title">
@@ -64,7 +64,7 @@
 		height: 64px;
 		background: #fff;">
 				<view class="plus">
-					<image src="/static/plus.png" style="width:100rpx;height:100rpx" @tap="goAddPage()"></image>
+					<image src="@/static/images/plus.png" style="width:100rpx;height:100rpx" @tap="goAddPage()"></image>
 				</view>
 			</view>
 			

+ 69 - 77
src/pages/setting/setting.vue

@@ -2,7 +2,7 @@
   <view class="setting-wrapper">
     <view class="top-banner justify-center align-center text-center">
       <view>
-        <image width="130" src="/static/personal-head.png"></image>
+        <image width="130" src="@/static/images/personal-head.png"></image>
         <view class="userName">admin</view>
         <view>上海永天科技股份有限公司</view>
       </view>
@@ -10,7 +10,7 @@
     <view class="cu-list menu-avatar padding-lr">
       <view class="cu-item shadow" @tap="goMessagePush()">
         <view class="cu-avatar">
-          <image class="image-bg" src="/static/push-icon.png" />
+          <image class="image-bg" src="@/static/images/push-icon.png" />
         </view>
         <view class="content">
           <view class="">推送设置</view>
@@ -26,7 +26,7 @@
 
       <view class="cu-item shadow" @tap="goBuilding()">
         <view class="cu-avatar">
-          <image class="image-bg" src="/static/building-icon.png" />
+          <image class="image-bg" src="@/static/images/building-icon.png" />
         </view>
         <view class="content">
           <view class="">建筑管理</view>
@@ -42,7 +42,7 @@
 
       <view class="cu-item shadow" @tap="goFunReport()">
         <view class="cu-avatar">
-          <image class="image-bg" src="/static/funcReport.png" />
+          <image class="image-bg" src="@/static/images/funcReport.png" />
         </view>
         <view class="content">
           <view class="">功能报备</view>
@@ -56,8 +56,12 @@
         </view>
       </view>
 
+      <view style="margin-top: 20px">
+        <u-button @click="loginOut()" text="退出登录"></u-button>
+      </view>
+
       <!-- <view class="cu-item" @tap="goSiteManage" v-if="permissionLabel==1">
-				<view class="cu-avatar " style="background-image:url(../../static/setting-icon2.png)"></view>
+				<view class="cu-avatar " style="background-image:url(@/static/images/setting-icon2.png)"></view>
 				<view class="content">
 					<view class="">站点管理</view>
 				</view>
@@ -68,7 +72,7 @@
 				</view>
 			</view>
 			<view class="cu-item" @tap="goAuthManage" v-if="permissionLabel==1">
-				<view class="cu-avatar " style="background-image:url(../../static/setting-icon4.png)"></view>
+				<view class="cu-avatar " style="background-image:url(@/static/images/setting-icon4.png)"></view>
 				<view class="content">
 					<view class="">权限管理</view>
 				</view>
@@ -82,78 +86,63 @@
   </view>
 </template>
 
-<script>
-export default {
-  data() {
-    return {
-      permissionLabel: 0,
-    };
-  },
-  onLoad() {
-    // this.getAuthorization()
-  },
-  methods: {
-    async getAuthorization(params) {
-      const res = await this.$myRequest({
-        url: "Com/getAuthorization",
-        showLoading: true,
-        data: params,
-      });
+<script setup>
+import { onLoad, onShow, onHide, onLaunch } from "@dcloudio/uni-app";
+import { ref, onMounted, inject, shallowRef } from "vue";
+
+import useXunJianStore from "@/store/modules/xunJian";
+const settingsStore = useXunJianStore(); //全局变量值Store
+
+const permissionLabel = ref(0);
 
-      console.log(res.data.permissionLabel);
-      this.permissionLabel = res.data.permissionLabel;
-    },
+async function getAuthorization(params) {
+  const res = await this.$myRequest({
+    url: "Com/getAuthorization",
+    showLoading: true,
+    data: params,
+  });
 
-    // goSiteManage() {
-    // 	uni.navigateTo({
-    // 		url: '/pages/siteManage/siteManage?type=1',
-    // 		success: res => {},
-    // 		fail: () => {},
-    // 		complete: () => {}
-    // 	});
-    // },
-    // goDeviceManage() {
-    // 	uni.navigateTo({
-    // 		url: '/pages/siteManage/siteManage?type=2',
-    // 		success: res => {},
-    // 		fail: () => {},
-    // 		complete: () => {}
-    // 	});
-    // },
-    // goAuthManage() {
-    // 	uni.navigateTo({
-    // 		url: '/pages/authManage/authManage',
-    // 		success: res => {},
-    // 		fail: () => {},
-    // 		complete: () => {}
-    // 	});
-    // },
-    goMessagePush() {
-      uni.navigateTo({
-        url: "/pages/setting/messagePush/messagePush",
-        success: (res) => {},
-        fail: () => {},
-        complete: () => {},
-      });
-    },
-    goBuilding() {
-      uni.navigateTo({
-        url: "/pages/setting/building/building",
-        success: (res) => {},
-        fail: () => {},
-        complete: () => {},
-      });
-    },
-    goFunReport() {
-      uni.navigateTo({
-        url: "/pages/setting/funReport/funReport",
-        success: (res) => {},
-        fail: () => {},
-        complete: () => {},
-      });
-    },
-  },
-};
+  this.permissionLabel = res.data.permissionLabel;
+}
+
+function goMessagePush() {
+  uni.navigateTo({
+    url: "/pages/setting/messagePush/messagePush",
+    success: (res) => {},
+    fail: () => {},
+    complete: () => {},
+  });
+}
+function goBuilding() {
+  uni.navigateTo({
+    url: "/pages/setting/building/building",
+    success: (res) => {},
+    fail: () => {},
+    complete: () => {},
+  });
+}
+function goFunReport() {
+  uni.navigateTo({
+    url: "/pages/setting/funReport/funReport",
+    success: (res) => {},
+    fail: () => {},
+    complete: () => {},
+  });
+}
+
+/**
+ * @退出登录
+ */
+function loginOut() {
+  //销毁存储的token
+  uni.clearStorage()
+  //关闭当前页面 返回指定页面
+  uni.redirectTo({
+    url: "/pages/login/login",
+  });
+}
+
+onLoad(() => {});
 </script>
 
 <style lang="scss">
@@ -161,7 +150,7 @@ export default {
   .top-banner {
     width: 100%;
     height: 380rpx;
-    background: url(../../static/setting-bg.png) no-repeat;
+    background: url(@/static/images/setting-bg.png) no-repeat;
     background-size: cover;
     color: #fff;
     display: flex;
@@ -193,6 +182,9 @@ export default {
 }
 </style>
 <style>
+body {
+  background: #fff;
+}
 .shadow {
   box-shadow: 1px 1px 4px rgb(26 26 26 / 10%);
 }

+ 146 - 0
src/pages/xunJian/collect/components/collectDetail.vue

@@ -0,0 +1,146 @@
+<template>
+  <scroll-view scroll-y class="grayBackgroundColor">
+    <view class="whiteBackgroundColor" style="padding: 15px 15px 15px 15px">
+      <u-form
+        ref="form"
+        labelPosition="left"
+        :model="model"
+        :rules="rules"
+        labelWidth="82"
+      >
+        <u-form-item label="地点号码:" prop="siteNubmber">
+          <u-input v-model="model.siteNubmber" disabled></u-input>
+        </u-form-item>
+        <u-form-item label="地点名称:" prop="siteName">
+          <u-input v-model="model.siteName"></u-input>
+        </u-form-item>
+        <u-form-item label="备注:" prop="siteDescribe">
+          <u-input v-model="model.siteDescribe"></u-input>
+        </u-form-item>
+      </u-form>
+
+      <u-button
+        type="primary"
+        style="width: 100%; height: 40px; font-size: 14px; margin-top: 15px"
+        @click="handleInsert()"
+        shape="circle"
+      >
+        保存
+      </u-button>
+    </view>
+  </scroll-view>
+</template>
+
+<script setup>
+import {
+  onReady,
+  onLoad,
+  onShow,
+  onPullDownRefresh, //下拉刷新
+  onReachBottom, // 上拉加载
+  onNavigationBarButtonTap,
+} from "@dcloudio/uni-app";
+import { reactive, ref, onMounted, inject, shallowRef } from "vue";
+import useXunJianStore from "@/store/modules/xunJian";
+
+const myRequest = inject("$myRequest"); //全局接口请求
+const settingsStore = useXunJianStore(); //全局变量值Store
+
+const form = ref(null); //表单refs获取
+const model = reactive({
+  siteType: 1,
+  siteTime: "",
+  swipeBool: false,
+  siteName: "",
+  siteNubmber: "",
+  siteDescribe: "",
+}); //form表单数据定义
+const rules = ref({
+  siteName: {
+    type: "string",
+    required: true,
+    message: "地点名称不能为空",
+    trigger: ["blur", "change"],
+  },
+
+  siteNubmber: [
+    { required: true, message: "地点编号不能为空", trigger: "blur" },
+  ],
+
+  siteDescribe: [
+    { min: 1, max: 30, message: "长度在 1 到 30 个字符", trigger: "blur" },
+  ],
+}); //form表单校验
+
+/**
+ * @保存按钮点击事件
+ */
+function handleInsert() {
+  form.value
+    .validate()
+    .then((res) => {
+      let endTime = new Date();
+      model.siteTime = settingsStore.formatterDate(
+        endTime,
+        "yyyy-MM-dd hh:mm:ss"
+      );
+
+      settingsStore.collectDataList.push(model);
+
+      //   uni.navigateTo({
+      //     url: "/pages/xunJian/collect/index",
+      //   });
+      uni.navigateBack({
+        delta: 1, //返回到需要执行方法的页面
+      });
+    })
+    .catch((errors) => {
+      uni.$u.toast("校验失败");
+    });
+}
+
+onLoad((options) => {
+  model.siteNubmber = options.siteNubmber;
+});
+
+onMounted(() => {});
+</script>
+
+<style lang="scss">
+.is-selected {
+  color: #1989fa;
+}
+</style>
+
+<style scoped>
+body,
+uni-page-body,
+uni-page-refresh,
+.grayBackgroundColor {
+  background: rgb(241, 241, 241);
+}
+.whiteBackgroundColor {
+  background-color: #ffffff;
+}
+
+.reportLeft {
+  margin-right: 15px;
+  display: flex;
+}
+
+.reportCenter {
+}
+
+.reportCenter .centerSiteName {
+  font-size: 15px;
+  margin-bottom: 5px;
+  height: 20px;
+  line-height: 20px;
+  display: flex;
+}
+
+.reportRight {
+  display: flex;
+  padding: 0 15px;
+}
+</style>

+ 173 - 0
src/pages/xunJian/collect/components/collectRecord.vue

@@ -0,0 +1,173 @@
+<template>
+  <scroll-view scroll-y class="grayBackgroundColor">
+    <view class="example-body" v-if="show">
+      <uni-datetime-picker
+        v-model="datetimerange"
+        type="daterange"
+        rangeSeparator="~"
+        @change="confirm"
+      />
+    </view>
+    <view
+      v-for="(cu, index) in dataList.siteList"
+      :key="index"
+      class="whiteBackgroundColor"
+      style="display: flex; padding: 15px 0px 15px 15px; margin-bottom: 15px"
+    >
+      <view class="reportLeft">
+        <u-image
+          style="margin: auto"
+          width="40"
+          height="40"
+          src="@/static/inspection/scan.png"
+          v-if="cu.siteType == 1"
+          shape="circle"
+        ></u-image>
+
+        <u-image
+          style="margin: auto"
+          width="40"
+          height="40"
+          src="@/static/inspection/NFC.png"
+          v-if="cu.siteType == 2"
+          shape="circle"
+        ></u-image>
+      </view>
+      <view class="reportCenter">
+        <view class="centerSiteName">
+          {{ cu.siteName }}
+        </view>
+
+        <view style="font-size: 13px; color: #a1a1a1">
+          {{
+            cu.createTime == "" || cu.createTime == null ? "无" : cu.createTime
+          }}
+        </view>
+      </view>
+      <view style="margin: auto"></view>
+      <view class="reportRight">
+        <view style="margin: auto">
+          <view style="padding: 0; font-size: 14px; color: #a1a1a1">
+            已提交
+          </view>
+        </view>
+      </view>
+    </view>
+
+    <u-empty
+      marginTop="20%"
+      mode="data"
+      icon="http://cdn.uviewui.com/uview/empty/data.png"
+      v-if="dataList.siteList.length <= 0"
+    >
+    </u-empty>
+  </scroll-view>
+</template>
+
+<script setup>
+import {
+  onReady,
+  onLoad,
+  onShow,
+  onNavigationBarButtonTap,
+} from "@dcloudio/uni-app";
+import { reactive, ref, onMounted, inject, shallowRef } from "vue";
+import useXunJianStore from "@/store/modules/xunJian";
+
+const myRequest = inject("$myRequest"); //全局接口请求
+const settingsStore = useXunJianStore(); //全局变量值Store
+
+const show = ref(false);
+
+const dataList = reactive({
+  siteList: [],
+  startTime: "",
+  endTime: "",
+});
+
+/**
+ * @日期选中事件回调
+ */
+function confirm(e) {
+  dataList.startTime = e[0];
+  dataList.endTime = e[1];
+  handleSelectApi();
+}
+
+/**
+ * @采集记录接口查询
+ * @api请求
+ */
+async function handleSelectApi() {
+  const res = await myRequest({
+    url: "/service-fire/appPatrolInspection/siteList",
+    header: {
+      "Content-Type": "application/json;charset=utf-8",
+    },
+    method: "GET",
+    data: {
+      startTime: dataList.startTime, //开始时间
+      endTime: dataList.endTime, //结束时间
+    },
+  });
+  if (res.data.status == "SUCCESS") {
+    dataList.siteList = res.data.data;
+  } else {
+  }
+}
+
+// 自定义导航事件
+onNavigationBarButtonTap((e) => {
+  if (e.float == "right") {
+    show.value = !show.value;
+  } else {
+  }
+});
+
+onLoad((options) => {});
+
+onReady(() => {});
+
+onMounted(() => {
+  handleSelectApi();
+});
+</script>
+
+<style lang="scss">
+.is-selected {
+  color: #1989fa;
+}
+</style>
+
+<style scoped>
+body,
+uni-page-body,
+uni-page-refresh,
+.grayBackgroundColor {
+  background: rgb(241, 241, 241);
+}
+.whiteBackgroundColor {
+  background-color: #ffffff;
+}
+
+.reportLeft {
+  margin-right: 15px;
+  display: flex;
+}
+
+.reportCenter {
+}
+
+.reportCenter .centerSiteName {
+  font-size: 15px;
+  margin-bottom: 5px;
+  height: 20px;
+  line-height: 20px;
+  display: flex;
+}
+
+.reportRight {
+  display: flex;
+  padding: 0 15px;
+}
+</style>

+ 283 - 0
src/pages/xunJian/collect/index.vue

@@ -0,0 +1,283 @@
+<template>
+  <scroll-view scroll-y class="grayBackgroundColor">
+    <!-- 按组使用 -->
+    <uni-swipe-action>
+      <uni-swipe-action-item
+        v-for="(cu, index) in settingsStore.collectDataList"
+        :key="index"
+        :right-options="options"
+        @click="bindClick($event, index)"
+        @change="swipeChange($event, index)"
+        style="margin-bottom: 15px"
+      >
+        <view
+          class="whiteBackgroundColor"
+          style="display: flex; padding: 15px 0px 15px 15px"
+        >
+          <view class="reportLeft">
+            <u-image
+              style="margin: auto"
+              width="40"
+              height="40"
+              src="@/static/inspection/scan.png"
+              v-if="cu.siteType == 1"
+              shape="circle"
+            ></u-image>
+
+            <u-image
+              style="margin: auto"
+              width="40"
+              height="40"
+              src="@/static/inspection/NFC.png"
+              v-if="cu.siteType == 2"
+              shape="circle"
+            ></u-image>
+          </view>
+          <view class="reportCenter">
+            <view class="centerSiteName">
+              {{ cu.siteName }}
+            </view>
+
+            <view style="font-size: 13px; color: #a1a1a1">
+              {{
+                cu.siteTime == "" || cu.siteTime == null ? "无" : cu.siteTime
+              }}
+            </view>
+          </view>
+          <view style="margin: auto"></view>
+          <view class="reportRight">
+            <view style="margin: auto" v-if="cu.swipeBool == false">
+              <view
+                style="padding: 0; font-size: 14px; color: #409eff"
+                @click="handleInsert(cu)"
+              >
+                提交
+              </view>
+            </view>
+          </view>
+        </view>
+      </uni-swipe-action-item>
+    </uni-swipe-action>
+
+    <view style="position: fixed; right: 0; bottom: 50px">
+      <u-image
+        width="67"
+        height="67"
+        src="@/static/inspection/plan-scan.png"
+        shape="circle"
+        @click="scanClick()"
+      ></u-image>
+    </view>
+
+    <!-- 提示信息弹窗 -->
+    <uni-popup ref="message" type="message">
+      <uni-popup-message
+        :style="{
+          color: messageList.color,
+        }"
+        :type="messageList.type"
+        :message="messageList.message"
+        :duration="messageList.duration"
+      ></uni-popup-message>
+    </uni-popup>
+
+    <u-empty
+      marginTop="20%"
+      mode="data"
+      icon="http://cdn.uviewui.com/uview/empty/data.png"
+      v-if="settingsStore.collectDataList.length <= 0"
+    >
+    </u-empty>
+  </scroll-view>
+</template>
+
+<script setup>
+import {
+  onReady,
+  onLoad,
+  onShow,
+  onNavigationBarButtonTap,
+} from "@dcloudio/uni-app";
+import { ref, onMounted, inject, shallowRef, reactive } from "vue";
+import useXunJianStore from "@/store/modules/xunJian";
+
+const myRequest = inject("$myRequest"); //全局接口请求
+const settingsStore = useXunJianStore(); //全局变量值Store
+
+/**
+ * @扫一扫
+ * @点击事件
+ */
+const scanArray = ref([]);
+const scanBool = ref(false);
+function scanClick() {
+  uni.scanCode({
+    success: (e) => {
+      uni.showToast({
+        title: "扫码成功",
+        icon: "none",
+      });
+      uni.navigateTo({
+        url:
+          "/pages/xunJian/collect/components/collectDetail?siteNubmber=" +
+          e.result,
+      });
+    },
+    fail: (err) => {
+      uni.showToast({
+        title: "扫码失败",
+        icon: "none",
+      });
+      console.log("扫码失败", err);
+    },
+    complete: () => {
+      console.log("扫码结束");
+    },
+  });
+}
+
+/**
+ * @api请求
+ * @提交按钮点击事件
+ */
+const message = ref(null);
+const messageList = reactive({
+  type: "",
+  message: "",
+  duration: 0,
+  color: "",
+});
+function handleInsert(e) {
+  uni.getLocation({
+    type: "wgs84",
+    success: function (res) {
+      console.log("当前位置的经度:" + res.longitude);
+      console.log("当前位置的纬度:" + res.latitude);
+      api(res.longitude, res.latitude);
+    },
+    fail: function (res) {
+      uni.showToast({
+        title: "请打开手机定位或相关应用权限定位!",
+        icon: "none",
+      });
+    },
+  });
+
+  async function api(longitude, latitude) {
+    const res = await myRequest({
+      url: "/service-fire/appPatrolInspection/addSite",
+      header: {
+        "Content-Type": "application/json;charset=utf-8",
+      },
+      method: "POST",
+      data: {
+        siteName: e.siteName, //地点名称
+        siteNubmber: e.siteNubmber, //地点号码
+        siteDescribe: e.siteDescribe, //地点描述
+        siteType: e.siteType, //地点类型(1二维码,2NFC)
+        longitude: longitude, //经度
+        latitude: latitude, //纬度
+        pictureUrl: "", //图片地址
+        distanceRange: 10, //误差范围
+        // areaId: 0, //区域id
+        // companyId: 0, //单位ID
+      },
+    });
+    if (res.data.status == "SUCCESS") {
+      messageList.type = "SUCCESS";
+      messageList.message = "提交成功";
+      messageList.duration = 2000;
+      messageList.color = "#09bb07";
+      message.value.open();
+
+      settingsStore.collectDataList.splice(
+        settingsStore.collectDataList.indexOf(e),
+        1
+      );
+    } else {
+    }
+  }
+}
+
+const options = ref([
+  {
+    text: "删除",
+    style: {
+      backgroundColor: "#dd524d",
+    },
+  },
+]);
+
+/**
+ * @左滑删除点击事件
+ */
+function bindClick(e, index) {
+  settingsStore.collectDataList.splice(index, 1);
+}
+
+/**
+ * @左滑删除change事件
+ */
+function swipeChange(e, index) {
+  if (e == "right") {
+    settingsStore.collectDataList[index].swipeBool = true;
+  } else {
+    settingsStore.collectDataList[index].swipeBool = false;
+  }
+}
+
+// 自定义导航事件
+onNavigationBarButtonTap((e) => {
+  if (e.float == "right") {
+    uni.navigateTo({
+      url: "/pages/xunJian/collect/components/collectRecord",
+    });
+  } else {
+  }
+});
+
+onLoad((options) => {});
+
+onReady(() => {});
+
+onMounted(() => {});
+</script>
+
+<style lang="scss">
+.is-selected {
+  color: #1989fa;
+}
+</style>
+
+<style scoped>
+body,
+uni-page-body,
+uni-page-refresh,
+.grayBackgroundColor {
+  background: rgb(241, 241, 241);
+}
+.whiteBackgroundColor {
+  background-color: #ffffff;
+}
+
+.reportLeft {
+  margin-right: 15px;
+  display: flex;
+}
+
+.reportCenter {
+}
+
+.reportCenter .centerSiteName {
+  font-size: 15px;
+  margin-bottom: 5px;
+  height: 20px;
+  line-height: 20px;
+  display: flex;
+}
+
+.reportRight {
+  display: flex;
+  padding: 0 15px;
+}
+</style>

+ 33 - 19
src/pages/xunJian/components/echarts/chart.vue

@@ -1,13 +1,21 @@
 <template>
   <view class="content">
-    <view @click="initEcharts" :prop="option" id="echarts" class="echarts">
-    </view>
+    <l-echart ref="domMyChart" class="echarts"></l-echart>
+    <!-- <view
+      @click="initEcharts"
+      :prop="option"
+      ref="domMyChart"
+      id="linEcharts"
+      class="echarts"
+    >
+    </view> -->
   </view>
 </template>
 
 <script setup>
 import * as echarts from "echarts";
-import { defineComponent, ref, onMounted } from "vue";
+import { onLoad, onShow, onHide, onLaunch, onResize } from "@dcloudio/uni-app";
+import { defineComponent, ref, onMounted, nextTick } from "vue";
 
 const props = defineProps({
   currentDateList: {
@@ -17,6 +25,7 @@ const props = defineProps({
 });
 
 let myChart;
+const domMyChart = ref(null);
 var datas = [
   {
     name: "漏检任务",
@@ -49,7 +58,7 @@ let option = {
         `{value|${props.currentDateList[0].planSonCount}}`,
         "{name|巡检总数}",
       ].join("\n "),
-      top: 135,
+      top: "40%",
       left: "center",
       textStyle: {
         color: "black",
@@ -78,10 +87,9 @@ let option = {
   series: {
     type: "pie",
     radius: [40, 80],
-    top: 10,
     height: "100%",
     left: "center",
-    width: 350,
+    width: "100%",
     itemStyle: {
       borderColor: "#fff",
       borderWidth: 1,
@@ -107,7 +115,8 @@ let option = {
       maxSurfaceAngle: 80,
     },
     labelLayout: function (params) {
-      var isLeft = params.labelRect.x < myChart.getWidth() / 2;
+      // var isLeft = params.labelRect.x < myChart.getWidth() / 2;
+      var isLeft = params.labelRect.x < myChart.nodeWidth / 2;
       var points = params.labelLinePoints;
       points[2][0] = isLeft
         ? params.labelRect.x
@@ -121,22 +130,27 @@ let option = {
   },
 };
 
-onMounted(() => {
-  initEcharts();
-});
-
 function initEcharts() {
-  myChart = echarts.init(document.getElementById("echarts"));
-
+  // let dom = uni.createSelectorQuery().select("#linEcharts");
+  // myChart = echarts.init(document.getElementById("linEcharts"));
   // 观测更新的数据在 view 层可以直接访问到
-  myChart.setOption(option);
+  // myChart.setOption(option);
+
+  myChart = domMyChart.value;
+  myChart.init(echarts, (myChart) => {
+    myChart.setOption(option);
+  });
 }
 
-window.onresize = () => {
-  return (() => {
-    myChart.resize();
-  })();
-};
+onLoad(() => {
+  nextTick(() => {
+    initEcharts();
+  });
+});
+
+onResize(() => {
+  myChart.resize();
+});
 </script>
 
 <style>

+ 187 - 95
src/pages/xunJian/plan/components/content.vue

@@ -4,98 +4,126 @@
       <view
         class="whiteBackgroundColor"
         style="padding: 15px; margin-bottom: 15px"
-        v-for="(con, index) in settingsStore.contentArray.contentList"
+        v-for="(con, index) in contentList"
         :key="index"
       >
         <view class="siteHeader">
-          <view class="siteHeader-titleIcon" style="margin-right: 10px"> </view>
-          <view class="siteHeader-title">{{ con.contentTitle }} </view>
+          <uni-section :title="con.contentTitle" type="line"></uni-section>
 
           <view style="margin: auto"> </view>
 
-          <el-button
+          <u-button
             v-if="con.remarksBool == false"
             type="primary"
-            icon="Operation"
-            style="width: 18px; height: 18px; font-size: 13px; padding: 8px 9px"
-            round
+            icon="list-dot"
+            style="width: 18px; height: 18px; padding: 0; margin: 0"
+            shape="circle"
             @click="remarksClick(index)"
           >
-          </el-button>
+          </u-button>
         </view>
         <view>
-          <view v-if="con.submissionMethod == 1">
-            <el-row>
-              <el-col
-                v-for="option in con.contentOptionList"
-                :key="option"
-                :span="12"
-              >
-                <el-checkbox-group v-model="con.contentOptionListValue1">
-                  <el-checkbox :label="option.id">
-                    {{ option.optionName }}
-                  </el-checkbox>
-                </el-checkbox-group>
-              </el-col>
-            </el-row>
+          <view v-if="con.submissionMethod == 1" style="margin-top: 15px">
+            <u-checkbox-group
+              v-model="con.contentOptionListValue1"
+              @change="
+                (val) => {
+                  checkboxChange(val, index);
+                }
+              "
+              :disabled="
+                settingsStore.contentArray.siteList.inspectionStatus == 2
+              "
+            >
+              <u-row style="width: 100%; flex-wrap: wrap">
+                <u-col
+                  v-for="option in con.contentOptionList"
+                  :key="option"
+                  span="6"
+                  style="margin-bottom: 15px"
+                >
+                  <u-checkbox
+                    :label="option.optionName"
+                    :name="option.id"
+                    :checked="
+                      con.contentOptionListValue1.length > 0
+                        ? con.contentOptionListValue1.indexOf(option.id) >= 0
+                        : false
+                    "
+                  >
+                  </u-checkbox>
+                </u-col>
+              </u-row>
+            </u-checkbox-group>
+
             <view
               v-if="con.remarksBool == true"
               style="
                 display: flex;
-                margin-top: 15px;
                 height: 32px;
                 line-height: 32px;
                 white-space: nowrap;
               "
             >
               <span style="">备注:</span>
-              <el-input v-model="con.remarks" placeholder="请输入备注" />
+              <u-input
+                v-model="con.remarks"
+                placeholder="请输入备注"
+                :disabled="
+                  settingsStore.contentArray.siteList.inspectionStatus == 2
+                "
+              ></u-input>
             </view>
           </view>
-          <view v-if="con.submissionMethod == 2">
-            <el-row>
-              <el-col
-                v-for="option in con.contentOptionList"
-                :key="option"
-                :span="12"
-              >
-                <el-radio-group
-                  v-model="con.contentOptionListValue"
-                  class="ml-4"
+          <view v-if="con.submissionMethod == 2" style="margin-top: 15px">
+            <u-radio-group placement="row" v-model="con.contentOptionListValue">
+              <u-row style="width: 100%; flex-wrap: wrap">
+                <u-col
+                  v-for="option in con.contentOptionList"
+                  :key="option"
+                  :span="6"
+                  style="margin-bottom: 15px"
                 >
-                  <el-radio :label="option.id" size="large">
-                    {{ option.optionName }}
-                  </el-radio>
-                </el-radio-group>
-              </el-col>
-            </el-row>
+                  <u-radio
+                    :disabled="
+                      settingsStore.contentArray.siteList.inspectionStatus == 2
+                    "
+                    :label="option.optionName"
+                    :name="option.id"
+                  >
+                  </u-radio>
+                </u-col>
+              </u-row>
+            </u-radio-group>
+
             <view
               v-if="con.remarksBool == true"
               style="
                 display: flex;
-                margin-top: 15px;
                 height: 32px;
                 line-height: 32px;
                 white-space: nowrap;
               "
             >
               <span style="">备注:</span>
-              <el-input v-model="con.remarks" placeholder="请输入备注" />
+              <u-input
+                v-model="con.remarks"
+                placeholder="请输入备注"
+                :disabled="
+                  settingsStore.contentArray.siteList.inspectionStatus == 2
+                "
+              ></u-input>
             </view>
           </view>
-          <view v-if="con.submissionMethod == 3">
-            <span v-if="settingsStore.inspectionStatus == 2">
-              {{ con.contentOptionListValue }}
-            </span>
-            <el-input
-              v-if="settingsStore.inspectionStatus == 1"
+          <view v-if="con.submissionMethod == 3" style="margin-top: 15px">
+            <u-textarea
               v-model="con.contentOptionListValue"
-              :rows="5"
-              resize="none"
-              type="textarea"
-              maxlength="30"
               placeholder="请输入"
-            />
+              maxlength="30"
+              :disabled="
+                settingsStore.contentArray.siteList.inspectionStatus == 2
+              "
+            ></u-textarea>
 
             <view
               v-if="con.remarksBool == true"
@@ -108,7 +136,13 @@
               "
             >
               <span style="">备注:</span>
-              <el-input v-model="con.remarks" placeholder="请输入备注" />
+              <u-input
+                v-model="con.remarks"
+                placeholder="请输入备注"
+                :disabled="
+                  settingsStore.contentArray.siteList.inspectionStatus == 2
+                "
+              ></u-input>
             </view>
           </view>
         </view>
@@ -118,46 +152,58 @@
     </view>
     <view style="position: fixed; left: 0; right: 0; bottom: 0; padding: 15px">
       <view>
-        <el-button
-          v-if="settingsStore.inspectionStatus == 1"
+        <u-button
+          v-if="settingsStore.contentArray.siteList.inspectionStatus == 1"
           type="primary"
-          round
           style="
             width: 100%;
             height: 40px;
             font-size: 14px;
             margin-bottom: 15px;
           "
+          shape="circle"
           @click="buttonClick(1)"
         >
           上一步
-        </el-button>
+        </u-button>
       </view>
       <view>
-        <el-button
-          v-if="settingsStore.inspectionStatus == 1"
+        <u-button
+          v-if="settingsStore.contentArray.siteList.inspectionStatus == 1"
           type="primary"
-          round
           style="width: 100%; height: 40px; font-size: 14px"
+          shape="circle"
           @click="buttonClick(2)"
         >
           提交
-        </el-button>
+        </u-button>
       </view>
     </view>
+
+    <u-modal
+      ref="uModal"
+      :show="show"
+      :title="title"
+      :content="content"
+      @confirm="confirm"
+    ></u-modal>
   </scroll-view>
 </template>
 
 <script setup>
 import { onLoad, onShow } from "@dcloudio/uni-app";
 import { ref, onMounted, inject, shallowRef } from "vue";
-import { ElMessage, ElMessageBox } from "element-plus";
 const myRequest = inject("$myRequest");
 const BASE_URL = inject("$BASE_URL");
 
 import useXunJianStore from "@/store/modules/xunJian";
 const settingsStore = useXunJianStore(); //全局变量值Store
 
+const contentList = ref([]);
+function checkboxChange(value, index) {
+  contentList.value[index].contentOptionListValue1 = value;
+}
+
 /**
  * @按钮点击事件
  * @备注显示事件
@@ -166,28 +212,58 @@ function remarksClick(index) {
   settingsStore.contentArray.contentList[index].remarksBool = true;
 }
 
+/**
+ * @confirm确定回调事件
+ * @模态框
+ */
+const show = ref(false);
+const title = ref("");
+const content = ref("");
+function confirm() {
+  show.value = false;
+  uni.$emit("planSelect"); //执行页面中的自定义方法
+  uni.navigateBack({
+    delta: 3, //返回到需要执行方法的页面
+  });
+}
+
 /**
  * @按钮点击事件
  * @上一步
  * @提交
  */
-
 async function buttonClick(type) {
   if (type == 1) {
     //上一步
-    uni.navigateTo({
-      url: "/pages/xunJian/plan/components/siteDetails",
+    uni.navigateBack({
+      delta: 1,
     });
   } else if (type == 2) {
     //提交
 
-    const contentList = settingsStore.contentArray.contentList;
     const recordOptionList = [];
-    if (contentList.length > 0) {
-      contentList.forEach((e) => {
+    if (contentList.value.length > 0) {
+      contentList.value.forEach((e) => {
+        if (e.contentOptionListValue && e.contentOptionList.length > 0) {
+          recordOptionList.push({
+            contentId: e.id,
+            contentOptionId: e.contentOptionListValue,
+            remarks: e.remarks,
+          });
+        }
+
+        if (e.contentOptionListValue && e.contentOptionList.length == 0) {
+          recordOptionList.push({
+            contentId: e.id,
+            content: e.contentOptionListValue,
+            remarks: e.remarks,
+          });
+        }
+
         if (e.contentOptionListValue1.length > 0) {
           e.contentOptionListValue1.forEach((l) => {
             recordOptionList.push({
+              contentId: e.id,
               contentOptionId: l,
               remarks: e.remarks,
             });
@@ -219,27 +295,52 @@ async function buttonClick(type) {
     });
 
     if (res.data.status == "SUCCESS") {
-      ElMessageBox.alert("提交成功,确定后返回!", "消息", {
-        type: "success",
-        showClose: false,
-        confirmButtonText: "OK",
-        callback: (action) => {
-          uni.navigateTo({
-            url: "/pages/xunJian/plan/index",
-          });
-        },
-      });
+      title.value = "消息";
+      content.value = "提交成功,确定后返回!";
+      show.value = true;
     } else {
     }
   }
 }
 
-onLoad((options) => {});
+onLoad((options) => {
+  contentList.value = settingsStore.contentArray.contentList;
+
+  if (settingsStore.contentArray.siteList.inspectionStatus == 2) {
+    if (contentList.value.length > 0) {
+      contentList.value.forEach((el) => {
+        el.contentOptionListValue1 = [];
+      });
+
+      contentList.value.filter((e) => {
+        if (e.remarks) {
+          e.remarksBool = true;
+        } else {
+          e.remarksBool = false;
+        }
+
+        if (e.contentOptionList) {
+          e.contentOptionList.forEach((s) => {
+            if (e.contentOptionValue.indexOf(s.id) >= 0) {
+              //提交方式:1多选 2单选 3输入框
+              if (e.submissionMethod == 1) {
+                e.contentOptionListValue1.push(s.id);
+              } else if (e.submissionMethod == 2) {
+                e.contentOptionListValue = s.id;
+              }
+            }
+          });
+        } else {
+          e.contentOptionListValue = e.content;
+        }
+      });
+    }
+  }
+});
 
 onMounted(() => {});
 </script>
 
-
 <style scoped>
 uni-page-body,
 uni-page-refresh,
@@ -250,22 +351,13 @@ uni-page-refresh,
 .whiteBackgroundColor {
   background-color: #ffffff;
 }
+</style>
 
+<style lang="scss">
 .siteHeader {
   display: flex;
-  height: 15px;
-  line-height: 15px;
+  height: 18px;
+  line-height: 18px;
   margin-bottom: 10px;
 }
-
-.siteHeader-titleIcon {
-  width: 2px;
-  background-color: #149eff;
-}
-
-.siteHeader-title {
-  font-size: 15px;
-  color: #149eff;
-  font-weight: 600;
-}
-</style>
+</style>

+ 21 - 22
src/pages/xunJian/plan/components/drawer.vue

@@ -1,14 +1,7 @@
 <template>
-  <el-drawer
-    @open="open"
-    @close="close"
-    v-model="scanBool"
-    direction="btt"
-    :show-close="false"
-    size="50%"
-  >
-    <template #header style="margin-bottom: 0px">
-      <view>
+  <u-popup :show="scanBool" @close="close" @open="open" mode="bottom">
+    <template #default>
+      <view style="margin-bottom: 15px; margin-top: 15px">
         <h4
           style="
             font-size: 16px;
@@ -23,16 +16,21 @@
           当前地点存在于多个计划,请选择目标计划
         </view>
       </view>
-    </template>
-    <template #default>
-      <scroll-view scroll-y>
-        <view v-for="scan in scanArray" :key="scan">
+      <scroll-view
+        scroll-y
+        style="
+          padding-left: 15px;
+          padding-right: 15px;
+          height: calc(100vh - 30rem);
+        "
+      >
+        <view v-for="(scan, index) in scanArray" :key="index">
           <view
             style="
               display: flex;
               font-size: 15px;
-              height: 25px;
-              line-height: 25px;
+              height: 50px;
+              line-height: 50px;
             "
           >
             <view style="margin-right: 15px">
@@ -40,22 +38,23 @@
             </view>
             <view>{{ scan.planName }} </view>
             <view style="margin: auto"></view>
-            <view>
-              <el-button
+            <view style="margin: auto 0">
+              <u-button
                 type="primary"
-                round
+                shape="circle"
                 style="height: 25px; font-size: 13px"
                 @click="reportClick(scan.siteId, scan.id)"
               >
                 上报
-              </el-button>
+              </u-button>
             </view>
           </view>
-          <el-divider style="margin: 15px 0" />
+
+          <view style="border-bottom: 1.5px #dad7d7 solid"></view>
         </view>
       </scroll-view>
     </template>
-  </el-drawer>
+  </u-popup>
 </template>
 
 <script setup>

+ 192 - 95
src/pages/xunJian/plan/components/report.vue

@@ -1,95 +1,103 @@
 <template>
-  <scroll-view scroll-y>
-    <view class="grayBackgroundColor">
-      <view
-        class="whiteBackgroundColor"
-        style="display: flex; padding: 15px 0px 15px 15px; margin-bottom: 15px"
-        v-for="cu in currentDateList"
-        :key="cu"
-      >
-        <view class="reportLeft" @click="pulicClick(cu)">
-          <img
-            src="@/static/inspection/scan.png"
-            alt=""
-            v-if="cu.siteType == 1"
-          />
-          <img
-            src="@/static/inspection/NFC.png"
-            alt=""
-            v-if="cu.siteType == 2"
-          />
-        </view>
-        <view class="reportCenter" @click="pulicClick(cu)">
-          <view class="centerSiteName">
-            {{ cu.siteName }}
-            <view
-              :style="{
-                margin: 'auto auto auto 15px',
-                fontSize: '5px',
-                backgroundColor:
-                  cu.inspectionStatus == 1 ? '#ffbebb' : '#ABE399',
-                color: cu.inspectionStatus == 1 ? '#FF3128' : '#189400',
-                borderRadius: '10px',
-                padding: '0px 5px',
-              }"
-            >
-              {{ cu.inspectionStatus == 1 ? "未巡检" : "已巡检" }}
-            </view>
-
-            <!-- "inspectionStatus": 2 //巡检状态(1 未巡检,2 已巡检) -->
-          </view>
-          <view style="font-size: 13px; color: #a1a1a1; margin-bottom: 5px">
-            描述:{{
-              cu.siteDescribe == "" || cu.siteDescribe == null
-                ? "无"
-                : cu.siteDescribe
-            }}
-          </view>
-          <view style="font-size: 13px; color: #a1a1a1">
-            完成时间:
-            {{
-              cu.inspectionTime == "" || cu.inspectionTime == null
-                ? "无"
-                : cu.inspectionTime
-            }}
-          </view>
-        </view>
-        <view style="margin: auto" @click="pulicClick(cu)"></view>
-        <view class="reportRight">
-          <view
-            class="rightChild"
-            :style="{
-              color:
-                cu.siteStatus == null || cu.siteStatus == 0
-                  ? '#a0a0a0'
-                  : '#1989fa',
-            }"
-          >
-            <el-icon><MapLocation /></el-icon>
-            <view>定位</view>
-          </view>
+  <scroll-view scroll-y class="grayBackgroundColor">
+    <view
+      class="whiteBackgroundColor"
+      style="display: flex; padding: 15px 0px 15px 15px; margin-bottom: 15px"
+      v-for="cu in currentDateList"
+      :key="cu"
+    >
+      <view class="reportLeft" @click="pulicClick(cu)">
+        <u-image
+          style="margin: auto"
+          width="40"
+          height="40"
+          src="@/static/inspection/scan.png"
+          v-if="cu.siteType == 1"
+          shape="circle"
+        ></u-image>
+
+        <u-image
+          style="margin: auto"
+          width="40"
+          height="40"
+          src="@/static/inspection/NFC.png"
+          v-if="cu.siteType == 2"
+          shape="circle"
+        ></u-image>
+      </view>
+      <view class="reportCenter" @click="pulicClick(cu)">
+        <view class="centerSiteName">
+          {{ cu.siteName }}
           <view
-            class="rightChild"
             :style="{
-              color:
-                cu.siteStatus == null || cu.siteStatus == 0
-                  ? '#a0a0a0'
-                  : '#1989fa',
+              margin: 'auto auto auto 15px',
+              fontSize: '5px',
+              backgroundColor: cu.inspectionStatus == 1 ? '#ffbebb' : '#ABE399',
+              color: cu.inspectionStatus == 1 ? '#FF3128' : '#189400',
+              borderRadius: '10px',
+              padding: '0px 5px',
             }"
           >
-            <el-icon><Calendar /></el-icon>
-            <view>状态</view>
+            {{ cu.inspectionStatus == 1 ? "未巡检" : "已巡检" }}
           </view>
+
+          <!-- "inspectionStatus": 2 //巡检状态(1 未巡检,2 已巡检) -->
+        </view>
+        <view style="font-size: 13px; color: #a1a1a1; margin-bottom: 5px">
+          描述:{{
+            cu.siteDescribe == "" || cu.siteDescribe == null
+              ? "无"
+              : cu.siteDescribe
+          }}
+        </view>
+        <view style="font-size: 13px; color: #a1a1a1">
+          完成时间:
+          {{
+            cu.inspectionTime == "" || cu.inspectionTime == null
+              ? "无"
+              : cu.inspectionTime
+          }}
+        </view>
+      </view>
+      <view style="margin: auto" @click="pulicClick(cu)"></view>
+      <view class="reportRight">
+        <view
+          class="rightChild"
+          :style="{
+            color:
+              cu.siteStatus == null || cu.siteStatus == 0
+                ? '#a0a0a0'
+                : '#1989fa',
+          }"
+        >
+          <text class="iconfont ucicon-map" style="font-size: 22px"></text>
+          <view>定位</view>
+        </view>
+        <view
+          class="rightChild"
+          :style="{
+            color:
+              cu.siteStatus == null || cu.siteStatus == 0
+                ? '#a0a0a0'
+                : '#1989fa',
+          }"
+        >
+          <text class="iconfont ucicon-appstore" style="font-size: 22px"></text>
+
+          <view>状态</view>
         </view>
       </view>
     </view>
 
-    <img
-      src="@/static/inspection/plan-scan.png"
-      alt=""
-      style="position: fixed; right: 0; bottom: 50px"
-      @click="scanClick()"
-    />
+    <view style="position: fixed; right: 0; bottom: 50px">
+      <u-image
+        width="67"
+        height="67"
+        src="@/static/inspection/plan-scan.png"
+        shape="circle"
+        @click="scanClick()"
+      ></u-image>
+    </view>
   </scroll-view>
 </template>
 
@@ -101,8 +109,55 @@ const myRequest = inject("$myRequest");
 import useXunJianStore from "@/store/modules/xunJian";
 const settingsStore = useXunJianStore(); //全局变量值Store
 
-function pulicClick(obj) {
-  console.log(obj);
+async function pulicClick(obj) {
+  if (obj.inspectionStatus == 2) {
+    const res = await myRequest({
+      url: "/service-fire/appPatrolInspection/recordList",
+      header: {
+        "Content-Type": "application/json;charset=utf-8",
+      },
+      method: "GET",
+      data: {
+        siteId: obj.id,
+        planSonId: settingsStore.planSonId,
+      },
+    });
+
+    if (res.data.status == "SUCCESS") {
+      if (res.data.data.length > 0) {
+        const res1 = await myRequest({
+          url: "/service-fire/appPatrolInspection/recordOption",
+          header: {
+            "Content-Type": "application/json;charset=utf-8",
+          },
+          method: "GET",
+          data: {
+            siteId: res.data.data[0].siteId,
+            recordId: res.data.data[0].id,
+          },
+        });
+
+        res.data.data[0].inspectionStatus = 2;
+        res.data.data[0].pictureUrl = obj.pictureUrl;
+
+        settingsStore.contentArray = {
+          contentList: [res1.data.data.contentList],
+          siteList: res.data.data[0],
+        };
+        settingsStore.siteId = undefined;
+        settingsStore.siteNubmber = undefined;
+      }
+    } else {
+    }
+  } else {
+    settingsStore.contentArray = {};
+    settingsStore.siteId = obj.id;
+    settingsStore.siteNubmber = undefined;
+  }
+
+  uni.navigateTo({
+    url: "/pages/xunJian/plan/components/siteDetails",
+  });
 }
 
 /**
@@ -112,13 +167,51 @@ function pulicClick(obj) {
 const scanArray = ref([]);
 const scanBool = ref(false);
 async function scanClick() {
-  settingsStore.contentArray = {};
-  settingsStore.siteNubmber = "0000000000";
-  settingsStore.siteId = undefined;
-  settingsStore.planSonId = undefined;
+  uni.scanCode({
+    success: async (e) => {
+      uni.showToast({
+        title: "扫码成功",
+        icon: "none",
+      });
 
-  uni.navigateTo({
-    url: "/pages/xunJian/plan/components/siteDetails",
+      settingsStore.contentArray = {};
+      settingsStore.siteId = undefined;
+      settingsStore.siteNubmber = e.result;
+
+      let res = await myRequest({
+        url: "/service-fire/appPatrolInspection/siteDetails",
+        header: {
+          "Content-Type": "application/json;charset=utf-8",
+        },
+        method: "GET",
+        data: {
+          siteId: settingsStore.siteId,
+          siteNubmber: settingsStore.siteNubmber,
+          planSonId: settingsStore.planSonId,
+        },
+      });
+
+      if (res.data.status == "SUCCESS") {
+        currentDateList.value.forEach((e) => {
+          if (e.id == res.data.data.siteList[0].id) {
+            uni.navigateTo({
+              url: "/pages/xunJian/plan/components/siteDetails",
+            });
+          }
+        });
+      } else {
+      }
+    },
+    fail: (err) => {
+      uni.showToast({
+        title: "扫码失败",
+        icon: "none",
+      });
+      console.log("扫码失败", err);
+    },
+    complete: () => {
+      console.log("扫码结束");
+    },
   });
 }
 
@@ -126,7 +219,7 @@ async function scanClick() {
  * @地点列表
  * @api接口请求
  */
-const currentDateList = ref({}); //地点列表list数据存储
+const currentDateList = ref([]); //地点列表list数据存储
 async function currentApi() {
   const res = await myRequest({
     url: "/service-fire/appPatrolInspection/planSonSiteDetails",
@@ -135,12 +228,18 @@ async function currentApi() {
     },
     method: "GET",
     data: {
-      planSonId: settingsStore.planSonId1,
+      planSonId: settingsStore.planSonId,
     },
   });
 
   if (res.data.status == "SUCCESS") {
     currentDateList.value = res.data.data;
+
+    currentDateList.value.forEach((e) => {
+      if (e.inspectionTime) {
+        e.inspectionTime = e.inspectionTime.replace("T", " ");
+      }
+    });
   } else {
   }
 }
@@ -159,6 +258,7 @@ onMounted(() => {});
 </style>
 
 <style scoped>
+body,
 uni-page-body,
 uni-page-refresh,
 .grayBackgroundColor {
@@ -172,9 +272,6 @@ uni-page-refresh,
   margin-right: 15px;
   display: flex;
 }
-.reportLeft img {
-  margin: auto;
-}
 
 .reportCenter {
 }

+ 113 - 96
src/pages/xunJian/plan/components/siteDetails.vue

@@ -6,18 +6,23 @@
         style="display: flex; padding: 15px; margin-bottom: 15px"
       >
         <view style="margin-right: 15px; display: flex">
-          <img
+          <u-image
             style="margin: auto"
+            width="40"
+            height="40"
             src="@/static/inspection/scan.png"
-            alt=""
             v-if="siteList.siteType == 1"
-          />
-          <img
+            shape="circle"
+          ></u-image>
+
+          <u-image
             style="margin: auto"
+            width="40"
+            height="40"
             src="@/static/inspection/NFC.png"
-            alt=""
             v-if="siteList.siteType == 2"
-          />
+            shape="circle"
+          ></u-image>
         </view>
         <view>
           <view style="font-size: 15px; margin-bottom: 2px">
@@ -29,6 +34,7 @@
         </view>
         <view style="margin: auto"></view>
         <view style="margin: auto 0">
+          <!-- {{ siteList.siteStatus == null }} -->
           <view style="font-size: 15px; color: #30bb00">已定位</view>
           <!-- #f07d28 -->
         </view>
@@ -39,8 +45,7 @@
         style="margin-bottom: 15px; padding: 15px"
       >
         <view class="siteHeader">
-          <view class="siteHeader-titleIcon" style="margin-right: 10px"> </view>
-          <view class="siteHeader-title"> 上报现场 </view>
+          <uni-section title="上报现场" type="line"></uni-section>
         </view>
         <view style="display: flex; flex-wrap: wrap">
           <view
@@ -48,20 +53,36 @@
             v-for="record in siteList.recordPictureList"
             :key="record"
           >
-            <img :src="record.url" alt="" />
-            <view class="uploadViewClose" @click="uploadViewClose(record)">
-              <el-icon><Close /></el-icon
-            ></view>
+            <view class="uploadUimage">
+              <u-image
+                width="100%"
+                height="100%"
+                :src="record.pictureUrl"
+              ></u-image>
+            </view>
+
+            <view
+              v-if="siteList.inspectionStatus == 1"
+              class="uploadViewClose"
+              @click="uploadViewClose(record)"
+            >
+              <u-icon name="close" color="#ffffff" size="12"></u-icon>
+            </view>
           </view>
           <view
             :class="
-              settingsStore.inspectionStatus == 2
+              siteList.inspectionStatus == 2
                 ? 'uploadView upload-buttom uploadDisabled'
                 : 'uploadView upload-buttom'
             "
             @click="uploadClick"
           >
-            <el-icon style="margin: auto"><Plus /></el-icon>
+            <u-icon
+              style="margin: auto"
+              name="plus"
+              color="#909399"
+              size="28"
+            ></u-icon>
           </view>
         </view>
       </view>
@@ -76,32 +97,29 @@
         "
       >
         <view class="siteHeader">
-          <view class="siteHeader-titleIcon" style="margin-right: 10px"> </view>
-          <view class="siteHeader-title"> 备注 </view>
+          <uni-section title="备注" type="line"></uni-section>
         </view>
-        <view>
-          <span v-if="settingsStore.inspectionStatus == 2">
+        <view style="height: calc(100% - 25px)">
+          <span v-if="siteList.inspectionStatus == 2">
             {{ siteList.remarks }}
           </span>
-          <el-input
-            v-if="settingsStore.inspectionStatus == 1"
+
+          <u-textarea
+            v-if="siteList.inspectionStatus == 1"
+            style="height: 100%"
             v-model="siteList.remarks"
-            :rows="5"
-            resize="none"
-            type="textarea"
-            maxlength="30"
             placeholder="请输入备注"
-          />
+            maxlength="50"
+          ></u-textarea>
         </view>
       </view>
 
       <view class="whiteBackgroundColor" style="padding: 15px">
         <view class="siteHeader">
-          <view class="siteHeader-titleIcon" style="margin-right: 10px"> </view>
-          <view class="siteHeader-title"> 消防紧急疏散图 </view>
+          <uni-section title="消防设施分布图" type="line"></uni-section>
         </view>
         <view>
-          <img style="width: 100%" :src="siteList.pictureUrl" alt="" />
+          <u-image width="100%" :src="siteList.pictureUrl"></u-image>
         </view>
       </view>
 
@@ -109,24 +127,25 @@
     </view>
     <view style="position: fixed; left: 0; right: 0; bottom: 0; padding: 15px">
       <view>
-        <el-button
-          v-if="settingsStore.inspectionStatus == 1"
+        <u-button
+          v-if="siteList.inspectionStatus == 1"
           type="primary"
-          round
           style="width: 100%; height: 40px; font-size: 14px"
           @click="buttonClick()"
+          shape="circle"
         >
           下一步
-        </el-button>
-        <el-button
-          v-if="settingsStore.inspectionStatus == 2"
+        </u-button>
+
+        <u-button
+          v-if="siteList.inspectionStatus == 2"
           type="primary"
-          round
           style="width: 100%; height: 40px; font-size: 14px"
           @click="buttonClick()"
+          shape="circle"
         >
           查看巡检项
-        </el-button>
+        </u-button>
       </view>
     </view>
   </scroll-view>
@@ -134,14 +153,48 @@
 
 <script setup>
 import { onLoad, onShow } from "@dcloudio/uni-app";
-import { ref, onMounted, inject, shallowRef } from "vue";
+import { ref, onMounted, inject, shallowRef, reactive } from "vue";
 const myRequest = inject("$myRequest");
 const sendUploadFile = inject("$sendUploadFile");
 
 import useXunJianStore from "@/store/modules/xunJian";
 const settingsStore = useXunJianStore(); //全局变量值Store
 
-const textarea = ref("");
+/**
+ * @站点详情
+ * @api接口查询
+ * @siteList站点详情信息存储
+ * @contentList内容详情信息存储
+ */
+const siteList = ref([]);
+const contentList = ref([]);
+async function selectAPI() {
+  let res = await myRequest({
+    url: "/service-fire/appPatrolInspection/siteDetails",
+    header: {
+      "Content-Type": "application/json;charset=utf-8",
+    },
+    method: "GET",
+    data: {
+      siteId: settingsStore.siteId,
+      siteNubmber: settingsStore.siteNubmber,
+      planSonId: settingsStore.planSonId,
+    },
+  });
+
+  if (res.data.status == "SUCCESS") {
+    contentList.value = res.data.data.contentList;
+    siteList.value = res.data.data.siteList[0];
+    siteList.value.recordPictureList = [];
+
+    contentList.value.forEach((el) => {
+      el.remarksBool = false;
+      el.contentOptionListValue = "";
+      el.contentOptionListValue1 = [];
+    });
+  } else {
+  }
+}
 
 /**
  * @按钮点击事件
@@ -150,10 +203,9 @@ const textarea = ref("");
  */
 function buttonClick() {
   settingsStore.contentArray = {
-    contentList: [contentList.value],
+    contentList: contentList.value,
     siteList: siteList.value,
   };
-
   uni.navigateTo({
     url: "/pages/xunJian/plan/components/content",
   });
@@ -182,12 +234,14 @@ async function uploadApi(res) {
   let list = await sendUploadFile({
     url: "/service-file/upload",
     method: "POST",
-    data: {
-      file: res.tempFiles[0],
-    },
+    filePath: res.tempFilePaths[0],
+    file: res.tempFiles[0],
   });
 
-  siteList.value.recordPictureList.push(list.data);
+  siteList.value.recordPictureList.push({
+    name: list.data.name,
+    pictureUrl: list.data.url,
+  });
 }
 
 /**
@@ -202,42 +256,6 @@ function uploadViewClose(el) {
   );
 }
 
-/**
- * @站点详情
- * @api接口查询
- * @siteList站点详情信息存储
- * @contentList内容详情信息存储
- */
-const siteList = ref([]);
-const contentList = ref([]);
-async function selectAPI() {
-  let res = await myRequest({
-    url: "/service-fire/appPatrolInspection/siteDetails",
-    header: {
-      "Content-Type": "application/json;charset=utf-8",
-    },
-    method: "GET",
-    data: {
-      siteId: settingsStore.siteId,
-      siteNubmber: settingsStore.siteNubmber,
-      planSonId: settingsStore.planSonId,
-    },
-  });
-
-  if (res.data.status == "SUCCESS") {
-    contentList.value = res.data.data.contentList[0];
-    siteList.value = res.data.data.siteList[0];
-    siteList.value.recordPictureList = [];
-
-    [contentList.value].forEach((el) => {
-      el.remarksBool = false;
-      el.contentOptionListValue = "";
-      el.contentOptionListValue1 = [];
-    });
-  } else {
-  }
-}
-
 onLoad((options) => {
   if (JSON.stringify(settingsStore.contentArray) == "{}") {
     selectAPI();
@@ -264,21 +282,10 @@ uni-page-refresh,
 
 .siteHeader {
   display: flex;
-  height: 15px;
-  line-height: 15px;
+  height: 20px;
+  line-height: 20px;
   margin-bottom: 10px;
 }
-
-.siteHeader-titleIcon {
-  width: 2px;
-  background-color: #149eff;
-}
-
-.siteHeader-title {
-  font-size: 15px;
-  color: #149eff;
-  font-weight: 600;
-}
 </style>
 
 <!--自定义图片上传功能样式-->
@@ -294,6 +301,14 @@ uni-page-refresh,
   cursor: pointer;
 }
 
+.uploadView .uploadUimage {
+  height: 100%;
+}
+
+.uploadView .uploadUimage > uni-view {
+  height: 100%;
+}
+
 .uploadViewClose {
   position: absolute;
   background-color: #409eff;
@@ -306,9 +321,11 @@ uni-page-refresh,
   cursor: pointer;
 }
 
+.uploadViewClose .u-icon,
 .uploadViewClose .el-icon {
   font-size: 12px;
-  margin-top: 11px;
+  margin-top: 4px;
+  margin-left: 10px;
   transform: rotate(-45deg);
   color: #ffffff;
 }
@@ -333,7 +350,7 @@ uni-page-refresh,
   border: 1px dashed #409eff;
 }
 
-::v-deep .uploadDisabled .upload-buttom {
-  display: none;
+::v-deep .uploadDisabled {
+  display: none !important;
 }
 </style>

+ 244 - 149
src/pages/xunJian/plan/index.vue

@@ -1,5 +1,5 @@
 <template>
-  <scroll-view scroll-y>
+  <scroll-view scroll-y class="grayBackgroundColor">
     <view class="grayBackgroundColor">
       <view>
         <el-calendar
@@ -44,46 +44,65 @@
         </el-calendar>
       </view>
       <view>
-        <view class="padding-sm" style="display: flex; margin: 10px">
-          <el-radio-group
-            v-model="tabPosition"
-            style="margin: auto"
-            @change="tabPositionChange()"
-          >
-            <el-radio-button label="task">巡检任务</el-radio-button>
-            <el-radio-button label="record">巡检记录</el-radio-button>
-          </el-radio-group>
+        <view
+          class="padding-sm"
+          style="display: flex; margin: 10px; padding: 10px 5rem"
+        >
+          <u-subsection
+            :list="list"
+            :current="tabPosition"
+            inactiveColor="#303133"
+            activeColor="#3c9cff"
+            @change="tabPositionChange"
+          ></u-subsection>
         </view>
         <view>
-          <el-timeline id="planTimeline" v-if="activities.length > 0">
-            <view>
-              <el-button
-                type="primary"
-                style="margin: 0px -7.5px"
-                link
-                @click="activitiesSortClick()"
-              >
-                排序
-              </el-button>
+          <view id="planTimeline1" v-if="activities.length > 0">
+            <view
+              style="margin: 0px -3.5px; font-size: 13px; color: #409eff"
+              @click="activitiesSortClick()"
+            >
+              排序
             </view>
-            <view v-if="tabPosition == 'task'">
-              <el-timeline-item
-                v-for="(activity, index) in activities"
-                :key="index"
-                :icon="activity.icon"
-                :type="activity.type"
-                :color="activity.color"
-                :size="activity.size"
-                :hollow="activity.hollow"
-              >
-                <view style="display: flex">
-                  <view style="font-size: 15px"> {{ activity.planName }}</view>
+            <view
+              v-for="(activity, index) in activities"
+              :key="index"
+              v-show="tabPosition == 0"
+            >
+              <view style="display: flex; height: 25px; line-height: 25px">
+                <view style="margin: auto 0">
+                  <u-icon
+                    name="info-circle-fill"
+                    color="#409eff"
+                    size="18"
+                  ></u-icon>
+                </view>
+                <view style="display: flex; width: 100%; margin-left: 15px">
+                  <view style="font-size: 15px; color: #000000">
+                    {{ activity.planName }}
+                  </view>
                   <view style="margin: auto"> </view>
-                  <view style="color: #b5b5b5"> {{ activity.timestamp }}</view>
+                  <view style="font-size: 14px; color: #b5b5b5">
+                    {{ activity.timestamp }}
+                  </view>
+                </view>
+              </view>
+
+              <view style="display: flex">
+                <view style="width: 18px; display: flex">
+                  <viwe
+                    v-if="index != activities.length - 1"
+                    style="
+                      width: 2px;
+                      background-color: #e4e7ed;
+                      margin: -5px auto;
+                    "
+                  ></viwe>
                 </view>
                 <view
                   style="
-                    margin-top: 15px;
+                    width: 100%;
+                    margin: 15px 0px 15px 15px;
                     padding: 15px;
                     background-color: #fff;
                     border-radius: 10px;
@@ -93,20 +112,17 @@
                     <view>
                       <view>巡检任务结束</view>
                       <br />
-                      <view>
-                        <el-button
-                          type="primary"
-                          link
-                          style="padding: 0"
-                          @click="reportClick(activity.id)"
-                        >
-                          点击查看
-                        </el-button>
+                      <view
+                        style="padding: 0; font-size: 14px; color: #409eff"
+                        @click="reportClick(activity)"
+                      >
+                        点击查看
                       </view>
                     </view>
                     <view style="margin: auto"></view>
-                    <view>
+                    <view style="display: flex">
                       <el-progress
+                        style="margin: auto"
                         type="circle"
                         :percentage="activity.completion"
                         :width="50"
@@ -120,20 +136,17 @@
                         {{ activity.undetectedSiteCount }}个
                       </view>
                       <br />
-                      <view>
-                        <el-button
-                          type="primary"
-                          link
-                          style="padding: 0"
-                          @click="reportClick(activity.id)"
-                        >
-                          点击巡检
-                        </el-button>
+                      <view
+                        @click="reportClick(activity)"
+                        style="padding: 0; font-size: 14px; color: #409eff"
+                      >
+                        点击巡检
                       </view>
                     </view>
                     <view style="margin: auto"></view>
-                    <view>
+                    <view style="display: flex">
                       <el-progress
+                        style="margin: auto"
                         type="circle"
                         :percentage="activity.completion"
                         :width="50"
@@ -160,8 +173,9 @@
                       </view>
                     </view>
                     <view style="margin: auto"></view>
-                    <view>
+                    <view style="display: flex">
                       <el-progress
+                        style="margin: auto"
                         type="circle"
                         :percentage="activity.completion"
                         :width="50"
@@ -169,61 +183,78 @@
                     </view>
                   </view>
                 </view>
-              </el-timeline-item>
+              </view>
             </view>
 
-            <view v-if="tabPosition == 'record'">
-              <el-timeline-item
-                v-for="(activity, index) in activities"
-                :key="index"
-                :icon="activity.icon"
-                :type="activity.type"
-                :color="activity.color"
-                :size="activity.size"
-                :hollow="activity.hollow"
-              >
-                <view style="display: flex">
-                  <view style="font-size: 15px"> {{ activity.siteName }}</view>
+            <view
+              v-for="(activity, index) in activities"
+              :key="index"
+              v-show="tabPosition == 1"
+            >
+              <view style="display: flex; height: 25px; line-height: 25px">
+                <view style="margin: auto 0">
+                  <u-icon
+                    name="info-circle-fill"
+                    color="#409eff"
+                    size="18"
+                  ></u-icon>
+                </view>
+                <view style="display: flex; width: 100%; margin-left: 15px">
+                  <view style="font-size: 15px; color: #000000">
+                    {{ activity.areaName }}
+                  </view>
                   <view style="margin: auto"> </view>
-                  <view style="color: #b5b5b5"> {{ activity.createTime }}</view>
+                  <view style="font-size: 14px; color: #b5b5b5">
+                    {{ activity.createTime }}
+                  </view>
+                </view>
+              </view>
+
+              <view style="display: flex">
+                <view style="width: 18px; display: flex">
+                  <viwe
+                    v-if="index != activities.length - 1"
+                    style="
+                      width: 2px;
+                      background-color: #e4e7ed;
+                      margin: -5px auto;
+                    "
+                  ></viwe>
                 </view>
                 <view
                   style="
-                    margin-top: 15px;
+                    width: 100%;
+                    margin: 15px 0px 15px 15px;
                     padding: 15px;
                     background-color: #fff;
                     border-radius: 10px;
                   "
                 >
-                  <view>已检查{{ activity.contentCount }}项内容</view>
-                  <view
-                    :style="{
-                      color:
-                        activity.siteStatus == 0
-                          ? '#f07d28'
-                          : activity.siteStatus == 1
-                          ? '#00cdac'
-                          : '',
-                      textAlign: 'right',
-                    }"
-                  >
-                    {{
-                      activity.siteStatus == 0
-                        ? "未定位"
-                        : activity.siteStatus == 1
-                        ? "已定位"
-                        : ""
-                    }}
-                  </view>
-                  <view>
-                    <el-button type="primary" link style="padding: 0">
-                      点击查看
-                    </el-button>
+                  <view style="display: flex">
+                    <view>
+                      <view>已检查{{ activity.contentCount }}项内容</view>
+                      <br />
+                      <view
+                        style="padding: 0; font-size: 14px; color: #409eff"
+                        @click="reportClick(activity)"
+                      >
+                        点击查看
+                      </view>
+                    </view>
+                    <view style="margin: auto"></view>
+                    <view
+                      style="display: flex; font-size: 15px; color: #30bb00"
+                    >
+                      <view style="margin: auto">
+                        {{ activity.siteStatus == 0 ? "未定位" : "已定位" }}
+                      </view>
+                    </view>
                   </view>
                 </view>
-              </el-timeline-item>
+              </view>
             </view>
-          </el-timeline>
+          </view>
+
           <view
             id="planTimeline"
             style="text-align: center; color: #bdbdbd; font-size: 14px"
@@ -235,12 +266,16 @@
       </view>
     </view>
 
-    <img
-      src="@/static/inspection/plan-scan.png"
-      alt=""
-      style="position: fixed; right: 0; bottom: 50px"
-      @click="scanClick()"
-    />
+    <view style="position: fixed; right: 0; bottom: 50px">
+      <u-image
+        width="67"
+        height="67"
+        src="@/static/inspection/plan-scan.png"
+        shape="circle"
+        @click="scanClick()"
+      ></u-image>
+    </view>
+
     <drawer
       v-if="scanArray.length > 0"
       :scanArray="scanArray"
@@ -253,20 +288,67 @@
 <script setup>
 import drawer from "./components/drawer.vue";
 
-import { onLoad, onShow } from "@dcloudio/uni-app";
+import { onLoad, onShow, onLaunch } from "@dcloudio/uni-app";
 import { ref, onMounted, inject, shallowRef } from "vue";
 const myRequest = inject("$myRequest");
 
 import useXunJianStore from "@/store/modules/xunJian";
 const settingsStore = useXunJianStore(); //全局变量值Store
 
-import { MoreFilled } from "@element-plus/icons-vue";
+/**
+ * @点击巡检
+ * @点击事件
+ */
+async function reportClick(obj) {
+  if (tabPosition.value == 0) {
+    settingsStore.planSonId = obj.id;
+    uni.navigateTo({
+      url: "/pages/xunJian/plan/components/report",
+    });
+  } else if (tabPosition.value == 1) {
+    const res = await myRequest({
+      url: "/service-fire/appPatrolInspection/recordList",
+      header: {
+        "Content-Type": "application/json;charset=utf-8",
+      },
+      method: "GET",
+      data: {
+        siteId: obj.id,
+        planSonId: obj.planSonId,
+      },
+    });
 
-function reportClick(id) {
-  settingsStore.planSonId1 = id;
-  uni.navigateTo({
-    url: "/pages/xunJian/plan/components/report",
-  });
+    if (res.data.status == "SUCCESS") {
+      if (res.data.data.length > 0) {
+        const res1 = await myRequest({
+          url: "/service-fire/appPatrolInspection/recordOption",
+          header: {
+            "Content-Type": "application/json;charset=utf-8",
+          },
+          method: "GET",
+          data: {
+            siteId: res.data.data[0].siteId,
+            recordId: res.data.data[0].id,
+          },
+        });
+
+        res.data.data[0].inspectionStatus = 2;
+        res.data.data[0].pictureUrl = obj.pictureUrl;
+
+        settingsStore.contentArray = {
+          contentList: [res1.data.data.contentList],
+          siteList: res.data.data[0],
+        };
+        settingsStore.siteId = undefined;
+        settingsStore.siteNubmber = undefined;
+
+        uni.navigateTo({
+          url: "/pages/xunJian/plan/components/siteDetails",
+        });
+      }
+    } else {
+    }
+  }
 }
 
 /**
@@ -275,43 +357,53 @@ function reportClick(id) {
  */
 const scanArray = ref([]);
 const scanBool = ref(false);
-async function scanClick() {
+function scanClick() {
   uni.scanCode({
-    success: (res) => {
-      console.log("扫码成功", res);
+    success: async (e) => {
+      uni.showToast({
+        title: "扫码成功",
+        icon: "none",
+      });
+      settingsStore.inspectionStatus = 1;
+      let res = await myRequest({
+        url: "/service-fire/appPatrolInspection/planList",
+        header: {
+          "Content-Type": "application/json;charset=utf-8",
+        },
+        method: "GET",
+        data: {
+          siteNubmber: e.result,
+        },
+      });
+
+      if (res.data.status == "SUCCESS") {
+        if (res.data.data.length > 0) {
+          scanArray.value = res.data.data;
+          scanBool.value = true;
+        } else {
+          uni.showToast({
+            title: "此点位下暂无数据,请切换点位重试!",
+            icon: "none",
+          });
+        }
+      } else {
+      }
     },
     fail: (err) => {
+      uni.showToast({
+        title: "扫码失败",
+        icon: "none",
+      });
       console.log("扫码失败", err);
     },
     complete: () => {
+      // uni.showToast({
+      //   title: "扫码结束",
+      //   icon: "none",
+      // });
       console.log("扫码结束");
     },
   });
-
-  settingsStore.inspectionStatus = 1;
-  let res = await myRequest({
-    url: "/service-fire/appPatrolInspection/planList",
-    header: {
-      "Content-Type": "application/json;charset=utf-8",
-    },
-    method: "GET",
-    data: {
-      siteNubmber: "0000000000",
-    },
-  });
-
-  if (res.data.status == "SUCCESS") {
-    if (res.data.data.length > 0) {
-      scanArray.value = res.data.data;
-      scanBool.value = true;
-    } else {
-      uni.showToast({
-        title: "此点位下暂无数据,请切换点位重试!",
-        icon: "none",
-      });
-    }
-  } else {
-  }
 }
 
 /**
@@ -330,7 +422,7 @@ function scanClose(flag) {
 const activities = ref([]);
 async function activitiesApi() {
   activities.value = [];
-  if (tabPosition.value == "task") {
+  if (tabPosition.value == 0) {
     let res = await myRequest({
       url: "/service-fire/appPatrolInspection/patrolInspectionPlan",
       header: {
@@ -367,7 +459,7 @@ async function activitiesApi() {
       });
     } else {
     }
-  } else if (tabPosition.value == "record") {
+  } else if (tabPosition.value == 1) {
     let res = await myRequest({
       url: "/service-fire/appPatrolInspection/recordList",
       header: {
@@ -383,22 +475,16 @@ async function activitiesApi() {
     if (res.data.status == "SUCCESS") {
       res.data.data.forEach((el) => {
         activities.value.push({
+          areaName: el.areaName,
           siteName: el.siteName,
           contentCount: el.contentCount,
-          createTime:
-            el.createTime.split("T")[0] + " " + el.createTime.split("T")[1],
+          createTime: el.createTime.replace("T", " "),
           siteStatus: el.siteStatus,
         });
       });
     } else {
     }
   }
-
-  activities.value.forEach((el) => {
-    el.size = "large";
-    el.type = "primary";
-    el.icon = shallowRef(MoreFilled);
-  });
 }
 
 /**
@@ -435,7 +521,7 @@ async function currentApi() {
 /**
  * @排序按钮
  */
-const activitiesSort = ref("ASC");
+const activitiesSort = ref("DESC");
 function activitiesSortClick() {
   if (activitiesSort.value == "ASC") {
     activitiesSort.value = "DESC";
@@ -448,8 +534,10 @@ function activitiesSortClick() {
 /**
  * @tabs切换change事件
  */
+const list = ref(["巡检任务", "巡检记录"]);
 const tabPosition = ref(settingsStore.planTabs);
-function tabPositionChange() {
+function tabPositionChange(index) {
+  tabPosition.value = index;
   activitiesApi();
 }
 
@@ -504,6 +592,12 @@ function touchEnd(e) {
 onLoad((options) => {
   currentApi();
   activitiesApi();
+
+  // 从详情页返回该页面的获取数据
+  uni.$on("planSelect", () => {
+    currentApi();
+    activitiesApi();
+  });
 });
 
 onMounted(() => {});
@@ -516,6 +610,7 @@ onMounted(() => {});
 </style>
 
 <style scoped>
+body,
 uni-page-body,
 uni-page-refresh,
 .grayBackgroundColor {

+ 90 - 70
src/pages/xunJian/record/record.vue

@@ -1,79 +1,99 @@
 <template>
-
-	<view class="">
-		<view class="cu-list menu-avatar">
-			<view class="cu-item"  :class="modalName=='move-box-'+ index?'move-cur':''" v-for="(item,index) in this.getData"
-			 :key="index" :data-target="'move-box-' + index" @tap="goDetail(item)">
-				<view class="content" style="left:0;width:80%">
-					<view class="pro-title">
-						<view class="cut">计划:{{item.plan_name}}</view>
-					</view>
-					<view class="pro-des  ">
-						<view class="text-cut">
-							点位:{{item.spot_name}}
-						</view>
-					</view>
-					<view class="pro-date ">{{item.wc_time}}</view>
-				</view>
-				<view class="nav-right num margin-right-sm">
-					<view class="text-grey">
-						<button class="cu-btn radius bg-green sm" v-if="item.spot_abnormal==0">正常</button>
-						<button class="cu-btn radius bg-orange sm" v-if="item.spot_abnormal==1">异常</button>
-						<button class="cu-btn radius bg-red sm" v-if="item.spot_abnormal==2">故障</button>
-						<button class="cu-btn radius bg-orange sm" v-if="item.spot_abnormal==3">其他</button>
-					</view>
-				</view>
-			</view>
-		</view>
-	</view>
+  <view class="">
+    <view class="cu-list menu-avatar">
+      <view
+        class="cu-item"
+        :class="modalName == 'move-box-' + index ? 'move-cur' : ''"
+        v-for="(item, index) in this.getData"
+        :key="index"
+        :data-target="'move-box-' + index"
+        @tap="goDetail(item)"
+      >
+        <view class="content" style="left: 0; width: 80%">
+          <view class="pro-title">
+            <view class="cut">计划:{{ item.plan_name }}</view>
+          </view>
+          <view class="pro-des">
+            <view class="text-cut"> 点位:{{ item.spot_name }} </view>
+          </view>
+          <view class="pro-date">{{ item.wc_time }}</view>
+        </view>
+        <view class="nav-right num margin-right-sm">
+          <view class="text-grey">
+            <button
+              class="cu-btn radius bg-green sm"
+              v-if="item.spot_abnormal == 0"
+            >
+              正常
+            </button>
+            <button
+              class="cu-btn radius bg-orange sm"
+              v-if="item.spot_abnormal == 1"
+            >
+              异常
+            </button>
+            <button
+              class="cu-btn radius bg-red sm"
+              v-if="item.spot_abnormal == 2"
+            >
+              故障
+            </button>
+            <button
+              class="cu-btn radius bg-orange sm"
+              v-if="item.spot_abnormal == 3"
+            >
+              其他
+            </button>
+          </view>
+        </view>
+      </view>
+    </view>
+  </view>
 </template>
 
 <script>
-	import json from '../../../data/json.js';
-	export default {
-		data() {
-			return {
-				modalName: null,
-				getData:[]
-			};
-		},
-		
-		onLoad:function(option){
-			this.goRecordList({'company_code':uni.getStorageSync('selectedCode')})
-		},
-		onNavigationBarButtonTap(e) {
-			console.log(e)
-			uni.navigateTo({
-				url: '/pages/export/export',
-	
-			});
-		},
-		methods: {
-			
-			// 巡检记录列表数据请求
-			async goRecordList(params = {}) {
-				const res = await this.$myRequest({
-					url: 'Inspection/getInspectionRecordList',
-					data:params,
-					showLoading: true
-				})
-				this.getData=res.data.data;
-				console.log(this.getData);
-			},
-		
-			// 页面跳转
-			goDetail(item) {
-				uni.navigateTo({
-					url: '/pages/xunJian/recordDetail/recordDetail?id='+item.id,
-				});
-			},
-		}
+import json from "../../../data/json.js";
+export default {
+  data() {
+    return {
+      modalName: null,
+      getData: [],
+    };
+  },
+
+  onLoad: function (option) {
+    this.goRecordList({ company_code: uni.getStorageSync("selectedCode") });
+  },
+  onNavigationBarButtonTap(e) {
+    console.log(e);
+    uni.navigateTo({
+      url: "/pages/export/export",
+    });
+  },
+  methods: {
+    // 巡检记录列表数据请求
+    async goRecordList(params = {}) {
+      const res = await this.$myRequest({
+        url: "Inspection/getInspectionRecordList",
+        data: params,
+        showLoading: true,
+      });
+      this.getData = res.data.data;
+      console.log(this.getData);
+    },
 
-	}
+    // 页面跳转
+    goDetail(item) {
+      uni.navigateTo({
+        url: "/pages/xunJian/record/recordDetail/index?id=" + item.id,
+      });
+    },
+  },
+};
 </script>
 
 <style lang="scss">
-	.cu-item{
-		height:180rpx!important
-	}
+.cu-item {
+  height: 180rpx !important;
+}
 </style>

+ 159 - 0
src/pages/xunJian/record/recordDetail/index.vue

@@ -0,0 +1,159 @@
+<template>
+  <view>
+    <view class="timeBox flex justify-between align-center padding-lr-sm">
+      <view class="time">{{ this.getData.plan_name }}</view>
+      <button
+        class="cu-btn radius bg-green sm"
+        v-if="this.getData.spot_abnormal == 0"
+      >
+        正常
+      </button>
+      <button
+        class="cu-btn radius bg-orange sm"
+        v-if="this.getData.spot_abnormal == 1"
+      >
+        异常
+      </button>
+      <button
+        class="cu-btn radius bg-red sm"
+        v-if="this.getData.spot_abnormal == 2"
+      >
+        故障
+      </button>
+      <button
+        class="cu-btn radius bg-red sm"
+        v-if="this.getData.spot_abnormal == 3"
+      >
+        其他
+      </button>
+    </view>
+
+    <view>
+      <view class="basic-info">
+        <view class="info-tit margin-left-xs">
+          <text class="cuIcon-titles margin-right-xs"></text>
+          基本信息
+        </view>
+        <view class="info-content">
+          <view class="info-one-info">
+            <text>所属单位:</text>
+            <text>{{ this.getData.owner_name }}</text>
+          </view>
+
+          <view class="info-one-info">
+            <text>单位地址:</text>
+            <text>{{ this.getData.owner_address }}</text>
+          </view>
+          <view class="info-one-info">
+            <text>巡检点位:</text>
+            <text>{{ this.getData.spot_name }}</text>
+          </view>
+          <view class="info-one-info">
+            <text>点位地址:</text>
+            <text>{{ this.getData.spot_address }}</text>
+          </view>
+          <view class="info-one-info">
+            <text>预期时间:</text>
+            <text>{{ this.getData.ywc_time }}</text>
+          </view>
+          <view class="info-one-info">
+            <text>完成时间:</text>
+            <text>{{ this.getData.wc_time }}</text>
+          </view>
+        </view>
+      </view>
+
+      <!-- 巡检信息 -->
+      <view class="basic-info">
+        <view class="info-tit margin-left-xs">
+          <text class="cuIcon-titles margin-right-xs"></text>
+          巡检信息
+        </view>
+        <view class="info-content">
+          <view class="info-one-info">
+            <text>巡检人员:</text>
+            <text>{{ this.getData.name }}</text>
+          </view>
+
+          <view class="info-one-info">
+            <text>联系方式:</text>
+            <text>{{ this.getData.phone }}</text>
+          </view>
+          <view class="info-one-info">
+            <text>巡检描述:</text>
+            <text>{{ this.getData.dwsb_remarks }}</text>
+          </view>
+        </view>
+      </view>
+      <!-- 处理状态start -->
+      <view class="processStatus">
+        <view class="info-tit margin-left-xs">
+          <text class="cuIcon-titles margin-right-xs"></text>
+          巡检图片
+        </view>
+        <view class="padding-lr padding-bottom-lg imgPic">
+          <image
+            v-if="!this.getData.report_photos && this.dataRes == 1"
+            mode="widthFix"
+            src="@/static/images/defaultImg.jpg"
+            width="100%"
+          />
+          <image
+            v-else
+            mode="widthFix"
+            :src="`${this.$websiteUrl}${this.getData.report_photos}`"
+            width="100%"
+          />
+
+          <!-- <image class="image-bg"  v-if="!this.getData.report_photos&&this.dataRes==1"  src="@/static/images/defaultImg.jpg"/>
+						<image  class="image-bg" v-else :src="this.getData.report_photos" /> -->
+        </view>
+      </view>
+      <!-- 处理状态end -->
+    </view>
+  </view>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      radio: "A",
+      radio: "B",
+      modalName: null,
+      reason: "",
+      type: "0",
+      detailMessage: {},
+      detailMessage2: {},
+      msg: "",
+      msg2: "",
+      flag: false,
+      companyCode: 0,
+      getData: {},
+      dataRes: 0,
+    };
+  },
+  onLoad: function (option) {
+    this.goRecordDetail({
+      company_code: uni.getStorageSync("selectedCode"),
+      id: option.id,
+    });
+  },
+  methods: {
+    // 巡检记录列详情数据请求
+    async goRecordDetail(params = {}) {
+      const res = await this.$myRequest({
+        url: "Inspection/getInspectionRecordDetails",
+        data: params,
+        showLoading: true,
+      });
+      this.getData = res.data.data[0];
+      this.dataRes = 1;
+      console.log(this.getData);
+    },
+  },
+};
+</script>
+
+<style lang="scss">
+</style>

+ 10 - 8
src/pages/xunJian/xunJian.vue

@@ -1,5 +1,5 @@
 <template>
-  <scroll-view scroll-x>
+  <scroll-view scroll-x class="grayBackgroundColor">
     <view class="padding-sm">
       <!-- 图表 -->
       <view class="section1 section bg-white padding-xs">
@@ -75,15 +75,15 @@ const currentDateList = ref([]);
 
 function navItemClick(url, id) {
   if (url) {
-    uni.navigateTo({
-      url: url,
-    });
-
     if (id == 1) {
-      settingsStore.planTabs = "task";
+      settingsStore.planTabs = 0;
     } else if (id == 2) {
-      settingsStore.planTabs = "record";
+      settingsStore.planTabs = 1;
     }
+
+    uni.navigateTo({
+      url: url,
+    });
   } else {
     uni.showModal({
       title: "Tips",
@@ -129,8 +129,10 @@ onMounted(() => {
 </style>
 
 <style scoped>
+body,
 uni-page-body,
-uni-page-refresh {
+uni-page-refresh,
+.grayBackgroundColor {
   background: rgb(241, 241, 241);
 }
 </style>

BIN
src/static/alarming-kr.png


BIN
src/static/building1.png


BIN
src/static/building2.png


BIN
src/static/fail.png


+ 6 - 8
src/static/iconfont/iconfont.css

@@ -10,16 +10,14 @@
 
 
 @font-face {
-  font-family: 'iconfont';  /* Project id 2394829 */
+  font-family: 'iconfont';
+  /* Project id 2394829 */
   src: url('https://at.alicdn.com/t/font_2394829_ken0vmyss6a.woff2?t=1623131965202') format('woff2'),
-       url('https://at.alicdn.com/t/font_2394829_ken0vmyss6a.woff?t=1623131965202') format('woff'),
-       url('https://at.alicdn.com/t/font_2394829_ken0vmyss6a.ttf?t=1623131965202') format('truetype');
+    url('https://at.alicdn.com/t/font_2394829_ken0vmyss6a.woff?t=1623131965202') format('woff'),
+    url('https://at.alicdn.com/t/font_2394829_ken0vmyss6a.ttf?t=1623131965202') format('truetype'),
 }
 
 
-
-
-
 .iconfont {
   font-family: "iconfont" !important;
   font-size: 16px;
@@ -28,6 +26,7 @@
   -moz-osx-font-smoothing: grayscale;
 }
 
+
 .icon-xingzhuang8:before {
   content: "\e66b";
 }
@@ -82,5 +81,4 @@
 
 .icon-guanbi:before {
   content: "\e610";
-}
-
+}

+ 39 - 0
src/static/iconfont/uciconfont/iconfont.css

@@ -0,0 +1,39 @@
+@font-face {
+  font-family: "iconfont"; /* Project id 3620854 */
+  src: url('iconfont.woff2?t=1662690989920') format('woff2'),
+       url('iconfont.woff?t=1662690989920') format('woff'),
+       url('iconfont.ttf?t=1662690989920') format('truetype');
+}
+
+.iconfont {
+  font-family: "iconfont" !important;
+  font-size: 16px;
+  font-style: normal;
+  -webkit-font-smoothing: antialiased;
+  -moz-osx-font-smoothing: grayscale;
+}
+
+.ucicon-filter:before {
+  content: "\e7c7";
+}
+
+.ucicon-appstore:before {
+  content: "\e792";
+}
+
+.ucicon-map:before {
+  content: "\e719";
+}
+
+.ucicon-info-circle-fill:before {
+  content: "\e844";
+}
+
+.ucicon-eye:before {
+  content: "\e78f";
+}
+
+.ucicon-eye-close:before {
+  content: "\e8ff";
+}
+

BIN
src/static/iconfont/uciconfont/iconfont.ttf


BIN
src/static/iconfont/uciconfont/iconfont.woff


BIN
src/static/iconfont/uciconfont/iconfont.woff2