瀏覽代碼

Merge remote-tracking branch 'origin/dev' into dev

001295 1 年之前
父節點
當前提交
9517db877d

+ 5 - 4
src/api/business/purchase/apply.js

@@ -26,16 +26,17 @@ export function SAVE(data) {
 
 export function SUBMIT(data) {
   return request({
-    url: `/pu/priceApply/submit/${data}`,
+    url: `/pu/priceApply/submit`,
     method: "POST",
-    data: data,
+    data: {submitIds:data},
   });
 }
 
 export function REMOVE(data) {
   return request({
-    url: `/pu/priceApply/${data}`,
+    url: `/pu/priceApply/del`,
     method: "delete",
+    data: {submitIds:data},
   });
 }
 
@@ -64,4 +65,4 @@ export function oaBack(data) {
     method: "POST",
     data: data,
   });
-}
+}

+ 2 - 2
src/api/requisition/basic.js

@@ -38,9 +38,9 @@ export function editReq(data) {
 // 物料申请单-修改提交
 export function betchSubmit(data) {
   return request({
-    url: `/system/apply/material/submit/${data}`,
+    url: `/system/apply/material/submit`,
     method: 'post',
-    // data: data
+    data: data,
   })
 }
 

+ 80 - 63
src/components/file-preview/index.vue

@@ -33,9 +33,18 @@
             <el-button
               :size="size"
               type="text"
-              icon="el-icon-download"
               @click="useDownload(item)"
-            ></el-button>
+            >
+               <el-link
+                 icon="el-icon-download"
+                 :href="`${baseUrl}${fileId}`"
+                 :underline="false"
+                 target="_blank"
+                 @click="useDownload(item)"
+               />
+            </el-button>
+
+
           </span>
         </div>
       </div>
@@ -45,73 +54,81 @@
 </template>
 
 <script>
-export default {
-  name: "FilePreview",
-  props: {
-    // 值
-    value: [String, Object, Array],
-    // 组件大小
-    size: {
-      type: String,
-      dafault: () => {
-        return "mini";
+  export default {
+    name: "FilePreview",
+    props: {
+      // 值
+      value: [String, Object, Array],
+      // 组件大小
+      size: {
+        type: String,
+        dafault: () => {
+          return "mini";
+        },
       },
     },
-  },
-  data() {
-    return {
-      separator: ";",
-      visible: false,
-      fileList: [],
-    };
-  },
-  computed: {},
-  watch: {
-    value: {
-      handler(val) {
-        if (val) {
-          let temp = 1;
-          // 首先将值转为数组
-          const list = Array.isArray(val)
-            ? val
-            : this.value.split(this.separator);
-          this.fileList = list.map((item) => {
-            item = JSON.parse(item);
-            return {
-              ...item,
-              uid: item.uid || new Date().getTime() + temp++,
-            };
-          });
-        } else {
-          this.fileList = [];
-          return [];
-        }
+    data() {
+      return {
+        baseUrl: "https://sy.derom.com/document-center/fastdfs/download?id=",
+        fileId: "",
+        separator: ";",
+        visible: false,
+        fileList: [],
+      };
+    },
+    computed: {},
+    watch: {
+      value: {
+        handler(val) {
+          if (val) {
+            let temp = 1;
+            // 首先将值转为数组
+            const list = Array.isArray(val)
+              ? val
+              : this.value.split(this.separator);
+            this.fileList = list.map((item) => {
+              item = JSON.parse(item);
+              return {
+                ...item,
+                uid: item.uid || new Date().getTime() + temp++,
+              };
+            });
+          } else {
+            this.fileList = [];
+            return [];
+          }
+        },
+        deep: true,
+        immediate: true,
       },
-      deep: true,
-      immediate: true,
     },
-  },
-  methods: {
-    //
-    useDownload(prop) {
-      const { url, name } = prop;
-      this.download("/pu/contract/download/resource", { resource: url }, name);
+    methods: {
+      //
+      useDownload(prop) {
+        const {url, name, id} = prop;
+        // this.download("/pu/contract/download/resource", {resource: url}, name);
+        this.fileId = id
+        // this.download("https://sy.derom.com/document-center/fastdfs/download", {id});
+      },
+      //
+      useView(prop) {
+        this.$notify.info({title: "暂不支持查看"});
+      },
+    },
+    created() {
     },
-    //
-    useView(prop) {
-      this.$notify.info({ title: "暂不支持查看" });
+    mounted() {
     },
-  },
-  created() {},
-  mounted() {},
-  destroyed() {},
-};
+    destroyed() {
+    },
+  };
 </script>
 <style scoped>
-.file-preview_content > div {
-  margin-bottom: 10px;
-}
-.file-preview_content > div:last-of-type {
-  margin-bottom: 0;
-}
+  .file-preview_content > div {
+    margin-bottom: 10px;
+  }
+
+  .file-preview_content > div:last-of-type {
+    margin-bottom: 0;
+  }
 </style>

+ 1 - 1
src/components/popover-select-v2/index.vue

@@ -170,7 +170,7 @@ export default {
     // auto
     async useAutocomplete(prop, cb) {
       if (prop) {
-        this.page.pageSize = 1000000;
+        this.page.pageSize = 10;
         this.model.search = prop;
         await this.fetchList(this.model, this.page);
         await cb(this.data);

+ 3 - 2
src/views/material/requisition/index.vue

@@ -238,7 +238,7 @@
 
                 let ids = this.checkedList.map( item => Number(item.id));
 
-                let {code,msg} = await betchSubmit(ids);
+                let {code,msg} = await betchSubmit({ids});
 
                 if(code == 200){
                   this.reset();
@@ -479,7 +479,8 @@
       async handleBack(row){
         try {
           const { msg, code } = await oaBack({
-            fdTemplateId: '1873b5ce924f9cc37c06e884b1e9ee26',
+            fdTemplateId: process.env.NODE_ENV == "production" ? 
+              '1877e71c5a1929040faa0e647a2ac75e':'1873b5ce924f9cc37c06e884b1e9ee26',
             fdId: row.oaId,
             billCode: row.code,
             billMaker: row.createBy

+ 7 - 1
src/views/purchase/PurchaseDemandList/index.vue

@@ -687,7 +687,13 @@ export default {
     // 流程收回
     reback(row) {
       this.$modal.loading("收回中...");
-      let params = {billCode: row.code, fdId: row.flowId, fdTemplateId: '18804432233a7813df7921d436ab69b7',billMaker: row.createBy }
+      let params = {
+        billCode: row.code, 
+        fdId: row.flowId, 
+        fdTemplateId: process.env.NODE_ENV == "production" ? 
+          '188001c472bbac2caa873d14669a33c3' : '18804432233a7813df7921d436ab69b7',
+        billMaker: row.createBy 
+      }
       rebacktWork(params).then(res => {
         if (res.code === 200) {
           this.$modal.notifySuccess("收回成功");

+ 1 - 1
src/views/purchase/apply/delete/index.vue

@@ -52,7 +52,7 @@ export default {
             try {
               // try
               const { selectData } = this.$props;
-              const ids = selectData.map((item) => item.id).join(",");
+              const ids = selectData.map((item) => item.id);
               const { msg, code } = await REMOVE(ids);
               if (code === 200) {
                 done();

+ 2 - 1
src/views/purchase/apply/index.vue

@@ -175,7 +175,8 @@
       async reback(row) {
         try {
           const { msg, code } = await oaBack({
-            fdTemplateId: '188095a870d007772057d7d4ffaad3c7',
+            fdTemplateId: process.env.NODE_ENV == "production" ?
+            '18804bd6335dd3a05fd9a12415fb6e70' : '188095a870d007772057d7d4ffaad3c7',
             fdId: row.flowId,
             billCode: row.priceCode,
             billMaker: row.createBy

+ 1 - 1
src/views/purchase/apply/submit/index.vue

@@ -52,7 +52,7 @@ export default {
             try {
               // try
               const { selectData } = this.$props;
-              const ids = selectData.map((item) => item.id).join(",");
+              const ids = selectData.map((item) => item.id);
               const { msg, code } = await SUBMIT(ids);
               if (code === 200) {
                 done();

+ 1 - 1
src/views/purchase/purchase-order/add/column.js

@@ -375,7 +375,7 @@ const PurchaseTabColumns =[
         },
       },
       { 
-        key: "rowno", 
+        key: "rowNo", 
         title: "行号", 
         inputType: "Input", 
         disabled:true,

+ 4 - 2
src/views/purchase/purchase-order/add/index.vue

@@ -149,6 +149,7 @@ export default {
             source: "3",
             isClose:'N',
             billDate: new Date().Format('yyyy-MM-dd'),
+            createTime : new Date().Format('yyyy-MM-dd HH:mm:ss'),
             closeTime:'',
             oaDemandNo:'',
             isInvoice:'N',
@@ -458,7 +459,8 @@ export default {
               key != "puDept" &&
               key != "puDeptName" &&
               key != "status" &&
-              key != "billDate" 
+              key != "billDate" &&
+              key != "createTime" 
             ) {
               this.params[key] = "";
             } else {
@@ -555,7 +557,7 @@ export default {
     // 子表inputNumber
     handleInputChange(row, type) {
       // 物料数量变化----询价
-      if ((type == "qty" || type == "taxPrice" )&& row.material) {
+      if ((type == "qty" || type == "taxPrice" || type == 'taxDeductMoneya')&& row.material) {
 
         // row['whetherCompleteInquiry'] = false;
 

+ 1 - 1
src/views/purchase/purchase-order/edit/index.vue

@@ -505,7 +505,7 @@ export default {
 
 
       // 物料数量变化----询价
-      if ((type == "qty" || type == "taxPrice" ) && row.material ) {
+      if ((type == "qty" || type == "taxPrice"  || type == 'taxDeductMoneya') && row.material ) {
 
         if(this.params.status === '2'){
 

+ 3 - 2
src/views/purchase/purchase-order/index.vue

@@ -410,7 +410,7 @@ export default {
     async handleBack(row){
       try {
         const { msg, code } = await orderApi.oaBack({
-          fdTemplateId: '1880447a834addc648b3763477a9b09f',
+          fdTemplateId: process.env.NODE_ENV == "production" ?'':'1880447a834addc648b3763477a9b09f',
           fdId: row.flowId,
           billCode: row.code,
           billMaker: row.createBy
@@ -654,7 +654,8 @@ export default {
       return {
         status,
         fdId:flowId,
-        fdTemplateId:'1880447a834addc648b3763477a9b09f',
+        fdTemplateId: process.env.NODE_ENV == "production" ?
+          '188006ef5804ba83b5144264a58ba944' : '1880447a834addc648b3763477a9b09f',
         billCode:code,
         billMaker:createBy,
       }

+ 2 - 1
src/views/purchase/transferOrder/index.vue

@@ -636,7 +636,8 @@ export default {
     async handleBack(row){
       try {
         const { msg, code } = await oaBack({
-          fdTemplateId: '188095b2398846ad82cad7a46ef9a971',
+          fdTemplateId: process.env.NODE_ENV == "production" ?
+          '188094ce4e3fc061f2bc2a046909173e' : '188095b2398846ad82cad7a46ef9a971',
           fdId: row.oaId,
           billCode: row.code,
           billMaker: row.createBy

+ 4 - 0
src/views/purchase/workSpace/index.vue

@@ -323,11 +323,13 @@ export default {
             this.$modal.closeLoading();
             this.$modal.notifySuccess("审批成功");
             this.searchList()
+            this.sonTableList = []
           }
         })
         }).catch(() => {
           this.$modal.closeLoading();
           this.searchList()
+          this.sonTableList = []
         })
       } 
     },
@@ -342,10 +344,12 @@ export default {
           this.$modal.closeLoading();
           this.$modal.notifySuccess("审批成功");
           this.searchList()
+          this.sonTableList = []
         }
       }).catch(() => {
         this.$modal.closeLoading();
         this.searchList()
+        this.sonTableList = []
       })
     },
     handleSizeChange(val) {