mirror of
https://gitee.com/log4j/pig-ui.git
synced 2024-12-23 05:40:20 +08:00
🐛 Fixing a bug.#5248 【菜单搜索】搜索结果被追加至表格树种显示不正确
This commit is contained in:
parent
b9b2fc8955
commit
6a6271d284
@ -6,11 +6,12 @@
|
|||||||
<el-form-item :label="$t('sysmenu.name')" prop="menuName">
|
<el-form-item :label="$t('sysmenu.name')" prop="menuName">
|
||||||
<el-input :placeholder="$t('sysmenu.inputNameTip')" clearable style="max-width: 180px" v-model="state.queryForm.menuName" />
|
<el-input :placeholder="$t('sysmenu.inputNameTip')" clearable style="max-width: 180px" v-model="state.queryForm.menuName" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button @click="getDataList" class="ml10" icon="search" type="primary">
|
<el-button @click="query" class="ml10" icon="search" type="primary">
|
||||||
{{ $t('common.queryBtn') }}
|
{{ $t('common.queryBtn') }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-form-item>
|
<el-button @click="resetQuery" icon="Refresh">{{ $t('common.resetBtn') }}</el-button>
|
||||||
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row>
|
<el-row>
|
||||||
@ -102,6 +103,7 @@ const { t } = useI18n();
|
|||||||
// 定义变量内容
|
// 定义变量内容
|
||||||
const tableRef = ref();
|
const tableRef = ref();
|
||||||
const menuDialogRef = ref();
|
const menuDialogRef = ref();
|
||||||
|
const queryRef = ref();
|
||||||
const showSearch = ref(true);
|
const showSearch = ref(true);
|
||||||
const isExpand = ref(false);
|
const isExpand = ref(false);
|
||||||
const state: BasicTableProps = reactive<BasicTableProps>({
|
const state: BasicTableProps = reactive<BasicTableProps>({
|
||||||
@ -144,6 +146,19 @@ const toggleExpand = (children: any[], unfold = true) => {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 搜索事件
|
||||||
|
const query = () => {
|
||||||
|
state.dataList = [];
|
||||||
|
getDataList();
|
||||||
|
};
|
||||||
|
|
||||||
|
// 清空搜索条件
|
||||||
|
const resetQuery = () => {
|
||||||
|
queryRef.value.resetFields();
|
||||||
|
state.dataList = [];
|
||||||
|
getDataList();
|
||||||
|
};
|
||||||
|
|
||||||
// 删除操作
|
// 删除操作
|
||||||
const handleDelete = async (row: any) => {
|
const handleDelete = async (row: any) => {
|
||||||
try {
|
try {
|
||||||
|
Loading…
Reference in New Issue
Block a user