bug优化

This commit is contained in:
13218645326 2023-12-09 23:13:06 +08:00
parent 10743074ff
commit a1c7b06450
5 changed files with 338 additions and 128 deletions

View File

@ -16,3 +16,5 @@ app.use(router)
app.use(pinia) app.use(pinia)
app.use(components) app.use(components)
app.mount('#app') app.mount('#app')

View File

@ -0,0 +1,204 @@
export const list: any = [
{
name: "configManage",
path:'/index/configManage',
meta: {
title: '配置管理',
keepAlive: true,
AuthFlag: true
},
children: [
{
path:'/index/configManage/swiperConfig',
name: 'swiperConfig',
component: 'views/configuration/swiperConfig.vue',
meta: {
title: '轮播图配置',
keepAlive: true,
AuthFlag: true
}
},
{
path:'/index/configManage/specialInformationConfiguration',
name: 'specialInformationConfiguration',
component: 'views/configuration/specialInformationConfiguration/index.vue',
meta: {
title: '专题资讯配置',
keepAlive: true,
AuthFlag: true
}
},
{
path:'/index/configManage/privacyAgreement',
name: 'privacyAgreement',
component: 'views/configuration/privacyAgreement/index.vue',
meta: {
title: '隐私协议模板管理',
keepAlive: true,
AuthFlag: true
}
},
]
},
{
name: "企业管理",
path:'/index/enterpriseTypeManage',
meta: {
title: '企业管理',
keepAlive: true,
AuthFlag: true
},
children: [
{
path:'/index/enterpriseTypeManage/enterpriseType',
name: 'configuration',
component: 'views/enterpriseManagement/enterpriseType/index.vue',
meta: {
title: '企业类型',
keepAlive: true,
AuthFlag: true
}
},
{
path:'/index/enterpriseTypeManage/enterpriseEntryReview',
name: 'enterpriseEntryReview',
component: 'views/enterpriseManagement/enterpriseEntryReview/index.vue',
meta: {
title: '企业入驻审核',
keepAlive: true,
AuthFlag: true
},
},
{
path:'/index/enterpriseTypeManage/businessReview',
name: 'businessReview',
component: 'views/enterpriseManagement/businessReview/index.vue',
meta: {
title: '企业业务开通审核',
keepAlive: true,
AuthFlag: true
}
},
{
path:'/index/enterpriseTypeManage/enterpriseInfo',
name: 'enterpriseInfo',
component: 'views/enterpriseManagement/enterpriseInfo/index.vue',
meta: {
title: '企业信息',
keepAlive: true,
AuthFlag: true
}
},
]
},
{
name: "企业装备管理",
path:'/index/enterpriseEquipmentManage',
meta: {
title: '企业装备管理',
keepAlive: true,
AuthFlag: true
},
children: [
{
path:'/index/enterpriseEquipmentManage/equipmentTypeTemplate',
name: 'equipmentTypeTemplate',
component: 'views/enterpriseEquipmentManage/equipmentTypeTemplate/index.vue',
meta: {
title: '装备类型模板',
keepAlive: true,
AuthFlag: true
}
},
{
path:'/index/enterpriseEquipmentManage/equipmentListingApproval',
name: 'equipmentListingApproval',
component: 'views/enterpriseEquipmentManage/equipmentListingApproval/index.vue',
meta: {
title: '装备上架审批',
keepAlive: true,
AuthFlag: true
},
},
// iotEquipmentManagement
{
path:'/index/enterpriseEquipmentManage/iotEquipmentManagement',
name: 'iotEquipmentManagement',
component: 'views/enterpriseEquipmentManage/iotEquipmentManagement/index.vue',
meta: {
title: 'iot设备管理',
keepAlive: true,
AuthFlag: true
}
}
]
},
{
name: "orderManagement",
path:'/index/orderManagement',
component: 'views/orderManagement/index.vue',
meta: {
title: '订单管理',
keepAlive: true,
AuthFlag: true
},
children: []
},
{
name: "systemManage",
path:'/index/systemManage',
meta: {
title: '系统管理',
keepAlive: true,
AuthFlag: true
},
children: [
{
path:'/index/systemManage/systemVersion',
name: 'systemVersion',
component: 'views/systemManage/systemVersion/index.vue',
meta: {
title: '系统版本管理',
keepAlive: true,
AuthFlag: true
}
},
{
path:'/index/systemManage/userManage',
name: 'userManage',
component: 'views/systemManage/userManage/index.vue',
meta: {
title: '用户管理',
keepAlive: true,
AuthFlag: true
}
} ,
{
path:'/index/systemManage/systemLog',
name: 'systemLog',
component: 'views/systemManage/systemLog/index.vue',
meta: {
title: '系统日志',
keepAlive: true,
AuthFlag: true
}
} ,
{
name: "lonLatPick",
path: 'lonLatPick',
component: () => import('views/enterpriseManagement/lonLatPick/index.vue'),
meta: {
title: '经纬度拾取',
keepAlive: true,
AuthFlag: true
},
}
]
}
]

View File

@ -1,45 +1,45 @@
export const list: any = [ export const list: any = [
{ // {
name: "configManage", // name: "configManage",
path:'/index/configManage', // path:'/index/configManage',
meta: { // meta: {
title: '配置管理', // title: '配置管理',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
}, // },
children: [ // children: [
{ // {
path:'/index/configManage/swiperConfig', // path:'/index/configManage/swiperConfig',
name: 'swiperConfig', // name: 'swiperConfig',
component: 'views/configuration/swiperConfig.vue', // component: 'views/configuration/swiperConfig.vue',
meta: { // meta: {
title: '轮播图配置', // title: '轮播图配置',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
}, // },
{ // {
path:'/index/configManage/specialInformationConfiguration', // path:'/index/configManage/specialInformationConfiguration',
name: 'specialInformationConfiguration', // name: 'specialInformationConfiguration',
component: 'views/configuration/specialInformationConfiguration/index.vue', // component: 'views/configuration/specialInformationConfiguration/index.vue',
meta: { // meta: {
title: '专题资讯配置', // title: '专题资讯配置',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
}, // },
{ // {
path:'/index/configManage/privacyAgreement', // path:'/index/configManage/privacyAgreement',
name: 'privacyAgreement', // name: 'privacyAgreement',
component: 'views/configuration/privacyAgreement/index.vue', // component: 'views/configuration/privacyAgreement/index.vue',
meta: { // meta: {
title: '隐私协议模板管理', // title: '隐私协议模板管理',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
}, // },
] // ]
}, // },
{ {
name: "企业管理", name: "企业管理",
path:'/index/enterpriseTypeManage', path:'/index/enterpriseTypeManage',
@ -103,16 +103,16 @@ export const list: any = [
AuthFlag: true AuthFlag: true
}, },
children: [ children: [
{ // {
path:'/index/enterpriseEquipmentManage/equipmentTypeTemplate', // path:'/index/enterpriseEquipmentManage/equipmentTypeTemplate',
name: 'equipmentTypeTemplate', // name: 'equipmentTypeTemplate',
component: 'views/enterpriseEquipmentManage/equipmentTypeTemplate/index.vue', // component: 'views/enterpriseEquipmentManage/equipmentTypeTemplate/index.vue',
meta: { // meta: {
title: '装备类型模板', // title: '装备类型模板',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
}, // },
{ {
path:'/index/enterpriseEquipmentManage/equipmentListingApproval', path:'/index/enterpriseEquipmentManage/equipmentListingApproval',
@ -126,79 +126,79 @@ export const list: any = [
}, },
// iotEquipmentManagement // iotEquipmentManagement
{ // {
path:'/index/enterpriseEquipmentManage/iotEquipmentManagement', // path:'/index/enterpriseEquipmentManage/iotEquipmentManagement',
name: 'iotEquipmentManagement', // name: 'iotEquipmentManagement',
component: 'views/enterpriseEquipmentManage/iotEquipmentManagement/index.vue', // component: 'views/enterpriseEquipmentManage/iotEquipmentManagement/index.vue',
meta: { // meta: {
title: 'iot设备管理', // title: 'iot设备管理',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
} // }
] ]
}, },
{ // {
name: "orderManagement", // name: "orderManagement",
path:'/index/orderManagement', // path:'/index/orderManagement',
component: 'views/orderManagement/index.vue', // component: 'views/orderManagement/index.vue',
meta: { // meta: {
title: '订单管理', // title: '订单管理',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
}, // },
children: [] // children: []
}, // },
{ // {
name: "systemManage", // name: "systemManage",
path:'/index/systemManage', // path:'/index/systemManage',
meta: { // meta: {
title: '系统管理', // title: '系统管理',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
}, // },
children: [ // children: [
{ // {
path:'/index/systemManage/systemVersion', // path:'/index/systemManage/systemVersion',
name: 'systemVersion', // name: 'systemVersion',
component: 'views/systemManage/systemVersion/index.vue', // component: 'views/systemManage/systemVersion/index.vue',
meta: { // meta: {
title: '系统版本管理', // title: '系统版本管理',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
}, // },
{ // {
path:'/index/systemManage/userManage', // path:'/index/systemManage/userManage',
name: 'userManage', // name: 'userManage',
component: 'views/systemManage/userManage/index.vue', // component: 'views/systemManage/userManage/index.vue',
meta: { // meta: {
title: '用户管理', // title: '用户管理',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
} , // } ,
{ // {
path:'/index/systemManage/systemLog', // path:'/index/systemManage/systemLog',
name: 'systemLog', // name: 'systemLog',
component: 'views/systemManage/systemLog/index.vue', // component: 'views/systemManage/systemLog/index.vue',
meta: { // meta: {
title: '系统日志', // title: '系统日志',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
} // }
} , // } ,
{ // {
name: "lonLatPick", // name: "lonLatPick",
path: 'lonLatPick', // path: 'lonLatPick',
component: () => import('views/enterpriseManagement/lonLatPick/index.vue'), // component: () => import('views/enterpriseManagement/lonLatPick/index.vue'),
meta: { // meta: {
title: '经纬度拾取', // title: '经纬度拾取',
keepAlive: true, // keepAlive: true,
AuthFlag: true // AuthFlag: true
}, // },
} // }
] // ]
} // }
] ]

View File

@ -33,6 +33,7 @@ const form = reactive({
name: '', name: '',
status: false status: false
}) })
let editId = ""
// const validatorLink = (rule: any, value: any, callback: any) => { // const validatorLink = (rule: any, value: any, callback: any) => {
// if (linkReg.test(value)) { // if (linkReg.test(value)) {
// callback() // callback()
@ -54,7 +55,8 @@ const publishFn = () => {
if (valid) { if (valid) {
const params = { const params = {
name: form.name, name: form.name,
status: form.status ? '1' : '0' status: form.status ? '1' : '0',
id:editId
} }
const res = await apiAddOrUpdateCompanyType(params) const res = await apiAddOrUpdateCompanyType(params)
console.log("res-apiAddOrUpdateCompanyType", res) console.log("res-apiAddOrUpdateCompanyType", res)
@ -99,6 +101,7 @@ const edit = (val:any) => {
addShow.value = true addShow.value = true
form.name = val.name form.name = val.name
form.status=val.status=='1' ?true : false form.status=val.status=='1' ?true : false
editId=val.id
} }
defineExpose({ defineExpose({

View File

@ -41,8 +41,7 @@ import addCom from "./com/addCom.vue"
import { ElConfirmBeforeOpert } from "utils/elementCom" import { ElConfirmBeforeOpert } from "utils/elementCom"
import { ElMessage } from 'element-plus' import { ElMessage } from 'element-plus'
import { apiSelectCompanyTypeList, apiDeleteCompanyType, apiExportExcel, apiAddOrUpdateCompanyType } from "http/api/enterprise" import { apiSelectCompanyTypeList, apiDeleteCompanyType, apiExportExcel, apiAddOrUpdateCompanyType } from "http/api/enterprise"
import { rejects } from "assert"
import { fa } from "element-plus/es/locale"
const addComRef = ref() const addComRef = ref()
const paginationInfo = reactive({ const paginationInfo = reactive({
pageNum: 1, pageNum: 1,
@ -123,7 +122,8 @@ const beforeChange = (ev: any) => {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
apiAddOrUpdateCompanyType({ apiAddOrUpdateCompanyType({
name: ev.name, name: ev.name,
status: ev.status ? '1' : '0' status: ev.status ? '1' : '0',
id:ev.id
}).then((res: any) => { }).then((res: any) => {
if(res.code == 200){ if(res.code == 200){
resolve(true) resolve(true)
@ -154,7 +154,8 @@ const initTableList = async () => {
tableListInfo.list = res.rows.map((ele: any) => { tableListInfo.list = res.rows.map((ele: any) => {
const item = { const item = {
...ele, ...ele,
status: ele.status == '1' ? true : false status: ele.status == '1' ? true : false,
id:ele.id
} }
return item return item
}) })