doctor-admin-components 1.0.14-beta.21 → 1.0.14-beta.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "doctor-admin-components",
3
3
  "version1": "1.0.11",
4
- "version": "1.0.14-beta.21",
4
+ "version": "1.0.14-beta.23",
5
5
  "private": false,
6
6
  "main1": "lib/index.umd.min.js",
7
7
  "main": "packages/index.js",
@@ -1130,3 +1130,13 @@ export function editReferenceNo(data) {
1130
1130
  data: data,
1131
1131
  });
1132
1132
  }
1133
+
1134
+
1135
+ // 获取第二通知人
1136
+ export function getSecondNotifyInfo(query) {
1137
+ return request({
1138
+ url: "/biz/contract/getSecondNotifyInfo",
1139
+ method: "get",
1140
+ params: query,
1141
+ });
1142
+ }
@@ -155,4 +155,33 @@ export function getDraft(contractId) {
155
155
  contractId
156
156
  }
157
157
  })
158
- }
158
+ }
159
+
160
+
161
+
162
+ // 保存草稿
163
+ export function containerEditBatch(data) {
164
+ return request({
165
+ url: '/biz/container/editBatch',
166
+ method: 'put',
167
+ data
168
+ })
169
+ }
170
+
171
+
172
+ // 保存草稿
173
+ export function deductionRecords(data) {
174
+ return request({
175
+ url: `biz/shipment/deposit/deduction/record/${data.shipmentId}`,
176
+ method: 'get',
177
+ data:{}
178
+ })
179
+ }
180
+ // 更新 eta更新时间
181
+ export function refreshUpdateTime(data) {
182
+ return request({
183
+ url: '/biz/shipment/refreshUpdateTime',
184
+ method: 'put',
185
+ data: data
186
+ })
187
+ }
@@ -1540,6 +1540,12 @@ export default {
1540
1540
  this.contractId = contractId;
1541
1541
  this.getContractFileInfo(contractId);
1542
1542
  this.queryParams.linkId = contractId;
1543
+ if(this.$route.query.deductionRecordsShipmentId) {
1544
+ const timer = setTimeout(() => {
1545
+ this.$refs.shipmentPurchaseAmount.handleShow(this.$route.query.deductionRecordsShipmentId);
1546
+ clearTimeout(timer);
1547
+ }, 1000)
1548
+ }
1543
1549
  }
1544
1550
  },
1545
1551
  mounted() { },
@@ -50,17 +50,20 @@
50
50
  </el-form-item>
51
51
  </el-col>
52
52
  <el-col :span="6">
53
- <el-form-item label="ETA" prop="eta" label-width="100">
54
- <el-date-picker
55
- style="width: 75%"
56
- clearable
57
- size="small"
58
- v-model="form.eta"
59
- type="date"
60
- value-format="yyyy-MM-dd HH:mm:ss"
61
- placeholder="请选择预计到港日期"
62
- ></el-date-picker>
63
- </el-form-item>
53
+ <el-form-item label="ETA" prop="eta" label-width="100">
54
+ <div style="display: flex; flex-direction: row; align-items: center">
55
+ <el-date-picker
56
+ style="width: 75%"
57
+ clearable
58
+ size="small"
59
+ v-model="form.eta"
60
+ type="date"
61
+ value-format="yyyy-MM-dd HH:mm:ss"
62
+ placeholder="请选择预计到港日期"
63
+ ></el-date-picker>
64
+ <el-button type="text" @click="refreshUpdateTime">更新</el-button>
65
+ </div>
66
+ </el-form-item>
64
67
  </el-col>
65
68
  <el-col :span="6">
66
69
  <el-form-item label="实际到港日" prop="actualArrivalDate" label-width="90px">
@@ -212,6 +215,7 @@
212
215
  placeholder="请输入毛重"
213
216
  size="mini"
214
217
  v-decimal="3"
218
+ @input="limitDecimalPlaces(index, scope1.$index, scope2.$index, scope2.row, 'packageGrossWeight')"
215
219
  ></el-input>
216
220
  </el-form-item>
217
221
  </template>
@@ -230,6 +234,7 @@
230
234
  placeholder="请输入皮重"
231
235
  size="mini"
232
236
  v-decimal="3"
237
+ @input="limitDecimalPlaces(index, scope1.$index, scope2.$index, scope2.row, 'packageTareWeight')"
233
238
  ></el-input>
234
239
  </el-form-item>
235
240
  </template>
@@ -248,6 +253,7 @@
248
253
  placeholder="请输入净重"
249
254
  size="mini"
250
255
  v-decimal="3"
256
+ @input="limitDecimalPlaces(index, scope1.$index, scope2.$index, scope2.row, 'packageNetWeight')"
251
257
  ></el-input>
252
258
  </el-form-item>
253
259
  </template>
@@ -452,7 +458,7 @@ import {
452
458
  updateWithContainer,
453
459
  updateWithContainerAndInvoice,
454
460
  saveDraft,
455
- getDraft
461
+ getDraft, refreshUpdateTime
456
462
  } from '../../../api/biz/bizShipment'
457
463
  import { generateFinalInvoiceByShipmentId } from '../../../api/biz/bizInvoice'
458
464
  import { updateBizContractDetail } from '../../../api/biz/bizContractDetail'
@@ -679,13 +685,13 @@ export default {
679
685
  },
680
686
 
681
687
  limitDecimalPlaces(index, scope1Index, scope2Index, data, type) {
682
- let value = data[type]
683
- const decimalPlaces = 3
684
- if (!isNaN(value)) {
685
- value = parseFloat(value).toFixed(decimalPlaces)
686
- value = parseFloat(value).toString()
687
- data[type] = value
688
- }
688
+ // let value = data[type]
689
+ // const decimalPlaces = 3
690
+ // if (!isNaN(value)) {
691
+ // value = parseFloat(value).toFixed(decimalPlaces)
692
+ // value = parseFloat(value).toString()
693
+ // data[type] = value
694
+ // }
689
695
  if (type == 'packageGrossWeight') {
690
696
  this.changePackageGrossWeight(index, scope1Index, scope2Index)
691
697
  } else if (type == 'packageTareWeight') {
@@ -1314,6 +1320,17 @@ export default {
1314
1320
  this.isDraft = false
1315
1321
  }
1316
1322
  }
1323
+ },
1324
+ refreshUpdateTime() {
1325
+ if (this.form.shipmentId) {
1326
+ const loading = this.openLoading()
1327
+ refreshUpdateTime(this.form.shipmentId).then((res) => {
1328
+ loading.close()
1329
+ this.$modal.msgSuccess('更新成功')
1330
+ }).catch(() => {
1331
+ loading.close();
1332
+ })
1333
+ }
1317
1334
  }
1318
1335
  }
1319
1336
  }
@@ -198,17 +198,17 @@
198
198
  <el-row>
199
199
  <el-col :span="8">
200
200
  <el-form-item :label="$t('contract.company') + ':'">
201
- {{ 'TTYY INTERNATIONAL LIMITED' }}
201
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.companyName : ""}}
202
202
  </el-form-item>
203
203
  </el-col>
204
204
  <el-col :span="8">
205
205
  <el-form-item :label="$t('contract.taxId') + ':'">
206
- {{ '73855725-000-23-0' }}
206
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.taxNumber : "" }}
207
207
  </el-form-item>
208
208
  </el-col>
209
209
  <el-col :span="8">
210
210
  <el-form-item :label="$t('contract.address') + ':'">
211
- {{ 'FLAT/RM 07, 12/F, CHEVALIER COMMERCIAL CENTRE, 8 WANG HOI ROAD, KOWLOON BAY' }}
211
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.address : "" }}
212
212
  </el-form-item>
213
213
  </el-col>
214
214
  </el-row>
@@ -216,19 +216,19 @@
216
216
  <el-row>
217
217
  <el-col :span="8">
218
218
  <el-form-item :label="$t('contract.contact') + ':'">
219
- {{ 'Ms. Zhou' }}
219
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.contactPerson : "" }}
220
220
  </el-form-item>
221
221
  </el-col>
222
222
  <el-col :span="8">
223
223
  <el-form-item :label="$t('contract.phoneNumber') + ':'">
224
- {{ '00-852 53816912' }}
224
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.phoneNumber : "" }}
225
225
  </el-form-item>
226
226
  </el-col>
227
227
  <el-col :span="8"></el-col>
228
228
  </el-row>
229
229
 
230
230
  <el-row>
231
- <el-form-item :label="$t('contract.email') + ':'">{{ 'info@tyzltech.com' }}</el-form-item>
231
+ <el-form-item :label="$t('contract.email') + ':'">{{ secondNotifyInfoInfo ? secondNotifyInfoInfo.email : "" }}</el-form-item>
232
232
  </el-row>
233
233
  <el-divider></el-divider>
234
234
  <div class="sub-title mb20">{{ $t('contract.otherInfo') }}</div>
@@ -303,6 +303,7 @@ import { listBizContractCompany } from '../../../api/biz/bizContractCompany'
303
303
  import BillPdf from './billPdf.vue'
304
304
  import { listCompanyBillGoods } from '../../../api/biz/bizCompanyBillGoods'
305
305
  import EditBill from './editBill.vue'
306
+ import { getSecondNotifyInfo } from '../../../api/biz/bizContract'
306
307
  // import { getSaleContractInfo } from '../../../api/biz/bizContract'
307
308
 
308
309
  export default {
@@ -368,7 +369,8 @@ export default {
368
369
  notifierCompanyId: [{ required: true, trigger: 'blur' }],
369
370
  goodsName: [{ required: true, trigger: 'blur' }]
370
371
  },
371
- isMobile: document.body.clientWidth <= 768
372
+ isMobile: document.body.clientWidth <= 768,
373
+ secondNotifyInfoInfo: null
372
374
  }
373
375
  },
374
376
  created() {
@@ -378,6 +380,7 @@ export default {
378
380
  if (printModel == 1) {
379
381
  this.printModel = true
380
382
  }
383
+ this.getSecondNotifyInfo();
381
384
  // this.getSaleContractInfo(this.contract.dealId)
382
385
  },
383
386
  methods: {
@@ -436,6 +439,11 @@ export default {
436
439
  }
437
440
  })
438
441
  },
442
+ getSecondNotifyInfo() {
443
+ getSecondNotifyInfo().then((res) => {
444
+ this.secondNotifyInfoInfo = res.data;
445
+ })
446
+ },
439
447
  //更改收货人或者通知人公司时 相应显示变更
440
448
  changeSubCompany(val, type) {
441
449
  if (type == 'delivery') {
@@ -0,0 +1,67 @@
1
+ <!--
2
+ * @Author: zhangpengwei@1338418459736990.onaliyun.com zhangpengwei@1338418459736990.onaliyun.com
3
+ * @Date: 2024-08-19 15:46:00
4
+ * @LastEditors: zhangpengwei@1338418459736990.onaliyun.com zhangpengwei@1338418459736990.onaliyun.com
5
+ * @LastEditTime: 2024-08-20 13:41:47
6
+ * @FilePath: /doctor-admin-components 公共组件/packages/src/views/biz/contractTracing/shipmentPurchaseAmountEditDialog.vue
7
+ * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
8
+ -->
9
+ <template>
10
+ <div v-if="list.length">
11
+ <div class="bold" style="margin-bottom:10px">历史修正记录</div>
12
+ <div class="wrap" v-for="listItem in list" :key="listItem.changeId">
13
+ <div class="row-wrap">
14
+ <div class="time">{{ utc2local(listItem.changeTime, 'yyyy-MM-DD HH:mm:ss') }}</div>
15
+ <div class="time">修改人{{ listItem.operName }}</div>
16
+ </div>
17
+ <div class="row-wrap-1">
18
+ <div class="title bold">修改内容:</div>
19
+ <div>{{ listItem.changeContent }}</div>
20
+ </div>
21
+ <div class="row-wrap-1" v-if="listItem.changeReason">
22
+ <div class="title bold">修改原因:</div>
23
+ <div>{{ listItem.changeReason }}</div>
24
+ </div>
25
+ </div>
26
+ </div>
27
+
28
+ </template>
29
+ <script>
30
+ export default {
31
+ props: {
32
+ list: {
33
+ type: Array,
34
+ default: () => []
35
+ }
36
+ },
37
+ name: 'changrLogList',
38
+ data() {
39
+ return {}
40
+ }
41
+ }
42
+ </script>
43
+ <style scoped lang="scss">
44
+ .wrap {
45
+ padding:10px 20px;
46
+ margin-bottom: 10px;
47
+ background-color: #f2f2f2;
48
+ }
49
+ .bold {
50
+ font-weight: bold;
51
+ }
52
+ .row-wrap {
53
+ display: flex;
54
+ justify-content: space-between;
55
+ margin-bottom: 10px;
56
+ .time {
57
+ font-size:12px;
58
+ }
59
+ }
60
+ .row-wrap-1 {
61
+ display: flex;
62
+ margin-bottom: 10px;
63
+ .title {
64
+ min-width: 70px;
65
+ }
66
+ }
67
+ </style>
@@ -157,22 +157,22 @@
157
157
  <el-collapse-item name="3">
158
158
  <template slot="title">
159
159
  <el-row style="width: 75%">
160
- <el-form-item class="mt20" :label="$t('contract.secondNotifier') + ':'">{{ 'TTYY INTERNATIONAL LIMITED' }}</el-form-item>
160
+ <el-form-item class="mt20" :label="$t('contract.secondNotifier') + ':'">{{ secondNotifyInfoInfo ? secondNotifyInfoInfo.companyName : "" }}</el-form-item>
161
161
  </el-row>
162
162
  </template>
163
163
  <el-form-item :label="$t('contract.taxId') + ':'">
164
- {{ '73855725-000-23-0' }}
164
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.taxNumber : "" }}
165
165
  </el-form-item>
166
166
  <el-form-item :label="$t('contract.notifierAddress') + ':'">
167
- {{ 'FLAT/RM 07, 12/F, CHEVALIER COMMERCIAL CENTRE, 8 WANG HOI ROAD, KOWLOON BAY' }}
167
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.address : "" }}
168
168
  </el-form-item>
169
169
  <el-form-item :label="$t('contract.contact') + ':'">
170
- {{ 'Ms. Zhou' }}
170
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.contactPerson : "" }}
171
171
  </el-form-item>
172
172
  <el-form-item :label="$t('contract.phoneNumber') + ':'">
173
- {{ '00-852 53816912' }}
173
+ {{ secondNotifyInfoInfo ? secondNotifyInfoInfo.phoneNumber : "" }}
174
174
  </el-form-item>
175
- <el-form-item :label="$t('contract.email') + ':'">{{ 'info@tyzltech.com' }}</el-form-item>
175
+ <el-form-item :label="$t('contract.email') + ':'">{{ secondNotifyInfoInfo ? secondNotifyInfoInfo.email : "" }}</el-form-item>
176
176
  </el-collapse-item>
177
177
  </el-collapse>
178
178
 
@@ -288,7 +288,7 @@ import { listBizContractCompany } from '../../../api/biz/bizContractCompany'
288
288
  import SubCompanyDialog from './subCompanyDialog.vue'
289
289
  import BillGoods from './billGoods.vue'
290
290
  import { listCompanyBillGoods } from '../../../api/biz/bizCompanyBillGoods'
291
- import { getBizContract, changeBizStatus } from '../../../api/biz/bizContract'
291
+ import { getBizContract, changeBizStatus, getSecondNotifyInfo } from '../../../api/biz/bizContract'
292
292
  import FileUpload from '../../../components/FileUpload/s3.vue'
293
293
 
294
294
  export default {
@@ -336,7 +336,8 @@ export default {
336
336
  notifierCompanyId: [{ required: true, trigger: 'blur', message: this.$t('bill.tip4') }],
337
337
  goodsName: [{ required: true, trigger: 'blur' }]
338
338
  },
339
- contract: null
339
+ contract: null,
340
+ secondNotifyInfoInfo: null
340
341
  }
341
342
  },
342
343
  watch: {
@@ -367,7 +368,9 @@ export default {
367
368
  }
368
369
  }
369
370
  },
370
- created() {},
371
+ created() {
372
+ this.getSecondNotifyInfo();
373
+ },
371
374
  methods: {
372
375
  async handleEdit(contractId, dealId) {
373
376
  const loading = this.openLoading()
@@ -597,7 +600,12 @@ export default {
597
600
  }
598
601
  }
599
602
  })
600
- }
603
+ },
604
+ getSecondNotifyInfo() {
605
+ getSecondNotifyInfo().then((res) => {
606
+ this.secondNotifyInfoInfo = res.data;
607
+ })
608
+ },
601
609
  }
602
610
  }
603
611
  </script>
@@ -0,0 +1,102 @@
1
+ <!--
2
+ * @Author: zhangpengwei@1338418459736990.onaliyun.com zhangpengwei@1338418459736990.onaliyun.com
3
+ * @Date: 2024-08-20 10:37:30
4
+ * @LastEditors: zhangpengwei@1338418459736990.onaliyun.com zhangpengwei@1338418459736990.onaliyun.com
5
+ * @LastEditTime: 2024-08-20 13:45:55
6
+ * @FilePath: /doctor-admin-components 公共组件/packages/src/views/biz/contractTracing/queryDeductionRecords.vue
7
+ * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
8
+ -->
9
+ <template>
10
+ <el-dialog
11
+ title="定金扣减记录"
12
+ :visible.sync="dialogVisible"
13
+ width="800px"
14
+ :modal="false"
15
+ >
16
+ <el-table
17
+ :data="tableList"
18
+ :cell-style="{'text-align': 'center'}"
19
+ :header-cell-style="{'text-align': 'center'}"
20
+ >
21
+ <el-table-column
22
+ prop="billOfLadingNo"
23
+ label="提单号"
24
+ width="180">
25
+ </el-table-column>
26
+ <el-table-column
27
+ prop="containerNumber"
28
+ label="柜数"
29
+ width="180">
30
+ </el-table-column>
31
+ <el-table-column
32
+ prop="purchaseDepositTotalAmount"
33
+ label="定金总额">
34
+ <template slot-scope="{ row }">
35
+ {{ row.purchaseDepositTotalAmount ? "$" + row.purchaseDepositTotalAmount : '' }}
36
+ </template>
37
+ </el-table-column>
38
+ <el-table-column
39
+ prop="purchaseDepositBalance"
40
+ label="上次剩余定金">
41
+ <template slot-scope="{ row }">
42
+ {{ row.purchaseDepositBalance ? "$" + row.purchaseDepositBalance : '' }}
43
+ </template>
44
+ </el-table-column>
45
+ <el-table-column
46
+ prop="purchaseDepositAmount"
47
+ label="扣减定金">
48
+ <template slot-scope="{ row }">
49
+ <span class="edit-style" v-if="row.purchaseDepositAmount" @click.stop="jumpFileManage(row)">{{ row.purchaseDepositAmount ? "$" + row.purchaseDepositAmount : '' }}</span>
50
+ </template>
51
+ </el-table-column>
52
+ <el-table-column
53
+ prop="purchaseDepositRemainAmount"
54
+ label="定金余额">
55
+ <template slot-scope="{ row }">
56
+ {{ row.purchaseDepositRemainAmount ? "$" + row.purchaseDepositRemainAmount : '' }}
57
+ </template>
58
+ </el-table-column>
59
+ </el-table>
60
+ </el-dialog>
61
+ </template>
62
+
63
+ <script>
64
+ import { deductionRecords } from '../../../api/biz/bizShipment'
65
+
66
+ export default {
67
+ name: 'DoctorAdminComponentsQueryDeductionRecords',
68
+
69
+ data() {
70
+ return {
71
+ tableList:[],
72
+ dialogVisible: false
73
+ };
74
+ },
75
+
76
+ mounted() {
77
+
78
+ },
79
+
80
+ methods: {
81
+ handlerOpen(shipmentId) {
82
+ this.dialogVisible = true
83
+ deductionRecords({shipmentId}).then((res) => {
84
+ this.tableList = res.rows
85
+ })
86
+ },
87
+ jumpFileManage(row) {
88
+ window.open(`/contract/tracing/detail/${row.purchaseContractId}?activeName=fourth&deductionRecordsShipmentId=${row.shipmentId}`)
89
+ }
90
+
91
+
92
+ },
93
+ };
94
+ </script>
95
+
96
+ <style lang="scss" scoped>
97
+ .edit-style {
98
+ cursor: pointer;
99
+ color: #409eff;
100
+ }
101
+
102
+ </style>
@@ -2,115 +2,238 @@
2
2
  * @Author: zhangpengwei 15038779532@163.com
3
3
  * @Date: 2023-07-31 17:40:56
4
4
  * @LastEditors: zhangpengwei@1338418459736990.onaliyun.com zhangpengwei@1338418459736990.onaliyun.com
5
- * @LastEditTime: 2024-04-02 17:58:33
5
+ * @LastEditTime: 2024-08-20 14:23:13
6
6
  * @FilePath: /doctor-admin-components/packages/src/views/biz/contractTracing/chargingDialog.vue
7
7
  * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
8
8
  -->
9
9
  <template>
10
10
  <div class="app-container">
11
11
  <!-- 合同争议详情对话框 -->
12
- <el-dialog :title="title" :visible.sync="open" width="800px" append-to-body>
12
+ <el-dialog :title="title" :visible.sync="open" width="1000px" append-to-body>
13
13
  <el-form :model="form">
14
- <el-row>
14
+ <el-table
15
+ :data="form.containerPurchaseAmountRespList"
16
+ >
17
+ <el-table-column align="center" prop="containerNo" label="柜号"></el-table-column>
18
+ <el-table-column align="center" label="货物名称">
19
+ <template slot-scope="{ row }">
20
+ <div style="white-space: pre-line !important" v-for="(item, index) in getColumnPropArray(row)" :key="index">{{item.askName}}</div>
21
+ </template>
22
+ </el-table-column>
23
+ <el-table-column align="center" label="净量(MT)" prop="goodsNetWeight">
24
+ <template slot-scope="{ row }">
25
+ <div style="white-space: pre-line !important" v-for="(item, index) in getColumnPropArray(row)" :key="index">
26
+ <span :style="item.goodsNetWeight != item.purchaseActualNetWeight ? 'color:red' : ''">{{item.goodsNetWeight}}</span>
27
+ </div>
28
+ </template>
29
+ </el-table-column>
30
+ <el-table-column align="center" label="单价($)" width="100" prop="purchasePriceResult">
31
+ <template slot-scope="{ row }">
32
+ <div style="white-space: pre-line !important" v-for="(item, index) in getColumnPropArray(row)" :key="index">
33
+ <span :style="item.purchasePriceResult != item.purchaseActualUnitPrice ? 'color:red' : ''"> {{item.purchasePriceResult}}</span>
34
+ </div>
35
+ </template>
36
+ </el-table-column>
37
+ <el-table-column align="center" label="修正净重(MT)" width="130" prop="purchaseActualNetWeight">
38
+ <template slot-scope="{ row }">
39
+ <div style="white-space: pre-line !important" v-for="(item, index) in getColumnPropArray(row)" :key="index">
40
+ <span :style="item.goodsNetWeight != item.purchaseActualNetWeight ? 'color:red' : ''">{{item.purchaseActualNetWeight}}</span>
41
+ <i class="el-icon-edit-outline edit-style" @click.stop="editInfo(item,'purchaseActualNetWeight', '1')"/>
42
+ </div>
43
+ </template>
44
+ </el-table-column>
45
+ <el-table-column align="center" label="修正单价($)" width="130" prop="purchaseActualUnitPrice">
46
+ <template slot-scope="{ row }">
47
+ <div style="white-space: pre-line !important" v-for="(item, index) in getColumnPropArray(row)" :key="index">
48
+ <span :style="item.purchasePriceResult != item.purchaseActualUnitPrice ? 'color:red' : ''"> {{item.purchaseActualUnitPrice}}</span>
49
+ <i class="el-icon-edit-outline edit-style" @click.stop="editInfo(item, 'purchaseActualUnitPrice', '1')"/>
50
+ </div>
51
+ </template>
52
+ </el-table-column>
53
+ <el-table-column align="center" prop="amount" label="采购金额($)" width="130"></el-table-column>
54
+ <el-table-column align="center" prop="purchaseDepositAmount" label="扣减定金($)" width="130"></el-table-column>
55
+ <el-table-column align="center" label="尾款">
56
+ <template slot-scope="{ row }">{{ (row.amount - row.purchaseDepositAmount).toFixed(2) }}</template>
57
+ </el-table-column>
58
+ </el-table>
59
+ <div class="my-footer">
60
+ <div style="width:65px;text-align:center"> 总计</div>
61
+ <div> 柜数:{{ form && form.containerPurchaseAmountRespList && form.containerPurchaseAmountRespList.length }}柜</div>
62
+ <div>装运总净重: {{form.totalNetWeight + 'MT'}}</div>
63
+ <div>装运总修正净重:{{ form.actualTotalNetWeight || 0 + 'MT'}}</div>
64
+ <div>采购总金额:$ {{ form.totalPurchaseAmount }}
65
+ <i class="el-icon-edit-outline edit-style" @click.stop="editInfo(form,'purchaseActualTotalAmount', '2')"/>
66
+ </div>
67
+ <div>本次扣减定金:$ {{ form.purchaseDepositAmount }}
68
+ <i class="el-icon-edit-outline edit-style" @click.stop="editInfo(form,'purchaseDepositAmount', '2')"/>
69
+ </div>
70
+ <div>采购总尾款:$ {{ form.totalPurchaseAmount - form.purchaseDepositAmount }}</div>
71
+ </div>
72
+ <!-- 自定义合并行 -->
73
+ <div>
74
+
75
+ </div>
76
+ <el-row style="margin-top:20px">
15
77
  <el-col :span="8">
16
- <el-row>
17
- <el-col :span="18">
18
- <el-form-item label="本次扣减定金:"
19
- >{{ '$' + form.purchaseDepositAmount ? form.purchaseDepositAmount : '' }}
20
- <el-tooltip class="item" effect="dark" content="当前提单抵扣定金金额" placement="top-start">
21
- <span>
22
- <i class="el-icon-warning" />
23
- </span>
24
- </el-tooltip>
25
- </el-form-item>
26
- </el-col>
27
- <el-col :span="6">
28
- <el-button type="text" @click="updateShipmentDepositAmount(form.shipmentId, form.purchaseDepositAmount)">编辑</el-button>
29
- </el-col>
30
- </el-row>
78
+ <el-form-item label="本次装运总修正净重:">
79
+ <el-tooltip class="ml10" effect="dark" content="本次一共装了多少吨的货(取修正重量汇总)" placement="top">
80
+ <span>
81
+ {{ form.actualTotalNetWeight || 0 + 'MT'}}
82
+ <i class="el-icon-question"></i>
83
+ </span>
84
+ </el-tooltip>
85
+ </el-form-item>
31
86
  </el-col>
32
87
  <el-col :span="8">
33
- <el-form-item label="上次剩余定金余额:">
34
- {{ '$' + form.purchaseDepositBalanceAmount ? form.purchaseDepositBalanceAmount : '' }}
35
- <el-tooltip class="item" effect="dark" content="还剩多少定金可抵扣,可为负数" placement="top-start">
88
+ <el-form-item label="本次装运柜数:">
89
+ <el-tooltip class="ml10" effect="dark" content="当前装运装了多少柜" placement="top">
36
90
  <span>
37
- <i class="el-icon-warning" />
38
- </span>
39
- </el-tooltip>
91
+ {{form && form.containerPurchaseAmountRespList && form.containerPurchaseAmountRespList.length }}柜
92
+ <i class="el-icon-question"></i>
93
+ </span>
94
+ </el-tooltip>
40
95
  </el-form-item>
41
96
  </el-col>
42
97
  <el-col :span="8">
43
- <el-form-item label="定金总额:"
44
- >{{ '$' + form.totalPurchaseDepositAmount ? form.totalPurchaseDepositAmount : '' }}
45
- <el-tooltip class="item" effect="dark" content="定金发票一共有多少" placement="top-start">
98
+ <el-form-item label="定金总额:">
99
+ <el-tooltip class="ml10" effect="dark" content="采购定金发票一共已付多少金额" placement="top">
100
+ <span>
101
+ $ {{
102
+ form.totalPurchaseDepositAmount
103
+ }}
104
+ <i class="el-icon-question"></i>
105
+ </span>
106
+ </el-tooltip>
107
+ </el-form-item>
108
+ </el-col>
109
+ <el-col :span="8">
110
+ <el-form-item label="总已装运净重:">
111
+ <el-tooltip class="ml10" effect="dark" content="该采购合同一共装了多少吨的货" placement="top">
46
112
  <span>
47
- <i class="el-icon-warning" />
48
- </span>
49
- </el-tooltip>
113
+ {{form.totalNetWeight + 'MT'}}
114
+ <i class="el-icon-question"></i>
115
+ </span>
116
+ </el-tooltip>
50
117
  </el-form-item>
51
118
  </el-col>
52
- </el-row>
53
- <el-row>
54
119
  <el-col :span="8">
55
- <el-form-item label="采购尾款:">{{ '$' + (form.totalPurchaseAmount - form.purchaseDepositAmount).toFixed(2) }}</el-form-item>
120
+ <el-form-item label="总已装运柜数:">
121
+ <el-tooltip class="ml10" effect="dark" content="此采购合同一共已经装了多少柜(根据最新的装运数据实时刷新)" placement="top">
122
+ <span>
123
+ {{form.loadedContainerNumber + '柜'}}
124
+ <i class="el-icon-question"></i>
125
+ </span>
126
+ </el-tooltip>
127
+ </el-form-item>
56
128
  </el-col>
57
129
  <el-col :span="8">
58
- <el-form-item label="装运总价:">{{ '$' + form.totalPurchaseAmount }}</el-form-item>
130
+ <el-form-item label="上次剩余定金:">
131
+ <el-tooltip class="ml10" effect="dark" content="创建时间在此之前的装运还剩多少定金可以抵扣,不会随着上次的抵扣金额中途变更而刷新,可为负数" placement="top">
132
+ <span>
133
+ <span v-if="form.purchaseDepositBalanceAmount == null"></span>
134
+ <span v-else>
135
+ $ {{ form.purchaseDepositBalanceAmount }}
136
+ <span @click.stop="queryDeductionRecords" class="edit-style">点击查询扣减记录</span>
137
+ </span>
138
+ <i class="el-icon-question"></i>
139
+ </span>
140
+ </el-tooltip>
141
+ </el-form-item>
59
142
  </el-col>
60
- </el-row>
61
- <el-row>
62
143
  <el-col :span="8">
63
- <el-form-item label="重量/柜数:">{{ form.totalNetWeight + 'MT/' + form.containerNumber + '柜' }}</el-form-item>
144
+ <el-form-item label="签约总净重:">
145
+ <el-tooltip class="ml10" effect="dark" content="该采购合同一共签了多少吨的货(实时刷新合同的签约重量)" placement="top">
146
+ <span>
147
+ {{form.signedContractWeight + 'MT'}}
148
+ <i class="el-icon-question"></i>
149
+ </span>
150
+ </el-tooltip>
151
+ </el-form-item>
64
152
  </el-col>
65
153
  <el-col :span="8">
66
- <el-form-item label="已装柜数/签约柜数:">{{ form.loadedContainerNumber + '柜/' + form.signedContainerNumber + '柜' }}</el-form-item>
154
+ <el-form-item label="本次扣减定金基于总柜数:">
155
+ <el-tooltip class="ml10" effect="dark" content="生成此装运时,采购合同签了多少柜(在此装运后再修改合同不刷新该数据)" placement="top">
156
+ <span>
157
+ {{(form.purchaseDepositContainerNumber || 0) + '柜'}}
158
+ <i class="el-icon-question"></i>
159
+ <span class="edit-style" @click.stop="editInfo(form,'purchaseDepositContainerNumber', '2')">编辑</span>
160
+ </span>
161
+ </el-tooltip>
162
+ </el-form-item>
67
163
  </el-col>
68
- </el-row>
69
-
70
- <el-table :data="form.containerPurchaseAmountRespList">
71
- <el-table-column align="center" prop="containerNo" label="柜号"></el-table-column>
72
- <el-table-column align="center" label="货物名称">
73
- <template slot-scope="{ row }">
74
- <div style="white-space: pre-line !important">{{ getColumnProp(row, 'askName') }}</div>
75
- </template>
76
- </el-table-column>
77
- <el-table-column align="center" label="重量(MT)">
78
- <template slot-scope="{ row }">
79
- <div style="white-space: pre-line !important">{{ getColumnProp(row, 'goodsNetWeight') }}</div>
80
- </template>
81
- </el-table-column>
82
- <el-table-column align="center" label="单价($)" width="130">
83
- <template slot-scope="{ row }">
84
- <div v-for="(item, index) in getColumnPropArray(row)" :key="index">
85
- {{ item.purchasePriceResult }};
86
- <!-- 显示每个项的值 -->
87
- <el-tooltip
88
- v-if="item.quoteType != 'FIXED' && row.pointPrice"
89
- class="item"
90
- effect="dark"
91
- :content="getPurchaseAmountTip(item, row)"
92
- placement="top-start"
93
- >
94
- <span>
95
- <i class="el-icon-question" />
164
+ <el-col :span="8">
165
+ <el-form-item label="本次扣减定金:">
166
+ <el-tooltip class="ml10" effect="dark" content="当前装运抵扣了多少定金" placement="top">
167
+ <span>
168
+ <span v-if="form.purchaseDepositAmount == null"/>
169
+ <span v-else>
170
+ $ {{ form.purchaseDepositAmount}}
171
+ </span>
172
+ <i class="el-icon-question"></i>
173
+ </span>
174
+ </el-tooltip>
175
+ </el-form-item>
176
+ </el-col>
177
+ <el-col :span="8">
178
+ <el-form-item label="签约总柜:">
179
+ <el-tooltip class="ml10" effect="dark" content="采购合同签了多少柜(根据最新的合同数据实时刷新)" placement="top">
180
+ <span>
181
+ {{(form.signedContainerNumber || 0) + '柜'}}
182
+ <i class="el-icon-question"></i>
183
+ </span>
184
+ </el-tooltip>
185
+ </el-form-item>
186
+ </el-col>
187
+ <el-col :span="8">
188
+ <el-form-item label="本次剩余定金:">
189
+ <el-tooltip class="ml10" effect="dark" content="本次还剩多少定金可供下次抵扣,不会随着下次的抵扣行为刷新,可为负数" placement="top">
190
+ <span>
191
+ <span v-if="form.thisRemainingDeposit == null"></span>
192
+ <span v-else>
193
+ $ {{ form.thisRemainingDeposit }}
194
+ </span>
195
+ <i class="el-icon-question"></i>
196
+ </span>
197
+ </el-tooltip>
198
+ </el-form-item>
199
+ </el-col>
200
+ <el-col :span="8">
201
+ <el-form-item label="总剩余定金:">
202
+ <el-tooltip class="ml10" effect="dark" content="当前时间该合同还剩余多少定金可以用于抵扣,随着每次的抵扣行为实时刷新,可为负数" placement="top">
203
+ <span>
204
+ <span v-if="form.purchaseDepositBalanceAmount == null"></span>
205
+ <span v-else>
206
+ $ {{ form.purchaseDepositBalanceAmount }}
96
207
  </span>
208
+ <i class="el-icon-question"></i>
209
+ </span>
97
210
  </el-tooltip>
211
+ </el-form-item>
212
+ </el-col>
213
+ <el-col :span="24">
214
+ <el-form-item>
215
+ <div>
216
+ <span style="font-weight: bold;margin-right:5px;">备注:</span>
217
+ <el-button size="mini" v-if="!remarkEditable" type="primary" @click.stop="remarkEditable = true">编辑备注</el-button>
218
+ <el-button size="mini" v-else type="success" @click.stop="editRemark">保存备注</el-button>
98
219
  </div>
99
- </template>
100
- </el-table-column>
101
- <el-table-column align="center" prop="amount" label="小计($)" width="130"></el-table-column>
102
- <el-table-column align="center" prop="purchaseDepositAmount" label="扣减定金($)" width="130"></el-table-column>
103
- <el-table-column align="center" label="单柜尾款">
104
- <template slot-scope="{ row }">{{ (row.amount - row.purchaseDepositAmount).toFixed(2) }}</template>
105
- </el-table-column>
106
- </el-table>
107
- </el-form>
220
+ <el-input type="textarea" :rows="2" v-model="form.remark" :disabled="!remarkEditable"/>
221
+ </el-form-item>
222
+ </el-col>
223
+ </el-row>
224
+ </el-form>
225
+ <ShipmentPurchaseAmountEditDialog ref="ShipmentPurchaseAmountEditDialog" @refresh="refresh"></ShipmentPurchaseAmountEditDialog>
226
+ <ChangrLogList :list="form.changeLogList"></ChangrLogList>
227
+ <QueryDeductionRecords ref="QueryDeductionRecords"></QueryDeductionRecords>
108
228
  </el-dialog>
109
229
  </div>
110
230
  </template>
111
231
 
112
232
  <script>
113
233
  import { getPurchaseAmount, updateBizShipment } from '../../../api/biz/bizShipment'
234
+ import ShipmentPurchaseAmountEditDialog from './shipmentPurchaseAmountEditDialog.vue'
235
+ import ChangrLogList from './changrLogList.vue'
236
+ import QueryDeductionRecords from './queryDeductionRecords.vue'
114
237
 
115
238
  export default {
116
239
  name: 'ShipmentPurchaseAmount',
@@ -119,19 +242,28 @@ export default {
119
242
  // 遮罩层
120
243
  loading: true,
121
244
  // 弹出层标题
122
- title: '',
245
+ title: '尾款计算明细',
123
246
  // 是否显示弹出层
124
247
  open: false,
125
248
  // 表单参数
126
- form: {},
249
+ form: {
250
+ changrLogList: [],
251
+ },
127
252
  // 非单个禁用
128
253
  single: true,
129
254
  // 非多个禁用
130
255
  multiple: true,
131
256
  //
132
- contract: null
257
+ contract: null,
258
+ remarkEditable: false,
259
+ tableList: []
133
260
  }
134
261
  },
262
+ components: {
263
+ ShipmentPurchaseAmountEditDialog,
264
+ ChangrLogList,
265
+ QueryDeductionRecords
266
+ },
135
267
  props: {
136
268
  getContractFileInfoCallback: {
137
269
  type: Function
@@ -140,6 +272,97 @@ export default {
140
272
  created() {},
141
273
  mounted() {},
142
274
  methods: {
275
+ /**
276
+ * @description: 查询扣减记录
277
+ * @return {*}
278
+ */
279
+ queryDeductionRecords() {
280
+ if(!this.form.shipmentId) {
281
+ this.$message.error('shipmentId不能为空')
282
+ return
283
+ }
284
+ this.$refs.QueryDeductionRecords.handlerOpen(this.form.shipmentId)
285
+
286
+ },
287
+ /**
288
+ * @description: 编辑备注
289
+ * @return {*}
290
+ */
291
+ editRemark() {
292
+ updateBizShipment({
293
+ shipmentId: this.form.shipmentId,
294
+ remark: this.form.remark
295
+ }).then(() => {
296
+ this.$message({
297
+ type: 'success',
298
+ message: '修改成功'
299
+ })
300
+ this.refresh()
301
+ this.remarkEditable = false
302
+ })
303
+ },
304
+ // 编辑信息
305
+ editInfo(detail, prop, type) {
306
+ this.remarkEditable = false
307
+ let textInfo = {}
308
+ let info = {}
309
+ if(type == 1) {
310
+ info = {
311
+ containerId: detail.containerId,
312
+ containerDetailId: detail.containerDetailId,
313
+ purchaseActualNetWeight: detail.purchaseActualNetWeight,
314
+ purchaseActualUnitPrice: detail.purchaseActualUnitPrice,
315
+ }
316
+ // 修改表格净重
317
+ if(prop == 'purchaseActualNetWeight') {
318
+ textInfo = {
319
+ title: `请输入柜号${detail.containerNo}的修正净重`,
320
+ label: detail.askName,
321
+ unit: 'MT'
322
+ }
323
+ }
324
+ // 修改表格单价
325
+ if(prop == 'purchaseActualUnitPrice') {
326
+ textInfo = {
327
+ title: `请输入柜号${detail.containerNo}的修正单价`,
328
+ label: detail.askName,
329
+ unit: '$'
330
+ }
331
+ }
332
+ }
333
+
334
+ if(type == 2) {
335
+ info = {
336
+ shipmentId: detail.shipmentId,
337
+ purchaseDepositContainerNumber: detail.purchaseDepositContainerNumber,
338
+ purchaseActualTotalAmount: detail.totalPurchaseAmount,
339
+ purchaseDepositAmount: detail.purchaseDepositAmount,
340
+ }
341
+ if(prop == 'purchaseDepositContainerNumber') {
342
+ textInfo = {
343
+ title: `请输入本次扣减定金基于总柜数`,
344
+ label: '本次扣减定金基于总柜数',
345
+ unit: '柜'
346
+ }
347
+ }
348
+ if(prop == 'purchaseActualTotalAmount') {
349
+ textInfo = {
350
+ title: `直接修改采购总金额`,
351
+ label: '',
352
+ unit: '$'
353
+ }
354
+ }
355
+
356
+ if(prop == 'purchaseDepositAmount') {
357
+ textInfo = {
358
+ title: `请输入本次扣减定金`,
359
+ label: '本次扣减定金',
360
+ unit: '$'
361
+ }
362
+ }
363
+ }
364
+ this.$refs.ShipmentPurchaseAmountEditDialog.handlerOpen(info, type, textInfo,prop)
365
+ },
143
366
  //更新装运采购定金
144
367
  updateShipmentDepositAmount(shipmentId, purchaseDepositAmount) {
145
368
  this.$prompt('本次扣减定金$', '请输入本次扣减定金', {
@@ -203,7 +426,24 @@ export default {
203
426
  this.form = res.data
204
427
  this.open = true
205
428
  })
429
+ },
430
+ refresh() {
431
+ this.handleShow(this.form.shipmentId)
432
+ this.getContractFileInfoCallback && this.getContractFileInfoCallback()
206
433
  }
207
434
  }
208
435
  }
209
436
  </script>
437
+ <style scoped lang="scss">
438
+ .edit-style {
439
+ cursor: pointer;
440
+ color: #409eff;
441
+ }
442
+ .my-footer {
443
+ display: flex;
444
+ justify-content: space-between;
445
+ background-color: #f5f7fa;
446
+ padding: 10px;
447
+ font-weight: bold;
448
+ }
449
+ </style>
@@ -0,0 +1,152 @@
1
+ <!--
2
+ * @Author: zhangpengwei@1338418459736990.onaliyun.com zhangpengwei@1338418459736990.onaliyun.com
3
+ * @Date: 2024-08-19 15:46:00
4
+ * @LastEditors: zhangpengwei@1338418459736990.onaliyun.com zhangpengwei@1338418459736990.onaliyun.com
5
+ * @LastEditTime: 2024-08-20 14:21:29
6
+ * @FilePath: /doctor-admin-components 公共组件/packages/src/views/biz/contractTracing/shipmentPurchaseAmountEditDialog.vue
7
+ * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
8
+ -->
9
+ <template>
10
+ <el-dialog
11
+ :title="title"
12
+ v-if="dialogVisible"
13
+ :visible.sync="dialogVisible"
14
+ width="40%"
15
+ :modal="false"
16
+ :before-close="handleClose">
17
+ <div>
18
+ <el-form ref="form" :model="form" label-width="200px">
19
+ <div v-if="prop == 'purchaseActualTotalAmount'">
20
+ <div>
21
+ 由于
22
+ </div>
23
+ <el-input
24
+ type="textarea"
25
+ placeholder="请详细说明是什么业务场景导致系统无法自动计算?"
26
+ :autosize="{ minRows: 2, maxRows: 4}"
27
+ v-model="changeReason"/>
28
+ </div>
29
+ <div v-if="prop == 'purchaseActualTotalAmount'" style="margin:20px 0">
30
+ 需要将采购总金额由$ <span style="color:#1890ff">{{ currentVal }}</span> 直接改成
31
+ </div>
32
+ <el-form-item :label="label">
33
+ <el-input v-decimal="decimal" v-model="form.vlaue" placeholder="请输入标签">
34
+ <template slot="prepend" v-if="unitPostion == 'pre'">{{ unit }}</template>
35
+ <template slot="append" v-if="unitPostion == 'append'">{{ unit }}</template>
36
+ </el-input>
37
+ </el-form-item>
38
+ </el-form>
39
+ </div>
40
+ <span slot="footer" class="dialog-footer">
41
+ <el-button @click="dialogVisible = false">取 消</el-button>
42
+ <el-button type="primary" @click="confirm">确 定</el-button>
43
+ </span>
44
+ </el-dialog>
45
+
46
+ </template>
47
+ <script>
48
+ import { containerEditBatch, updateBizShipment } from '../../../api/biz/bizShipment'
49
+ export default {
50
+ data() {
51
+ return {
52
+ dialogVisible: false,
53
+ title: '',
54
+ label:'',
55
+ form: {
56
+ vlaue:''
57
+ },
58
+ type:0,
59
+ prop:'',
60
+ info:{},
61
+ unit:'',
62
+ unitPostion:'pre',
63
+ changeReason:null,
64
+ currentVal:null,
65
+ decimal:0
66
+
67
+ }
68
+ },
69
+ methods: {
70
+ confirm() {
71
+ if(!this.form.vlaue) {
72
+ this.$message({
73
+ message: '请输入修改内容',
74
+ type: 'warning'
75
+ });
76
+ return;
77
+ }
78
+ // table内容修改净重 修改单价
79
+ if(this.type == 1) {
80
+ let info = {
81
+ containerId: this.info.containerId,
82
+ containerDetailId: this.info.containerDetailId
83
+ }
84
+ info[this.prop] = this.form.vlaue;
85
+
86
+ containerEditBatch([info]).then(res => {
87
+ this.$message({
88
+ message: '修改成功',
89
+ type: 'success'
90
+ });
91
+
92
+ this.$emit('refresh');
93
+ this.dialogVisible = false;
94
+ })
95
+ }
96
+ // shipment信息修改
97
+ if(this.type == 2) {
98
+ let info = {
99
+ shipmentId: this.info.shipmentId,
100
+ }
101
+ info[this.prop] = this.form.vlaue;
102
+ if(this.changeReason) {
103
+ info.changeReason = this.changeReason;
104
+ }
105
+
106
+ updateBizShipment(info).then(res => {
107
+ this.$message({
108
+ message: '修改成功',
109
+ type: 'success'
110
+ });
111
+
112
+ this.$emit('refresh');
113
+ this.dialogVisible = false;
114
+ })
115
+ }
116
+ },
117
+ handlerOpen(info, type, textInfo, prop) {
118
+ this.title = textInfo.title;
119
+ this.label = textInfo.label;
120
+ this.unit = textInfo.unit;
121
+ this.type = type;
122
+ this.prop = prop;
123
+ this.info = info;
124
+ this.form.vlaue = info[prop];
125
+ if(prop == 'purchaseActualTotalAmount') {
126
+ this.currentVal = info[prop];
127
+ this.form.vlaue = null
128
+ }
129
+
130
+ if(this.unit == 'MT' || this.unit == '柜') {
131
+ this.unitPostion = 'append'
132
+ if(this.unit == 'MT') {
133
+ this.decimal = 3
134
+ } else {
135
+ this.decimal = 0
136
+ }
137
+ }
138
+
139
+ if(this.unit == '$') {
140
+ this.unitPostion = 'pre'
141
+ this.decimal = 2
142
+ }
143
+ this.dialogVisible = true;
144
+ },
145
+ handleClose(done) {
146
+ this.dialogVisible = false;
147
+ done();
148
+ }
149
+
150
+ }
151
+ }
152
+ </script>