|
|
@@ -1,33 +1,56 @@
|
|
|
<template>
|
|
|
- <!-- 买大厅 -->
|
|
|
- <a-table
|
|
|
- :columns="columns"
|
|
|
- class="buyHallTable"
|
|
|
- :scroll="{ x: '100%', y: 'calc(100% - 61px)' }"
|
|
|
- :pagination="false"
|
|
|
- :loading="loading"
|
|
|
- :expandedRowKeys="expandedRowKeys"
|
|
|
- :customRow="Rowclick"
|
|
|
- rowKey="key"
|
|
|
- :data-source="tableList"
|
|
|
- ></a-table>
|
|
|
+ <!-- 买大厅 -->
|
|
|
+ <a-table :columns="columns"
|
|
|
+ class="buyHallTable"
|
|
|
+ :scroll="{ x: '100%', y: 'calc(100% - 61px)' }"
|
|
|
+ :pagination="false"
|
|
|
+ :loading="loading"
|
|
|
+ :expandedRowKeys="expandedRowKeys"
|
|
|
+ :customRow="Rowclick"
|
|
|
+ rowKey="key"
|
|
|
+ :data-source="tableList">
|
|
|
+ <!-- 额外的展开行 -->
|
|
|
+ <template #expandedRowRender="{ record }">
|
|
|
+ <BtnList :btnList="btnList"
|
|
|
+ :record="record"
|
|
|
+ @click="open" />
|
|
|
+ </template>
|
|
|
+ </a-table>
|
|
|
</template>
|
|
|
|
|
|
<script lang="ts">
|
|
|
import { EnumRouterName } from '@/common/constants/enumRouterName';
|
|
|
-import { ComposeTableParam, defineComponent, handleComposeTable, ModalEnum, queryTableList } from '@/common/export/commonTable';
|
|
|
+import { ComposeTableParam, BtnList, defineComponent, handleComposeTable, ModalEnum, queryTableList } from '@/common/export/commonTable';
|
|
|
import { _closeModal } from '@/common/setup/modal/modal';
|
|
|
import { queryAgreementConfig } from '@/services/go/ermcp/qhj';
|
|
|
import { queryOrderQuoteDetail } from '@/services/go/wrtrade';
|
|
|
import { QueryOrderQuoteDetailReq, WrOrderQuoteDetail } from '@/services/go/wrtrade/interface';
|
|
|
+import { defineAsyncComponent, PropType, ref } from 'vue';
|
|
|
+import { BtnList as btnListType } from '@/common/components/btnList/interface';
|
|
|
+import { handleModalComponent } from '@/common/setup/asyncComponent';
|
|
|
|
|
|
export default defineComponent({
|
|
|
- emits: ['cancel'],
|
|
|
+ emits: ['cancel', 'openComponent'],
|
|
|
name: 'warehouse_receipt_trade_price_delisting_buy',
|
|
|
- props: {},
|
|
|
+ props: {
|
|
|
+ enumName: {
|
|
|
+ default: '',
|
|
|
+ type: String as PropType<EnumRouterName>,
|
|
|
+ },
|
|
|
+ btnList: {
|
|
|
+ default: [],
|
|
|
+ type: Array as PropType<btnListType[]>,
|
|
|
+ },
|
|
|
+ },
|
|
|
+ components: {
|
|
|
+ BtnList,
|
|
|
+ },
|
|
|
setup(props, context) {
|
|
|
// 表格列表数据
|
|
|
const { loading, tableList, queryTable } = queryTableList<WrOrderQuoteDetail>();
|
|
|
+ function open(item: btnListType) {
|
|
|
+ context.emit('openComponent', item);
|
|
|
+ }
|
|
|
// 获取列表数据
|
|
|
const queryTableAction = () => {
|
|
|
// const param: QueryOrderQuoteReq = {
|
|
|
@@ -40,12 +63,13 @@ export default defineComponent({
|
|
|
// 表格通用逻辑
|
|
|
const param: ComposeTableParam = {
|
|
|
queryFn: queryTableAction,
|
|
|
- menuType: EnumRouterName.warehouse_receipt_trade_floating_price,
|
|
|
+ menuType: props.enumName,
|
|
|
tableName: 'table_pcweb_agreement',
|
|
|
tableFilterKey: [],
|
|
|
isDetail: false,
|
|
|
};
|
|
|
return {
|
|
|
+ open,
|
|
|
...handleComposeTable<WrOrderQuoteDetail>(param),
|
|
|
loading,
|
|
|
tableList,
|