|
@@ -1,7 +1,7 @@
|
|
|
<template>
|
|
|
<scroll-view scroll-y>
|
|
|
- <view>
|
|
|
- <view class="whiteBackgroundColor" style="padding: 15px; margin-bottom: 15px" v-for="(con, index) in contentList" :key="index">
|
|
|
+ <view style="margin-bottom: 130px">
|
|
|
+ <view class="padding-15 margin-bottom-15 whiteBackgroundColor" v-for="(con, index) in contentList" :key="index">
|
|
|
<view class="siteHeader">
|
|
|
<uni-section :title="con.contentTitle" type="line"></uni-section>
|
|
|
|
|
@@ -10,7 +10,7 @@
|
|
|
<u-button v-if="con.remarksBool == false" type="primary" icon="list-dot" style="width: 18px; height: 18px; padding: 0; margin: 0" shape="circle" @click="remarksClick(index)"> </u-button>
|
|
|
</view>
|
|
|
<view>
|
|
|
- <view v-if="con.submissionMethod == 1" style="margin-top: 15px">
|
|
|
+ <view class="margin-top-15" v-if="con.submissionMethod == 1">
|
|
|
<u-checkbox-group
|
|
|
v-model="con.contentOptionListValue1"
|
|
|
@change="
|
|
@@ -18,10 +18,10 @@
|
|
|
checkboxChange(val, index);
|
|
|
}
|
|
|
"
|
|
|
- :disabled="xunjianStore.contentArray.siteList.inspectionStatus == 2"
|
|
|
+ :disabled="xunJianStore.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-col class="margin-bottom-15" v-for="option in con.contentOptionList" :key="option" span="6">
|
|
|
<u-checkbox :label="option.optionName" :name="option.id" :checked="con.contentOptionListValue1.length > 0 ? con.contentOptionListValue1.indexOf(option.id) >= 0 : false">
|
|
|
</u-checkbox>
|
|
|
</u-col>
|
|
@@ -29,53 +29,47 @@
|
|
|
</u-checkbox-group>
|
|
|
|
|
|
<view v-if="con.remarksBool == true" style="display: flex; height: 32px; line-height: 32px; white-space: nowrap">
|
|
|
- <span style="">备注:</span>
|
|
|
- <u-input v-model="con.remarks" placeholder="请输入备注" :disabled="xunjianStore.contentArray.siteList.inspectionStatus == 2"></u-input>
|
|
|
+ <span>备注:</span>
|
|
|
+ <u-input v-model="con.remarks" placeholder="请输入备注" :disabled="xunJianStore.contentArray.siteList.inspectionStatus == 2"></u-input>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view v-if="con.submissionMethod == 2" style="margin-top: 15px">
|
|
|
+ <view class="margin-top-15" v-if="con.submissionMethod == 2">
|
|
|
<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">
|
|
|
- <u-radio :disabled="xunjianStore.contentArray.siteList.inspectionStatus == 2" :label="option.optionName" :name="option.id"> </u-radio>
|
|
|
+ <u-col class="margin-bottom-15" v-for="option in con.contentOptionList" :key="option" :span="6">
|
|
|
+ <u-radio :disabled="xunJianStore.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; height: 32px; line-height: 32px; white-space: nowrap">
|
|
|
- <span style="">备注:</span>
|
|
|
- <u-input v-model="con.remarks" placeholder="请输入备注" :disabled="xunjianStore.contentArray.siteList.inspectionStatus == 2"></u-input>
|
|
|
+ <span>备注:</span>
|
|
|
+ <u-input v-model="con.remarks" placeholder="请输入备注" :disabled="xunJianStore.contentArray.siteList.inspectionStatus == 2"></u-input>
|
|
|
</view>
|
|
|
</view>
|
|
|
- <view v-if="con.submissionMethod == 3" style="margin-top: 15px">
|
|
|
- <u-textarea v-model="con.contentOptionListValue" placeholder="请输入" maxlength="30" :disabled="xunjianStore.contentArray.siteList.inspectionStatus == 2"></u-textarea>
|
|
|
+ <view class="margin-top-15" v-if="con.submissionMethod == 3">
|
|
|
+ <u-textarea
|
|
|
+ class="margin-bottom-15"
|
|
|
+ v-model="con.contentOptionListValue"
|
|
|
+ placeholder="请输入"
|
|
|
+ maxlength="30"
|
|
|
+ :disabled="xunJianStore.contentArray.siteList.inspectionStatus == 2"
|
|
|
+ ></u-textarea>
|
|
|
|
|
|
- <view v-if="con.remarksBool == true" style="display: flex; margin-top: 15px; height: 32px; line-height: 32px; white-space: nowrap">
|
|
|
- <span style="">备注:</span>
|
|
|
- <u-input v-model="con.remarks" placeholder="请输入备注" :disabled="xunjianStore.contentArray.siteList.inspectionStatus == 2"></u-input>
|
|
|
+ <view v-if="con.remarksBool == true" style="display: flex; height: 32px; line-height: 32px; white-space: nowrap">
|
|
|
+ <span>备注:</span>
|
|
|
+ <u-input v-model="con.remarks" placeholder="请输入备注" :disabled="xunJianStore.contentArray.siteList.inspectionStatus == 2"></u-input>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
|
-
|
|
|
- <view style="margin-bottom: 125px"></view>
|
|
|
</view>
|
|
|
- <view style="position: fixed; left: 0; right: 0; bottom: 0; padding: 15px">
|
|
|
+ <view class="app-position-fixed">
|
|
|
<view>
|
|
|
- <u-button
|
|
|
- v-if="xunjianStore.contentArray.siteList.inspectionStatus == 1"
|
|
|
- type="primary"
|
|
|
- style="width: 100%; height: 40px; font-size: 14px; margin-bottom: 15px"
|
|
|
- shape="circle"
|
|
|
- @click="buttonClick(1)"
|
|
|
- >
|
|
|
- 上一步
|
|
|
- </u-button>
|
|
|
+ <u-button class="app-buttom" v-if="xunJianStore.contentArray.siteList.inspectionStatus == 1" type="primary" shape="circle" @click="buttonClick(1)"> 上一步 </u-button>
|
|
|
</view>
|
|
|
<view>
|
|
|
- <u-button v-if="xunjianStore.contentArray.siteList.inspectionStatus == 1" type="primary" style="width: 100%; height: 40px; font-size: 14px" shape="circle" @click="buttonClick(2)">
|
|
|
- 提交
|
|
|
- </u-button>
|
|
|
+ <u-button class="app-buttom" v-if="xunJianStore.contentArray.siteList.inspectionStatus == 1" type="primary" shape="circle" @click="buttonClick(2)"> 提交 </u-button>
|
|
|
</view>
|
|
|
</view>
|
|
|
|
|
@@ -86,13 +80,12 @@
|
|
|
<script setup>
|
|
|
import { onLoad, onShow } from "@dcloudio/uni-app";
|
|
|
import { ref, onMounted, reactive, computed, getCurrentInstance, toRefs, inject, shallowRef } from "vue";
|
|
|
+import { publicStores, xunJianStores } from "@/store/modules/index";
|
|
|
|
|
|
import { updatePlan } from "@/api/business/mhxf/xunJian/plan.js";
|
|
|
|
|
|
-import xunJianStore from "@/store/modules/xunJian";
|
|
|
-
|
|
|
const BASE_URL = inject("$BASE_URL");
|
|
|
-const xunjianStore = xunJianStore(); //全局变量值Store
|
|
|
+const xunJianStore = xunJianStores(); //全局变量值Store
|
|
|
|
|
|
const { proxy } = getCurrentInstance();
|
|
|
|
|
@@ -106,7 +99,7 @@ function checkboxChange(value, index) {
|
|
|
* @备注显示事件
|
|
|
*/
|
|
|
function remarksClick(index) {
|
|
|
- xunjianStore.contentArray.contentList[index].remarksBool = true;
|
|
|
+ xunJianStore.contentArray.contentList[index].remarksBool = true;
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -170,15 +163,15 @@ async function buttonClick(type) {
|
|
|
}
|
|
|
|
|
|
const array = {
|
|
|
- siteType: xunjianStore.contentArray.siteList.siteType,
|
|
|
- siteNubmber: xunjianStore.contentArray.siteList.siteNubmber,
|
|
|
- siteName: xunjianStore.contentArray.siteList.siteName,
|
|
|
+ siteType: xunJianStore.contentArray.siteList.siteType,
|
|
|
+ siteNubmber: xunJianStore.contentArray.siteList.siteNubmber,
|
|
|
+ siteName: xunJianStore.contentArray.siteList.siteName,
|
|
|
siteStatus: 1, //定位 (0:未定位 1:已定位)
|
|
|
- longitude: xunjianStore.contentArray.siteList.longitude,
|
|
|
- latitude: xunjianStore.contentArray.siteList.latitude,
|
|
|
- planSonId: xunjianStore.contentArray.siteList.planSonId,
|
|
|
- siteId: xunjianStore.contentArray.siteList.id,
|
|
|
- recordPictureList: xunjianStore.contentArray.siteList.recordPictureList,
|
|
|
+ longitude: xunJianStore.contentArray.siteList.longitude,
|
|
|
+ latitude: xunJianStore.contentArray.siteList.latitude,
|
|
|
+ planSonId: xunJianStore.contentArray.siteList.planSonId,
|
|
|
+ siteId: xunJianStore.contentArray.siteList.id,
|
|
|
+ recordPictureList: xunJianStore.contentArray.siteList.recordPictureList,
|
|
|
recordOptionList: recordOptionList,
|
|
|
};
|
|
|
|
|
@@ -194,9 +187,9 @@ async function buttonClick(type) {
|
|
|
}
|
|
|
|
|
|
onLoad((options) => {
|
|
|
- contentList.value = xunjianStore.contentArray.contentList;
|
|
|
+ contentList.value = xunJianStore.contentArray.contentList;
|
|
|
|
|
|
- if (xunjianStore.contentArray.siteList.inspectionStatus == 2) {
|
|
|
+ if (xunJianStore.contentArray.siteList.inspectionStatus == 2) {
|
|
|
if (contentList.value.length > 0) {
|
|
|
contentList.value.forEach((el) => {
|
|
|
el.contentOptionListValue1 = [];
|