Commit d394f721 by 匡雅琴

第一轮测试bug修复,样式修改

1 parent 64782f23
...@@ -58,7 +58,8 @@ const createRole = params => { ...@@ -58,7 +58,8 @@ const createRole = params => {
url: '/rop-merchants/router', url: '/rop-merchants/router',
method: 'POST', method: 'POST',
data: params, data: params,
sign: true sign: true,
returnAll: true
}) })
} }
const updateRole = params => { const updateRole = params => {
......
...@@ -227,3 +227,11 @@ img { ...@@ -227,3 +227,11 @@ img {
} }
} }
} }
.role-border {
border: 1px solid #e5e5e5;
}
.role-border-b {
border-bottom: 1px solid #e5e5e5;
}
...@@ -52,7 +52,7 @@ export default { ...@@ -52,7 +52,7 @@ export default {
merchantId: '', merchantId: '',
roleName: '', roleName: '',
roleDesc: '', roleDesc: '',
roleAuth: '' roleAuth: []
}, },
rules: { rules: {
roleName: [{ required: true, message: '请输入角色名称', trigger: 'blur' }], roleName: [{ required: true, message: '请输入角色名称', trigger: 'blur' }],
...@@ -136,8 +136,11 @@ export default { ...@@ -136,8 +136,11 @@ export default {
requestList: accountTypes requestList: accountTypes
} }
this.$apis.role.createRole(para).then(res => { this.$apis.role.createRole(para).then(res => {
console.log(res, '====') if (res.code == -1) {
res ? this.$message.success('操作成功') : this.$message.error('操作失败') this.$message.error(res.message)
return
}
this.$message.success('操作成功')
this.$emit('updataRole', true) this.$emit('updataRole', true)
this.roleVisible = !res this.roleVisible = !res
this.ruleForm = { this.ruleForm = {
......
<template> <template>
<div class="account-body" v-loading="loading" v-if="tabMenuStatus"> <div class="account-body" v-loading="loading" v-if="tabMenuStatus">
<!-- <div class="account-title">{{ title }}</div> --> <!-- <div class="account-title">{{ title }}</div> -->
<el-tabs v-if="tabMenu.length != 0" v-model="tabName" type="card" @tab-click="handleClik"> <el-tabs v-if="tabMenu.length != 0" v-model="tabName" @tab-click="handleClik">
<template v-for="(item, index) in tabMenu"> <template v-for="(item, index) in tabMenu">
<el-tab-pane v-show="item && item.accounttypeId" :label="item.accounttypeName" :name="item.accounttypeId" v-if="item" :key="index"></el-tab-pane> <el-tab-pane :label="item.accounttypeName" :name="item.accounttypeId + ''" v-if="item && item.accounttypeId" :key="index"></el-tab-pane>
</template> </template>
</el-tabs> </el-tabs>
<div class="account-select-pro" v-for="(item, index) in tabMenu" :key="index" v-show="tabName == item.accounttypeId"> <div class="account-select-pro" v-for="(item, index) in tabMenu" :key="index" v-show="tabName == item.accounttypeId">
...@@ -451,34 +451,45 @@ export default { ...@@ -451,34 +451,45 @@ export default {
.el-checkbox:last-of-type { .el-checkbox:last-of-type {
margin-right: 8px; margin-right: 8px;
} }
.el-tabs--card > .el-tabs__header .el-tabs__nav { .el-tabs {
border: 0;
}
.el-tabs--card > .el-tabs__header {
border: 0;
border-bottom: 1px solid #e5e5e5; border-bottom: 1px solid #e5e5e5;
// background-color: #f4f6fc; margin-bottom: 20px;
}
.el-tabs--card > .el-tabs__header .el-tabs__item {
position: relative;
border: none;
// width: 180px;
margin: 2px;
text-align: center;
&::after {
content: '';
display: inline-block;
width: calc(100% - 40px);
height: 2px;
background-color: #5850ff;
position: absolute;
bottom: -2px;
left: 20px;
} }
.el-tabs__header {
margin: 0;
padding: 0 30px;
} }
.el-tabs__item.is-active { .el-tabs__nav-wrap::after {
background-color: #fff; content: none;
} }
// .el-tabs--card > .el-tabs__header .el-tabs__nav {
// border: 0;
// }
// .el-tabs--card > .el-tabs__header {
// border: 0;
// border-bottom: 1px solid #e5e5e5;
// // background-color: #f4f6fc;
// }
// .el-tabs--card > .el-tabs__header .el-tabs__item {
// position: relative;
// border: none;
// // width: 180px;
// margin: 2px;
// text-align: center;
// &::after {
// content: '';
// display: inline-block;
// width: calc(100% - 40px);
// height: 2px;
// background-color: #5850ff;
// position: absolute;
// bottom: -2px;
// left: 20px;
// }
// }
// .el-tabs__item.is-active {
// background-color: #fff;
// }
.el-form-item { .el-form-item {
margin-bottom: 0 !important; margin-bottom: 0 !important;
} }
......
<template> <template>
<div class="account-body scrm-box-f" v-loading="loading" v-if="tabMenuStatus"> <div class="account-body scrm-box-f role-border" v-loading="loading" v-if="tabMenuStatus">
<!-- <div class="account-title">{{ title }}</div> --> <!-- <div class="account-title">{{ title }}</div> -->
<el-tabs v-if="tabMenu.length != 0" v-model="tabName" @tab-click="handleClik"> <el-tabs v-if="tabMenu.length != 0" v-model="tabName" @tab-click="handleClik">
<template v-for="(item, index) in tabMenu"> <template v-for="(item, index) in tabMenu">
<el-tab-pane v-show="item && item.accounttypeId" :label="item.accounttypeName" :name="item.accounttypeId" v-if="item" :key="index"></el-tab-pane> <el-tab-pane :label="item.accounttypeName" :name="item.accounttypeId + ''" v-if="item && item.accounttypeId" :key="index">{{ item.accounttypeId }}</el-tab-pane>
</template> </template>
</el-tabs> </el-tabs>
<div class="account-select-pro" v-for="(item, index) in tabMenu" :key="index" v-show="tabName == item.accounttypeId"> <div class="account-select-pro" v-for="(item, index) in tabMenu" :key="index" v-show="tabName == item.accounttypeId">
...@@ -107,6 +107,8 @@ export default { ...@@ -107,6 +107,8 @@ export default {
this.productTab = productId this.productTab = productId
}, },
findMenuFunTree(id, status) { findMenuFunTree(id, status) {
console.log(id, status)
// this.tabName = id + ''
let menu = util.deepClone(this.tabMenu) let menu = util.deepClone(this.tabMenu)
let tabMenu = util.deepClone(this.tabMenu_r) let tabMenu = util.deepClone(this.tabMenu_r)
let menuSelect = tabMenu.filter(item => item.accounttypeId == id) let menuSelect = tabMenu.filter(item => item.accounttypeId == id)
...@@ -445,7 +447,7 @@ export default { ...@@ -445,7 +447,7 @@ export default {
<style scoped lang="scss"> <style scoped lang="scss">
.account-body { .account-body {
border: 1px solid #e5e5e5; // border: 1px solid #e5e5e5;
border-radius: 2px; border-radius: 2px;
/deep/ { /deep/ {
.el-tabs { .el-tabs {
...@@ -461,9 +463,6 @@ export default { ...@@ -461,9 +463,6 @@ export default {
.el-tabs__nav-wrap::after { .el-tabs__nav-wrap::after {
content: none; content: none;
} }
.el-tabs__active-bar {
width: 100%;
}
} }
.account-select-pro { .account-select-pro {
padding-left: 30px; padding-left: 30px;
......
...@@ -59,9 +59,9 @@ ...@@ -59,9 +59,9 @@
</div> </div>
</el-col> </el-col>
</el-row> </el-row>
<div class="role-detail"> <!-- <div > -->
<SelectProduct ref="productFrom" :roleType="true"></SelectProduct> <SelectProduct class="role-detail" ref="productFrom" :roleType="true"></SelectProduct>
</div> <!-- </div> -->
</div> </div>
<GLFooter style="z-index: 1"> <GLFooter style="z-index: 1">
<el-button @click="toBack">取消</el-button> <el-button @click="toBack">取消</el-button>
...@@ -359,10 +359,11 @@ export default { ...@@ -359,10 +359,11 @@ export default {
margin-top: 16px; margin-top: 16px;
background: #ffffff; background: #ffffff;
margin-bottom: 80px; margin-bottom: 80px;
padding-bottom: 32px; // padding-bottom: 32px;
overflow: hidden;
} }
.role-detail { .role-detail {
padding: 0 20px; margin: 0 20px 32px 20px;
} }
.role-create-page { .role-create-page {
height: 100%; height: 100%;
...@@ -370,7 +371,7 @@ export default { ...@@ -370,7 +371,7 @@ export default {
background: #ffffff; background: #ffffff;
} }
.role-list { .role-list {
padding: 40px 0 0 104px; padding: 40px 0 20px 104px;
} }
.top_title_widget { .top_title_widget {
width: 100%; width: 100%;
......
...@@ -19,9 +19,9 @@ ...@@ -19,9 +19,9 @@
</div> </div>
</div> </div>
<div class="main_widget"> <div class="main_widget">
<div class="main_title">角色权限</div> <div class="main_title role-border-b">角色权限</div>
<div class="wrapper"> <div class="wrapper role-border">
<div class="menu_line_one" :style="rootList.length ? '' : 'padding:0'"> <div class="menu_line_one role-border-b" :style="rootList.length ? '' : 'padding:0'">
<div v-for="(item, index) in rootList" :key="index" class="line_element" :class="curRootIndex == index ? 'line_element_active' : ''" @click="selectRootItem(index)"> <div v-for="(item, index) in rootList" :key="index" class="line_element" :class="curRootIndex == index ? 'line_element_active' : ''" @click="selectRootItem(index)">
{{ item.accounttypeName }} {{ item.accounttypeName }}
<div class="tab_line" v-show="curRootIndex == index"></div> <div class="tab_line" v-show="curRootIndex == index"></div>
...@@ -29,9 +29,9 @@ ...@@ -29,9 +29,9 @@
</div> </div>
<div class="main_body"> <div class="main_body">
<div class="menu_line_two"> <div class="menu_line_two">
<div v-for="(item, index) in productList" :key="index" class="line_element_two" :class="curProductIndex == index ? 'line_element_two_active' : ''" @click="selectProductItem(index)">{{ item.productName }}</div> <div v-for="(item, index) in productList" :key="index" class="line_element_two role-border" :class="curProductIndex == index ? 'line_element_two_active' : ''" @click="selectProductItem(index)">{{ item.productName }}</div>
</div> </div>
<div class="tree_widget"> <div class="tree_widget role-border">
<el-tree :render-content="renderContent" v-if="productList.length" default-expand-all :data="newTreeList" :props="defaultProps"></el-tree> <el-tree :render-content="renderContent" v-if="productList.length" default-expand-all :data="newTreeList" :props="defaultProps"></el-tree>
<div v-if="productList.length == 0" class="no_data_icon"> <div v-if="productList.length == 0" class="no_data_icon">
<div class="nodata_wrap"> <div class="nodata_wrap">
...@@ -196,6 +196,7 @@ export default { ...@@ -196,6 +196,7 @@ export default {
border-radius: 4px; border-radius: 4px;
position: absolute; position: absolute;
left: 50%; left: 50%;
top: 38px;
transform: translate(-50%, 0); transform: translate(-50%, 0);
} }
.role-create-page { .role-create-page {
...@@ -253,6 +254,7 @@ export default { ...@@ -253,6 +254,7 @@ export default {
min-height: calc(100% - 300px); min-height: calc(100% - 300px);
background: #ffffff; background: #ffffff;
box-shadow: 0px 10px 20px 0px rgba(88, 80, 255, 0.1); box-shadow: 0px 10px 20px 0px rgba(88, 80, 255, 0.1);
padding-bottom: 20px;
.main_title { .main_title {
width: 100%; width: 100%;
box-sizing: border-box; box-sizing: border-box;
...@@ -260,12 +262,12 @@ export default { ...@@ -260,12 +262,12 @@ export default {
font-size: 16px; font-size: 16px;
font-weight: 600; font-weight: 600;
color: #333333; color: #333333;
border-bottom: 1px solid #e5e5e5; // border-bottom: 1px solid #e5e5e5;
} }
.wrapper { .wrapper {
// border: 1px solid #e5e5e5;
box-sizing: border-box; box-sizing: border-box;
padding: 20px 20px; margin: 20px 20px;
padding-bottom: 20px;
.menu_line_one { .menu_line_one {
width: 100%; width: 100%;
height: 48px; height: 48px;
...@@ -273,6 +275,7 @@ export default { ...@@ -273,6 +275,7 @@ export default {
align-items: center; align-items: center;
box-sizing: border-box; box-sizing: border-box;
padding: 0px 32px; padding: 0px 32px;
// border-bottom: 1px solid #e5e5e5;
.line_element { .line_element {
position: relative; position: relative;
height: 32px; height: 32px;
...@@ -290,11 +293,9 @@ export default { ...@@ -290,11 +293,9 @@ export default {
} }
} }
.main_body { .main_body {
width: 100%; border-radius: 0 0 4px 4px;
border-radius: 4px;
box-sizing: border-box; box-sizing: border-box;
border: 1px solid #e5e5e5; margin: 20px;
margin: 10px;
.menu_line_two { .menu_line_two {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
...@@ -305,9 +306,11 @@ export default { ...@@ -305,9 +306,11 @@ export default {
height: 40px; height: 40px;
text-align: center; text-align: center;
line-height: 40px; line-height: 40px;
background: #ffffff; background: #fafafa;
border-radius: 4px 0px 0px 0px; border-radius: 4px 4px 0px 0px;
border: 1px solid #f4f6fc; // border: 1px solid #e5e5e5;
border-bottom: none;
margin-right: 2px;
color: #37383a; color: #37383a;
font-size: 14px; font-size: 14px;
font-weight: 400; font-weight: 400;
...@@ -315,12 +318,14 @@ export default { ...@@ -315,12 +318,14 @@ export default {
} }
.line_element_two_active { .line_element_two_active {
color: #322ad9; color: #322ad9;
background-color: #ffffff;
} }
} }
.tree_widget { .tree_widget {
width: 100%; width: 100%;
// height: calc(100% - 40px); // height: calc(100% - 40px);
background: #ffffff; background: #ffffff;
// border: 1px solid #e5e5e5;
border-radius: 0px 4px 4px 4px; border-radius: 0px 4px 4px 4px;
// height: 200px; // height: 200px;
// overflow: auto; // overflow: auto;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!