Переглянути джерело

投诉,信息沟通问题及提示信息修改

cyy 2 роки тому
батько
коміт
951edb040d

+ 5 - 5
src/api/platform/form/transfer.js

@@ -28,7 +28,7 @@ export function findFormJsonByBo(params) {
  * 快照
  * @param {*} params
  */
-export function snapshot( params) {
+export function snapshot(params) {
   return request({
     url: FORM_URL() + `/file/upload/runQianUpload?url=${encodeURIComponent(params.url)}&name=${params.name}&type=${params.type}`,
     method: 'post',
@@ -49,14 +49,14 @@ export function save(params) {
 }
 
 /**
- * 复制前数据请求
+ * 同意流程
  * @param {*} params
  */
-export function preCopy(params) {
+export function argee(params) {
   return request({
-    url: FORM_URL() + '/form/def/preCopy',
+    url: FORM_URL() + '/bpm/task/agree',
     method: 'post',
-    params: params
+    data: params
   })
 }
 

+ 6 - 0
src/router/routes.js

@@ -311,6 +311,12 @@ const frameCustom = [
         name: 'communicationList',
         meta: { title: '信息沟通' },
         component: _import('/platform/bpmn/communication/communicationList')
+      },
+      {
+        path: 'complaint/complaintList',
+        name: 'complaintList',
+        meta: { title: '投诉列表' },
+        component: _import('/platform/bpmn/complaint/complaintList')
       }
     ]
   },

+ 762 - 700
src/views/platform/bpmn/communication/communication.vue

@@ -1,62 +1,94 @@
 <template>
-  <van-overlay class="backgroundSty" z-index="2004" :show="showPop">
+  <van-overlay class="backgroundSty" z-index="2002" :show="showPop">
     <div style="height:5%">
       <van-sticky>
-        <van-nav-bar :title="'沟通记录 ' +  (typeValue == '3'? '编制' : typeValue == '4' ? '修改': typeValue == '1' ? '详情' : '')"
-          :left-text="'x'" left-arrow
-          :right-text="typeValue == '4'?'退回原因':''"
-          @click-left="closePop()" @click-right="toCheckMode()" />
+        <van-nav-bar
+          :title="
+            '沟通记录 ' +
+              (typeValue == '3'
+                ? '编制'
+                : typeValue == '4'
+                ? '修改'
+                : typeValue == '1'
+                ? '详情'
+                : '')
+          "
+          :right-text="typeValue == '4' ? '退回原因' : ''"
+          @click-left="closePop()"
+          @click-right="getBack()"
+        >
+          <template #left>
+            <van-icon name="cross" class="ibps-nav-bar__close-icon" />
+          </template>
+        </van-nav-bar>
       </van-sticky>
     </div>
     <div class="scrollView">
       <van-form @submit="onSubmit">
-        <van-field label="表单编号:" placeholder="请输入表单编号" v-model="form.biaoDanBianHao" label-width = "6em" input-align="left" readonly />
+        <van-field
+          v-model="form.biaoDanBianHao"
+          label="表单编号:"
+          placeholder="请输入表单编号"
+          label-width="6em"
+          input-align="left"
+          readonly
+        />
         <van-field
           v-model="form.keHuLianXiRen"
           required
           label="用户姓名:"
           placeholder="请输入用户姓名"
-          label-width = "6em" 
+          label-width="6em"
           clearable
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
         />
         <van-field
           v-model="form.keHuDanWeiMin"
           required
           label="用户单位:"
           placeholder="请输入用户单位"
-          label-width = "6em" 
+          label-width="6em"
           clearable
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
         />
         <van-field
           v-model="form.lianXiDianHua"
           required
           label="联系电话:"
           placeholder="请输入联系电话"
-          label-width = "6em" 
+          label-width="6em"
           clearable
-          :rules="[{ validator:$common.getRequest.checkPhone, message: '手机号格式错误' }]"
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+          :rules="[
+            {
+              validator: $common.getRequest.checkPhone,
+              message: '手机号格式错误'
+            }
+          ]"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
         />
         <van-field
           v-model="form.yongHuYouXiang"
           required
           label="用户邮箱:"
           placeholder="请输入用户邮箱"
-          label-width = "6em" 
+          label-width="6em"
           clearable
-          :rules="[{ validator:$common.getRequest.checkEmail, message: '邮箱格式错误' }]"
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+          :rules="[
+            {
+              validator: $common.getRequest.checkEmail,
+              message: '邮箱格式错误'
+            }
+          ]"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
         />
         <van-field
           required
           label="沟通类型:"
           placeholder="请选择沟通类型"
-          label-width = "6em"
+          label-width="6em"
           :value="form.gouTongLeiXing"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
           @click="sheetShow = true"
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
         />
         <van-popup v-model="sheetShow" position="bottom">
           <van-picker
@@ -72,18 +104,18 @@
           required
           label="其他类型:"
           placeholder="请输入其他类型"
-          label-width = "6em" 
+          label-width="6em"
           clearable
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
         />
         <van-field
           required
           label="沟通时间:"
           placeholder="请选择沟通时间"
-          label-width = "6em"
+          label-width="6em"
           :value="form.gouTongRiQi"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
           @click="gouTongRiQiClick(form.gouTongRiQi)"
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
         />
         <van-popup v-model="timeShow" position="bottom">
           <van-datetime-picker
@@ -100,25 +132,27 @@
           type="textarea"
           label="沟通事项:"
           placeholder="请输入沟通事项"
-          label-width = "6em" 
+          label-width="6em"
           clearable
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
         />
-			</van-form>
+      </van-form>
       <van-cell-group>
-        <div class="verticalLine" style="width:6em;padding: 1em 0;">沟通内容</div>
+        <div class="verticalLine" style="width:6em;padding: 1em 0;">
+          沟通内容
+        </div>
         <van-field
           v-model="form.gouTongNeiRong"
           autosize
           type="textarea"
           label=""
           placeholder="意见和建议"
-          label-width = "0" 
+          label-width="0"
           clearable
-          :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+          :readonly="typeValue != 3 && typeValue != 4 ? true : false"
         />
       </van-cell-group>
-      
+
       <ibps-uploader
         v-model="form.fuJian"
         label="附件"
@@ -127,7 +161,7 @@
         :have-padding="false"
         multiple
         clearable
-        :readonly="typeValue != 3 && typeValue != 4 ? true: false"
+        :readonly="typeValue != 3 && typeValue != 4 ? true : false"
       />
       <ibps-signature
         v-if="form.leiXing == '2'"
@@ -135,17 +169,19 @@
         label="用户确认"
         class="yonghu"
         placeholder=" "
-        :readonly="typeValue == 3 && typeValue == 4 ? true: false"
+        :readonly="typeValue == 3 && typeValue == 4 ? true : false"
       />
-      <van-cell-group  v-if="typeValue != 3 && typeValue != 4">
-        <div class="verticalLine" style="width:8em;padding: 1em 0;">沟通内容确定</div>
+      <van-cell-group v-if="typeValue != 3 && typeValue != 4">
+        <div class="verticalLine" style="width:8em;padding: 1em 0;">
+          沟通内容确定
+        </div>
         <van-field
           v-model="form.gouTongQueDingNei"
           autosize
           type="textarea"
           label=""
           placeholder="意见和建议"
-          label-width = "0" 
+          label-width="0"
           clearable
           :readonly="typeValue != 2"
         />
@@ -159,714 +195,740 @@
         :readonly="typeValue != 2"
       />
 
-			<div class="padding flex flex-direction" v-if="typeValue == '3'">
-				<van-button type="success" class="btn btn-back-color" @click="onSubmit">提交
-				</van-button>
-			</div>
-			<div class="padding flex flex-direction" v-if="typeValue == '2'">
-				<van-button type="success" class="btn btn-back-color" @click="onAgree('已完成','同意','确定')">同意
-				</van-button>
-			</div>
-			<div class="padding flex flex-direction" v-if="typeValue == '4'">
-				<van-button type="success" class="btn btn-back-color" @click="onAgree('已编制','重新提交','提交')">修改
-				</van-button>
-			</div>
-		</div>
-    
+      <div v-if="typeValue == '3'" class="padding flex flex-direction">
+        <van-button
+type="success"
+class="btn btn-back-color"
+@click="onSubmit"
+          >提交
+        </van-button>
+      </div>
+      <div v-if="typeValue == '2'" class="padding flex flex-direction">
+        <van-button
+          type="success"
+          class="btn btn-back-color"
+          @click="onAgree('已完成', '同意', '确定')"
+          >同意
+        </van-button>
+      </div>
+      <div v-if="typeValue == '4'" class="padding flex flex-direction">
+        <van-button
+          type="success"
+          class="btn btn-back-color"
+          @click="onAgree('已编制', '重新提交', '提交')"
+          >修改
+        </van-button>
+      </div>
+    </div>
   </van-overlay>
 </template>
 <script>
-  import random from '@/mixins/random'
-  import bpmnStatus from '@/mixins/bpmnStatus'
-
-  import ApprovePopup from '@/business/platform/bpmn/form-ext/approve'
-
-  import IbpsMoreSearch from '@/components/ibps-more-search'
-  import IbpsAvatar from '@/components/ibps-avatar'
-  import IbpsToolbar from '@/components/ibps-toolbar'
-  import IbpsListResultPage from '@/components/ibps-list-result-page'
-  import IbpsTypeTree from '@/business/platform/cat/type/tree'
-  import IbpsBpmnDefinition from '@/business/platform/bpmn/definition/field'
-  import IbpsUploader from '@/business/platform/file/uploader'
+import random from '@/mixins/random'
+import bpmnStatus from '@/mixins/bpmnStatus'
+import IbpsUploader from '@/business/platform/file/uploader'
 
-  import IbpsBpmnFormrenderDialog from '@/business/platform/bpmn/form/dialog'
+import {
+  getNextIdByAlias,
+  findFormJsonByBo,
+  snapshot
+} from '@/api/platform/form/transfer'
+import { agree } from '@/api/platform/bpmn/bpmTask'
 
-  import { getNextIdByAlias, findFormJsonByBo, snapshot } from '@/api/platform/form/transfer'
-  import { agree } from '@/api/platform/bpmn/bpmTask'
-
-
-  export default {
-    components: {
-      IbpsMoreSearch,
-      IbpsAvatar,
-      IbpsListResultPage,
-      IbpsTypeTree,
-      IbpsBpmnDefinition,
-      IbpsToolbar,
-      ApprovePopup,
-      IbpsBpmnFormrenderDialog,
-      IbpsUploader
+export default {
+  components: {
+    IbpsUploader
+  },
+  mixins: [random, bpmnStatus],
+  props: {
+    showPop: {
+      type: Boolean,
+      default: false
     },
-    mixins: [random, bpmnStatus],
-    props: {
-      showPop:{
-        type: Boolean,
-        default: false
+    typeValue: {
+      type: String,
+      default: '3'
+    },
+    id: {
+      type: String,
+      default: ''
+    }
+  },
+  data() {
+    const useId = this.$store.getters.userId
+    return {
+      useId,
+      show: this.showPop,
+      // typeValue: '3',
+      sheetShow: false,
+      taskId: '',
+      form: {
+        xuanZeKeHu: '',
+        biaoDanBianHao: '',
+        buMenName: '',
+        keHuDanWeiMin: '',
+        keHuLianXiRen: '',
+        weiTuoDanHao: '',
+        lianXiDianHua: '',
+        yangPinMingCheng: '',
+        yangPinBianHao: '',
+        yangPinLeiXing: '',
+        baoGaoBianHao: '',
+        gouTongLeiXing: '',
+        gouTongNeiRong: '',
+        keHu: '',
+        gouTongQueDingNei: '',
+        leiXing: '2',
+        yongHuYouXiang: '',
+        qiTa: ''
+      },
+      fuJianShangChuanArray: [],
+      popupShow: false,
+      list: [
+        {
+          text: '投诉'
+        },
+        {
+          text: '检验项目'
+        },
+        {
+          text: '危机值报告'
+        },
+        {
+          text: '口头报告结果'
+        },
+        {
+          text: '延迟报告'
+        },
+        {
+          text: '其它'
+        }
+      ],
+      kehuXinXinList: [],
+
+      weiTuoList: [],
+      bianZhiRenName: '',
+      queDingRenName: '',
+      backShow: false,
+      option: '',
+      content: '',
+      timeShow: false,
+      params: {
+        year: true,
+        month: true,
+        day: true,
+        hour: true,
+        minute: true,
+        second: false
       },
-      typeValue:{
-        type: String,
-        default: '3'
+      level: null,
+      mainPosition: {
+        id: ''
       },
-      id:{
-        type: String,
-        default: ''
-      }
+      xuanzeTime: null
+    }
+  },
+  computed: {
+    rightText() {
+      return this.checkMode
+        ? this.$t('common.button.cancel')
+        : this.$t('common.button.manage')
     },
-    data() {
-      const useId = this.$store.getters.userId
-      return {
-        useId,
-        show: this.showPop,
-        // typeValue: '3',
-				sheetShow: false,
-				taskId: '',
-				form: {
-					xuanZeKeHu: '',
-					biaoDanBianHao: '',
-					buMenName: '',
-					keHuDanWeiMin: '',
-					keHuLianXiRen: '',
-					weiTuoDanHao: '',
-					lianXiDianHua: '',
-					yangPinMingCheng: '',
-					yangPinBianHao: '',
-					yangPinLeiXing: '',
-					baoGaoBianHao: '',
-					gouTongLeiXing: '',
-					gouTongNeiRong: '',
-					keHu: '',
-					gouTongQueDingNei: '',
-					leiXing: '2',
-					yongHuYouXiang: '',
-					xuanZeKeHu: '',
-					qiTa: ''
-				},
-				fuJianShangChuanArray: [],
-				popupShow: false,
-				list: [{
-					text: '投诉'
-				}, {
-					text: '检验项目'
-				}, {
-					text: '危机值报告'
-				}, {
-					text: '口头报告结果'
-				}, {
-					text: '延迟报告'
-				}, {
-					text: '其它'
-				}],
-				kehuXinXinList: [],
-
-				weiTuoList: [],
-				bianZhiRenName: '',
-				queDingRenName: '',
-				backShow: false,
-				option: '',
-				content: '',
-				timeShow: false,
-				params: {
-					year: true,
-					month: true,
-					day: true,
-					hour: true,
-					minute: true,
-					second: false
-				},
-				level: null,
-				mainPosition: {
-					id: ''
-				},
-        xuanzeTime: null,
+    selectedIds() {
+      return this.checkedIds.join(',')
+    }
+  },
+  watch: {
+    showPop: {
+      handler: function(val, oldVal) {
+        if (val === true) {
+          this.form = {
+            xuanZeKeHu: '',
+            biaoDanBianHao: '',
+            buMenName: '',
+            keHuDanWeiMin: '',
+            keHuLianXiRen: '',
+            weiTuoDanHao: '',
+            lianXiDianHua: '',
+            yangPinMingCheng: '',
+            yangPinBianHao: '',
+            yangPinLeiXing: '',
+            baoGaoBianHao: '',
+            gouTongLeiXing: '',
+            gouTongNeiRong: '',
+            keHu: '',
+            gouTongQueDingNei: '',
+            leiXing: '2',
+            yongHuYouXiang: '',
+            qiTa: ''
+          }
+          this.getKehu()
+          this.level = this.$store.getters.level
+          const mainPosition = this.$store.getters.mainPosition
+          this.mainPosition = mainPosition
+          if (this.id && this.id !== '') {
+            // this.id = this.id
+            this.getDe(this.id)
+          } else {
+            this.getGtbh()
+          }
+          // if (this.typeValue) {
+          //   this.typeValue = this.typeValue
+          // }
+        }
+      },
+      immediate: true
+    }
+  },
+  created() {},
+  methods: {
+    closePop() {
+      this.$emit('updataSet', false)
+    },
+    toCheckMode() {
+      if (this.$utils.isEmpty(this.listData)) {
+        return
       }
+      if (this.checkMode) {
+        this.showA = true
+        this.checkedIds = []
+      }
+      this.checkMode = !this.checkMode
     },
-    watch:{
-      showPop:{
-        handler: function (val, oldVal) {
-          if(val === true){
-            this.form = {
-              xuanZeKeHu: '',
-              biaoDanBianHao: '',
-              buMenName: '',
-              keHuDanWeiMin: '',
-              keHuLianXiRen: '',
-              weiTuoDanHao: '',
-              lianXiDianHua: '',
-              yangPinMingCheng: '',
-              yangPinBianHao: '',
-              yangPinLeiXing: '',
-              baoGaoBianHao: '',
-              gouTongLeiXing: '',
-              gouTongNeiRong: '',
-              keHu: '',
-              gouTongQueDingNei: '',
-              leiXing: '2',
-              yongHuYouXiang: '',
-              xuanZeKeHu: '',
-              qiTa: ''
-            }
-            this.getKehu()
-            this.level = this.$store.getters.level
-            let mainPosition = this.$store.getters.mainPosition
-            this.mainPosition = mainPosition
-            if (this.id && this.id!='') {
-              // this.id = this.id
-              this.getDe(this.id)
-            } else {
-              this.getGtbh()
-            }
-            // if (this.typeValue) {
-            //   this.typeValue = this.typeValue
-            // }
-          }
-        },
-        immediate: true
+    actionSheetCallback(e) {
+      this.form.gouTongLeiXing = e.text
+      this.sheetShow = false
+    },
+    timeShowCallback(e) {
+      const nowDate = new Date(e.getTime() + 8 * 60 * 60 * 1000)
+      const time = nowDate
+        .toJSON()
+        .split('T')
+        .join(' ')
+        .substr(0, 16)
+      this.form.gouTongRiQi = time
+      this.timeShow = false
+    },
+    gouTongRiQiClick(e) {
+      this.timeShow = true
+    },
+    // 获取上传状态
+    select(file) {
+      this.$uploades.selectUpload(file).then(res => {
+        res.forEach(item => {
+          this.fuJianShangChuanArray.push(item)
+        })
+      })
+    },
+    // 删除
+    deleteMe(id) {
+      this.fuJianShangChuanArray = this.fuJianShangChuanArray.filter(
+        item => item.id !== id
+      )
+    },
+    // 获取上传进度
+    progress(e) {},
+    // 上传成功
+    success(file) {},
+    // 上传失败
+    fail(e) {},
+    // 弹出框显示
+    qianming(index) {
+      this.popupShow = true
+    },
+    // 清除签名
+    deqianming(index) {
+      this.form.keHu = ''
+    },
+    // 保存签名
+    save(val) {
+      this.form.keHu = val
+      this.popupShow = false
+    },
+    // 清除签名
+    clear(val) {
+      this.form.keHu = ''
+    },
+    /**
+     * 关闭签名弹窗
+     */
+    close() {
+      this.popupShow = false
+    },
+
+    // 获取样品编号
+    getGtbh(callback) {
+      const smsParams = {
+        alias: 'gtbh'
       }
+      const this_ = this
+      getNextIdByAlias(smsParams).then(res => {
+        if (res.state === 200) {
+          const data = res.data
+          this_.form.biaoDanBianHao = data
+        }
+      })
     },
-    created() {
-			
-		},
-    computed: {
-      rightText() {
-        return this.checkMode ? this.$t('common.button.cancel') : this.$t('common.button.manage')
-      },
-      selectedIds() {
-        return this.checkedIds.join(',')
+    getKehu() {
+      const info = this.$store.getters.userInfo
+      if (info) {
+        this.form.keHuDanWeiMin = info.user.qq
+        this.form.lianXiDianHua = info.user.mobile
+        // this.form.keHuDanWeiMingChe = info.user.id
+        this.form.keHuLianXiRen = info.user.fullname
+        this.form.gouTongLeiXing = '投诉'
+        this.form.gouTongRiQi = this.$methCommon.time(16)
+        this.xuanzeTime = new Date()
+        this.form.yongHuYouXiang = info.user.email
       }
     },
-    methods: {
-      closePop() {
-        this.$emit('updataSet',false)
-      },
-      toCheckMode() {
-        if (this.$utils.isEmpty(this.listData)) {
-          return
-        }
-        if (this.checkMode) {
-          this.show = true
-          this.checkedIds = []
-        }
-        this.checkMode = !this.checkMode
-      },
-      actionSheetCallback(e) {
-				this.form.gouTongLeiXing = e.text
-        this.sheetShow = false
-			},
-      timeShowCallback(e) {
-        const nowDate = new Date((e).getTime() + 8 * 60 * 60 * 1000)
-		    const time = nowDate.toJSON().split('T').join(' ').substr(0, 16)
-        this.form.gouTongRiQi = time
-        this.timeShow = false
-      },
-      gouTongRiQiClick(e){
-        this.timeShow = true
-      },
-			// 获取上传状态
-			select(file) {
-				this.$uploades.selectUpload(file).then(res => {
-					res.forEach(item => {
-						this.fuJianShangChuanArray.push(item)
-					})
-				})
-			},
-			// 删除
-			deleteMe(id) {
-				this.fuJianShangChuanArray = this.fuJianShangChuanArray.filter(item => item.id !== id)
-			},
-			// 获取上传进度
-			progress(e) {},
-			// 上传成功
-			success(file) {},
-			// 上传失败
-			fail(e) {},
-			//弹出框显示
-			qianming(index) {
-				this.popupShow = true
-			},
-			//清除签名
-			deqianming(index) {
-				this.form.keHu = ''
-			},
-			//保存签名
-			save(val) {
-				this.form.keHu = val
-				this.popupShow = false
-			},
-			//清除签名
-			clear(val) {
-				this.form.keHu = ''
-			},
-			/**
-			 * 关闭签名弹窗
-			 */
-			close() {
-				this.popupShow = false
-			},
-
-			//获取样品编号
-			getGtbh(callback) {
-				let smsParams = {
-					alias: "gtbh"
-				};
-				let this_ = this
-				getNextIdByAlias(smsParams).then(res => {
-					if (res.state == 200) {
-						const data = res.data
-						this.form.biaoDanBianHao = data
-					}
-				});
-			},
-			getKehu() {
-				let info = this.$store.getters.userInfo
-				if (info) {
-					this.form.keHuDanWeiMin = info.user.qq
-					this.form.lianXiDianHua = info.user.mobile
-					// this.form.keHuDanWeiMingChe = info.user.id
-					this.form.keHuLianXiRen = info.user.fullname
-					this.form.gouTongLeiXing = '投诉'
-					this.form.gouTongRiQi = this.$methCommon.time(16)
-          this.xuanzeTime = new Date()
-					this.form.yongHuYouXiang = info.user.email
-				}
-			},
-			getDe(id) {
-				let sql =
-					`select * from t_khgtjlb where id_ = ${id}`
+    getDe(id) {
+      const sql = `select * from t_khgtjlb where id_ = ${id}`
 
-				this.$common.request('sql', sql).then(res => {
-					if (res.state == 200) {
-						const data = res.variables.data[0]
-						this.form = {
-							id: data.id_,
-							xuanZeKeHu: data.xuan_ze_ke_hu_,
-							biaoDanBianHao: data.biao_dan_bian_hao,
-							buMenName: data.xuan_ze_ke_hu_,
-							keHuDanWeiMin: data.ke_hu_dan_wei_min,
-							keHuLianXiRen: data.ke_hu_lian_xi_ren,
-							weiTuoDanHao: data.wei_tuo_dan_hao_,
-							lianXiDianHua: data.lian_xi_dian_hua_,
-							yangPinMingCheng: data.yang_pin_ming_che,
-							yangPinBianHao: data.yang_pin_bian_hao,
-							yangPinLeiXing: data.yang_pin_lei_xing,
-							baoGaoBianHao: data.bao_gao_bian_hao_,
-							gouTongLeiXing: data.gou_tong_lei_xing,
-							gouTongNeiRong: data.gou_tong_nei_rong,
-							keHu: data.ke_hu_,
-							gouTongQueDingNei: data.gou_tong_que_ding,
-							leiXing: data.lei_xing_,
-							bianZhiShiJian: data.bian_zhi_shi_jian,
-							gouTongRiQi: data.gou_tong_ri_qi_,
-							yongHuYouXiang: data.yong_hu_you_xiang,
-							gouTongRenYuan: data.gou_tong_ren_yuan,
-							xuanZeKeHu: data.xuan_ze_ke_hu_,
-              fuJian: data.fu_jian_
-						}
-						if (this.typeValue == '2' || this.typeValue == '4') {
-							this.getTaskId(data.id_)
-						}
-					}
-				})
-			},
-			getFileList(ids) {
-				this.$uploades.getFilesList(ids, this).then(res => {
-					this.fuJianShangChuanArray = res
-				})
-			},
-			onSubmit() {
-				if (!this.getYanZheng()) {
-					return
-				}
-				let tmpArray = []
-				this.fuJianShangChuanArray.forEach((item) => {
-					tmpArray.push(item.id)
-				})
+      this.$common.request('sql', sql).then(res => {
+        if (res.state === 200) {
+          const data = res.variables.data[0]
+          this.form = {
+            id: data.id_,
+            xuanZeKeHu: data.xuan_ze_ke_hu_,
+            biaoDanBianHao: data.biao_dan_bian_hao,
+            buMenName: data.xuan_ze_ke_hu_,
+            keHuDanWeiMin: data.ke_hu_dan_wei_min,
+            keHuLianXiRen: data.ke_hu_lian_xi_ren,
+            weiTuoDanHao: data.wei_tuo_dan_hao_,
+            lianXiDianHua: data.lian_xi_dian_hua_,
+            yangPinMingCheng: data.yang_pin_ming_che,
+            yangPinBianHao: data.yang_pin_bian_hao,
+            yangPinLeiXing: data.yang_pin_lei_xing,
+            baoGaoBianHao: data.bao_gao_bian_hao_,
+            gouTongLeiXing: data.gou_tong_lei_xing,
+            gouTongNeiRong: data.gou_tong_nei_rong,
+            keHu: data.ke_hu_,
+            gouTongQueDingNei: data.gou_tong_que_ding,
+            leiXing: data.lei_xing_,
+            bianZhiShiJian: data.bian_zhi_shi_jian,
+            gouTongRiQi: data.gou_tong_ri_qi_,
+            yongHuYouXiang: data.yong_hu_you_xiang,
+            gouTongRenYuan: data.gou_tong_ren_yuan,
+            fuJian: data.fu_jian_
+          }
+          if (this.typeValue === '2' || this.typeValue === '4') {
+            this.getTaskId(data.id_)
+          }
+        }
+      })
+    },
+    getFileList(ids) {
+      this.$uploades.getFilesList(ids, this).then(res => {
+        this.fuJianShangChuanArray = res
+      })
+    },
+    onSubmit() {
+      if (!this.getYanZheng()) {
+        return
+      }
+      const tmpArray = []
+      this.fuJianShangChuanArray.forEach(item => {
+        tmpArray.push(item.id)
+      })
 
-				let info = this.$store.getters.userInfo
-				let useId = info.user.id
-				let detpId = info.employee.positions
-				let para = {
-					"parameters": [{
-							"key": "defId",
-							"value": "1056942070293331968"
-						},
-						{
-							"key": "version",
-							"value": "0"
-						},
-						{
-							"key": "data",
-							"value": ""
-						}
-					]
-				}
-				this.form.fuJian = tmpArray.join(",")
-				this.form.bianZhiRen = useId
-				this.form.bianZhiShiJian = this.$methCommon.time(16)
-				// this.form.bianZhiBuMen = this.mainPosition.id || detpId
-				this.form.bianZhiBuMen =  detpId
-        
-				this.form.shiFouGuoShen = "已编制"
-				this.form.diDian = this.level.second
-				this.form.xuanZeKeHu = useId
-				para.parameters[2].value = JSON.stringify(this.form)
-				let that = this
-        
-				findFormJsonByBo(para).then(res => {
-					if (res.data.state == 200) {
-						this.$toast.success('提交成功!')
-						setTimeout(() => {
-							this.getPageA()
-						}, 1000);
-					}
-				}).catch((err) => {
+      const info = this.$store.getters.userInfo
+      const useId = info.user.id
+      const detpId = info.employee.positions
+      const para = {
+        parameters: [
+          {
+            key: 'defId',
+            value: '1056942070293331968'
+          },
+          {
+            key: 'version',
+            value: '0'
+          },
+          {
+            key: 'data',
+            value: ''
+          }
+        ]
+      }
+      this.form.fuJian = tmpArray.join(',')
+      this.form.bianZhiRen = useId
+      this.form.bianZhiShiJian = this.$methCommon.time(16)
+      // this.form.bianZhiBuMen = this.mainPosition.id || detpId
+      this.form.bianZhiBuMen = detpId
 
-				});
-			},
-			onAgree(shiFouGuoShen, opinion, type) {
-				if (this.typeValue !== '2' && !this.getYanZheng()) {
-					return
-				}
-				let info = this.$store.getters.userInfo
-				let useId = info.user.id
-				let detpId = info.employee.positions
-				let tmpArray = []
-				this.fuJianShangChuanArray.forEach((item) => {
-					tmpArray.push(item.id)
-				})
-				this.form.fuJian = tmpArray.join(",")
-				this.form.shiFouGuoShen = shiFouGuoShen
-				this.form.diDian = this.level.second
-				this.form.shiFouGuoShen = shiFouGuoShen
-				let editData = {
-					data: JSON.stringify(this.form),
-					opinion: opinion,
-					taskId: this.taskId
-				}
-				agree(editData).then(res => {
-					if (res.state == 200) {
+      this.form.shiFouGuoShen = '已编制'
+      this.form.diDian = this.level.second
+      this.form.xuanZeKeHu = useId
+      para.parameters[2].value = JSON.stringify(this.form)
+      const that = this
 
-						if (this.typeValue == '2') {
-							setTimeout(() => {
-								this.getPath(this.id)
-							}, 1000)
-						} else {
-              this.$toast.success(type + '成功!')
-							this.getPageA()
-						}
+      findFormJsonByBo(para)
+        .then(res => {
+          if (res.data.state === 200) {
+            that.$toast.success('提交成功!')
+            setTimeout(() => {
+              that.closePop()
+            }, 1000)
+          }
+        })
+        .catch(() => {})
+    },
+    onAgree(shiFouGuoShen, opinion, type) {
+      if (this.typeValue !== '2' && !this.getYanZheng()) {
+        return
+      }
+      // const info = this.$store.getters.userInfo
+      // const useId = info.user.id
+      // const detpId = info.employee.positions
+      const tmpArray = []
+      this.fuJianShangChuanArray.forEach(item => {
+        tmpArray.push(item.id)
+      })
+      this.form.fuJian = tmpArray.join(',')
+      this.form.shiFouGuoShen = shiFouGuoShen
+      this.form.diDian = this.level.second
+      this.form.shiFouGuoShen = shiFouGuoShen
+      const editData = {
+        data: JSON.stringify(this.form),
+        opinion: opinion,
+        taskId: this.taskId
+      }
+      agree(editData).then(res => {
+        if (res.state === 200) {
+          if (this.typeValue === '2') {
+            setTimeout(() => {
+              this.getPath(this.id)
+            }, 1000)
+          } else {
             this.$toast.success(type + '成功!')
-						setTimeout(() => {
-							this.getPageA()
-						}, 1000);
-
-					} else {
-            this.$toast.fail(type+'异常!')
-					}
-				});
-
-			},
-			//生成快照
-			getPath(id) {
-				let org = this.level.first
-
-				let url = this.$common.getRequest.downloadReport('咨询活动/客户沟通记录表.rpx', `id_=${id}&org_=${org}`)
-				let data = {
-					url,
-					name: '用户沟通记录表' + this.$methCommon.time(19),
-					type: 'pdf'
-				}
-				snapshot(data).then(res => {
-					let result = res.data
-					if (result.state == 200) {
-						this.updateData(id, result.data.id)
-					}
-
-				})
-			},
-			updateData(id, fileId) {
-				let pp = {
-					updList: [{
-						where: {
-							id_: id
-						},
-						param: {
-							kuai_zhao_: fileId,
-							shi_fou_guo_shen_: '已完成'
-						}
-					}],
-					tableName: "t_khgtjlb"
-				}
-				let data = this.$sig(pp)
-				this.$common.request('update', data).then(res => {
-					this.$methCommon.getPrompt('提交成功', 'success')
-					setTimeout(() => {
-						this.getPageA()
-					}, 1000);
-				})
-			},
-			getYanZheng() {
-				let suList = ['keHuLianXiRen', 'keHuDanWeiMin', 'lianXiDianHua', 'yongHuYouXiang', 'weiTuoDanHao', 'gouTongNeiRong']
-				let suListName = ['用户姓名', '用户单位', '联系电话', '用户邮箱', '沟通事项', '沟通内容']
-				for (let item in suList) {
-					if (!this.form[suList[item]]) {
-            this.$toast({
-              duration: 2000, // 持续展示 toast
-              message: '请输入' + suListName[item]
-            })
-						return false
-					}
-				}
-
-				let selList = ['gouTongRiQi', 'gouTongLeiXing']
-				let selListName = ['沟通时间', '沟通类型']
-				for (let item in selList) {
-					if (!this.form[selList[item]]) {
-            this.$toast({
-              duration: 2000, // 持续展示 toast
-              message: '请选择' + selListName[item]
-            })
-						return false
-					}
-				}
+            this.closePop()
+          }
+          this.$toast.success(type + '成功!')
+          setTimeout(() => {
+            this.closePop()
+          }, 1000)
+        } else {
+          this.$toast.fail(type + '异常!')
+        }
+      })
+    },
+    // 生成快照
+    getPath(id) {
+      const org = this.level.first
 
-				if (!this.form.keHu) {
+      const url = this.$common.getRequest.downloadReport(
+        '咨询活动/客户沟通记录表.rpx',
+        `id_=${id}&org_=${org}`
+      )
+      const data = {
+        url,
+        name: '用户沟通记录表' + this.$methCommon.time(19),
+        type: 'pdf'
+      }
+      snapshot(data).then(res => {
+        const result = res.data
+        if (result.state === 200) {
+          this.updateData(id, result.data.id)
+        }
+      })
+    },
+    updateData(id, fileId) {
+      const pp = {
+        updList: [
+          {
+            where: {
+              id_: id
+            },
+            param: {
+              kuai_zhao_: fileId,
+              shi_fou_guo_shen_: '已完成'
+            }
+          }
+        ],
+        tableName: 't_khgtjlb'
+      }
+      const data = this.$sig(pp)
+      this.$common.request('update', data).then(res => {
+        this.$methCommon.getPrompt('提交成功', 'success')
+        setTimeout(() => {
+          this.closePop()
+        }, 1000)
+      })
+    },
+    getYanZheng() {
+      const suList = [
+        'keHuLianXiRen',
+        'keHuDanWeiMin',
+        'lianXiDianHua',
+        'yongHuYouXiang',
+        'weiTuoDanHao',
+        'gouTongNeiRong'
+      ]
+      const suListName = [
+        '用户姓名',
+        '用户单位',
+        '联系电话',
+        '用户邮箱',
+        '沟通事项',
+        '沟通内容'
+      ]
+      for (const item in suList) {
+        if (!this.form[suList[item]]) {
           this.$toast({
             duration: 2000, // 持续展示 toast
-            message: '请填写签名'
+            message: '请输入' + suListName[item]
           })
-					return false
-				}
+          return false
+        }
+      }
 
-				if (this.form.gouTongLeiXing == '其它' && !this.form.qiTa) {
+      const selList = ['gouTongRiQi', 'gouTongLeiXing']
+      const selListName = ['沟通时间', '沟通类型']
+      for (const item in selList) {
+        if (!this.form[selList[item]]) {
           this.$toast({
             duration: 2000, // 持续展示 toast
-            message: '请填写其他类型'
+            message: '请选择' + selListName[item]
           })
-					return false
-				}
+          return false
+        }
+      }
 
-				return true
-			},
-			//根据委托单id查询 taskId
-			getTaskId(id) {
-				let sql = ``
-				if (this.typeValue == '2') {
-					sql =
-						`select TASK_ID_,PROC_INST_ID_ from ibps_bpm_tasks where NAME_ = '确认' and NODE_ID_ = 'Activity_02lroj1' and PROC_DEF_KEY_ = 'Process_0pjp1fy' and EXEC_ID_ = (select PROC_INST_ID_ from act_ru_execution where ACT_ID_ = 'Activity_02lroj1' and BUSINESS_KEY_ = '${id}') ORDER BY CREATE_TIME_ desc`
-				} else if (this.typeValue == '4') {
-					sql =
-						`select TASK_ID_,PROC_INST_ID_ from ibps_bpm_tasks where NAME_ = '沟通' and NODE_ID_ = 'Activity_0qy1dd7' and PROC_DEF_KEY_ = 'Process_0pjp1fy' and EXEC_ID_ = (select PROC_INST_ID_ from act_ru_execution where ACT_ID_ = 'Activity_0qy1dd7' and BUSINESS_KEY_ = '${id}') ORDER BY CREATE_TIME_ desc`
-				}
-				this.$common.request('sql', sql).then(res => {
-					if (res.state == 200) {
-						let result = res.variables.data[0]
-						this.taskId = result.TASK_ID_
+      if (!this.form.keHu) {
+        this.$toast({
+          duration: 2000, // 持续展示 toast
+          message: '请填写签名'
+        })
+        return false
+      }
 
-						this.getProcInstId(result.PROC_INST_ID_)
-					}
-				})
-			},
-			//根据委托单id查询 taskId
-			getProcInstId(id) {
-				let sql =
-					`select OPTION_ from ibps_bpm_oper_log where PROC_INST_ID_ = '${id}'   order by create_time_ desc  limit 1`
-				this.$common.request('sql', sql).then(res => {
-					if (res.data.state == 200) {
-						let result = res.data.variables.data[0]
-						this.option = result.OPTION_
-					}
-				})
-			},
-			getShow() {
-				this.$refs['picker'].show();
-			},
-			getPageA() {
-				let pages = getCurrentPages()
-				let prevPage = pages[pages.length - 2]
-				prevPage.$vm.getValue()
-				// uni.navigateBack({
-				// 	dalta: 1
-				// })
-			},
-			uploadClick(item) {
-				if (/^(pdf|png|jpg|jpeg|gif)$/.test(item.ext)) {
-					// uni.navigateTo({
-					// 	url: `/pages/fileView/fileView?id=${item.id}&ext=${item.ext}`
-					// })
-				} else {
-					this.$uploades.download(item.id, item.name, this)
-				}
-			},
-			//退回原因
-			getBack() {
-				this.content = this.option
-				this.backShow = true
-			},
-			cancel() {
-				this.backShow = false
-			},
-      formatter(type, val) {
-        if (type === 'year') {
-          return val + '年';
-        }
-        if (type === 'month') {
-          return val + '月';
+      if (this.form.gouTongLeiXing === '其它' && !this.form.qiTa) {
+        this.$toast({
+          duration: 2000, // 持续展示 toast
+          message: '请填写其他类型'
+        })
+        return false
+      }
+
+      return true
+    },
+    // 根据委托单id查询 taskId
+    getTaskId(id) {
+      let sql = ``
+      if (this.typeValue === '2') {
+        sql = `select TASK_ID_,PROC_INST_ID_ from ibps_bpm_tasks where NAME_ = '确认' and NODE_ID_ = 'Activity_02lroj1' and PROC_DEF_KEY_ = 'Process_0pjp1fy' and EXEC_ID_ = (select PROC_INST_ID_ from act_ru_execution where ACT_ID_ = 'Activity_02lroj1' and BUSINESS_KEY_ = '${id}') ORDER BY CREATE_TIME_ desc`
+      } else if (this.typeValue === '4') {
+        sql = `select TASK_ID_,PROC_INST_ID_ from ibps_bpm_tasks where NAME_ = '沟通' and NODE_ID_ = 'Activity_0qy1dd7' and PROC_DEF_KEY_ = 'Process_0pjp1fy' and EXEC_ID_ = (select PROC_INST_ID_ from act_ru_execution where ACT_ID_ = 'Activity_0qy1dd7' and BUSINESS_KEY_ = '${id}') ORDER BY CREATE_TIME_ desc`
+      }
+      this.$common.request('sql', sql).then(res => {
+        if (res.state === 200) {
+          const result = res.variables.data[0]
+          this.taskId = result.TASK_ID_
+
+          this.getProcInstId(result.PROC_INST_ID_)
         }
-        if (type === 'day') {
-          return val + '日';
+      })
+    },
+    // 根据委托单id查询 taskId
+    getProcInstId(id) {
+      const sql = `select OPTION_ from ibps_bpm_oper_log where PROC_INST_ID_ = '${id}'   order by create_time_ desc  limit 1`
+      this.$common.request('sql', sql).then(res => {
+        if (res.state === 200) {
+          const result = res.variables.data[0]
+          this.option = result.OPTION_
         }
-        return val;
+      })
+    },
+    getShow() {
+      this.$refs['picker'].show()
+    },
+    getPageA() {
+      // const pages = getCurrentPages()
+      // const prevPage = pages[pages.length - 2]
+      // prevPage.$vm.getValue()
+      // uni.navigateBack({
+      // 	dalta: 1
+      // })
+    },
+    uploadClick(item) {
+      if (/^(pdf|png|jpg|jpeg|gif)$/.test(item.ext)) {
+        // uni.navigateTo({
+        // 	url: `/pages/fileView/fileView?id=${item.id}&ext=${item.ext}`
+        // })
+      } else {
+        this.$uploades.download(item.id, item.name, this)
       }
+    },
+    // 退回原因
+    getBack() {
+      this.content = this.option
+      this.backShow = true
+      this.$dialog
+        .alert({
+          title: '退回原因',
+          message: this.option,
+          theme: 'round-button',
+          confirmButtonColor: '#1989fa'
+        })
+        .then(() => {
+          // on close
+        })
+    },
+    cancel() {
+      this.backShow = false
+    },
+    formatter(type, val) {
+      if (type === 'year') {
+        return val + '年'
+      }
+      if (type === 'month') {
+        return val + '月'
+      }
+      if (type === 'day') {
+        return val + '日'
+      }
+      return val
     }
   }
+}
 </script>
 <style lang="scss" scoped>
-  ::v-deep .van-cell__title {
-    width: 65%;
+::v-deep .van-cell__title {
+  width: 65%;
 
-    .van-cell__label {
-      overflow-wrap: break-word;
-    }
+  .van-cell__label {
+    overflow-wrap: break-word;
   }
-  .sectionBox {
-		display: flex;
-		align-items: center;
-		margin-bottom: 2px;
-		font-size: 14px;
-		color: rgba(128, 138, 135, .9);
-
-		.left {
-			width: 90px;
+}
+.sectionBox {
+  display: flex;
+  align-items: center;
+  margin-bottom: 2px;
+  font-size: 14px;
+  color: rgba(128, 138, 135, 0.9);
 
-		}
-	}
-  .sectionBox::before {
-    content: '';
-    width: 5px;
-    height: 14px;
-    border-radius: 2px;
-    margin-right: 5px;
+  .left {
+    width: 90px;
   }
-  .btn-back-color {
-		background-color: #30c2bd !important;
-    border: none;
-	}
-  .btn-sty {
-    padding: 0 13px;
-    border-radius: 5px;
-  }
-  .u-m-r-15 {
-    margin-right: 8px !important;
-  }
-  .verticalLine {
-    color: #000;
-    font-size: 13px;
-    margin-bottom: 20px;
-  }
-  .verticalLine::before {
-    content: '';
-    width: 5px;
-    height: 14px;
-    background-color: #2979ff;
-    border-radius: 2px;
-    margin-right: 5px;
-  }
-  .suspensionBtn {
-    width: 80px;
-    height: 80px;
-    position: fixed;
-    top: 75%;
-    right: 2%;
-    img {
-      width: 100%;
-      height: 100%;
-    }
-  }
-  .backgroundSty {
+}
+.sectionBox::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+.btn-back-color {
+  background-color: #1989fa !important;
+  border: none;
+}
+.btn-sty {
+  padding: 0 13px;
+  border-radius: 5px;
+}
+.u-m-r-15 {
+  margin-right: 8px !important;
+}
+.verticalLine {
+  color: #000;
+  font-size: 13px;
+  margin-bottom: 20px;
+}
+.verticalLine::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  background-color: #2979ff;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+.suspensionBtn {
+  width: 80px;
+  height: 80px;
+  position: fixed;
+  top: 75%;
+  right: 2%;
+  img {
+    width: 100%;
     height: 100%;
-    background-color: #fff;
-  }
-  .cu-form-group .title {
-		min-width: 180px;
-	}
-  .padding{
-    padding-bottom: 15px;
-    padding-top: 5px;
-    background-color: #f8f8f8;
-    display: flex;
-    justify-content: center;
   }
-	.btn {
-		width: 90%;
-    padding: 15px;
-    border-radius: 5px;
-	}
+}
+.backgroundSty {
+  height: 100%;
+  background-color: #fff;
+}
+.cu-form-group .title {
+  min-width: 180px;
+}
+.padding {
+  padding-bottom: 15px;
+  padding-top: 5px;
+  background-color: #f8f8f8;
+  display: flex;
+  justify-content: center;
+}
+.btn {
+  width: 90%;
+  padding: 15px;
+  border-radius: 5px;
+}
 
-	.fileBox {
-		line-height: 50px;
-		color: #888888;
-		display: flex;
-		align-items: center;
-		justify-content: space-between;
-		border: 1px solid #DDDDDD;
-		border-radius: 8px;
-		padding: 5px;
-		margin-top: 10px;
-	}
+.fileBox {
+  line-height: 50px;
+  color: #888888;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  border: 1px solid #dddddd;
+  border-radius: 8px;
+  padding: 5px;
+  margin-top: 10px;
+}
 
-	.u-update-content {
-		font-size: 26px;
-		// color: $u-content-color;
-		line-height: 1.7;
-		padding: 30px;
-	}
-  .verticalLine {
-    display: flex;
-    align-items: center;
-    justify-content: center;
-    font-size: 14px;
-    color: rgb(51, 51, 51);
-  }
-  .verticalLine::before {
-    content: '';
-    width: 5px;
-    height: 14px;
-    background-color: #2979ff;
-    border-radius: 2px;
-    margin-right: 5px;
-  }
-  .scrollView {
-    overflow-y: scroll;
-    height: 95%;
-  }
-  .scrollView::-webkit-scrollbar{
-    display: none;
-  }
-  ::v-deep .yonghu .van-cell--borderless {
-    padding-left: 8px;
-  }
-  ::v-deep .yonghu .van-cell .van-field__label {
-    display: flex;
-    align-items: center;
-    justify-content: left;
-    font-size: 14px;
-    color: rgb(51, 51, 51);
-  }
-  ::v-deep .yonghu .van-cell .van-field__label::before {
-    content: '';
-    width: 5px;
-    height: 14px;
-    background-color: #2979ff;
-    border-radius: 2px;
-    margin-right: 5px;
-  }
-</style>
+.u-update-content {
+  font-size: 26px;
+  // color: $u-content-color;
+  line-height: 1.7;
+  padding: 30px;
+}
+.verticalLine {
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  font-size: 14px;
+  color: rgb(51, 51, 51);
+}
+.verticalLine::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  background-color: #2979ff;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+.scrollView {
+  overflow-y: scroll;
+  height: 95%;
+}
+.scrollView::-webkit-scrollbar {
+  display: none;
+}
+::v-deep .yonghu .van-cell--borderless {
+  padding-left: 8px;
+}
+::v-deep .yonghu .van-cell .van-field__label {
+  display: flex;
+  align-items: center;
+  justify-content: left;
+  font-size: 14px;
+  color: rgb(51, 51, 51);
+}
+::v-deep .yonghu .van-cell .van-field__label::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  background-color: #2979ff;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+</style>

+ 2 - 2
src/views/platform/bpmn/communication/communicationList.vue

@@ -198,11 +198,11 @@
 					itemSql = itemSql + `and gou_tong_lei_xing = '${gtlx.value}'`
 				}
         let bdbh = params.parameters.find( i => i.key === 'biao_dan_bian_hao' ) || ''
-				if ( bdbh && bdbh.value != '全部') {
+				if ( bdbh && bdbh.value != '') {
 					itemSql = itemSql + `and biao_dan_bian_hao like '%${bdbh.value}%'`
 				}
         let khlxr = params.parameters.find( i => i.key === 'ke_hu_lian_xi_ren' ) || ''
-				if ( khlxr && khlxr.value != '全部') {
+				if ( khlxr && khlxr.value != '') {
 					itemSql = itemSql + `and ke_hu_lian_xi_ren like '%${khlxr.value}%'`
 				}
         let two = params.parameters.find( i => i.key === 'two' ) || ''

+ 18 - 0
src/views/platform/bpmn/complaint/complaint.json

@@ -0,0 +1,18 @@
+{
+	"touSuFangShiList": [{
+		"name": "电话"
+	}, {
+		"name": "电子邮件"
+	}, {
+		"name": "书面"
+	}, {
+		"name": "口头"
+	}],
+	"touSuFenLeiList": [{
+		"name": "患者"
+	}, {
+		"name": "临床医护"
+	}, {
+		"name": "其它"
+	}]
+}

+ 967 - 0
src/views/platform/bpmn/complaint/complaint.vue

@@ -0,0 +1,967 @@
+<template>
+  <van-overlay class="backgroundSty" z-index="2002" :show="showPop">
+    <div style="height:5%">
+      <van-sticky>
+        <van-nav-bar
+          :title="
+            '投诉 ' +
+              (typeValue == '1'
+                ? '编制'
+                : typeValue == '3'
+                ? '修改'
+                : typeValue == '2'
+                ? '详情'
+                : '')
+          "
+          :right-text="typeValue == '3' ? '退回原因' : ''"
+          @click-left="closePop()"
+          @click-right="getBack()"
+        >
+          <template #left>
+            <van-icon name="cross" class="ibps-nav-bar__close-icon" />
+          </template>
+        </van-nav-bar>
+      </van-sticky>
+    </div>
+    <div class="scrollView">
+      <van-form @submit="onSubmit">
+        <van-field
+          v-model="form.touSuRen"
+          required
+          label="投诉者:"
+          placeholder="请输入投诉者"
+          label-width="6em"
+          clearable
+          :readonly="typeValue == '2' ? true : false"
+        />
+        <van-field
+          v-model="form.touSuDanWei"
+          required
+          label="投诉单位:"
+          placeholder="请输入投诉单位"
+          label-width="6em"
+          clearable
+          :readonly="typeValue == '2' ? true : false"
+        />
+        <van-field
+          v-model="form.lianXiDianHua"
+          required
+          label="联系电话:"
+          placeholder="请输入联系电话"
+          label-width="6em"
+          clearable
+          :rules="[
+            {
+              validator: $common.getRequest.checkPhone,
+              message: '手机号格式错误'
+            }
+          ]"
+          :readonly="typeValue == '2' ? true : false"
+        />
+        <van-field
+          v-model="form.touSuBuMenJiRenYu"
+          required
+          label="投诉部门及人员:"
+          placeholder="请输入投诉部门及人员"
+          label-width="8em"
+          clearable
+          :readonly="typeValue == '2' ? true : false"
+        />
+        <van-field
+          name="radio"
+          required
+          label="投诉分类:"
+          placeholder="请选择投诉类型"
+          label-width="6em"
+          :value="form.touSuFenLei"
+          :readonly="typeValue == '2' ? true : false"
+        >
+          <template #input>
+            <van-radio-group
+              v-if="typeValue != '2'"
+              v-model="form.touSuFenLei"
+              direction="horizontal"
+            >
+              <van-radio
+                v-for="(it, index) in touSuFenLeiList"
+                :key="index"
+                :name="it.name"
+                shape="square"
+                class="lineSty"
+              >
+                {{ it.name }}
+              </van-radio>
+            </van-radio-group>
+            <div v-else>{{ form.touSuFenLei }}</div>
+          </template>
+        </van-field>
+        <van-field
+          v-if="form.touSuFenLei == '其它'"
+          v-model="form.qiTaFenLei"
+          required
+          label="其它分类:"
+          placeholder="请输入其它分类"
+          label-width="6em"
+          clearable
+          :readonly="typeValue == '2' ? true : false"
+        />
+        <van-field
+          required
+          label="投诉方式:"
+          label-width="6em"
+          :value="form.touSuFangShi"
+          :readonly="typeValue == '2' ? true : false"
+        >
+          <template #input>
+            <van-radio-group
+              v-if="typeValue != '2'"
+              v-model="form.touSuFangShi"
+              direction="horizontal"
+            >
+              <van-radio
+                v-for="(it, index) in touSuFangShiList"
+                :key="index"
+                :name="it.name"
+                shape="square"
+                class="lineSty"
+              >
+                {{ it.name }}
+              </van-radio>
+            </van-radio-group>
+            <div v-else>{{ form.touSuFangShi }}</div>
+          </template>
+        </van-field>
+      </van-form>
+      <van-cell-group>
+        <div
+          class="verticalLine"
+          style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
+        >
+          投诉内容
+        </div>
+        <van-field
+          v-model="form.touSuNeiRong"
+          autosize
+          type="textarea"
+          label=""
+          placeholder="投诉内容"
+          label-width="0"
+          clearable
+          :readonly="typeValue == '2' ? true : false"
+        />
+      </van-cell-group>
+
+      <ibps-uploader
+        v-model="form.fuJian"
+        label="上传附件"
+        download
+        placeholder="请上传附件"
+        :have-padding="false"
+        multiple
+        clearable
+        :readonly="typeValue == '2' ? true : false"
+      />
+      <div v-if="typeValue == '2'" class="spei">
+        <van-cell-group>
+          <div
+            class="verticalLine"
+            style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
+          >
+            审核
+          </div>
+          <van-field
+            :value="form.touSuQueRen | getValue"
+            autosize
+            type="textarea"
+            label="投诉受理审核:"
+            label-width="7em"
+            clearable
+            :readonly="typeValue != 2"
+            class="typeStyle"
+          />
+        </van-cell-group>
+
+        <van-cell-group>
+          <div
+            class="verticalLine"
+            style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
+          >
+            调查
+          </div>
+          <van-field
+            :value="form.shiShiDiaoChaQing | getValue"
+            autosize
+            type="textarea"
+            label="事实调查情况:"
+            label-width="7em"
+            clearable
+            :readonly="typeValue != 2"
+            class="typeStyle"
+          />
+          <ibps-uploader
+            v-model="form.diaoChaQingKuangF"
+            class="paddingNone"
+            label="调查附件"
+            download
+            :have-padding="false"
+            multiple
+            clearable
+            :readonly="typeValue == '2' ? true : false"
+          />
+          <van-field
+            :value="form.chuLiCuoShi | getValue"
+            autosize
+            class="typeStyle"
+            type="textarea"
+            label="处理措施:"
+            label-width="5em"
+            clearable
+            :readonly="typeValue != 2"
+          />
+        </van-cell-group>
+        <van-cell-group>
+          <div
+            class="verticalLine"
+            style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
+          >
+            确认
+          </div>
+          <van-field
+            :value="form.chuLiJieGuoQueRen | getValue"
+            autosize
+            class="typeStyle"
+            type="textarea"
+            label="处理结果确认:"
+            label-width="7em"
+            clearable
+            :readonly="typeValue != 2"
+          />
+        </van-cell-group>
+        <van-cell-group>
+          <div
+            class="verticalLine"
+            style="width:8em;text-align:left;padding: 1em 0 1em 0.5em;margin: 0;"
+          >
+            通知
+          </div>
+          <van-field
+            :value="form.chuLiJieGuoShiFou | getValue"
+            autosize
+            type="textarea"
+            label="处理结果是否通知当事人:"
+            label-width="12em"
+            clearable
+            :readonly="typeValue != 2"
+            class="typeStyle"
+          />
+          <ibps-uploader
+            v-model="form.touSuFangShiQiTa"
+            class="paddingNone"
+            label="通知附件:"
+            download
+            :have-padding="false"
+            multiple
+            clearable
+            :readonly="typeValue == '2' ? true : false"
+          />
+          <van-field
+            :value="form.touSuRenQianMing | getValue"
+            autosize
+            class="typeStyle"
+            type="textarea"
+            label="通知内容:"
+            label-width="5em"
+            clearable
+            :readonly="typeValue != 2"
+          />
+        </van-cell-group>
+      </div>
+
+      <div class="padding flex flex-direction">
+        <van-button
+          v-if="id == ''"
+          type="success"
+          class="btn btn-back-color"
+          @click="onSubmit"
+          >提交</van-button
+        >
+        <van-button
+          v-if="typeValue == '3'"
+          type="success"
+          class="btn btn-back-color"
+          @click="getArgee()"
+        >
+          修改
+        </van-button>
+      </div>
+    </div>
+  </van-overlay>
+</template>
+<script>
+import random from '@/mixins/random'
+import bpmnStatus from '@/mixins/bpmnStatus'
+import IbpsUploader from '@/business/platform/file/uploader'
+import {
+  getNextIdByAlias,
+  findFormJsonByBo
+} from '@/api/platform/form/transfer'
+import { agree } from '@/api/platform/bpmn/bpmTask'
+import test from './complaint.json'
+
+export default {
+  components: {
+    IbpsUploader
+  },
+  filters: {
+    getValue(value) {
+      if (value && value !== '') {
+        return value
+      } else {
+        return '/'
+      }
+    },
+    getNotVa(value) {
+      if (!value) {
+        return '/'
+      }
+    }
+  },
+  mixins: [random, bpmnStatus],
+  props: {
+    showPop: {
+      type: Boolean,
+      default: false
+    },
+    typeValue: {
+      type: String,
+      default: '1'
+    },
+    id: {
+      type: String,
+      default: ''
+    }
+  },
+  data() {
+    const useId = this.$store.getters.userId
+    return {
+      useId,
+      show: this.showPop,
+      sheetShow: false,
+      option2: '',
+      option3: '',
+      option4: '',
+      content: '',
+
+      buMenList: [],
+      fuJianShangChuanArray: [],
+      popupShow: false,
+
+      type: '',
+      form: {
+        id: '',
+        diDian: '',
+        bianZhiBuMen: '',
+        bianZhiRen: '',
+        bianZhiShiJian: '',
+        touSuRen: '',
+        lianXiDianHua: '',
+        touSuDanWei: '',
+        touSuBuMenJiRenYu: '',
+        touSuFenLei: '患者',
+        touSuFangShi: '电话',
+        touSuNeiRong: '',
+        fuJian: '',
+        touSuRiQi: '',
+        touSuQueRen: '',
+        touSuFenLeiQiTa: '',
+        shiShiDiaoChaQing: '',
+        diaoChaQingKuangF: '',
+        chuLiCuoShi: '',
+        chuLiJieGuoQueRen: '',
+        chuLiJieGuoShiFou: '',
+        touSuRenQianMing: '',
+        touSuFangShiQiTa: '',
+        qiTaFenLei: ''
+      },
+      list: [
+        {
+          text: '投诉'
+        },
+        {
+          text: '检验项目'
+        },
+        {
+          text: '危机值报告'
+        },
+        {
+          text: '口头报告结果'
+        },
+        {
+          text: '延迟报告'
+        },
+        {
+          text: '其它'
+        }
+      ],
+      touSuFangShiQiTaList: [],
+      diaoChaQingKuangFList: [],
+      touSuFenLeiList: test.touSuFenLeiList,
+      touSuFangShiList: test.touSuFangShiList,
+      timeShow: false,
+      yangPinList: [],
+      option: '',
+      orgId: '',
+      backShow: false,
+      level: null,
+      mainPosition: {
+        id: ''
+      },
+      xuanzeTime: null
+    }
+  },
+  computed: {
+    rightText() {
+      return this.checkMode
+        ? this.$t('common.button.cancel')
+        : this.$t('common.button.manage')
+    },
+    selectedIds() {
+      return this.checkedIds.join(',')
+    }
+  },
+  watch: {
+    showPop: {
+      handler: function(val, oldVal) {
+        if (val === true) {
+          this.form = {
+            id: '',
+            diDian: '',
+            bianZhiBuMen: '',
+            bianZhiRen: '',
+            bianZhiShiJian: '',
+            touSuRen: '',
+            lianXiDianHua: '',
+            touSuDanWei: '',
+            touSuBuMenJiRenYu: '',
+            touSuFenLei: '患者',
+            touSuFangShi: '电话',
+            touSuNeiRong: '',
+            fuJian: '',
+            touSuRiQi: '',
+            touSuQueRen: '',
+            touSuFenLeiQiTa: '',
+            shiShiDiaoChaQing: '',
+            diaoChaQingKuangF: '',
+            chuLiCuoShi: '',
+            chuLiJieGuoQueRen: '',
+            chuLiJieGuoShiFou: '',
+            touSuRenQianMing: '',
+            touSuFangShiQiTa: '',
+            qiTaFenLei: ''
+          }
+          this.level = this.$store.getters.level
+          const mainPosition = this.$store.getters.mainPosition
+          this.mainPosition = mainPosition
+
+          const info = this.$store.getters.userInfo
+          this.form.touSuRen = info.user.name
+          this.form.touSuDanWei = info.user.qq
+          this.form.lianXiDianHua = info.user.mobile
+          this.orgId = info.employee.positions
+          if (this.id && this.id !== '') {
+            this.getDe(this.id)
+          } else {
+            this.getTaskId(this.id)
+          }
+        }
+      },
+      immediate: true
+    }
+  },
+  created() {},
+  methods: {
+    closePop() {
+      this.$emit('updataSet', false)
+    },
+    toCheckMode() {
+      if (this.$utils.isEmpty(this.listData)) {
+        return
+      }
+      if (this.checkMode) {
+        this.showA = true
+        this.checkedIds = []
+      }
+      this.checkMode = !this.checkMode
+    },
+    actionSheetCallback(e) {
+      this.form.gouTongLeiXing = e.text
+      this.sheetShow = false
+    },
+    timeShowCallback(e) {
+      const nowDate = new Date(e.getTime() + 8 * 60 * 60 * 1000)
+      const time = nowDate
+        .toJSON()
+        .split('T')
+        .join(' ')
+        .substr(0, 16)
+      this.form.gouTongRiQi = time
+      this.timeShow = false
+    },
+    gouTongRiQiClick(e) {
+      this.timeShow = true
+    },
+    // 获取上传状态
+    select(file) {
+      this.$uploades.selectUpload(file).then(res => {
+        res.forEach(item => {
+          this.fuJianShangChuanArray.push(item)
+        })
+      })
+    },
+    // 删除
+    deleteMe(id) {
+      this.fuJianShangChuanArray = this.fuJianShangChuanArray.filter(
+        item => item.id !== id
+      )
+    },
+    // 获取上传进度
+    progress(e) {},
+    // 上传成功
+    success(file) {},
+    // 上传失败
+    fail(e) {},
+    // 弹出框显示
+    qianming(index) {
+      this.popupShow = true
+    },
+    // 清除签名
+    deqianming(index) {
+      this.form.keHu = ''
+    },
+    // 保存签名
+    save(val) {
+      this.form.keHu = val
+      this.popupShow = false
+    },
+    // 清除签名
+    clear(val) {
+      this.form.keHu = ''
+    },
+    /**
+     * 关闭签名弹窗
+     */
+    close() {
+      this.popupShow = false
+    },
+
+    // 获取样品编号
+    getGtbh(callback) {
+      const smsParams = {
+        alias: 'gtbh'
+      }
+      const this_ = this
+      getNextIdByAlias(smsParams).then(res => {
+        if (res.state === 200) {
+          const data = res.data
+          this_.form.biaoDanBianHao = data
+        }
+      })
+    },
+    getDe(id) {
+      const sql = `select a.*,b.name_ from t_tsclb a left join ibps_party_employee b on a.tou_su_fen_lei_qi = b.id_ where a.id_ =  '${id}'`
+      this.$common.request('sql', sql).then(res => {
+        if (res.state === 200) {
+          const data = res.variables.data[0]
+          this.form = {
+            id: data.id_,
+            diDian: data.di_dian_,
+            bianZhiBuMen: data.bian_zhi_bu_men_,
+            bianZhiRen: data.bian_zhi_ren_,
+            bianZhiShiJian: data.bian_zhi_shi_jian,
+            touSuRen: data.tou_su_ren_,
+            lianXiDianHua: data.lian_xi_dian_hua_,
+            touSuDanWei: data.tou_su_dan_wei_,
+            touSuBuMenJiRenYu: data.tou_su_bu_men_ji_,
+            touSuFenLei: data.tou_su_fen_lei_,
+            touSuFangShi: data.tou_su_fang_shi_,
+            touSuNeiRong: data.tou_su_nei_rong_,
+            fuJian: data.fu_jian_,
+            touSuRiQi: data.tou_su_ri_qi_,
+            touSuQueRen: data.tou_su_que_ren_,
+            touSuFenLeiQiTa: data.tou_su_fen_lei_qi,
+            shiShiDiaoChaQing: data.shi_shi_diao_cha_,
+            diaoChaQingKuangF: data.diao_cha_qing_kua,
+            chuLiCuoShi: data.chu_li_cuo_shi_,
+            chuLiJieGuoQueRen: data.chu_li_jie_guo_qu,
+            chuLiJieGuoShiFou: data.chu_li_jie_guo_sh,
+            touSuRenQianMing: data.tou_su_ren_qian_m,
+            touSuFangShiQiTa: data.tou_su_fang_shi_q,
+            qiTaFenLei: data.qi_ta_fen_lei_
+          }
+        }
+      })
+    },
+    onSubmit() {
+      if (!this.getYanZheng()) {
+        return
+      }
+      const tmpArray = []
+      this.fuJianShangChuanArray.forEach(item => {
+        tmpArray.push(item.id)
+      })
+
+      const info = this.$store.getters.userInfo
+      const useId = info.user.id
+      const para = {
+        parameters: [
+          {
+            key: 'defId',
+            value: '1133803612284125184'
+          },
+          {
+            key: 'version',
+            value: '0'
+          },
+          {
+            key: 'data',
+            value: ''
+          }
+        ]
+      }
+      this.form.fuJian = tmpArray.join(',')
+      this.form.bianZhiRen = useId
+      this.form.bianZhiShiJian = this.$methCommon.time(16)
+      this.form.shiFouGuoShen = '已登记'
+      // this.form.bianZhiBuMen = this.mainPosition.id || this.orgId
+      this.form.bianZhiBuMen = this.orgId
+      this.form.diDian = this.level.second
+      para.parameters[2].value = JSON.stringify(this.form)
+      findFormJsonByBo(para)
+        .then(res => {
+          if (res.state === 200) {
+            this.$toast({
+              duration: 2000, // 持续展示 toast
+              message: '提交成功!'
+            })
+            setTimeout(() => {
+              this.closePop()
+            }, 1000)
+          }
+        })
+        .catch(() => {
+          // this.$methCommon.getPrompt('请求出现错误,请稍后再试', 'error')
+        })
+    },
+    // 修改
+    getArgee() {
+      if (!this.getYanZheng()) {
+        return
+      }
+      // uni.showLoading({
+      //   mask: true,
+      //   title: '加载中'
+      // })
+      const info = this.$store.getters.userInfo
+      const useId = info.user.id
+      const tmpArray = []
+      this.fuJianShangChuanArray.forEach(item => {
+        tmpArray.push(item.id)
+      })
+      this.form.fuJian = tmpArray.join(',')
+      this.form.touSuQueRen = ''
+      this.form.bianZhiRen = useId
+      this.form.bianZhiShiJian = this.$methCommon.time(16)
+      this.form.shiFouGuoShen = '已登记'
+      this.form.bianZhiBuMen = this.mainPosition.id || this.orgId
+      this.form.diDian = this.level.second
+      const editData = {
+        data: JSON.stringify(this.form),
+        opinion: '',
+        taskId: this.taskId
+      }
+      agree(editData)
+        .then(res => {
+          if (res.state === 200) {
+            // this.$methCommon.getPrompt('提交成功!')
+            // uni.hideLoading()
+            setTimeout(() => {
+              this.closePop()
+            }, 1000)
+          } else {
+            // this.$methCommon.getPrompt('提交异常', 'error')
+            // uni.hideLoading()
+          }
+        })
+        .catch(() => {
+          // this.$methCommon.getPrompt('提交异常', 'error')
+          // uni.hideLoading()
+        })
+    },
+    getYanZheng() {
+      const suList = [
+        'touSuRen',
+        'touSuDanWei',
+        'lianXiDianHua',
+        'touSuBuMenJiRenYu',
+        'touSuNeiRong'
+      ]
+      const suListName = [
+        '投诉者',
+        '投诉单位',
+        '联系电话',
+        '投诉部门及人员',
+        '投诉内容'
+      ]
+      for (const item in suList) {
+        if (!this.form[suList[item]]) {
+          this.$toast({
+            duration: 2000, // 持续展示 toast
+            message: '请输入' + suListName[item]
+          })
+          return false
+        }
+      }
+
+      if (!this.$common.getRequest.checkPhone(this.form.lianXiDianHua)) {
+        return false
+      }
+
+      return true
+    },
+    // 根据委托单id查询 taskId
+    getTaskId(id) {
+      const sql = `select TASK_ID_,PROC_INST_ID_ from ibps_bpm_tasks where NAME_ = '登记' and NODE_ID_ = 'Activity_0276m43' and PROC_DEF_KEY_ = 'Process_09j5fge' and EXEC_ID_ = (select PROC_INST_ID_ from act_ru_execution where ACT_ID_ = 'Activity_0276m43' and BUSINESS_KEY_ = '${id}') ORDER BY CREATE_TIME_ desc`
+      this.$common.request('sql', sql).then(res => {
+        if (res.state === 200) {
+          if (res.variables.data.length > 0) {
+            const result = res.variables.data[0]
+            if (result.TASK_ID_) {
+              this.taskId = result.TASK_ID_
+              this.getProcInstId(result.PROC_INST_ID_)
+            }
+          }
+        }
+      })
+    },
+    // 根据委托单id查询 taskId
+    getProcInstId(id) {
+      const sql = `select OPTION_ from ibps_bpm_oper_log where PROC_INST_ID_ = '${id}'   order by create_time_ desc  limit 1`
+      this.$common.request('sql', sql).then(res => {
+        if (res.state === 200) {
+          const result = res.variables.data[0]
+          this.option = result.OPTION_
+        }
+      })
+    },
+    getShow() {
+      this.$refs['picker'].show()
+    },
+    getPageA() {
+      // const pages = getCurrentPages()
+      // const prevPage = pages[pages.length - 2]
+      // prevPage.$vm.getValue()
+      // uni.navigateBack({
+      // 	dalta: 1
+      // })
+    },
+    uploadClick(item) {
+      if (/^(pdf|png|jpg|jpeg|gif)$/.test(item.ext)) {
+        // uni.navigateTo({
+        // 	url: `/pages/fileView/fileView?id=${item.id}&ext=${item.ext}`
+        // })
+      } else {
+        this.$uploades.download(item.id, item.name, this)
+      }
+    },
+    // 退回原因
+    getBack() {
+      this.content = this.option
+      this.backShow = true
+      this.$dialog
+        .alert({
+          title: '退回原因',
+          message: this.option,
+          theme: 'round-button',
+          confirmButtonColor: '#1989fa'
+        })
+        .then(() => {
+          // on close
+        })
+    },
+    cancel() {
+      this.backShow = false
+    },
+    formatter(type, val) {
+      if (type === 'year') {
+        return val + '年'
+      }
+      if (type === 'month') {
+        return val + '月'
+      }
+      if (type === 'day') {
+        return val + '日'
+      }
+      return val
+    }
+  }
+}
+</script>
+<style lang="scss" scoped>
+::v-deep .van-cell__title {
+  width: 65%;
+
+  .van-cell__label {
+    overflow-wrap: break-word;
+  }
+}
+.sectionBox {
+  display: flex;
+  align-items: center;
+  margin-bottom: 2px;
+  font-size: 14px;
+  color: rgba(128, 138, 135, 0.9);
+
+  .left {
+    width: 90px;
+  }
+}
+.sectionBox::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+.btn-back-color {
+  background-color: #1989fa !important;
+  border: none;
+}
+.btn-sty {
+  padding: 0 13px;
+  border-radius: 5px;
+}
+.u-m-r-15 {
+  margin-right: 8px !important;
+}
+.verticalLine {
+  color: #000;
+  font-size: 13px;
+  margin-bottom: 20px;
+}
+.verticalLine::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  background-color: #2979ff;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+.suspensionBtn {
+  width: 80px;
+  height: 80px;
+  position: fixed;
+  top: 75%;
+  right: 2%;
+  img {
+    width: 100%;
+    height: 100%;
+  }
+}
+.backgroundSty {
+  height: 100%;
+  background-color: #f8f8f8;
+}
+.cu-form-group .title {
+  min-width: 180px;
+}
+.padding {
+  padding-bottom: 15px;
+  padding-top: 5px;
+  background-color: #f8f8f8;
+  display: flex;
+  justify-content: center;
+}
+.btn {
+  width: 90%;
+  padding: 15px;
+  border-radius: 5px;
+}
+
+.fileBox {
+  line-height: 50px;
+  color: #888888;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  border: 1px solid #dddddd;
+  border-radius: 8px;
+  padding: 5px;
+  margin-top: 10px;
+}
+
+.u-update-content {
+  font-size: 26px;
+  // color: $u-content-color;
+  line-height: 1.7;
+  padding: 30px;
+}
+.verticalLine {
+  display: flex;
+  align-items: center;
+  // justify-content: center;
+  font-size: 14px;
+  color: rgb(51, 51, 51);
+}
+.verticalLine::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  background-color: #2979ff;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+.scrollView {
+  overflow-y: scroll;
+  height: 95%;
+}
+.scrollView::-webkit-scrollbar {
+  display: none;
+}
+.typeStyle {
+  padding-left: 0.5em;
+}
+.paddingNone {
+  padding: 0;
+}
+::v-deep .paddingNone .ibps-uploader {
+  padding-left: 0.5em;
+}
+::v-deep .typeStyle.van-cell::after {
+  border-bottom: 0px solid #fff;
+}
+::v-deep .yonghu .van-cell--borderless {
+  padding-left: 8px;
+}
+::v-deep .yonghu .van-cell .van-field__label {
+  display: flex;
+  align-items: center;
+  justify-content: left;
+  font-size: 14px;
+  color: rgb(51, 51, 51);
+}
+::v-deep .yonghu .van-cell .van-field__label::before {
+  content: '';
+  width: 5px;
+  height: 14px;
+  background-color: #2979ff;
+  border-radius: 2px;
+  margin-right: 5px;
+}
+.lineSty {
+  margin-top: 3px;
+  margin-bottom: 3px;
+}
+::v-deep .spei .van-cell-group {
+  margin-bottom: 10px;
+}
+</style>

+ 409 - 0
src/views/platform/bpmn/complaint/complaintList.vue

@@ -0,0 +1,409 @@
+<template>
+  <div :class="{'ibps-fixed-toolbar':checkMode}">
+    <van-sticky>
+      <van-nav-bar :title="generateTitle($route.name,$route.params.title||$route.meta.title)"
+        :left-text="$t('common.button.back')" left-arrow
+        @click-left="$router.push({ name: 'dashboard' })" />
+      <van-search v-model="twoParam" show-action placeholder="输入搜索的投诉者/投诉单位" @search="onSearch">
+        <template #action>
+          <van-icon name="filter-o" :class="{'ibps-active':stateActive}" @click="clickMoreSearch" />
+        </template>
+      </van-search>
+    </van-sticky>
+    <van-pull-refresh v-model="refreshing" @refresh="onRefresh">
+      <van-list v-model="loading" :finished="finished" @load="loadData">
+        <van-checkbox-group v-model="checkedIds">
+          <van-cell v-for="(item,index) in listData" :key="item.id+index" >
+            <div class="sectionBox verticalLine">
+							<div class="left ">投诉者:</div>
+							<div>{{item.tou_su_ren_}} </div>
+						</div>
+            <div class="sectionBox">
+							<div class="left">投诉单位:</div>
+							<div>{{item.tou_su_dan_wei_}} </div>
+						</div>
+						<div class="sectionBox">
+							<div class="left">投诉受理时间:</div>
+							<div>{{item.bian_zhi_shi_jian}} </div>
+						</div>
+						<div class="sectionBox">
+							<div class="left">投诉分类:</div>
+							<div>{{item.tou_su_fen_lei_}} </div>
+						</div>
+						<div class="sectionBox">
+							<div class="left">投诉方式:</div>
+							<div>{{item.tou_su_fang_shi_}} </div>
+						</div>
+						<div class="sectionBox">
+							<div class="left">状态:</div>
+							<div style="color: #7349ff;">
+								{{item.shi_fou_guo_shen_}}
+							</div>
+						</div>
+						<div style=" width: 100%; text-align: right; padding-top: 5rpx;padding-bottom: 0rpx;">
+							<!-- <van-button type="warning" size="small" @click="getGo(item.id_,'2')" class="u-m-r-15 btn-sty" v-if="item.lei_xing_ == '1' && item.shi_fou_guo_shen_ == '已编制'">确定</van-button>
+							<van-button type="success" size="small" class="u-m-r-15 btn-sty" @click="getGo(item.id_,'4')" v-if="item.shi_fou_guo_shen_ == '已退回'">修改
+							</van-button>
+							<van-button type="warning" size="small" class="btn-back-color btn-sty" @click="getGo(item.id_,'1')">查阅
+							</van-button> -->
+							<van-button type="success" size="small" @click="getGo(item.id_,'3')" class="u-m-r-15 btn-sty" v-if="item.tou_su_ri_qi_ && item.shi_fou_guo_shen_ == '已退回'">修改</van-button>
+							<van-button type="success" size="small" @click="getDe(item.id_,'3')" class="btn-back-color btn-sty">详情
+							</van-button>
+						</div>
+          </van-cell>
+        </van-checkbox-group>
+      </van-list>
+      <ibps-list-result-page :result-type="resultType" :error-type="errorType" :result-message="resultMessage" />
+    </van-pull-refresh>
+    <div class="suspensionBtn">
+      <img src="@/assets/images/add.png" alt="" srcset="" @click="LiftUpPop()">
+    </div>
+    <approve-popup :visible="batchOpinionPopup" :task-id="selectedIds" :action="actionName"
+      @close="(visible)=>{batchOpinionPopup =visible}" @callback="onRefreshPage" />
+    <!--高级查询-->
+    <ibps-more-search :show="moreSearchPopup" :search-forms="searchForms" @callback="onMoreSearch"
+      @close="callback => moreSearchPopup = callback" @reset-form="resetForm">
+      <template v-slot:definition>
+        <ibps-bpmn-definition v-model="defKey" value-key="defKey" input-align="left" class="van-hairline--bottom" />
+      </template>
+    </ibps-more-search>
+    <communication :showPop = "showPop" @updataSet="updataSet" :typeValue = "typeValue" :id = "id"></communication>
+  </div>
+</template>
+<script>
+  import i18n from '@/utils/i18n'
+  import random from '@/mixins/random'
+  import bpmnStatus from '@/mixins/bpmnStatus'
+  import ActionUtils from '@/utils/action'
+
+  import ApprovePopup from '@/business/platform/bpmn/form-ext/approve'
+
+  import IbpsMoreSearch from '@/components/ibps-more-search'
+  import IbpsAvatar from '@/components/ibps-avatar'
+  import IbpsToolbar from '@/components/ibps-toolbar'
+  import IbpsListResultPage from '@/components/ibps-list-result-page'
+  import IbpsTypeTree from '@/business/platform/cat/type/tree'
+  import IbpsBpmnDefinition from '@/business/platform/bpmn/definition/field'
+
+  import IbpsBpmnFormrenderDialog from '@/business/platform/bpmn/form/dialog'
+  import communication from './complaint.vue'
+
+  export default {
+    components: {
+      IbpsMoreSearch,
+      IbpsAvatar,
+      IbpsListResultPage,
+      IbpsTypeTree,
+      IbpsBpmnDefinition,
+      IbpsToolbar,
+      ApprovePopup,
+      IbpsBpmnFormrenderDialog,
+      communication
+    },
+    mixins: [random, bpmnStatus],
+    data() {
+      const useId = this.$store.getters.userId
+      return {
+        useId,
+        moreSearchPopup: false,
+        stateActive: false,
+        searchForms: {
+          forms: [
+            { prop: 'tou_su_ren_', label: '投诉者', fieldType: 'text'  },
+            { prop: 'tou_su_dan_wei_', label: '投诉单位',  fieldType: 'text' },
+            { prop: 'tou_su_fen_lei_', label: '投诉类型', fieldType: 'checker', cols: 3, options: [
+                {
+                  value: '全部',
+                  label: '全部'
+                }, {
+                  value: '患者',
+                  label: '患者'
+                }, {
+                  value: '临床医护',
+                  label: '临床医护'
+                }, {
+                  value: '其它',
+                  label: '其它'
+                }
+              ]
+            }
+          ]
+        },
+        subject: '',
+        typeId: '',
+        defKey: '',
+        twoParam: '',
+        moreParams: {},
+
+        listData: [],
+        pagination: {},
+        sorts: {},
+
+        loading: false,
+        finished: false,
+        refreshing: false,
+        resultType: 'init',
+        errorType: null,
+        resultMessage: null,
+
+        checkMode: false,
+        checkedIds: [],
+        show: false,
+        batchOpinionPopup: false,
+        actionName: 'agree',
+
+        typeTreePopup: false,
+        scrollWhere: 0,
+        taskId: '',
+        formrenderVisible: false,
+        formrenderTitle: '',
+        page: 0,
+        showPop: false,
+        typeValue: '0',
+        id: ''
+      }
+    },
+    computed: {
+      rightText() {
+        return this.checkMode ? this.$t('common.button.cancel') : this.$t('common.button.manage')
+      },
+      selectedIds() {
+        return this.checkedIds.join(',')
+      }
+    },
+    methods: {
+      updataSet(v){
+        this.showPop=v
+        this.startScroll()
+      },
+      generateTitle(name, title) { // generateTitle by vue-i18n
+        return i18n.generateTitle(name, title)
+      },
+      /**
+       * 加载数据
+       */
+      loadData(j) {
+        this.loading = true
+        const params = this.getSearcFormData()
+        if( j === 'search'){
+          this.page = 0
+        }
+        let itemSql = ``
+        let gtlx = params.parameters.find( i => i.key === 'tou_su_fen_lei_' ) || ''
+				if ( gtlx && gtlx.value != '全部') {
+					itemSql = itemSql + `and tou_su_fen_lei_ = '${gtlx.value}'`
+				}
+        let bdbh = params.parameters.find( i => i.key === 'tou_su_dan_wei_' ) || ''
+				if ( bdbh && bdbh.value != '') {
+					itemSql = itemSql + `and tou_su_dan_wei_ like '%${bdbh.value}%'`
+				}
+        let khlxr = params.parameters.find( i => i.key === 'tou_su_ren_' ) || ''
+				if ( khlxr && khlxr.value != '') {
+					itemSql = itemSql + `and tou_su_ren_ like '%${khlxr.value}%'`
+				}
+        let two = params.parameters.find( i => i.key === 'two' ) || ''
+				if ( two ) {
+					itemSql = itemSql + `and (tou_su_ren_ like '%${two.value}%' or tou_su_dan_wei_ like '%${two.value}%')`
+				}
+        let sql =
+					`select * from t_tsclb where create_by_ = '${this.useId}' ${itemSql}  ORDER BY create_time_ desc LIMIT ${this.page*params.requestPage.limit},${params.requestPage.limit}`
+        this.$common.request('sql', sql).then(response => {
+          // 处理数据
+          ActionUtils.handleListDataCommon(this, response.variables)
+        }).catch((e) => {
+          ActionUtils.handleErrorData(this, e)
+        })
+      },
+      /**
+       * 获取格式化参数
+       */
+      getSearcFormData() {
+        let params = {}
+        if (this.$utils.isNotEmpty(this.twoParam)) {
+          params['two'] = this.twoParam
+        }
+        // if (this.$utils.isNotEmpty(this.typeId)) {
+        //   params['Q^temp.TYPE_ID_^S'] = this.typeId
+        // }
+        // if (this.$utils.isNotEmpty(this.defKey)) {
+        //   params['Q^temp.proc_def_key_^S'] = this.defKey
+        // }
+        if (this.$utils.isNotEmpty(this.moreParams)) {
+          params = Object.assign(params, this.moreParams)
+        }
+				console.log(params, 'paramsparamsparamsparams')
+        return ActionUtils.formatParams(
+          params,
+          this.pagination,
+          this.sorts)
+      },
+      LiftUpPop() {
+        this.scrollWhere = window.pageYOffset||document.body.scrollTop||document.documentElement.scrollTop;
+        this.stopScroll()
+        this.getGo('', '1')
+      },
+      /**
+       * 下拉刷新
+       */
+      onRefresh() {
+        this.refreshing = true
+        this.finished = false
+        this.loading = true
+        this.onSearch()
+      },
+      /**
+       * 查询
+       */
+      onSearch() {
+        this.stateActive = false
+        ActionUtils.initListData(this)
+        this.loadData('search')
+      },
+      /**
+       * 高级查询
+       */
+      onMoreSearch(params) {
+        this.moreParams = params
+        this.onSearch()
+        if (this.$utils.isNotEmpty(params)) {
+          this.stateActive = true
+        }
+      },
+      /**
+       * 弹窗更多查询条件
+       */
+      clickMoreSearch() {
+        this.moreSearchPopup = true
+        this.stateActive = false
+      },
+      /**
+       * 重置表单
+       */
+      resetForm() {
+        this.typeId = ''
+        this.defKey = ''
+      },
+
+      onRefreshPage() {
+        this.checkedIds = []
+        this.checkMode = false
+        this.onRefresh()
+      },
+
+      onClick(item, index) {
+        if (this.checkMode) {
+          this.$refs.checkboxes[index].toggle()
+        } else {
+          this.taskId = item.id
+          this.formrenderTitle = item.procDefName
+          this.formrenderVisible = true
+        }
+      },
+      clickType() {
+        this.typeTreePopup = true
+      },
+      clickTypeNode(data) {
+        this.typeId = data.id
+        this.onMoreSearch({})
+      },
+      toCheckMode() {
+        if (this.$utils.isEmpty(this.listData)) {
+          return
+        }
+        if (this.checkMode) {
+          this.show = true
+          this.checkedIds = []
+        }
+        this.checkMode = !this.checkMode
+      },
+      stopScroll(){
+        let mid = this.scrollWhere
+        // document.documentElement.style.overflow='hidden';
+        document.body.style.overflow='hidden';
+        // document.documentElement.style.position='fixed';
+        document.body.style.position='fixed';
+        // document.documentElement.style.top=-mid+'px';
+        document.body.style.top=-mid+'px';
+      },
+      //启用页面滚动
+      startScroll(){
+        // document.documentElement.style.overflow='';
+        document.body.style.overflow='auto';
+        document.body.style.position='static';
+        window.scrollTo(0,this.scrollWhere)
+        this.scrollWhere=0
+      },
+      getGo(id, typeValue) {
+        this.id = id
+        this.typeValue = typeValue
+        this.showPop = true
+			},
+			getDe(id) {
+				this.getGo(id, '2')
+			},
+    }
+  }
+</script>
+<style lang="scss" scoped>
+  ::v-deep .van-cell__title {
+    width: 65%;
+
+    .van-cell__label {
+      overflow-wrap: break-word;
+    }
+  }
+  .sectionBox {
+		display: flex;
+		align-items: center;
+		margin-bottom: 2px;
+		font-size: 14px;
+		color: rgba(128, 138, 135, .9);
+
+		.left {
+			width: 90px;
+
+		}
+	}
+  .sectionBox::before {
+    content: '';
+    width: 5px;
+    height: 14px;
+    border-radius: 2px;
+    margin-right: 5px;
+  }
+  .btn-back-color {
+		background-color: #30c2bd !important;
+    border: none;
+	}
+  .btn-sty {
+    padding: 0 13px;
+    border-radius: 5px;
+  }
+  .u-m-r-15 {
+    margin-right: 8px !important;
+  }
+  .verticalLine {
+    color: #000;
+    font-size: 13px;
+    margin-bottom: 20px;
+  }
+  .verticalLine::before {
+    content: '';
+    width: 5px;
+    height: 14px;
+    background-color: #2979ff;
+    border-radius: 2px;
+    margin-right: 5px;
+  }
+  .suspensionBtn {
+    width: 80px;
+    height: 80px;
+    position: fixed;
+    top: 75%;
+    right: 2%;
+    img {
+      width: 100%;
+      height: 100%;
+    }
+  }
+</style>

+ 399 - 292
src/views/system/dashboard/index.vue

@@ -9,7 +9,7 @@
     <div class="dashboard-swipe ">
       <van-swipe :autoplay="11000">
         <van-swipe-item v-for="(swipe, index) in swipes" :key="index">
-          <img v-lazy="swipe.image||blankImage">
+          <img v-lazy="swipe.image || blankImage" />
         </van-swipe-item>
       </van-swipe>
     </div>
@@ -17,15 +17,33 @@
     <!--通知-->
     <template v-if="noticeList && noticeList.length > 0">
       <div class="dashboard-notice" style="height: 52px;background: #F3F3F3;">
-        <van-swipe :autoplay="6000" :height="44" :show-indicators="false" :initial-swipe="initialNotice()"
-          style="height:44px;" vertical>
+        <van-swipe
+          :autoplay="6000"
+          :height="44"
+          :show-indicators="false"
+          :initial-swipe="initialNotice()"
+          style="height:44px;"
+          vertical
+        >
           <van-swipe-item v-for="(notice, index) in noticeList" :key="index">
-            <van-notice-bar background="#ffffff" style="height:44px;" color="#979797" mode="link"
-              @click="onNotice(notice)">
+            <van-notice-bar
+              background="#ffffff"
+              style="height:44px;"
+              color="#979797"
+              mode="link"
+              @click="onNotice(notice)"
+            >
               <span class="ibps-pl-10"> {{ notice.title }}</span>
               <template #left-icon>
-                <ibps-avatar icon="volume-o" bg-color="#3396FB" color="#ffffff" radius="8" width="24" height="24"
-                  icon-size="12" />
+                <ibps-avatar
+                  icon="volume-o"
+                  bg-color="#3396FB"
+                  color="#ffffff"
+                  radius="8"
+                  width="24"
+                  height="24"
+                  icon-size="12"
+                />
               </template>
             </van-notice-bar>
           </van-swipe-item>
@@ -33,41 +51,75 @@
       </div>
     </template>
     <template v-else>
-      <div v-if="!emptyNoticeData" class="dashboard-notice__empty van-skeleton--animate" />
+      <div
+        v-if="!emptyNoticeData"
+        class="dashboard-notice__empty van-skeleton--animate"
+      />
     </template>
 
     <!--栏目-->
-    <template v-if="dashboards && dashboards.length >0">
+    <template v-if="dashboards && dashboards.length > 0">
       <van-collapse v-model="activeDashboards" :border="false">
-        <van-collapse-item v-for="(dashboard,index) in dashboards" :key="dashboard[aliasKey]+index"
-          :name="dashboard[aliasKey]" :border="false" :is-link="false">
+        <van-collapse-item
+          v-for="(dashboard, index) in dashboards"
+          :key="dashboard[aliasKey] + index"
+          :name="dashboard[aliasKey]"
+          :border="false"
+          :is-link="false"
+        >
           <template #title>
             <h2 class="menus-title">
-              <van-icon :name="dashboard.icon" :color="dashboard.iconBgColor" class-prefix="ibps-icon" />
+              <van-icon
+                :name="dashboard.icon"
+                :color="dashboard.iconBgColor"
+                class-prefix="ibps-icon"
+              />
               {{ getText(dashboard) }}
               <span class="icon-wrapper">
-                <van-icon :name="getIcon(dashboard.alias) ?'arrow-down':'arrow-up'" class="icon-displacement" />
+                <van-icon
+                  :name="getIcon(dashboard.alias) ? 'arrow-down' : 'arrow-up'"
+                  class="icon-displacement"
+                />
               </span>
             </h2>
           </template>
           <van-grid :column-num="4" :border="false" class="avatar-grid">
-            <van-grid-item v-for="menu in dashboard[childrenKey]" :key="menu[aliasKey]" :badge="getBadge(menu)"
-              :text="getText(menu)" @click.native="onClick(menu)">
+            <van-grid-item
+              v-for="menu in dashboard[childrenKey]"
+              :key="menu[aliasKey]"
+              :badge="getBadge(menu)"
+              :text="getText(menu)"
+              @click.native="onClick(menu)"
+            >
               <template #icon>
-                <ibps-avatar :icon="menu.icon" :text="getText(menu)" :bg-color="menu.iconBgColor"
-                  :color="menu.iconFontColor" icon-prefix="ibps-icon" radius="17" class="ibps-mb-10 avatar-layout" />
+                <ibps-avatar
+                  :icon="menu.icon"
+                  :text="getText(menu)"
+                  :bg-color="menu.iconBgColor"
+                  :color="menu.iconFontColor"
+                  icon-prefix="ibps-icon"
+                  radius="17"
+                  class="ibps-mb-10 avatar-layout"
+                />
               </template>
-
             </van-grid-item>
           </van-grid>
         </van-collapse-item>
       </van-collapse>
     </template>
     <div v-else>
-      <van-empty v-if="emptyData" :type="resultType" :description="resultMessage" />
+      <van-empty
+        v-if="emptyData"
+        :type="resultType"
+        :description="resultMessage"
+      />
       <!--骨架屏-->
       <template v-else>
-        <div v-for="i in 8" :key="i" class="van-hairline--bottom dashboard-menus empty-data van-skeleton--animate">
+        <div
+          v-for="i in 8"
+          :key="i"
+          class="van-hairline--bottom dashboard-menus empty-data van-skeleton--animate"
+        >
           <h2 class="menus-title">&nbsp;</h2>
           <van-grid :column-num="4" :border="false">
             <van-grid-item v-for="j in 8" :key="j">
@@ -83,88 +135,129 @@
       </template>
     </div>
 
-    <notice-dialog :id="noticeId" :visible="noticeVisible" readonly @close="visible => noticeVisible = visible" />
+    <notice-dialog
+      :id="noticeId"
+      :visible="noticeVisible"
+      readonly
+      @close="visible => (noticeVisible = visible)"
+    />
   </div>
 </template>
 <script>
-  import Vue from 'vue'
-  import { getMenuData, getInfoCount } from '@/api/platform/auth/appres'
-  import { queryPageList } from '@/api/platform/system/news'
-  import ActionUtils from '@/utils/action'
-  // import navbar from '@/mixins/navbar'
-  import { Lazyload } from 'vant'
-  Vue.use(Lazyload)
-  import TreeUtils from '@/utils/tree'
-  import i18n from '@/utils/i18n' // Internationalization 国际化
-  import IbpsAvatar from '@/components/ibps-avatar'
-  import NoticeDialog from '@/views/platform/notice/edit'
-  // 透明图片
-  const BLANK = 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7'
-  export default {
-    name: 'dashboard',
-    // mixins: [navbar],
-    components: {
-      IbpsAvatar,
-      NoticeDialog
-    },
-    data() {
-      const { userInfo } = this.$store.getters
-      return {
-        userInfo,
-        idKey: 'id',
-        aliasKey: 'alias',
-        labelKey: 'name',
-        parentIdKey: 'parentId',
-        childrenKey: 'children',
-        urlKey: 'defaultUrl',
-        dashboards: [],
-        emptyData: false,
-        resultType: 'empty',
-        resultMessage: '没有应用,请联系管理员',
-        countInfo: {}, // 右上角图标
-        swipes: [],
-        blankImage: BLANK,
+import Vue from 'vue'
+import { getMenuData, getInfoCount } from '@/api/platform/auth/appres'
+import { queryPageList } from '@/api/platform/system/news'
+import ActionUtils from '@/utils/action'
+// import navbar from '@/mixins/navbar'
+import { Lazyload } from 'vant'
+Vue.use(Lazyload)
+import TreeUtils from '@/utils/tree'
+import i18n from '@/utils/i18n' // Internationalization 国际化
+import IbpsAvatar from '@/components/ibps-avatar'
+import NoticeDialog from '@/views/platform/notice/edit'
+// 透明图片
+const BLANK =
+  'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7'
+export default {
+  name: 'dashboard',
+  // mixins: [navbar],
+  components: {
+    IbpsAvatar,
+    NoticeDialog
+  },
+  data() {
+    const { userInfo } = this.$store.getters
+    return {
+      userInfo,
+      idKey: 'id',
+      aliasKey: 'alias',
+      labelKey: 'name',
+      parentIdKey: 'parentId',
+      childrenKey: 'children',
+      urlKey: 'defaultUrl',
+      dashboards: [],
+      emptyData: false,
+      resultType: 'empty',
+      resultMessage: '没有应用,请联系管理员',
+      countInfo: {}, // 右上角图标
+      swipes: [],
+      blankImage: BLANK,
 
-        noticeList: [],
-        emptyNoticeData: false,
-        activeDashboards: [],
-        noticeVisible: false,
-        noticeId: '',
-        outList: [{
+      noticeList: [],
+      emptyNoticeData: false,
+      activeDashboards: [],
+      noticeVisible: false,
+      noticeId: '',
+      outList: [
+        {
           alias: 'userFeedback',
           checked: 'false',
-          children: [{
-            alias: 'InfoComm',
-            checked: 'false',
-            children: [],
-            createBy: null,
-            createTime: '2016-08-26 09:48:29',
-            dataStatus: null,
-            dbType: null,
-            defaultUrl: '/bpmn/communication/communicationList',
-            desc: '',
-            displayInMenu: '1',
-            dsAlias: null,
-            icon: 'title',
-            iconBgColor: '#00aabb',
-            iconFontColor: '#ffffff',
-            iconType: 'icon',
-            id: '2',
-            ip: null,
-            isCommon: 'N',
-            isFolder: 'Y',
-            isOpen: 'N',
-            name: '信息沟通',
-            parentId: '1',
-            path: '1.1.2.1.1.2',
-            pk: '',
-            resourceType: 'menu',
-            sn: 1,
-            systemId: 'app',
-            tenantId: '-999',
-            updateBy: null,
-            updateTime: null
-          }],
+          children: [
+            {
+              alias: 'InfoComm',
+              checked: 'false',
+              children: [],
+              createBy: null,
+              createTime: '2016-08-26 09:48:29',
+              dataStatus: null,
+              dbType: null,
+              defaultUrl: '/bpmn/communication/communicationList',
+              desc: '',
+              displayInMenu: '1',
+              dsAlias: null,
+              icon: 'title',
+              iconBgColor: '#00aabb',
+              iconFontColor: '#ffffff',
+              iconType: 'icon',
+              id: '2',
+              ip: null,
+              isCommon: 'N',
+              isFolder: 'Y',
+              isOpen: 'N',
+              name: '信息沟通',
+              parentId: '1',
+              path: '1.1.2.1.1.2',
+              pk: '',
+              resourceType: 'menu',
+              sn: 1,
+              systemId: 'app',
+              tenantId: '-999',
+              updateBy: null,
+              updateTime: null
+            },
+            {
+              alias: 'Complanint',
+              checked: 'false',
+              children: [],
+              createBy: null,
+              createTime: '2016-08-26 09:48:29',
+              dataStatus: null,
+              dbType: null,
+              defaultUrl: '/bpmn/complaint/complaintList',
+              desc: '',
+              displayInMenu: '1',
+              dsAlias: null,
+              icon: 'completed',
+              iconBgColor: '#e7505a',
+              iconFontColor: '#ffffff',
+              iconType: 'icon',
+              id: '3',
+              ip: null,
+              isCommon: 'N',
+              isFolder: 'Y',
+              isOpen: 'N',
+              name: '投诉',
+              parentId: '1',
+              path: '1.1.2.1.1.3',
+              pk: '',
+              resourceType: 'menu',
+              sn: 1,
+              systemId: 'app',
+              tenantId: '-999',
+              updateBy: null,
+              updateTime: null
+            }
+          ],
           createBy: null,
           createTime: '2016-08-26 09:48:29',
           dataStatus: null,
@@ -192,61 +285,68 @@
           tenantId: '-999',
           updateBy: null,
           updateTime: null
-        }]
+        }
+      ]
+    }
+  },
+  created() {
+    this.loadData()
+  },
+  methods: {
+    getIcon(data) {
+      return this.activeDashboards.includes(data)
+    },
+    changeIcon(data) {
+      console.info(data, this.activeDashboards)
+    },
+    svgName(name) {
+      return `#${name}`
+    },
+    getImage(menu) {
+      if (menu.iconType === 'image') {
+        return menu.icon
       }
+      return
     },
-    created() {
-      this.loadData()
+    getText(menu) {
+      return i18n.generateTitle(menu[this.aliasKey], menu[this.labelKey])
     },
-    methods: {
-      getIcon(data) {
-        return this.activeDashboards.includes(data)
-      },
-      changeIcon(data) {
-        console.info(data, this.activeDashboards)
-      },
-      svgName(name) {
-        return `#${name}`
-      },
-      getImage(menu) {
-        if (menu.iconType === 'image') {
-          return menu.icon
+    getBadge(menu) {
+      const info = this.countInfo[menu[this.aliasKey]]
+      if (this.$utils.isNotEmpty(info)) {
+        return info > 99 ? '99+' : info === '0' ? '' : info
+      }
+    },
+    loadData() {
+      this.loadMenus()
+      this.loadCountInfo()
+      this.loadNotice()
+    },
+    loadMenus() {
+      this.swipes = [{}]
+      this.swipes = [
+        { image: './images/swipes/banner1.png' },
+        { image: './images/swipes/banner2.png' },
+        { image: './images/swipes/banner3.png' }
+      ]
+      if (
+        this.userInfo.employee.jiNengZhiCheng !== 'inside' &&
+        this.userInfo.employee.isSuper === 'N'
+      ) {
+        this.dashboards = this.outList
+        if (this.$utils.isNotEmpty(this.dashboards)) {
+          const activeDashboards = []
+          this.dashboards.forEach(d => {
+            activeDashboards.push(d[this.aliasKey])
+          })
+          this.activeDashboards = activeDashboards
         }
-        return
-      },
-      getText(menu) {
-        return i18n.generateTitle(menu[this.aliasKey], menu[this.labelKey])
-      },
-      getBadge(menu) {
-        const info = this.countInfo[menu[this.aliasKey]]
-        if (this.$utils.isNotEmpty(info)) { return info > 99 ? '99+' : info === '0' ? '' : info }
-      },
-      loadData() {
-        this.loadMenus()
-        this.loadCountInfo()
-        this.loadNotice()
-      },
-      loadMenus() {
-        this.swipes = [{}]
-        this.swipes = [
-          { image: './images/swipes/banner1.png' },
-          { image: './images/swipes/banner2.png' },
-          { image: './images/swipes/banner3.png' }
-        ]
-        if (this.userInfo.employee.jiNengZhiCheng !== 'inside' && this.userInfo.employee.isSuper === 'N') {
-          this.dashboards = this.outList
-          if (this.$utils.isNotEmpty(this.dashboards)) {
-            const activeDashboards = []
-            this.dashboards.forEach((d) => {
-              activeDashboards.push(d[this.aliasKey])
-            })
-            this.activeDashboards = activeDashboards
-          }
-          this.emptyData = !(this.dashboards.length > 0)
-        } else {
-          getMenuData().then(response => {
+        this.emptyData = !(this.dashboards.length > 0)
+      } else {
+        getMenuData()
+          .then(response => {
             const data = response.data
-            const listData = data.filter((d) => {
+            const listData = data.filter(d => {
               return d.id !== '0'
             })
             this.dashboards = TreeUtils.transformToTreeFormat(listData, {
@@ -256,200 +356,207 @@
             })
             if (this.$utils.isNotEmpty(this.dashboards)) {
               const activeDashboards = []
-              this.dashboards.forEach((d) => {
+              this.dashboards.forEach(d => {
                 activeDashboards.push(d[this.aliasKey])
               })
               this.activeDashboards = activeDashboards
             }
             this.emptyData = !(listData.length > 0)
-          }).catch((e) => {
+          })
+          .catch(e => {
             this.emptyData = true
             this.resultType = 'error'
             this.resultMessage = e.message
           })
-        }
-      },
-      loadCountInfo() {
-        getInfoCount().then(response => {
+      }
+    },
+    loadCountInfo() {
+      getInfoCount()
+        .then(response => {
           const data = response.data
           const countInfo = {}
-          data.forEach((d) => {
+          data.forEach(d => {
             countInfo[d.alias] = d.dataText
           })
           this.countInfo = countInfo
-        }).catch((e) => {
         })
-      },
+        .catch(e => {})
+    },
 
-      loadNotice() {
-        this.emptyNoticeData = false
-        const params = ActionUtils.formatParams({ status: 'publish' }, { page: 1, limit: 5 })
-        queryPageList(params).then(response => {
+    loadNotice() {
+      this.emptyNoticeData = false
+      const params = ActionUtils.formatParams(
+        { status: 'publish' },
+        { page: 1, limit: 5 }
+      )
+      queryPageList(params)
+        .then(response => {
           this.noticeList = response.data.dataResult
           this.emptyNoticeData = !(this.noticeList.length > 0)
-        }).catch((e) => {
+        })
+        .catch(e => {
           this.emptyNoticeData = true
         })
-      },
-      initialNotice() {
-        return Math.floor((Math.random() * this.noticeList.length))
-      },
-      onClick(menu) {
-        const url = menu[this.urlKey]
-        if (this.$utils.isNotEmpty(url)) {
-          if (/^https:\/\/|http:\/\//.test(url)) {
-            this.$utils.open(url)
-          } else {
-            this.$router.push({ path: url })
-          }
+    },
+    initialNotice() {
+      return Math.floor(Math.random() * this.noticeList.length)
+    },
+    onClick(menu) {
+      const url = menu[this.urlKey]
+      if (this.$utils.isNotEmpty(url)) {
+        if (/^https:\/\/|http:\/\//.test(url)) {
+          this.$utils.open(url)
         } else {
-          // 判断是否有下级菜单如果有
-          if (this.$utils.isNotEmpty(menu.children)) {
-            this.$router.push({
-              name: 'next-menu',
-              params: {
-                title: menu.name,
-                menus: menu.children
-              }
-            })
-          } else {
-            this.$notify({
-              type: 'danger',
-              message: '未配置菜单的url路径,请在PC后台配置!'
-            })
-          }
+          this.$router.push({ path: url })
+        }
+      } else {
+        // 判断是否有下级菜单如果有
+        if (this.$utils.isNotEmpty(menu.children)) {
+          this.$router.push({
+            name: 'next-menu',
+            params: {
+              title: menu.name,
+              menus: menu.children
+            }
+          })
+        } else {
+          this.$notify({
+            type: 'danger',
+            message: '未配置菜单的url路径,请在PC后台配置!'
+          })
         }
-      },
-      onNotice(item) {
-        this.noticeId = item.id
-        this.noticeVisible = true
-        // this.$router.push({
-        //   name: 'noticeDetail',
-        //   query: {
-        //     id: item.id
-        //   }
-        // })
       }
+    },
+    onNotice(item) {
+      this.noticeId = item.id
+      this.noticeVisible = true
+      // this.$router.push({
+      //   name: 'noticeDetail',
+      //   query: {
+      //     id: item.id
+      //   }
+      // })
     }
   }
+}
 </script>
 <style lang="scss">
-  .dashboard {
-    .dashboard-menus {
-      margin: 0 15px;
-    }
-
-    .menus-title {
-      margin: 0;
-      font-weight: 600;
-      font-size: 14px;
-    }
-
-    .van-grid-item__text {
-      overflow: hidden;
-      text-overflow: ellipsis;
-      display: -webkit-box;
-      -webkit-line-clamp: 1;
-      -webkit-box-orient: vertical;
-    }
+.dashboard {
+  .dashboard-menus {
+    margin: 0 15px;
+  }
 
-    /**滚屏 */
-    .dashboard-swipe {
-      .van-swipe {
-        cursor: pointer;
-      }
+  .menus-title {
+    margin: 0;
+    font-weight: 600;
+    font-size: 14px;
+  }
 
-      .van-swipe-item {
-        color: #fff;
-        font-size: 20px;
-        text-align: center;
-        line-height: 120px
-      }
+  .van-grid-item__text {
+    overflow: hidden;
+    text-overflow: ellipsis;
+    display: -webkit-box;
+    -webkit-line-clamp: 1;
+    -webkit-box-orient: vertical;
+  }
 
-      .van-swipe-item:nth-child(even) {
-        background-color: #f7f7f7;
-        background: -webkit-linear-gradient(#f7f7f7, #f0f7fb);
-      }
+  /**滚屏 */
+  .dashboard-swipe {
+    .van-swipe {
+      cursor: pointer;
+    }
 
-      .van-swipe-item:nth-child(odd) {
-        background-color: #f0f7fb;
-        background: -webkit-linear-gradient(#f0f7fb, #f7f7f7);
-      }
+    .van-swipe-item {
+      color: #fff;
+      font-size: 20px;
+      text-align: center;
+      line-height: 120px;
+    }
 
-      .van-swipe img {
-        width: 100%;
-        height: 180px;
-        display: block;
-        box-sizing: border-box;
-        pointer-events: none;
-      }
+    .van-swipe-item:nth-child(even) {
+      background-color: #f7f7f7;
+      background: -webkit-linear-gradient(#f7f7f7, #f0f7fb);
     }
 
-    /**公告 */
-    .dashboard-notice {
-      .van-swipe-item {
-        text-align: center;
-        line-height: 36px
-      }
+    .van-swipe-item:nth-child(odd) {
+      background-color: #f0f7fb;
+      background: -webkit-linear-gradient(#f0f7fb, #f7f7f7);
+    }
 
-      .van-swipe-item:nth-child(even) {
-        background-color: #f7f7f7;
-        background: -webkit-linear-gradient(#f7f7f7, #f0f7fb);
-      }
+    .van-swipe img {
+      width: 100%;
+      height: 180px;
+      display: block;
+      box-sizing: border-box;
+      pointer-events: none;
+    }
+  }
 
-      .van-swipe-item:nth-child(odd) {
-        background-color: #f0f7fb;
-        background: -webkit-linear-gradient(#f0f7fb, #f7f7f7);
-      }
+  /**公告 */
+  .dashboard-notice {
+    .van-swipe-item {
+      text-align: center;
+      line-height: 36px;
     }
 
-    .dashboard-notice__empty {
-      width: 100%;
-      height: 36px;
-      background-color: #f2f3f5;
+    .van-swipe-item:nth-child(even) {
+      background-color: #f7f7f7;
+      background: -webkit-linear-gradient(#f7f7f7, #f0f7fb);
     }
 
-    .empty-data {
-      .menus-title {
-        background-color: #f7f7f7;
-        background: -webkit-linear-gradient(#f7f7f7, #f0f7fb);
-        width: 70px;
-        margin: 10px;
-        height: 16px;
-      }
+    .van-swipe-item:nth-child(odd) {
+      background-color: #f0f7fb;
+      background: -webkit-linear-gradient(#f0f7fb, #f7f7f7);
+    }
+  }
 
-      .avatar {
-        width: 48px;
-        height: 48px;
-        background: #f9f9f9;
-        margin-bottom: 5px;
-        border-radius: 12px;
-      }
+  .dashboard-notice__empty {
+    width: 100%;
+    height: 36px;
+    background-color: #f2f3f5;
+  }
 
-      .title {
-        width: 48px;
-        height: 16px;
-        background: #f9f9f9;
-      }
+  .empty-data {
+    .menus-title {
+      background-color: #f7f7f7;
+      background: -webkit-linear-gradient(#f7f7f7, #f0f7fb);
+      width: 70px;
+      margin: 10px;
+      height: 16px;
     }
 
-    .avatar-grid {
-      margin: -12px -16px;
+    .avatar {
+      width: 48px;
+      height: 48px;
+      background: #f9f9f9;
+      margin-bottom: 5px;
+      border-radius: 12px;
     }
 
-    .avatar-layout {
-      height: 50px;
-      width: 50px;
+    .title {
+      width: 48px;
+      height: 16px;
+      background: #f9f9f9;
     }
+  }
+
+  .avatar-grid {
+    margin: -12px -16px;
+  }
+
+  .avatar-layout {
+    height: 50px;
+    width: 50px;
+  }
 
-    .icon-wrapper {
-      position: relative;
-      margin-left: 5px;
+  .icon-wrapper {
+    position: relative;
+    margin-left: 5px;
 
-      .icon-displacement {
-        position: absolute;
-        top: 1px;
-      }
+    .icon-displacement {
+      position: absolute;
+      top: 1px;
     }
   }
-</style>
+}
+</style>