changjiaming vor 7 Monaten
Ursprung
Commit
e60eb05514

+ 4 - 3
src/views/myTrade/purchaseContractManagement/detailComponents/Step2.vue

@@ -46,7 +46,8 @@
         </tr>
         <tr>
           <td>合同附件</td>
-          <td style="padding-left: 0; width: 150px;">
+          <!-- <td style="padding-left: 0; width: 150px;"> -->
+          <td colspan="2">
             <cy-upload
               :upload-params="{}"
               :file-data="detailInfo.files"
@@ -55,9 +56,9 @@
               :disabled="true"
             />
           </td>
-          <td>
+          <!-- <td>
             <el-button type="primary" @click="downloadFile">下载</el-button>
-          </td>
+          </td> -->
         </tr>
       </table>
 

+ 10 - 0
src/views/myTrade/purchaseContractManagement/index.vue

@@ -48,6 +48,7 @@
 <script>
 import { mapGetters } from 'vuex'
 import indexTable from './indexTable'
+import { exportFile } from '@/utils/index'
 import { getPurchManagementList } from '@/api/myTrade/purchaseContractManagement/purchaseContractManagement'
 export default {
   name: 'ProcurementContractManagement',
@@ -111,6 +112,15 @@ export default {
             isChange: row.stage && row.stage.includes('采购合同变更签署')
           }
         })
+      } else if(type == 'download') {
+        request({
+          url: '/purchManagement/downloadPurchFile',
+          method: 'get',
+          responseType: 'arraybuffer',
+          params: { id: info.id }
+        }).then(data => {
+          exportFile(data)
+        })
       } else {
         this.$router.push({
           name: 'PurchaseContractDetail',

+ 4 - 1
src/views/myTrade/purchaseContractManagement/indexTable.js

@@ -73,11 +73,14 @@ export default {
             ]) : [
               { msg: '查看', icon: 'iconfont icon-orange icon-a-Group957', power: 'projectNumber:delete', category: 'see' }
             ]
+            if(row.status == '已完成') {
+              btnList.push({ msg: '下载签署附件', icon: 'iconfont icon-orange icon-Union', category: 'download' })
+            }
             const options = btnList.map(item => {
               return (
                 <el-tooltip class='item' effect='dark' content={item.msg} placement='top' >
                   <span class='table-icon-box'>
-                    <i class={item.icon} onClick={() => { this.handlerOperate(item.category, row) }}></i>
+                    <i class={item.icon} style={ item.category === 'download' ? { 'font-size': '16px', 'margin-top': '20px' } : ''} onClick={() => { this.handlerOperate(item.category, row) }}></i>
                   </span>
                 </el-tooltip>
               )

+ 4 - 3
src/views/myTrade/settlementDocumentManagement/components/sign.vue

@@ -44,7 +44,8 @@
         </tr>
         <tr>
           <td>结算单附件</td>
-          <td style="padding-left: 0; width: 150px">
+          <!-- <td style="padding-left: 0; width: 150px"> -->
+          <td colspan="2">
             <cy-upload
               :upload-params="{}"
               :file-data="detailInfo.files"
@@ -53,9 +54,9 @@
               :disabled="true"
             />
           </td>
-          <td>
+          <!-- <td>
             <el-button type="primary" @click="downloadFile">下载</el-button>
-          </td>
+          </td> -->
         </tr>
       </table>
 

+ 10 - 0
src/views/myTrade/settlementDocumentManagement/index.vue

@@ -49,6 +49,7 @@
 import indexTable from './indexTable'
 import request from '@/utils/request'
 import { getStatus } from '@/api/myTrade/biddingManagement/biddingManagement'
+import { exportFile } from '@/utils/index'
 
 export default {
   name: 'SettlementDocumentManagement',
@@ -116,6 +117,15 @@ export default {
             taskId: info.taskId, key: info.id
           }
         })
+      } else if(type == 'download') {
+        request({
+          url: '/bill/downloadPdfSign',
+          method: 'get',
+          responseType: 'arraybuffer',
+          params: { settlementBasicInfoId: info.id }
+        }).then(data => {
+          exportFile(data)
+        })
       }
     },
     getStatusList() {

+ 4 - 1
src/views/myTrade/settlementDocumentManagement/indexTable.js

@@ -89,11 +89,14 @@ export default {
             // if(row.currentStage == '财务审核') {
             //   btnList.push({ msg: '查看', icon: 'iconfont icon-Vector-2', power: 'projectNumber:delete', category: 'see' })
             // }
+            if(row.status && row.status.name == '已完成') {
+              btnList.push({ msg: '下载签署附件', icon: 'iconfont icon-orange icon-Union', category: 'download' })
+            }
             const options = btnList.map(item => {
               return (
                 <el-tooltip class='item' effect='dark' content={item.msg} placement='top' >
                   <span class='table-icon-box'>
-                    <i class={item.icon} onClick={() => { this.handlerOperate(item.category, row) }}></i>
+                    <i class={item.icon} style={ item.category === 'download' ? { 'font-size': '16px', 'margin-top': '20px' } : ''} onClick={() => { this.handlerOperate(item.category, row) }}></i>
                   </span>
                 </el-tooltip>
               )