|
@@ -8,10 +8,10 @@ export function usePageUpdateInfo() {
|
|
|
onMounted(async () => {
|
|
|
UrlList = await getGroupUrl(["kxsConfigServer"]);
|
|
|
onSearch(ruleFormRef.value);
|
|
|
-
|
|
|
+
|
|
|
});
|
|
|
let form = reactive({
|
|
|
- kind:"", //分类
|
|
|
+ kind: "", //分类
|
|
|
|
|
|
});
|
|
|
const dataList = ref([]);
|
|
@@ -36,9 +36,24 @@ export function usePageUpdateInfo() {
|
|
|
width: 70,
|
|
|
hide: ({ checkList }) => !checkList.includes("序号列")
|
|
|
},
|
|
|
- {
|
|
|
- label: "分类",
|
|
|
- prop: "kind",
|
|
|
+ {
|
|
|
+ label: "ID",
|
|
|
+ prop: "id",
|
|
|
+ minWidth: 200
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "模板更新版本",
|
|
|
+ prop: "moduleVersion",
|
|
|
+ minWidth: 200
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "模板路径",
|
|
|
+ prop: "modulePath",
|
|
|
+ minWidth: 200
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "顶部标题",
|
|
|
+ prop: "title",
|
|
|
minWidth: 200
|
|
|
},
|
|
|
|
|
@@ -81,8 +96,8 @@ export function usePageUpdateInfo() {
|
|
|
loading.value = true;
|
|
|
// 调用接口(需动态生成接口)
|
|
|
const { status, msg, data }: any = await http.Request({
|
|
|
- method: UrlList.kxsConfigServer.applist.method,
|
|
|
- url: UrlList.kxsConfigServer.applist.url,
|
|
|
+ method: UrlList.kxsConfigServer.pageUpdateInfolist.method,
|
|
|
+ url: UrlList.kxsConfigServer.pageUpdateInfolist.url,
|
|
|
params: {
|
|
|
...form,
|
|
|
pageSize: pagination.pageSize,
|
|
@@ -106,7 +121,7 @@ export function usePageUpdateInfo() {
|
|
|
|
|
|
|
|
|
|
|
|
- // 删除
|
|
|
+ // 删除
|
|
|
function handleDelete(row) {
|
|
|
ElMessageBox.confirm(
|
|
|
`是否删除该页面模板更新信息? `,
|
|
@@ -117,7 +132,7 @@ export function usePageUpdateInfo() {
|
|
|
type: "warning"
|
|
|
}
|
|
|
).then(async () => {
|
|
|
- const { status, msg }: any = await http.Request({ method: UrlList.kxsConfigServer.appdelete.method, url: UrlList.kxsConfigServer.appdelete.url, params: row.id });
|
|
|
+ const { status, msg }: any = await http.Request({ method: UrlList.kxsConfigServer.pageUpdateInfodelete.method, url: UrlList.kxsConfigServer.pageUpdateInfodelete.url, params: row.id });
|
|
|
if (status === 1) {
|
|
|
ElMessage({
|
|
|
message: "删除成功",
|
|
@@ -126,20 +141,53 @@ export function usePageUpdateInfo() {
|
|
|
onSearch(ruleFormRef.value);
|
|
|
} else {
|
|
|
ElMessageBox.alert(msg, "提示", {
|
|
|
+ confirmButtonText: "关闭",
|
|
|
+ type: "warning"
|
|
|
+ });
|
|
|
+ };
|
|
|
+ })
|
|
|
+ }
|
|
|
+
|
|
|
+ function handleSycn() {
|
|
|
+ if (form.kind == "") {
|
|
|
+ ElMessageBox.alert("请筛选分类", "提示", {
|
|
|
confirmButtonText: "关闭",
|
|
|
type: "warning"
|
|
|
});
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ ElMessageBox.confirm(
|
|
|
+ `是否同步页面模板? `,
|
|
|
+ "提示",
|
|
|
+ {
|
|
|
+ confirmButtonText: "同步",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning"
|
|
|
+ }
|
|
|
+ ).then(async () => {
|
|
|
+ const { status, msg }: any = await http.Request({ method: UrlList.kxsConfigServer.pageUpdateInfoupdateTemplate.method, url: UrlList.kxsConfigServer.pageUpdateInfoupdateTemplate.url, params: { kind: form.kind } });
|
|
|
+ if (status === 1) {
|
|
|
+ ElMessage({
|
|
|
+ message: "同步成功",
|
|
|
+ type: "success"
|
|
|
+ });
|
|
|
+ onSearch(ruleFormRef.value);
|
|
|
+ } else {
|
|
|
+ ElMessageBox.alert(msg, "提示", {
|
|
|
+ confirmButtonText: "关闭",
|
|
|
+ type: "warning"
|
|
|
+ });
|
|
|
};
|
|
|
})
|
|
|
}
|
|
|
|
|
|
- // 新增
|
|
|
+ // 新增
|
|
|
const addVisible = ref(false);
|
|
|
function handleAdd() {
|
|
|
addVisible.value = true;
|
|
|
};
|
|
|
|
|
|
- // 修改
|
|
|
+ // 修改
|
|
|
const editUpdateVisible = ref(false);
|
|
|
const editUpdateFormData = ref({});
|
|
|
function handleUpdate(row) {
|
|
@@ -175,6 +223,7 @@ export function usePageUpdateInfo() {
|
|
|
editUpdateFormData,
|
|
|
handleDelete,
|
|
|
handleUpVersion,
|
|
|
+ handleSycn,
|
|
|
editUpVersionVisible,
|
|
|
editUpVersionFormData,
|
|
|
|