Explorar o código

Merge branch 'purchaseDev' of http://172.16.100.139/new-business/drp-web into purchaseDev

002201 %!s(int64=2) %!d(string=hai) anos
pai
achega
629f5a7605

+ 1 - 1
src/views/purchase/PurchaseDemandList/add.vue

@@ -789,7 +789,7 @@ export default {
           let params = {...{id: row.id}, ...{pageNum:1, pageSize: 10}}
           getDemandSonDetail(params).then(res => {
             if (res.code === 200) {
-              reciveForm.puDemandItemList = res.rows
+              reciveForm.puDemandItemList = res.data
               console.log('reciveForm',reciveForm)
               this.basicForm = reciveForm
               if(this.basicForm.org) { this.reBackRefer('ORG_PARAM', this.basicForm.org) }

+ 62 - 28
src/views/purchase/purchase-order/add/column.js

@@ -408,41 +408,55 @@ export const TabColumns = [
         title: "物料编码",
         inputType: "Input",
         width: 180,
+        disabled:true,
+        readonly:true,
       },
       { //classifyIdName   classifyId
         key: "materialClassify",
         title: "物料分类", 
         inputType: "Input",
-        width: 180 
+        width: 180,
+        disabled:true,
+        readonly:true, 
       },
       { // manufacturersMaterialCode  manufacturersMaterialName
         key: "materialManufacturersCode",
          title: "厂家物料编码", 
          inputType: "Input",
-          width: 180
+          width: 180,
+          disabled:true,
+        readonly:true,
          },
       { //specification
         key: "specification",
-         title: "规格", 
-         inputType: "Input",
-          width: 180 
+        title: "规格", 
+        inputType: "Input",
+        width: 180 ,
+        disabled:true,
+        readonly:true,
         },
       { //model
         key: "model",
-         title: "型号", 
-         inputType: "Input",
-         },
+        title: "型号", 
+        inputType: "Input",
+        disabled:true,
+        readonly:true,
+      },
       { //isMedicine  isMedicineValue
         key: "isMedcine",
-         title: "医药物料", 
-         inputType: "Input", 
-         width: 180 
+        title: "医药物料", 
+        inputType: "Input", 
+        width: 180,
+        disabled:true,
+        readonly:true,
         },
       { // manufacturerId  manufacturerIdName
         key: "manufacturer",
         title: "生产厂家代理人",
         inputType: "Input",
-        width: 180 
+        width: 180,
+        disabled:true,
+        readonly:true,
       },
       { 
         key: "isDrug",
@@ -454,6 +468,8 @@ export const TabColumns = [
         key: "unit", 
         title: "单位", 
         inputType: "Input",
+        disabled:true,
+        readonly:true,
        },
       {
         key: "qty",
@@ -467,8 +483,8 @@ export const TabColumns = [
       { //materialRate  materialRateName
         key: "tax", 
         title: "税率",
-         inputType: "Input",
-         },
+        inputType: "Input",
+      },
       { key: "taxDeductMoneya", title: "折扣金额", inputType: "Input", },
       { key: "arrivalQty", title: "已到货数量", inputType: "Input", },
       { key: "unarrivedQty", title: "未到货数量", inputType: "Input", },
@@ -520,14 +536,18 @@ export const TabColumns = [
         title: "存储条件",
         inputType: "Select",
         referName: "sys_storage_condition", // 字典名
-        width: 180
+        width: 180,
+        disabled:true,
+        readonly:true,
       },
       { // transportationCondition  transportationConditionName
         key: "carriageCondition",
         title: "运输条件",
         inputType: "Select",
         referName: "sys_conditions_carriage", // 字典名
-        width: 180
+        width: 180,
+        disabled:true,
+        readonly:true,
       },
 
       { key: "isBatchLock", title: "批号锁定标识", inputType: "Checkbox", },
@@ -559,26 +579,34 @@ export const TabColumns = [
         key: "materialClassifyOneName", 
         title: "物料一级分类名称", 
         inputType: "Input",
-         width: 180 
-        },
+        width: 180,
+        disabled:true,
+        readonly:true, 
+      },
       { //twoClass
         key: "materialClassifyTwoName",
-         title: "物料二级分类名称", 
-         inputType: "Input",
-          width: 180
-         },
+        title: "物料二级分类名称", 
+        inputType: "Input",
+        width: 180,
+        disabled:true,
+        readonly:true, 
+      },
       { //threeClass
         key: "materialClassifyThreeName", 
         title: "物料三级分类名称", 
         inputType: "Input", 
-        width: 180 
+        width: 180,
+        disabled:true,
+        readonly:true,
       },
       { //fourClass
         key: "materialClassifyFourName", 
         title: "物料四级分类名称",
-         inputType: "Input", 
-         width: 180 
-        },
+        inputType: "Input", 
+        width: 180,
+        disabled:true,
+        readonly:true,
+      },
       { 
         key: "price",
         title: "无税单价",
@@ -590,7 +618,7 @@ export const TabColumns = [
     title: '执行结果',
     key: 'puOrderExecuteList',
     tableColumns: [
-      { key: "orderId", title: "采购订单ID", inputType: "Input", width: 180 },
+      // { key: "orderId", title: "采购订单ID", inputType: "Input", width: 180 },
       { key: "rowno", title: "行号", inputType: "Input", },
       {
         key: "materialName",
@@ -620,7 +648,13 @@ export const TabColumns = [
         queryParams: () => ({}),
         width: 180
       },
-      { key: "specification", title: "规格", inputType: "Input", },
+      { 
+        key: "specification",
+        title: "规格", 
+        inputType: "Input", 
+        disabled:true,
+        readonly:true, 
+      },
       {
         key: "qty",
         title: "数量",

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

@@ -206,7 +206,7 @@ export default {
     // 保存
     async handleSava() {
       // orderAddForm
-      console.log(this.params.sysFileRecordList, "params");
+      console.log(this.params, "params");
 
       // this.$refs['orderAddForm'].validate(async (valid) => {
       //   if (valid) {

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

@@ -21,7 +21,7 @@ export const TableColumns = [
     title: "单据状态",
     inputType: "Select",
     width:80,
-    referName: "sys_status", // 字典名
+    referName: "documents_status", // 字典名
   },
   { key: "billDate", title: "订单日期" },
   // { key: "supplier", title: "供应商" },

+ 15 - 5
src/views/purchase/purchase-order/components/FileUploadCenter/index.vue

@@ -23,9 +23,11 @@
 
       <li :key="file.fileUrl" class="el-upload-list__item ele-upload-list__item-content"
         v-for="(file, index) in fileList">
-        <!-- <el-link :href="`${baseUrl}${file.fileUrl}`" :underline="false" target="_blank"> -->
-        <el-link :href="`${baseUrl}${file.fileUrl}`" :underline="false" target="_blank">
-          <!-- <span class="el-icon-document"> {{ getFileName(file.name) }} </span> -->
+        <el-link
+          :href="`${baseUrl}?id=${file.fileFastId}`"
+          :underline="false"
+          target="_blank"
+        >
           <span class="el-icon-document"> {{ file.fileName }} </span>
         </el-link>
         <div class="ele-upload-list__item-content-action">
@@ -75,8 +77,16 @@ export default {
     return {
       number: 0,
       uploadList: [],
-      baseUrl: '/sy-derom',
-      uploadFileUrl: "/sy-derom/document-center/fastdfs/upload", // 上传文件服务器地址
+      // baseUrl: '/sy-derom',
+      // uploadFileUrl: "/sy-derom/document-center/fastdfs/upload", // 上传文件服务器地址
+      baseUrl: "https://sy.derom.com/document-center/fastdfs/download",
+      uploadFileUrl:
+        process.env.NODE_ENV == "development"
+          ? "/drp-file/document-center/fastdfs/upload"
+          : "/document-center/fastdfs/upload",
+      headers: {
+        Authorization: "Bearer " + getToken(),
+      },
       fileList: [],
     };
   },

+ 26 - 7
src/views/purchase/purchase-order/index.vue

@@ -146,15 +146,34 @@ export default {
       }
     },
     // 删除操作
-    async handleDeleteList(row) {
+     handleDeleteList(row) {
       try {
         this.loading = true;
-        const { id } = row;
-        console.log(id, 'id');
-        const { code, msg } = await orderApi.remove(id);
-        if (code === 200) {
-          this.fetchList(this.params, this.page);
-        }
+
+        this.$confirm('此操作将删除该订单, 是否继续?', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then( async() => {
+
+          const { id } = row;
+
+          const { code } = await orderApi.remove(id);
+          
+          if (code === 200) {
+
+            this.fetchList(this.params, this.page);
+
+          }
+
+        }).catch(() => {
+
+          this.$message({
+            type: 'info',
+            message: '已取消删除'
+          });          
+        });
+        
       } catch (err) {
         //
       } finally {

+ 2 - 1
src/views/purchase/purchase-order/see/index.vue

@@ -94,7 +94,8 @@ export default {
       let {source,status,deliveryStatus} = this.params;
 
       // 自制 & 状态为:自由态、驳回
-      if(source === '3' &&(status === '0' || status === '3')){
+      // if(source === '3' &&(status === '0' || status === '3')){
+      if(status === '2'){
 
         // 发送NC之后展示 SUCCESS("0","成功"),SEND_IN("1","发送中"),FAILURE("2","失败");
         //    未发送                发送过但未成功

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

@@ -13,7 +13,7 @@
           <el-col :span="1.5">
             <el-form-item label="单据日期">
               <el-date-picker
-               style="width: 240px"
+               style="width: 200px"
                size="small"
                clearable
                value-format="yyyy-MM-dd"
@@ -38,6 +38,16 @@
             </el-form-item>
           </el-col>
           <el-col :span="1.5">
+            <el-form-item label="单据号">
+              <el-input
+                v-model.trim="queryParams.code"
+                size="small"
+                clearable
+                style="width: 200px"
+              />
+            </el-form-item>
+          </el-col>
+          <el-col :span="1.5">
             <el-form-item label="" label-width="20px">
               <el-button type="primary" size="small" icon="el-icon-search" plain @click="searchList">搜索</el-button>
               <el-button size="small" icon="el-icon-refresh" plain @click="resetList">重置</el-button>
@@ -329,6 +339,7 @@ export default {
         billDate: '',
         billType: '',
         storageInventoryOrg: '',
+        code: '',
         pageNum: 1,
         pageSize: 5
       },
@@ -368,6 +379,7 @@ export default {
         billDate: '',
         billType: '',
         storageInventoryOrg: '',
+        code: '',
         pageNum: 1,
         pageSize: 5
       }