Browse Source

合并冲突

shibei_master
jiangyy 4 years ago
parent
commit
5ec86b8f1e
  1. 2
      .env.production
  2. 2
      public/index.html
  3. 4
      src/assets/scss/modules/search.scss
  4. 1
      src/js/dai/request.js
  5. 13
      src/views/main-shuju/main.vue
  6. 16
      src/views/main.vue
  7. 58
      src/views/modules/base/community/buildTable.vue
  8. 40
      src/views/modules/base/community/community.vue
  9. 62
      src/views/modules/base/community/communityTable.vue
  10. 63
      src/views/modules/base/community/roomTable.vue
  11. 16
      src/views/modules/shequ/index.vue

2
.env.production

@ -1,4 +1,4 @@
NODE_ENV=production
VUE_APP_API_SERVER = https://epdc-shibei.elinkservice.cn/api
VUE_APP_API_SERVER = https://epmet-cloud.elinkservice.cn/api
VUE_APP_NODE_ENV=prod
VUE_APP_PUBLIC_PATH=epmet-oper

2
public/index.html

@ -64,7 +64,7 @@
<!-- 生产环境 -->
<% if (process.env.VUE_APP_NODE_ENV==='prod' ) { %>
<script>
window.SITE_CONFIG['apiURL'] = 'https://epdc-shibei.elinkservice.cn/api'
window.SITE_CONFIG['apiURL'] = 'https://epmet-cloud.elinkservice.cn/api'
</script>
<% } %>
</head>

4
src/assets/scss/modules/search.scss

@ -26,13 +26,15 @@
.input {
position: relative;
select {
.select-show {
border: none;
display: block;
font-size: 16px;
width: 90px;
line-height: 32px;
text-align: center;
color: #0082fb;
cursor: default;
}
input {

1
src/js/dai/request.js

@ -2,7 +2,6 @@
| 请求接口封装 |
---------------------------------------------------------------*/
import axios from "axios";
import curry from "dai-js/tools/curry";
import { Message } from "element-ui";

13
src/views/main-shuju/main.vue

@ -1,6 +1,5 @@
<template>
<div
v-loading.fullscreen.lock="loading"
<div v-loading.fullscreen.lock="loading"
:element-loading-text="$t('loading')"
:class="[
'g-bd',
@ -8,15 +7,12 @@
{
'z-sidebar--noside': true,
},
]"
>
]">
<template v-if="!loading">
<main-navbar ref="ref_navbar" />
<div class="g-cnt">
<main-content
v-if="!$store.state.contentIsNeedRefresh"
@changeCustomerName="changeCustomerName"
/>
<main-content v-if="!$store.state.contentIsNeedRefresh"
@changeCustomerName="changeCustomerName" />
</div>
</template>
</div>
@ -115,6 +111,7 @@ export default {
localStorage.setItem("roleList", data.roleList);
localStorage.setItem("customerId", data.customerId);
localStorage.setItem("staffId", data.id);
localStorage.setItem("agencyId", data.agencyId);
if (!localStorage.getItem("customerName")) {
localStorage.setItem("customerName", data.customerName || "");
}

16
src/views/main.vue

@ -1,6 +1,5 @@
<template>
<div
v-loading.fullscreen.lock="loading"
<div v-loading.fullscreen.lock="loading"
:element-loading-text="$t('loading')"
:class="[
'aui-wrapper',
@ -10,16 +9,14 @@
$store.state.sidebarActiveSubMenuList.length == 0 || $store.state.inIframe,
},
{ 'z-iframe': $store.state.inIframe },
]"
>
]">
<template v-if="!loading">
<main-navbar ref="ref_navbar" v-if="!$store.state.inIframe" />
<main-navbar ref="ref_navbar"
v-if="!$store.state.inIframe" />
<main-sidebar v-if="!$store.state.inIframe" />
<div class="aui-content__wrapper">
<main-content
v-if="!$store.state.contentIsNeedRefresh"
@changeCustomerName="changeCustomerName"
/>
<main-content v-if="!$store.state.contentIsNeedRefresh"
@changeCustomerName="changeCustomerName" />
</div>
<main-theme-tools v-if="!$store.state.inIframe" />
</template>
@ -148,6 +145,7 @@ export default {
localStorage.setItem("roleList", data.roleList);
localStorage.setItem("customerId", data.customerId);
localStorage.setItem("staffId", data.id);
localStorage.setItem("agencyId", data.agencyId);
if (!localStorage.getItem("customerName")) {
localStorage.setItem("customerName", data.customerName || "");
}

58
src/views/modules/base/community/buildTable.vue

@ -41,7 +41,8 @@
size="small"
icon="el-icon-plus"
@click="handleAdd">新增楼宇</el-button>
<div class="btn_upload"
v-if="showImportBtn">
<el-button style=";margin-left:10px"
type="blue"
size="small"
@ -83,6 +84,7 @@
type="red">导入房屋数据</el-button>
</el-upload>
</div>
</div>
<div class="div_table">
<el-table ref="ref_table"
@ -134,12 +136,14 @@
style="color:#1C6AFD;text-decoration: underline;"
size="small"
@click="handleDetail(scope.row)">查看</el-button>
<el-button type="text"
<el-button v-if="scope.row.showBtn"
type="text"
style="color:#00A7A9;text-decoration: underline;"
size="small"
@click="handleEdit(scope.row)">修改</el-button>
<el-button type="text"
<el-button v-if="scope.row.showBtn"
type="text"
style="color:#D51010;text-decoration: underline;"
size="small"
@click="handleDelete(scope.row)">删除</el-button>
@ -206,6 +210,7 @@ export default {
tableLoading: true,
selAllFlag: false,
isIndeterminate: false,//
// showImportBtn: false,//
agencyObj: {},//
ownerName: '',
@ -242,8 +247,17 @@ export default {
async loadTable (fromTree, treeObj) {
this.tableLoading = true
if (fromTree) {
this.agencyObj = treeObj
// if (this.agencyObj.pid === this.staffAgencyId) {//idid
// this.showImportBtn = true
// } else {
// this.showImportBtn = false
// }
}
console.log(this.agencyObj)
const url = "/gov/org/building/buildinglist"
let params = {
@ -258,6 +272,14 @@ export default {
if (code === 0) {
this.total = data.total
data.list.forEach(item => {
if (item.agencyId === this.staffAgencyId) {
item.showBtn = true
} else {
item.showBtn = false
}
});
this.tableData = data.list
} else {
this.$message.error(msg)
@ -410,10 +432,11 @@ export default {
this.$emit('refreshTree')
this.loadTable()
} else if (code > 8000) {
// this.$message({
// type: "success",
// message: msg
// });
this.$message({
showClose: true,
message: msg,
duration: 0
})
this.$emit('refreshTree')
this.loadTable()
} else {
@ -590,12 +613,12 @@ export default {
if (data.code === 0 && data.msg == 'success') {
// this.$message.success('')
} else {
this.$message({
showClose: true,
message: rspMsg,
duration: 0,
type: "error"
})
// this.$message({
// showClose: true,
// message: rspMsg,
// duration: 0,
// type: "error"
// })
// this.$message.error(rspMsg)
}
this.$emit('refreshTree')
@ -660,7 +683,14 @@ export default {
}
},
props: {
staffAgencyId: {
type: String,
default: '',
},
showImportBtn: {
type: Boolean,
default: false,
},
}
}
</script>

40
src/views/modules/base/community/community.vue

@ -29,13 +29,18 @@
<build-table v-if="selTreeObj.level==='neighborHood'"
ref="ref_neighTable"
:staffAgencyId="staffAgencyId"
:showImportBtn="showImportBtn"
@toNextLevel="toNextLevel"
@refreshTree="refreshTree"></build-table>
<room-table v-else-if="selTreeObj.level==='building'"
:staffAgencyId="staffAgencyId"
:showImportBtn="showImportBtn"
ref="ref_buildingTable"
@refreshTree="refreshTree"></room-table>
<community-table v-else
@toNextLevel="toNextLevel"
:staffAgencyId="staffAgencyId"
ref="ref_communityTable"
@refreshTree="refreshTree"></community-table>
@ -67,7 +72,9 @@ export default {
selTreeObj: {},
centerPoint: []
centerPoint: [],
staffAgencyId: localStorage.getItem("agencyId"),
showImportBtn: false
}
},
@ -78,6 +85,7 @@ export default {
this.treeLoading = true
await this.loadOrgData()
await this.loadTree()
await this.$refs['ref_communityTable'].loadTable(true, this.selTreeObj)
if (this.treeData.length > 0) {
this.$nextTick(() => {
@ -147,7 +155,12 @@ export default {
handleNodeClick (obj) {
this.getTreeObj(obj)
this.$nextTick(() => {
if (obj.level === 'building') {//
this.$refs['ref_buildingTable'].loadTable(true, this.selTreeObj)
@ -196,18 +209,31 @@ export default {
// idtypeidid
// idtypeid
if (obj.level === 'building') {//
let communityNode = this.$refs.ref_tree.getNode(obj.pid)
obj.communityId = communityNode.data.id
obj.communityName = communityNode.data.label
let neighborHoodNode = this.$refs.ref_tree.getNode(obj.pid)//
} else if (obj.level === 'neighborHood') {//
let gridNode = this.$refs.ref_tree.getNode(neighborHoodNode.data.pid)//
let agencyNode = this.$refs.ref_tree.getNode(gridNode.data.pid)//
obj.agencyId = agencyNode.data.id
obj.agencyName = agencyNode.data.label
if (obj.agencyId === this.staffAgencyId) {
this.showImportBtn = true
} else {
this.showImportBtn = false
}
} else if (obj.level === 'neighborHood') {//
let gridNode = this.$refs.ref_tree.getNode(obj.pid)
let agencyNode = this.$refs.ref_tree.getNode(gridNode.data.pid)
obj.gridId = gridNode.data.id
obj.gridName = gridNode.data.label
obj.agencyId = agencyNode.data.id
obj.agencyName = agencyNode.data.label
if (obj.agencyId === this.staffAgencyId) {
this.showImportBtn = true
} else {
this.showImportBtn = false
}
} else {
}
@ -276,8 +302,8 @@ export default {
.div_table {
margin-left: 15px;
flex: 1;
// width: calc(100vw - 550px);
// flex: 1;
width: calc(100vw - 550px);
background-color: #ffffff;
border-radius: 5px;
padding: 10px;

62
src/views/modules/base/community/communityTable.vue

@ -42,7 +42,7 @@
icon="el-icon-plus"
@click="handleAdd">新增小区</el-button>
<div class="btn_upload"
v-if="agencyObj.level==='community'||agencyObj.level==='grid'">
v-if="showImportBtn">
<el-button style=""
type="blue"
size="small"
@ -157,12 +157,14 @@
style="color:#1C6AFD;text-decoration: underline;"
size="small"
@click="handleDetail(scope.row)">查看</el-button>
<el-button type="text"
<el-button v-if="scope.row.showBtn"
type="text"
style="color:#00A7A9;text-decoration: underline;"
size="small"
@click="handleEdit(scope.row)">修改</el-button>
<el-button type="text"
<el-button v-if="scope.row.showBtn"
type="text"
style="color:#D51010;text-decoration: underline;"
size="small"
@click="handleDelete(scope.row)">删除</el-button>
@ -229,6 +231,7 @@ export default {
tableLoading: true,
selAllFlag: false,
isIndeterminate: false,//
showImportBtn: false,//
agencyObj: {},//
ownerName: '',
@ -236,6 +239,7 @@ export default {
tableData: [],
selection: [],
//form
formShow: false,
formTitle: '新增小区',
@ -254,7 +258,6 @@ export default {
},
computed: {
tableHeight () {
return (this.clientHeight - 300)
},
@ -269,9 +272,26 @@ export default {
this.loadTable()
},
async loadTable (fromTree, treeObj) {
console.log(111, this.staffAgencyId)
this.tableLoading = true
if (fromTree) {
this.agencyObj = treeObj
if (this.agencyObj.level === 'community') {//
if (this.agencyObj.id === this.staffAgencyId) {//idid
this.showImportBtn = true
} else {
this.showImportBtn = false
}
} else if (this.agencyObj.level === 'grid') {//
if (this.agencyObj.pid === this.staffAgencyId) {//idid
this.showImportBtn = true
} else {
this.showImportBtn = false
}
} else {
this.showImportBtn = false
}
}
const url = "/gov/org/neighborhood/neighborhoodlist"
@ -289,6 +309,14 @@ export default {
if (code === 0) {
this.total = data.total
data.list.forEach(item => {
if (item.agencyId === this.staffAgencyId) {
item.showBtn = true
} else {
item.showBtn = false
}
});
this.tableData = data.list
} else {
this.$message.error(msg)
@ -440,11 +468,11 @@ export default {
this.$emit('refreshTree')
this.loadTable()
} else if (code > 8000) {
// this.$message({
// showClose: true,
// message: msg,
// duration: 0
// })
this.$message({
showClose: true,
message: msg,
duration: 0
})
this.$emit('refreshTree')
this.loadTable()
} else {
@ -624,12 +652,12 @@ export default {
if (data.code === 0 && data.msg == 'success') {
// this.$message.success('')
} else {
this.$message({
showClose: true,
message: rspMsg,
duration: 0,
type: "error"
})
// this.$message({
// showClose: true,
// message: rspMsg,
// duration: 0,
// type: "error"
// })
// this.$message.error(rspMsg)
}
this.$emit('refreshTree')
@ -702,6 +730,10 @@ export default {
}
},
props: {
staffAgencyId: {
type: String,
default: '',
},
}
}

63
src/views/modules/base/community/roomTable.vue

@ -41,6 +41,8 @@
icon="el-icon-plus"
size="small"
@click="handleAdd">新增房屋</el-button>
<div class="btn_upload"
v-if="showImportBtn">
<el-button style="float:left"
type="blue"
size="small"
@ -62,6 +64,7 @@
type="red">导入房屋数据</el-button>
</el-upload>
</div>
</div>
<div class="div_table">
<el-table ref="ref_table"
@ -125,12 +128,14 @@
style="color:#1C6AFD;text-decoration: underline;"
size="small"
@click="handleDetail(scope.row)">查看</el-button>
<el-button type="text"
<el-button v-if="scope.row.showBtn"
type="text"
style="color:#00A7A9;text-decoration: underline;"
size="small"
@click="handleEdit(scope.row)">修改</el-button>
<el-button type="text"
<el-button v-if="scope.row.showBtn"
type="text"
style="color:#D51010;text-decoration: underline;"
size="small"
@click="handleDelete(scope.row)">删除</el-button>
@ -195,6 +200,7 @@ export default {
tableLoading: true,
selAllFlag: false,
isIndeterminate: false,//
// showImportBtn: false,//
agencyObj: {},//
ownerName: '',
@ -234,6 +240,21 @@ export default {
this.tableLoading = true
if (fromTree) {
this.agencyObj = treeObj
// if (this.agencyObj.level === 'community') {//
// if (this.agencyObj.id === this.staffAgencyId) {//idid
// this.showImportBtn = true
// } else {
// this.showImportBtn = false
// }
// } else if (this.agencyObj.level === 'grid') {//
// if (this.agencyObj.pid === this.staffAgencyId) {//idid
// this.showImportBtn = true
// } else {
// this.showImportBtn = false
// }
// } else {
// this.showImportBtn = false
// }
}
const url = "/gov/org/house/houselist"
@ -250,6 +271,14 @@ export default {
if (code === 0) {
this.total = data.total
data.list.forEach(item => {
if (item.agencyId === this.staffAgencyId) {
item.showBtn = true
} else {
item.showBtn = false
}
});
this.tableData = data.list
} else {
this.$message.error(msg)
@ -397,10 +426,11 @@ export default {
this.$emit('refreshTree')
this.loadTable()
} else if (code > 8000) {
// this.$message({
// type: "success",
// message: msg
// });
this.$message({
showClose: true,
message: msg,
duration: 0
})
this.$emit('refreshTree')
this.loadTable()
} else {
@ -553,12 +583,12 @@ export default {
if (data.code === 0 && data.msg == 'success') {
// this.$message.success('')
} else {
this.$message({
showClose: true,
message: rspMsg,
duration: 0,
type: "error"
})
// this.$message({
// showClose: true,
// message: rspMsg,
// duration: 0,
// type: "error"
// })
// this.$message.error(rspMsg)
}
this.$emit('refreshTree')
@ -615,7 +645,14 @@ export default {
}
},
props: {
staffAgencyId: {
type: String,
default: '',
},
showImportBtn: {
type: Boolean,
default: false,
},
}
}
</script>

16
src/views/modules/shequ/index.vue

@ -9,11 +9,17 @@
<div class="search">
<div class="input">
<select v-model="searchData.type">
<option value="jumin">居民</option>
<option value="fangwu">房屋</option>
<option value="xuqiu">需求</option>
</select>
<el-dropdown class="select"
placement="bottom" v-model="searchData.type" @command="type => searchData.type = type">
<span class="select-show">
{{{jumin:'居民', fangwu: '房屋', xuqiu:'需求'}[searchData.type]}}<i class="el-icon-arrow-down el-icon--right"></i>
</span>
<el-dropdown-menu slot="dropdown">
<el-dropdown-item command="jumin">居民</el-dropdown-item>
<el-dropdown-item command="fangwu">房屋</el-dropdown-item>
<el-dropdown-item command="xuqiu">需求</el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
<input
type="text"

Loading…
Cancel
Save