Browse Source

bug 修复

lilei 2 years ago
parent
commit
4db723ba23

+ 7 - 0
src/api/expenseManagement.js

@@ -193,6 +193,13 @@ export const getProcessInstance = (params) => {
     method: 'post'
   })
 }
+// 审核进度历史查看
+export const getProcessInstanceList = (params) => {
+  return axios({
+    url: `/dingTalk/getProcessInstanceList/${params.businessType}/${params.businessSn}`,
+    method: 'get'
+  })
+}
 // 钉钉部门
 export const getDingTalkDepartmentList = (params) => {
   return axios({

+ 0 - 1
src/api/salesReturn.js

@@ -8,7 +8,6 @@ export const salesReturnAudit = (params) => {
     method: 'post'
   })
 }
-
 //  销售退货 品检
 export const salesReturnCheck = (params) => {
   return axios({

+ 80 - 0
src/views/salesReturnManagement/salesReturn/auditDetail.vue

@@ -0,0 +1,80 @@
+<template>
+  <div>
+    <p>说明:以下信息来自钉钉</p>
+    <a-spin :spinning="spinning" tip="Loading...">
+      <div style="margin-bottom:10px;" v-for="item in list" :key="item.businessId">
+        <div style="margin-bottom:10px;font-weight:bold;">提审时间:{{ item.createTime }}</div>
+        <a-table
+          class="sTable fixPagination"
+          ref="table"
+          size="small"
+          :rowKey="(record) => record.businessId"
+          :columns="columns"
+          :dataSource="item.taskVOList"
+          :scroll="{ y: 500 }"
+          :pagination="false"
+          bordered>
+        </a-table>
+      </div>
+    </a-spin>
+  </div>
+</template>
+
+<script>
+import { STable } from '@/components'
+import { getProcessInstanceList } from '@/api/expenseManagement'
+export default {
+  name: 'AuditDetail',
+  components: { STable },
+  props: {
+    openModal: {
+      type: Boolean,
+      default: false
+    },
+    itemSn: {
+      type: [Number, String],
+      default: ''
+    },
+    businessType: {
+      type: [Number, String],
+      default: ''
+    }
+  },
+  data () {
+    return {
+      spinning: false,
+      columns: [{ title: '序号', dataIndex: 'no', width: '8%', align: 'center' },
+        { title: '人员姓名', width: '12%', dataIndex: 'userName', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '人员类型', dataIndex: 'userType', width: '15%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '状态', dataIndex: 'state', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '审批意见', dataIndex: 'remark', width: '20%', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '附件', dataIndex: 'hasAttachments', width: '20%', align: 'center', customRender: function (text) { return text != '0' ? '请在钉钉中查看附件内容' : '--' } },
+        { title: '操作时间', dataIndex: 'date', width: '20%', align: 'center', customRender: function (text) { return text || '--' } }],
+      list: []
+    }
+  },
+  methods: {
+    clearTable () {
+      this.list = []
+    },
+    refresh () {
+      this.getData()
+    },
+    getData () {
+      this.spinning = true
+      getProcessInstanceList({ businessType: this.businessType, businessSn: this.itemSn }).then(res => {
+        if (res.status == 200) {
+          this.list = res.data
+          this.list.map(item => {
+            item.taskVOList.map((a, index) => a.no = index + 1)
+          })
+        }
+        this.spinning = false
+      })
+    }
+  }
+}
+</script>
+
+<style>
+</style>

+ 2 - 2
src/views/salesReturnManagement/salesReturn/detail.vue

@@ -51,7 +51,7 @@
               <a-descriptions-item label="创建时间">{{ detailData&&detailData.createDate || '--' }}</a-descriptions-item>
               <a-descriptions-item label="审核时间">{{ detailData&&detailData.auditTime || '--' }}</a-descriptions-item>
               <a-descriptions-item label="退货类型">{{ detailData&&detailData.salesReturnTypeDictValue || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="附件" :span="3">
+              <a-descriptions-item label="附件" v-if="detailData" :span="3">
                 <a target="_blank" style="color: #00aaff;text-decoration: underline;margin-right: 15px;" :href="item.filePath" v-for="item in detailData.attachmentList" :key="item.id">
                   {{ item.fileName }}
                 </a>
@@ -120,7 +120,7 @@
 import { commonMixin } from '@/utils/mixin'
 import { STable, VSelect } from '@/components'
 import { printFun, exportExcel } from '@/libs/JGPrint.js'
-import auditDetail from '@/views/common/auditDetail.vue'
+import auditDetail from './auditDetail.vue'
 import printModal from './printModal.vue'
 import { salesReturnDetail, salesReturnChangeLogList, salesReturnPrint, salesReturnExport } from '@/api/salesReturn'
 import { salesReturnDetailList } from '@/api/salesReturnDetail'

+ 5 - 1
src/views/salesReturnManagement/salesReturn/verifyModal.vue

@@ -12,7 +12,7 @@
 </template>
 
 <script>
-import auditDetail from '@/views/common/auditDetail.vue'
+import auditDetail from './auditDetail.vue'
 export default {
   name: 'VerifyModal',
   components: { auditDetail },
@@ -39,6 +39,10 @@ export default {
       if (!nVal) {
         this.$emit('close')
         this.$refs.auditDetail.clearTable()
+      } else {
+        this.$nextTick(() => {
+          this.$refs.auditDetail.refresh()
+        })
       }
     }
   }

+ 2 - 2
vue.config.js

@@ -107,9 +107,9 @@ const vueConfig = {
     // If you want to turn on the proxy, please remove the mockjs /src/main.jsL11
     proxy: {
       '/api': {
-        // target: 'http://192.168.0.215/ocs-admin',
+        target: 'http://192.168.0.183:8602/ocs-admin',
         // target: 'https://t.ocs.360arrow.com/ocs-admin', //  Á·Ï°
-        target: 'http://p.ocs.360arrow.com/ocs-admin', //  Ô¤·¢²¼
+        // target: 'http://p.ocs.360arrow.com/ocs-admin', //  Ô¤·¢²¼
         ws: false,
         changeOrigin: true,
         pathRewrite: {