UnionPayModel.vue 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. <template>
  2. <BasicModal v-bind="$attrs" @register="registerModal" destroyOnClose title="银联商户" :width="800">
  3. <a-button type="primary" preIcon="ant-design:plus-outlined" @click="router.push({ path: '/AccountManagement/Merchant/UnionPay' })">
  4. 新建</a-button
  5. >
  6. <!-- <BasicTable @register="registerTable" :rowSelection="rowSelection">
  7. <template #tableTitle>
  8. <a-button type="primary" @click="handleAdd" preIcon="ant-design:plus-outlined"> 新增</a-button>
  9. </template>
  10. <template #action="{ record }">
  11. <TableAction :actions="getTableAction(record)" :dropDownActions="getDropDownAction(record)" />
  12. </template>
  13. </BasicTable> -->
  14. </BasicModal>
  15. </template>
  16. <script lang="ts" setup>
  17. import { InputNumber, FormItem } from 'ant-design-vue';
  18. import { ref, computed, unref } from 'vue';
  19. import { BasicModal, useModalInner } from '/@/components/Modal';
  20. import { BasicForm, useForm } from '/@/components/Form/index';
  21. import { formSchema, columns } from '../Merchant.data';
  22. import { saveOrUpdate } from '../Merchant.api.';
  23. import { useMessage } from '/@/hooks/web/useMessage';
  24. import { useListPage } from '/@/hooks/system/useListPage';
  25. import { useRouter } from 'vue-router';
  26. const router = useRouter();
  27. const { createMessage } = useMessage();
  28. // Emits声明
  29. const emit = defineEmits(['register', 'success']);
  30. //表单赋值
  31. const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data) => {
  32. //重置表单
  33. setModalProps({ confirmLoading: false, showCancelBtn: !!data?.showFooter, showOkBtn: !!data?.showFooter, maskClosable: false });
  34. // 隐藏底部时禁用整个表单
  35. // setProps({ disabled: !data?.showFooter });
  36. });
  37. //注册table数据
  38. // const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
  39. // tableProps: {
  40. // title: 'Merchant',
  41. // // api: list,
  42. // columns,
  43. //
  44. // formConfig: {
  45. // autoSubmitOnEnter: true,
  46. // showAdvancedButton: true,
  47. // fieldMapToNumber: [],
  48. // fieldMapToTime: [],
  49. // },
  50. // actionColumn: {
  51. // width: 250,
  52. // fixed: 'right',
  53. // },
  54. // },
  55. // });
  56. // const [registerTable, { reload }, {}] = tableContext;
  57. </script>
  58. <style lang="less" scoped>
  59. /** 时间和数字输入框样式 */
  60. :deep(.ant-input-number) {
  61. width: 100%;
  62. }
  63. :deep(.ant-calendar-picker) {
  64. width: 100%;
  65. }
  66. </style>