Browse Source

主管任务审批

zhujindu 6 months ago
parent
commit
fd2387ba8a

+ 1 - 0
src/router/index.js

@@ -446,6 +446,7 @@ const router = new VueRouter({
           name: 'SUPTaskApproval',
           component: () => import('@/views/week/SUPTaskApproval/index.vue'),
           meta: { title: '主管任务审批', keepAlive: true },
+          children: [],
         },
         {
           path: '/SUPTaskApprovalDetail',

+ 10 - 32
src/views/week/SUPTaskApproval/SUPTaskApprovalDetail.vue

@@ -47,7 +47,7 @@
         ref="detailItem"></detailItem>
     </div>
     <br />
-    <div class="approvalRemarh" v-if="source == 'SUPTaskApproval' && info.approvalStatus == '1'">
+    <div class="approvalRemarh" v-if="info.approvalStatus == '1'">
       <div class="approvalLabel">审批意见</div>
       <div class="remark">
         <van-field
@@ -57,21 +57,7 @@
           placeholder="请输入审批意见" />
       </div>
     </div>
-    <!-- 从查询列表来 -->
-    <!-- approvalStatus//1-待审批 2-审批通过 3-拒绝待提交 -->
-    <template v-if="source == 'VisitSummary'">
-      <div class="tc" style="padding: 0 16px" v-if="writeAgain && !info.approvalStatus">
-        <van-button class="submitBtn" block type="info" color="#0057ba" @click="onSubmit">
-          补填保存
-        </van-button>
-      </div>
-      <div class="tc" style="padding: 0 16px" v-if="info.approvalStatus == '3'">
-        <van-button class="submitBtn" block type="info" color="#0057ba" @click="submitApproval">
-          提交审批
-        </van-button>
-      </div>
-    </template>
-    <template v-if="source == 'SUPTaskApproval' && info.approvalStatus == '1'">
+    <template v-if="info.approvalStatus == '1'">
       <div class="bottomBtn">
         <van-button color="red" round @click="approvalStoreFun('Nopass')">拒绝</van-button>
         <van-button type="primary" round @click="approvalStoreFun('pass')">通过</van-button>
@@ -95,7 +81,7 @@ import detailItem from './detailItem';
 import { writeAgainCustomAnswer } from '@/api/week';
 import { changeApproval } from '@/api/SUPTaskApproval.js';
 export default {
-  name: 'daily',
+  name: 'SUPTaskApprovalDetail',
   components: { deleteUploadImg, detailItem },
   data() {
     return {
@@ -124,12 +110,10 @@ export default {
       collectionItemLists: [],
       writeAgain: false,
       approvalMessage: '',
-      source: '',
       //
     };
   },
-  activated() {
-    this.source = this.$route.query.source || '';
+  created() {
     this.powerGrade = localStorage.getItem('powerGrade');
     this.getDetailById();
     this.num = 0;
@@ -205,18 +189,12 @@ export default {
       // });
     },
     onClickLeft() {
-      if (this.source == 'SUPTaskApproval') {
-        this.$router.replace({
-          path: '/SUPTaskApproval',
-          query: {
-            tabVal: this.info.approvalStatus == '1' ? '1' : '2',
-          },
-        });
-      } else {
-        this.$router.replace({
-          path: '/VisitSummary',
-        });
-      }
+      this.$router.replace({
+        path: '/SUPTaskApproval',
+        query: {
+          tabVal: this.info.approvalStatus == '1' ? '1' : '2',
+        },
+      });
     },
     onSubmit() {
       let collectionAnswerlisd = this.$refs.detailItem.collectionAnswerlisd;

+ 49 - 118
src/views/week/SUPTaskApproval/detailItem.vue

@@ -12,7 +12,7 @@
             v-model="item.answerValue"
             :placeholder="item.customName"
             type="number"
-            :disabled="setDisabled(item)"
+            :disabled="true"
             @input="numberFn(item, index)"></van-field>
           <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
             {{ item.remark }}
@@ -30,7 +30,7 @@
             name="calendar"
             placeholder="点击选择日期"
             readonly
-            :disabled="setDisabled(item)"
+            :disabled="true"
             @click="showCalendarClick(index)" />
           <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
             {{ item.remark }}
@@ -51,14 +51,14 @@
               :imgs="item.fileInfoList"
               :isEdit="item.allowWriteAgain"></delete-upload-img>
             <upload-img
-              v-if="!setDisabled(item)"
+              v-if="false"
               :uploadid="uploadid2"
               @newimgarr="newimgarr1"
               imgText="上传照片"
               :indexImg="index"
               :customId="item.customId"
               :summaryId="item.summaryId"
-              :allowWriteAgain="!setDisabled(item)"
+              :allowWriteAgain="false"
               @click="imgClick(item, index)"></upload-img>
           </van-row>
         </div>
@@ -69,7 +69,7 @@
             </template>
           </van-cell>
           <van-field
-            :disabled="setDisabled(item)"
+            :disabled="true"
             v-model="item.answerValue"
             :formatter="formatter"
             :placeholder="item.customName"></van-field>
@@ -77,81 +77,20 @@
             {{ item.remark }}
           </p>
         </div>
-        <template v-if="approvalStatus == '3'">
-          <div v-if="item.answerType == 'gs'" class="formLabel z-cell" @click="regionClick(index)">
-            <van-cell>
-              <template #title>
-                <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
-              </template>
-            </van-cell>
-            <van-field
-              readonly
-              v-model="item.answerValue"
-              :formatter="formatter"
-              :placeholder="item.customName"></van-field>
-            <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
-              {{ item.remark }}
-            </p>
-          </div>
-          <div
-            v-if="item.answerType == 'dq'"
-            class="formLabel z-cell"
-            @click="SalesRegionClick(index)">
-            <van-cell>
-              <template #title>
-                <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
-              </template>
-            </van-cell>
-            <van-field
-              readonly
-              v-model="item.answerValue"
-              :formatter="formatter"
-              :placeholder="item.customName"></van-field>
-            <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
-              {{ item.remark }}
-            </p>
-          </div>
-          <div
-            v-if="item.answerType == 'xsb'"
-            class="formLabel z-cell"
-            @click="SalesDepartmentClick(index)">
-            <van-cell>
-              <template #title>
-                <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
-              </template>
-            </van-cell>
-            <van-field
-              readonly
-              v-model="item.answerValue"
-              :formatter="formatter"
-              :placeholder="item.customName"></van-field>
-            <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
-              {{ item.remark }}
-            </p>
-          </div>
-        </template>
-        <template v-else>
-          <div
-            class="formLabel z-cell z-cells z-celly"
-            v-if="item.answerType == 'gs' || item.answerType == 'dq' || item.answerType == 'xsb'">
-            <van-cell>
-              <template #title
-                >{{ index + 1 }}.{{ item.customName }}
-                <span
-                  style="
-                    color: #444;
-                    font-size: 12px;
-                    margin: 0;
-                    padding: 10px 0;
-                    text-align: right;
-                  "
-                  >{{ item.remark }}</span
-                ></template
-              >
-            </van-cell>
-            <p class="mg0">{{ item.answerValue }}</p>
-          </div>
-        </template>
+        <div
+          class="formLabel z-cell z-cells z-celly"
+          v-if="item.answerType == 'gs' || item.answerType == 'dq' || item.answerType == 'xsb'">
+          <van-cell>
+            <template #title
+              >{{ index + 1 }}.{{ item.customName }}
+              <span
+                style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right"
+                >{{ item.remark }}</span
+              ></template
+            >
+          </van-cell>
+          <p class="mg0">{{ item.answerValue }}</p>
+        </div>
         <div v-if="item.answerType == 'duox'" class="formLabel z-cell">
           <van-cell>
             <template #title>
@@ -159,7 +98,7 @@
             </template>
           </van-cell>
           <z-checkbox
-            :disabled="setDisabled(item)"
+            :disabled="true"
             :answerType="item.answerType"
             :checkboxval="item.answerValue"
             :collectionType="item.customOptionList"
@@ -174,7 +113,7 @@
             </template>
           </van-cell>
           <z-radio
-            :disabled="setDisabled(item)"
+            :disabled="true"
             :answerType="item.answerType"
             :collectionType="item.collectionType"
             :radio="item.answerValue"
@@ -341,13 +280,6 @@ export default {
     },
   },
   methods: {
-    setDisabled(item) {
-      if (this.approvalStatus == '3' && this.source == 'VisitSummary') {
-        return false;
-      } else {
-        return true;
-      }
-    },
     showCalendarClick(val) {
       if (!val.allowWriteAgain) return;
       this.dateIndex = val;
@@ -456,29 +388,28 @@ export default {
       for (var q = 0; q < this.collectionItemList.length; q++) {
         this.collectionItemList[q].answerName = undefined;
         // 公司
-        if (
-          (this.collectionItemList[q].answerType == 'gs' ||
-            this.collectionItemList[q].answerType == 'dq' ||
-            this.collectionItemList[q].answerType == 'xsb') &&
-          this.activaFlag
-        ) {
-          debugger;
-          this.activaFlag = false;
-          if (this.collectionItemList[q].answerType == 'xsb') {
-            this.getDeptsBy(this.collectionItemList[q].answerValue);
-            this.getDeptInfo(
-              'dept',
-              this.collectionItemList[q].answerType,
-              this.collectionItemList[q].answerValue
-            );
-          } else {
-            this.getDeptInfo(
-              'dept',
-              this.collectionItemList[q].answerType,
-              this.collectionItemList[q].answerValue
-            );
-          }
-        }
+        // if (
+        //   (this.collectionItemList[q].answerType == 'gs' ||
+        //     this.collectionItemList[q].answerType == 'dq' ||
+        //     this.collectionItemList[q].answerType == 'xsb') &&
+        //   this.activaFlag
+        // ) {
+        //   this.activaFlag = false;
+        //   if (this.collectionItemList[q].answerType == 'xsb') {
+        //     this.getDeptsBy(this.collectionItemList[q].answerValue);
+        //     this.getDeptInfo(
+        //       'dept',
+        //       this.collectionItemList[q].answerType,
+        //       this.collectionItemList[q].answerValue
+        //     );
+        //   } else {
+        //     this.getDeptInfo(
+        //       'dept',
+        //       this.collectionItemList[q].answerType,
+        //       this.collectionItemList[q].answerValue
+        //     );
+        //   }
+        // }
         // 单选
         if (this.collectionItemList[q].answerType == 'dx') {
           let findCustom = this.collectionItemList[q].customOptionList.find((item) => item.checked);
@@ -706,8 +637,8 @@ export default {
           this.collectionItemList[k1].answerValue = '';
         }
         if (this.collectionItemList[k1].answerType == 'dq') {
-          this.collectionItemList[k1].answerName = val.deptName;
-          this.collectionItemList[k1].answerValue = val.deptCode;
+          this.collectionItemList[k1].answerName = val.deptCode;
+          this.collectionItemList[k1].answerValue = val.deptName;
         }
         if (this.collectionItemList[k1].answerType == 'xsb' && val.deptId != '') {
           this.getDeptInfo('dept', 'xsb');
@@ -727,8 +658,8 @@ export default {
           this.collectionItemList[k1].answerValue = '';
         }
         if (this.collectionItemList[k1].answerType == 'gs') {
-          this.collectionItemList[k1].answerName = val.deptName;
-          this.collectionItemList[k1].answerValue = val.deptCode;
+          this.collectionItemList[k1].answerName = val.deptCode;
+          this.collectionItemList[k1].answerValue = val.deptName;
         }
         if (this.collectionItemList[k1].answerType == 'dq') {
           this.getDeptInfo('dept', 'dq');
@@ -739,8 +670,8 @@ export default {
       this.SalesDepartmentShow = false;
       for (var k1 = 0; k1 < this.collectionItemList.length; k1++) {
         if (this.collectionItemList[k1].answerType == 'xsb') {
-          this.collectionItemList[k1].answerName = val.deptName;
-          this.collectionItemList[k1].answerValue = val.deptCode;
+          this.collectionItemList[k1].answerName = val.deptCode;
+          this.collectionItemList[k1].answerValue = val.deptName;
         }
       }
     },

+ 1 - 2
src/views/week/SUPTaskApproval/index.vue

@@ -67,11 +67,10 @@ export default {
     },
     approveFn(row) {
       this.$router.push({
-        path: '/VisitSummaryDetail',
+        path: '/SUPTaskApprovalDetail',
         query: {
           userSummaryId: row.userSummaryId,
           summaryApprovalId: row.summaryApprovalId,
-          source: 'SUPTaskApproval',
         },
       });
     },

+ 64 - 60
src/views/week/VisitSummaryDetail.vue

@@ -41,42 +41,34 @@
     <div
       class="container linep"
       style="background-color: #fff; width: 94%; margin: 0px auto; border-radius: 6px">
-      <componVisitSummary
-        :collectionItemLists="collectionItemLists"
-        :approvalStatus="info.approvalStatus"
-        ref="componVisitSummary"></componVisitSummary>
+      <!-- 退回待提交 -->
+      <template v-if="info.approvalStatus == '3'">
+        <componVisitSummary
+          :collectionItemLists="collectionItemLists"
+          :approvalStatus="info.approvalStatus"
+          ref="componVisitSummary"></componVisitSummary>
+      </template>
+      <!-- 补填、详情 -->
+      <template v-else>
+        <allowWriteAgainSummary
+          :collectionItemLists="collectionItemLists"
+          :approvalStatus="info.approvalStatus"
+          ref="allowWriteAgainSummary"></allowWriteAgainSummary>
+      </template>
     </div>
     <br />
-    <div class="approvalRemarh" v-if="source == 'SUPTaskApproval' && info.approvalStatus == '1'">
-      <div class="approvalLabel">审批意见</div>
-      <div class="remark">
-        <van-field
-          v-model="approvalMessage"
-          rows="3"
-          type="textarea"
-          placeholder="请输入审批意见" />
-      </div>
-    </div>
     <!-- 从查询列表来 -->
     <!-- approvalStatus//1-待审批 2-审批通过 3-拒绝待提交 -->
-    <template v-if="source == 'VisitSummary'">
-      <div class="tc" style="padding: 0 16px" v-if="writeAgain && !info.approvalStatus">
-        <van-button class="submitBtn" block type="info" color="#0057ba" @click="onSubmit">
-          补填保存
-        </van-button>
-      </div>
-      <div class="tc" style="padding: 0 16px" v-if="info.approvalStatus == '3'">
-        <van-button class="submitBtn" block type="info" color="#0057ba" @click="submitApproval">
-          提交审批
-        </van-button>
-      </div>
-    </template>
-    <template v-if="source == 'SUPTaskApproval' && info.approvalStatus == '1'">
-      <div class="bottomBtn">
-        <van-button color="red" round @click="approvalStoreFun('Nopass')">拒绝</van-button>
-        <van-button type="primary" round @click="approvalStoreFun('pass')">通过</van-button>
-      </div>
-    </template>
+    <div class="tc" style="padding: 0 16px" v-if="writeAgain && !info.approvalStatus">
+      <van-button class="submitBtn" block type="info" color="#0057ba" @click="onSubmit">
+        补填保存
+      </van-button>
+    </div>
+    <div class="tc" style="padding: 0 16px" v-if="info.approvalStatus == '3'">
+      <van-button class="submitBtn" block type="info" color="#0057ba" @click="submitApproval">
+        提交审批
+      </van-button>
+    </div>
     <br />
     <br />
     <br />
@@ -88,15 +80,16 @@ import history from '@/assets/Icon/history.png';
 import tm from '@/assets/Icon/tm.png';
 import zw from '@/assets/Icon/zw.png';
 import ry from '@/assets/Icon/ry.png';
-import { getSummaryMobilo } from '@/api/index';
+import { getSummaryMobilo, insertCustomAnswer } from '@/api/index';
 import { ImagePreview } from 'vant';
 import deleteUploadImg from '@/components/deleteUploadImg';
 import componVisitSummary from '@/views/week/componVisitSummary';
+import allowWriteAgainSummary from '@/views/week/allowWriteAgainSummary';
 import { writeAgainCustomAnswer } from '@/api/week';
 import { changeApproval } from '@/api/SUPTaskApproval.js';
 export default {
   name: 'daily',
-  components: { deleteUploadImg, componVisitSummary },
+  components: { deleteUploadImg, componVisitSummary, allowWriteAgainSummary },
   data() {
     return {
       info: null,
@@ -219,8 +212,8 @@ export default {
       }
     },
     onSubmit() {
-      let collectionAnswerlisd = this.$refs.componVisitSummary.collectionAnswerlisd;
-      let collectionItemList = this.$refs.componVisitSummary.collectionItemList;
+      let collectionAnswerlisd = this.$refs.allowWriteAgainSummary.collectionAnswerlisd;
+      let collectionItemList = this.$refs.allowWriteAgainSummary.collectionItemList;
       for (var c = 0; c < collectionAnswerlisd.length; c++) {
         for (var b = 0; b < collectionItemList.length; b++) {
           if (collectionAnswerlisd[c].id == collectionItemList[b].customId) {
@@ -258,32 +251,43 @@ export default {
           this.$toast(err.msg);
         });
     },
-    approvalStoreFun(type) {
-      if (type == 'pass') {
-        this.changeApprovalFun('1');
-      } else {
-        if (this.approvalMessage != '') {
-          this.changeApprovalFun('2');
-        } else {
-          this.$notify({ type: 'warning', message: '请输入审批意见' });
+    submitApproval() {
+      let collectionAnswerlisd = this.$refs.componVisitSummary.collectionAnswerlisd;
+      let collectionItemList = this.$refs.componVisitSummary.collectionItemList;
+      for (var c = 0; c < collectionAnswerlisd.length; c++) {
+        for (var b = 0; b < collectionItemList.length; b++) {
+          if (collectionAnswerlisd[c].id == collectionItemList[b].customId) {
+            collectionItemList[b].customOptionList = collectionAnswerlisd[c].value;
+          }
         }
       }
-    },
-    changeApprovalFun(approvalStatus) {
-      this.toastLoading(0, '加载中...', true);
-      changeApproval({
-        summaryApprovalId: this.$route.query.summaryApprovalId || '', //	Long	主管任务审批id
-        userSummaryId: this.$route.query.userSummaryId, //	Long	主管任务填写主键id
-        approvalStatus: approvalStatus, //	string	审批状态:1-通过 2-拒绝
-        approvalOpinion: this.approvalMessage, //	string	审批意见,如果审批状态为拒绝则不能为空
-      }).then((res) => {
-        this.toastLoading().clear();
-        if (res.code == 200) {
-          this.$router.replace({
-            path: '/SUPTaskApproval',
-          });
-        }
-      });
+      // // 照片
+      let zpDataList = collectionItemList.find((item) => item.answerType == 'zp');
+      if (zpDataList) {
+        let fileIdList = [];
+        zpDataList.fileInfoList.forEach((item) => {
+          fileIdList.push(item.id);
+        });
+        zpDataList.fileIdList = fileIdList;
+      }
+      insertCustomAnswer({
+        userSummaryId: this.info.userSummaryId, //	Long	用户总结id,如果为新增则不填,编辑则必填
+        summaryId: this.info.summaryId, //Long	主管任务id
+        customItemList: collectionItemList,
+      })
+        .then((res) => {
+          if (res.code == 200) {
+            this.$toast('操作成功!');
+            this.$router.replace({
+              path: '/VisitSummary',
+            });
+          } else {
+            this.$toast(res.msg);
+          }
+        })
+        .catch((err) => {
+          this.$toast(err.msg);
+        });
     },
   },
 };

+ 0 - 8
src/views/week/allowWriteAgainSummary.vue

@@ -196,14 +196,6 @@ export default {
         return [];
       },
     },
-    approvalStatus: {
-      type: String,
-      default: '',
-    },
-    source: {
-      type: String,
-      default: '',
-    },
   },
   data() {
     return {

+ 51 - 93
src/views/week/componVisitSummary.vue

@@ -8,12 +8,10 @@
               <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
             </template>
           </van-cell>
-          <!-- allowWriteAgain 是否允许补填 true/false -->
           <van-field
             v-model="item.answerValue"
             :placeholder="item.customName"
             type="number"
-            :disabled="setDisabled(item)"
             @input="numberFn(item, index)"></van-field>
           <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
             {{ item.remark }}
@@ -31,7 +29,6 @@
             name="calendar"
             placeholder="点击选择日期"
             readonly
-            :disabled="setDisabled(item)"
             @click="showCalendarClick(index)" />
           <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
             {{ item.remark }}
@@ -52,14 +49,12 @@
               :imgs="item.fileInfoList"
               :isEdit="item.allowWriteAgain"></delete-upload-img>
             <upload-img
-              v-if="!setDisabled(item)"
               :uploadid="uploadid2"
               @newimgarr="newimgarr1"
               imgText="上传照片"
               :indexImg="index"
               :customId="item.customId"
               :summaryId="item.summaryId"
-              :allowWriteAgain="!setDisabled(item)"
               @click="imgClick(item, index)"></upload-img>
           </van-row>
         </div>
@@ -70,7 +65,6 @@
             </template>
           </van-cell>
           <van-field
-            :disabled="setDisabled(item)"
             v-model="item.answerValue"
             :formatter="formatter"
             :placeholder="item.customName"></van-field>
@@ -78,81 +72,57 @@
             {{ item.remark }}
           </p>
         </div>
-        <template v-if="approvalStatus == '3'">
-          <div v-if="item.answerType == 'gs'" class="formLabel z-cell" @click="regionClick(index)">
-            <van-cell>
-              <template #title>
-                <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
-              </template>
-            </van-cell>
-            <van-field
-              readonly
-              v-model="item.answerValue"
-              :formatter="formatter"
-              :placeholder="item.customName"></van-field>
-            <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
-              {{ item.remark }}
-            </p>
-          </div>
-          <div
-            v-if="item.answerType == 'dq'"
-            class="formLabel z-cell"
-            @click="SalesRegionClick(index)">
-            <van-cell>
-              <template #title>
-                <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
-              </template>
-            </van-cell>
-            <van-field
-              readonly
-              v-model="item.answerValue"
-              :formatter="formatter"
-              :placeholder="item.customName"></van-field>
-            <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
-              {{ item.remark }}
-            </p>
-          </div>
-          <div
-            v-if="item.answerType == 'xsb'"
-            class="formLabel z-cell"
-            @click="SalesDepartmentClick(index)">
-            <van-cell>
-              <template #title>
-                <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
-              </template>
-            </van-cell>
-            <van-field
-              readonly
-              v-model="item.answerValue"
-              :formatter="formatter"
-              :placeholder="item.customName"></van-field>
-            <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
-              {{ item.remark }}
-            </p>
-          </div>
-        </template>
-        <template v-else>
-          <div
-            class="formLabel z-cell z-cells z-celly"
-            v-if="item.answerType == 'gs' || item.answerType == 'dq' || item.answerType == 'xsb'">
-            <van-cell>
-              <template #title
-                >{{ index + 1 }}.{{ item.customName }}
-                <span
-                  style="
-                    color: #444;
-                    font-size: 12px;
-                    margin: 0;
-                    padding: 10px 0;
-                    text-align: right;
-                  "
-                  >{{ item.remark }}</span
-                ></template
-              >
-            </van-cell>
-            <p class="mg0">{{ item.answerValue }}</p>
-          </div>
-        </template>
+        <div v-if="item.answerType == 'gs'" class="formLabel z-cell" @click="regionClick(index)">
+          <van-cell>
+            <template #title>
+              <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
+            </template>
+          </van-cell>
+          <van-field
+            readonly
+            v-model="item.answerValue"
+            :formatter="formatter"
+            :placeholder="item.customName"></van-field>
+          <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
+            {{ item.remark }}
+          </p>
+        </div>
+        <div
+          v-if="item.answerType == 'dq'"
+          class="formLabel z-cell"
+          @click="SalesRegionClick(index)">
+          <van-cell>
+            <template #title>
+              <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
+            </template>
+          </van-cell>
+          <van-field
+            readonly
+            v-model="item.answerValue"
+            :formatter="formatter"
+            :placeholder="item.customName"></van-field>
+          <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
+            {{ item.remark }}
+          </p>
+        </div>
+        <div
+          v-if="item.answerType == 'xsb'"
+          class="formLabel z-cell"
+          @click="SalesDepartmentClick(index)">
+          <van-cell>
+            <template #title>
+              <span v-if="item.isMust == 0" class="van-f-red">*</span>{{ item.customName }}
+            </template>
+          </van-cell>
+          <van-field
+            readonly
+            v-model="item.answerValue"
+            :formatter="formatter"
+            :placeholder="item.customName"></van-field>
+          <p style="color: #444; font-size: 12px; margin: 0; padding: 10px 0; text-align: right">
+            {{ item.remark }}
+          </p>
+        </div>
         <div v-if="item.answerType == 'duox'" class="formLabel z-cell">
           <van-cell>
             <template #title>
@@ -160,7 +130,6 @@
             </template>
           </van-cell>
           <z-checkbox
-            :disabled="setDisabled(item)"
             :answerType="item.answerType"
             :checkboxval="item.answerValue"
             :collectionType="item.customOptionList"
@@ -175,7 +144,6 @@
             </template>
           </van-cell>
           <z-radio
-            :disabled="setDisabled(item)"
             :answerType="item.answerType"
             :collectionType="item.collectionType"
             :radio="item.answerValue"
@@ -342,15 +310,6 @@ export default {
     },
   },
   methods: {
-    setDisabled(item) {
-      if (this.approvalStatus == '3' && this.source == 'VisitSummary') {
-        return false;
-      } else if ((!this.approvalStatus || this.approvalStatus == '1') && item.allowWriteAgain) {
-        return false;
-      } else {
-        return true;
-      }
-    },
     showCalendarClick(val) {
       if (!val.allowWriteAgain) return;
       this.dateIndex = val;
@@ -465,7 +424,6 @@ export default {
             this.collectionItemList[q].answerType == 'xsb') &&
           this.activaFlag
         ) {
-          debugger;
           this.activaFlag = false;
           if (this.collectionItemList[q].answerType == 'xsb') {
             this.getDeptsBy(this.collectionItemList[q].answerValue);