|
@@ -182,12 +182,9 @@
|
|
|
<!--插槽:table标题-->
|
|
|
<template #tableTitle>
|
|
|
<a-button type="primary" v-auth="'b2bCode:sale_order_b2b:exportXls'" preIcon="ant-design:export-outlined" @click="onExportXls">导出(export)</a-button>
|
|
|
- <!-- <a-button type="primary" @click="submit"> 提交(submit)</a-button>
|
|
|
+ <a-button type="primary" @click="submit"> 提交(submit)</a-button>
|
|
|
<a-button type="primary" @click="cancelSubmit"> 取消提交(cancelSubmit)</a-button>
|
|
|
- <a-button type="primary" @click="close" v-auth="'saleCode:sale_order:close'"> 关闭(close)</a-button> -->
|
|
|
- <!-- <a-button type="primary" @click="cancelClose"> 取消关闭(cancel close)</a-button> -->
|
|
|
- <!-- <a-button type="primary" @click="confirm" v-auth="'saleCode:sale_order:confirm'"> 确认(confirm)</a-button>
|
|
|
- <a-button type="primary" @click="cancelConfirm" v-auth="'saleCode:sale_order:cancelConfirm'"> 取消确认(cancel confirm)</a-button> -->
|
|
|
+ <a-button type="primary" @click="close" > 关闭(close)</a-button>
|
|
|
<a-dropdown v-if="selectedRowKeys.length > 0">
|
|
|
<template #overlay>
|
|
|
<a-menu>
|
|
@@ -217,6 +214,7 @@
|
|
|
<!-- 表单区域 -->
|
|
|
<SaleInquiryFormB2BModal @register="registerModal" @success="handleSuccess" />
|
|
|
<ViewFileListModal ref="ViewFileListModalRef" />
|
|
|
+ <SetCloseReasonModal ref="SetCloseReasonModalRef" @success="successfullyClosed"></SetCloseReasonModal>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -225,6 +223,7 @@
|
|
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
|
|
import { useListPage } from '/@/hooks/system/useListPage';
|
|
|
import { useModal } from '/@/components/Modal';
|
|
|
+ import { message } from 'ant-design-vue';
|
|
|
import SaleInquiryFormB2BModal from './components/SaleOrderFormB2BModal.vue';
|
|
|
import { columns, superQuerySchema } from './SaleOrderB2BForm.data';
|
|
|
import {
|
|
@@ -237,16 +236,21 @@
|
|
|
CustomerOption,
|
|
|
ClassList,
|
|
|
SaleManOption,
|
|
|
- shipOption
|
|
|
+ shipOption,
|
|
|
+ batchSubmit,
|
|
|
+ cancelBatchSubmit,
|
|
|
+ bacthClose,
|
|
|
} from './SaleOrderyB2BForm.api';
|
|
|
import { cloneDeep } from 'lodash-es';
|
|
|
import { JDictSelectTag, ApiSelect, JInput,JSelect } from '/@/components/Form';
|
|
|
import JSelectUser from '/@/components/Form/src/jeecg/components/JSelectUser.vue';
|
|
|
import JSelectDept from '/@/components/Form/src/jeecg/components/JSelectDept.vue';
|
|
|
import ViewFileListModal from './components/ViewFileListModal.vue';
|
|
|
+ import SetCloseReasonModal from '../../publicComponents/SetCloseReasonModal.vue'
|
|
|
const formRef = ref();
|
|
|
var showField = ref('currency_dictText+name');
|
|
|
const ViewFileListModalRef = ref();
|
|
|
+ var SetCloseReasonModalRef = ref();
|
|
|
const queryParam = reactive<any>({});
|
|
|
//注册model
|
|
|
const [registerModal, { openModal }] = useModal();
|
|
@@ -345,9 +349,42 @@
|
|
|
label: '编辑(edit)',
|
|
|
onClick: handleEdit.bind(null, record),
|
|
|
auth: 'b2bCode:sale_order_b2b:edit',
|
|
|
+ ifShow: record.submit == '0' || !record.submit,
|
|
|
},
|
|
|
];
|
|
|
}
|
|
|
+ function submit() {
|
|
|
+ if (selectedRowKeys.value.length == 0) {
|
|
|
+ message.warning('请选择数据');
|
|
|
+ } else {
|
|
|
+ var ids = selectedRowKeys.value.join(',');
|
|
|
+ batchSubmit({ ids: ids }, handleSuccess);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ function cancelSubmit() {
|
|
|
+ if (selectedRowKeys.value.length == 0) {
|
|
|
+ message.warning('请选择数据');
|
|
|
+ } else {
|
|
|
+ var ids = selectedRowKeys.value.join(',');
|
|
|
+ cancelBatchSubmit({ ids: ids }, handleSuccess);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ function close() {
|
|
|
+ if (selectedRowKeys.value.length == 0) {
|
|
|
+ message.warning('请选择数据');
|
|
|
+ } else {
|
|
|
+ var ids = selectedRowKeys.value.join(',');
|
|
|
+ var ids=selectedRowKeys.value.join(',')
|
|
|
+ SetCloseReasonModalRef.value.getTable(ids)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ function successfullyClosed(reason,id){
|
|
|
+ var params={
|
|
|
+ ids: id,
|
|
|
+ closeReason: reason
|
|
|
+ }
|
|
|
+ bacthClose(params,handleSuccess);
|
|
|
+ }
|
|
|
/**
|
|
|
* 下拉操作栏
|
|
|
*/
|