Merge branch 'master' of http://47.115.223.229:8888/yangjun/nursing_unit_vue
This commit is contained in:
commit
5399127ea9
|
@ -627,4 +627,8 @@
|
||||||
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody > tr > td{
|
.ant-table-wrapper .ant-table.ant-table-middle .ant-table-tbody > tr > td{
|
||||||
padding: 8px 8px;
|
padding: 8px 8px;
|
||||||
}
|
}
|
||||||
|
.jeecg-basic-table .ant-table-wrapper{
|
||||||
|
padding: 15px;
|
||||||
|
border-radius: 8px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
|
@ -1,4 +1,33 @@
|
||||||
<template>
|
<template>
|
||||||
|
|
||||||
|
<div class="p-2">
|
||||||
|
<div class="jeecg-basic-table-form-container">
|
||||||
|
<a-form ref="formRef" @keyup.enter.native="searchQuery" :model="queryParam" :label-col="labelCol" :wrapper-col="wrapperCol">
|
||||||
|
<a-row :gutter="24">
|
||||||
|
<a-col :lg="6">
|
||||||
|
<a-form-item name="dictName">
|
||||||
|
<template #label><span title="字典名称">字典名称</span></template>
|
||||||
|
<j-input placeholder="请输入字典名称" v-model:value="queryParam.dictName" allow-clear ></j-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6">
|
||||||
|
<a-form-item name="dictCode">
|
||||||
|
<template #label><span title="字典编码">字典编码</span></template>
|
||||||
|
<j-input placeholder="请输入字典编码" v-model:value="queryParam.dictCode" allow-clear ></j-input>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
<a-col :lg="6" :sm="24">
|
||||||
|
<span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
|
||||||
|
<a-col :lg="6">
|
||||||
|
<a-button type="primary" preIcon="ant-design:search-outlined" @click="searchQuery">查询</a-button>
|
||||||
|
<a-button type="primary" preIcon="ant-design:reload-outlined" @click="searchReset" style="margin-left: 8px">重置</a-button>
|
||||||
|
</a-col>
|
||||||
|
</span>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-form>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!--引用表格-->
|
<!--引用表格-->
|
||||||
<BasicTable @register="registerTable" :rowSelection="rowSelection">
|
<BasicTable @register="registerTable" :rowSelection="rowSelection">
|
||||||
<!--插槽:table标题-->
|
<!--插槽:table标题-->
|
||||||
|
@ -34,11 +63,12 @@
|
||||||
<DictItemList @register="registerDrawer" />
|
<DictItemList @register="registerDrawer" />
|
||||||
<!--回收站弹窗-->
|
<!--回收站弹窗-->
|
||||||
<DictRecycleBinModal @register="registerModal1" @success="reload" />
|
<DictRecycleBinModal @register="registerModal1" @success="reload" />
|
||||||
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" name="system-dict" setup>
|
<script lang="ts" name="system-dict" setup>
|
||||||
//ts语法
|
//ts语法
|
||||||
import { ref, computed, unref } from 'vue';
|
import { ref,reactive, computed, unref } from 'vue';
|
||||||
import { BasicTable, TableAction } from '/src/components/Table';
|
import { BasicTable, TableAction } from '/src/components/Table';
|
||||||
import { useDrawer } from '/src/components/Drawer';
|
import { useDrawer } from '/src/components/Drawer';
|
||||||
import { useModal } from '/src/components/Modal';
|
import { useModal } from '/src/components/Modal';
|
||||||
|
@ -51,8 +81,12 @@ import { columns, searchFormSchema } from './dict.data';
|
||||||
import { list, deleteDict, batchDeleteDict, getExportUrl, getImportUrl, refreshCache, queryAllDictItems } from './dict.api';
|
import { list, deleteDict, batchDeleteDict, getExportUrl, getImportUrl, refreshCache, queryAllDictItems } from './dict.api';
|
||||||
import { DB_DICT_DATA_KEY } from '/src/enums/cacheEnum';
|
import { DB_DICT_DATA_KEY } from '/src/enums/cacheEnum';
|
||||||
import { useUserStore } from '/@/store/modules/user';
|
import { useUserStore } from '/@/store/modules/user';
|
||||||
|
import JInput from '/@/components/Form/src/jeecg/components/JInput.vue';
|
||||||
|
|
||||||
const { createMessage } = useMessage();
|
const { createMessage } = useMessage();
|
||||||
|
|
||||||
|
const formRef = ref();
|
||||||
|
const queryParam = reactive<any>({});
|
||||||
//字典model
|
//字典model
|
||||||
const [registerModal, { openModal }] = useModal();
|
const [registerModal, { openModal }] = useModal();
|
||||||
//字典配置drawer
|
//字典配置drawer
|
||||||
|
@ -69,9 +103,9 @@ const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
title: '数据字典',
|
title: '数据字典',
|
||||||
api: list,
|
api: list,
|
||||||
columns: columns,
|
columns: columns,
|
||||||
formConfig: {
|
// formConfig: {
|
||||||
schemas: searchFormSchema,
|
// schemas: searchFormSchema,
|
||||||
},
|
// },
|
||||||
actionColumn: {
|
actionColumn: {
|
||||||
width: 240,
|
width: 240,
|
||||||
},
|
},
|
||||||
|
@ -90,6 +124,16 @@ const { prefixCls, tableContext, onExportXls, onImportXls } = useListPage({
|
||||||
//注册table数据
|
//注册table数据
|
||||||
const [registerTable, { reload, updateTableDataRecord }, { rowSelection, selectedRowKeys, selectedRows }] = tableContext;
|
const [registerTable, { reload, updateTableDataRecord }, { rowSelection, selectedRowKeys, selectedRows }] = tableContext;
|
||||||
|
|
||||||
|
const labelCol = reactive({
|
||||||
|
xs:24,
|
||||||
|
sm:6,
|
||||||
|
xl:6,
|
||||||
|
xxl:6
|
||||||
|
});
|
||||||
|
const wrapperCol = reactive({
|
||||||
|
xs: 24,
|
||||||
|
sm: 24,
|
||||||
|
});
|
||||||
/**
|
/**
|
||||||
* 新增事件
|
* 新增事件
|
||||||
*/
|
*/
|
||||||
|
@ -144,6 +188,21 @@ function handleSuccess({ isUpdate, values }) {
|
||||||
reload();
|
reload();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
|
* 查询
|
||||||
|
*/
|
||||||
|
function searchQuery() {
|
||||||
|
reload();
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 重置
|
||||||
|
*/
|
||||||
|
function searchReset() {
|
||||||
|
formRef.value.resetFields();
|
||||||
|
selectedRowKeys.value = [];
|
||||||
|
//刷新数据
|
||||||
|
reload();
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
* 刷新缓存
|
* 刷新缓存
|
||||||
*/
|
*/
|
||||||
|
@ -193,4 +252,32 @@ function getTableAction(record) {
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped></style>
|
|
||||||
|
<style lang="less" scoped>
|
||||||
|
.jeecg-basic-table-form-container {
|
||||||
|
padding: 0;
|
||||||
|
.table-page-search-submitButtons {
|
||||||
|
display: block;
|
||||||
|
margin-bottom: 24px;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
.query-group-cust{
|
||||||
|
min-width: 100px !important;
|
||||||
|
}
|
||||||
|
.query-group-split-cust{
|
||||||
|
width: 30px;
|
||||||
|
display: inline-block;
|
||||||
|
text-align: center
|
||||||
|
}
|
||||||
|
.ant-form-item:not(.ant-form-item-with-help){
|
||||||
|
margin-bottom: 16px;
|
||||||
|
height: 32px;
|
||||||
|
}
|
||||||
|
:deep(.ant-picker),:deep(.ant-input-number){
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
:deep(.ant-picker),:deep(.ant-input-number){
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue