Commit 352a1fb5 authored by levante's avatar levante

Initial commit

parent 02d5c89b
...@@ -18,18 +18,17 @@ ...@@ -18,18 +18,17 @@
</div> </div>
<div> <div>
<!-- <a-badge :count="0" showZero><a><a-icon type="bell" /></a></a-badge> --> <!-- <a-badge :count="0" showZero><a><a-icon type="bell" /></a></a-badge> -->
<a-dropdown class="navdropmenu" style="margin-right:20px;"> <!-- <a-dropdown class="navdropmenu" style="margin-right:20px;">
<span> <span>
<a-icon type="user" /> <a-icon type="user" />
<span class="name">{{username}}</span> <span class="name">{{username}}</span>
<a-icon type="down" /> <a-icon type="down" />
</span> </span>
<a-menu slot="overlay" @click="handleClick"> <a-menu slot="overlay" @click="handleClick">
<!-- <a-menu-item key="1">个人中心</a-menu-item> -->
<a-menu-item key="changePwd" @click="showChangePwdModal">修改密码</a-menu-item> <a-menu-item key="changePwd" @click="showChangePwdModal">修改密码</a-menu-item>
<a-menu-item key="2">退出登录</a-menu-item> <a-menu-item key="2">退出登录</a-menu-item>
</a-menu> </a-menu>
</a-dropdown> </a-dropdown> -->
</div> </div>
</a-layout-header> </a-layout-header>
<a-layout-content class="layout-content"> <a-layout-content class="layout-content">
...@@ -157,8 +156,8 @@ export default { ...@@ -157,8 +156,8 @@ export default {
}, },
}, },
created(){ created(){
this.getLogo() // this.getLogo()
this.getInfo() // this.getInfo()
}, },
methods: { methods: {
showChangePwdModal(){ showChangePwdModal(){
......
...@@ -299,9 +299,9 @@ export default { ...@@ -299,9 +299,9 @@ export default {
}, },
created(){ created(){
this.getLogo() // this.getLogo()
this.getInfo() // this.getInfo()
/** 持久化存储vuex 使其页面刷新后数据不丢失 */ /** 持久化存储vuex 使其页面刷新后数据不丢失 */
//在页面加载时读取sessionStorage里的状态信息 //在页面加载时读取sessionStorage里的状态信息
......
...@@ -54,7 +54,7 @@ export default { ...@@ -54,7 +54,7 @@ export default {
return { return {
openKeys: [], openKeys: [],
selectedKeys: [], selectedKeys: [],
// menus: [], menus: [],
isAllPerm: false isAllPerm: false
} }
}, },
...@@ -68,76 +68,37 @@ export default { ...@@ -68,76 +68,37 @@ export default {
}, },
}, },
mounted(){ mounted(){
// this.$ajax.get({ let menus = []
// url: this.$api.GET_USER_INFO, let tempmenu = []
// }).then(res => { for(let i=0;i<routes.length;i++){
// if(res.code == 200) { if(!!routes[i].children){
// this.isAllPerm = res.data.content.isAllPerm for(let j=0;j<routes[i].children.length;j++){
// console.log(this.isAllPerm) if(!!routes[i].children[j].meta.menuIcon && routes[i].children[j].name == 'systemManagement' && isLoadExtendMenu == 'false'){
// let menus=[] let target = routes[i].children[j].children
// let tempmenu = [] if(target.length > 0) {
// let isLoadExtendMenu = this.$cookie.get('customKeyEnable') for(let k = 0 ; k < target.length; k++) {
// for(let i=0;i<routes.length;i++){ tempmenu.push(target[k])
// if(!!routes[i].children){ }
// for(let j=0;j<routes[i].children.length;j++){ }
// if(!!this.isAllPerm) { // 超管访问 let lusso = routes[i].children[j]
// if(!!routes[i].children[j].meta.menuIcon && routes[i].children[j].name == 'systemManagement' && isLoadExtendMenu == 'false'){ lusso.children = []
// let target = routes[i].children[j].children lusso.children = tempmenu
// if(target.length > 0) { menus.push(lusso)
// for(let k = 0 ; k < target.length; k++) { } else if (!!routes[i].children[j].meta.menuIcon) {
// if(target[k].name == 'tbls') { menus.push(routes[i].children[j])
// if(isLoadExtendMenu == 'true') { }
// tempmenu.push(target[k])
// } }
// } else { }
// tempmenu.push(target[k]) }
// }
// } this.menus = menus
// }
// let lusso = routes[i].children[j]
// lusso.children = []
// lusso.children = tempmenu
// menus.push(lusso)
// } else if (!!routes[i].children[j].meta.menuIcon) {
// menus.push(routes[i].children[j])
// }
// } else if(!this.isAllPerm) { // 非超管访问
// if(routes[i].children[j].meta.isAllPerm == false) {
// if(!!routes[i].children[j].meta.menuIcon && routes[i].children[j].name == 'systemManagement' && isLoadExtendMenu == 'false'){
// let target = routes[i].children[j].children
// if(target.length > 0) {
// for(let k = 0 ; k < target.length; k++) {
// if(target[k].name == 'tbls') {
// if(isLoadExtendMenu == 'true') {
// tempmenu.push(target[k])
// }
// } else {
// tempmenu.push(target[k])
// }
// }
// }
// let lusso = routes[i].children[j]
// lusso.children = []
// lusso.children = tempmenu
// menus.push(lusso)
// } else if (!!routes[i].children[j].meta.menuIcon) {
// menus.push(routes[i].children[j])
// }
// }
// }
// }
// }
// }
// this.menus=menus
// }
// })
}, },
computed: { computed: {
menus(){ // menus(){
// console.log(this.$store.state.menuList) // // console.log(this.$store.state.menuList)
return this.$store.state.menuList // return this.$store.state.menuList
} // }
}, },
methods: { methods: {
// 点击菜单,收起其他展开的菜单 // 点击菜单,收起其他展开的菜单
......
...@@ -87,19 +87,19 @@ function GetRoutes(router) { ...@@ -87,19 +87,19 @@ function GetRoutes(router) {
const { routes } = router.options const { routes } = router.options
const parent = routes.find(item => item.name === 'Layout') const parent = routes.find(item => item.name === 'Layout')
for (let key in micSystemRoutersConfigs) { // for (let key in micSystemRoutersConfigs) {
for (let i = 0; i < micSystemRoutersConfigs[key].length; i++) { // for (let i = 0; i < micSystemRoutersConfigs[key].length; i++) {
let firstRouter = Object.assign({}, micSystemRoutersConfigs[key][i]) // let firstRouter = Object.assign({}, micSystemRoutersConfigs[key][i])
if ( // if (
!!firstRouter.meta.openMode && // !!firstRouter.meta.openMode &&
firstRouter.meta.openMode == 'outsite' // firstRouter.meta.openMode == 'outsite'
) { // ) {
firstRouter.component = TipsOutsite // firstRouter.component = TipsOutsite
} // }
parent.children.push(Object.assign({}, firstRouter)) // parent.children.push(Object.assign({}, firstRouter))
router.addRoutes([ parent ]) // router.addRoutes([ parent ])
} // }
} // }
} }
......
...@@ -12,17 +12,17 @@ const router = new Router({ ...@@ -12,17 +12,17 @@ const router = new Router({
routes, routes,
}) })
router.beforeEach((to, from, next) => { // router.beforeEach((to, from, next) => {
// TODO // // TODO
store.commit('setWebviewSrc', to.meta && to.meta.src) // 判断有src的话为需要嵌入iframe的子项目 // store.commit('setWebviewSrc', to.meta && to.meta.src) // 判断有src的话为需要嵌入iframe的子项目
const token = Cookie.get('token') // const token = Cookie.get('token')
// 当前无token且不在login页面则推到登录页面 // // 当前无token且不在login页面则推到登录页面
if (to.path != '/login' && !token) { // if (to.path != '/login' && !token) {
next('/login') // next('/login')
} else { // } else {
next() // next()
} // }
}) // })
export default router export default router
This diff is collapsed.
...@@ -103,6 +103,7 @@ const errorHandler = (err) => { ...@@ -103,6 +103,7 @@ const errorHandler = (err) => {
Axios.interceptors.request.use(config => { Axios.interceptors.request.use(config => {
const token = Cookie.get('token') || Store.state.token const token = Cookie.get('token') || Store.state.token
console.log(token)
if (token) { if (token) {
config.headers.Authorization = token config.headers.Authorization = token
} }
......
let BASE_URL = '', MOCK_URL='', let BASE_URL = '', MOCK_URL='', WBX_URL = '',
FANGDI_URL = 'http://962121.fgj.sh.gov.cn/wyweb/shanghaiwuye' FANGDI_URL = 'http://962121.fgj.sh.gov.cn/wyweb/shanghaiwuye'
switch (process.env.NODE_ENV) { switch (process.env.NODE_ENV) {
...@@ -38,6 +38,7 @@ default: // 默认环境下(开发环境) ...@@ -38,6 +38,7 @@ default: // 默认环境下(开发环境)
// BASE_URL = 'http://31.0.161.39/apiv2' // BASE_URL = 'http://31.0.161.39/apiv2'
// BASE_URL = 'http://211.136.105.193/apiv2' // BASE_URL = 'http://211.136.105.193/apiv2'
// BASE_URL = 'http://yangpu-hm.omniview.pro/api/v2' // BASE_URL = 'http://yangpu-hm.omniview.pro/api/v2'
WBX_URL = 'http://wbx.omniview.pro'
BASE_URL = 'http://yangpu-hm.omniview.pro/api/v2' BASE_URL = 'http://yangpu-hm.omniview.pro/api/v2'
// BASE_URL = 'http://pudong.hm.omniview.pro/api/v2' // BASE_URL = 'http://pudong.hm.omniview.pro/api/v2'
// BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2' // BASE_URL = 'http://xuhui.hm.omniview.pro/api/v2'
...@@ -228,5 +229,6 @@ export default { ...@@ -228,5 +229,6 @@ export default {
POST_LABEL_RESULT_PREVIEW: '/service-customkey-ddd/findLabelObject', // 标签预览 POST_LABEL_RESULT_PREVIEW: '/service-customkey-ddd/findLabelObject', // 标签预览
POST_LABEL_CREATE_CONFIRM: '/service-customkey-ddd/label/confirm', POST_LABEL_CREATE_CONFIRM: '/service-customkey-ddd/label/confirm',
GET_ID_INFO_BY_LABEL: '/service-customkey-ddd/label/resource/datas', GET_ID_INFO_BY_LABEL: '/service-customkey-ddd/label/resource/datas',
GET_WY_AND_YWH_LIST: '/service-customkey-ddd/datas' GET_WY_AND_YWH_LIST: '/service-customkey-ddd/datas',
GET_RESERVATION_LIST: WBX_URL + '/api/service-documents/repair/reservations'
} }
...@@ -714,27 +714,27 @@ export default { ...@@ -714,27 +714,27 @@ export default {
mounted(){ mounted(){
this.getConfig() this.getConfig()
this.getList() this.getList()
this.$ajax.get({ // this.$ajax.get({
url: this.$api.GET_USER_INFO, // url: this.$api.GET_USER_INFO,
}).then(res => { // }).then(res => {
if(res.code == 200) { // if(res.code == 200) {
if(!!res.data.content.isAllPerm) { // if(!!res.data.content.isAllPerm) {
this.getDisposal() // this.getDisposal()
this.getHouthMonth() // this.getHouthMonth()
this.getCheckData() // this.getCheckData()
this.getCheckPeople() // this.getCheckPeople()
this.getSectNum() // this.getSectNum()
this.getReceiptsNum() // this.getReceiptsNum()
this.getRepair() // this.getRepair()
this.getTousuQuestion('M') // this.getTousuQuestion('M')
this.getTousuQuestion('Y') // this.getTousuQuestion('Y')
this.getTousuQuestion('S') // this.getTousuQuestion('S')
this.getTousuDensity('M') // this.getTousuDensity('M')
this.getTousuDensity('Y') // this.getTousuDensity('Y')
this.getTousuDensity('S') // this.getTousuDensity('S')
} // }
} // }
}) // })
// }) // })
// if (this.$store.state.userinfos && this.$store.state.userinfos.isAllPerm) { // 不是全部权限dashboard下方的模块不展示 // if (this.$store.state.userinfos && this.$store.state.userinfos.isAllPerm) { // 不是全部权限dashboard下方的模块不展示
// this.getDisposal() // this.getDisposal()
......
...@@ -715,27 +715,27 @@ export default { ...@@ -715,27 +715,27 @@ export default {
mounted(){ mounted(){
this.getConfig() this.getConfig()
this.getList() this.getList()
this.$ajax.get({ // this.$ajax.get({
url: this.$api.GET_USER_INFO, // url: this.$api.GET_USER_INFO,
}).then(res => { // }).then(res => {
if(res.code == 200) { // if(res.code == 200) {
if(!!res.data.content.isAllPerm) { // if(!!res.data.content.isAllPerm) {
this.getDisposal() // this.getDisposal()
this.getHouthMonth() // this.getHouthMonth()
this.getCheckData() // this.getCheckData()
this.getCheckPeople() // this.getCheckPeople()
this.getSectNum() // this.getSectNum()
this.getReceiptsNum() // this.getReceiptsNum()
this.getRepair() // this.getRepair()
this.getTousuQuestion('M') // this.getTousuQuestion('M')
this.getTousuQuestion('Y') // this.getTousuQuestion('Y')
this.getTousuQuestion('S') // this.getTousuQuestion('S')
this.getTousuDensity('M') // this.getTousuDensity('M')
this.getTousuDensity('Y') // this.getTousuDensity('Y')
this.getTousuDensity('S') // this.getTousuDensity('S')
} // }
} // }
}) // })
// }) // })
// if (this.$store.state.userinfos && this.$store.state.userinfos.isAllPerm) { // 不是全部权限dashboard下方的模块不展示 // if (this.$store.state.userinfos && this.$store.state.userinfos.isAllPerm) { // 不是全部权限dashboard下方的模块不展示
// this.getDisposal() // this.getDisposal()
......
...@@ -81,7 +81,7 @@ export default { ...@@ -81,7 +81,7 @@ export default {
}, },
created(){ created(){
this.getLogo() this.getLogo()
this.getInfo() // this.getInfo()
}, },
methods: { methods: {
getInfo() { getInfo() {
......
<template>
<div class="routerWapper">
<div class="portalDetailTitle" v-if="$route.name=='receiptList'">
<span class="title">预约列表</span>
</div>
<div v-if="$route.name=='receiptList'" class="layoutMargin layoutPadding">
<div class="portalTableOperates">
<a-table bordered class="portalTable" :dataSource="receiptList" :columns="columns" size="small" :pagination="pagination" rowKey="id">
<span slot="homeDate" slot-scope="text,record" align="center">
{{!!record.homeDate? record.homeDate.split(' ')[0]: ''}}
</span>
</a-table>
</div>
</div>
</div>
</template>
<script>
export default {
data() {
return {
receiptList: [],
pagination: {//分页
pageNo: 1,
pageSize: 10,
total: 10,
current: 1,
defaultCurrent: 1,
showQuickJumper: true,
onChange: this.pageChange
},
columns: [
{
title: '小区名称',
dataIndex: 'stNameFrst',
align: 'center',
key: 'stNameFrst',
},
{
title: '门牌详细地址',
dataIndex: 'addrFrst',
align: 'center',
key: 'addrFrst',
},
{
title: '报修部位',
dataIndex: 'place',
align: 'center',
key: 'place',
},
{
title: '报修类型',
dataIndex: 'type',
align: 'center',
key: 'type',
},
{
title: '描述',
dataIndex: 'dscr',
align: 'center',
key: 'dscr',
},
{
title: '上门日期',
dataIndex: 'homeDate',
align: 'center',
key: 'homeDate',
scopedSlots: {
customRender: 'homeDate',
},
},
{
title: '上门时间',
dataIndex: 'homeTime',
align: 'center',
key: 'homeTime',
},
]
}
},
mounted() {
this.getList()
},
methods: {
getList() {
this.$ajax.get({
url: this.$api.GET_RESERVATION_LIST,
params: {
pageNo: this.pagination.current,
pageSize: this.pagination.pageSize,
homeDate_desc: 'desc'
}
}).then(res => {
if (res.code == 200) {
//先获取全部的自定义字段列表
this.receiptList = this.$com.confirm(res, 'data.content', [])
this.pagination.total=res.data.totalRows
// console.log(this.extList)
}
})
},
pageChange(val) {
this.pagination.pageNo = val
this.pagination.current = val
this.getList()
},
}
}
</script>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment