Commit 0c53a5a8 by 杨北旺

角色管理/创建角色/修改角色

2 parents 3e06ae54 a9d049a6
......@@ -6,46 +6,46 @@
* @param {*} params
* @returns
*/
import { http } from '@/main'
import { http_config } from '@/main'
const getMerchantTree = params => {
params.method = 'org.ore.api.common.findMerchantTreeByMerchantNo.list'
return http({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'org.ore.api.common.findMerchantTreeByMerchantNo.list'
return http_config({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
const getDepartment = params => {
params.method = 'cn.com.glsx.entmicro.department.listDepartmentTree'
return http({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'cn.com.glsx.entmicro.department.listDepartmentTree'
return http_config({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
const toGL = params => {
params.method = 'org.ore.api.common.relevanceEntmicro.list'
return http({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'org.ore.api.common.relevanceEntmicro.list'
return http_config({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
const merchantInfo = params => {
params.method = 'org.ore.api.common.findMerchantInfoByMerchantNo.list'
return http({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
params.method = 'org.ore.api.common.findMerchantInfoByMerchantNo.list'
return http_config({
url: '/rop-scrm-entmicro/router',
method: 'POST',
data: params,
sign: true
})
}
export default {
getMerchantTree,
getDepartment,
toGL,
merchantInfo
getMerchantTree,
getDepartment,
toGL,
merchantInfo
}
\ No newline at end of file
<template>
<div disabled class="btn-unselect" :class="{ 'selectd-type': typeStatus }" @click="tabType">
<div disabled class="btn-unselect" :class="{ 'selectd-type': typeStatus,'no_click': stopClick }" @click="tabType">
<span class="select-type-title">{{ btnLabel }}</span
><i class="btn-icon" :class="{ 'el-icon-check': typeStatus }"></i>
</div>
......@@ -64,6 +64,9 @@ export default {
background: #5850ff;
}
}
&.no_click {
cursor: not-allowed!important;
}
.select-type-title {
display: inline-block;
padding: 0 16px;
......
......@@ -11,7 +11,6 @@
</template>
<script>
import AMap from "AMap";
let map, placeSearch;
export default {
name: "map",
......
......@@ -27,4 +27,5 @@ start()
export { bootstrap, mount, unmount }
from '@/setup'
export const http = params => Vue.prototype.$http(params)
export const http_common = params => Vue.prototype.$http_common(params)
\ No newline at end of file
export const http_common = params => Vue.prototype.$http_common(params)
export const http_config = params => Vue.prototype.$http_config(params)
\ No newline at end of file
......@@ -13,7 +13,7 @@ let routes = []
let router = null
let instance = null
export async function bootstrap({ name, id, history, common, messenger, globalState }) {
const { response, request, sign, secret, request_common } = await fetchConfig()
const { response, request, sign, secret, request_common, request_config } = await fetchConfig()
console.log(request)
Vue.prototype.$history = history
Vue.prototype.$messenger = messenger
......@@ -22,6 +22,7 @@ export async function bootstrap({ name, id, history, common, messenger, globalSt
Vue.prototype.$common = common
Vue.prototype.$http = new common.Http({ response, request, sign, secret, alert: ElementUI.Message.error, headers: { TGT: globalState.session.token } })
Vue.prototype.$http_common = new common.Http({ response, request: request_common, sign, secret, alert: ElementUI.Message.error, headers: { TGT: globalState.session.token } })
Vue.prototype.$http_config = new common.Http({ response, request: request_config, sign, secret, alert: ElementUI.Message.error, headers: { token: globalState.session.token } })
// Vue.prototype.$setGlobalState = globalState.actions.setGlobalState
Vue.use(GLButton, { permissions: globalState.permissions || ['1-1-1-1', '2-1-1-1', '3-1-1-1'] })
const routesData = common.utils.deepClone(globalState.routers)
......
......@@ -3,14 +3,12 @@
<div v-show="step == 1">
<div class="account-header scrm-flex-between scrm-box-f">
<span>创建子商户/门店</span>
<el-select v-model="status" slot="prepend" placeholder="请选择">
<el-option label="门店" :value="1"></el-option>
<el-option label="商户" :value="2"></el-option>
</el-select>
</div>
<div class="account-body scrm-box-f">
<div class="form-title">企业基本信息</div>
<el-form
<base-info ref="baseInfoForm" :brandData="brandData" :accountAddForm="accountAddForm" :businessScopeCustomize="businessScopeCustomize" :businessOption="businessOption"></base-info>
<!-- <el-form
ref="baseForm"
:model="accountAddForm"
class="account-body-form"
......@@ -39,9 +37,9 @@
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="商户类型" class="merchant-row">
<el-form-item
size="small" label="商户类型" class="merchant-row">
<el-input
size="small"
v-model="accountAddForm.merchantOrgcode"
placeholder="请输入组织机构号码"
v-if="accountAddForm.merchantType == 2"
......@@ -75,10 +73,11 @@
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-col :span="24">
<el-form-item size="small" label="商户地址" class="form-row">
<el-input v-model="accountAddForm.merchantAddress"> </el-input>
<el-button
readonly
type="primary"
class="form-btn"
@click="dialogMapVisible = true"
......@@ -239,7 +238,7 @@
</el-form-item>
</el-col>
</el-row>
</el-form>
</el-form> -->
</div>
<div class="account-body scrm-box-f">
<div class="form-title">账户信息</div>
......@@ -373,12 +372,14 @@ import util from "@/utils/util";
import mapView from "@/components/mapView/index";
import autoButton from "@/components/auto-button/index";
import selectProduct from "./components/selectProduct";
import baseInfo from "./components/baseInfo";
export default {
name: "index",
components: {
mapView,
autoButton,
selectProduct,
baseInfo
},
data() {
const validatePhone = (rule, value, callback) => {
......@@ -406,7 +407,7 @@ export default {
businessScopeCustomize: [{ name: "" }],
accountAddForm: {
status: 1,
merchantType: "1",
merchantType: 1,
businessScope: [],
parentId: "",
isloginName: false,
......@@ -519,7 +520,7 @@ export default {
//下一步
handleNext() {
const pm1 = new Promise((resolve, reject) => {
this.$refs.baseForm.validate((valid) => {
this.$refs.baseInfoForm.$refs.baseForm.validate((valid) => {
if (valid) resolve();
});
});
......@@ -548,7 +549,8 @@ export default {
if (params.businessScope) {
params.businessScope = params.businessScope.join(",");
}
params.merchantBrand = this.$refs.brandTree.getCheckedKeys().join(",");
console.log(this.$refs.baseInfoForm)
params.merchantBrand = this.$refs.baseInfoForm.$refs.brandTree.getCheckedKeys().join(",");
params.isloginName ? (params.isloginName = 1) : (params.isloginName = 0);
params.merchantAccountLevel = this.accountDetail.merchantAccountLevel;
let businessScopeCustomize = this.businessScopeCustomize.map((item) => item.name);
......@@ -568,7 +570,7 @@ export default {
this.nextStatus = true;
if (typeof res == "number") {
this.parentId = res;
this.findMenuFunTreeByMerId();
this.$refs.productForm.findMenuFunTreeByMerId();
}
this.twoMerchantDetail(this.parentId);
}
......
<template>
<div class="base-info">
<el-form
ref="baseForm"
:model="accountAddForm"
class="account-body-form"
label-width="120px"
:rules="baseRules"
>
<el-row>
<el-col :span="12">
<el-form-item label="商户名称" prop="merchantName">
<el-input
size="small"
v-model="accountAddForm.merchantName"
placeholder="请输入商户名称"
></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="商户简称">
<el-input
size="small"
v-model="accountAddForm.merchantAbbreviation"
placeholder="请输入商户简称"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item size="small" label="商户类型" class="merchant-row">
<el-input
v-model="accountAddForm.merchantOrgcode"
placeholder="请输入组织机构号码"
v-if="accountAddForm.merchantType == 2"
>
<el-select
v-model="accountAddForm.merchantType"
slot="prepend"
placeholder="请选择"
>
<el-option label="个人" value="1"></el-option>
<el-option label="企业" value="2"></el-option>
</el-select>
</el-input>
<el-input
size="small"
maxlength="18"
v-model="accountAddForm.merchantOrgcode"
placeholder="请输入正确的身份证号"
v-if="accountAddForm.merchantType == 1"
>
<el-select
v-model="accountAddForm.merchantType"
slot="prepend"
placeholder="请选择"
>
<el-option label="个人" :value="1"></el-option>
<el-option label="企业" :value="2"></el-option>
</el-select>
</el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<el-form-item size="small" label="商户地址" class="form-row">
<el-input readonly v-model="accountAddForm.merchantAddress"> </el-input>
<el-button
type="primary"
class="form-btn"
@click="dialogMapVisible = true"
>选择地址</el-button
>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="联系电话" prop="merchantLegalPersonPhone">
<el-input
maxlength="11"
size="small"
v-model="accountAddForm.merchantLegalPersonPhone"
placeholder="请输入联系电话"
></el-input>
<el-checkbox v-model="accountAddForm.isloginName"
>联系电话同时作为登录账户名</el-checkbox
>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="联系人">
<el-input
size="small"
v-model="accountAddForm.merchantLegalPerson"
placeholder="请输入联系人"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="驻店联系人">
<el-input
maxlength="11"
size="small"
v-model="accountAddForm.residentContact"
placeholder="请输入驻店联系人"
></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="驻店电话">
<el-input
maxlength="11"
size="small"
v-model="accountAddForm.residentPhone"
placeholder="请输入驻店电话"
></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="营业范围">
<el-checkbox-group v-model="accountAddForm.businessScope">
<el-checkbox
v-for="item in businessOption"
:label="item.dictValue"
:key="item"
>{{ item.dictLabel }}</el-checkbox
>
</el-checkbox-group>
<div
class="scrm-flex-center"
v-for="(item, index) in businessScopeCustomize"
:key="index"
>
<el-input
size="small"
v-model="businessScopeCustomize[index].name"
placeholder="请自定义营业范围,建议不超过10个"
></el-input>
<i
class="el-icon-circle-plus el-icon-btn"
@click="addBusinessScope"
v-if="index == businessScopeCustomize.length - 1"
></i>
<i
class="el-icon-remove el-icon-btn"
@click="removeBusinessScope"
v-else
></i>
</div>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="营业时间" class="open-time">
<el-time-picker
size="small"
value-format="HH:mm:ss"
is-range
v-model="accountAddForm.bussinessTime"
range-separator="至"
start-placeholder="开始时间"
end-placeholder="结束时间"
placeholder="选择时间范围"
></el-time-picker>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="12">
<el-form-item label="主营品牌">
<el-input size="small" v-model="filterText"></el-input>
<div class="brand-tree">
<el-tree
:data="brandData"
show-checkbox
default-expand-all
node-key="id"
ref="brandTree"
highlight-current
:props="defaultProps"
:filter-node-method="filterNode"
>
</el-tree>
</div>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="门店照片">
<div class="store-upload-list">
<template
v-if="
accountAddForm.merchantFiles && accountAddForm.merchantFiles.length > 0
"
>
<div
:key="index"
v-for="(item, index) in accountAddForm.merchantFiles"
class="store-border"
>
<img :src="item.fileUrl" />
<div class="uploader-del-icon">
<i class="el-icon-delete-solid" @click.stop="delImg(index)"></i>
</div>
</div>
</template>
<el-upload
action=""
class="image-uploader"
:show-file-list="false"
list-type="picture-card"
v-loading="loadingImg"
:before-upload="upLoadImg"
>
<i class="el-icon-plus"></i>
</el-upload>
</div>
<div class="tips">图片格式仅支持JPG,PNG格式,大小1M</div>
</el-form-item>
</el-col>
</el-row>
</el-form>
<el-dialog :visible.sync="dialogMapVisible" width="60%">
<map-view ref="mapForm" :mapHeight="mapHeight"></map-view>
<span slot="footer" class="dialog-footer">
<el-button @click="dialogMapVisible = false">取 消</el-button>
<el-button type="primary" @click="getAddress">确 定</el-button>
</span>
</el-dialog>
</div>
</template>
<script>
import util from "@/utils/util";
import mapView from "@/components/mapView/index";
export default {
name: "base",
components: {
mapView,
},
props: {
accountAddForm: {
type: Object,
},
businessOption: {
type: Array,
},
brandData: {
type: Array,
},
businessScopeCustomize: {
type: Array,
}
},
data() {
const validatePhone = (rule, value, callback) => {
if (!util.checkPhone(value)) {
callback(new Error("请输入正确的手机号"));
} else {
callback();
}
};
return {
filterText: "",
defaultProps: {
children: "children",
label: "label",
},
dialogMapVisible: false,
mapHeight: 300,
baseRules: {
merchantName: [{ required: true, message: "请输入商户名称", trigger: "blur" }],
merchantLegalPersonPhone: [
{ required: true, message: "请输入联系电话", trigger: "blur" },
{ validator: validatePhone, trigger: "blur" },
],
},
};
},
methods: {
getAddress() {
this.dialogMapVisible = false;
this.accountAddForm.merchantAddress = this.$refs.mapForm.address;
},
delImg(index) {
this.accountAddForm.merchantFiles.splice(index, 1);
},
addBusinessScope() {
this.businessScopeCustomize.push({ name: "" });
},
removeBusinessScope(index) {
this.businessScopeCustomize.splice(index, 1);
},
upLoadImg(file) {
let fileName = file.name;
if (file.name.lastIndexOf(".") === -1) {
this.$message.info("路径不正确");
return false;
}
let AllImgExt = ".jpg|.jpeg|.gif|.bmp|.png|.swf";
let extName = file.name.substring(file.name.lastIndexOf(".")).toLowerCase();
if (AllImgExt.indexOf(extName + "|") === -1) {
this.$message.info("图片格式不正确");
return false;
}
// if (fileSize < 3145728) {
if (window.FileReader) {
let reader = new FileReader();
let self = this;
reader.readAsDataURL(file);
reader.onload = (img) => {
console.log(file);
let type = fileName.split(".")[1];
let imgUrl = img.target.result.split(",")[1];
self.loadingImg = true;
self.$apis.common
.pictureUpload({
file: `${type}@${imgUrl}`,
})
.then((res) => {
if (res) {
self.accountAddForm.merchantFiles.push({
fileUrl: res,
});
}
});
};
}
},
},
mounted() {},
};
</script>
<style scoped lang="scss">
.base-info {
.account-body-form {
width: 80%;
margin: 20px auto;
.form-row {
/deep/ .el-form-item__content {
display: flex;
}
.form-btn {
margin-left: 10px;
}
}
.merchant-row {
/deep/ {
.el-form-item__content {
line-height: 1;
}
.el-select {
.el-input {
width: 80px;
}
}
}
}
.store-upload-list {
display: flex;
flex-wrap: wrap;
.store-border {
position: relative;
width: 120px;
height: 80px;
border-radius: 2px;
margin-right: 15px;
margin-bottom: 15px;
}
.uploader-del-icon {
position: absolute;
top: 0px;
right: 0px;
width: 30px;
height: 30px;
line-height: 30px;
background: rgba(0, 0, 0, 0.4);
border-radius: 0px 0px 0px 100px;
cursor: pointer;
}
.el-icon-delete-solid {
color: #c5c5c5;
font-size: 14px;
margin-left: 12px;
}
}
.image-uploader {
/deep/ .el-upload {
width: 120px;
height: 80px;
line-height: 80px;
}
}
.brand-tree {
height: 300px;
overflow-y: auto;
}
.open-time {
/deep/ {
.el-range-editor--small.el-input__inner {
width: 100%;
}
}
}
.el-icon-btn {
color: #5850ff;
font-size: 16px;
margin-left: 6px;
cursor: pointer;
}
.tips {
font-size: 14px;
font-weight: 400;
color: #999999;
line-height: 30px;
}
.btn-unselect {
display: inline-block;
cursor: pointer;
position: relative;
height: 30px;
line-height: 30px;
margin-top: 6px;
padding-right: 30px;
cursor: pointer;
font-size: 0;
-webkit-transition: 0.1s linear;
transition: 0.1s linear;
box-sizing: border-box;
&.selectd-type {
.select-type-title {
background: #5850ff;
}
}
.select-type-title {
display: inline-block;
padding: 0 16px;
height: 100%;
font-size: 14px;
border-radius: 2px 0 0 2px;
background-color: #d2d2d2;
color: #fff;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.btn-icon {
display: inline-block;
position: absolute;
right: 0;
top: 0;
width: 30px;
height: 28px;
line-height: 28px;
border: 1px solid #dcdfe6;
border-left: none;
border-radius: 2px 0px 0px 2px;
color: #5850ff;
font-size: 20px;
text-align: center;
}
}
}
}
</style>
\ No newline at end of file
......@@ -75,7 +75,8 @@
</div>
<div class="account-body scrm-box-f">
<div class="form-title">修改企业信息</div>
<el-form
<base-info ref="baseInfoForm" :brandData="brandData" :accountAddForm="accountAddForm" :businessScopeCustomize="businessScopeCustomize" :businessOption="businessOption"></base-info>
<!-- <el-form
ref="baseForm"
:model="accountAddForm"
class="account-body-form"
......@@ -299,7 +300,7 @@
</el-form-item>
</el-col>
</el-row>
</el-form>
</el-form> -->
</div>
</div>
<div v-show="step == 'first'">
......@@ -326,12 +327,14 @@
import mapView from "@/components/mapView/index";
import autoButton from "@/components/auto-button/index";
import selectProduct from "./components/selectProduct";
import baseInfo from "./components/baseInfo";
export default {
name: "index",
components: {
mapView,
autoButton,
selectProduct
selectProduct,
baseInfo
},
data() {
return {
......@@ -449,7 +452,7 @@ export default {
//下一步
handleNext() {
const pm1 = new Promise((resolve, reject) => {
this.$refs.baseForm.validate((valid) => {
this.$refs.baseInfoForm.$refs.baseForm.validate((valid) => {
if (valid) resolve();
});
});
......@@ -466,7 +469,7 @@ export default {
if (params.businessScope) {
params.businessScope = params.businessScope.join(",");
}
params.merchantBrand = this.$refs.brandTree.getCheckedKeys().join(",");
params.merchantBrand = this.$refs.baseInfoForm.$refs.brandTree.getCheckedKeys().join(",");
params.isloginName ? (params.isloginName = 1) : (params.isloginName = 0);
let businessScopeCustomize = this.businessScopeCustomize.map((item) => item.name);
params.businessScopeCustomize = businessScopeCustomize.join(",");
......@@ -540,7 +543,7 @@ export default {
for (let i in merchantBrand) {
merchantBrand[i] = parseInt(merchantBrand[i]);
}
this.$refs.brandTree.setCheckedKeys(merchantBrand);
this.$refs.baseInfoForm.$refs.brandTree.setCheckedKeys(merchantBrand);
});
},
getCarbrandTree() {
......
<template>
<div class="scrm-main">
<div class="form-header">
<el-button type="primary" @click="handleSearch" size="small" icon="el-icon-link"
>门店账户关联企微</el-button
>
</div>
<div class="form-header">
<el-button type="primary" @click="handleContact" size="small" icon="el-icon-link"
>门店账户关联企微</el-button
>
</div>
<div class="follow-form">
<el-form :inline="true" :model="searchForm" class="follow-form-item" label-width="80px">
<el-form
:inline="true"
:model="searchForm"
class="follow-form-item"
label-width="80px"
>
<el-row>
<el-form-item size="small" label="关联企微">
<el-select v-model="searchForm.isRelevance" placeholder="请选择">
<el-select v-model="searchForm.isRelevance" placeholder="请选择">
<el-option
v-for="item in optionsContact"
:key="item.value"
......@@ -18,8 +23,13 @@
></el-option>
</el-select>
</el-form-item>
<el-form-item class="merchant-row" size="small">
<el-input size="small" v-model="searchForm.merchantLoginAccount" placeholder="请输入" v-if="searchForm.accountOrPhone == 1">
<el-form-item class="merchant-row" size="small">
<el-input
size="small"
v-model="searchForm.merchantLoginAccount"
placeholder="请输入"
v-if="searchForm.accountOrPhone == 1"
>
<el-select
size="small"
v-model="searchForm.accountOrPhone"
......@@ -30,7 +40,12 @@
<el-option label="手机号" :value="2"></el-option>
</el-select>
</el-input>
<el-input size="small" v-model="searchForm.merchantLegalPersonPhone" placeholder="请输入" v-if="searchForm.accountOrPhone == 2">
<el-input
size="small"
v-model="searchForm.merchantLegalPersonPhone"
placeholder="请输入"
v-if="searchForm.accountOrPhone == 2"
>
<el-select
size="small"
v-model="searchForm.accountOrPhone"
......@@ -75,7 +90,7 @@
placeholder="请输入商户名称/关联的企业微信名"
></el-input>
</el-form-item>
<el-form-item size="small" style="float:right">
<el-form-item size="small" style="float: right">
<el-button type="primary" @click="handleSearch">查询</el-button>
</el-form-item>
</el-row>
......@@ -100,8 +115,16 @@
</div>
<template slot="auth-button" slot-scope="scope" :data="scope.scope">
<el-button type="text" @click="handleLook(scope.scope)">查看</el-button>
<el-button type="text" @click="handleEdit(scope.scope)" v-if="$globalState.session.merchantId != scope.scope.merchantNo">修改</el-button>
<el-button type="text" @click="handleAdd(scope.scope)" v-if="scope.scope.status == 2 && $globalState.session.accountLevel != 4"
<el-button
type="text"
@click="handleEdit(scope.scope)"
v-if="$globalState.session.merchantId != scope.scope.merchantNo"
>修改</el-button
>
<el-button
type="text"
@click="handleAdd(scope.scope)"
v-if="scope.scope.status == 2 && $globalState.session.accountLevel != 4"
>创建子商户/门店</el-button
>
</template>
......@@ -157,6 +180,9 @@ export default {
{
label: "关联的企业微信",
prop: "entmicroName",
formatter: (cellValue) => {
return cellValue.entmicroName ? cellValue.entmicroName : "--";
},
},
{
label: "账户类型",
......@@ -184,6 +210,9 @@ export default {
{
label: "联系人",
prop: "merchantLegalPerson",
formatter: (cellValue) => {
return cellValue.merchantLegalPerson ? cellValue.merchantLegalPerson : "--";
},
},
{
label: "手机号",
......@@ -198,14 +227,17 @@ export default {
};
},
methods: {
handleContact() {
this.$router.push("/baseInfo/relevance/");
},
handleLook(scope) {
this.$router.push("/account/detailAccount/"+scope.id);
this.$router.push("/account/detailAccount/" + scope.id);
},
handleEdit(scope) {
this.$router.push("/account/editAccount/"+scope.id);
this.$router.push("/account/editAccount/" + scope.id);
},
handleAdd(scope) {
this.$router.push("/account/addAccount/"+scope.id);
this.$router.push("/account/addAccount/" + scope.id);
},
findAllDictData(dictType) {
var params = {
......
......@@ -20,7 +20,7 @@
<div class="tittle1 text_w">门店名称</div>
<div class="tittle2 text_w">有效期</div>
</div>
<div class="line_body">
<div class="line_body" :style="{height: tableHeight+ 'px'}">
<template v-if="list.length">
<div v-for="(item, index) in list" :key="index" class="line_wrapper">
<div class="tittle">{{ index + 1 }}</div>
......@@ -66,9 +66,16 @@
<script>
export default {
name: '',
props: {
list: Array,
bloc: null
},
data() {
return {
curOpenIndex: 0,
tableHeight: 0,
dataList: [],
leftData: [],
rightData: [],
......@@ -88,10 +95,7 @@ export default {
isOpen: false
}
},
props: {
list: Array,
bloc: null
},
methods: {
// changeLeftOpenStatus(item, index) {
// this.leftData[index].open = !item.open
......@@ -116,9 +120,14 @@ export default {
// console.log(right)
// }
},
mounted() {}
}
</script>
mounted() {
let clientHeight = document.documentElement.clientHeight;
this.tableHeight = clientHeight - 475;
}
};
</script>
<style lang="scss" scoped>
.bloc-info-module {
box-sizing: border-box;
......@@ -167,10 +176,6 @@ export default {
height: 0;
// transition: height 0.1s ease-in-out;
}
.table_wrapper_open {
height: 378px;
// transition: height 0.1s ease-in-out;
}
.line_wrapper {
width: 100%;
min-height: 54px;
......@@ -211,7 +216,6 @@ export default {
}
.line_body {
width: 100%;
height: 324px;
overflow-y: auto;
overflow-x: hidden;
}
......
......@@ -40,9 +40,12 @@
</div>
</div>
<div style="height: 64px"></div>
<div class="fixed-footer">
<div class="fixed-footer" :style="{
left: footerLeft + 'px',
width: footerWidth + 'px',
}">
<div :style="{ width: customWidth + 'px' }" class="btn-custom" @click="closeCurRouter">取消</div>
<div style="width: 40px"></div>
<div style="width: 20px"></div>
<div :style="{ width: customWidth + 'px' }" ref="btnWidth" class="btn-custom pruple" @click="handleMutiGL">确定关联({{ dataList.length }})</div>
</div>
</div>
......@@ -51,6 +54,7 @@
<script>
export default {
name: '',
data() {
return {
departmentList: [],
......@@ -89,11 +93,7 @@ export default {
selectedDepartment: ''
}
},
created() {
this.getDepartmentList()
this.getMerchantList()
},
mounted() {},
methods: {
// 设置底部按钮宽度
setBtnWidth() {
......@@ -270,9 +270,20 @@ export default {
return arr1
}
},
created() {
this.getDepartmentList()
this.getMerchantList()
},
mounted() {
this.footerLeft = document.querySelector(".base-container-right").offsetLeft;
this.footerWidth = document.documentElement.clientWidth - this.footerLeft;
}
}
</script>
};
</script>
<style lang="scss" scoped>
.gl-page {
box-sizing: border-box;
......@@ -319,7 +330,7 @@ export default {
}
.tbale-wrapper {
width: 100%;
height: 590px;
min-height: 200px;
background: #ffffff;
box-shadow: 0px 10px 20px 0px rgba(88, 80, 255, 0.1);
box-sizing: border-box;
......@@ -358,7 +369,7 @@ export default {
border-radius: 4px;
cursor: pointer;
text-align: center;
padding: 8px 0;
padding: 12px 0;
}
.pruple {
background: #5850ff;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!