| | |
| | | <AppContainer> |
| | | <ProTableQueryFilterBar @on-reset="reset"> |
| | | <template #query> |
| | | <QueryFilterItem> |
| | | <FieldSelect |
| | | v-model="extraParamState.industrialParkId" |
| | | placeholder="请选择园区" |
| | | :value-enum="fourStreamsIndustrialParkList" |
| | | enumLabelKey="parkName" |
| | | enum-value-key="id" |
| | | clearable |
| | | @change="getList()" |
| | | /> |
| | | </QueryFilterItem> |
| | | <QueryFilterItem tip-content="申报日期"> |
| | | <FieldDatePicker |
| | | v-model="extraParamState.creationTime" |
| | |
| | | |
| | | <ProTableV2 v-bind="proTableProps" :columns="column" :operationBtns="operationBtns"> |
| | | </ProTableV2> |
| | | <ParkBountyApplyRedoDialog v-bind="dialogProps" /> |
| | | </AppContainer> |
| | | <OperateHistoryLogDialog v-bind="logDialogProps" /> |
| | | </LoadingLayout> |
| | | </template> |
| | | |
| | |
| | | FieldRadio, |
| | | QueryFilterItem, |
| | | FieldDatePicker, |
| | | FieldSelect, |
| | | useFormDialog, |
| | | } from '@bole-core/components'; |
| | | import { OrderInputType } from '@bole-core/core'; |
| | | import { Message, OrderInputType } from '@bole-core/core'; |
| | | import { format } from '@/utils'; |
| | | import { BountyCheckStatusEnum, BountyCheckStatusEnumText, DataRangeEnumText } from '@/constants'; |
| | | import * as parkBountyApplyServices from '@/services/api/ParkBountyApply'; |
| | | import _ from 'lodash'; |
| | | import { ModelValueType } from 'element-plus'; |
| | | import { useGlobalEventContext } from '@/hooks'; |
| | | import { |
| | | useAccess, |
| | | useGlobalEventContext, |
| | | useIndustrialParkDropDownList, |
| | | useOpenLogDialog, |
| | | } from '@/hooks'; |
| | | import ParkBountyApplyRedoDialog from './components/ParkBountyApplyRedoDialog.vue'; |
| | | |
| | | defineOptions({ |
| | | name: 'MaterialReview', |
| | | name: 'MaterialReviewList', |
| | | }); |
| | | |
| | | const column: API.CustomModuleColumnDto[] = [ |
| | | { |
| | | id: '1', |
| | | enCode: 'batchNo', |
| | | name: '申请批次号', |
| | | }, |
| | | { |
| | | id: '2', |
| | | enCode: 'parkName', |
| | | name: '申请园区', |
| | | }, |
| | | { |
| | | id: '3', |
| | | enCode: 'parkTypeName', |
| | | name: '园区类型', |
| | | }, |
| | | { |
| | | id: '4', |
| | | enCode: 'applyMonth', |
| | | name: '申请奖励金月份', |
| | | }, |
| | | { |
| | | id: '5', |
| | | enCode: 'applySumAmount', |
| | | name: '奖励金汇总金额(元)', |
| | | }, |
| | | { |
| | | id: '6', |
| | | enCode: 'creationTime', |
| | | name: '申报日期', |
| | | }, |
| | | { |
| | | id: '7', |
| | | enCode: 'outCheckTime', |
| | | name: '审核日期', |
| | | }, |
| | | { |
| | | id: '8', |
| | | enCode: 'outCheckStatus', |
| | | name: '审核状态', |
| | | }, |
| | | ]; |
| | | |
| | | const operationBtns = defineOperationBtns([ |
| | | { |
| | | data: { |
| | | enCode: 'detailBtn', |
| | | name: '详情', |
| | | }, |
| | | const operationBtnMap: Record<string, OperationBtnType> = { |
| | | detailBtn: { |
| | | emits: { |
| | | onClick: (role) => goDetail(role), |
| | | }, |
| | | }, |
| | | { |
| | | data: { |
| | | enCode: 'auditBtn', |
| | | name: '审核', |
| | | }, |
| | | auditBtn: { |
| | | emits: { |
| | | onClick: (role) => goAudit(role), |
| | | }, |
| | |
| | | row.outCheckStatus !== BountyCheckStatusEnum.WaitCheck, |
| | | }, |
| | | }, |
| | | ]); |
| | | redoBtn: { |
| | | emits: { |
| | | onClick: (role) => openDialog(role), |
| | | }, |
| | | extraProps: { |
| | | hide: (row: API.GetParkBountyApplyListOutput) => |
| | | row.outCheckStatus !== BountyCheckStatusEnum.CheckPassed, |
| | | }, |
| | | }, |
| | | logBtn: { emits: { onClick: (role) => openLogDialog(role.id) } }, |
| | | }; |
| | | |
| | | const { checkSubModuleItemShow, column, operationBtns } = useAccess({ |
| | | operationBtnMap, |
| | | }); |
| | | |
| | | const router = useRouter(); |
| | | const BaseState = { |
| | | loading: true, |
| | | }; |
| | | |
| | | const { fourStreamsIndustrialParkList } = useIndustrialParkDropDownList(); |
| | | |
| | | const state = reactive({ ...BaseState }); |
| | | |
| | |
| | | creationTimeEnd: format(extraParamState.creationTime?.[1] ?? '', 'YYYY-MM-DD 23:59:59'), |
| | | outCheckTimeBegin: format(extraParamState.outCheckTime?.[0] ?? '', 'YYYY-MM-DD 00:00:00'), |
| | | outCheckTimeEnd: format(extraParamState.outCheckTime?.[1] ?? '', 'YYYY-MM-DD 23:59:59'), |
| | | industrialParkId: extraParamState.industrialParkId, |
| | | }; |
| | | let res = await parkBountyApplyServices.getOutcheckParkBountyList(params, { |
| | | showLoading: !state.loading, |
| | |
| | | creationTime: [] as unknown as ModelValueType, |
| | | outCheckTime: [] as unknown as ModelValueType, |
| | | orderInput: [{ property: 'creationTime', order: OrderInputType.Desc }], |
| | | industrialParkId: '', |
| | | }, |
| | | columnsRenderProps: { |
| | | applyMonth: { type: 'date', format: 'YYYY年MM月' }, |
| | |
| | | }, |
| | | }); |
| | | } |
| | | |
| | | function openDialog(row: API.GetParkBountyApplyListOutput) { |
| | | handleAdd({ |
| | | parkBountyApplyId: row.id, |
| | | }); |
| | | } |
| | | |
| | | const { dialogProps, handleAdd, editForm } = useFormDialog({ |
| | | onConfirm: outcheckParkBountyApplyRedoed, |
| | | defaultFormParams: { |
| | | reasonForWithdrawal: '', |
| | | parkBountyApplyId: '', |
| | | }, |
| | | }); |
| | | |
| | | async function outcheckParkBountyApplyRedoed() { |
| | | try { |
| | | let params: API.OutcheckParkBountyApplyRedoedInput = { |
| | | parkBountyApplyId: editForm.parkBountyApplyId, |
| | | reasonForWithdrawal: editForm.reasonForWithdrawal, |
| | | }; |
| | | let res = await parkBountyApplyServices.outcheckParkBountyApplyRedoed(params); |
| | | if (res) { |
| | | Message.successMessage('操作成功'); |
| | | getList(paginationState.pageIndex); |
| | | } |
| | | } catch (error) {} |
| | | } |
| | | |
| | | const { openLogDialog, logDialogProps } = useOpenLogDialog(); |
| | | </script> |
| | | |
| | | <style lang="scss" scoped> |