|
@@ -162,7 +162,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script lang="ts" name="purchase-purchaseInquiryForm" setup>
|
|
|
- import { ref, reactive, computed, unref, onMounted } from 'vue';
|
|
|
+ import { ref, reactive, computed, unref, onMounted,watchEffect } from 'vue';
|
|
|
import { BasicTable, useTable, TableAction } from '/@/components/Table';
|
|
|
import { useListPage } from '/@/hooks/system/useListPage';
|
|
|
import { useModal } from '/@/components/Modal';
|
|
@@ -192,6 +192,7 @@
|
|
|
const checkedKeys = ref<Array<string | number>>([]);
|
|
|
//注册model
|
|
|
const [registerModal, { openModal }] = useModal();
|
|
|
+
|
|
|
//注册table数据
|
|
|
const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
|
|
tableProps: {
|
|
@@ -222,12 +223,8 @@
|
|
|
success: handleSuccess,
|
|
|
},
|
|
|
});
|
|
|
-
|
|
|
+
|
|
|
const [registerTable, { reload }, { rowSelection, selectedRowKeys }] = tableContext;
|
|
|
-
|
|
|
- /**
|
|
|
- * 高级查询事件
|
|
|
- */
|
|
|
function handleSuperQuery(params) {
|
|
|
Object.keys(params).map((k) => {
|
|
|
queryParam[k] = params[k];
|
|
@@ -296,7 +293,6 @@
|
|
|
{
|
|
|
label: '导出(export)',
|
|
|
onClick: onExportXlsNow.bind(null, record),
|
|
|
- ifShow: record.submit == '1',
|
|
|
},
|
|
|
{
|
|
|
label: '发送(sent)',
|
|
@@ -306,7 +302,6 @@
|
|
|
];
|
|
|
}
|
|
|
function handleSent() {}
|
|
|
- function handleExportOne() {}
|
|
|
/**
|
|
|
* 下拉操作栏
|
|
|
*/
|
|
@@ -398,6 +393,19 @@
|
|
|
}
|
|
|
async function onExportXlsNow(record) {
|
|
|
queryParam.id = record.id;
|
|
|
+ const {onExportXls} = useListPage({
|
|
|
+ tableProps: {
|
|
|
+ beforeFetch: async (params) => {
|
|
|
+ let rangerQuery = await setRangeQuery();
|
|
|
+ return Object.assign(params, rangerQuery);
|
|
|
+ },
|
|
|
+ },
|
|
|
+ exportConfig: {
|
|
|
+ name: record.billCode,
|
|
|
+ url: getExportUrl,
|
|
|
+ params: queryParam,
|
|
|
+ },
|
|
|
+ });
|
|
|
await onExportXls();
|
|
|
queryParam.id = '';
|
|
|
}
|