mirror of
https://gitee.com/log4j/pig-ui.git
synced 2024-12-22 21:22:33 +08:00
formatter code
This commit is contained in:
parent
dd7ea74da8
commit
c2161148d6
@ -63,7 +63,7 @@
|
||||
:cell-style="tableStyle.cellStyle"
|
||||
:header-cell-style="tableStyle.headerCellStyle"
|
||||
>
|
||||
<el-table-column :selectable="handleSelectable" align="center" type="selection" width="40"/>
|
||||
<el-table-column :selectable="handleSelectable" align="center" type="selection" width="40" />
|
||||
<el-table-column :label="t('param.index')" type="index" width="60" />
|
||||
<el-table-column :label="t('param.publicName')" prop="publicName" show-overflow-tooltip />
|
||||
<el-table-column :label="t('param.publicKey')" prop="publicKey" show-overflow-tooltip />
|
||||
|
@ -232,21 +232,21 @@ const onSubmit = async () => {
|
||||
* @return {Promise} - 包含用户数据的 Promise 对象
|
||||
*/
|
||||
const getUserData = async (id) => {
|
||||
try {
|
||||
loading.value = true;
|
||||
const { data } = await getObj(id);
|
||||
Object.assign(dataForm, data);
|
||||
if (data.roleList) {
|
||||
dataForm.role = data.roleList.map(item => item.roleId);
|
||||
}
|
||||
if (data.postList) {
|
||||
dataForm.post = data.postList.map(item => item.postId);
|
||||
}
|
||||
} catch (err:any) {
|
||||
useMessage().error(err.msg);
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
try {
|
||||
loading.value = true;
|
||||
const { data } = await getObj(id);
|
||||
Object.assign(dataForm, data);
|
||||
if (data.roleList) {
|
||||
dataForm.role = data.roleList.map((item) => item.roleId);
|
||||
}
|
||||
if (data.postList) {
|
||||
dataForm.post = data.postList.map((item) => item.postId);
|
||||
}
|
||||
} catch (err: any) {
|
||||
useMessage().error(err.msg);
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
};
|
||||
|
||||
// 初始化部门数据
|
||||
|
@ -8,7 +8,6 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" name="modelView" setup>
|
||||
import other from '/@/utils/other';
|
||||
import { Session } from '/@/utils/storage';
|
||||
const { proxy } = getCurrentInstance();
|
||||
const route = useRoute();
|
||||
|
@ -6,7 +6,6 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" name="modelView" setup>
|
||||
import other from '/@/utils/other';
|
||||
import { Session } from '/@/utils/storage';
|
||||
const { proxy } = getCurrentInstance();
|
||||
const route = useRoute();
|
||||
|
@ -341,17 +341,16 @@ const deleteMenu = () => {
|
||||
};
|
||||
|
||||
const handleSave = async () => {
|
||||
try {
|
||||
await useMessageBox().confirm('确定要保存该菜单吗?');
|
||||
await saveObj(accountId.value, { button: menuList });
|
||||
await publishObj(accountId.value);
|
||||
useMessage().error('发布成功');
|
||||
} catch (err:any) {
|
||||
useMessage().error(err.msg);
|
||||
}
|
||||
try {
|
||||
await useMessageBox().confirm('确定要保存该菜单吗?');
|
||||
await saveObj(accountId.value, { button: menuList });
|
||||
await publishObj(accountId.value);
|
||||
useMessage().error('发布成功');
|
||||
} catch (err: any) {
|
||||
useMessage().error(err.msg);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
const deleteMaterial = () => {
|
||||
tempObj.value.replyArticles = [];
|
||||
tempObj.value.articleId = '';
|
||||
|
Loading…
Reference in New Issue
Block a user