Merge branch 'master' of http://yun.pashanhoo.com:9090/bdc/bdcjg-web
Showing
21 changed files
with
778 additions
and
730 deletions
| ... | @@ -3,47 +3,47 @@ | ... | @@ -3,47 +3,47 @@ |
| 3 | </template> | 3 | </template> |
| 4 | 4 | ||
| 5 | <script> | 5 | <script> |
| 6 | import Chart from "./Chart"; | 6 | import Chart from "./Chart"; |
| 7 | import work from "@/api/work"; | 7 | import work from "@/api/work"; |
| 8 | export default { | 8 | export default { |
| 9 | data() { | 9 | data () { |
| 10 | return { | 10 | return { |
| 11 | cdata: { | 11 | cdata: { |
| 12 | category: [], | 12 | category: [], |
| 13 | lineData: [], | 13 | lineData: [], |
| 14 | barData: [], | 14 | barData: [], |
| 15 | }, | 15 | }, |
| 16 | }; | 16 | }; |
| 17 | }, | 17 | }, |
| 18 | components: { | 18 | components: { |
| 19 | Chart, | 19 | Chart, |
| 20 | }, | 20 | }, |
| 21 | mounted() { | 21 | mounted () { |
| 22 | window.addEventListener("resize", () => { | 22 | window.addEventListener("resize", () => { |
| 23 | this.submitViews(); | ||
| 24 | }); | ||
| 23 | this.submitViews(); | 25 | this.submitViews(); |
| 24 | }); | ||
| 25 | this.submitViews(); | ||
| 26 | }, | ||
| 27 | methods: { | ||
| 28 | async submitViews() { | ||
| 29 | try { | ||
| 30 | let { result: res } = await work.submitViews("A20"); | ||
| 31 | this.cdata.category = []; | ||
| 32 | this.cdata.barData = []; | ||
| 33 | this.cdata.lineData = []; | ||
| 34 | res.map((item) => { | ||
| 35 | return ( | ||
| 36 | this.cdata.category.push(item.areaName), | ||
| 37 | this.cdata.barData.push(item.successCount), | ||
| 38 | this.cdata.lineData.push(item.failureCount) | ||
| 39 | ); | ||
| 40 | }); | ||
| 41 | } catch (error) { | ||
| 42 | // this.$refs.msg.messageShow(); | ||
| 43 | } | ||
| 44 | }, | 26 | }, |
| 45 | }, | 27 | methods: { |
| 46 | }; | 28 | async submitViews () { |
| 29 | try { | ||
| 30 | let { result: res } = await work.submitViews("A20"); | ||
| 31 | this.cdata.category = []; | ||
| 32 | this.cdata.barData = []; | ||
| 33 | this.cdata.lineData = []; | ||
| 34 | res.map((item) => { | ||
| 35 | return ( | ||
| 36 | this.cdata.category.push(item.areaName), | ||
| 37 | this.cdata.barData.push(item.successCount), | ||
| 38 | this.cdata.lineData.push(item.failureCount) | ||
| 39 | ); | ||
| 40 | }); | ||
| 41 | } catch (error) { | ||
| 42 | // this.$refs.msg.messageShow(); | ||
| 43 | } | ||
| 44 | }, | ||
| 45 | }, | ||
| 46 | }; | ||
| 47 | </script> | 47 | </script> |
| 48 | 48 | ||
| 49 | <style lang="scss" scoped></style> | 49 | <style lang="scss" scoped></style> | ... | ... |
This diff is collapsed.
Click to expand it.
| ... | @@ -2,6 +2,7 @@ | ... | @@ -2,6 +2,7 @@ |
| 2 | <div> | 2 | <div> |
| 3 | <i class="el-icon-s-management icon" :title="title" @click="openDialog" /> | 3 | <i class="el-icon-s-management icon" :title="title" @click="openDialog" /> |
| 4 | <el-dialog | 4 | <el-dialog |
| 5 | class="configuration" | ||
| 5 | :key="key" | 6 | :key="key" |
| 6 | :title="title" | 7 | :title="title" |
| 7 | :inner-dialog="true" | 8 | :inner-dialog="true" |
| ... | @@ -9,8 +10,7 @@ | ... | @@ -9,8 +10,7 @@ |
| 9 | width="600px" | 10 | width="600px" |
| 10 | :close-on-click-modal="false" | 11 | :close-on-click-modal="false" |
| 11 | append-to-body | 12 | append-to-body |
| 12 | @cancel="cancel" | 13 | @cancel="cancel"> |
| 13 | > | ||
| 14 | <vue-json-editor | 14 | <vue-json-editor |
| 15 | id="minejson" | 15 | id="minejson" |
| 16 | v-model="resultInfo" | 16 | v-model="resultInfo" |
| ... | @@ -18,15 +18,13 @@ | ... | @@ -18,15 +18,13 @@ |
| 18 | lang="zh" | 18 | lang="zh" |
| 19 | @json-change="onJsonChange" | 19 | @json-change="onJsonChange" |
| 20 | @json-save="onJsonSave" | 20 | @json-save="onJsonSave" |
| 21 | @has-error="onError" | 21 | @has-error="onError" /> |
| 22 | /> | ||
| 23 | <el-tooltip | 22 | <el-tooltip |
| 24 | content="全屏缩放" | 23 | content="全屏缩放" |
| 25 | effect="dark" | 24 | effect="dark" |
| 26 | placement="bottom" | 25 | placement="bottom" |
| 27 | fullscreen | 26 | fullscreen |
| 28 | class="fullScreen" | 27 | class="fullScreen"> |
| 29 | > | ||
| 30 | <i class="el-icon-full-screen" @click="enLarge" /> | 28 | <i class="el-icon-full-screen" @click="enLarge" /> |
| 31 | </el-tooltip> | 29 | </el-tooltip> |
| 32 | <template slot="footer"> | 30 | <template slot="footer"> |
| ... | @@ -34,142 +32,156 @@ | ... | @@ -34,142 +32,156 @@ |
| 34 | <el-button | 32 | <el-button |
| 35 | type="primary" | 33 | type="primary" |
| 36 | class="confirmBtn" | 34 | class="confirmBtn" |
| 37 | @click="onJsonSave" | 35 | @click="onJsonSave">保存</el-button> |
| 38 | >保存</el-button> | ||
| 39 | <el-button | 36 | <el-button |
| 40 | type="primary" | 37 | type="primary" |
| 41 | class="cancelBtn" | 38 | class="cancelBtn" |
| 42 | @click="cancel" | 39 | @click="cancel">关闭</el-button> |
| 43 | >关闭</el-button> | ||
| 44 | </div> | 40 | </div> |
| 45 | </template> | 41 | </template> |
| 46 | </el-dialog> | 42 | </el-dialog> |
| 47 | </div> | 43 | </div> |
| 48 | </template> | 44 | </template> |
| 49 | <script> | 45 | <script> |
| 50 | import vueJsonEditor from 'vue-json-editor' | 46 | import vueJsonEditor from 'vue-json-editor' |
| 51 | export default { | 47 | export default { |
| 52 | components: { | 48 | components: { |
| 53 | vueJsonEditor | 49 | vueJsonEditor |
| 54 | }, | ||
| 55 | props: { | ||
| 56 | title: { | ||
| 57 | type: String, | ||
| 58 | default: '配置参数' | ||
| 59 | }, | 50 | }, |
| 60 | resultInfos: { | 51 | props: { |
| 61 | type: String, | 52 | title: { |
| 62 | default: '' | 53 | type: String, |
| 63 | } | 54 | default: '配置参数' |
| 64 | }, | ||
| 65 | data() { | ||
| 66 | return { | ||
| 67 | activeNames: [], | ||
| 68 | resultInfo: {}, | ||
| 69 | tmpResultInfo: {}, | ||
| 70 | dialogVisible: false, | ||
| 71 | hasJsonFlag: true, | ||
| 72 | key: 0, | ||
| 73 | isEnlarge: false | ||
| 74 | } | ||
| 75 | }, | ||
| 76 | watch: { | ||
| 77 | resultInfos: { | ||
| 78 | handler: function(val) { | ||
| 79 | ++this.key | ||
| 80 | this.resultInfo = | ||
| 81 | this.resultInfos === '' ? {} : JSON.parse(this.resultInfos) | ||
| 82 | this.tmpResultInfo = this.resultInfo | ||
| 83 | }, | 55 | }, |
| 84 | deep: true, | 56 | resultInfos: { |
| 85 | immediate: true | 57 | type: String, |
| 86 | } | 58 | default: '' |
| 87 | }, | ||
| 88 | |||
| 89 | mounted() { | ||
| 90 | this.resultInfo = | ||
| 91 | this.resultInfos === '' ? {} : JSON.parse(this.resultInfos) | ||
| 92 | }, | ||
| 93 | |||
| 94 | methods: { | ||
| 95 | onJsonChange(value) { | ||
| 96 | // 只有在格式正确的时候进入此事件 | ||
| 97 | this.hasJsonFlag = true | ||
| 98 | }, | ||
| 99 | onJsonSave() { | ||
| 100 | const value = this.resultInfo | ||
| 101 | console.log(this.resultInfo, 'resultInfo') | ||
| 102 | if (this.hasJsonFlag === false) { | ||
| 103 | this.$message.error({ message: 'json格式验证失败', showClose: true }) | ||
| 104 | // alert("json验证失败") | ||
| 105 | return false | ||
| 106 | } else { | ||
| 107 | this.dialogVisible = false | ||
| 108 | this.$emit('getJsonString', JSON.stringify(value)) | ||
| 109 | return true | ||
| 110 | } | 59 | } |
| 111 | }, | 60 | }, |
| 112 | onError(value) { | 61 | data () { |
| 113 | this.hasJsonFlag = false | 62 | return { |
| 63 | activeNames: [], | ||
| 64 | resultInfo: {}, | ||
| 65 | tmpResultInfo: {}, | ||
| 66 | dialogVisible: false, | ||
| 67 | hasJsonFlag: true, | ||
| 68 | key: 0, | ||
| 69 | isEnlarge: false | ||
| 70 | } | ||
| 114 | }, | 71 | }, |
| 115 | openDialog() { | 72 | watch: { |
| 116 | this.dialogVisible = true | 73 | resultInfos: { |
| 74 | handler: function (val) { | ||
| 75 | ++this.key | ||
| 76 | this.resultInfo = | ||
| 77 | this.resultInfos === '' ? {} : JSON.parse(this.resultInfos) | ||
| 78 | this.tmpResultInfo = this.resultInfo | ||
| 79 | }, | ||
| 80 | deep: true, | ||
| 81 | immediate: true | ||
| 82 | } | ||
| 117 | }, | 83 | }, |
| 118 | cancel() { | 84 | |
| 119 | console.log(this.tmpResultInfo, 'tmpResultInfo') | 85 | mounted () { |
| 120 | this.resultInfo = this.tmpResultInfo | 86 | this.resultInfo = |
| 121 | this.dialogVisible = false | 87 | this.resultInfos === '' ? {} : JSON.parse(this.resultInfos) |
| 122 | }, | 88 | }, |
| 123 | // 放大 | 89 | |
| 124 | enLarge() { | 90 | methods: { |
| 125 | const fullarea = document.getElementById('minejson') | 91 | onJsonChange (value) { |
| 126 | if (fullarea.requestFullscreen) { | 92 | // 只有在格式正确的时候进入此事件 |
| 127 | fullarea.requestFullscreen() | 93 | this.hasJsonFlag = true |
| 128 | } else if (fullarea.webkitRequestFullScreen) { | 94 | }, |
| 129 | fullarea.webkitRequestFullScreen() // webkit内核(chrome、safari、Opera等) | 95 | onJsonSave () { |
| 130 | } else if (fullarea.mozRequestFullScreen) { | 96 | const value = this.resultInfo |
| 131 | fullarea.mozRequestFullScreen() // moz内核(firefox) | 97 | console.log(this.resultInfo, 'resultInfo') |
| 132 | } else if (fullarea.msRequestFullscreen) { | 98 | if (this.hasJsonFlag === false) { |
| 133 | fullarea.msRequestFullscreen() // IE11、edge | 99 | this.$message.error({ message: 'json格式验证失败', showClose: true }) |
| 100 | // alert("json验证失败") | ||
| 101 | return false | ||
| 102 | } else { | ||
| 103 | this.dialogVisible = false | ||
| 104 | this.$emit('getJsonString', JSON.stringify(value)) | ||
| 105 | return true | ||
| 106 | } | ||
| 107 | }, | ||
| 108 | onError (value) { | ||
| 109 | this.hasJsonFlag = false | ||
| 110 | }, | ||
| 111 | openDialog () { | ||
| 112 | this.dialogVisible = true | ||
| 113 | }, | ||
| 114 | cancel () { | ||
| 115 | console.log(this.tmpResultInfo, 'tmpResultInfo') | ||
| 116 | this.resultInfo = this.tmpResultInfo | ||
| 117 | this.dialogVisible = false | ||
| 118 | }, | ||
| 119 | // 放大 | ||
| 120 | enLarge () { | ||
| 121 | const fullarea = document.getElementById('minejson') | ||
| 122 | if (fullarea.requestFullscreen) { | ||
| 123 | fullarea.requestFullscreen() | ||
| 124 | } else if (fullarea.webkitRequestFullScreen) { | ||
| 125 | fullarea.webkitRequestFullScreen() // webkit内核(chrome、safari、Opera等) | ||
| 126 | } else if (fullarea.mozRequestFullScreen) { | ||
| 127 | fullarea.mozRequestFullScreen() // moz内核(firefox) | ||
| 128 | } else if (fullarea.msRequestFullscreen) { | ||
| 129 | fullarea.msRequestFullscreen() // IE11、edge | ||
| 130 | } | ||
| 131 | this.isEnlarge = true | ||
| 134 | } | 132 | } |
| 135 | this.isEnlarge = true | ||
| 136 | } | 133 | } |
| 137 | } | 134 | } |
| 138 | } | ||
| 139 | </script> | 135 | </script> |
| 140 | 136 | ||
| 141 | <style scoped lang="scss"> | 137 | <style scoped lang="scss"> |
| 142 | /* jsoneditor右上角默认有一个链接,加css去掉了 */ | 138 | /* jsoneditor右上角默认有一个链接,加css去掉了 */ |
| 143 | .icon { | 139 | .icon { |
| 144 | color: #349af3; | 140 | color: #349af3; |
| 145 | } | 141 | } |
| 146 | /deep/ .jsoneditor-vue { | 142 | /deep/ .jsoneditor-vue { |
| 147 | height: 100%; | 143 | height: 100%; |
| 148 | } | 144 | } |
| 149 | .fullScreen { | 145 | .fullScreen { |
| 150 | position: absolute; | 146 | position: absolute; |
| 151 | right: 5%; | 147 | right: 5%; |
| 152 | top: 22%; | 148 | top: 20%; |
| 153 | cursor: pointer; | 149 | cursor: pointer; |
| 154 | color: #fff; | 150 | color: #fff; |
| 155 | } | 151 | } |
| 156 | /deep/ .jsoneditor-modes { | 152 | /deep/ .jsoneditor-modes { |
| 157 | display: none !important; | 153 | display: none !important; |
| 158 | } | 154 | } |
| 159 | .jsoneditor-poweredBy { | 155 | /deep/.jsoneditor-poweredBy { |
| 160 | display: none !important; | 156 | display: none !important; |
| 161 | } | 157 | } |
| 162 | .jsoneditor-menu { | 158 | .jsoneditor-menu { |
| 163 | background-color: #9c9e9f !important; | 159 | background-color: #9c9e9f !important; |
| 164 | border-bottom: 1px solid #9c9e9f !important; | 160 | border-bottom: 1px solid #9c9e9f !important; |
| 165 | } | 161 | } |
| 166 | .jsoneditor { | 162 | .jsoneditor { |
| 167 | border: 1px solid #9c9e9f !important; | 163 | border: 1px solid #9c9e9f !important; |
| 168 | } | 164 | } |
| 169 | .el-collapse { | 165 | .el-collapse { |
| 170 | border: 0; | 166 | border: 0; |
| 171 | } | 167 | } |
| 172 | .el-collapse-item__header { | 168 | .el-collapse-item__header { |
| 173 | height: 44px; | 169 | height: 44px; |
| 174 | } | 170 | } |
| 171 | .configuration { | ||
| 172 | color: white; | ||
| 173 | margin-top: 6vh; | ||
| 174 | /deep/.el-dialog { | ||
| 175 | background-color: #031a46 !important; | ||
| 176 | border: 1px solid #5f82c7; | ||
| 177 | .el-dialog__header { | ||
| 178 | .el-dialog__title { | ||
| 179 | color: white !important; | ||
| 180 | } | ||
| 181 | .el-dialog__headerbtn { | ||
| 182 | top: 20px; | ||
| 183 | } | ||
| 184 | } | ||
| 185 | } | ||
| 186 | } | ||
| 175 | </style> | 187 | </style> | ... | ... |
| ... | @@ -524,4 +524,45 @@ tr:hover { | ... | @@ -524,4 +524,45 @@ tr:hover { |
| 524 | .el-select-dropdown__item.hover, | 524 | .el-select-dropdown__item.hover, |
| 525 | .el-select-dropdown__item:hover { | 525 | .el-select-dropdown__item:hover { |
| 526 | background-color: transparent !important; | 526 | background-color: transparent !important; |
| 527 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 527 | } | ||
| 528 | |||
| 529 | // 提示框 | ||
| 530 | .el-message-box { | ||
| 531 | background-color: #031a46; | ||
| 532 | border: 1px solid #5f82c7; | ||
| 533 | |||
| 534 | .el-message-box__title{ | ||
| 535 | color: white; | ||
| 536 | } | ||
| 537 | .el-message-box__content{ | ||
| 538 | color: white; | ||
| 539 | } | ||
| 540 | } | ||
| 541 | // 上级菜单 | ||
| 542 | .el-cascader__dropdown { | ||
| 543 | background-color: #031a46; | ||
| 544 | border: 1px solid #5f82c7; | ||
| 545 | |||
| 546 | } | ||
| 547 | .el-cascader-menu{ | ||
| 548 | color: white; | ||
| 549 | } | ||
| 550 | .el-radio | ||
| 551 | { | ||
| 552 | .el-cascader-menu:hover{ | ||
| 553 | color: white; | ||
| 554 | } | ||
| 555 | } | ||
| 556 | .el-cascader-node:not(.is-disabled):hover, .el-cascader-node:not(.is-disabled):focus { | ||
| 557 | background: #F5F7FA; | ||
| 558 | background-image: initial; | ||
| 559 | background-position-x: initial; | ||
| 560 | background-position-y: initial; | ||
| 561 | background-size: initial; | ||
| 562 | background-repeat-x: initial; | ||
| 563 | background-repeat-y: initial; | ||
| 564 | background-attachment: initial; | ||
| 565 | background-origin: initial; | ||
| 566 | background-clip: initial; | ||
| 567 | background-color: rgb(80, 142, 235); | ||
| 568 | } | ... | ... |
| ... | @@ -21,4 +21,4 @@ export default function filterAsyncRouter (routers) { | ... | @@ -21,4 +21,4 @@ export default function filterAsyncRouter (routers) { |
| 21 | } | 21 | } |
| 22 | function loadView (view) { | 22 | function loadView (view) { |
| 23 | return r => require.ensure([], () => r(require(`@/views${view}.vue`))) | 23 | return r => require.ensure([], () => r(require(`@/views${view}.vue`))) |
| 24 | } | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 24 | } | ... | ... |
| ... | @@ -11,74 +11,74 @@ | ... | @@ -11,74 +11,74 @@ |
| 11 | </template> | 11 | </template> |
| 12 | 12 | ||
| 13 | <script> | 13 | <script> |
| 14 | import maps from "@/components/Echart/Map"; | 14 | import maps from "@/components/Echart/Map"; |
| 15 | import brokenline from "@/components/Echart/Brokenline"; | 15 | import brokenline from "@/components/Echart/Brokenline"; |
| 16 | export default { | 16 | export default { |
| 17 | data () { | 17 | data () { |
| 18 | return {}; | 18 | return {}; |
| 19 | }, | 19 | }, |
| 20 | components: { maps, brokenline }, | 20 | components: { maps, brokenline }, |
| 21 | mounted () { }, | 21 | mounted () { }, |
| 22 | beforeDestroy () { }, | 22 | beforeDestroy () { }, |
| 23 | methods: {}, | 23 | methods: {}, |
| 24 | }; | 24 | }; |
| 25 | </script> | 25 | </script> |
| 26 | 26 | ||
| 27 | <style lang="scss" scoped> | 27 | <style lang="scss" scoped> |
| 28 | .centercard { | 28 | .centercard { |
| 29 | width: 44%; | 29 | width: 44%; |
| 30 | height: calc(100vh - 114px); | 30 | height: calc(100vh - 114px); |
| 31 | box-sizing: border-box; | 31 | box-sizing: border-box; |
| 32 | padding: 0 .0521rem; | 32 | padding: 0 0.0521rem; |
| 33 | display: flex; | 33 | display: flex; |
| 34 | flex-direction: column; | 34 | flex-direction: column; |
| 35 | 35 | ||
| 36 | .card1 { | 36 | .card1 { |
| 37 | width: 100%; | 37 | width: 100%; |
| 38 | background: url("~@/image/mapcenter.png") no-repeat; | 38 | background: url("~@/image/mapcenter.png") no-repeat; |
| 39 | background-size: 100% 100%; | 39 | background-size: 100% 100%; |
| 40 | position: relative; | 40 | position: relative; |
| 41 | height: 64%; | 41 | height: 64%; |
| 42 | 42 | ||
| 43 | .title { | 43 | .title { |
| 44 | position: absolute; | 44 | position: absolute; |
| 45 | font-weight: bold; | 45 | font-weight: bold; |
| 46 | color: #02D9FD; | 46 | color: #02d9fd; |
| 47 | line-height: .1354rem; | 47 | line-height: 0.1354rem; |
| 48 | font-size: .1146rem; | 48 | font-size: 0.1146rem; |
| 49 | position: absolute; | 49 | position: absolute; |
| 50 | left: 0; | 50 | left: 0; |
| 51 | right: 0; | 51 | right: 0; |
| 52 | top: .0365rem; | 52 | top: 0.0365rem; |
| 53 | text-align: right; | 53 | text-align: right; |
| 54 | padding-right: 15%; | 54 | padding-right: 15%; |
| 55 | } | ||
| 55 | } | 56 | } |
| 56 | } | ||
| 57 | |||
| 58 | .card2 { | ||
| 59 | width: 100%; | ||
| 60 | background: url("~@/image/sjqs.png") no-repeat; | ||
| 61 | background-size: 100% 100%; | ||
| 62 | position: relative; | ||
| 63 | flex: 1; | ||
| 64 | 57 | ||
| 65 | .title { | 58 | .card2 { |
| 66 | position: absolute; | ||
| 67 | font-weight: bold; | ||
| 68 | color: #02D9FD; | ||
| 69 | line-height: .1354rem; | ||
| 70 | font-size: .1146rem; | ||
| 71 | position: absolute; | ||
| 72 | left: 0; | ||
| 73 | right: 0; | ||
| 74 | top: .0365rem; | ||
| 75 | text-align: center; | ||
| 76 | margin-bottom: .0521rem; | ||
| 77 | } | ||
| 78 | .brokenline { | ||
| 79 | margin: auto; | ||
| 80 | width: 100%; | 59 | width: 100%; |
| 60 | background: url("~@/image/sjqs.png") no-repeat; | ||
| 61 | background-size: 100% 100%; | ||
| 62 | position: relative; | ||
| 63 | flex: 1; | ||
| 64 | |||
| 65 | .title { | ||
| 66 | position: absolute; | ||
| 67 | font-weight: bold; | ||
| 68 | color: #02d9fd; | ||
| 69 | line-height: 0.1354rem; | ||
| 70 | font-size: 0.1146rem; | ||
| 71 | position: absolute; | ||
| 72 | left: 0; | ||
| 73 | right: 0; | ||
| 74 | top: 0.0365rem; | ||
| 75 | text-align: center; | ||
| 76 | margin-bottom: 0.0521rem; | ||
| 77 | } | ||
| 78 | .brokenline { | ||
| 79 | margin: auto; | ||
| 80 | width: 100%; | ||
| 81 | } | ||
| 81 | } | 82 | } |
| 82 | } | 83 | } |
| 83 | } | ||
| 84 | </style> | 84 | </style> | ... | ... |
| ... | @@ -13,59 +13,57 @@ | ... | @@ -13,59 +13,57 @@ |
| 13 | <dv-decoration-5 | 13 | <dv-decoration-5 |
| 14 | :dur="1" | 14 | :dur="1" |
| 15 | class="dv-dec-5" | 15 | class="dv-dec-5" |
| 16 | :color="decorationColor" | 16 | :color="decorationColor" /> |
| 17 | /> | ||
| 18 | </div> | 17 | </div> |
| 19 | <dv-decoration-8 | 18 | <dv-decoration-8 |
| 20 | class="dv-dec-8" | 19 | class="dv-dec-8" |
| 21 | :reverse="true" | 20 | :reverse="true" |
| 22 | :color="decorationColor" | 21 | :color="decorationColor" /> |
| 23 | /> | ||
| 24 | </div> | 22 | </div> |
| 25 | <dv-decoration-10 class="dv-dec-10-s" /> | 23 | <dv-decoration-10 class="dv-dec-10-s" /> |
| 26 | </div> | 24 | </div> |
| 27 | </div> | 25 | </div> |
| 28 | <screencontent v-show="isshow"/> | 26 | <screencontent v-show="isshow" /> |
| 29 | </div> | 27 | </div> |
| 30 | </div> | 28 | </div> |
| 31 | </div> | 29 | </div> |
| 32 | </template> | 30 | </template> |
| 33 | <script> | 31 | <script> |
| 34 | import drawMixin from "@/utils/drawMixin"; | 32 | import drawMixin from "@/utils/drawMixin"; |
| 35 | import screencontent from "./screencontent"; | 33 | import screencontent from "./screencontent"; |
| 36 | export default { | 34 | export default { |
| 37 | mixins: [drawMixin], | 35 | mixins: [drawMixin], |
| 38 | data() { | 36 | data () { |
| 39 | return { | 37 | return { |
| 40 | isshow:true, | 38 | isshow: true, |
| 41 | loading: true, | 39 | loading: true, |
| 42 | decorationColor: ["#568aea", "#568aea"], | 40 | decorationColor: ["#568aea", "#568aea"], |
| 43 | }; | 41 | }; |
| 44 | }, | 42 | }, |
| 45 | components: { | 43 | components: { |
| 46 | screencontent, | 44 | screencontent, |
| 47 | }, | 45 | }, |
| 48 | mounted() { | 46 | mounted () { |
| 49 | 47 | ||
| 50 | // this.timeFn(); | 48 | // this.timeFn(); |
| 51 | this.cancelLoading(); | 49 | this.cancelLoading(); |
| 52 | }, | 50 | }, |
| 53 | beforeDestroy() { | 51 | beforeDestroy () { |
| 54 | clearInterval(this.timing); | 52 | clearInterval(this.timing); |
| 55 | }, | 53 | }, |
| 56 | methods: { | 54 | methods: { |
| 57 | cancelLoading() { | 55 | cancelLoading () { |
| 58 | setTimeout(() => { | 56 | setTimeout(() => { |
| 59 | this.loading = false; | 57 | this.loading = false; |
| 60 | }, 500); | 58 | }, 500); |
| 59 | }, | ||
| 60 | }, | ||
| 61 | computed: { | ||
| 62 | ...mapGetters(["products"]), | ||
| 61 | }, | 63 | }, |
| 62 | }, | 64 | }; |
| 63 | computed: { | ||
| 64 | ...mapGetters(["products"]), | ||
| 65 | }, | ||
| 66 | }; | ||
| 67 | </script> | 65 | </script> |
| 68 | 66 | ||
| 69 | <style scoped lang="scss"> | 67 | <style scoped lang="scss"> |
| 70 | @import "./index.scss"; | 68 | @import "./index.scss"; |
| 71 | </style> | 69 | </style> | ... | ... |
| ... | @@ -55,206 +55,197 @@ | ... | @@ -55,206 +55,197 @@ |
| 55 | 55 | ||
| 56 | <script> | 56 | <script> |
| 57 | 57 | ||
| 58 | import columnar from "@/components/Echart/Columnar"; | 58 | import columnar from "@/components/Echart/Columnar"; |
| 59 | import work from "@/api/work"; | 59 | import work from "@/api/work"; |
| 60 | export default { | 60 | export default { |
| 61 | data () { | 61 | data () { |
| 62 | return { | 62 | return { |
| 63 | // 日均接入量 | 63 | // 日均接入量 |
| 64 | qxerrer: "", | 64 | qxerrer: "", |
| 65 | qxsuccess: "", | 65 | qxsuccess: "", |
| 66 | sterrer: "", | 66 | sterrer: "", |
| 67 | stsuccess: "", | 67 | stsuccess: "", |
| 68 | qxjrl: "", | 68 | qxjrl: "", |
| 69 | stjrl: "", | 69 | stjrl: "", |
| 70 | qxcgl: "", | 70 | qxcgl: "", |
| 71 | stcgl: "" | 71 | stcgl: "" |
| 72 | }; | 72 | }; |
| 73 | }, | ||
| 74 | mounted () { | ||
| 75 | this.getsthjqxjrtotal(); | ||
| 76 | }, | ||
| 77 | components: { columnar }, | ||
| 78 | computed: { | ||
| 79 | qxjrlList: function () { | ||
| 80 | return this.qxjrl && this.qxjrl.toString().split(""); | ||
| 81 | }, | 73 | }, |
| 82 | stjrlList: function () { | 74 | mounted () { |
| 83 | return this.stjrl && this.stjrl.toString().split(""); | 75 | this.getsthjqxjrtotal(); |
| 84 | }, | 76 | }, |
| 85 | }, | 77 | components: { columnar }, |
| 86 | methods: { | 78 | computed: { |
| 87 | getsthjqxjrtotal () { | 79 | qxjrlList: function () { |
| 88 | return new Promise(async (resolve) => { | 80 | return this.qxjrl && this.qxjrl.toString().split(""); |
| 89 | try { | 81 | }, |
| 90 | let p = { | 82 | stjrlList: function () { |
| 91 | DJLX: "", | 83 | return this.stjrl && this.stjrl.toString().split(""); |
| 92 | QLLX: "", | 84 | }, |
| 93 | XZQDM: "", | 85 | }, |
| 94 | }; | 86 | methods: { |
| 95 | let res = await work.getsthjqxjrtotal(p); | 87 | getsthjqxjrtotal () { |
| 96 | this.stjrl=res.result.stsum | 88 | return new Promise(async (resolve) => { |
| 97 | this.qxjrl=res.result.qxsum | 89 | try { |
| 98 | this.qxerrer=Number(res.result.qxjrerrer) | 90 | let p = { |
| 99 | this.sterrer=Number(res.result.sthjerrer) | 91 | DJLX: "", |
| 100 | if(res.result.sum=="0"){ | 92 | QLLX: "", |
| 101 | this.qxcgl="100%" | 93 | XZQDM: "", |
| 102 | this.stcgl="100%" | 94 | }; |
| 103 | }else{ | 95 | let res = await work.getsthjqxjrtotal(p); |
| 104 | let qxcglnum=Number(res.result.qxjrsuccess)/this.qxjrl*100 | 96 | this.stjrl = res.result.stsum |
| 105 | let stcgl=Number(res.result.sthjsuccess)/this.qxjrl*100 | 97 | this.qxjrl = res.result.qxsum |
| 106 | this.qxcgl=qxcglnum.toFixed(2)+"%"; | 98 | this.qxerrer = Number(res.result.qxjrerrer) |
| 107 | this.stcgl=stcgl.toFixed(2)+"%"; | 99 | this.sterrer = Number(res.result.sthjerrer) |
| 108 | 100 | if (res.result.sum == "0") { | |
| 101 | this.qxcgl = "100%" | ||
| 102 | this.stcgl = "100%" | ||
| 103 | } else { | ||
| 104 | let qxcglnum = Number(res.result.qxjrsuccess) / this.qxjrl * 100 | ||
| 105 | let stcgl = Number(res.result.sthjsuccess) / this.qxjrl * 100 | ||
| 106 | this.qxcgl = qxcglnum.toFixed(2) + "%"; | ||
| 107 | this.stcgl = stcgl.toFixed(2) + "%"; | ||
| 108 | |||
| 109 | } | ||
| 110 | } catch (error) { | ||
| 111 | this.$refs.msg.messageShow(); | ||
| 109 | } | 112 | } |
| 110 | } catch (error) { | 113 | }); |
| 111 | this.$refs.msg.messageShow(); | 114 | }, |
| 112 | } | ||
| 113 | }); | ||
| 114 | }, | 115 | }, |
| 115 | }, | 116 | }; |
| 116 | }; | ||
| 117 | </script> | 117 | </script> |
| 118 | 118 | ||
| 119 | <style lang="scss" scoped> | 119 | <style lang="scss" scoped> |
| 120 | .leftcard { | 120 | .leftcard { |
| 121 | width: 32%; | 121 | width: 32%; |
| 122 | height: calc(100vh -114px); | ||
| 123 | display: flex; | ||
| 124 | flex-direction: column; | ||
| 125 | |||
| 126 | .card { | ||
| 127 | background: url("~@/image/qxjr.png") no-repeat; | ||
| 128 | background-size: 100% 100%; | ||
| 129 | position: relative; | ||
| 130 | text-align: center; | ||
| 131 | width: 100%; | ||
| 132 | height: 22%; | ||
| 133 | } | ||
| 134 | .carda { | ||
| 135 | background: url("~@/image/sthj.png") no-repeat; | ||
| 136 | background-size: 100% 100%; | ||
| 137 | position: relative; | ||
| 138 | text-align: center; | ||
| 139 | width: 100%; | ||
| 140 | height: 22%; | ||
| 141 | } | ||
| 142 | |||
| 143 | // .card1 { | ||
| 144 | // background: url("~@/image/sbtj.png") no-repeat; | ||
| 145 | // background-size: 100% 100%; | ||
| 146 | // position: relative; | ||
| 147 | // text-align: center; | ||
| 148 | // width: 100%; | ||
| 149 | // padding: .0417rem 0; | ||
| 150 | // height: 49%; | ||
| 151 | // } | ||
| 152 | |||
| 153 | .card1 { | ||
| 154 | background: url("~@/image/sbtj.png") no-repeat; | ||
| 155 | background-size: 100% 100%; | ||
| 156 | position: relative; | ||
| 157 | box-sizing: border-box; | ||
| 158 | flex: 1; | ||
| 159 | height: 56%; | ||
| 160 | } | ||
| 161 | |||
| 162 | .cardhead { | ||
| 163 | color: #02d9fd; | ||
| 164 | line-height: .125rem; | ||
| 165 | letter-spacing: .0104rem; | ||
| 166 | position: absolute; | ||
| 167 | font-size: .1042rem; | ||
| 168 | left: 0; | ||
| 169 | right: 0; | ||
| 170 | margin: auto; | ||
| 171 | text-align: center; | ||
| 172 | top: 8px; | ||
| 173 | font-weight: 700; | ||
| 174 | } | ||
| 175 | |||
| 176 | .rjjrlList { | ||
| 177 | display: flex; | 122 | display: flex; |
| 178 | margin-top: .01781rem; | 123 | height: calc(100vh - 114px); |
| 124 | flex-direction: column; | ||
| 179 | 125 | ||
| 180 | .qxjr { | 126 | .card { |
| 181 | background: url("~@/image/jrl3.png"); | 127 | height: 22%; |
| 128 | background: url("~@/image/qxjr.png") no-repeat; | ||
| 182 | background-size: 100% 100%; | 129 | background-size: 100% 100%; |
| 130 | position: relative; | ||
| 131 | text-align: center; | ||
| 132 | width: 100%; | ||
| 183 | } | 133 | } |
| 184 | 134 | .carda { | |
| 185 | .sthj { | 135 | height: 22%; |
| 186 | background: url("~@/image/jh.png"); | 136 | background: url("~@/image/sthj.png") no-repeat; |
| 187 | background-size: 100% 100%; | 137 | background-size: 100% 100%; |
| 188 | } | 138 | position: relative; |
| 189 | 139 | text-align: center; | |
| 190 | p { | 140 | width: 100%; |
| 191 | margin: 0 .0156rem .0521rem .0156rem; | ||
| 192 | font-weight: 700; | ||
| 193 | width: .195rem; | ||
| 194 | height: .2475rem; | ||
| 195 | font-size: .2863rem; | ||
| 196 | font-size: .2867rem; | ||
| 197 | } | 141 | } |
| 198 | } | ||
| 199 | 142 | ||
| 200 | .cardcontent { | 143 | .card1 { |
| 201 | width: 100%; | 144 | background: url("~@/image/sbtj.png") no-repeat; |
| 202 | height: 100%; | 145 | background-size: 100% 100%; |
| 203 | display: flex; | ||
| 204 | // padding: 35px 20px 20px 20px; | ||
| 205 | box-sizing: border-box; | ||
| 206 | color: #e3f1ff; | ||
| 207 | margin-top: .1263rem; | ||
| 208 | |||
| 209 | .cardcontent-left { | ||
| 210 | width: 60%; | ||
| 211 | flex-direction: column; | ||
| 212 | position: relative; | 146 | position: relative; |
| 213 | li{ | 147 | box-sizing: border-box; |
| 214 | font-size: .1042rem; | 148 | flex: 1; |
| 215 | } | ||
| 216 | } | 149 | } |
| 217 | 150 | ||
| 218 | .cardcontent-left::before { | 151 | .cardhead { |
| 152 | color: #02d9fd; | ||
| 153 | line-height: 0.125rem; | ||
| 154 | letter-spacing: 0.0104rem; | ||
| 219 | position: absolute; | 155 | position: absolute; |
| 156 | font-size: 0.1042rem; | ||
| 157 | left: 0; | ||
| 220 | right: 0; | 158 | right: 0; |
| 221 | top: .3042rem; | 159 | margin: auto; |
| 222 | content: ""; | 160 | text-align: center; |
| 223 | width: .0052rem; | 161 | top: 8px; |
| 224 | height: .4688rem; | 162 | font-weight: 700; |
| 225 | background: linear-gradient(180deg, | ||
| 226 | #091b4c 0%, | ||
| 227 | #47b5e0 56%, | ||
| 228 | #091b4c 100%); | ||
| 229 | } | 163 | } |
| 230 | 164 | ||
| 231 | .cardcontent-right { | 165 | .rjjrlList { |
| 232 | flex: 1; | 166 | display: flex; |
| 233 | width: 100%; | 167 | margin-top: 0.01781rem; |
| 234 | flex-direction: column; | ||
| 235 | font-size: .0833rem; | ||
| 236 | 168 | ||
| 237 | .bad { | 169 | .qxjr { |
| 238 | color: #c97168; | 170 | background: url("~@/image/jrl3.png"); |
| 171 | background-size: 100% 100%; | ||
| 239 | } | 172 | } |
| 240 | 173 | ||
| 241 | .cg { | 174 | .sthj { |
| 242 | color: #5fba7d; | 175 | background: url("~@/image/jh.png"); |
| 176 | background-size: 100% 100%; | ||
| 243 | } | 177 | } |
| 244 | 178 | ||
| 245 | p { | 179 | p { |
| 246 | margin-bottom: .0417rem; | 180 | margin: 0 0.0156rem 0.0521rem 0.0156rem; |
| 181 | font-weight: 700; | ||
| 182 | width: 0.195rem; | ||
| 183 | height: 0.2475rem; | ||
| 184 | font-size: 0.2863rem; | ||
| 185 | font-size: 0.2867rem; | ||
| 186 | } | ||
| 187 | } | ||
| 188 | |||
| 189 | .cardcontent { | ||
| 190 | width: 100%; | ||
| 191 | height: 100%; | ||
| 192 | display: flex; | ||
| 193 | // padding: 35px 20px 20px 20px; | ||
| 194 | box-sizing: border-box; | ||
| 195 | color: #e3f1ff; | ||
| 196 | margin-top: 0.1263rem; | ||
| 197 | |||
| 198 | .cardcontent-left { | ||
| 199 | width: 60%; | ||
| 200 | flex-direction: column; | ||
| 201 | position: relative; | ||
| 202 | li { | ||
| 203 | font-size: 0.1042rem; | ||
| 204 | } | ||
| 205 | } | ||
| 206 | |||
| 207 | .cardcontent-left::before { | ||
| 208 | position: absolute; | ||
| 209 | right: 0; | ||
| 210 | top: 0.3042rem; | ||
| 211 | content: ""; | ||
| 212 | width: 0.0052rem; | ||
| 213 | height: 0.4688rem; | ||
| 214 | background: linear-gradient( | ||
| 215 | 180deg, | ||
| 216 | #091b4c 0%, | ||
| 217 | #47b5e0 56%, | ||
| 218 | #091b4c 100% | ||
| 219 | ); | ||
| 220 | } | ||
| 221 | |||
| 222 | .cardcontent-right { | ||
| 223 | flex: 1; | ||
| 224 | width: 100%; | ||
| 225 | flex-direction: column; | ||
| 226 | font-size: 0.0833rem; | ||
| 247 | 227 | ||
| 248 | span:nth-child(1) { | 228 | .bad { |
| 249 | margin-right: .0781rem; | 229 | color: #c97168; |
| 250 | } | 230 | } |
| 251 | 231 | ||
| 252 | span:nth-child(2) { | 232 | .cg { |
| 253 | font-size: .1042rem; | 233 | color: #5fba7d; |
| 254 | font-weight: 900; | 234 | } |
| 235 | |||
| 236 | p { | ||
| 237 | margin-bottom: 0.0417rem; | ||
| 238 | |||
| 239 | span:nth-child(1) { | ||
| 240 | margin-right: 0.0781rem; | ||
| 241 | } | ||
| 242 | |||
| 243 | span:nth-child(2) { | ||
| 244 | font-size: 0.1042rem; | ||
| 245 | font-weight: 900; | ||
| 246 | } | ||
| 255 | } | 247 | } |
| 256 | } | 248 | } |
| 257 | } | 249 | } |
| 258 | } | 250 | } |
| 259 | } | ||
| 260 | </style> | 251 | </style> | ... | ... |
| ... | @@ -19,131 +19,136 @@ | ... | @@ -19,131 +19,136 @@ |
| 19 | </template> | 19 | </template> |
| 20 | 20 | ||
| 21 | <script> | 21 | <script> |
| 22 | import columnarsmat from "@/components/Echart/Columnarsmat"; | 22 | import columnarsmat from "@/components/Echart/Columnarsmat"; |
| 23 | import Rose from "@/components/Echart/Rose"; | 23 | import Rose from "@/components/Echart/Rose"; |
| 24 | import work from "@/api/work"; | 24 | import work from "@/api/work"; |
| 25 | export default { | 25 | export default { |
| 26 | data () { | 26 | data () { |
| 27 | return { | 27 | return { |
| 28 | config: { | 28 | config: { |
| 29 | headerBGC: '#016AC5', | 29 | headerBGC: '#016AC5', |
| 30 | oddRowBGC: '#154295', | 30 | oddRowBGC: '#154295', |
| 31 | evenRowBGC: '#154295', | 31 | evenRowBGC: '#154295', |
| 32 | header: ['序号', '用途', '性质', '面积'], | 32 | header: ['序号', '用途', '性质', '面积'], |
| 33 | data: [], | 33 | data: [], |
| 34 | key: 0 | 34 | key: 0 |
| 35 | } | ||
| 35 | } | 36 | } |
| 36 | } | 37 | }, |
| 37 | }, | 38 | components: { columnarsmat, Rose }, |
| 38 | components: { columnarsmat, Rose }, | 39 | mounted () { |
| 39 | mounted () { | 40 | this.addhousetotal(); |
| 40 | this.addhousetotal(); | 41 | // scroll(tableref.value.$refs.bodyWrapper);//设置滚动 |
| 41 | // scroll(tableref.value.$refs.bodyWrapper);//设置滚动 | 42 | }, |
| 42 | }, | 43 | methods: { |
| 43 | methods: { | 44 | async addhousetotal () { |
| 44 | async addhousetotal () { | 45 | try { |
| 45 | try { | 46 | let { result: res } = await work.addhousetotal(); |
| 46 | let { result: res } = await work.addhousetotal(); | 47 | res.map((item, index) => { |
| 47 | res.map((item, index) => { | 48 | return ( |
| 48 | return ( | 49 | this.config.data.push([index, item.fwyt, item.fwxz, item.mj]) |
| 49 | this.config.data.push([index, item.fwyt, item.fwxz, item.mj]) | 50 | ) |
| 50 | ) | 51 | }); |
| 51 | }); | 52 | } catch (error) { |
| 52 | } catch (error) { | 53 | console.log("error", error); |
| 53 | console.log("error", error); | 54 | } |
| 54 | } | 55 | } |
| 55 | } | 56 | } |
| 56 | } | 57 | } |
| 57 | } | ||
| 58 | </script> | 58 | </script> |
| 59 | <style lang="scss" scoped> | 59 | <style lang="scss" scoped> |
| 60 | /deep/.row-item:not(:last-child) { | 60 | /deep/.row-item:not(:last-child) { |
| 61 | margin-bottom: .026rem; | 61 | margin-bottom: 0.026rem; |
| 62 | } | ||
| 63 | |||
| 64 | .rightcard { | ||
| 65 | width: 32%; | ||
| 66 | display: flex; | ||
| 67 | height: calc(100vh - 114px); | ||
| 68 | flex-direction: column; | ||
| 69 | |||
| 70 | .cardhead { | ||
| 71 | font-size: .1042rem; | ||
| 72 | font-weight: bold; | ||
| 73 | color: #02D9FD; | ||
| 74 | text-align: center; | ||
| 75 | position: absolute; | ||
| 76 | left: 0; | ||
| 77 | right: 0; | ||
| 78 | top: .0625rem; | ||
| 79 | text-align: center; | ||
| 80 | } | 62 | } |
| 81 | 63 | ||
| 82 | .cardcontent { | 64 | .rightcard { |
| 83 | width: 100%; | 65 | width: 32%; |
| 84 | height: 100%; | 66 | display: flex; |
| 85 | display: -webkit-box; | 67 | height: calc(100vh - 114px); |
| 86 | overflow: hidden; | 68 | flex-direction: column; |
| 87 | 69 | ||
| 88 | .nodata { | 70 | .cardhead { |
| 89 | font-size: .1042rem; | 71 | font-size: 0.1042rem; |
| 90 | color: #02D9FD; | ||
| 91 | font-weight: bold; | 72 | font-weight: bold; |
| 92 | margin: auto; | 73 | color: #02d9fd; |
| 93 | margin-top: 120px; | 74 | text-align: center; |
| 75 | position: absolute; | ||
| 76 | left: 0; | ||
| 77 | right: 0; | ||
| 78 | top: 0.0625rem; | ||
| 79 | text-align: center; | ||
| 94 | } | 80 | } |
| 95 | } | ||
| 96 | 81 | ||
| 97 | .cardCon { | 82 | .cardcontent { |
| 98 | padding: .0521rem .026rem; | 83 | width: 100%; |
| 99 | position: relative; | 84 | height: 100%; |
| 100 | text-align: center; | 85 | display: -webkit-box; |
| 101 | width: 100%; | 86 | overflow: hidden; |
| 102 | } | 87 | |
| 88 | .nodata { | ||
| 89 | font-size: 0.1042rem; | ||
| 90 | color: #02d9fd; | ||
| 91 | font-weight: bold; | ||
| 92 | margin: auto; | ||
| 93 | margin-top: 120px; | ||
| 94 | } | ||
| 95 | } | ||
| 103 | 96 | ||
| 104 | .card1 { | 97 | .cardCon { |
| 105 | height: 33%; | 98 | padding: 0.0521rem 0.026rem; |
| 106 | background: url("~@/image/xjgyfwxx.png") no-repeat; | 99 | position: relative; |
| 107 | background-size: 100% 100%; | 100 | text-align: center; |
| 101 | width: 100%; | ||
| 102 | } | ||
| 108 | 103 | ||
| 109 | .board { | 104 | .card1 { |
| 110 | width: 90%; | 105 | height: 33%; |
| 111 | margin: 0 auto; | 106 | background: url("~@/image/xjgyfwxx.png") no-repeat; |
| 112 | height: 1.1031rem; | 107 | background-size: 100% 100%; |
| 113 | margin-top: .0521rem; | 108 | /deep/.dv-scroll-board { |
| 114 | /deep/.header{ | 109 | .header { |
| 115 | font-size: .0738rem; | 110 | height: 0.1875rem; |
| 111 | align-items: center; | ||
| 112 | } | ||
| 116 | } | 113 | } |
| 117 | /deep/.rows{ | 114 | .board { |
| 118 | .ceil{ | 115 | width: 90%; |
| 119 | font-size: .0738rem; | 116 | margin: 0 auto; |
| 120 | color: #6BC1FC | 117 | height: 1.1031rem; |
| 121 | } | 118 | margin-top: 0.0521rem; |
| 119 | /deep/.header { | ||
| 120 | font-size: 0.0738rem; | ||
| 121 | } | ||
| 122 | /deep/.rows { | ||
| 123 | .ceil { | ||
| 124 | font-size: 0.0738rem; | ||
| 125 | color: #6bc1fc; | ||
| 126 | } | ||
| 127 | } | ||
| 122 | } | 128 | } |
| 123 | } | 129 | } |
| 124 | } | ||
| 125 | 130 | ||
| 126 | .card2 { | 131 | .card2 { |
| 127 | height: 33%; | 132 | height: 33%; |
| 128 | background: url("~@/image/djywl.png") no-repeat; | 133 | background: url("~@/image/djywl.png") no-repeat; |
| 129 | background-size: 100% 100%; | 134 | background-size: 100% 100%; |
| 130 | padding: .3825rem 0 0 0; | 135 | padding: 0.3825rem 0 0 0; |
| 131 | } | 136 | } |
| 132 | 137 | ||
| 133 | .card3 { | 138 | .card3 { |
| 134 | height: 33%; | 139 | height: 33%; |
| 135 | flex: 1; | 140 | flex: 1; |
| 136 | background: url("~@/image/djlxzl.png") no-repeat; | 141 | background: url("~@/image/djlxzl.png") no-repeat; |
| 137 | background-size: 100% 100%; | 142 | background-size: 100% 100%; |
| 138 | padding-bottom: 0; | 143 | padding-bottom: 0; |
| 139 | 144 | ||
| 140 | .cardhead { | 145 | .cardhead { |
| 141 | top: .0417rem; | 146 | top: 0.0417rem; |
| 147 | } | ||
| 142 | } | 148 | } |
| 143 | } | ||
| 144 | 149 | ||
| 145 | .cardhead { | 150 | .cardhead { |
| 146 | position: absolute; | 151 | position: absolute; |
| 152 | } | ||
| 147 | } | 153 | } |
| 148 | } | ||
| 149 | </style> | 154 | </style> | ... | ... |
This diff is collapsed.
Click to expand it.
| ... | @@ -142,8 +142,8 @@ | ... | @@ -142,8 +142,8 @@ |
| 142 | padding: 24px 120px 0px; | 142 | padding: 24px 120px 0px; |
| 143 | .el-form-item { | 143 | .el-form-item { |
| 144 | margin-bottom: 24px; | 144 | margin-bottom: 24px; |
| 145 | .el-form-item__label { | 145 | /deep/.el-form-item__label { |
| 146 | color: #747e8c; | 146 | color: #ffffff; |
| 147 | } | 147 | } |
| 148 | ::v-deep .el-input .el-input__inner { | 148 | ::v-deep .el-input .el-input__inner { |
| 149 | padding: 0 8px; | 149 | padding: 0 8px; | ... | ... |
| ... | @@ -15,8 +15,8 @@ | ... | @@ -15,8 +15,8 @@ |
| 15 | </div> | 15 | </div> |
| 16 | <div class="from-clues-content"> | 16 | <div class="from-clues-content"> |
| 17 | <div class="contentbox"> | 17 | <div class="contentbox"> |
| 18 | <base-set v-show="isshow" :userInfo="userData" /> | 18 | <base-set v-if="isshow" :userInfo="userData" /> |
| 19 | <password-edit v-show="!isshow" :userInfo="userData" /> | 19 | <password-edit v-if="!isshow" :userInfo="userData" /> |
| 20 | </div> | 20 | </div> |
| 21 | </div> | 21 | </div> |
| 22 | </div> | 22 | </div> | ... | ... |
| ... | @@ -110,10 +110,10 @@ | ... | @@ -110,10 +110,10 @@ |
| 110 | overflow-y: auto; | 110 | overflow-y: auto; |
| 111 | .form-wrapper { | 111 | .form-wrapper { |
| 112 | padding: 24px 120px 0px; | 112 | padding: 24px 120px 0px; |
| 113 | .el-form-item { | 113 | /deep/.el-form-item { |
| 114 | margin-bottom: 24px; | 114 | margin-bottom: 24px; |
| 115 | .el-form-item__label { | 115 | .el-form-item__label { |
| 116 | color: #747e8c; | 116 | color: #ffffff; |
| 117 | } | 117 | } |
| 118 | ::v-deep .el-input .el-input__inner { | 118 | ::v-deep .el-input .el-input__inner { |
| 119 | padding: 0 8px; | 119 | padding: 0 8px; | ... | ... |
| ... | @@ -30,8 +30,8 @@ | ... | @@ -30,8 +30,8 @@ |
| 30 | 30 | ||
| 31 | </el-row> | 31 | </el-row> |
| 32 | <el-row :gutter="24"> | 32 | <el-row :gutter="24"> |
| 33 | <el-col :span="12"> | 33 | <el-col :span="24"> |
| 34 | <el-form-item label="代码:" prop="code" label-width="54px"> | 34 | <el-form-item label="代码:" prop="code" label-width="124px"> |
| 35 | <el-input | 35 | <el-input |
| 36 | v-model="codeComputed" | 36 | v-model="codeComputed" |
| 37 | placeholder="请输入菜单代码" | 37 | placeholder="请输入菜单代码" |
| ... | @@ -272,4 +272,5 @@ | ... | @@ -272,4 +272,5 @@ |
| 272 | /deep/.el-input__inner { | 272 | /deep/.el-input__inner { |
| 273 | background-color: #07388b; | 273 | background-color: #07388b; |
| 274 | } | 274 | } |
| 275 | |||
| 275 | </style> | 276 | </style> | ... | ... |
src/views/system/roles/data/roles.js
deleted
100644 → 0
| 1 | import filter from '@/utils/filter.js' | ||
| 2 | class data extends filter { | ||
| 3 | constructor() { | ||
| 4 | super() | ||
| 5 | } | ||
| 6 | columns () { | ||
| 7 | return [ | ||
| 8 | { | ||
| 9 | prop: "name", | ||
| 10 | label: "角色名称", | ||
| 11 | width: 330 | ||
| 12 | }, | ||
| 13 | { | ||
| 14 | prop: "type", | ||
| 15 | label: "类别", | ||
| 16 | width: 400 | ||
| 17 | }, | ||
| 18 | { | ||
| 19 | prop: "address", | ||
| 20 | label: "备注" | ||
| 21 | } | ||
| 22 | ] | ||
| 23 | } | ||
| 24 | } | ||
| 25 | export default new data() |
| ... | @@ -4,39 +4,36 @@ | ... | @@ -4,39 +4,36 @@ |
| 4 | :title="dialogTitle" | 4 | :title="dialogTitle" |
| 5 | :show.sync="showAddEditDialog" | 5 | :show.sync="showAddEditDialog" |
| 6 | :width="'767px'" | 6 | :width="'767px'" |
| 7 | @close="handleCloseDialog()" | 7 | @close="handleCloseDialog()"> |
| 8 | > | ||
| 9 | <template slot="content"> | 8 | <template slot="content"> |
| 10 | <el-form ref="form" :model="dialogForm" :rules="rules" label-width="82px"> | 9 | <el-form ref="form" :model="dialogForm" :rules="rules" label-width="82px"> |
| 11 | <el-row :gutter="24"> | 10 | <el-row :gutter="24"> |
| 12 | <el-col :span="12"> | 11 | <el-col :span="15"> |
| 13 | <el-form-item label="角色名称:" prop="roleName"> | 12 | <el-form-item label="角色名称:" prop="roleName"> |
| 14 | <el-input | 13 | <el-input |
| 15 | v-model="dialogForm.roleName" | 14 | v-model="dialogForm.roleName" |
| 16 | clearable | 15 | clearable |
| 17 | placeholder="角色名称" | 16 | placeholder="角色名称" /> |
| 18 | /> | ||
| 19 | </el-form-item> | 17 | </el-form-item> |
| 20 | </el-col> | 18 | </el-col> |
| 21 | <el-col :span="12"> | 19 | </el-row> |
| 20 | <el-row :gutter="24"> | ||
| 21 | <el-col :span="24"> | ||
| 22 | <el-form-item label="角色类型:" prop="roleType"> | 22 | <el-form-item label="角色类型:" prop="roleType"> |
| 23 | <el-input | 23 | <el-input |
| 24 | v-model="dialogForm.roleType" | 24 | v-model="dialogForm.roleType" |
| 25 | clearable | 25 | clearable |
| 26 | placeholder="角色类型" | 26 | placeholder="角色类型" /> |
| 27 | /> | ||
| 28 | </el-form-item> | 27 | </el-form-item> |
| 29 | </el-col> | 28 | </el-col> |
| 30 | </el-row> | 29 | </el-row> |
| 31 | <br> | ||
| 32 | <el-row> | 30 | <el-row> |
| 33 | <el-col :span="24"> | 31 | <el-col :span="24"> |
| 34 | <el-form-item label="备注:" class="form-item-mb0"> | 32 | <el-form-item label="备注:" class="form-item-mb0"> |
| 35 | <el-input | 33 | <el-input |
| 36 | v-model="dialogForm.roleTextArea" | 34 | v-model="dialogForm.roleTextArea" |
| 37 | type="textarea" | 35 | type="textarea" |
| 38 | placeholder="备注" | 36 | placeholder="备注" /> |
| 39 | /> | ||
| 40 | </el-form-item> | 37 | </el-form-item> |
| 41 | </el-col> | 38 | </el-col> |
| 42 | </el-row> | 39 | </el-row> |
| ... | @@ -45,72 +42,89 @@ | ... | @@ -45,72 +42,89 @@ |
| 45 | <template slot="footer"> | 42 | <template slot="footer"> |
| 46 | <el-button | 43 | <el-button |
| 47 | class="cancel-button" | 44 | class="cancel-button" |
| 48 | @click="handleCloseDialog" | 45 | @click="handleCloseDialog">取消</el-button> |
| 49 | >取消</el-button> | ||
| 50 | 46 | ||
| 51 | <el-button | 47 | <el-button |
| 52 | type="primary" | 48 | type="primary" |
| 53 | @click="handleSaveRole()" | 49 | @click="handleSaveRole()">保存</el-button> |
| 54 | >保存</el-button> | ||
| 55 | </template> | 50 | </template> |
| 56 | </Dialog> | 51 | </Dialog> |
| 57 | </template> | 52 | </template> |
| 58 | 53 | ||
| 59 | <script> | 54 | <script> |
| 60 | import Dialog from "@/components/Dialog/"; | 55 | import Dialog from "@/components/Dialog/"; |
| 61 | import { api, httpAction } from '@/api/manageApi' | 56 | import { api, httpAction } from '@/api/manageApi' |
| 62 | export default { | 57 | export default { |
| 63 | components: { | 58 | components: { |
| 64 | Dialog | 59 | Dialog |
| 65 | }, | 60 | }, |
| 66 | data() { | 61 | data () { |
| 67 | return { | 62 | return { |
| 68 | dialogTitle: '', | 63 | dialogTitle: '', |
| 69 | showAddEditDialog: false, | 64 | showAddEditDialog: false, |
| 70 | menuType: '', | 65 | menuType: '', |
| 71 | roleId: '', | 66 | roleId: '', |
| 72 | sort: 0, | 67 | sort: 0, |
| 73 | dialogForm: { | 68 | dialogForm: { |
| 74 | roleName: '', | 69 | roleName: '', |
| 75 | roleType: '', | 70 | roleType: '', |
| 76 | roleTextArea: '' | 71 | roleTextArea: '' |
| 77 | }, | 72 | }, |
| 78 | rules: { | 73 | rules: { |
| 79 | roleName: [ | 74 | roleName: [ |
| 80 | { required: true, message: '请输入角色名称', trigger: 'blur' } | 75 | { required: true, message: '请输入角色名称', trigger: 'blur' } |
| 81 | ], | 76 | ], |
| 82 | roleType: [ | 77 | roleType: [ |
| 83 | { required: true, message: '请输入角色类型', trigger: 'blur' } | 78 | { required: true, message: '请输入角色类型', trigger: 'blur' } |
| 79 | ] | ||
| 80 | }, | ||
| 81 | roleTypeOptions: [ | ||
| 82 | { name: '定制', value: '定制' }, | ||
| 83 | { name: '其他', value: '其他' } | ||
| 84 | ] | 84 | ] |
| 85 | }, | 85 | } |
| 86 | roleTypeOptions: [ | 86 | }, |
| 87 | { name: '定制', value: '定制' }, | 87 | methods: { |
| 88 | { name: '其他', value: '其他' } | 88 | // 保存新增或关闭事件 |
| 89 | ] | 89 | handleSaveRole (val) { |
| 90 | } | 90 | this.$refs.form.validate((valid) => { |
| 91 | }, | 91 | if (valid) { |
| 92 | methods: { | 92 | try { |
| 93 | // 保存新增或关闭事件 | 93 | const params = { |
| 94 | handleSaveRole(val) { | 94 | category: 2, |
| 95 | this.$refs.form.validate((valid) => { | 95 | description: this.dialogForm.roleTextArea, |
| 96 | if (valid) { | 96 | name: this.dialogForm.roleName, |
| 97 | try { | 97 | sort: this.sort, |
| 98 | const params = { | 98 | type: this.dialogForm.roleType |
| 99 | category: 2, | 99 | } |
| 100 | description: this.dialogForm.roleTextArea, | 100 | if (this.roleId) { |
| 101 | name: this.dialogForm.roleName, | 101 | params.id = this.roleId |
| 102 | sort: this.sort, | 102 | httpAction(`${api.roles}/${params.id}`, params, 'post').then( |
| 103 | type: this.dialogForm.roleType | 103 | (res) => { |
| 104 | } | 104 | if (res.status === 1) { |
| 105 | console.log("this.roleId",this.roleId); | 105 | this.$message.success({ |
| 106 | if (this.roleId) { | 106 | message: '修改成功', |
| 107 | params.id = this.roleId | 107 | showClose: true |
| 108 | console.log("修改",params.id,params); | 108 | }) |
| 109 | httpAction(`${api.roles}/${params.id}`, params, 'post').then( | 109 | this.dialogForm = { |
| 110 | (res) => { | 110 | roleName: '', |
| 111 | roleType: '' | ||
| 112 | } | ||
| 113 | this.showAddEditDialog = val | ||
| 114 | this.$emit('ok', this.menuType) | ||
| 115 | } else { | ||
| 116 | this.$message.error({ | ||
| 117 | message: res.message, | ||
| 118 | showClose: true | ||
| 119 | }) | ||
| 120 | } | ||
| 121 | } | ||
| 122 | ) | ||
| 123 | } else { | ||
| 124 | httpAction(api.roles, params, 'post').then((res) => { | ||
| 111 | if (res.status === 1) { | 125 | if (res.status === 1) { |
| 112 | this.$message.success({ | 126 | this.$message.success({ |
| 113 | message: '修改成功', | 127 | message: '新增成功', |
| 114 | showClose: true | 128 | showClose: true |
| 115 | }) | 129 | }) |
| 116 | this.dialogForm = { | 130 | this.dialogForm = { |
| ... | @@ -125,58 +139,49 @@ export default { | ... | @@ -125,58 +139,49 @@ export default { |
| 125 | showClose: true | 139 | showClose: true |
| 126 | }) | 140 | }) |
| 127 | } | 141 | } |
| 128 | } | 142 | }) |
| 129 | ) | 143 | } |
| 130 | } else { | 144 | } catch (e) { |
| 131 | httpAction(api.roles, params, 'post').then((res) => { | 145 | console.error(e) |
| 132 | if (res.status === 1) { | ||
| 133 | this.$message.success({ | ||
| 134 | message: '新增成功', | ||
| 135 | showClose: true | ||
| 136 | }) | ||
| 137 | this.dialogForm = { | ||
| 138 | roleName: '', | ||
| 139 | roleType: '' | ||
| 140 | } | ||
| 141 | this.showAddEditDialog = val | ||
| 142 | this.$emit('ok', this.menuType) | ||
| 143 | } else { | ||
| 144 | this.$message.error({ | ||
| 145 | message: res.message, | ||
| 146 | showClose: true | ||
| 147 | }) | ||
| 148 | } | ||
| 149 | }) | ||
| 150 | } | 146 | } |
| 151 | } catch (e) { | ||
| 152 | console.error(e) | ||
| 153 | } | 147 | } |
| 148 | }) | ||
| 149 | }, | ||
| 150 | // 取消事件 | ||
| 151 | handleCloseDialog () { | ||
| 152 | this.$refs.form.resetFields() | ||
| 153 | this.dialogForm = { | ||
| 154 | roleName: '', | ||
| 155 | roleType: '' | ||
| 154 | } | 156 | } |
| 155 | }) | 157 | this.showAddEditDialog = false |
| 156 | }, | ||
| 157 | // 取消事件 | ||
| 158 | handleCloseDialog() { | ||
| 159 | this.$refs.form.resetFields() | ||
| 160 | this.dialogForm = { | ||
| 161 | roleName: '', | ||
| 162 | roleType: '' | ||
| 163 | } | 158 | } |
| 164 | this.showAddEditDialog = false | ||
| 165 | } | 159 | } |
| 166 | } | 160 | } |
| 167 | } | ||
| 168 | </script> | 161 | </script> |
| 169 | <style scoped lang="scss"> | 162 | <style scoped lang="scss"> |
| 170 | /deep/.el-input__inner { | 163 | /deep/.el-input__inner { |
| 171 | background: #07388B; | 164 | background: #07388b; |
| 172 | border-radius: 2px; | 165 | border-radius: 2px; |
| 173 | border: 1px solid #6BC1FC; | 166 | border: 1px solid #6bc1fc; |
| 174 | } | 167 | } |
| 175 | /deep/.el-textarea__inner{ | 168 | /deep/.el-textarea__inner { |
| 176 | background: #07388B; | 169 | background: #07388b; |
| 177 | color: #fff; | 170 | color: #fff; |
| 178 | } | 171 | } |
| 179 | /deep/.el-form-item__label{ | 172 | /deep/.el-form-item__label { |
| 180 | color:#fff; | 173 | color: #fff; |
| 181 | } | 174 | } |
| 175 | /deep/.el-dialog__headerbtn { | ||
| 176 | position: absolute; | ||
| 177 | top: 15px; | ||
| 178 | right: 30px; | ||
| 179 | } | ||
| 180 | /deep/.el-dialog__header { | ||
| 181 | text-align: center; | ||
| 182 | margin-bottom: 10px; | ||
| 183 | .el-dialog__title { | ||
| 184 | color: white; | ||
| 185 | } | ||
| 186 | } | ||
| 182 | </style> | 187 | </style> | ... | ... |
| ... | @@ -14,15 +14,13 @@ | ... | @@ -14,15 +14,13 @@ |
| 14 | </div> | 14 | </div> |
| 15 | <div class="from-clues-content"> | 15 | <div class="from-clues-content"> |
| 16 | <lb-table | 16 | <lb-table |
| 17 | :page-size="pageData.size" | 17 | :pagination="false" |
| 18 | :current-page.sync="pageData.current" | ||
| 19 | :total="pageData.total" | ||
| 20 | @size-change="handleSizeChange" | 18 | @size-change="handleSizeChange" |
| 21 | @p-current-change="handleCurrentChange" | 19 | @p-current-change="handleCurrentChange" |
| 22 | :column="tableData.columns" | 20 | :column="tableData.columns" |
| 23 | :data="listdata" | 21 | :data="listdata" |
| 24 | :expand-row-keys="keyList" | 22 | :expand-row-keys="keyList" |
| 25 | row-key="id"> | 23 | row-key="dictid"> |
| 26 | </lb-table> | 24 | </lb-table> |
| 27 | </div> | 25 | </div> |
| 28 | <EditDialog ref="addEditDialog" @ok="reloadTableData" /> | 26 | <EditDialog ref="addEditDialog" @ok="reloadTableData" /> |
| ... | @@ -219,11 +217,6 @@ | ... | @@ -219,11 +217,6 @@ |
| 219 | ]), | 217 | ]), |
| 220 | data: [], | 218 | data: [], |
| 221 | }, | 219 | }, |
| 222 | pageData: { | ||
| 223 | total: 5, | ||
| 224 | pageSize: 15, | ||
| 225 | current: 1, | ||
| 226 | }, | ||
| 227 | }; | 220 | }; |
| 228 | }, | 221 | }, |
| 229 | created () { | 222 | created () { |
| ... | @@ -242,6 +235,7 @@ | ... | @@ -242,6 +235,7 @@ |
| 242 | Builtinrole = res.content; | 235 | Builtinrole = res.content; |
| 243 | getRolesById(2) | 236 | getRolesById(2) |
| 244 | .then((res) => { | 237 | .then((res) => { |
| 238 | console.log("角色列表", res); | ||
| 245 | Publicrole = res.content; | 239 | Publicrole = res.content; |
| 246 | 240 | ||
| 247 | this.listdata = Builtinrole.concat(Publicrole); | 241 | this.listdata = Builtinrole.concat(Publicrole); |
| ... | @@ -376,8 +370,6 @@ | ... | @@ -376,8 +370,6 @@ |
| 376 | } | 370 | } |
| 377 | 371 | ||
| 378 | this.$refs.rolesForm.personlist(this.waitMemberList, row.id); | 372 | this.$refs.rolesForm.personlist(this.waitMemberList, row.id); |
| 379 | // this.$refs.rolesForm.getMenuData(); | ||
| 380 | |||
| 381 | this.$refs.rolesForm.menulist(this.operationList, row.id, this.selectedSubsystemCode, this.menutablelistData, this.operationCodes); | 373 | this.$refs.rolesForm.menulist(this.operationList, row.id, this.selectedSubsystemCode, this.menutablelistData, this.operationCodes); |
| 382 | } else { | 374 | } else { |
| 383 | this.$message.error({ message: res.message, showClose: true }); | 375 | this.$message.error({ message: res.message, showClose: true }); |
| ... | @@ -402,15 +394,15 @@ | ... | @@ -402,15 +394,15 @@ |
| 402 | }, | 394 | }, |
| 403 | // 上移下移 | 395 | // 上移下移 |
| 404 | moveUpward (index, row) { | 396 | moveUpward (index, row) { |
| 405 | realMove(row.id, "UP", this.listdata); | 397 | realMove(row.dictid, "UP", this.listdata); |
| 406 | this.key++; | 398 | this.key++; |
| 407 | let id = findParents(this.listdata, row.id); | 399 | let id = findParents(this.listdata, row.dictid); |
| 408 | this.keyList = id; | 400 | this.keyList = id; |
| 409 | }, | 401 | }, |
| 410 | moveDown (index, row) { | 402 | moveDown (index, row) { |
| 411 | realMove(row.id, "DOWN", this.listdata); | 403 | realMove(row.dictid, "DOWN", this.listdata); |
| 412 | this.key++; | 404 | this.key++; |
| 413 | let id = findParents(this.listdata, row.id); | 405 | let id = findParents(this.listdata, row.dictid); |
| 414 | this.keyList = id; | 406 | this.keyList = id; |
| 415 | }, | 407 | }, |
| 416 | 408 | ... | ... |
| ... | @@ -10,7 +10,7 @@ | ... | @@ -10,7 +10,7 @@ |
| 10 | {{ title || "标题" }} | 10 | {{ title || "标题" }} |
| 11 | </div> | 11 | </div> |
| 12 | <div class="editDialogBox-box"> | 12 | <div class="editDialogBox-box"> |
| 13 | <el-tabs v-model="activeName" type="card"> | 13 | <el-tabs v-model="activeName" type="card" @tab-click="handleClick"> |
| 14 | <el-tab-pane label="人员配置" name="first"></el-tab-pane> | 14 | <el-tab-pane label="人员配置" name="first"></el-tab-pane> |
| 15 | <el-tab-pane label="菜单配置" name="second"></el-tab-pane> | 15 | <el-tab-pane label="菜单配置" name="second"></el-tab-pane> |
| 16 | </el-tabs> | 16 | </el-tabs> |
| ... | @@ -19,7 +19,7 @@ | ... | @@ -19,7 +19,7 @@ |
| 19 | ref="multipleTable" | 19 | ref="multipleTable" |
| 20 | :pagination="false" | 20 | :pagination="false" |
| 21 | :column="usertableData.column" | 21 | :column="usertableData.column" |
| 22 | :data="usertableData.data" | 22 | :data="lastuserList" |
| 23 | @selection-change="handleSelectionChange" | 23 | @selection-change="handleSelectionChange" |
| 24 | @row-click="handleClickTableRow"> | 24 | @row-click="handleClickTableRow"> |
| 25 | > | 25 | > |
| ... | @@ -27,7 +27,6 @@ | ... | @@ -27,7 +27,6 @@ |
| 27 | <lb-table | 27 | <lb-table |
| 28 | :key="menukey" | 28 | :key="menukey" |
| 29 | v-if="activeName == 'second'" | 29 | v-if="activeName == 'second'" |
| 30 | ref="multipleTable1" | ||
| 31 | :pagination="false" | 30 | :pagination="false" |
| 32 | :column="menutableData.column" | 31 | :column="menutableData.column" |
| 33 | :data="lastMenuList" | 32 | :data="lastMenuList" |
| ... | @@ -99,7 +98,6 @@ | ... | @@ -99,7 +98,6 @@ |
| 99 | label: "用户名", | 98 | label: "用户名", |
| 100 | }, | 99 | }, |
| 101 | ], | 100 | ], |
| 102 | data: [] | ||
| 103 | }, | 101 | }, |
| 104 | // 角色id | 102 | // 角色id |
| 105 | roleId: "", | 103 | roleId: "", |
| ... | @@ -107,6 +105,7 @@ | ... | @@ -107,6 +105,7 @@ |
| 107 | queryParam: {}, | 105 | queryParam: {}, |
| 108 | menukey: 0, | 106 | menukey: 0, |
| 109 | activeName: "first", | 107 | activeName: "first", |
| 108 | lastuserList: [], // 人员表格数据 | ||
| 110 | lastMenuList: [], // 重构完成的菜单表格数据 | 109 | lastMenuList: [], // 重构完成的菜单表格数据 |
| 111 | usermultipleSelection: [], | 110 | usermultipleSelection: [], |
| 112 | // 选中菜单列表 | 111 | // 选中菜单列表 |
| ... | @@ -132,8 +131,8 @@ | ... | @@ -132,8 +131,8 @@ |
| 132 | 131 | ||
| 133 | // 人员配置点击行勾选数据 | 132 | // 人员配置点击行勾选数据 |
| 134 | handleClickTableRow (row, event) { | 133 | handleClickTableRow (row, event) { |
| 135 | this.checkNum1 = 0; | 134 | this.checkNum = 0; |
| 136 | this.isCheck1 = false; | 135 | this.isCheck = false; |
| 137 | if (event.label == "操作") { | 136 | if (event.label == "操作") { |
| 138 | return; | 137 | return; |
| 139 | } else { | 138 | } else { |
| ... | @@ -163,10 +162,10 @@ | ... | @@ -163,10 +162,10 @@ |
| 163 | } | 162 | } |
| 164 | } | 163 | } |
| 165 | if (this.usermultipleSelection.length > 0) { | 164 | if (this.usermultipleSelection.length > 0) { |
| 166 | this.checkNum1 = this.usermultipleSelection.length; | 165 | this.checkNum = this.usermultipleSelection.length; |
| 167 | this.isCheck1 = true; | 166 | this.isCheck = true; |
| 168 | } else { | 167 | } else { |
| 169 | this.isCheck1 = false; | 168 | this.isCheck = false; |
| 170 | } | 169 | } |
| 171 | }, | 170 | }, |
| 172 | // 获取授权主体的菜单权限 | 171 | // 获取授权主体的菜单权限 |
| ... | @@ -304,19 +303,21 @@ | ... | @@ -304,19 +303,21 @@ |
| 304 | personlist (a, rid) { | 303 | personlist (a, rid) { |
| 305 | this.roleId = rid; | 304 | this.roleId = rid; |
| 306 | this.visible = true; | 305 | this.visible = true; |
| 307 | 306 | this.lastuserList = a; | |
| 308 | this.usertableData.data = a; | 307 | this.lastuserList.forEach((item, index) => { |
| 309 | this.usertableData.data.forEach((item, index) => { | ||
| 310 | if (item.selectStatus === 0) { | 308 | if (item.selectStatus === 0) { |
| 311 | this.$nextTick(() => { | 309 | this.$nextTick(async () => { |
| 312 | this.$refs.multipleTable.toggleRowSelection( | 310 | await this.$refs.multipleTable |
| 313 | this.usertableData.data[index], | 311 | if (this.$refs.multipleTable) { |
| 314 | true | 312 | this.$refs.multipleTable.toggleRowSelection( |
| 315 | ); | 313 | this.lastuserList[index], |
| 314 | true | ||
| 315 | ); | ||
| 316 | } | ||
| 317 | |||
| 316 | }); | 318 | }); |
| 317 | } | 319 | } |
| 318 | }); | 320 | }); |
| 319 | |||
| 320 | }, | 321 | }, |
| 321 | // 关闭事件 | 322 | // 关闭事件 |
| 322 | close () { | 323 | close () { |
| ... | @@ -351,7 +352,17 @@ | ... | @@ -351,7 +352,17 @@ |
| 351 | }, | 352 | }, |
| 352 | // 勾选人员事件 | 353 | // 勾选人员事件 |
| 353 | handleSelectionChange (val) { | 354 | handleSelectionChange (val) { |
| 355 | this.lastuserList.forEach((element, index) => { | ||
| 356 | delete this.lastuserList[index].selectStatus | ||
| 357 | }); | ||
| 354 | this.usermultipleSelection = val; | 358 | this.usermultipleSelection = val; |
| 359 | this.lastuserList.forEach((element, index) => { | ||
| 360 | this.usermultipleSelection.forEach(element1 => { | ||
| 361 | if (element.id == element1.id) { | ||
| 362 | this.lastuserList[index].selectStatus = 0 | ||
| 363 | } | ||
| 364 | }); | ||
| 365 | }); | ||
| 355 | }, | 366 | }, |
| 356 | // 数据筛选 | 367 | // 数据筛选 |
| 357 | setarrdata (scope, arr) { | 368 | setarrdata (scope, arr) { |
| ... | @@ -383,6 +394,23 @@ | ... | @@ -383,6 +394,23 @@ |
| 383 | ) | 394 | ) |
| 384 | this.getAuthorizedInfo() | 395 | this.getAuthorizedInfo() |
| 385 | }, | 396 | }, |
| 397 | handleClick (tab, event) { | ||
| 398 | this.lastuserList.forEach((item, index) => { | ||
| 399 | if (item.selectStatus === 0) { | ||
| 400 | this.$nextTick(async () => { | ||
| 401 | await this.$refs.multipleTable | ||
| 402 | if (this.$refs.multipleTable) { | ||
| 403 | this.$refs.multipleTable.toggleRowSelection( | ||
| 404 | this.lastuserList[index], | ||
| 405 | true | ||
| 406 | ); | ||
| 407 | } | ||
| 408 | |||
| 409 | }); | ||
| 410 | } | ||
| 411 | }); | ||
| 412 | } | ||
| 413 | |||
| 386 | }, | 414 | }, |
| 387 | }; | 415 | }; |
| 388 | </script> | 416 | </script> |
| ... | @@ -566,13 +594,8 @@ | ... | @@ -566,13 +594,8 @@ |
| 566 | display: flex; | 594 | display: flex; |
| 567 | margin-bottom: 15px; | 595 | margin-bottom: 15px; |
| 568 | } | 596 | } |
| 569 | 597 | .el-dialog__footer { | |
| 570 | .dialog_footer { | 598 | padding-right: 40px; |
| 571 | flex-direction: column; | ||
| 572 | |||
| 573 | .dialog_button { | ||
| 574 | margin-top: 8px; | ||
| 575 | } | ||
| 576 | } | 599 | } |
| 577 | 600 | ||
| 578 | .divider { | 601 | .divider { | ... | ... |
| ... | @@ -114,7 +114,7 @@ | ... | @@ -114,7 +114,7 @@ |
| 114 | { required: true, message: "请输入用户名", trigger: "blur" }, | 114 | { required: true, message: "请输入用户名", trigger: "blur" }, |
| 115 | ], | 115 | ], |
| 116 | }, | 116 | }, |
| 117 | title: "", | 117 | title: "修改", |
| 118 | visible: false, | 118 | visible: false, |
| 119 | showLoginName: false, | 119 | showLoginName: false, |
| 120 | sexList: [{ lable: "0", value: "0", name: "男" }, { lable: "1", value: "1", name: "女" }], | 120 | sexList: [{ lable: "0", value: "0", name: "男" }, { lable: "1", value: "1", name: "女" }], |
| ... | @@ -230,4 +230,14 @@ | ... | @@ -230,4 +230,14 @@ |
| 230 | /deep/.el-form-item__label { | 230 | /deep/.el-form-item__label { |
| 231 | color: #fff; | 231 | color: #fff; |
| 232 | } | 232 | } |
| 233 | /deep/.el-dialog__body { | ||
| 234 | padding-top: 20px; | ||
| 235 | } | ||
| 236 | /deep/.el-dialog__header { | ||
| 237 | text-align: center; | ||
| 238 | margin-bottom: 10px; | ||
| 239 | .el-dialog__title { | ||
| 240 | color: white; | ||
| 241 | } | ||
| 242 | } | ||
| 233 | </style> | 243 | </style> | ... | ... |
| ... | @@ -17,9 +17,7 @@ | ... | @@ -17,9 +17,7 @@ |
| 17 | </div> | 17 | </div> |
| 18 | <div class="from-clues-content"> | 18 | <div class="from-clues-content"> |
| 19 | <lb-table | 19 | <lb-table |
| 20 | :page-size="pageData.size" | 20 | :pagination="false" |
| 21 | :current-page.sync="pageData.current" | ||
| 22 | :total="pageData.total" | ||
| 23 | @size-change="handleSizeChange" | 21 | @size-change="handleSizeChange" |
| 24 | @p-current-change="handleCurrentChange" | 22 | @p-current-change="handleCurrentChange" |
| 25 | :column="tableData.columns" | 23 | :column="tableData.columns" |
| ... | @@ -182,11 +180,6 @@ | ... | @@ -182,11 +180,6 @@ |
| 182 | ]), | 180 | ]), |
| 183 | data: [], | 181 | data: [], |
| 184 | }, | 182 | }, |
| 185 | pageData: { | ||
| 186 | total: 5, | ||
| 187 | pageSize: 15, | ||
| 188 | current: 1, | ||
| 189 | }, | ||
| 190 | }; | 183 | }; |
| 191 | }, | 184 | }, |
| 192 | created () { | 185 | created () { |
| ... | @@ -209,6 +202,7 @@ | ... | @@ -209,6 +202,7 @@ |
| 209 | departmentId: this.departmentid.departmentId, | 202 | departmentId: this.departmentid.departmentId, |
| 210 | }; | 203 | }; |
| 211 | getUserList(this.queryParam).then((res) => { | 204 | getUserList(this.queryParam).then((res) => { |
| 205 | console.log("人员列表", res); | ||
| 212 | if (res.status === 1) { | 206 | if (res.status === 1) { |
| 213 | this.loading = false; | 207 | this.loading = false; |
| 214 | this.tableData.data = res.content; | 208 | this.tableData.data = res.content; | ... | ... |
-
Please register or sign in to post a comment