diff --git a/epmet-oper-web/src/js/columns/customer/manage/customer.js b/epmet-oper-web/src/js/columns/customer/manage/customer.js
index 8c7f53e..0481508 100644
--- a/epmet-oper-web/src/js/columns/customer/manage/customer.js
+++ b/epmet-oper-web/src/js/columns/customer/manage/customer.js
@@ -76,7 +76,7 @@ export default {
{
key: 'rootManageName',
title: '管理员',
- display: ['formA', 'formU', 'table', 'model'],
+ display: ['table', 'model'],
type: 'input',
rule: [
{
@@ -91,7 +91,7 @@ export default {
{
key: 'rootManagePhone',
title: '联系方式',
- display: ['formA', 'formU', 'table', 'model'],
+ display: ['table', 'model'],
type: 'input',
rule: [
{
diff --git a/epmet-oper-web/src/js/columns/miniPro/customizedFunction.js b/epmet-oper-web/src/js/columns/miniPro/customizedFunction.js
index 974529c..e244584 100644
--- a/epmet-oper-web/src/js/columns/miniPro/customizedFunction.js
+++ b/epmet-oper-web/src/js/columns/miniPro/customizedFunction.js
@@ -22,7 +22,7 @@ export default [
return '未知'
}
},
- width: 80
+ width: 60
},
{
key: 'functionExplain',
@@ -48,7 +48,9 @@ export default [
fixed: false,
block: true,
width: 100,
- tableType: 'image'
+ tableType: 'image',
+ imgWidth: '30px',
+ imgHeight: '30px'
},
{
@@ -56,7 +58,7 @@ export default [
title: '外链地址',
display: ['formA', 'formU', 'table', 'model'],
block: true,
- width: 60
+ width: 120
},
// {
// key: 'domainName',
diff --git a/epmet-oper-web/src/router/index.js b/epmet-oper-web/src/router/index.js
index 650e936..417612b 100644
--- a/epmet-oper-web/src/router/index.js
+++ b/epmet-oper-web/src/router/index.js
@@ -12,7 +12,7 @@ export const pageRoutes = [
component: () => import('@/views/pages/404'),
name: '404',
meta: { title: '404未找到' },
- beforeEnter (to, from, next) {
+ beforeEnter(to, from, next) {
// 拦截处理特殊业务场景
// 如果, 重定向路由包含__双下划线, 为临时添加路由
if (/__.*/.test(to.redirectedFrom)) {
@@ -21,7 +21,18 @@ export const pageRoutes = [
next()
}
},
- { path: '/login', component: () => import('@/views/pages/login'), name: 'login', meta: { title: '登录' } }
+ {
+ path: '/login',
+ component: () => import('@/views/pages/login'),
+ name: 'login',
+ meta: { title: '登录' }
+ },
+ {
+ path: '/loginWork',
+ component: () => import('@/views/pages/loginWork'),
+ name: 'loginWork',
+ meta: { title: '工作端登录' }
+ }
]
// 模块路由(基于主入口布局页面)
@@ -32,14 +43,21 @@ export const moduleRoutes = {
redirect: { name: 'home' },
meta: { title: '主入口布局' },
children: [
- { path: '/home', component: () => import('@/views/modules/home'), name: 'home', meta: { title: '首页', isTab: true } }
+ {
+ path: '/home',
+ component: () => import('@/views/modules/home'),
+ name: 'home',
+ meta: { title: '首页', isTab: true }
+ }
]
}
-export function addDynamicRoute (routeParams, router) {
+export function addDynamicRoute(routeParams, router) {
// 组装路由名称, 并判断是否已添加, 如是: 则直接跳转
var routeName = routeParams.routeName
- var dynamicRoute = window.SITE_CONFIG['dynamicRoutes'].filter(item => item.name === routeName)[0]
+ var dynamicRoute = window.SITE_CONFIG['dynamicRoutes'].filter(
+ (item) => item.name === routeName
+ )[0]
if (dynamicRoute) {
return router.push({ name: routeName, params: routeParams.params })
}
@@ -74,29 +92,38 @@ const router = new Router({
router.beforeEach((to, from, next) => {
// 添加动态(菜单)路由
// 已添加或者当前路由为页面路由, 可直接访问
- if (window.SITE_CONFIG['dynamicMenuRoutesHasAdded'] || fnCurrentRouteIsPageRoute(to, pageRoutes)) {
+ if (
+ window.SITE_CONFIG['dynamicMenuRoutesHasAdded'] ||
+ fnCurrentRouteIsPageRoute(to, pageRoutes)
+ ) {
return next()
}
// 获取字典列表, 添加并全局变量保存
- http.get('/sys/dict/type/all').then(({ data: res }) => {
- if (res.code !== 0) {
- return
- }
- window.SITE_CONFIG['dictList'] = res.data
- }).catch(() => { })
+ http
+ .get('/sys/dict/type/all')
+ .then(({ data: res }) => {
+ if (res.code !== 0) {
+ return
+ }
+ window.SITE_CONFIG['dictList'] = res.data
+ })
+ .catch(() => {})
// 获取菜单列表, 添加并全局变量保存
- http.get('/oper/access/menu/nav').then(({ data: res }) => {
- if (res.code !== 0) {
- // Vue.prototype.$message.error(res.msg)
- return next({ name: 'login' })
- }
- window.SITE_CONFIG['menuList'] = res.data
- fnAddDynamicMenuRoutes(window.SITE_CONFIG['menuList'])
- // next({ ...to, replace: true })
- next({ ...to, replace: true })
- }).catch(() => {
- next({ name: 'login' })
- })
+ http
+ .get('/oper/access/menu/nav')
+ .then(({ data: res }) => {
+ if (res.code !== 0) {
+ // Vue.prototype.$message.error(res.msg)
+ return next({ name: 'login' })
+ }
+ window.SITE_CONFIG['menuList'] = res.data
+ fnAddDynamicMenuRoutes(window.SITE_CONFIG['menuList'])
+ // next({ ...to, replace: true })
+ next({ ...to, replace: true })
+ })
+ .catch(() => {
+ next({ name: 'login' })
+ })
})
/**
@@ -104,7 +131,7 @@ router.beforeEach((to, from, next) => {
* @param {*} route 当前路由
* @param {*} pageRoutes 页面路由
*/
-function fnCurrentRouteIsPageRoute (route, pageRoutes = []) {
+function fnCurrentRouteIsPageRoute(route, pageRoutes = []) {
var temp = []
for (var i = 0; i < pageRoutes.length; i++) {
if (route.path === pageRoutes[i].path) {
@@ -122,7 +149,7 @@ function fnCurrentRouteIsPageRoute (route, pageRoutes = []) {
* @param {*} menuList 菜单列表
* @param {*} routes 递归创建的动态(菜单)路由
*/
-function fnAddDynamicMenuRoutes (menuList = [], routes = []) {
+function fnAddDynamicMenuRoutes(menuList = [], routes = []) {
var temp = []
for (var i = 0; i < menuList.length; i++) {
if (menuList[i].children && menuList[i].children.length >= 1) {
@@ -141,7 +168,9 @@ function fnAddDynamicMenuRoutes (menuList = [], routes = []) {
}
}
// eslint-disable-next-line
- let URL = (menuList[i].url || '').replace(/{{([^}}]+)?}}/g, (s1, s2) => eval(s2)) // URL支持{{ window.xxx }}占位符变量
+ let URL = (menuList[i].url || '').replace(/{{([^}}]+)?}}/g, (s1, s2) =>
+ eval(s2)
+ ) // URL支持{{ window.xxx }}占位符变量
if (isURL(URL)) {
route['path'] = route['name'] = `i-${menuList[i].id}`
route['meta']['iframeURL'] = URL
diff --git a/epmet-oper-web/src/views/modules/customer/customize/ConfigEdit.vue b/epmet-oper-web/src/views/modules/customer/customize/ConfigEdit.vue
index 7d7ea21..fbde498 100644
--- a/epmet-oper-web/src/views/modules/customer/customize/ConfigEdit.vue
+++ b/epmet-oper-web/src/views/modules/customer/customize/ConfigEdit.vue
@@ -45,11 +45,12 @@
class="function-icon">
- 恢复默认
+
+ 恢复默认
@@ -58,7 +59,7 @@
label="默认小图标">
@@ -73,15 +74,16 @@
:before-upload="beforeImgUpload">
- 恢复默认
+
+ 恢复默认
diff --git a/epmet-oper-web/src/views/modules/customer/customize/ConfigItem.vue b/epmet-oper-web/src/views/modules/customer/customize/ConfigItem.vue
index fd4d5b3..51c08da 100644
--- a/epmet-oper-web/src/views/modules/customer/customize/ConfigItem.vue
+++ b/epmet-oper-web/src/views/modules/customer/customize/ConfigItem.vue
@@ -81,7 +81,7 @@
prop="iconSmallImg">
@@ -444,11 +444,11 @@ export default {
if (i === index - 1) {
one.customerId = this.customizedList[i].customerId
one.functionId = this.customizedList[i].functionId
- one.displayOrder = i
+ one.displayOrder = index
} else if (i === index) {
obj.customerId = this.customizedList[i].customerId
obj.functionId = this.customizedList[i].functionId
- obj.displayOrder = i
+ obj.displayOrder = index - 1
resultList.push(obj)
resultList.push(one)
} else {
@@ -461,16 +461,18 @@ export default {
console.log(resultList)
// const url = 'https://nei.netease.com/api/apimock-v2/e3b1d0eb88e905f6c7ee559b2d6bb7ad/oper/customize/customerfunctiondetail/updatedisplayorder'
- // const url = '/oper/customize/customerfunctiondetail/updatedisplayorder'
- // window.app.ajax.post(url, resultList,
- // (data, rspMsg) => {
- // // this.$message.success('操作成功')
- // this.loadTableData()
- // },
- // (rspMsg, data) => {
- // this.$message.error(rspMsg)
- // })
- this.endLoading()
+ const url = '/oper/customize/customerfunctiondetail/updatedisplayorder'
+ window.app.ajax.post(url, resultList,
+ (data, rspMsg) => {
+ this.endLoading()
+ // this.$message.success('操作成功')
+ this.loadTableData()
+ },
+ (rspMsg, data) => {
+ this.endLoading()
+ this.$message.error(rspMsg)
+ })
+
} else {
this.$message.warning('无法上移')
diff --git a/epmet-oper-web/src/views/modules/customer/manage/EditForm.vue b/epmet-oper-web/src/views/modules/customer/manage/EditForm.vue
index a426553..9a88769 100644
--- a/epmet-oper-web/src/views/modules/customer/manage/EditForm.vue
+++ b/epmet-oper-web/src/views/modules/customer/manage/EditForm.vue
@@ -133,8 +133,13 @@ export default {
// let url = 'https://nei.netease.com/api/apimock-v2/e3b1d0eb88e905f6c7ee559b2d6bb7ad/oper/crm/customer/updatecustomer'
let url = '/oper/crm/customer/updatecustomer'
// 表单对象
- let _data = this.$refs['ref_form'].model
- _data.logo = this.formData2.logo
+ const model = this.$refs['ref_form'].model
+ let _data = {
+ customerId: model.customerId,
+ customerName: model.customerName,
+ logo: this.formData2.logo
+ }
+
window.app.ajax.post(url, _data,
(data, rspMsg) => {
this.endLoading()
diff --git a/epmet-oper-web/src/views/modules/customer/miniProAgent/BasicInfo.vue b/epmet-oper-web/src/views/modules/customer/miniProAgent/BasicInfo.vue
index 7be00ff..f615df5 100644
--- a/epmet-oper-web/src/views/modules/customer/miniProAgent/BasicInfo.vue
+++ b/epmet-oper-web/src/views/modules/customer/miniProAgent/BasicInfo.vue
@@ -8,117 +8,140 @@
:width="70"
@cancel="diaCancel"
@ok="setDomains">
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{formData.webViewDomain[index]}}
+
+
+
+
+
+
+
+
@@ -137,11 +160,13 @@ export default {
customerId: '', // 客户id,父组件传
clientType: '', // 客户端类型,父组件传
diaVisible: false,
+ activeName: 'service',
formData: {
requestDomain: [], // request 合法域名
wsRequestDomain: [], // socket 合法域名
uploadDomain: [], // uploadFile 合法域名
- downloadDomain: [] // downloadFile 合法域名
+ downloadDomain: [], // downloadFile 合法域名
+ webViewDomain: []// 业务域名
}
}
},
@@ -188,6 +213,9 @@ export default {
if (this.formData.downloadDomain.length === 0) {
this.formData.downloadDomain.push('')
}
+ if (this.formData.webViewDomain.length === 0) {
+ this.formData.webViewDomain.push('无')
+ }
this.endLoading()
},
(rspMsg, data) => {
@@ -214,6 +242,7 @@ export default {
const param = {
customerId: this.customerId,
clientType: this.clientType,
+ action: 'set',
requestDomain: requestDomain,
wsRequestDomain: wsRequestDomain,
uploadDomain: uploadDomain,
diff --git a/epmet-oper-web/src/views/modules/productConfig/customizeFunction/CustomFun.vue b/epmet-oper-web/src/views/modules/productConfig/customizeFunction/CustomFun.vue
index 619ba98..4953006 100644
--- a/epmet-oper-web/src/views/modules/productConfig/customizeFunction/CustomFun.vue
+++ b/epmet-oper-web/src/views/modules/productConfig/customizeFunction/CustomFun.vue
@@ -166,22 +166,11 @@ export default {
},
// 新增
addShow () {
- let row = {
- functionId: '',
- customizedName: '',
- iconLargeImg: '',
- iconSmallImg: '',
- shoppingStatus: '1',
- functionExplain: '',
- targetLink: '',
- domainName: '',
- fromApp: 'resi'
- }
- this.$refs['ref_edit'].init(row, 'A')
+ this.$refs['ref_edit'].init('', 'A')
},
// 编辑
editShow (row) {
- this.$refs['ref_edit'].init(row, 'U')
+ this.$refs['ref_edit'].init(row.functionId, 'U')
},
// 删除
diff --git a/epmet-oper-web/src/views/modules/productConfig/customizeFunction/Edit.vue b/epmet-oper-web/src/views/modules/productConfig/customizeFunction/Edit.vue
index a998302..0e26b47 100644
--- a/epmet-oper-web/src/views/modules/productConfig/customizeFunction/Edit.vue
+++ b/epmet-oper-web/src/views/modules/productConfig/customizeFunction/Edit.vue
@@ -3,7 +3,9 @@
:title="'修改定制功能'"
:close-on-click-modal="false"
:before-close="handleClose"
- :close-on-press-escape="false">
+ :close-on-press-escape="false"
+ :width="60+'%'"
+ :top="'20px'">
@@ -44,6 +47,7 @@
@@ -73,7 +77,7 @@
:before-upload="beforeImgUpload">
@@ -82,20 +86,21 @@
-
-
+
-
-
-
@@ -144,6 +139,7 @@ export default {
return {
visible: false,
type: '', // 操作类型A/U
+ functionId: '', // 父组件传来功能id
dataForm: {
functionId: '',
functionName: '',
@@ -154,9 +150,10 @@ export default {
functionExplain: '',
targetLink: '',
domainName: '',
- domainNameList: [],
fromApp: 'resi'
},
+ domainNameList: [],
+ isApply: 0,//客户是否在用
uploadUlr: window.SITE_CONFIG['apiURL'] + '/oss/file/function/upload',
fromAppList: [
{
@@ -209,26 +206,55 @@ export default {
}
},
methods: {
- init (dataForm, type) {
+ init (functionId, type) {
this.type = type
this.visible = true
- // this.dataForm=dataForm
-
- this.$nextTick(() => {
- dataForm.functionName = dataForm.customizedName
- if (dataForm.domainName === '') {
- dataForm.domainNameList.push('')
- } else {
- dataForm.domainNameList = dataForm.domainName.split(';')
+ this.functionId = functionId
+ if (type === 'A') {
+ this.dataForm = {
+ functionId: '',
+ functionName: '',
+ customizedName: '',
+ iconLargeImg: '',
+ iconSmallImg: '',
+ shoppingStatus: '1',
+ functionExplain: '',
+ targetLink: '',
+ domainName: '',
+ fromApp: 'resi'
}
- Object.assign(this.dataForm, dataForm)
- })
+ this.domainNameList = ['']
+ this.isApply = 0
+ } else {
+ this.loadFormData()
+ }
},
addRequest () {
- this.dataForm.domainNameList.push('')
+ // eslint-disable-next-line
+ // debugger
+ this.domainNameList.push('')
},
delRequest (index) {
- this.dataForm.domainNameList.splice(index, 1)
+ this.domainNameList.splice(index, 1)
+ },
+
+ loadFormData () {
+ // const url='https://nei.netease.com/api/apimock-v2/e3b1d0eb88e905f6c7ee559b2d6bb7ad/oper/customize/functioncustomized/getfunctioncustomized'
+ const url = '/oper/customize/functioncustomized/getfunctioncustomized'
+ let _data = {
+ functionId: this.functionId
+ }
+ window.app.ajax.post(url, _data,
+ (data, rspMsg) => {
+ this.dataForm = data
+ // this.dataForm.domainNameList = this.dataForm.domainName.split(';')
+ this.domainNameList = this.dataForm.domainName.split(';')
+ this.isApply = data.isApply
+ },
+ (rspMsg, data) => {
+ this.endLoading()
+ this.$message.error(rspMsg)
+ })
},
// 上传大图标成功
@@ -273,9 +299,9 @@ export default {
// eslint-disable-next-line
// debugger
let domainName = ''
- for (let i = 0; i < this.dataForm.domainNameList.length; i++) {
- if (this.dataForm.domainNameList[i] !== '') {
- domainName = domainName + this.dataForm.domainNameList[i] + ';'
+ for (let i = 0; i < this.domainNameList.length; i++) {
+ if (this.domainNameList[i] !== '') {
+ domainName = domainName + this.domainNameList[i] + ';'
}
}
domainName = domainName.substring(0, domainName.length - 1)
@@ -337,7 +363,7 @@ export default {
width: 300px;
}
.item_width_2 {
- width: 700px;
+ width: 500px;
}
.block {
display: block;
diff --git a/epmet-oper-web/src/views/pages/login.vue b/epmet-oper-web/src/views/pages/login.vue
index 5537a7e..15d07cc 100644
--- a/epmet-oper-web/src/views/pages/login.vue
+++ b/epmet-oper-web/src/views/pages/login.vue
@@ -7,51 +7,81 @@
{{ $t('login.title') }}
-
+
-
-
+
+
-
-
-
+
+
+
-
-
-
+
+
+
-
-
-
+
+
+
-
-
+
+
- {{ $t('login.title') }}
+ {{ $t('login.title') }}
@@ -104,7 +134,7 @@ export default {
this.captchaPath = `${window.SITE_CONFIG['apiURL']}/auth/login/captcha?uuid=${this.dataForm.uuid}`
},
// 表单提交
- dataFormSubmitHandle: debounce(function () {
+ dataFormSubmitHandle: debounce(function() {
this.$refs['dataForm'].validate((valid) => {
if (!valid) {
return false
@@ -116,7 +146,7 @@ export default {
}
Cookies.set('token', res.data.token)
this.$router.replace({ name: 'home' })
- }).catch(() => {})
+ }).catch(() => { })
})
}, 1000, { 'leading': true, 'trailing': false })
}
diff --git a/epmet-oper-web/src/views/pages/loginWork.vue b/epmet-oper-web/src/views/pages/loginWork.vue
new file mode 100644
index 0000000..d436624
--- /dev/null
+++ b/epmet-oper-web/src/views/pages/loginWork.vue
@@ -0,0 +1,155 @@
+
+
+
WorkWorkWorkWorkWork
+
+
+
+
+
{{ $t('login.title') }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ $t('login.title') }}
+
+
+
+
+
+
+
+
+
+