f79f1525 by 任超
2 parents 0a11bd7f 90e3f601
......@@ -3,10 +3,10 @@
</template>
<script>
import Chart from "./Chart";
import work from "@/api/work";
export default {
data() {
import Chart from "./Chart";
import work from "@/api/work";
export default {
data () {
return {
cdata: {
category: [],
......@@ -18,14 +18,14 @@ export default {
components: {
Chart,
},
mounted() {
mounted () {
window.addEventListener("resize", () => {
this.submitViews();
});
this.submitViews();
},
methods: {
async submitViews() {
async submitViews () {
try {
let { result: res } = await work.submitViews("A20");
this.cdata.category = [];
......@@ -43,7 +43,7 @@ export default {
}
},
},
};
};
</script>
<style lang="scss" scoped></style>
......
......@@ -7,15 +7,14 @@
ref="centreLeft2ChartRef"
width="100%"
height="100%"
:options="options"
></Echart>
:options="options"></Echart>
</template>
<script>
import Echart from "@/common/echart";
import { mapGetters } from "vuex";
export default {
data() {
import Echart from "@/common/echart";
import { mapGetters } from "vuex";
export default {
data () {
return {
options: {},
max: "100", //最大value值
......@@ -27,14 +26,14 @@ export default {
components: {
Echart,
},
created() {},
created () { },
props: {
cdata: {
type: Array,
default: () => [],
},
},
mounted() {
mounted () {
window.addEventListener("resize", () => {
this.key++;
......@@ -43,7 +42,7 @@ export default {
},
watch: {
cdata: {
handler(newData) {
handler (newData) {
let _this = this;
// 设置点的位置(经纬度)
const geoCoordMap = {
......@@ -73,8 +72,7 @@ export default {
},
// 如果需要自定义 tooltip样式,需要使用formatter
formatter: (params) => {
return `<div style="">${params.name}:${
params.value + "个"
return `<div style="">${params.name}:${params.value + "个"
}</div>`;
},
},
......@@ -164,24 +162,23 @@ export default {
},
computed: {
...mapGetters(["sidebar", "dicData"]),
logoName() {
logoName () {
return (
this.dicData["sysCode"] &&
this.dicData["sysCode"].filter((item) => item.DCODE == "areaMap")
this.dicData["sysCode"].filter((item) => { return item.DCODE == "areaMap" })
);
},
},
methods: {
// 根据行政区代码匹配行政区
getDistrictcode() {
console.log("this.logoName.DNAME", this.logoName.DNAME);
if ((this.logoName.DNAME = "map610700")) {
this.mapjson = "hanzhong";
getDistrictcode () {
this.mapjson = ""
if (this.logoName[0].DNAME) {
this.mapjson = this.logoName[0].DNAME;
require(`@/common/map/${this.mapjson}.js`);
}
},
// 开启定时器
startInterval() {
startInterval () {
const _self = this;
// 应通过接口获取配置时间,暂时写死5s
const time = 2000;
......@@ -193,7 +190,7 @@ export default {
}, time);
},
// 重新随机选中地图区域
reSelectMapRandomArea() {
reSelectMapRandomArea () {
const length = 9;
this.$nextTick(() => {
try {
......@@ -223,7 +220,7 @@ export default {
}
});
},
handleMapRandomSelect() {
handleMapRandomSelect () {
this.$nextTick(() => {
try {
const map = this.$refs.centreLeft2ChartRef.chart;
......@@ -258,6 +255,6 @@ export default {
});
},
},
};
};
</script>
<style></style>
......
......@@ -2,6 +2,7 @@
<div>
<i class="el-icon-s-management icon" :title="title" @click="openDialog" />
<el-dialog
class="configuration"
:key="key"
:title="title"
:inner-dialog="true"
......@@ -9,8 +10,7 @@
width="600px"
:close-on-click-modal="false"
append-to-body
@cancel="cancel"
>
@cancel="cancel">
<vue-json-editor
id="minejson"
v-model="resultInfo"
......@@ -18,15 +18,13 @@
lang="zh"
@json-change="onJsonChange"
@json-save="onJsonSave"
@has-error="onError"
/>
@has-error="onError" />
<el-tooltip
content="全屏缩放"
effect="dark"
placement="bottom"
fullscreen
class="fullScreen"
>
class="fullScreen">
<i class="el-icon-full-screen" @click="enLarge" />
</el-tooltip>
<template slot="footer">
......@@ -34,21 +32,19 @@
<el-button
type="primary"
class="confirmBtn"
@click="onJsonSave"
>保存</el-button>
@click="onJsonSave">保存</el-button>
<el-button
type="primary"
class="cancelBtn"
@click="cancel"
>关闭</el-button>
@click="cancel">关闭</el-button>
</div>
</template>
</el-dialog>
</div>
</template>
<script>
import vueJsonEditor from 'vue-json-editor'
export default {
import vueJsonEditor from 'vue-json-editor'
export default {
components: {
vueJsonEditor
},
......@@ -62,7 +58,7 @@ export default {
default: ''
}
},
data() {
data () {
return {
activeNames: [],
resultInfo: {},
......@@ -75,7 +71,7 @@ export default {
},
watch: {
resultInfos: {
handler: function(val) {
handler: function (val) {
++this.key
this.resultInfo =
this.resultInfos === '' ? {} : JSON.parse(this.resultInfos)
......@@ -86,17 +82,17 @@ export default {
}
},
mounted() {
mounted () {
this.resultInfo =
this.resultInfos === '' ? {} : JSON.parse(this.resultInfos)
},
methods: {
onJsonChange(value) {
onJsonChange (value) {
// 只有在格式正确的时候进入此事件
this.hasJsonFlag = true
},
onJsonSave() {
onJsonSave () {
const value = this.resultInfo
console.log(this.resultInfo, 'resultInfo')
if (this.hasJsonFlag === false) {
......@@ -109,19 +105,19 @@ export default {
return true
}
},
onError(value) {
onError (value) {
this.hasJsonFlag = false
},
openDialog() {
openDialog () {
this.dialogVisible = true
},
cancel() {
cancel () {
console.log(this.tmpResultInfo, 'tmpResultInfo')
this.resultInfo = this.tmpResultInfo
this.dialogVisible = false
},
// 放大
enLarge() {
enLarge () {
const fullarea = document.getElementById('minejson')
if (fullarea.requestFullscreen) {
fullarea.requestFullscreen()
......@@ -135,41 +131,57 @@ export default {
this.isEnlarge = true
}
}
}
}
</script>
<style scoped lang="scss">
/* jsoneditor右上角默认有一个链接,加css去掉了 */
.icon {
/* jsoneditor右上角默认有一个链接,加css去掉了 */
.icon {
color: #349af3;
}
/deep/ .jsoneditor-vue {
}
/deep/ .jsoneditor-vue {
height: 100%;
}
.fullScreen {
}
.fullScreen {
position: absolute;
right: 5%;
top: 22%;
top: 20%;
cursor: pointer;
color: #fff;
}
/deep/ .jsoneditor-modes {
}
/deep/ .jsoneditor-modes {
display: none !important;
}
.jsoneditor-poweredBy {
}
/deep/.jsoneditor-poweredBy {
display: none !important;
}
.jsoneditor-menu {
}
.jsoneditor-menu {
background-color: #9c9e9f !important;
border-bottom: 1px solid #9c9e9f !important;
}
.jsoneditor {
}
.jsoneditor {
border: 1px solid #9c9e9f !important;
}
.el-collapse {
}
.el-collapse {
border: 0;
}
.el-collapse-item__header {
}
.el-collapse-item__header {
height: 44px;
}
}
.configuration {
color: white;
margin-top: 6vh;
/deep/.el-dialog {
background-color: #031a46 !important;
border: 1px solid #5f82c7;
.el-dialog__header {
.el-dialog__title {
color: white !important;
}
.el-dialog__headerbtn {
top: 20px;
}
}
}
}
</style>
......
......@@ -525,3 +525,44 @@ tr:hover {
.el-select-dropdown__item:hover {
background-color: transparent !important;
}
// 提示框
.el-message-box {
background-color: #031a46;
border: 1px solid #5f82c7;
.el-message-box__title{
color: white;
}
.el-message-box__content{
color: white;
}
}
// 上级菜单
.el-cascader__dropdown {
background-color: #031a46;
border: 1px solid #5f82c7;
}
.el-cascader-menu{
color: white;
}
.el-radio
{
.el-cascader-menu:hover{
color: white;
}
}
.el-cascader-node:not(.is-disabled):hover, .el-cascader-node:not(.is-disabled):focus {
background: #F5F7FA;
background-image: initial;
background-position-x: initial;
background-position-y: initial;
background-size: initial;
background-repeat-x: initial;
background-repeat-y: initial;
background-attachment: initial;
background-origin: initial;
background-clip: initial;
background-color: rgb(80, 142, 235);
}
......
......@@ -199,3 +199,4 @@
box-sizing: border-box;
text-align: right;
}
......
......@@ -11,9 +11,9 @@
</template>
<script>
import maps from "@/components/Echart/Map";
import brokenline from "@/components/Echart/Brokenline";
export default {
import maps from "@/components/Echart/Map";
import brokenline from "@/components/Echart/Brokenline";
export default {
data () {
return {};
},
......@@ -21,15 +21,15 @@ export default {
mounted () { },
beforeDestroy () { },
methods: {},
};
};
</script>
<style lang="scss" scoped>
.centercard {
.centercard {
width: 44%;
height: calc(100vh - 114px);
box-sizing: border-box;
padding: 0 .0521rem;
padding: 0 0.0521rem;
display: flex;
flex-direction: column;
......@@ -43,13 +43,13 @@ export default {
.title {
position: absolute;
font-weight: bold;
color: #02D9FD;
line-height: .1354rem;
font-size: .1146rem;
color: #02d9fd;
line-height: 0.1354rem;
font-size: 0.1146rem;
position: absolute;
left: 0;
right: 0;
top: .0365rem;
top: 0.0365rem;
text-align: right;
padding-right: 15%;
}
......@@ -65,20 +65,20 @@ export default {
.title {
position: absolute;
font-weight: bold;
color: #02D9FD;
line-height: .1354rem;
font-size: .1146rem;
color: #02d9fd;
line-height: 0.1354rem;
font-size: 0.1146rem;
position: absolute;
left: 0;
right: 0;
top: .0365rem;
top: 0.0365rem;
text-align: center;
margin-bottom: .0521rem;
margin-bottom: 0.0521rem;
}
.brokenline {
margin: auto;
width: 100%;
}
}
}
}
</style>
......
......@@ -13,31 +13,29 @@
<dv-decoration-5
:dur="1"
class="dv-dec-5"
:color="decorationColor"
/>
:color="decorationColor" />
</div>
<dv-decoration-8
class="dv-dec-8"
:reverse="true"
:color="decorationColor"
/>
:color="decorationColor" />
</div>
<dv-decoration-10 class="dv-dec-10-s" />
</div>
</div>
<screencontent v-show="isshow"/>
<screencontent v-show="isshow" />
</div>
</div>
</div>
</template>
<script>
import drawMixin from "@/utils/drawMixin";
import screencontent from "./screencontent";
export default {
import drawMixin from "@/utils/drawMixin";
import screencontent from "./screencontent";
export default {
mixins: [drawMixin],
data() {
data () {
return {
isshow:true,
isshow: true,
loading: true,
decorationColor: ["#568aea", "#568aea"],
};
......@@ -45,16 +43,16 @@ export default {
components: {
screencontent,
},
mounted() {
mounted () {
// this.timeFn();
this.cancelLoading();
},
beforeDestroy() {
beforeDestroy () {
clearInterval(this.timing);
},
methods: {
cancelLoading() {
cancelLoading () {
setTimeout(() => {
this.loading = false;
}, 500);
......@@ -63,9 +61,9 @@ export default {
computed: {
...mapGetters(["products"]),
},
};
};
</script>
<style scoped lang="scss">
@import "./index.scss";
@import "./index.scss";
</style>
......
......@@ -55,9 +55,9 @@
<script>
import columnar from "@/components/Echart/Columnar";
import work from "@/api/work";
export default {
import columnar from "@/components/Echart/Columnar";
import work from "@/api/work";
export default {
data () {
return {
// 日均接入量
......@@ -93,18 +93,18 @@ export default {
XZQDM: "",
};
let res = await work.getsthjqxjrtotal(p);
this.stjrl=res.result.stsum
this.qxjrl=res.result.qxsum
this.qxerrer=Number(res.result.qxjrerrer)
this.sterrer=Number(res.result.sthjerrer)
if(res.result.sum=="0"){
this.qxcgl="100%"
this.stcgl="100%"
}else{
let qxcglnum=Number(res.result.qxjrsuccess)/this.qxjrl*100
let stcgl=Number(res.result.sthjsuccess)/this.qxjrl*100
this.qxcgl=qxcglnum.toFixed(2)+"%";
this.stcgl=stcgl.toFixed(2)+"%";
this.stjrl = res.result.stsum
this.qxjrl = res.result.qxsum
this.qxerrer = Number(res.result.qxjrerrer)
this.sterrer = Number(res.result.sthjerrer)
if (res.result.sum == "0") {
this.qxcgl = "100%"
this.stcgl = "100%"
} else {
let qxcglnum = Number(res.result.qxjrsuccess) / this.qxjrl * 100
let stcgl = Number(res.result.sthjsuccess) / this.qxjrl * 100
this.qxcgl = qxcglnum.toFixed(2) + "%";
this.stcgl = stcgl.toFixed(2) + "%";
}
} catch (error) {
......@@ -113,58 +113,47 @@ export default {
});
},
},
};
};
</script>
<style lang="scss" scoped>
.leftcard {
.leftcard {
width: 32%;
height: calc(100vh -114px);
display: flex;
height: calc(100vh - 114px);
flex-direction: column;
.card {
height: 22%;
background: url("~@/image/qxjr.png") no-repeat;
background-size: 100% 100%;
position: relative;
text-align: center;
width: 100%;
height: 22%;
}
.carda {
height: 22%;
background: url("~@/image/sthj.png") no-repeat;
background-size: 100% 100%;
position: relative;
text-align: center;
width: 100%;
height: 22%;
}
// .card1 {
// background: url("~@/image/sbtj.png") no-repeat;
// background-size: 100% 100%;
// position: relative;
// text-align: center;
// width: 100%;
// padding: .0417rem 0;
// height: 49%;
// }
.card1 {
background: url("~@/image/sbtj.png") no-repeat;
background-size: 100% 100%;
position: relative;
box-sizing: border-box;
flex: 1;
height: 56%;
}
.cardhead {
color: #02d9fd;
line-height: .125rem;
letter-spacing: .0104rem;
line-height: 0.125rem;
letter-spacing: 0.0104rem;
position: absolute;
font-size: .1042rem;
font-size: 0.1042rem;
left: 0;
right: 0;
margin: auto;
......@@ -175,7 +164,7 @@ export default {
.rjjrlList {
display: flex;
margin-top: .01781rem;
margin-top: 0.01781rem;
.qxjr {
background: url("~@/image/jrl3.png");
......@@ -188,12 +177,12 @@ export default {
}
p {
margin: 0 .0156rem .0521rem .0156rem;
margin: 0 0.0156rem 0.0521rem 0.0156rem;
font-weight: 700;
width: .195rem;
height: .2475rem;
font-size: .2863rem;
font-size: .2867rem;
width: 0.195rem;
height: 0.2475rem;
font-size: 0.2863rem;
font-size: 0.2867rem;
}
}
......@@ -204,35 +193,37 @@ export default {
// padding: 35px 20px 20px 20px;
box-sizing: border-box;
color: #e3f1ff;
margin-top: .1263rem;
margin-top: 0.1263rem;
.cardcontent-left {
width: 60%;
flex-direction: column;
position: relative;
li{
font-size: .1042rem;
li {
font-size: 0.1042rem;
}
}
.cardcontent-left::before {
position: absolute;
right: 0;
top: .3042rem;
top: 0.3042rem;
content: "";
width: .0052rem;
height: .4688rem;
background: linear-gradient(180deg,
width: 0.0052rem;
height: 0.4688rem;
background: linear-gradient(
180deg,
#091b4c 0%,
#47b5e0 56%,
#091b4c 100%);
#091b4c 100%
);
}
.cardcontent-right {
flex: 1;
width: 100%;
flex-direction: column;
font-size: .0833rem;
font-size: 0.0833rem;
.bad {
color: #c97168;
......@@ -243,18 +234,18 @@ export default {
}
p {
margin-bottom: .0417rem;
margin-bottom: 0.0417rem;
span:nth-child(1) {
margin-right: .0781rem;
margin-right: 0.0781rem;
}
span:nth-child(2) {
font-size: .1042rem;
font-size: 0.1042rem;
font-weight: 900;
}
}
}
}
}
}
</style>
......
......@@ -19,10 +19,10 @@
</template>
<script>
import columnarsmat from "@/components/Echart/Columnarsmat";
import Rose from "@/components/Echart/Rose";
import work from "@/api/work";
export default {
import columnarsmat from "@/components/Echart/Columnarsmat";
import Rose from "@/components/Echart/Rose";
import work from "@/api/work";
export default {
data () {
return {
config: {
......@@ -54,28 +54,28 @@ export default {
}
}
}
}
}
</script>
<style lang="scss" scoped>
/deep/.row-item:not(:last-child) {
margin-bottom: .026rem;
}
/deep/.row-item:not(:last-child) {
margin-bottom: 0.026rem;
}
.rightcard {
.rightcard {
width: 32%;
display: flex;
height: calc(100vh - 114px);
flex-direction: column;
.cardhead {
font-size: .1042rem;
font-size: 0.1042rem;
font-weight: bold;
color: #02D9FD;
color: #02d9fd;
text-align: center;
position: absolute;
left: 0;
right: 0;
top: .0625rem;
top: 0.0625rem;
text-align: center;
}
......@@ -86,8 +86,8 @@ export default {
overflow: hidden;
.nodata {
font-size: .1042rem;
color: #02D9FD;
font-size: 0.1042rem;
color: #02d9fd;
font-weight: bold;
margin: auto;
margin-top: 120px;
......@@ -95,7 +95,7 @@ export default {
}
.cardCon {
padding: .0521rem .026rem;
padding: 0.0521rem 0.026rem;
position: relative;
text-align: center;
width: 100%;
......@@ -105,19 +105,24 @@ export default {
height: 33%;
background: url("~@/image/xjgyfwxx.png") no-repeat;
background-size: 100% 100%;
/deep/.dv-scroll-board {
.header {
height: 0.1875rem;
align-items: center;
}
}
.board {
width: 90%;
margin: 0 auto;
height: 1.1031rem;
margin-top: .0521rem;
/deep/.header{
font-size: .0738rem;
margin-top: 0.0521rem;
/deep/.header {
font-size: 0.0738rem;
}
/deep/.rows{
.ceil{
font-size: .0738rem;
color: #6BC1FC
/deep/.rows {
.ceil {
font-size: 0.0738rem;
color: #6bc1fc;
}
}
}
......@@ -127,7 +132,7 @@ export default {
height: 33%;
background: url("~@/image/djywl.png") no-repeat;
background-size: 100% 100%;
padding: .3825rem 0 0 0;
padding: 0.3825rem 0 0 0;
}
.card3 {
......@@ -138,12 +143,12 @@ export default {
padding-bottom: 0;
.cardhead {
top: .0417rem;
top: 0.0417rem;
}
}
.cardhead {
position: absolute;
}
}
}
</style>
......
......@@ -99,17 +99,17 @@
</template>
<script>
// 接收报文查询
// 引入表格头部数据
import data from "./data";
// 引入table混入方法
import tableMixin from "@/mixins/tableMixin.js";
import { getReceiveDataReportPage } from "@/api/dataReport.js";
// 引入详情弹框
import dataDetails from "@/components/EditDialog";
//引入日期处理方法
import { timeFormat } from "@/utils/operation";
export default {
// 接收报文查询
// 引入表格头部数据
import data from "./data";
// 引入table混入方法
import tableMixin from "@/mixins/tableMixin.js";
import { getReceiveDataReportPage } from "@/api/dataReport.js";
// 引入详情弹框
import dataDetails from "@/components/EditDialog";
//引入日期处理方法
import { timeFormat } from "@/utils/operation";
export default {
name: "jsbwcx",
mixins: [tableMixin],
// 注册组件
......@@ -224,6 +224,7 @@ export default {
getReceiveDataReportPage({ ...this.form, ...this.formData }).then(
(res) => {
if (res.code === 200) {
console.log("菜单列表", res);
let { total, records, current } = res.result;
this.tableData.total = total;
this.tableData.data = records ? records : [];
......@@ -274,12 +275,12 @@ export default {
}
},
}
}
}
</script>
<style scoped lang="scss">
// 引入表单整体样式
@import "~@/styles/public.scss";
// 引入当前css
@import "./index.scss";
// 引入表单整体样式
@import "~@/styles/public.scss";
// 引入当前css
@import "./index.scss";
</style>
......
......@@ -142,8 +142,8 @@
padding: 24px 120px 0px;
.el-form-item {
margin-bottom: 24px;
.el-form-item__label {
color: #747e8c;
/deep/.el-form-item__label {
color: #ffffff;
}
::v-deep .el-input .el-input__inner {
padding: 0 8px;
......
......@@ -15,8 +15,8 @@
</div>
<div class="from-clues-content">
<div class="contentbox">
<base-set v-show="isshow" :userInfo="userData" />
<password-edit v-show="!isshow" :userInfo="userData" />
<base-set v-if="isshow" :userInfo="userData" />
<password-edit v-if="!isshow" :userInfo="userData" />
</div>
</div>
</div>
......
......@@ -110,10 +110,10 @@
overflow-y: auto;
.form-wrapper {
padding: 24px 120px 0px;
.el-form-item {
/deep/.el-form-item {
margin-bottom: 24px;
.el-form-item__label {
color: #747e8c;
color: #ffffff;
}
::v-deep .el-input .el-input__inner {
padding: 0 8px;
......
......@@ -30,8 +30,8 @@
</el-row>
<el-row :gutter="24">
<el-col :span="12">
<el-form-item label="代码:" prop="code" label-width="54px">
<el-col :span="24">
<el-form-item label="代码:" prop="code" label-width="124px">
<el-input
v-model="codeComputed"
placeholder="请输入菜单代码"
......@@ -272,4 +272,5 @@
/deep/.el-input__inner {
background-color: #07388b;
}
</style>
......
import filter from '@/utils/filter.js'
class data extends filter {
constructor() {
super()
}
columns () {
return [
{
prop: "name",
label: "角色名称",
width: 330
},
{
prop: "type",
label: "类别",
width: 400
},
{
prop: "address",
label: "备注"
}
]
}
}
export default new data()
......@@ -4,39 +4,36 @@
:title="dialogTitle"
:show.sync="showAddEditDialog"
:width="'767px'"
@close="handleCloseDialog()"
>
@close="handleCloseDialog()">
<template slot="content">
<el-form ref="form" :model="dialogForm" :rules="rules" label-width="82px">
<el-row :gutter="24">
<el-col :span="12">
<el-col :span="15">
<el-form-item label="角色名称:" prop="roleName">
<el-input
v-model="dialogForm.roleName"
clearable
placeholder="角色名称"
/>
placeholder="角色名称" />
</el-form-item>
</el-col>
<el-col :span="12">
</el-row>
<el-row :gutter="24">
<el-col :span="24">
<el-form-item label="角色类型:" prop="roleType">
<el-input
v-model="dialogForm.roleType"
clearable
placeholder="角色类型"
/>
placeholder="角色类型" />
</el-form-item>
</el-col>
</el-row>
<br>
<el-row>
<el-col :span="24">
<el-form-item label="备注:" class="form-item-mb0">
<el-input
v-model="dialogForm.roleTextArea"
type="textarea"
placeholder="备注"
/>
placeholder="备注" />
</el-form-item>
</el-col>
</el-row>
......@@ -45,25 +42,23 @@
<template slot="footer">
<el-button
class="cancel-button"
@click="handleCloseDialog"
>取消</el-button>
@click="handleCloseDialog">取消</el-button>
<el-button
type="primary"
@click="handleSaveRole()"
>保存</el-button>
@click="handleSaveRole()">保存</el-button>
</template>
</Dialog>
</template>
<script>
import Dialog from "@/components/Dialog/";
import { api, httpAction } from '@/api/manageApi'
export default {
import Dialog from "@/components/Dialog/";
import { api, httpAction } from '@/api/manageApi'
export default {
components: {
Dialog
},
data() {
data () {
return {
dialogTitle: '',
showAddEditDialog: false,
......@@ -91,7 +86,7 @@ export default {
},
methods: {
// 保存新增或关闭事件
handleSaveRole(val) {
handleSaveRole (val) {
this.$refs.form.validate((valid) => {
if (valid) {
try {
......@@ -102,10 +97,8 @@ export default {
sort: this.sort,
type: this.dialogForm.roleType
}
console.log("this.roleId",this.roleId);
if (this.roleId) {
params.id = this.roleId
console.log("修改",params.id,params);
httpAction(`${api.roles}/${params.id}`, params, 'post').then(
(res) => {
if (res.status === 1) {
......@@ -155,7 +148,7 @@ export default {
})
},
// 取消事件
handleCloseDialog() {
handleCloseDialog () {
this.$refs.form.resetFields()
this.dialogForm = {
roleName: '',
......@@ -164,19 +157,31 @@ export default {
this.showAddEditDialog = false
}
}
}
}
</script>
<style scoped lang="scss">
/deep/.el-input__inner {
background: #07388B;
background: #07388b;
border-radius: 2px;
border: 1px solid #6BC1FC;
border: 1px solid #6bc1fc;
}
/deep/.el-textarea__inner {
background: #07388b;
color: #fff;
}
/deep/.el-textarea__inner{
background: #07388B;
/deep/.el-form-item__label {
color: #fff;
}
/deep/.el-form-item__label{
color:#fff;
}
}
/deep/.el-dialog__headerbtn {
position: absolute;
top: 15px;
right: 30px;
}
/deep/.el-dialog__header {
text-align: center;
margin-bottom: 10px;
.el-dialog__title {
color: white;
}
}
</style>
......
......@@ -14,15 +14,13 @@
</div>
<div class="from-clues-content">
<lb-table
:page-size="pageData.size"
:current-page.sync="pageData.current"
:total="pageData.total"
:pagination="false"
@size-change="handleSizeChange"
@p-current-change="handleCurrentChange"
:column="tableData.columns"
:data="listdata"
:expand-row-keys="keyList"
row-key="id">
row-key="dictid">
</lb-table>
</div>
<EditDialog ref="addEditDialog" @ok="reloadTableData" />
......@@ -219,11 +217,6 @@
]),
data: [],
},
pageData: {
total: 5,
pageSize: 15,
current: 1,
},
};
},
created () {
......@@ -242,6 +235,7 @@
Builtinrole = res.content;
getRolesById(2)
.then((res) => {
console.log("角色列表", res);
Publicrole = res.content;
this.listdata = Builtinrole.concat(Publicrole);
......@@ -376,8 +370,6 @@
}
this.$refs.rolesForm.personlist(this.waitMemberList, row.id);
// this.$refs.rolesForm.getMenuData();
this.$refs.rolesForm.menulist(this.operationList, row.id, this.selectedSubsystemCode, this.menutablelistData, this.operationCodes);
} else {
this.$message.error({ message: res.message, showClose: true });
......@@ -402,15 +394,15 @@
},
// 上移下移
moveUpward (index, row) {
realMove(row.id, "UP", this.listdata);
realMove(row.dictid, "UP", this.listdata);
this.key++;
let id = findParents(this.listdata, row.id);
let id = findParents(this.listdata, row.dictid);
this.keyList = id;
},
moveDown (index, row) {
realMove(row.id, "DOWN", this.listdata);
realMove(row.dictid, "DOWN", this.listdata);
this.key++;
let id = findParents(this.listdata, row.id);
let id = findParents(this.listdata, row.dictid);
this.keyList = id;
},
......
......@@ -10,7 +10,7 @@
{{ title || "标题" }}
</div>
<div class="editDialogBox-box">
<el-tabs v-model="activeName" type="card">
<el-tabs v-model="activeName" type="card" @tab-click="handleClick">
<el-tab-pane label="人员配置" name="first"></el-tab-pane>
<el-tab-pane label="菜单配置" name="second"></el-tab-pane>
</el-tabs>
......@@ -19,7 +19,7 @@
ref="multipleTable"
:pagination="false"
:column="usertableData.column"
:data="usertableData.data"
:data="lastuserList"
@selection-change="handleSelectionChange"
@row-click="handleClickTableRow">
>
......@@ -27,7 +27,6 @@
<lb-table
:key="menukey"
v-if="activeName == 'second'"
ref="multipleTable1"
:pagination="false"
:column="menutableData.column"
:data="lastMenuList"
......@@ -99,7 +98,6 @@
label: "用户名",
},
],
data: []
},
// 角色id
roleId: "",
......@@ -107,6 +105,7 @@
queryParam: {},
menukey: 0,
activeName: "first",
lastuserList: [], // 人员表格数据
lastMenuList: [], // 重构完成的菜单表格数据
usermultipleSelection: [],
// 选中菜单列表
......@@ -132,8 +131,8 @@
// 人员配置点击行勾选数据
handleClickTableRow (row, event) {
this.checkNum1 = 0;
this.isCheck1 = false;
this.checkNum = 0;
this.isCheck = false;
if (event.label == "操作") {
return;
} else {
......@@ -163,10 +162,10 @@
}
}
if (this.usermultipleSelection.length > 0) {
this.checkNum1 = this.usermultipleSelection.length;
this.isCheck1 = true;
this.checkNum = this.usermultipleSelection.length;
this.isCheck = true;
} else {
this.isCheck1 = false;
this.isCheck = false;
}
},
// 获取授权主体的菜单权限
......@@ -304,19 +303,21 @@
personlist (a, rid) {
this.roleId = rid;
this.visible = true;
this.usertableData.data = a;
this.usertableData.data.forEach((item, index) => {
this.lastuserList = a;
this.lastuserList.forEach((item, index) => {
if (item.selectStatus === 0) {
this.$nextTick(() => {
this.$nextTick(async () => {
await this.$refs.multipleTable
if (this.$refs.multipleTable) {
this.$refs.multipleTable.toggleRowSelection(
this.usertableData.data[index],
this.lastuserList[index],
true
);
}
});
}
});
},
// 关闭事件
close () {
......@@ -351,7 +352,17 @@
},
// 勾选人员事件
handleSelectionChange (val) {
this.lastuserList.forEach((element, index) => {
delete this.lastuserList[index].selectStatus
});
this.usermultipleSelection = val;
this.lastuserList.forEach((element, index) => {
this.usermultipleSelection.forEach(element1 => {
if (element.id == element1.id) {
this.lastuserList[index].selectStatus = 0
}
});
});
},
// 数据筛选
setarrdata (scope, arr) {
......@@ -383,6 +394,23 @@
)
this.getAuthorizedInfo()
},
handleClick (tab, event) {
this.lastuserList.forEach((item, index) => {
if (item.selectStatus === 0) {
this.$nextTick(async () => {
await this.$refs.multipleTable
if (this.$refs.multipleTable) {
this.$refs.multipleTable.toggleRowSelection(
this.lastuserList[index],
true
);
}
});
}
});
}
},
};
</script>
......@@ -566,13 +594,8 @@
display: flex;
margin-bottom: 15px;
}
.dialog_footer {
flex-direction: column;
.dialog_button {
margin-top: 8px;
}
.el-dialog__footer {
padding-right: 40px;
}
.divider {
......
......@@ -114,7 +114,7 @@
{ required: true, message: "请输入用户名", trigger: "blur" },
],
},
title: "",
title: "修改",
visible: false,
showLoginName: false,
sexList: [{ lable: "0", value: "0", name: "男" }, { lable: "1", value: "1", name: "女" }],
......@@ -230,4 +230,14 @@
/deep/.el-form-item__label {
color: #fff;
}
/deep/.el-dialog__body {
padding-top: 20px;
}
/deep/.el-dialog__header {
text-align: center;
margin-bottom: 10px;
.el-dialog__title {
color: white;
}
}
</style>
......
......@@ -17,9 +17,7 @@
</div>
<div class="from-clues-content">
<lb-table
:page-size="pageData.size"
:current-page.sync="pageData.current"
:total="pageData.total"
:pagination="false"
@size-change="handleSizeChange"
@p-current-change="handleCurrentChange"
:column="tableData.columns"
......@@ -182,11 +180,6 @@
]),
data: [],
},
pageData: {
total: 5,
pageSize: 15,
current: 1,
},
};
},
created () {
......@@ -209,6 +202,7 @@
departmentId: this.departmentid.departmentId,
};
getUserList(this.queryParam).then((res) => {
console.log("人员列表", res);
if (res.status === 1) {
this.loading = false;
this.tableData.data = res.content;
......