Browse Source

Merge branch 'dev-220309' of http://git.elinkit.com.cn:7070/r/epmet-oper-gov into dev-220309

shibei_master
jiangyy 3 years ago
parent
commit
f1863fbf91
  1. 2
      src/assets/scss/buttonstyle.scss
  2. 62
      src/assets/scss/modules/search.scss
  3. 147
      src/assets/scss/modules/warning.scss
  4. 2
      src/views/components/resiSearch.vue
  5. 88
      src/views/modules/base/resi.vue
  6. 43
      src/views/modules/communityParty/elegant/index.vue
  7. 22
      src/views/modules/communityService/sqzzz/index.vue
  8. 200
      src/views/modules/shequ/cpts/bar-chart.vue
  9. 125
      src/views/modules/shequ/cpts/scroll-notice.vue
  10. 897
      src/views/modules/shequ/index.vue
  11. 12
      src/views/modules/systemManagement/serviceMatter/service.vue
  12. 12
      src/views/modules/systemManagement/serviceMatter/serviceForm.vue
  13. 68
      src/views/modules/warning/components/screen-loading/index.vue
  14. 392
      src/views/modules/warning/components/screen-table/index.vue
  15. 200
      src/views/modules/warning/index.vue
  16. 14
      src/views/modules/workPc/guidance/categoryList.vue
  17. 10
      src/views/modules/workSys/demandCate.vue
  18. 15
      src/views/modules/workSys/elegantCate.vue
  19. 11
      src/views/modules/workSys/elegantEdit.vue
  20. 7
      src/views/modules/workSys/resiCate.vue

2
src/assets/scss/buttonstyle.scss

@ -86,7 +86,7 @@
//查看
.div-table-button--detail {
color: #1c6afd !important;
color: #3E8EF7 !important;
text-decoration: underline !important;
}

62
src/assets/scss/modules/search.scss

@ -199,13 +199,48 @@
background-color: #fff;
border-radius: 10px;
padding: 30px 40px;
.headline {
.header {
display: flex;
justify-content: space-between;
align-items: center;
margin-bottom: 20px;
font-size: 24px;
font-family: PingFang SC;
font-weight: bold;
color: #333333;
.headline {
font-size: 24px;
font-family: PingFang SC;
font-weight: bold;
color: #333333;
}
.notice {
width: 85%;
line-height: 24px;
display: flex;
justify-content: space-between;
align-items: center;
.notice-btn {
width: 50px;
background-color: #3e8ef7;
color: #fff;
text-align: center;
border-radius: 4px;
cursor: pointer;
}
.notice-list {
// @include toe;
width: 92%;
// height: 24px;
// overflow: hidden;
a {
margin-right: 20px;
cursor: pointer;
color: #999;
&:hover {
color: #3e8ef7;
}
}
}
}
}
.cnt {
@ -219,3 +254,18 @@
}
}
}
.m-crumbs {
padding: 10px 30px 0;
font-size: 16px;
a {
color: #666;
&:hover {
color: #094bea;
}
cursor: pointer;
}
span {
color: #094bea;
}
}

147
src/assets/scss/modules/warning.scss

@ -0,0 +1,147 @@
.warning-box {
box-sizing: border-box;
// width: 1881px;
width: 100%;
// height: 100%;
min-height: 100%;
margin: 0 auto;
color: #999;
// background: url("../../../img/modules/visual/warning-box.png") no-repeat center;
background-size: 100% 100%;
padding: 25px 21px 35px 24px;
&-top {
display: flex;
// justify-content: space-around;
justify-content: flex-start;
flex-wrap: wrap;
min-height: 190px;
.top-item {
box-sizing: border-box;
width: 280px;
height: 190px;
padding: 10px 22px 14px 21px;
border-radius: 8px;
margin-right: 15px;
margin-bottom: 15px;
background-color: #fff;
&-img {
display: flex;
align-items: center;
img {
width: 78px;
height: 78px;
margin-right: 16px;
margin-bottom: 10px;
}
.top-item-left {
display: flex;
flex-direction: column;
span {
display: inline-block;
}
span:nth-child(1) {
font-size: 18px;
font-weight: 400;
color: #333333;
}
span:nth-child(2) {
font-size: 28px;
font-weight: bold;
color: #2194fe;
margin-top: 10px;
}
}
}
&-num {
width: 100%;
display: flex;
position: relative;
flex-direction: column;
align-items: space-between;
// border: 1px solid red;
.num-item {
position: relative;
width: 100%;
height: 35px;
display: flex;
border-radius: 4px;
align-items: center;
justify-content: space-between;
padding: 0 10px 0 29px;
cursor: pointer;
&::after {
display: block;
content: "";
width: 8px;
height: 8px;
background: #2194fe;
border-radius: 50%;
position: absolute;
left: 12px;
top: 50%;
transform: translate(0, -50%);
}
div:nth-child(1) {
font-size: 16px;
font-family: PingFang SC;
font-weight: 400;
color: #333333;
}
div:nth-child(2) {
// width: 70%;
display: flex;
font-size: 20px;
font-family: PingFang SC;
font-weight: 500;
color: #333;
.right-icon {
width: 10px;
height: 14px;
}
}
}
.num-item-active {
background-color: #f0f3f7;
}
.num-item:nth-child(2) {
margin-top: 10px;
}
}
}
}
&-bottom {
box-sizing: border-box;
width: 100%;
height: calc(100% - 300px);
padding: 35px 40px;
min-height: 300px;
margin-top: 30px;
background-color: #fff;
.pagination {
box-sizing: border-box;
margin-top: 20px;
width: 100%;
height: 40px;
display: flex;
justify-content: flex-end;
}
}
}

2
src/views/components/resiSearch.vue

@ -189,7 +189,7 @@
<el-button type="primary" size="mini">查询</el-button>
</el-col> -->
<el-col :span="24">
<el-button type="primary" size="mini" @click="handleSearch">查询</el-button>
<el-button type="primary" size="small" @click="handleSearch">查询</el-button>
</el-col>
</el-row>
<div class="resi-down" @click="handleOpenSearch">

88
src/views/modules/base/resi.vue

@ -7,14 +7,10 @@
@search="handleSearch" />
<el-card class="resi-card-table">
<div class="resi-row-btn">
<el-button type="success"
<el-button
size="small"
class="diy-button--add"
@click="handleAdd">新增</el-button>
<el-button type="warning"
size="small"
:loading="exportBtn"
@click="handleExport">{{exportBtnTitle}}</el-button>
<!-- <el-button type="primary" size="small">下载人口模板</el-button> -->
<el-upload ref="upload"
class="upload-demo"
action="uploadUlr"
@ -26,10 +22,22 @@
:on-success="handleExcelSuccess"
:before-upload="beforeExcelUpload"
:http-request="uploadHttpRequest">
<el-button type="danger"
<el-button
size="small"
class="diy-button--delete"
:loading="importLoading">{{importBtnTitle}}</el-button>
</el-upload>
<el-button
size="small"
class="diy-button--reset"
:loading="exportBtn"
@click="handleExport">{{exportBtnTitle}}</el-button>
<!-- <el-button type="primary" size="small">下载人口模板</el-button> -->
<el-button
class="diy-button--export"
size="small"
@click="handleExportModule('room')">下载人口模板</el-button>
</div>
<el-table ref="ref_table" :data="tableData"
@ -77,16 +85,18 @@
<el-button @click="handleTransfer(scope.row)"
type="text"
size="small"
class="btn-color-look">调动</el-button>
class="div-table-button--detail"
>调动</el-button>
<el-button @click="handleChangeRecord(scope.row)"
type="text"
size="small"
class="btn-color-look">变更记录</el-button>
class="div-table-button--detail"
>变更记录</el-button>
<template v-if="filterEdit(scope.row.ORG_ID)">
<el-button @click="handleEdit(scope.row)"
type="text"
size="small"
class="btn-color-edit">编辑</el-button>
class="div-table-button--edit">编辑</el-button>
<el-popconfirm title="删除之后无法回复,确认删除?"
@onConfirm="handleDel(scope.row)">
<!-- <el-button slot="reference"
@ -102,7 +112,7 @@
<div class="div_del">
<el-checkbox :indeterminate="isIndeterminate"
v-model="selAllFlag"
:disabled="tableData.length==0"
:disabled="selAllFlagDisabled"
@change="handleSelectAll">全选</el-checkbox>
<el-button v-if="selection.length > 0" style="margin-left:15px"
type="danger"
@ -277,6 +287,7 @@ export default {
disabled: false,
pageLoading: false,
selAllFlag: false,
selAllFlagDisabled: false,
isIndeterminate: false,
dialogEditVisible: false,
dialogVisible: false,
@ -473,6 +484,36 @@ export default {
this.conditions = val
this.getTableData()
},
async handleExportModule () {
let url = "/epmetuser/icresiuser/import/download-template"
let params = {}
await this.$http
.post(url, params)
.then(res => {
console.log('res----dddd', res)
// this.download(res.data, title + '.xls')
if (res.headers["content-disposition"]) {
let fileName = window.decodeURI(res.headers["content-disposition"].split(";")[1].split("=")[1])
console.log('filename', fileName)
let blob = new Blob([res.data], { type: 'application/vnd.ms-excel' })
var url = window.URL.createObjectURL(blob)
var aLink = document.createElement('a')
aLink.style.display = 'none'
aLink.href = url
aLink.setAttribute('download', fileName)
document.body.appendChild(aLink)
aLink.click()
document.body.removeChild(aLink) //
window.URL.revokeObjectURL(url) //blob
} else this.$message.error('下载失败')
})
.catch(err => {
console.log('err', err)
return this.$message.error('网络错误')
})
},
//
download (data, fileName) {
console.log('data', data)
@ -859,6 +900,11 @@ export default {
isChecked: this.filterEdit(item.ORG_ID)
}
})
let _selAllFlagDisabled = true
this.tableData.forEach(item => {
if (item.isChecked) _selAllFlagDisabled = false
})
this.selAllFlagDisabled = _selAllFlagDisabled
this.total = res.data.total
}
})
@ -970,7 +1016,7 @@ export default {
if (res.code !== 0) {
return this.$message.error(res.msg)
} else {
// console.log('', res.data)
console.log('获取查询详情成功--sss', res)
this.searchList = res.data
res.data.forEach((item) => {
if (item.optionSourceType === 'remote') {
@ -1135,15 +1181,15 @@ export default {
margin-left: 10px;
border: 0;
}
.el-button--success {
background: rgba(34, 193, 195, 1);
}
.el-button--warning {
background: rgba(254, 179, 73, 1);
}
.el-button--danger {
background: rgba(254, 98, 82, 1);
}
// .el-button--success {
// background: rgba(34, 193, 195, 1);
// }
// .el-button--warning {
// background: rgba(254, 179, 73, 1);
// }
// .el-button--danger {
// background: rgba(254, 98, 82, 1);
// }
}
.resi-other {
width: 100%;

43
src/views/modules/communityParty/elegant/index.vue

@ -38,8 +38,8 @@
<el-input v-model="searchForm.mainDeed" placeholder="请输入" class="input-width" clearable></el-input>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="handleSearch">查询</el-button>
<el-button type="yellow" @click="resetForm('searchForm')">重置</el-button>
<el-button class="diy-button--search" size="small" @click="handleSearch">查询</el-button>
<el-button class="diy-button--reset" size="small" @click="resetForm('searchForm')">重置</el-button>
</el-form-item>
</el-form>
</div>
@ -47,8 +47,7 @@
<el-card class="resi-card-table">
<div class="resi-row-btn">
<el-button type="success" @click="handleAdd">新增</el-button>
<el-button type="warning" size="small" :loading="exportBtn" @click="handleExport">{{ exportBtnTitle }}</el-button>
<el-button class="diy-button--add" size="small" @click="handleAdd">新增</el-button>
<el-upload
ref="upload"
class="upload-demo"
@ -61,8 +60,13 @@
:before-upload="beforeExcelUpload"
:http-request="uploadHttpRequest"
>
<el-button type="danger" :loading="importLoading">{{importBtnTitle}}</el-button>
<el-button size="small" class="diy-button--delete" :loading="importLoading">{{importBtnTitle}}</el-button>
</el-upload>
<el-button class="diy-button--reset" size="small" :loading="exportBtn" @click="handleExport">{{ exportBtnTitle }}</el-button>
<!-- <el-button
class="diy-button--export"
size="small"
@click="handleExportModule('room')">下载模板</el-button> -->
</div>
<el-table
@ -376,6 +380,35 @@ export default {
this.uploading = true
this.unloadPencent = Number(file.percentage.toFixed(0))
},
async handleExportModule () {
let url = "/resi/partymember/import/template-download"
let params = {}
await this.$http
.post(url, params)
.then(res => {
// this.download(res.data, title + '.xls')
if (res.headers["content-disposition"]) {
let fileName = window.decodeURI(res.headers["content-disposition"].split(";")[1].split("=")[1])
console.log('filename', fileName)
let blob = new Blob([res.data], { type: 'application/vnd.ms-excel' })
var url = window.URL.createObjectURL(blob)
var aLink = document.createElement('a')
aLink.style.display = 'none'
aLink.href = url
aLink.setAttribute('download', fileName)
document.body.appendChild(aLink)
aLink.click()
document.body.removeChild(aLink) //
window.URL.revokeObjectURL(url) //blob
} else this.$message.error('下载失败')
})
.catch(err => {
console.log('err', err)
return this.$message.error('网络错误')
})
},
beforeExcelUpload (file) {
console.log('file', file)
const isType = file.type === 'application/vnd.ms-excel'

22
src/views/modules/communityService/sqzzz/index.vue

@ -24,15 +24,15 @@
</el-date-picker>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="handleSearch">查询</el-button>
<el-button type="yellow" @click="resetForm('searchForm')">重置</el-button>
<el-button class="diy-button--search" size="small" @click="handleSearch">查询</el-button>
<el-button class="diy-button--reset" size="small" @click="resetForm('searchForm')">重置</el-button>
</el-form-item>
</el-form>
</el-card>
<el-card class="resi-card-table">
<div class="resi-row-btn">
<el-button type="success" size="small" @click="handleAdd"
<el-button class="diy-button--add" size="small" @click="handleAdd"
>新增</el-button
>
<el-upload
@ -48,12 +48,12 @@
:before-upload="beforeExcelUpload"
:http-request="uploadHttpRequest"
>
<el-button type="warning" size="small" :loading="importLoading">{{
<el-button size="small" class="diy-button--delete" :loading="importLoading">{{
importBtnTitle
}}</el-button>
</el-upload>
<el-button @click="handleChu" type="danger" size="small"
<el-button @click="handleChu" class="diy-button--reset" size="small"
>excel导出</el-button
>
</div>
@ -92,7 +92,7 @@
> -->
<el-button
type="text"
style="color: #1c6afd"
class="div-table-button--detail"
size="small"
@click="handleScore(scope.row)"
>积分记录</el-button
@ -102,7 +102,7 @@
@click="handleEdit(scope.$index)"
type="text"
size="small"
style="margin-right: 10px; color: #00a7a9"
class="div-table-button--edit"
>编辑</el-button
>
@ -115,7 +115,8 @@
slot="reference"
type="text"
size="small"
style="color: #d51010"
class="div-table-button--delete"
style="margin-left: 10px;"
>删除</el-button
>
</el-popconfirm>
@ -457,6 +458,11 @@ export default {
// border-right: 1px solid rgba(33, 149, 254, 1);
}
}
.resi-table {
::v-deep .el-button--text {
text-decoration: underline;
}
}
.resi-card-table {
margin-top: 20px;
}

200
src/views/modules/shequ/cpts/bar-chart.vue

@ -0,0 +1,200 @@
<template>
<div class="m-chart">
<canvas id="myChart" :width="width" :height="height" />
</div>
</template>
<script>
import nextTick from "dai-js/tools/nextTick";
import F2 from "@antv/f2/lib/index-all";
// iosbug
const fontFamily = "PingFang SC";
const fontSize = 14;
let chart;
let srcData = [];
const iniChart = function (config, srcData, total, that) {
chart = new F2.Chart({
id: "myChart",
...config,
});
let data = [
{
const: "const",
name: "--",
count: 51.39,
},
{
const: "const",
name: "--",
count: 356.68,
},
{
const: "const",
name: "--",
count: 20.0,
},
{
const: "const",
name: "--",
count: 116.53,
},
];
console.log("-----------------------------------", srcData);
data = srcData;
chart.source(data);
// chart.axis(false);
chart.legend(false);
// chart.legend({
// position: "bottom",
// align: "center",
// });
chart.tooltip(false);
chart
.interval()
.position("name*count")
.color("name", [
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
"#3e8ef7",
]);
chart.render();
//
const offset = -5;
const canvas = chart.get("canvas");
const group = canvas.addGroup();
const shapes = {};
data.forEach(function (obj) {
const point = chart.getPosition(obj);
const text = group.addShape("text", {
attrs: {
x: point.x,
y: point.y + offset,
text: obj.count + '人',
textAlign: "center",
textBaseline: "bottom",
fill: "#808080",
},
});
shapes[obj.name] = text; // shape, 便
});
//
chart.interaction("interval-select", {
selectAxisStyle: {
fill: "#000",
fontWeight: "bold",
},
mode: "range", // range
// defaultSelected: {
// year: '1962 ',
// sales: 38
// },
onStart(ev) {
console.log(ev);
const data = ev.data,
selected = ev.selected;
if (data && selected) {
that.handleClickBar(data.name);
} else {
that.handleClickBar();
}
},
onEnd(ev) {
console.log("-------------------", ev);
},
});
// chart return
return chart;
};
export default {
name: "chart",
props: {
list: {
type: Array,
default: () => {
return [];
},
},
total: {
type: Number,
default: 0,
},
config: {
type: Object,
default: () => {
return {};
},
},
width: {
type: Number,
default: 400,
},
height: {
type: Number,
default: 260,
},
},
data() {
return {
iniLoading: false,
};
},
watch: {
list(data) {
// chart.changeData(data);
srcData = data;
},
},
async created() {
await nextTick(200);
iniChart(this.config, this.list, this.total, this);
await nextTick(200);
this.iniLoading = true;
},
methods: {
setList(data) {
chart.changeData(data);
srcData = data;
},
handleClickBar(name) {
let code = "";
if (name) {
let item = this.list.find((item) => item.name == name);
console.log(item);
code = item && item.code;
}
console.log(code);
this.$emit("clickBar", { code });
},
},
};
</script>
<style lang="scss" scoped></style>

125
src/views/modules/shequ/cpts/scroll-notice.vue

@ -0,0 +1,125 @@
<template>
<div class="m-scoll-notice">
<div class="wrapper">
<div class="bar" ref="barparent">
<div class="bartext" ref="barchild" :style="bartextStyle">
<!-- <li
v-for="(item, index) in list"
:key="item.configId + item.buildingId + index"
@click="toNoticeInfo(item)"
>
{{ item.noticeContent }}
</li> -->
<slot></slot>
</div>
</div>
</div>
</div>
</template>
<script>
import { requestPost } from "@/js/dai/request";
export default {
props: {
list: {
type: Array,
default: [],
},
},
data() {
return {
parentClientWidth: 100000,
beyond: false,
};
},
components: {},
computed: {
bartextStyle() {
let len = this.list.length;
let beyond = this.beyond;
return {
paddingLeft: beyond ? this.parentClientWidth + "px" : "",
animation: beyond
? `move_left_right ${len * 5}s linear 0s infinite`
: "",
};
},
},
mounted() {
this.move();
},
methods: {
move() {
const parentClientWidth = this.$refs.barparent.clientWidth;
this.parentClientWidth = parentClientWidth;
//
const parent = this.$refs.barparent;
const child = this.$refs.barchild;
console.log("对比", child.clientWidth, parent.clientWidth);
this.beyond = child.clientWidth > parent.clientWidth;
},
handleCancle() {
this.$emit("dialogCancle");
this.resetData();
},
resetData() {
this.dataForm = {
neighborHoodId: "", // ID
buildingId: "", //ID
buildingUnitId: "", //ID
doorName: "", //
houseType: "1", //
purpose: "1", //
rentFlag: 1, //10
ownerPhone: "", //
ownerName: "", //
ownerIdCard: "", //
};
},
},
};
</script>
<style lang="scss">
.m-scoll-notice {
.wrapper {
// padding: 0 15px;
display: flex;
align-items: center;
// background-color: "#FFF6EC";
}
.bar {
width: 100%;
// height: 32px;
// line-height: 32px;
overflow: hidden;
box-sizing: border-box;
}
.bartext {
white-space: nowrap;
display: inline-block;
}
.bartext li {
white-space: nowrap;
display: inline-block;
color: red;
font-size: 14px;
}
.state-text-overflow {
animation: move_left_right 120s linear 0s infinite;
}
@keyframes move_left_right {
from {
transform: translateX(0%);
}
to {
transform: translateX(-80%);
}
}
}
</style>

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

File diff suppressed because it is too large

12
src/views/modules/systemManagement/serviceMatter/service.vue

@ -3,9 +3,7 @@
<div class="div_table">
<div class="div_btn">
<el-button style=""
type="green"
size="small"
<el-button class="diy-button--add" size="small"
@click="handleAdd">新增</el-button>
</div>
@ -47,17 +45,17 @@
<template slot-scope="scope">
<el-button v-if="scope.row.usableFlag"
type="text"
style="color:#D51010;text-decoration: underline;"
class="div-table-button--delete"
size="small"
@click="handleDisable(scope.row,'disable')">禁用</el-button>
<el-button v-if="!scope.row.usableFlag"
type="text"
style="color:#D51010;text-decoration: underline;"
class="div-table-button--detail"
size="small"
@click="handleDisable(scope.row,'able')">启用</el-button>
<el-button type="text"
style="color:#00A7A9;text-decoration: underline;"
class="div-table-button--edit"
size="small"
@click="handleEdit(scope.row)">修改</el-button>
@ -72,7 +70,7 @@
:close-on-click-modal="false"
:close-on-press-escape="false"
:title="formTitle"
width="950px"
width="50%"
top="5vh"
@closed="diaClose">
<service-form ref="ref_form"

12
src/views/modules/systemManagement/serviceMatter/serviceForm.vue

@ -35,13 +35,21 @@
</div>
</div>
<div class="div_btn">
<!-- <div class="div_btn">
<el-button @click="handleCancle"> </el-button>
<el-button v-if="formType != 'detail'"
type="primary"
:disabled="btnDisable"
@click="handleComfirm"> </el-button>
</div>
</div> -->
<div class="resi-btns">
<el-button size="small"
@click="handleCancle"> </el-button>
<el-button v-if="formType != 'detail'" type="primary"
size="small"
:disabled="btnDisable"
@click="handleComfirm"> </el-button>
</div>
</div>
</template>

68
src/views/modules/warning/components/screen-loading/index.vue

@ -0,0 +1,68 @@
<template>
<div class="screen-loading">
<svg width="50px"
height="50px">
<circle cx="25"
cy="25"
r="20"
fill="transparent"
stroke-width="3"
stroke-dasharray="31.415, 31.415"
stroke="#29cdff"
stroke-linecap="round">
<animateTransform attributeName="transform"
type="rotate"
values="0, 25 25;360, 25 25"
dur="1.5s"
repeatCount="indefinite" />
<animate attributeName="stroke"
values="#02bcfe;#3be6cb;#02bcfe"
dur="3s"
repeatCount="indefinite" />
</circle>
<circle cx="25"
cy="25"
r="10"
fill="transparent"
stroke-width="3"
stroke-dasharray="15.7, 15.7"
stroke="#29cdff"
stroke-linecap="round">
<animateTransform attributeName="transform"
type="rotate"
values="360, 25 25;0, 25 25"
dur="1.5s"
repeatCount="indefinite" />
<animate attributeName="stroke"
values="#3be6cb;#02bcfe;#3be6cb"
dur="3s"
repeatCount="indefinite" />
</circle>
</svg>
<div class="loading-tip">
<slot></slot>
</div>
</div>
</template>
<script>
export default {
name: 'DvLoading'
}
</script>
<style lang="scss" scoped>
.screen-loading {
width: 100%;
height: 100%;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
.loading-tip {
font-size: 14px;
color: #fff;
}
}
</style>

392
src/views/modules/warning/components/screen-table/index.vue

@ -0,0 +1,392 @@
<template>
<div>
<div class="warning-table">
<div class="table">
<div class="table-header">
<div
class="table-header-th"
v-for="(item, index) in headerList"
:key="item.title"
:style="headerStyle[index]"
>
{{ item.title }}
</div>
</div>
<div class="table-body">
<div
class="table-body-tr"
v-for="(value, index) in tableData"
:key="index"
>
<div
class="td"
v-for="(item, indexs) in value"
:key="indexs"
:style="tableContentStyle[indexs]"
>
<div v-if="Array.isArray(item)">
<span
v-show="rIndex < 3"
:key="resi.userId"
v-for="(resi, rIndex) in item"
>
{{ rIndex != 0 ? "、" : "" }}
<a @click="handlePeopleItem(resi.userId, value[1])">{{
resi.residentName
}}</a>
</span>
</div>
<span v-else>{{ item }}</span>
<span
v-if="indexs + 1 == value.length && item.length > 3"
class="more"
@click.stop="onClickMorePop(index)"
ref="morePop"
>
更多>
<div class="more-pop" v-if="visiblePopList[index]">
<span
:key="index + rIndex + resi.userId"
v-for="(resi, rIndex) in item"
>
{{ rIndex != 0 ? "、" : "" }}
<a @click="handlePeopleItem(resi.userId, value[1])">{{
resi.residentName
}}</a>
</span>
</div>
</span>
</div>
</div>
<screen-loading v-if="visibleLoading">加载中</screen-loading>
<div class="no-data" v-if="tableData.length == 0 && !visibleLoading">
<img
src="@/assets/img/modules/visual/noData.png"
class="no-data-img"
/>
</div>
</div>
</div>
</div>
<people-more
v-if="showedPeopleMoreInfo && currentPepeleId"
:userId="currentPepeleId"
:gridName="currentPepeleGridName"
@close="showedPeopleMoreInfo = false"
/>
</div>
</template>
<script>
import ScreenLoading from "../screen-loading/index";
import Vue from "vue";
import peopleMore from "@/views/modules/shequ/cpts/people-more";
export default {
name: "warning-table",
components: {
ScreenLoading,
peopleMore,
},
props: {
headerList: {
type: Array,
required: false,
default: () => {
return [
{ title: "序号" },
{ title: "所属网格" },
{ title: "所属小区" },
{ title: "楼号" },
{ title: "姓名" },
];
},
},
tableData: {
type: Array,
required: false,
default: () => {
return [
// [
// 1,
// "",
// "",
// "2",
// "",
// ],
// [
// 2,
// "",
// "",
// "2",
// "",
// ],
];
},
},
//
headerStyle: {
type: Array,
default: () => {
return [
// {
// width:'200px',
// border:'1px solid red'
// },
// {
// width:'200px'
// }
];
},
},
//
tableContentStyle: {
type: Array,
default: () => {
return [
// {
// width:'200px',
// border:'1px solid red'
// },
// {
// width:'200px'
// }
];
},
},
visibleLoading: {
type: Boolean,
default: true,
},
// //
// ava: {
// type: Number,
// default: 8
// },
// // --10%
// headerHeightAva: {
// type: String,
// default: '10%'
// },
// //
// tableContentAva: {
// type: Number,
// default: 5
// },
},
data() {
return {
//
showedPeopleMoreInfo: false,
currentPepeleId: "",
currentPepeleGridName: "",
visiblePopList: [
false,
false,
false,
false,
false,
false,
false,
false,
false,
false,
],
};
},
watch: {
tableData(arr) {
if (Array.isArray(arr)) {
this.visiblePopList = new Array(arr.length).fill(false);
}
},
},
mounted() {
window.addEventListener("click", (e) => {
this.visiblePopList = new Array(this.visiblePopList.length).fill(false);
});
},
created() {},
methods: {
toUserInfo(uid) {
this.$router.push({ path: `/main-shuju/visual-basicinfo-people/${uid}` });
},
handlePeopleItem(uid, gridName) {
this.currentPepeleId = uid;
this.currentPepeleGridName = gridName;
this.showedPeopleMoreInfo = true;
},
onClickMorePop(index) {
this.visiblePopList.forEach((item, indexs) => {
if (index == indexs) {
Vue.set(this.visiblePopList, index, true);
} else {
Vue.set(this.visiblePopList, indexs, false);
}
});
},
},
};
</script>
<style lang="scss" scoped>
.warning-table {
box-sizing: border-box;
width: 100%;
height: 100%;
.table {
width: 100%;
height: 100%;
border: 1px solid #dfdfdd;
&-header {
width: 100%;
height: 50px;
display: flex;
justify-content: space-around;
align-items: center;
background: #2194fe;
font-size: 16px;
font-weight: 400;
color: #ffffff;
&-th {
text-align: center;
width: 20%;
&:nth-child(1) {
width: 5%;
}
&:nth-child(2) {
width: 25%;
}
&:nth-child(3) {
width: 25%;
}
&:nth-child(5) {
width: 25%;
}
}
}
&-body {
box-sizing: border-box;
width: 100%;
height: calc(100% - 50px);
font-size: 16px;
font-weight: 400;
color: #333;
&-tr {
width: 100%;
height: 50px;
display: flex;
justify-content: space-around;
align-items: center;
border-bottom: 1px dashed #dfdfdd;
.td {
text-align: center;
width: 20%;
border-left: 1px dashed #dfdfdd;
height: 50px;
display: flex;
align-items: center;
justify-content: space-around;
&:nth-child(1) {
width: 5%;
border-left: 0;
}
&:nth-child(2) {
width: 25%;
}
&:nth-child(3) {
width: 25%;
}
&:nth-child(5) {
width: 25%;
}
a {
cursor: pointer;
}
.more {
font-size: 16px;
font-weight: 400;
color: #e4dc00;
position: relative;
cursor: pointer;
&-pop {
box-sizing: border-box;
display: block;
box-sizing: border-box;
width: 215px;
height: auto;
line-height: 20px;
border: 1px solid red;
position: absolute;
right: -100%;
top: 150%;
background: #fff;
box-shadow: 0 0 10px 0 #2194fe;
border: 1px solid #42a4fe;
border-radius: 5px;
font-size: 9px;
font-weight: 400;
color: #333;
padding: 16px 8px 10px 9px;
z-index: 1;
cursor: default;
// &::after{
// position: absolute;
// left: 30%;
// top: -30%;
// display: flex;
// content:'';
// width: 0;
// height: 0;
// border-width: 13px;
// border-style: solid;
// border-color: transparent transparent rgba(26, 100, 204,0.5) transparent;
// // border-color: transparent transparent red transparent;
// transform: translate(-50%,0);
// }
}
}
}
&:last-child {
border-bottom: none;
}
}
&-tr:nth-child(2n) {
}
&-tr:hover {
background: rgba(16, 75, 164, 0.1);
}
//
.no-data {
width: 100%;
height: calc(100% - 50px);
display: flex;
align-items: center;
justify-content: center;
&-img {
width: 249px;
height: 172px;
}
}
}
}
}
</style>

200
src/views/modules/warning/index.vue

@ -0,0 +1,200 @@
<template>
<div class="warning-box">
<div class="warning-box-top">
<div class="top-item" v-for="(item, index) in warningList" :key="index">
<div class="top-item-img">
<img :src="item.managementIcon" />
<div class="top-item-left">
<span>{{ item.label }}</span>
<span>{{ item.count }}</span>
</div>
</div>
<div class="top-item-num">
<div
class="num-item"
:class="{
'num-item-active': activeIndex == index && activeLevel == '1',
}"
@click="onClickList(index, '1')"
>
<div>{{ item.level1 }}-{{ item.level2 }}</div>
<div>
<div>{{ item.levelCount1 }}</div>
<img
src="../../../assets/img/modules/visual/right-icon.png"
class="right-icon"
/>
</div>
</div>
<div
class="num-item"
:class="{
'num-item-active': activeIndex == index && activeLevel == '2',
}"
@click="onClickList(index, '2')"
>
<div>{{ item.level2 }}人以上</div>
<div>
<div>{{ item.levelCount2 }}</div>
<img
src="../../../assets/img/modules/visual/right-icon.png"
class="right-icon"
/>
</div>
</div>
</div>
</div>
</div>
<div class="warning-box-bottom">
<screen-table
:headerList="headerList"
:tableData="tableData"
:visibleLoading="visibleLoading"
></screen-table>
<div class="pagination">
<el-pagination
:current-page="pageNo"
:page-size="pageSize"
background
layout="prev, pager, next"
@size-change="pageSizeChangeHandleNew"
@current-change="pageCurrentChangeHandleNew"
:total="total"
>
</el-pagination>
</div>
</div>
</div>
</template>
<script>
import { requestPost } from "@/js/dai/request";
import screenTable from "./components/screen-table/index";
import cptCard from "@/views/modules/visual/cpts/card";
import nextTick from "dai-js/tools/nextTick";
export default {
name: "warning-box",
components: {
cptCard,
screenTable,
},
props: {
buildingId: {
type: String,
default: "",
},
configId: {
type: String,
default: "",
},
},
data() {
return {
warningList: [],
headerList: [
{ title: "序号" },
{ title: "所属网格" },
{ title: "所属小区" },
{ title: "楼号" },
{ title: "姓名" },
],
tableData: [
// [1,'','','2',''],
],
visibleLoading: true,
pageNo: 1,
pageSize: 10,
total: 0,
activeIndex: 0,
activeLevel: "1",
};
},
async mounted() {
await nextTick(100);
this.getBuildingwarnlist();
},
methods: {
onClickList(index, level) {
this.activeIndex = index;
this.activeLevel = level;
this.pageNo = 1;
this.getUserwarnlist();
},
//
async getUserwarnlist() {
const { activeIndex, activeLevel, warningList } = this;
const reqItem = warningList[activeIndex];
let tableData = [];
const url = "/epmetuser/statsresiwarn/userwarnlist";
let params = {
configId: reqItem.configId,
buildingIdList: reqItem["buildingIdList" + activeLevel],
pageNo: this.pageNo,
pageSize: this.pageSize,
};
const { data, code, msg } = await requestPost(url, params);
if (code === 0) {
data.list.forEach((item, index) => {
tableData.push([
index + 1,
item.gridName,
item.neighborhoodName,
item.buildingName,
item.userList || "暂无",
]);
});
this.tableData = tableData;
this.total = data.total;
} else {
}
},
//
async getBuildingwarnlist() {
const url = "/epmetuser/statsresiwarn/buildingwarnlist";
let params = {
agencyId: this.$store.state.user.agencyId,
};
const { data, code, msg } = await requestPost(url, params);
if (code === 0) {
this.warningList = data;
this.visibleLoading = false;
const { buildingId, configId } = this;
if (configId && buildingId) {
let activeIndex = 0;
let activeLevel = 1;
data.forEach((item, index) => {
if (item.configId == configId) {
activeIndex = index;
if (item.buildingIdList1.indexOf(buildingId) !== -1) {
activeLevel = 1;
}
if (item.buildingIdList2.indexOf(buildingId) !== -1) {
activeLevel = 2;
}
if (item.buildingIdList3.indexOf(buildingId) !== -1) {
activeLevel = 3;
}
}
});
this.activeIndex = activeIndex;
this.activeLevel = activeLevel;
}
this.getUserwarnlist();
} else {
}
},
pageSizeChangeHandleNew(val) {
this.pageNo = 1;
this.pageSize = val;
},
pageCurrentChangeHandleNew(val) {
this.pageNo = val;
this.getUserwarnlist();
},
},
};
</script>
<style lang="scss" src="@/assets/scss/modules/warning.scss" scoped></style>

14
src/views/modules/workPc/guidance/categoryList.vue

@ -49,21 +49,23 @@
<el-button v-if="scope.row.status==='enable'"
type="text"
size="mini"
size="small"
class="div-table-button--detail"
@click="confirmChangeState(scope.row,'disable')">禁用</el-button>
<el-button v-if="scope.row.status==='disable'"
type="text"
size="mini"
size="small"
class="div-table-button--detail"
@click="confirmChangeState(scope.row,'enable')">启用</el-button>
<el-button type="text"
size="mini"
class="btn-color-edit"
size="small"
class="div-table-button--edit"
@click="handleEdit(scope.row)">修改</el-button>
<el-button type="text"
size="mini"
class="btn-color-del"
size="small"
class="div-table-button--delete"
@click="confirmDel(scope.row)">删除</el-button>
</template>
</el-table-column>

10
src/views/modules/workSys/demandCate.vue

@ -14,14 +14,14 @@
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="handleSearch">查询</el-button>
<el-button class="diy-button--search" size="small" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
</div>
</el-card>
<el-card class="resi-card-table">
<div class="resi-row-btn">
<el-button type="success" @click="handleAdd('1', 'add')">新增分类</el-button>
<el-button class="diy-button--add" size="small" @click="handleAdd('1', 'add')">新增分类</el-button>
</div>
<el-table
@ -54,7 +54,7 @@
@click="handleLook(scope.row)"
type="text"
size="small"
class="btn-color-look"
class="div-table-button--detail"
>{{(scope.row.usableFlag&&'禁用') || '启用'}}</el-button
>
<el-button
@ -62,14 +62,14 @@
@click="handleAdd('2', 'add', scope.row)"
type="text"
size="small"
class="btn-color-del"
class="div-table-button--delete"
>添加二级分类</el-button
>
<el-button
@click="handleEdit(scope.row, 'edit')"
type="text"
size="small"
class="btn-color-edit"
class="div-table-button--edit"
>编辑</el-button
>
</template>

15
src/views/modules/workSys/elegantCate.vue

@ -3,24 +3,25 @@
<el-card class="resi-card-table">
<div class="mod-sys__menu">
<div class="resi-row-btn">
<el-button class=""
type="success"
<el-button class="diy-button--add"
size="small"
@click="addShow()">新增</el-button>
</div>
<el-table v-loading="dataListLoading"
:data="dataList"
:default-expand-all="false"
row-key="categoryId"
:cell-style="cellStyle"
:height="tableHeight"
border
style="width: 100%;" class="resi-table">
<el-table-column prop="categoryName"
label="分类名称"
align="center"
header-align="center"
min-width="150"></el-table-column>
<el-table-column prop="stateShow"
label="状态"
align="center"
header-align="center"
min-width="150"></el-table-column>
@ -32,21 +33,21 @@
<el-table-column label="操作"
fixed="right"
header-align="center"
align="left"
align="center"
width="350">
<template slot-scope="scope">
<el-button type="text"
size="small"
class="btn-color-look"
class="div-table-button--detail"
@click="disableCategory(scope.row)">{{ scope.row.btnShow}}</el-button>
<el-button type="text"
size="small"
class="btn-color-edit"
class="div-table-button--edit"
@click="editShow(scope.row)">修改</el-button>
<el-button type="text"
size="small"
class="btn-color-del"
class="div-table-button--delete"
@click="deleteCategory(scope.row)">删除</el-button>
</template>
</el-table-column>

11
src/views/modules/workSys/elegantEdit.vue

@ -34,11 +34,18 @@
</div>
</el-form>
<template slot="footer">
<!-- <template slot="footer">
<el-button @click="visible = false;resetData()">{{ $t('cancel') }}</el-button>
<el-button type="primary"
@click="saveForm()">{{ $t('confirm') }}</el-button>
</template>
</template> -->
<div class="resi-btns">
<el-button size="small"
@click="visible = false;resetData()">取消</el-button>
<el-button type="primary"
size="small"
@click="saveForm">提交</el-button>
</div>
</el-dialog>
</template>

7
src/views/modules/workSys/resiCate.vue

@ -36,7 +36,7 @@
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="handleSearch">查询</el-button>
<el-button class="diy-button--search" size="small" @click="handleSearch">查询</el-button>
</el-form-item>
</el-form>
</div>
@ -77,14 +77,14 @@
@click="handleLook(scope.row)"
type="text"
size="small"
class="btn-color-look"
class="div-table-button--detail"
>{{(scope.row.status === 'show'&&'隐藏') || '显示'}}</el-button
>
<el-button
@click="handleEdit(scope.row)"
type="text"
size="small"
class="btn-color-edit"
class="div-table-button--edit"
>编辑</el-button
>
</template>
@ -108,6 +108,7 @@
title="居民类别配置"
:visible.sync="dialogVisible"
width="50%"
top="5vh"
append-to-body
class="dialog-h"
:close-on-click-modal="false"

Loading…
Cancel
Save