|
@@ -30,12 +30,8 @@
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script lang="ts">
|
|
<script lang="ts">
|
|
|
-import { MtpTableButton, contextMenu, defineAsyncComponent, defineComponent, handleComposeTable, ComposeTableParam } from '@/common/export/commonTable';
|
|
|
|
|
-import { initData, getTableColumns, getTableEvent, getBtnList } from '@/common/export/table';
|
|
|
|
|
-
|
|
|
|
|
-import { SettlementDetail, SettlementAudit, SettlementCancel, Filter } from '../../../components';
|
|
|
|
|
-
|
|
|
|
|
-import { queryTableList, QryBussinessJsRsp } from '../setup';
|
|
|
|
|
|
|
+import { MtpTableButton, contextMenu, defineAsyncComponent, defineComponent, handleComposeTable, ComposeTableParam, queryTableList } from '@/common/export/commonTable';
|
|
|
|
|
+import { Filter } from '../../components';
|
|
|
import { invoiceStatusName } from '@/views/manage/finance-review/setup';
|
|
import { invoiceStatusName } from '@/views/manage/finance-review/setup';
|
|
|
import { Column, ColumnType } from '@/common/setup/table';
|
|
import { Column, ColumnType } from '@/common/setup/table';
|
|
|
import { getPriceTypeName, getContractTypeName, getApplyStatusName } from '@/common/constants/enumsName';
|
|
import { getPriceTypeName, getContractTypeName, getApplyStatusName } from '@/common/constants/enumsName';
|
|
@@ -43,6 +39,9 @@ import { getAnalogueName } from '@/views/information/spot-contract/setup';
|
|
|
import { EnumRouterName } from '@/common/constants/enumRouterName';
|
|
import { EnumRouterName } from '@/common/constants/enumRouterName';
|
|
|
import { BtnListType } from '@/common/components/btnList/interface';
|
|
import { BtnListType } from '@/common/components/btnList/interface';
|
|
|
import { getTableButton } from '@/common/setup/table/button';
|
|
import { getTableButton } from '@/common/setup/table/button';
|
|
|
|
|
+import { QueryBusinessJs } from '@/services/go/ermcp/business-review';
|
|
|
|
|
+import { QryBussinessJsRsp } from '@/services/go/ermcp/business-review/interface';
|
|
|
|
|
+import { useRoute } from 'vue-router';
|
|
|
|
|
|
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
|
name: 'business-review-js',
|
|
name: 'business-review-js',
|
|
@@ -50,16 +49,30 @@ export default defineComponent({
|
|
|
contextMenu,
|
|
contextMenu,
|
|
|
Filter,
|
|
Filter,
|
|
|
MtpTableButton,
|
|
MtpTableButton,
|
|
|
- detail: defineAsyncComponent(() => import('../../../components/settlementDetail/index.vue')),
|
|
|
|
|
- settlement_checkpending_check: defineAsyncComponent(() => import('../../../components/settlementAudit/index.vue')),
|
|
|
|
|
- settlement_checkpending_cancel: defineAsyncComponent(() => import('../../../components/settlementCancel/index.vue')),
|
|
|
|
|
|
|
+ detail: defineAsyncComponent(() => import('../../components/settlementDetail/index.vue')),
|
|
|
|
|
+ check: defineAsyncComponent(() => import('../../components/settlementAudit/index.vue')),
|
|
|
|
|
+ cancel: defineAsyncComponent(() => import('../../components/settlementCancel/index.vue')),
|
|
|
},
|
|
},
|
|
|
setup() {
|
|
setup() {
|
|
|
|
|
+ const { name: routeName } = useRoute();
|
|
|
|
|
+ // 权限按钮
|
|
|
|
|
+ const buttons = getTableButton();
|
|
|
|
|
+
|
|
|
// 表格列表数据
|
|
// 表格列表数据
|
|
|
- const { loading, tableList, queryTable } = queryTableList({ applystatus: '1' });
|
|
|
|
|
|
|
+ const { loading, tableList, queryTable } = queryTableList<QryBussinessJsRsp>();
|
|
|
|
|
|
|
|
// 获取列表数据
|
|
// 获取列表数据
|
|
|
- const queryTableAction = () => queryTable();
|
|
|
|
|
|
|
+ const queryTableAction = () => {
|
|
|
|
|
+ switch (routeName) {
|
|
|
|
|
+ case 'settlement_checkpending':
|
|
|
|
|
+ queryTable(QueryBusinessJs, { applystatus: '1' });
|
|
|
|
|
+ break;
|
|
|
|
|
+ case 'settlement_performance':
|
|
|
|
|
+ queryTable(QueryBusinessJs, { applystatus: '2' });
|
|
|
|
|
+ break;
|
|
|
|
|
+ }
|
|
|
|
|
+ };
|
|
|
|
|
+
|
|
|
const filtrFn = (e: Column, item: ColumnType, filtered: any) => {
|
|
const filtrFn = (e: Column, item: ColumnType, filtered: any) => {
|
|
|
if (e.columnfield === 'buyusernameOrsellusername') {
|
|
if (e.columnfield === 'buyusernameOrsellusername') {
|
|
|
item.onFilter = (value: string, record: QryBussinessJsRsp) => {
|
|
item.onFilter = (value: string, record: QryBussinessJsRsp) => {
|
|
@@ -98,9 +111,6 @@ export default defineComponent({
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- // 权限按钮
|
|
|
|
|
- const buttons = getTableButton(['settlement_checkpending_check', 'settlement_checkpending_cancel', 'detail']);
|
|
|
|
|
-
|
|
|
|
|
return {
|
|
return {
|
|
|
...handleComposeTable<QryBussinessJsRsp>(param),
|
|
...handleComposeTable<QryBussinessJsRsp>(param),
|
|
|
handlePermissionBtn,
|
|
handlePermissionBtn,
|