|
@@ -64,18 +64,19 @@
|
|
|
</div>
|
|
</div>
|
|
|
</el-card>
|
|
</el-card>
|
|
|
|
|
|
|
|
- <add-dialog ref="addDialogRef" @done="reload"></add-dialog>
|
|
|
|
|
|
|
+ <add-dialog ref="addDialogRef" conditionType="terms" @done="reload"></add-dialog>
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
import searchForm from './components/searchForm.vue';
|
|
import searchForm from './components/searchForm.vue';
|
|
|
- import addDialog from './components/addDialog.vue';
|
|
|
|
|
|
|
+ import addDialog from '@/views/rulesManagement/receiveTerms/components/addDialog.vue';
|
|
|
import tabMixins from '@/mixins/tableColumnsMixin';
|
|
import tabMixins from '@/mixins/tableColumnsMixin';
|
|
|
|
|
+ import { calcReceiveDateTypeOp, payConfirmTypeOp, dateUnitOptions } from '@/enum/dict';
|
|
|
import {
|
|
import {
|
|
|
getTableList,
|
|
getTableList,
|
|
|
deleteInformation
|
|
deleteInformation
|
|
|
- } from '@/api/rulesManagement/paymentTerms';
|
|
|
|
|
|
|
+ } from '@/api/rulesManagement/receiveTerms';
|
|
|
|
|
|
|
|
export default {
|
|
export default {
|
|
|
mixins: [tabMixins],
|
|
mixins: [tabMixins],
|
|
@@ -125,14 +126,7 @@
|
|
|
showOverflowTooltip: true,
|
|
showOverflowTooltip: true,
|
|
|
minWidth: 160,
|
|
minWidth: 160,
|
|
|
formatter: (row) => {
|
|
formatter: (row) => {
|
|
|
- const map = {
|
|
|
|
|
- 1: '订单日期',
|
|
|
|
|
- 2: '入库日期',
|
|
|
|
|
- 3: '收票日期',
|
|
|
|
|
- 4: '对账单日期',
|
|
|
|
|
- 5: '应付单日期'
|
|
|
|
|
- };
|
|
|
|
|
- return map[row.calcDateType] || '';
|
|
|
|
|
|
|
+ return calcReceiveDateTypeOp.find(item => item.value === row.dateType)?.label || '';
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
@@ -140,7 +134,10 @@
|
|
|
label: '支付方式',
|
|
label: '支付方式',
|
|
|
align: 'center',
|
|
align: 'center',
|
|
|
showOverflowTooltip: true,
|
|
showOverflowTooltip: true,
|
|
|
- minWidth: 180
|
|
|
|
|
|
|
+ minWidth: 180,
|
|
|
|
|
+ formatter: (row) => {
|
|
|
|
|
+ return this.buildPaymentMethod(row.rulesTypePOList);
|
|
|
|
|
+ }
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
prop: 'confirmType',
|
|
prop: 'confirmType',
|
|
@@ -149,16 +146,12 @@
|
|
|
showOverflowTooltip: true,
|
|
showOverflowTooltip: true,
|
|
|
minWidth: 140,
|
|
minWidth: 140,
|
|
|
formatter: (row) => {
|
|
formatter: (row) => {
|
|
|
- const map = {
|
|
|
|
|
- 1: '交易日',
|
|
|
|
|
- 2: 'X天后'
|
|
|
|
|
- };
|
|
|
|
|
- return map[row.confirmType] || '';
|
|
|
|
|
|
|
+ return payConfirmTypeOp.find(item => item.value === row.determinationMethod)?.label || '';
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
- prop: 'confirmDesc',
|
|
|
|
|
- label: '付款日确认方式描述',
|
|
|
|
|
|
|
+ prop: 'remark',
|
|
|
|
|
+ label: '备注',
|
|
|
align: 'center',
|
|
align: 'center',
|
|
|
showOverflowTooltip: true,
|
|
showOverflowTooltip: true,
|
|
|
minWidth: 180
|
|
minWidth: 180
|
|
@@ -189,11 +182,24 @@
|
|
|
datasource({ page, limit, where }) {
|
|
datasource({ page, limit, where }) {
|
|
|
return getTableList({
|
|
return getTableList({
|
|
|
pageNum: page,
|
|
pageNum: page,
|
|
|
|
|
+ conditionConfigurationType: 'terms',
|
|
|
size: limit,
|
|
size: limit,
|
|
|
...where
|
|
...where
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
|
|
+ // 构建支付方式字符串
|
|
|
|
|
+ buildPaymentMethod(list) {
|
|
|
|
|
+ return list
|
|
|
|
|
+ .map(item => {
|
|
|
|
|
+ const unit =
|
|
|
|
|
+ (dateUnitOptions.find(opt => opt.value === item.dateType) || {}).label ||
|
|
|
|
|
+ '月';
|
|
|
|
|
+ return `${item.percentage}% ${item.paymentSum}${unit} ${item.paymentType}`;
|
|
|
|
|
+ })
|
|
|
|
|
+ .join(',');
|
|
|
|
|
+ },
|
|
|
|
|
+
|
|
|
/* 刷新表格 */
|
|
/* 刷新表格 */
|
|
|
reload(where) {
|
|
reload(where) {
|
|
|
this.$refs.table.reload({ page: 1, where });
|
|
this.$refs.table.reload({ page: 1, where });
|