diff --git a/.beagle.yml b/.beagle.yml index 590cc2723416c4d98cfa5e49c8684a9ea9fb5a59..87caa1789c95e17b7ad1ced3ac3b16092e0e53ec 100644 --- a/.beagle.yml +++ b/.beagle.yml @@ -36,7 +36,7 @@ pipeline: - /var/run/docker.sock:/var/run/docker.sock base: registry.cn-qingdao.aliyuncs.com/wod-devops/ui-base:2.0.0 repo: wod/apaas-ui - version: "v3.1.0" + version: "v3.2.0" channel: alpha registry: registry.cn-qingdao.aliyuncs.com secrets: @@ -52,7 +52,7 @@ pipeline: - /var/run/docker.sock:/var/run/docker.sock base: registry.cn-qingdao.aliyuncs.com/wod-devops/ui-base:2.0.0 repo: wod/apaas-ui - version: "v3.1.0" + version: "v3.2.0" registry: registry.cn-qingdao.aliyuncs.com secrets: - source: REGISTRY_USER_ALIYUN @@ -87,3 +87,4 @@ pipeline: - source: REGISTRY_PASSWORD_ALIYUN target: REGISTRY_PASSWORD branches: [master,dev] + diff --git a/build/webpack.base.conf.js b/build/webpack.base.conf.js index c7ff2b9ce8bcec5b032cfb451183a8769ff57884..1e6d9fb3c8f48b1ec39281403618a6951a55729f 100644 --- a/build/webpack.base.conf.js +++ b/build/webpack.base.conf.js @@ -35,12 +35,27 @@ module.exports = { rules: [ { test: /\.vue$/, - loader: 'vue-loader', - options: vueLoaderConfig + use:[ + { + loader: 'thread-loader' + }, + { + loader: 'vue-loader', + options: vueLoaderConfig + }, + ], + }, { test: /\.js$/, - loader: 'babel-loader', + use:[ + { + loader: 'thread-loader' + }, + { + loader: 'babel-loader', + } + ], include: [resolve('src'), resolve('test'), resolve('node_modules/webpack-dev-server/client')] }, { diff --git a/config/index.js b/config/index.js index 5ee0fdcdf683d80bc92c37dbf5d75b79953e1253..3b1177d3715693d946a83f23dcb459c54c5588bf 100644 --- a/config/index.js +++ b/config/index.js @@ -24,6 +24,13 @@ module.exports = { "^/awecloud": "" } }, + "/vmap": { + target: "https://apaas3.wodcloud.com/vmap/", + changeOrigin: true, + pathRewrite: { + "^/vmap": "" + } + }, }, // Various Dev Server settings host: "localhost", // can be overwritten by process.env.HOST diff --git a/package.json b/package.json index 55396da4590d4cc645cc74f7b0fb397be78c2252..3c90effd7c9493c4a1d02d8bcddaa22816e071a9 100644 --- a/package.json +++ b/package.json @@ -15,7 +15,7 @@ "ace-builds": "^1.4.11", "axios": "^0.19.2", "babel-polyfill": "^6.26.0", - "codemirror": "^5.45.0", + "codemirror": "^5.58.2", "compression-webpack-plugin": "^6.0.2", "echarts": "^4.8.0", "echarts-liquidfill": "^2.0.6", @@ -27,7 +27,9 @@ "qs": "^6.9.4", "string-format": "^2.0.0", "svg-sprite-loader": "^4.2.6", + "thread-loader": "^3.0.0", "vue": "^2.6.10", + "vue-codemirror": "^4.0.6", "vue-cropper": "^0.5.2", "vue-echarts": "^5.0.0-beta.0", "vue-i18n": "^8.17.7", @@ -35,6 +37,7 @@ "vue-router": "^3.0.2", "vue-super-flow": "^1.3.2", "vuex": "^3.1.0", + "wangeditor": "^4.0.5", "xterm": "^4.7.0", "xterm-addon-fit": "^0.4.0", "yaml2json": "^1.0.2" diff --git a/src/assets/css/index.css b/src/assets/css/index.css index b79bed552394d8fe0084b3168bc16a2f8696843d..643d7f96c0d2230b71e2a7011df48afee994ef81 100644 --- a/src/assets/css/index.css +++ b/src/assets/css/index.css @@ -1,29 +1,34 @@ [v-cloak] { display: none; } + /* 新增按钮颜色 */ .form-group .el-button--primary { background-color: #264dd9 !important; border-color: #264dd9 !important; } + /* 返回按钮颜色 */ -.from_return > .el-button--primary { +.from_return>.el-button--primary { background-color: #edf0ff !important; border-color: #edf0ff !important; color: #264dd9 !important; } + /* 取消按钮颜色 */ .form_c { background-color: #dde4ff !important; border-color: #dde4ff !important; - color: #264dd9 !important ; + color: #264dd9 !important; } + /* 确定按钮颜色 */ .form_t { background-color: #264dd9 !important; border-color: #264dd9 !important; - color: #f4f7fc !important ; + color: #f4f7fc !important; } + /* 搜索框颜色 */ .form-group .el-input__inner { border-radius: 28px !important; @@ -31,12 +36,14 @@ background: #f4f7fc !important; color: #8890a7 !important; } + .drawer_return .el-input__inner { border-radius: 28px !important; border: 1px solid #bcc1d0 !important; background: #f4f7fc !important; color: #8890a7 !important; } + /* 多行文本框样式 */ .jbxx_desc textarea { height: 150px !important; @@ -45,39 +52,46 @@ outline: none !important; resize: none !important; } + /* 面包屑文字大小 */ .el-breadcrumb { font-size: 14px; color: #898d9e; } + /* 编辑颜色*/ .primary-edit { color: #264dd9; cursor: pointer; } + /* 删除颜色 */ .primary-del { color: #264dd9; cursor: pointer; } -.space_bet { -} + +.space_bet {} + /* reset */ -html { -} +html {} + body { margin: 0; font-family: Microsoft YaHei, sans-serif; /* font-size: 17px; */ } + ul { list-style: none; padding: 0; margin: 0; } + p { margin: 0; } + h1, h2, h3, @@ -90,6 +104,7 @@ h5 { div { box-sizing: border-box; } + /* reset end */ /* common */ @@ -97,12 +112,14 @@ div { /* height: 100%; */ /* overflow: hidden; */ } + .text_clip { overflow: hidden; text-overflow: ellipsis; word-break: break-all; white-space: nowrap; } + .text_clip_2 { text-overflow: -o-ellipsis-lastline; overflow: hidden; @@ -112,16 +129,19 @@ div { -webkit-line-clamp: 2; -webkit-box-orient: vertical; } + .map_container { background-color: #eee; } + .ss_card { padding: 1.2rem; display: flex; justify-content: flex-start; align-items: flex-start; } -.ss_card > .sc_left_container { + +.ss_card>.sc_left_container { width: 6rem; height: 6rem; flex-shrink: 0; @@ -129,71 +149,87 @@ div { overflow: hidden; font-size: 0; } -.ss_card > .sc_right_container { + +.ss_card>.sc_right_container { width: calc(100% - 7rem); flex-grow: 1; margin-left: 1.2rem; } -.ss_card > .sc_right_container > .sc_title { + +.ss_card>.sc_right_container>.sc_title { font-size: 1.6rem; font-weight: bold; line-height: 2.6rem; } -.ss_card > .sc_right_container > .sc_info { + +.ss_card>.sc_right_container>.sc_info { display: flex; justify-content: space-between; } + .form-group { padding: 20px 20px 15px; box-sizing: border-box; border-bottom: 1px solid #edf0ff; } + .padding_table { padding: 0 20px; } + /* 设置抽屉的样式 */ .el-drawer__header { display: none; } + .from_return { text-align: center; padding: 18px 20px 10px; border-bottom: 1px solid #edf0ff; position: relative; } -.from_return > .el-button--primary { + +.from_return>.el-button--primary { position: absolute; top: 15px; left: 20px; } -.from_return > span { + +.from_return>span { color: #1a2236; font-size: 16px; } + .demo-drawer__content .el-form-item__label { color: #242c43; } + .demo-drawer__content .el-input__inner { border: 1px solid #bcc1d0; border-radius: 17px; color: #58617a; background: #fff; } + .demo-drawer__footer { text-align: right; padding-right: 40px; margin-top: 40px; } + .el-form-item__error { font-size: 11px; } + /* 设置提示弹窗的样式 */ .el-dialog { border-radius: 10px; } + .el-dialog__header { border-bottom: 1px solid #edf0ff; } + .el-dialog__title { font-size: 16px; font-weight: 700; @@ -201,6 +237,7 @@ div { padding-left: 8px; position: relative; } + .el-dialog__title::before { content: ""; position: absolute; @@ -211,37 +248,49 @@ div { left: 0; top: 2px; } + .el-dialog__body { font-size: 18px; color: #242c43; text-align: center; } + /* 设置tab切换的样式 */ .el-tabs__item.is-disabled { color: #8890a7 !important; } + .el-tabs__item { font-size: 16px; color: #8890a7; line-height: 24px !important; + font-weight: bold; } + .el-tabs__nav-scroll .el-tabs__item { - line-height: 40px !important; + line-height: 38px !important; + height: 44px !important; } + .el-tabs__item:hover { color: #687087; } + .el-tabs__item.is-active { color: #e56600 !important; } + .el-tabs__active-bar { height: 3px; - background-color: #e56600 !important; + border-radius: 1px; + background-color: #f5ab4c !important; } + .el-tabs__nav-wrap::after { height: 1px; background-color: #edf0ff; } + /* 设置tree的样式 */ /* .usrrole .el-tree-node:focus>.el-tree-node__content{ background: rgb(248, 249, 253) !important; @@ -287,18 +336,26 @@ border-radius:8px; /* 左右布局 */ .flex { height: 100%; - display: -webkit-box; /* Chrome 4+, Safari 3.1, iOS Safari 3.2+ */ - display: -moz-box; /* Firefox 17- */ - display: -webkit-flex; /* Chrome 21+, Safari 6.1+, iOS Safari 7+, Opera 15/16 */ - display: -moz-flex; /* Firefox 18+ */ - display: -ms-flexbox; /* IE 10 */ - display: flex; /* Chrome 29+, Firefox 22+, IE 11+, Opera 12.1/17/18, Android 4.4+ */ + display: -webkit-box; + /* Chrome 4+, Safari 3.1, iOS Safari 3.2+ */ + display: -moz-box; + /* Firefox 17- */ + display: -webkit-flex; + /* Chrome 21+, Safari 6.1+, iOS Safari 7+, Opera 15/16 */ + display: -moz-flex; + /* Firefox 18+ */ + display: -ms-flexbox; + /* IE 10 */ + display: flex; + /* Chrome 29+, Firefox 22+, IE 11+, Opera 12.1/17/18, Android 4.4+ */ } + .flex-left { width: 178px; background-color: #1a2236; height: 100%; } + .flex-right { padding: 0 20px 20px; box-sizing: border-box; @@ -308,64 +365,76 @@ border-radius:8px; flex: 1; overflow-y: auto; } + .flex-right-box { width: 100%; height: 100%; position: relative; } + .ces-main { position: absolute; width: 100%; } + .v-modal { background: #000a2b !important; } + .drawer600 { width: 600px !important; } + .drawer620 { width: 620px !important; } + .drawer1202 { width: 1202px !important; } -.el-form-item.is-required:not(.is-no-asterisk) - .el-form-item__label-wrap - > .el-form-item__label:before, -.el-form-item.is-required:not(.is-no-asterisk) > .el-form-item__label:before { + +.el-form-item.is-required:not(.is-no-asterisk) .el-form-item__label-wrap>.el-form-item__label:before, +.el-form-item.is-required:not(.is-no-asterisk)>.el-form-item__label:before { content: ""; } + /* 设置switch的样式 */ .switchStyle1 .el-switch__label { position: absolute; display: none; color: #fff; } + /*打开时文字位置设置*/ .switchStyle1 .el-switch__label--right { z-index: 1; right: -10px; top: 1px; } + /*关闭时文字位置设置*/ .switchStyle1 .el-switch__label--left { z-index: 1; left: 28px; top: 1px; } + .switchStyle1 .el-switch__label.is-active { display: block; } + .switchStyle1.el-switch .el-switch__core, .switchStyle1.el-switch .el-switch__label { width: 62px !important; height: 28px !important; border-radius: 28px !important; } + .switchStyle1 .el-switch__core { background: #f8f9fd !important; border: 1px solid #8890a7 !important; } + .switchStyle1 .el-switch__core:after { background: #8890a7 !important; width: 22px; @@ -373,10 +442,12 @@ border-radius:8px; left: 2px; top: 2.1px; } + .switchStyle1.el-switch.is-checked .el-switch__core { background: #f8f9fd !important; border: 1px solid #5c82ff !important; } + .switchStyle1.el-switch.is-checked .el-switch__core:after { background: #5c82ff !important; width: 22px; @@ -384,22 +455,28 @@ border-radius:8px; right: 0; top: 2.1px; } + .switchStyle1.el-switch.is-checked .el-switch__core::after { margin-left: -25px; } + .switchStyle1 .el-switch__label * { font-size: 14px !important; font-weight: 800; } + .switchStyle1.el-switch .el-switch__label { color: #8890a7 !important; } + .switchStyle1.el-switch.is-checked .el-switch__label { color: #5c82ff !important; } + .switchStyle1.el-switch:hover { opacity: 0.8; } + /* 自定义图表提示框小三角 */ /* .div-tip-warp { position: relative; @@ -424,13 +501,16 @@ border-radius:8px; .el-input__inner { border-radius: 8px; } + .el-input-group__append, .el-input-group__prepend { border-radius: 8px; } + .el-button { border-radius: 8px; } + /* 下拉选样式 此处勿删,apaasV3下拉选择样式统一用这个 @@ -438,17 +518,20 @@ border-radius:8px; .el-select-dropdown { border-radius: 8px; } + .el-select-dropdown__empty { background-color: #0f2683; color: #f4f7fc; border-radius: 8px; } + .el-select-dropdown__list { padding: 0; background-color: #0f2683; top: 10px; border-radius: 4px; } + .el-select-dropdown__item { font-size: 12px; padding: 0 20px; @@ -457,59 +540,75 @@ border-radius:8px; line-height: 34px; background-color: #0f2683; } + .el-select-dropdown__item.hover, .el-select-dropdown__item:hover { background-color: #3f4f9c; } + .el-select-dropdown__item.selected { color: #f4f7fc; } + .el-scrollbar { border-radius: 8px; } + .el-popper[x-placement^="bottom"] .popper__arrow::after { border-bottom-color: transparent; } + .el-popper[x-placement^="top"] .popper__arrow::after { border-top-color: transparent; } + /* 单选激活样式 */ .el-radio__input.is-checked .el-radio__inner { - border-color: #838383; - background-color: #fff; + border-color: #e3e5ef; + background-color: #f7f8f9; } -.el-radio__input.is-checked + .el-radio__label { + +.el-radio__input.is-checked+.el-radio__label { color: #1a2236; font-weight: 700; } + .el-radio__inner::after { width: 8px; height: 8px; } + .el-radio__input.is-checked .el-radio__inner::after { background-color: #e56600; } + .el-radio__inner:hover { border-color: #e56600; } + /* 面包屑样式 */ .bread_crumb { margin: 20px; font-size: 14px; } + .bread_crumb .el-breadcrumb__inner { color: #b4c0f5 !important; } + .bread_crumb .is-link { color: #626de9 !important; } + .bread_crumb1 { margin: 20px; font-size: 14px; } + .bread_crumb1 .el-breadcrumb__inner { color: #242c43 !important; } + .bread_crumb1 .is-link { color: #898d9e !important; } @@ -522,60 +621,68 @@ border-radius:8px; } /* common */ -.apass_breadcrumb > .el-breadcrumb { +.apass_breadcrumb>.el-breadcrumb { padding: 15px 0; } -.apass_breadcrumb > .el-breadcrumb .el-breadcrumb__inner { + +.apass_breadcrumb>.el-breadcrumb .el-breadcrumb__inner { font-size: 14px; font-weight: bold; color: #898d9e; line-height: 23px; } -.apass_breadcrumb - > .el-breadcrumb - .el-breadcrumb__item:last-child - .el-breadcrumb__inner { + +.apass_breadcrumb>.el-breadcrumb .el-breadcrumb__item:last-child .el-breadcrumb__inner { color: #242c43; font-weight: normal; } + .apaas_button .el-button { min-width: 90px; color: #0f2683; } + .apaas_button .el-button--mini, .apaas_button .el-button--mini.is-round { padding: 10px 15px; } + .apaas_button .el-button--primary { color: #fff; background-color: #0f2683; border-color: #0f2683; } + .apaas_button .el-button--primary.is-plain { color: #0f2683; background-color: #e1e4fb; border-color: #e1e4fb; } + .apaas_button .el-button--danger { color: #fff; - background-color: #e15260; - border-color: #e15260; + background-color: #ad3a4a; + border-color: #ad3a4a; } + .apaas_button .el-button.is-disabled, .apaas_button .el-button.is-disabled:focus, .apaas_button .el-button.is-disabled:hover { cursor: not-allowed; } + .apaas_button .el-button--warning.is-plain { background-color: #fcefd6; border-color: #fac266; color: #e56600; } + .apaas_button .el-button--warning { background-color: #e56600; border-color: #e56600; color: #fcefd6; } + .apaas_button .el-button.is-disabled, .apaas_button .el-button.is-disabled:focus, .apaas_button .el-button.is-disabled:hover { @@ -586,62 +693,76 @@ border-radius:8px; border-color: #ebeef5; } -.apass_table .el-table th > .cell { +.apass_table .el-table th>.cell { color: #1a2236; } + .apass_table .el-table td, .apass_table .el-table th.is-leaf { border: none !important; line-height: 23px; } + .apass_table .el-table::before { display: none; } + .apass_table .el-table { width: 100%; } + .apass_table .el-table__row:nth-child(odd) td { background-color: #f8f9fd; } + .apass_table .table_html a { font-size: 14px; color: #0f2683; cursor: pointer; } + .apass_table .row_action { user-select: none; } + .apass_table .row_action .btn { font-size: 14px; font-weight: bold; color: #0f2683; cursor: pointer; } + .apass_table .row_action .btn.warn { color: #830f53; } + .apass_table .row_action .btn.disabled { color: #999; cursor: not-allowed; } + .apass_table .row_action .disabled.hide { opacity: 0; cursor: auto; } + .apass_table .row_action .interval_line { font-size: 14px; color: #dde4ff; margin: 0 20px; } + .apass_table .border-active td { padding: 10px 0; background-color: #e6ebfe; border-top: 2px solid #515fe7 !important; border-bottom: 2px solid #515fe7 !important; } + .apass_table .border-active td:first-child { border-left: 2px solid #515fe7 !important; } + .apass_table .border-active td:last-child { border-right: 2px solid #515fe7 !important; } @@ -651,7 +772,8 @@ border-radius:8px; background-color: #626de9; border-color: #515fe7; } -.apass_checkbox .el-checkbox__input.is-checked + .el-checkbox__label { + +.apass_checkbox .el-checkbox__input.is-checked+.el-checkbox__label { color: #58617a; } @@ -659,12 +781,14 @@ border-radius:8px; width: 16px; height: 1px; } + .apaas_scroll::-webkit-scrollbar-thumb { border-radius: 8px; /* background: #dde4ff; */ box-shadow: 8px 0 0 #a5adb7 inset; border: 4px solid rgba(0, 0, 0, 0); } + .apaas_scroll::-webkit-scrollbar-track { border-radius: 8px; /* background: #f4f4f4; */ @@ -676,6 +800,7 @@ border-radius:8px; .apaas_detail_container { padding: 0 20px; } + .apaas_detail_container .main_contaner { min-height: calc(100vh - 58px - 83px); flex-grow: 1; @@ -691,41 +816,51 @@ border-radius:8px; flex-direction: column; justify-content: space-between; } + .apaas_detail_container .main_contaner.locked_height { height: calc(100vh - 58px - 83px); min-height: 400px; } + .apaas_detail_container .main_contaner.locked_height_900 { height: calc(100vh - 58px - 83px); min-height: 900px; } + .apaas_detail_container .detail_action { text-align: right; margin-top: 50px; } -.apaas_detail_container .detail_action .el-button + .el-button { + +.apaas_detail_container .detail_action .el-button+.el-button { margin-left: 30px; } + .apaas_detail_form { max-width: 970px; } + .apaas_detail_form .el-input__inner, .apaas_detail_form .el-textarea__inner { width: 100%; background-color: #f7f8f9; } + .apaas_detail_form .el-select { width: 100%; } + .apaas_detail_form.el-form--label-top .el-form-item__label { padding: 0 0 15px; font-size: 14px; line-height: 1; color: #58617a; } + .apaas_detail_form .el-form-item { margin-bottom: 30px; } + .apaas_detail_form .textarea_count { font-size: 14px; line-height: 1; @@ -733,13 +868,16 @@ border-radius:8px; text-align: right; margin-top: 10px; } + .apaas_steps { height: 100%; } + .apaas_steps .apaas_step { height: 100%; position: relative; } + .apaas_steps .apaas_step .apaas_step_content { position: absolute; top: 0; @@ -749,6 +887,7 @@ border-radius:8px; border-bottom: 1px solid #f4f7fc; /* overflow: hidden; */ } + .apaas_steps .apaas_step .apaas_step_action { position: absolute; bottom: 0; @@ -758,34 +897,42 @@ border-radius:8px; justify-content: space-between; align-items: flex-start; } + .apaas_steps .apaas_step .apaas_step_action .el-button { height: 44px; width: 124px; } -.apaas_steps .apaas_step .apaas_step_action .el-button + .el-button { + +.apaas_steps .apaas_step .apaas_step_action .el-button+.el-button { margin-left: 20px; } + .top_fliter { display: flex; } + .top_fliter .filter_list { flex-grow: 1; min-width: 550px; font-size: 0; } -.filter_list > .filter_item { + +.filter_list>.filter_item { display: inline-block; vertical-align: middle; margin-top: 15px; } -.filter_list > .filter_item { + +.filter_list>.filter_item { margin-right: 15px; } -.filter_list > .filter_item > * { + +.filter_list>.filter_item>* { display: inline-block; vertical-align: middle; } -.filter_list > .filter_item > .filter_title { + +.filter_list>.filter_item>.filter_title { width: 8em; text-align: right; font-size: 14px; @@ -794,19 +941,23 @@ border-radius:8px; margin-right: 10px; white-space: nowrap; } -.filter_list > .filter_item > .filter_title + * { + +.filter_list>.filter_item>.filter_title+* { width: 300px; } + .top_fliter .filter_action { flex-shrink: 0; margin-left: 25px; text-align: right; } -.filter_action > .el-button { + +.filter_action>.el-button { min-width: 90px; margin-top: 15px; } -.filter_action > .el-button + .el-button { + +.filter_action>.el-button+.el-button { margin-left: 10px; } @@ -815,41 +966,235 @@ border-radius:8px; flex-wrap: wrap; text-align: left; } + .meassage_detail_dialog .detail_item { flex: 1 1 auto; width: 50%; margin-top: 20px; } + .meassage_detail_dialog .detail_item.full_line { width: 100%; } + .meassage_detail_dialog .detail_item p { padding: 0 15px; font-size: 14px; line-height: 22px; color: #8890a7; } + .meassage_detail_dialog .detail_item .item_content { color: #000; margin-top: 10px; } + .meassage_detail_dialog .detail_item .full_content { padding: 10px 0; border-radius: 8px; background-color: #f8f9fd; margin-top: 5px; } -.meassage_detail_dialog .detail_item .full_content > .apaas_scroll { + +.meassage_detail_dialog .detail_item .full_content>.apaas_scroll { height: 176px; overflow: auto; } + .meassage_detail_dialog .detail_item .full_content .item_content { margin: 0; } + .no_wrap .apass_table td .cell { overflow: hidden; text-overflow: ellipsis; word-break: break-all; white-space: nowrap; } + /* 详情页公共样式 by xuyiming ~~~end */ + +/* + form_content +*/ +.from_content1 { + width: calc(100% - 40px); + background-color: rgba(255, 255, 255, 1); + overflow: hidden; + margin: 0 20px 20px; + position: relative; + box-shadow: 0px 3px 6px 0px rgba(15, 19, 65, 0.05); + border-radius: 12px; + padding-top: 20px; +} + +.from_content { + width: calc(100% - 40px); + background-color: rgba(255, 255, 255, 1); + /* flex: 1 0 auto; */ + position: relative; + box-shadow: 0px 3px 6px 0px rgba(15, 19, 65, 0.05); + border-radius: 12px; + margin: 0 20px; + padding: 20px 20px 30px; +} + +.from_content_table { + height: calc(100% - 90px); +} + +.from_content_table_app { + height: calc(100% - 170px); +} + +.from_content_table_auth { + height: calc(100% - 100px); +} + +.from_content_btn { + height: 40px; + margin-bottom: 20px; +} + +/* 时间控件样式 */ +.el-picker-panel { + background-color: #242c43 !important; + border-radius: 8px !important; + font-size: 12px !important; + color: #e3e5ef !important; + box-shadow: 0 !important; + border: none !important; +} + +.el-picker-panel__footer { + border-top: 1px solid #3f4864 !important; + background-color: #242c43 !important; +} + +.el-date-table th { + border-bottom: 1px solid #3f4864 !important; + color: #e3e5ef !important; +} + +.el-date-table td.current:not(.disabled) span { + color: #e3e5ef !important; + background-color: #315efc !important; +} + +.el-date-table td.next-month, +.el-date-table td.prev-month { + color: #58617a !important; +} + +.el-date-picker__time-header { + border-bottom: 1px solid #3f4864 !important; +} + +.el-picker-panel__body .el-input__inner { + height: 24px !important; + line-height: 24px !important; + background-color: #1a2236 !important; + border-radius: 12px !important; + border: solid 1px #3f4864 !important; + color: #e3e5ef !important; + font-size: 12px; +} + +.el-picker-panel__footer .el-button { + background-color: #264dd9; + border-radius: 12px; + padding: 5px 12px; + color: #f4f7fc; + font-size: 12px; + border: none !important; +} + +.el-picker-panel__footer .el-button--text { + background-color: #dde4ff; + border-radius: 12px; + padding: 5px 12px; + color: #264dd9; + font-size: 12px; +} + +.el-button.is-plain:focus, +.el-button.is-plain:hover { + background-color: #264dd9; + color: #f4f7fc; +} + +.el-button--text:focus, +.el-button--text:hover { + color: #264dd9; + +} + +.el-time-panel { + border-radius: 8px !important; + border: 1px solid #3f4864 !important; + background-color: #242c43 !important; +} + +.el-time-panel__footer { + border: 1px solid #3f4864 !important; +} + +.el-time-panel__btn.confirm { + background-color: #264dd9; + border-radius: 12px !important; + padding: 0px 12px; + color: #f4f7fc !important; + font-size: 12px !important; +} + +.el-time-panel__btn { + line-height: 22px !important; + height: 22px !important; +} + +.el-time-spinner__item:hover:not(.disabled):not(.active) { + background-color: #264dd9 !important; + border-radius: 12px !important; + color: #f4f7fc; +} + +.el-time-spinner__item { + color: #58617a !important; +} + +.el-date-table td.in-range div, +.el-date-table td.in-range div:hover, +.el-date-table.is-week-mode .el-date-table__row.current div, +.el-date-table.is-week-mode .el-date-table__row:hover div { + background-color: #283456; +} + +.el-date-table td.end-date span, +.el-date-table td.start-date span { + background-color: #264DD9; +} + +.el-date-table td.today span { + color: #0c3ff7; +} + +.el-date-editor .el-range-separator { + width: 15%; + line-height: 28px; +} + +/* table select window */ +.el-checkbox__input.is-checked .el-checkbox__inner, +.el-checkbox__input.is-indeterminate .el-checkbox__inner { + background-color: #626de9; + border-color: #515fe7; +} +.el-checkbox__input.is-focus .el-checkbox__inner { + border-color: #515fe7; +} +.el-checkbox__input:hover .el-checkbox__inner { + border-color: #515fe7; +} +.el-date-editor .el-range-input { + width: 36%; +} \ No newline at end of file diff --git a/src/assets/i18n/language-zh.js b/src/assets/i18n/language-zh.js index 1e64e6fe8b7aabb34eb1a1a5e58847a1e9f7f7b0..dc78d6f56c25f72d481be264dfb2d20a5000739f 100644 --- a/src/assets/i18n/language-zh.js +++ b/src/assets/i18n/language-zh.js @@ -7,6 +7,7 @@ export const lang = { personal_center: "个人中心", profile: "个人档案", message_center: "消息中心", + my_questions_and_answers: "我的问答", // unit of purchase duration by_year: "按年", diff --git a/src/assets/imgs/demo_logo.png b/src/assets/imgs/demo_logo.png new file mode 100644 index 0000000000000000000000000000000000000000..a2ce2353f273cbda4cc6de145f86062ff039a1d2 Binary files /dev/null and b/src/assets/imgs/demo_logo.png differ diff --git a/src/assets/imgs/home_tool_ic_sscj.png b/src/assets/imgs/home_tool_ic_sscj.png new file mode 100644 index 0000000000000000000000000000000000000000..437816487b3b7dc35b4bfaf62462c306f80c5515 Binary files /dev/null and b/src/assets/imgs/home_tool_ic_sscj.png differ diff --git a/src/assets/imgs/ic_banbenhao.png b/src/assets/imgs/ic_banbenhao.png new file mode 100644 index 0000000000000000000000000000000000000000..c179d9c11dbc3e7134754255968085e06e3fde75 Binary files /dev/null and b/src/assets/imgs/ic_banbenhao.png differ diff --git a/src/assets/imgs/ic_gongzuoquyu.png b/src/assets/imgs/ic_gongzuoquyu.png new file mode 100644 index 0000000000000000000000000000000000000000..7f3871ef57aa8bfba782d5b4f3037377cc98ee31 Binary files /dev/null and b/src/assets/imgs/ic_gongzuoquyu.png differ diff --git a/src/assets/imgs/ic_jiaoyizs.png b/src/assets/imgs/ic_jiaoyizs.png new file mode 100644 index 0000000000000000000000000000000000000000..ab5abfbcdfcd59cf8c3909a63d5401397f5a691a Binary files /dev/null and b/src/assets/imgs/ic_jiaoyizs.png differ diff --git a/src/assets/imgs/ic_liulanshu.png b/src/assets/imgs/ic_liulanshu.png new file mode 100644 index 0000000000000000000000000000000000000000..13dc89d5df65cc60c15df7f0c7f6af9ec97ca076 Binary files /dev/null and b/src/assets/imgs/ic_liulanshu.png differ diff --git a/src/assets/imgs/ic_shouyizonge.png b/src/assets/imgs/ic_shouyizonge.png new file mode 100644 index 0000000000000000000000000000000000000000..d12e8ac54cee2026534ae7093b646c28122ba07d Binary files /dev/null and b/src/assets/imgs/ic_shouyizonge.png differ diff --git a/src/assets/imgs/ic_wodehuida.png b/src/assets/imgs/ic_wodehuida.png new file mode 100644 index 0000000000000000000000000000000000000000..fe013168b0ce88dd74e1460500efe94a719a14b2 Binary files /dev/null and b/src/assets/imgs/ic_wodehuida.png differ diff --git a/src/assets/imgs/ic_wodetiwen.png b/src/assets/imgs/ic_wodetiwen.png new file mode 100644 index 0000000000000000000000000000000000000000..d0795bb9121bb40bf23f2a11e74917f865921cd9 Binary files /dev/null and b/src/assets/imgs/ic_wodetiwen.png differ diff --git a/src/assets/imgs/ic_yuejiaoyi.png b/src/assets/imgs/ic_yuejiaoyi.png new file mode 100644 index 0000000000000000000000000000000000000000..bb33346cfbe5c1700fdc596eb443e7d773bfc95a Binary files /dev/null and b/src/assets/imgs/ic_yuejiaoyi.png differ diff --git a/src/assets/imgs/img_head.png b/src/assets/imgs/img_head.png index 801b461b0f444967d8b1e0b45e7a3a7e64d5ae4f..ce6d1d86ecf100af9ca27c872cbae89b33919880 100644 Binary files a/src/assets/imgs/img_head.png and b/src/assets/imgs/img_head.png differ diff --git a/src/assets/imgs/jszc_btn_huifu.png b/src/assets/imgs/jszc_btn_huifu.png new file mode 100644 index 0000000000000000000000000000000000000000..f2ff2177f45e67f59a84f60e5ec724d89022d84a Binary files /dev/null and b/src/assets/imgs/jszc_btn_huifu.png differ diff --git a/src/assets/imgs/jszc_ic_fabu.png b/src/assets/imgs/jszc_ic_fabu.png new file mode 100644 index 0000000000000000000000000000000000000000..a9b236457f8dbae2457f8f55b9000ff8a1c9d9e3 Binary files /dev/null and b/src/assets/imgs/jszc_ic_fabu.png differ diff --git a/src/assets/imgs/jszc_ic_huida.png b/src/assets/imgs/jszc_ic_huida.png new file mode 100644 index 0000000000000000000000000000000000000000..b553c91bd27386cc36ccb6c2b09ad4f0d8775a26 Binary files /dev/null and b/src/assets/imgs/jszc_ic_huida.png differ diff --git a/src/assets/imgs/jszc_ic_liulan.png b/src/assets/imgs/jszc_ic_liulan.png new file mode 100644 index 0000000000000000000000000000000000000000..ef9c0925e62f41e1c5d01208c5b2e74e8b6b0c57 Binary files /dev/null and b/src/assets/imgs/jszc_ic_liulan.png differ diff --git a/src/assets/imgs/money_table_ico.png b/src/assets/imgs/money_table_ico.png new file mode 100644 index 0000000000000000000000000000000000000000..ef54b892a7c09e2878789a537c61b7b2a9c7bfa0 Binary files /dev/null and b/src/assets/imgs/money_table_ico.png differ diff --git a/src/assets/imgs/tool_ic_kaifawendang.png b/src/assets/imgs/tool_ic_kaifawendang.png new file mode 100644 index 0000000000000000000000000000000000000000..5bd2147c17d04a6654b3cbab8773cd37862e0a1c Binary files /dev/null and b/src/assets/imgs/tool_ic_kaifawendang.png differ diff --git a/src/assets/imgs/tool_ic_shili.png b/src/assets/imgs/tool_ic_shili.png new file mode 100644 index 0000000000000000000000000000000000000000..6caf2b6856b7d30d9f5842063495f1352c924fdf Binary files /dev/null and b/src/assets/imgs/tool_ic_shili.png differ diff --git a/src/assets/imgs/tool_ic_tips.png b/src/assets/imgs/tool_ic_tips.png new file mode 100644 index 0000000000000000000000000000000000000000..ef54b892a7c09e2878789a537c61b7b2a9c7bfa0 Binary files /dev/null and b/src/assets/imgs/tool_ic_tips.png differ diff --git a/src/assets/imgs/tool_ic_wenda.png b/src/assets/imgs/tool_ic_wenda.png new file mode 100644 index 0000000000000000000000000000000000000000..6cbe90cf2b626710d17ecc37f6a6e68eabc70340 Binary files /dev/null and b/src/assets/imgs/tool_ic_wenda.png differ diff --git a/src/assets/imgs/wdjb_ic_czbs.png b/src/assets/imgs/wdjb_ic_czbs.png new file mode 100644 index 0000000000000000000000000000000000000000..ebf6bfa13bd3f3a498b70c814b049c588795d1d1 Binary files /dev/null and b/src/assets/imgs/wdjb_ic_czbs.png differ diff --git a/src/assets/imgs/wdjb_ic_zhye.png b/src/assets/imgs/wdjb_ic_zhye.png new file mode 100644 index 0000000000000000000000000000000000000000..2cf30054e30ce53ad2b8691abe5fd76fad1b477a Binary files /dev/null and b/src/assets/imgs/wdjb_ic_zhye.png differ diff --git a/src/components/apass-list.vue b/src/components/apass-list.vue index 68b2f517c4784a4a0d343aae1abf39af3afb3592..346485d980a3f26cd021ae1cb661564aedd6112e 100644 --- a/src/components/apass-list.vue +++ b/src/components/apass-list.vue @@ -80,9 +80,12 @@
@@ -146,6 +149,10 @@ export default { type: String, default: () => "请输入关键字", }, + listSelect: { + type: Boolean, + default: false, + }, }, data: () => ({ showListFilter: false, @@ -223,6 +230,15 @@ export default { }); }, 200); }, + selectAction(selectedItems) { + this.$emit("list-select", selectedItems); + }, + clearSelection() { + this.$refs.listTable.clearSelection(); + }, + setSelectedRow(row, flag) { + this.$refs.listTable.setSelectedRow(row, flag); + }, }, mounted() { this.initOtherFilter(); diff --git a/src/components/apass-table.vue b/src/components/apass-table.vue index 5590a1269d07844caf76bbaeec12e928ac7b33b5..7e289fa1d5452d31d605a52417bf0a280b28add2 100644 --- a/src/components/apass-table.vue +++ b/src/components/apass-table.vue @@ -1,15 +1,20 @@ @@ -371,6 +562,7 @@ export default { ], }, ], + showApproval: false, header_arr: [ { prop: "name", @@ -477,15 +669,24 @@ export default { .then((response) => { if (response.data.success == 1) { let data = response.data.data || []; - for (let i = 0; i < data.length; i++) { - this.approval_arr1[i].result = data[i].apply_type_name; - this.approval_arr1[i].arr[0].info = data[i].created; - this.approval_arr1[i].arr[1].info = data[i].department_name; - this.approval_arr1[i].arr[2].info = data[i].user_name; - this.approval_arr1[i].arr[3].info = data[i].comments; + if (data.length != 0) { + for (let i = 0; i < data.length; i++) { + this.approval_arr1[i].result = data[i].apply_type_name; + this.approval_arr1[i].arr[0].info = data[i].created; + this.approval_arr1[i].arr[1].info = data[i].department_name; + this.approval_arr1[i].arr[2].info = data[i].user_name; + this.approval_arr1[i].arr[3].info = data[i].comments; + } + this.approval_arr1.splice(data.length); + } else { + this.approval_arr1[0].result = "待审批"; + this.approval_arr1[0].arr = []; + this.approval_arr1.splice(1); } - this.approval_arr1.splice(data.length); + this.showApproval = true; + console.log(this.approval_arr1); } else { + this.showApproval = false; console.log(response.data.errMsg); } }); @@ -578,6 +779,7 @@ export default { .detail { margin: 0 20px; } + .detail_head { width: 100%; background-color: #f6f7fb; @@ -586,87 +788,109 @@ export default { position: relative; margin-bottom: 20px; } + .detail_head_msg { padding: 20px; } + .detail_head_cell { display: inline-block; height: 50px; text-align: center; } + .detail_head_status { width: 160px; } + .detail_head_no { width: 360px; } + .detail_head_time { width: 240px; } + .border_right { border-right: 1px #e3e5ef solid; } + .border_left { border-left: 1px #e3e5ef solid; } + .detail_head_cell_title { font-size: 14px; color: #8890a7; line-height: 22px; } + .detail_head_cell_val { font-size: 16px; font-weight: 700; line-height: 28px; color: #242c43; } + .text_blue { color: #515fe7; } + .text_yellow { color: #ef9433; } + .text_blackblue { color: #242c43; } + .text_red { color: #e15260; } + .btn_group { position: absolute; right: 20px; top: 26px; } + .evaluation { width: 100px; background-color: #c3caf8; color: #0f2683; margin-right: 20px; } + .again { width: 100px; background-color: #0f2683; color: #f8f9fd; } + .pop_rate { padding: 0 0 0 50px; margin: 15px 0; } + .evaluation_text { padding: 15px 4px; } + .pop_cancel { color: #58617a; margin-right: 20px; } + .pop_submit { background-color: #e56600; border: 0; } + .pop_btn_group { margin-top: 10px; text-align: center; } + .detail_title { font-size: 18px; margin: 10px 0 20px; @@ -674,6 +898,7 @@ export default { position: relative; color: #58617a; } + .detail_title::before { position: absolute; content: ""; @@ -684,6 +909,7 @@ export default { left: 0; top: 4px; } + .detail_service { width: 100%; height: 100%; @@ -691,6 +917,7 @@ export default { border-radius: 8px; border: solid 1px #ededed; } + .detail_service_msg { height: 162px; padding: 20px 10px 20px 20px; @@ -698,17 +925,20 @@ export default { justify-content: space-between; border-right: 1px #ededed solid; } + .detail_service_msg_img { width: 118px; height: 118px; border-radius: 8px; border: 3px #f4f7fc solid; } + .detail_service_msg_right { width: calc(100% - 140px); margin: 0 0 0 10px; position: relative; } + .detail_service_name { width: 100%; line-height: 24px; @@ -721,6 +951,7 @@ export default { -webkit-box-orient: vertical; font-size: 16px; } + .detail_service_name_cloud { width: 100%; line-height: 24px; @@ -734,20 +965,24 @@ export default { -webkit-box-orient: vertical; font-size: 16px; } + .detail_service_msg_other { position: absolute; bottom: 2px; } + .detail_service_type { color: #8890a7; font-size: 14px; line-height: 22px; } + .detail_service_creator { color: #8890a7; font-size: 14px; line-height: 22px; } + .tags { display: inline-block; margin-left: 10px; @@ -759,26 +994,31 @@ export default { position: relative; top: -2px; } + .map_service { background-color: #626de9; border: solid 1px #626de9; color: #fff; } + .shared { background-color: #e7fdfc; border: solid 1px #8bd6d0; color: #25bdb1; } + .restricted { background-color: #fffee8; border: solid 1px #e4c884; color: #ef9433; } + .sensitive { background-color: #ffefef; border: solid 1px #d7a4a9; color: #e15260; } + .detail_service_specification { height: 162px; color: #8890a7; @@ -789,37 +1029,63 @@ export default { padding: 22px 20px; border-right: 1px #ededed solid; } + .detail_service_specification_val { color: #242c43; } + .detail_service_time { text-align: center; height: 162px; display: flex; justify-content: center; align-items: center; + border-right: 1px #ededed solid; } + .detail_service_time_title { color: #8890a7; } + +.detail_service_money { + text-align: center; + height: 162px; + display: flex; + justify-content: center; + align-items: center; +} + +.detail_service_money_title { + color: #8890a7; +} +.adhekadwn { + color: #8890a7; + display: block; + margin-top: 20px; +} + .detail_s_title { color: #8890a7; margin: 20px 0 10px; padding: 0 0 0 20px; } + .detail_app_scence { padding: 0 0 0 20px; color: #242c43; font-size: 14px; line-height: 22px; } + .detail_s_val { padding: 0 0 0 20px; } + .approval_status_btn { background-color: #e1e4fb; color: #626de9; } + .params_block { background-color: #f8f9fd; border-radius: 8px; @@ -828,47 +1094,58 @@ export default { font-size: 14px; line-height: 22px; } + .params_block_title { padding-left: 5px; color: #242c43; } + .params_block_item { padding: 10px 0 0 0; } + .params_block_item_in { display: flex; justify-content: space-between; margin-bottom: 5px; } + .params_block_item_title { color: #8890a7; width: 80px; text-align: right; } + .params_block_item_val { color: #242c43; width: calc(100% - 82px); } + .val_has_2 { margin-right: 20px; } + .margin_top_20 { display: block; margin-top: 20px; } + .evaluation_msg { height: 100%; border-top: solid 2px #e3e5ef; padding: 20px; background-color: #fff; } + .msg_title { color: #8890a7; margin: 0 0 10px; } + .msg_rate { margin: 0 0 20px 0; } + .msg_text { /* margin-left: 20px; */ color: #242c43; @@ -878,6 +1155,7 @@ export default { .pop_rate .el-rate__icon { font-size: 24px; } + .pop_rate .el-rate__text { font-size: 20px; margin-left: 20px; @@ -885,7 +1163,8 @@ export default { top: 1px; color: #58617a !important; } + .evaluation_text .el-textarea__inner { border-radius: 8px; } - \ No newline at end of file + diff --git a/src/pages/user/questions-answers/community.vue b/src/pages/user/questions-answers/community.vue new file mode 100644 index 0000000000000000000000000000000000000000..a08271028ab510634cc6e954efb9773e812fc610 --- /dev/null +++ b/src/pages/user/questions-answers/community.vue @@ -0,0 +1,477 @@ + + + + + + diff --git a/src/pages/user/questions-answers/my-qa.vue b/src/pages/user/questions-answers/my-qa.vue new file mode 100644 index 0000000000000000000000000000000000000000..eb1b4678059a68e40ffe0fa471826407f41ee347 --- /dev/null +++ b/src/pages/user/questions-answers/my-qa.vue @@ -0,0 +1,659 @@ + + + + + + + \ No newline at end of file diff --git a/src/pages/user/questions-answers/qa.vue b/src/pages/user/questions-answers/qa.vue new file mode 100644 index 0000000000000000000000000000000000000000..e46fdd0e2edec31253c57b5f71c375f37af4abc9 --- /dev/null +++ b/src/pages/user/questions-answers/qa.vue @@ -0,0 +1,88 @@ + + + + + diff --git a/src/pages/workbench/component-center/process-management/designer/detail.vue b/src/pages/workbench/component-center/process-management/designer/detail.vue index 809d41d2d860b6de3f3e3b377f732bf00d39d26d..63ec72698ceac7b44bfb959dd644d1614925f593 100644 --- a/src/pages/workbench/component-center/process-management/designer/detail.vue +++ b/src/pages/workbench/component-center/process-management/designer/detail.vue @@ -122,6 +122,8 @@ export default { service_header_arr:{ id: "", isMap: false, + isProcess: true, + workflows_id:parseInt(this.$route.params.id), name:'', first:[], second:[], diff --git a/src/pages/workbench/fwgl/apply_service_detail.vue b/src/pages/workbench/fwgl/apply_service_detail.vue index 865df8b4fe39d1cea4a6e6a33681d1d79564312c..d60203d653bf427d1baa6135196dd51c7f289c22 100644 --- a/src/pages/workbench/fwgl/apply_service_detail.vue +++ b/src/pages/workbench/fwgl/apply_service_detail.vue @@ -19,7 +19,54 @@ >{{ item }}
+ +
+ + + + +
+ + + + + + +
+
+
+ + + + + + + +
@@ -67,6 +116,257 @@ export default { data() { return { use_approval_arr: [], + process_in_up:false,//是否是服务注册产生的 + perception_in:false,//是否是感知服务 + service_apply_type:1,//服务申请的方式,1:计次收费2:时长收费 + port_select:'', + req_solt_code_arr:'', + res_solt_code_arr:'', + perception_req_solt_code_arr:'', + perception_res_solt_code_arr:'', + req_solt_data:[], + res_solt_data:[], + perception_req_solt_data:[], + perception_res_solt_data:[], + req_solt_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "is_must", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], // 请求参数-header + res_solt_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "is_must", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], + perception_req_solt_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "is_must", + label: "是否必须", + align: "center", + }, + { + prop: "is_must", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], + perception_res_solt_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "is_must", + label: "是否必须", + align: "center", + }, + { + prop: "is_must", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], + port_options:[ + { + label:'接口1', + value:'qweqweqsdfsdf', + able:true, + }, + { + label:'接口2', + value:'qweqweqsdfsdfwer2w23', + able:false, + }, + + ], + port_solt_arr:[ + { + title: "服务地址:", + info: "12312312", + }, + { + title: "请求方式:", + info: "12123", + }, + { + title: "编码格式:", + info: "get", + }, + { + title: "请求参数:", + info: "", + type: "solt", + solt_name: "request_table", + }, + { + title: "请求示例:", + info: "", + type: "solt", + solt_name: "request_code", + }, + { + title: "响应参数:", + info: "", + type: "solt", + solt_name: "response_table", + }, + { + title: "响应示例:", + info: "", + type: "solt", + solt_name: "response_code", + }, + ], + perception_solt_arr:[ + { + title: "接口文档:", + info: "接口文档示例.docx", + url: "11111", + type: "down", + }, + { + title: "请求方式:", + info: "12123", + }, + { + title: "编码格式:", + info: "get", + }, + { + title: "请求参数:", + info: "", + type: "solt", + solt_name: "request_table", + }, + { + title: "请求示例:", + info: "", + type: "solt", + solt_name: "request_code", + }, + { + title: "响应参数:", + info: "", + type: "solt", + solt_name: "response_table", + }, + { + title: "响应示例:", + info: "", + type: "solt", + solt_name: "response_code", + } + ], + process_in_up_arr:[ + { + title: "接口文档:", + info: "接口文档示例.docx", + url: "11111", + type: "down", + }, + { + title: "服务接口:", + info: "", + type: "solt", + solt_name: "service_port", + } + ], approval_arr: [ { title: "一级审批", @@ -189,6 +489,7 @@ export default { service_header_arr: { id: "", isMap: false, + isProcess:false, name: "", first: [ { @@ -318,6 +619,10 @@ export default { title: "申请时间:", info: "", }, + { + title: "支付总价:", + info: "0", + }, { title: "审批信息", prop: "title", @@ -381,11 +686,17 @@ export default { } let data = response.data.data; this.$set(this.service_header_arr, "portal_id", data.portal_id); // 时空服务id + this.$set(this.service_header_arr, "workflows_id", data.workflows_id); // 时空服务id this.$set( this.service_header_arr, "isMap", data.data_service_type1 === 6 ); + this.$set( + this.service_header_arr, + "isProcess", + data.data_service_type2 === 24 + ); this.$set(this.service_header_arr, "name", data.name); this.$set( this.service_header_arr["first"][0], @@ -414,17 +725,50 @@ export default { ? "#515fe7" : "#e15260" ); - this.$set( - this.service_header_arr["first"][2], - "text", - data.service_apply_info.service_end_time == "0001-01-01T00:00:00Z" - ? "-" - : data.service_apply_info.service_end_time - .replace("T", " ") - .split("+")[0] - ); + this.$set(this.service_header_arr["second"][0], "text", data.req_url); this.$set(this.service_header_arr, "url", data.cover); + + //判断是否是服务注册出来的流程服务 + if(data.data_service_type2 == 24&&data.workflows_id==0){ + this.process_in_up = true + }else{ + this.process_in_up = false + } + + if(data.service_data_type_1 == 10){ + this.perception_in = true + }else{ + this.perception_in = false + } + + if(this.process_in_up){ + var temp_sj = this.service_header_arr.first.pop() + this.service_header_arr.second = [] + this.service_header_arr.second.push(temp_sj) + } + if(this.service_apply_type==1){ + this.$set( + this.service_header_arr["first"][2], + "text", + data.service_apply_info.service_end_time == "0001-01-01T00:00:00Z" + ? "-" + : data.service_apply_info.service_end_time + .replace("T", " ") + .split("+")[0] + ); + this.$set(this.service_header_arr["first"][2],'name','可调用次数') + }else{ + this.$set( + this.service_header_arr["first"][2], + "text", + data.service_apply_info.service_end_time == "0001-01-01T00:00:00Z" + ? "-" + : data.service_apply_info.service_end_time + .replace("T", " ") + .split("+")[0] + ); + } this.$set(this.list_arr[0], "info", data.descript); this.$set(this.list_arr[1], "info", data.data_service_type2_name); this.$set( @@ -504,6 +848,11 @@ export default { "info", data.service_apply_info.apply_time.replace("T", " ").split("+")[0] ); + this.$set( + this.apply_arr[9], + "info", + data.service_apply_info.total_money + ); this.res_table_arr = JSON.parse( data.service_apply_info.res_fields || "[]" ); diff --git a/src/pages/workbench/fwgl/approval_service_detail.vue b/src/pages/workbench/fwgl/approval_service_detail.vue index 8cf24819e89fa477dd2516bda2c9230f229e40d4..9f3a77cdeae91e1ee1c35fded8ccca5e654c0466 100644 --- a/src/pages/workbench/fwgl/approval_service_detail.vue +++ b/src/pages/workbench/fwgl/approval_service_detail.vue @@ -160,6 +160,7 @@ export default { service_header_arr: { id: "", isMap: false, + isProcess: false, name: "", first: [ { @@ -261,7 +262,11 @@ export default { { title: "申请规格:", info: "" - } + }, + { + title: "总价:", + info: "", + }, ] }; }, @@ -340,7 +345,9 @@ export default { } let data = response.data.data; this.$set(this.service_header_arr, "portal_id", data.portal_id); // 时空服务id + this.$set(this.service_header_arr, "workflows_id", data.workflows_id); // 时空服务id this.$set(this.service_header_arr, "isMap", data.data_service_type1 === 6); + this.$set(this.service_header_arr, "isProcess", data.data_service_type2 === 24); this.$set(this.service_header_arr, "name", data.name); this.$set(this.service_header_arr['first'][0], 'text', data.data_service_type1_name); this.$set(this.service_header_arr['first'][1], 'text', data.sectors_name); @@ -358,6 +365,7 @@ export default { this.$set(this.list_arr[6], "url", data.service_apply_info.apply_file); this.$set(this.list_arr[8], "info", data.service_apply_info.duration+(data.service_apply_info.duration_unit==1?'月':'年')); this.$set(this.list_arr[9], "info", "访问次数:"+(data.service_apply_info.request_spcs&&data.service_apply_info.request_spcs.pv||'-')+"次/日 访问量:"+(data.service_apply_info.request_spcs&&data.service_apply_info.request_spcs.count||'-')+"次/日"); + this.$set(this.list_arr[10], "info", data.service_apply_info.total_money); this.id = data.service_apply_info.id if(data.service_apply_info.approval_status!==0){ this.servicead_arr[this.now_user].splice(1,1) diff --git a/src/pages/workbench/fwgl/cloud-detail.vue b/src/pages/workbench/fwgl/cloud-detail.vue index 997d8140bfc278dca2de496d91d674829d16fcaf..23e6c19026976218d243460609464fe554004979 100644 --- a/src/pages/workbench/fwgl/cloud-detail.vue +++ b/src/pages/workbench/fwgl/cloud-detail.vue @@ -342,6 +342,10 @@ export default { title: "剩余使用天数:", info: "1000天", }, + { + title: "支付总价:", + info: "0 金币", + }, { title: "到期时间:", info: "2020-06-02 15:54:21", @@ -698,7 +702,8 @@ export default { this.list_arr[3].url = data.apply_file; // application file url this.list_arr[6].info = data.bgn_time; // get time this.list_arr[7].info = data.time_remaining; // remaining days - this.list_arr[8].info = data.end_time; // maturity time + this.list_arr[8].info = data.total_money; + this.list_arr[9].info = data.end_time; // maturity time this.list_arr_my[0].info = data.first_level_time || "暂未提交"; // submit application time this.list_arr_my[1].info = data.second_level_time || "暂未获取"; // super get time this.super_status = data.second_level; // super status diff --git a/src/pages/workbench/fwgl/fwglList.vue b/src/pages/workbench/fwgl/fwglList.vue index b2db3e286c7980f2e517a2d560483f957f6117fe..bf99754e16a03a7b273305417e939fd3eadf146a 100644 --- a/src/pages/workbench/fwgl/fwglList.vue +++ b/src/pages/workbench/fwgl/fwglList.vue @@ -586,6 +586,11 @@ export default { ]; }, }, + { + label: "费用", + align: "center", + prop: "total_money" + }, { label: "资源调整结果", align: "center", diff --git a/src/pages/workbench/fwgl/serviceDetail.vue b/src/pages/workbench/fwgl/serviceDetail.vue index 713b15cc583df06a37fcae59938f80a8d07a7c07..fe2f3188de495d33c1e46235b98d5fc8b14ba9a5 100644 --- a/src/pages/workbench/fwgl/serviceDetail.vue +++ b/src/pages/workbench/fwgl/serviceDetail.vue @@ -24,6 +24,7 @@ :style=" now_service == index ? { borderBottom: '4px solid #f5ab4c' } : {} " + v-if="index<3||in_origin_ser" > {{ item }} @@ -31,7 +32,7 @@
-

+

流程服务接口说明见文档中心流程服务接口文档

+ +
+ + + + +
+ + + + + + +
+
+
+ + + + + +

服务运行概况

-
- - + +
+ +
- - -

服务调用列表

+ + -

购买方式:

+
-

@@ -172,15 +246,60 @@ :type="buy_style.indexOf(2) !== -1 ? 'primary' : ''" @click="change_buy(2)" >按年购买 + > -->

保存 取消
+
+ +
+
+
+ +

服务收益总额

+

{{trans_all_obj.all}}

+ 金币 +
+
+
+
+ +

交易总数

+

{{trans_all_obj.times}}

+ +
+
+
+
+ +

本月交易总数

+

{{trans_all_obj.month}}

+ +
+
+
+
+ + +
+
+
+ @@ -212,13 +331,21 @@ export default { data() { return { now_user: 0, //0:普通用户,1:组织管理员,2:超级管理员 + process_in_up:false,//是否是服务注册产生的流程服务 + perception_in:false,//是否是感知服务 + in_origin_ser:false,//是否是组织内部的服务 buy_style: [1], + // editstr:'

1221312

wuqwyequ827812731731', listTotal: 0, currentPage: 1, pageSize: 10, + translistTotal: 0, + transcurrentPage: 1, + transpageSize: 10, pageSizes: [10, 50, 100], responseParamUrl: "", codeExampleUrl: "", + port_select_server:'', yx_state: { state: "", averageTime: "", @@ -227,7 +354,213 @@ export default { maxTraffic: "", memory: "", }, + port_select:'', service_use_arr: [], + req_solt_data:[], + res_solt_data:[], + req_gz_solt_data:[], + res_gz_solt_data:[], + service_gz_process_arr:[], + trans_all_obj:{ + all:0, + times:0, + month:0, + }, + trans_log_arr:[ + { + title: "服务交易概览", + info: "", + prop:'title', + type: "solt", + solt_name: "trans_all", + }, + { + title: "服务交易记录", + info: "", + prop:'title', + type: "solt", + solt_name: "trans_log", + }, + ], + trans_log_header:[ + { + prop: "department_name", + label: "申请单位", + minWidth: "20%", + align: "left", + }, + { + prop: "system_name", + label: "业务系统", + minWidth: "20%", + align: "left", + }, + { + prop: "apply_username", + label: "申请人", + minWidth: "20%", + align: "center", + }, + { + prop: "gg", + label: "规格", + minWidth: "20%", + align: "left", + }, + { + prop: "duration_name", + label: "购买时长", + width: "110px", + align: "center", + }, + { + prop: "total_money", + label: "订单总价", + width: "150px", + align: "center", + }, + { + prop: "trade_time", + label: "交易时间", + width: "160px", + align: "center", + }, + ], + trans_log_data:[], + res_solt_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "example", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], // 请求参数-header + req_solt_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "example", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], // 请求参数-header + req_gz_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "is_must", + label: "是否必须", + align: "left", + }, + { + prop: "example", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], // 请求参数-header + res_gz_header_arr: [ + { + prop: "name", + label: "字段编码", + align: "left", + width: 200, + }, + { + prop: "label", + label: "字段名称", + align: "center", + width: 200, + }, + { + prop: "show_type", + label: "字段类型", + align: "center", + width: 240, + }, + { + prop: "descript", + label: "字段说明", + align: "left", + }, + { + prop: "is_must", + label: "是否必须", + align: "left", + }, + { + prop: "example", + label: "字段示例数值", + align: "center", + width: 240, + }, + ], // 请求参数-header req_header_arr: [ { prop: "name", @@ -298,18 +631,21 @@ export default { ], // 响应参数-header res_data: [], // 响应参数 res_code_arr: "", // 响应示例 + req_solt_code_arr:'11', + res_solt_code_arr:'11', buy_type: "", workflows_id:'',//判断是否是流程服务 sizeset_flag: false, //规格设置是否显示 service_arr: [ ["服务基本信息", "接口详细信息", "服务运行状态"], - ["服务基本信息", "接口详细信息", "服务运行状态", "服务计费规则"], - ["服务基本信息", "接口详细信息", "服务运行状态", "服务规格"], + ["服务基本信息", "接口详细信息", "服务运行状态", "服务计费规则","服务交易记录"], + ["服务基本信息", "接口详细信息", "服务运行状态", "服务规格","服务交易记录"], ], service_size_data: [], //服务规格数组 service_header_arr: { id: "", isMap: false, + isProcess: false, url: "", name: "", first: [ @@ -391,21 +727,139 @@ export default { align: "right", }, ], - service_size_arr: [ + header_gz_process_arr: [ + { + prop: "dyyw", + label: "调用业务系统", + minWidth: "20%", + align: "left", + }, + { + prop: "dydw", + label: "调用单位", + minWidth: "20%", + align: "left", + }, + { + prop: "ywxt", + label: "业务系统网址", + minWidth: "20%", + align: "left", + }, + { + prop: "cjms", + label: "场景描述", + minWidth: "40%", + align: "left", + }, + { + prop: "sqgg", + label: "申请规格", + minWidth: "40%", + align: "center", + }, + { + prop: "sqsc", + label: "申请时长", + minWidth: "40%", + align: "center", + }, + { + prop: "sqsj", + label: "申请调用时间", + width: "160px", + align: "right", + }, + ], + header_process_arr: [ + { + prop: "dydw", + label: "调用单位", + minWidth: "20%", + align: "left", + }, + { + prop: "dyyw", + label: "调用业务系统", + minWidth: "20%", + align: "left", + }, + { + prop: "ywxt", + label: "业务系统网址", + minWidth: "20%", + align: "left", + }, + { + prop: "jkmc", + label: "调用接口名称", + minWidth: "20%", + align: "left", + }, + { + prop: "jkdz", + label: "调用接口地址", + minWidth: "20%", + align: "left", + }, + { + prop: "state", + label: "调用状态", + minWidth: "20%", + align: "center", + }, + { + prop: "time", + label: "调用时间", + minWidth: "20%", + align: "center", + }, { prop: "count", - label: "访问次数(次/日)", + label: "总调用次数", + minWidth: "20%", + align: "center", + } + ], + service_process_arr:[ + { + dydw:'比格大数据', + dyyw:'apaas', + ywxt:'https:www.apaas.com', + jkmc:'地图服务', + jkdz:'https://www.apaas.com/map', + state:'成功', + time:'2020-10-20 10:05:11', + count:125 + } + ], + service_size_arr: [ + { + prop: "index", + label: "序号", + width: "100px", + align: "center", + }, + { + prop: "spcs_type", + label: "规格类型", minWidth: "33.33%", align: "center", }, { - prop: "pv", - label: "访问量(PV/日)", + prop: "gg", + label: "规格", minWidth: "33.33%", align: "center", }, { - prop: "des", + prop: "time", + label: "购买时长", + width: "200px", + align: "center", + }, + { + prop: "descript", label: "规格说明", minWidth: "33.33%", align: "left", @@ -413,25 +867,54 @@ export default { ], edit_size_arr: [ { - prop: "count", - label: "访问次数(次/日)", - minWidth: "33.33%", + prop: "spcs_type", + label: '规格类型', + width: "180px", + align: "center", + type: "select", + selectArr:[ + { + label:'计次收费规格', + value:1 + }, + { + label:'时长收费规格', + value:2 + } + ] + }, + { + prop: "money", + label: "价格/金币", + width: "200px", align: "center", - type: "inputNumber", + type: "inputMoney", }, { prop: "pv", - label: "访问量(PV/日)", - minWidth: "33.33%", + label: '调用次数', + width: "150px", align: "center", - type: "inputNumber", + type: "input", }, { - prop: "des", + prop: "d_price", + label: "单价", + width: "150px", + align: "left", + }, + { + prop: "time", + label: "时长", + width: "150px", + align: "left" + }, + { + prop: "descript", label: "规格说明", minWidth: "33.33%", align: "left", - type: "input", + type:'input' }, { label: "操作", @@ -482,6 +965,93 @@ export default { solt_name: "res_code", }, ], + process_in_up_arr:[ + { + title: "接口文档:", + info: "", + url: "", + type: "down", + }, + { + title: "服务接口:", + info: "", + type: "solt", + solt_name: "service_port", + } + ], + port_solt_arr:[ + { + title: "服务地址:", + info: "", + }, + { + title: "请求方式:", + info: "", + }, + { + title: "编码格式:", + info: "get", + }, + { + title: "请求参数:", + info: "", + type: "solt", + solt_name: "request_table", + }, + { + title: "请求示例:", + info: "", + type: "solt", + solt_name: "request_code", + }, + { + title: "响应参数:", + info: "", + type: "solt", + solt_name: "response_table", + }, + { + title: "响应示例:", + info: "", + type: "solt", + solt_name: "response_code", + }, + ], + gz_solt_arr:[ + { + title: "请求方式:", + info: "12123", + }, + { + title: "编码格式:", + info: "get", + }, + { + title: "请求参数:", + info: "", + type: "solt", + solt_name: "request_table", + }, + { + title: "请求示例:", + info: "", + type: "solt", + solt_name: "request_code", + }, + { + title: "响应参数:", + info: "", + type: "solt", + solt_name: "response_table", + }, + { + title: "响应示例:", + info: "", + type: "solt", + solt_name: "response_code", + }, + ], + port_options:[], service_type_arr: [ "数据服务", "时空服务", @@ -541,11 +1111,16 @@ export default { if (n == 2) { this.getData(); } - }, + } }, created() { if (this.userInfo) { this.now_user = this.level; + if(this.now_user==1||this.now_user==2){ + this.in_origin_ser = true + }else{ + this.in_origin_ser = false + } } else { this.getCurrentUser(); } @@ -555,15 +1130,63 @@ export default { }, mounted() {}, methods: { + change_port(val){ + this.port_options.forEach(e => { + if(e.value == val){ + this.$set(this.port_solt_arr[0],'info',e.value) + this.$set(this.port_solt_arr[1],'info',e.req_type) + this.$set(this.port_solt_arr[2],'info',e.encode_method) + this.req_solt_data = e.req_fields + this.res_solt_data = e.res_fields + this.req_solt_code_arr = e.req_fields_example + this.res_solt_code_arr = e.res_fields_example + } + }); + }, changePageSize(value) { this.pageSize = value; this.currentPage = 1; this.get_use_list(); }, + transchangePageSize(value) { + this.transpageSize = value; + this.transcurrentPage = 1; + this.get_trans_data() + }, changeCurrentPage(value) { this.currentPage = value; this.get_use_list(); }, + transchangeCurrentPage(value) { + this.transcurrentPage = value; + this.get_trans_data() + }, + iconChange (val) { + // el-select实际上是两层div包裹的input + this.port_select = val; + // 获取当前el-select标签第一层div + const dom = this.$refs['select_icon'].$el; + if(dom.children[0].children[0].tagName == 'SPAN'){ + dom.children[0].children[0].remove() + } + // 创建需要添加到其中的标签 并填充内容 + const svgDom = document.createElement('span'); // (''); + svgDom.setAttribute('class', 'el-input__prefix'); + if(val.split(',')[1]=='true'){ + svgDom.innerHTML = ''; + }else{ + svgDom.innerHTML = '故障'; + } + // 将创建的标签添加到父节点(第二层div) + dom.children[0].appendChild(svgDom); + // 得到el-select中的input标签 + const inputDom = dom.children[0].children[0]; + inputDom.setAttribute('style', 'padding-left: 60px;'); + // 将添加的标签放到input前面 + dom.children[0].insertBefore(svgDom, inputDom); + + this.getData() + }, get_use_list() { this.service_use_arr = []; this.$http @@ -588,6 +1211,11 @@ export default { ? `访问次数:${e.request_spcs.count}/日 访问量:${e.request_spcs.pv}/日` : "", sqsc: e.duration + ["", "个月", "年"][e.duration_unit || 0], + jkmc:'', + jkdz:'', + state:'', + time:'', + count:'' }); }); } @@ -606,6 +1234,11 @@ export default { if (data.success == 1) { this.$store.commit("userInfofun", data.data); this.now_user = this.level; + if(this.now_user==1||this.now_user==2){ + this.in_origin_ser = true + }else{ + this.in_origin_ser = false + } console.log(this.level); } else { console.log(data.errMsg); @@ -618,6 +1251,29 @@ export default { this.datas = response.data.elements; }); }, + get_trans_data(){ + this.$http + .get( + `/apaas/service/v3/service/manager/service/trade/list?page=${this.currentPage}&size=${this.pageSize}&service_id=${this.$route.params.id}` + ).then(res=>{ + console.log(res); + // listTotal: 0, + if(res.data.success){ + this.listTotal = res.data.total + var temp = res.data.data||[] + temp.forEach(e => { + if(e.spcs_type==1){ + e.duration_name = '不限时长' + e.gg = `${e.spcs_count}次/ ${e.single_money} 元` + }else if(e.spcs_type==2){ + e.duration_name = e.duration+'月' + e.gg = `${e.single_money} 元/月` + } + }); + this.trans_log_data = temp + } + }) + }, getServiceInfo() { this.$http .get( @@ -627,16 +1283,24 @@ export default { .then((response) => { if (response.data.success === 1) { let data = response.data.data; - this.namespace = data.namespace; + this.namespace = data.urls[0].namespace; if(data.workflows_id){ this.workflows_id = data.workflows_id + }else{ + this.workflows_id = false } this.$set(this.service_header_arr, "portal_id", data.portal_id); // 时空服务id + this.$set(this.service_header_arr, "workflows_id", data.workflows_id); // 时空服务id this.$set( this.service_header_arr, "isMap", data.data_service_type1 === 6 ); + this.$set( + this.service_header_arr, + "isProcess", + data.data_service_type2 === 24 + ); this.$set(this.service_header_arr, "name", data.name); this.$set( this.service_header_arr["first"][0], @@ -672,6 +1336,59 @@ export default { "fixedurl", this.$route.path.replace("servicedetail", "serviceedit") ); + this.trans_all_obj={ + all:data.sale_total_money, + times:data.sale_total, + month:data.sale_month_total, + } + //判断是否是服务注册出来的流程服务 + if(data.data_service_type2 == 24&&data.workflows_id==0){ + this.process_in_up = true + this.$set(this.process_in_up_arr[0],'info',data.doc_file.split('/')[data.doc_file.split('/').length-1]) + this.$set(this.process_in_up_arr[0],'url',data.doc_file) + var temp_port_arr = [] + data.urls.forEach(e => { + temp_port_arr.push({ + label:e.req_name, + value:e.req_url, + able:e.state==-1?false:true, + ...e + }) + }); + this.port_options = temp_port_arr + if(this.port_options[0]){ + this.port_select = this.port_options[0].value + this.$set(this.port_solt_arr[0],'info',this.port_options[0].value) + this.$set(this.port_solt_arr[1],'info',this.port_options[0].req_type) + this.$set(this.port_solt_arr[2],'info',this.port_options[0].encode_method) + this.req_solt_data = this.port_options[0].req_fields + this.res_solt_data = this.port_options[0].res_fields + this.req_solt_code_arr = this.port_options[0].req_fields_example + this.res_solt_code_arr = this.port_options[0].res_fields_example + } + }else{ + this.process_in_up = false + } + + if(data.service_data_type_1 == 10){ + this.perception_in = true + this.$set(this.gz_solt_arr[0],'info',data.urls[0].req_url) + this.$set(this.gz_solt_arr[1],'info',data.urls[0].encode_method) + this.req_gz_solt_data = data.urls[0].req_fields + this.res_gz_solt_data = data.urls[0].res_fields + this.req_solt_code_arr = data.urls[0].req_fields_example + this.res_solt_code_arr = data.urls[0].res_fields_example + + }else{ + this.perception_in = false + } + console.log(this.process_in_up,this.perception_in); + if(this.process_in_up){ + this.get_trans_data() + var temp_sj = this.service_header_arr.first.pop() + this.service_header_arr.second = [] + this.service_header_arr.second.push(temp_sj) + } this.$set(this.list_arr[0], "info", data.descript); this.$set(this.list_arr[1], "info", data.sectors_name); this.$set(this.list_arr[2], "info", data.organization_name); @@ -716,15 +1433,23 @@ export default { this.$set(this.servicead_arr[5], "info", "无响应示例"); } // 接口详情信息 end - - this.service_size_data = data.request_spcs_info; - this.size_arr_down = data.request_spcs_info; - this.buy_type = data.request_spcs_info[0].type; - if (this.buy_type == 3) { - this.buy_style = [1, 2]; - } else { - this.buy_style = [this.buy_type]; - } + var temp = data.request_spcs_info||[] + temp.forEach((e,idx) => { + e.index = idx+1 + if(e.spcs_type==1){ + e.gg = e.money+'/'+e.spcs_count + e.time = '不限时长' + e.pv = e.spcs_count + e.d_price = e.money + }else if(e.spcs_type==1){ + e.gg = e.money+'/月' + e.time = '1个月' + e.pv = '不限次数' + e.d_price = '-' + } + }); + this.service_size_data =temp; + this.size_arr_down =temp; } else { this.$message({ message: response.data.errMsg, @@ -736,6 +1461,28 @@ export default { }, now_size_data(val) { console.log(val); + val.forEach(e => { + if(e.spcs_type==1){ + if(e.pv=='不限次数'){ + e.pv = '' + e.time = '' + e.descript = '' + e.money = '' + e.d_price = '' + } + e.time = '不限时长' + e.descript = '提供'+e.pv+'次服务,时长不限' + if(e.money&&e.pv){ + e.d_price = parseInt(e.money/e.pv)+'金币/次' + } + }else if(e.spcs_type==2){ + e.pv = '不限次数' + e.d_price = '-' + e.time = '按月' + e.descript = '每月不限调用次数' + } + + }); this.size_arr_down = val; }, getsize_arr() { @@ -747,38 +1494,41 @@ export default { .then((response) => { let data = response.data.data; console.log(data); - this.service_size_data = data.data; - this.buy_type = data.data[0].type; - if (this.buy_type == 3) { - this.buy_style = [1, 2]; - } else { - this.buy_style = [this.buy_type]; - } + var temp = data.data||[] + temp.forEach((e,idx) => { + e.index = idx+1 + if(e.spcs_type==1){ + e.gg = e.money+'/'+e.spcs_count + e.time = '不限时长' + e.pv = e.spcs_count + e.d_price = '' + }else if(e.spcs_type==1){ + e.gg = e.money+'/月' + e.time = '1个月' + e.pv = '不限次数' + e.d_price = '-' + } + }); + this.service_size_data = temp; }) .catch(function(response) {}); }, change_service_size() { let temp = []; + this.size_arr_down.forEach((e) => { - if (e.pv && e.count) { - if (e.flag) { - e.id = 0; - } - if (this.buy_style.length == 0) { - this.$message.error("请选择申请时长"); - return; - } else if (this.buy_style.length == 2) { - e.type = 3; - } else { - e.type = this.buy_style[0]; - } + if (e.pv && e.money&&e.spcs_type) { + e.id = 0 delete e.undefined; delete e.flag; - e.pv = parseInt(e.pv); - e.count = parseInt(e.count); + e.spcs_count = e.spcs_type==1?parseInt(e.pv):0; + e.money = parseFloat(e.money); + e.duration=1 + e.duration_unit=1 temp.push(e); } }); + console.log(this.size_arr_down); this.$http .post("/apaas/service/v3/service/manager/request/spcs/save", { service_id: parseInt(this.$route.params.id), @@ -843,6 +1593,10 @@ export default { background-color: #c3caf8; color: #0f2683; } +.service_port .el-input__inner{ + width: 785px; + background-color: #f7f8f9; +} diff --git a/src/pages/workbench/fwzc_fwcs.vue b/src/pages/workbench/fwzc_fwcs.vue index 9294b06ca073c1bfa49359adcc0a23c76acf1411..96d26bb11b26629f6b61ce6d60a3246aacfb44f8 100644 --- a/src/pages/workbench/fwzc_fwcs.vue +++ b/src/pages/workbench/fwzc_fwcs.vue @@ -1,19 +1,33 @@