|
@@ -0,0 +1,92 @@
|
|
|
+<script setup lang="ts">
|
|
|
+ import { useModalInner } from '/@/components/Modal';
|
|
|
+ import BasicModal from '/@/components/Modal/src/BasicModal.vue';
|
|
|
+ import BasicTable from '/@/components/Table/src/BasicTable.vue';
|
|
|
+ import { useTable } from '/@/components/Table';
|
|
|
+ import { computed, reactive } from 'vue';
|
|
|
+ import { getTextbookDiscountAlterRecordList } from '/@/services/apis/TextbookDiscountAlterRecordController';
|
|
|
+
|
|
|
+ defineEmits(['register']);
|
|
|
+ const searchInfo = reactive<Recordable>({});
|
|
|
+ const state = reactive({
|
|
|
+ type: 1,
|
|
|
+ });
|
|
|
+
|
|
|
+ const getTitle = computed(() => (state.type === 1 ? '折扣变更记录' : '折扣变更记录'));
|
|
|
+
|
|
|
+ const [tableReg, { reload }] = useTable({
|
|
|
+ title: '',
|
|
|
+ api: getTextbookDiscountAlterRecordList,
|
|
|
+ pagination: false,
|
|
|
+ immediate: false,
|
|
|
+ showTableSetting: true,
|
|
|
+ bordered: true,
|
|
|
+ resizeHeightOffset: 50,
|
|
|
+ columns: [
|
|
|
+ {
|
|
|
+ title: '变更后折扣',
|
|
|
+ dataIndex: 'oldDiscount',
|
|
|
+ align: 'left',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '变更前折扣',
|
|
|
+ dataIndex: 'newDiscount',
|
|
|
+ align: 'left',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '变更时间',
|
|
|
+ dataIndex: 'createDate',
|
|
|
+ align: 'left',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ title: '操作人',
|
|
|
+ dataIndex: 'createUserIdCn',
|
|
|
+ align: 'left',
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ formConfig: {
|
|
|
+ labelWidth: 100,
|
|
|
+ schemas: [
|
|
|
+ {
|
|
|
+ label: '操作人',
|
|
|
+ field: 'createUserIdCn',
|
|
|
+ component: 'Input',
|
|
|
+ colProps: { span: 8 },
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '变更时间',
|
|
|
+ field: '[startCreateDate,endCreateDate]',
|
|
|
+ component: 'RangePicker',
|
|
|
+ colProps: { span: 8 },
|
|
|
+ componentProps: {
|
|
|
+ getPopupContainer: () => document.body,
|
|
|
+ placeholder: ['开始时间', '结束时间'],
|
|
|
+ format: 'YYYY-MM-DD HH:mm:ss',
|
|
|
+ showTime: { format: 'HH:mm:ss' },
|
|
|
+ },
|
|
|
+ },
|
|
|
+ ],
|
|
|
+ },
|
|
|
+ useSearchForm: true,
|
|
|
+ });
|
|
|
+
|
|
|
+ const [register] = useModalInner((data) => {
|
|
|
+ searchInfo.textbookWarehouseRecordId = data.baseData.id;
|
|
|
+
|
|
|
+ reload();
|
|
|
+ });
|
|
|
+</script>
|
|
|
+
|
|
|
+<template>
|
|
|
+ <BasicModal
|
|
|
+ :title="getTitle"
|
|
|
+ v-bind="$attrs"
|
|
|
+ default-fullscreen
|
|
|
+ @register="register"
|
|
|
+ :footer="null"
|
|
|
+ >
|
|
|
+ <BasicTable @register="tableReg" :search-info="searchInfo" />
|
|
|
+ </BasicModal>
|
|
|
+</template>
|
|
|
+
|
|
|
+<style scoped lang="less"></style>
|