Commit ef0c67c2 by 无尘

fix: 修改选择商户

parent 90df0e0b
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
* @Author: 无尘 * @Author: 无尘
* @Date: 2018-10-10 14:44:45 * @Date: 2018-10-10 14:44:45
* @LastEditors: 无尘 * @LastEditors: 无尘
* @LastEditTime: 2020-08-27 09:27:35 * @LastEditTime: 2020-09-03 09:58:17
--> -->
<template> <template>
<div class="nav-wrap border-box flex flex-space-between"> <div class="nav-wrap border-box flex flex-space-between">
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
</template> </template>
</el-breadcrumb> </el-breadcrumb>
<div class="my-customer-brand"> <div class="my-customer-brand">
<el-tooltip class="item" effect="dark" content="不同品牌的工作台可分别进行管理。点击后切换,可以管理不同品牌下的应用" placement="top-start"> <el-tooltip class="item" effect="dark" content="不同商户的工作台可分别进行管理。点击后切换,可以管理不同商户下的应用" placement="top-start">
<span class="font-14 color-606266" style="cursor: pointer;padding-bottom: 2px; border-bottom: 1px dashed #2F54EB;">授权商户名称 </span> <span class="font-14 color-606266" style="cursor: pointer;padding-bottom: 2px; border-bottom: 1px dashed #2F54EB;">授权商户名称 </span>
</el-tooltip> </el-tooltip>
<el-select class="p-l-10" v-model="activeBrand" placeholder="请选择" @change="changeSelect"> <el-select class="p-l-10" v-model="activeBrand" placeholder="请选择" @change="changeSelect">
...@@ -49,6 +49,7 @@ export default { ...@@ -49,6 +49,7 @@ export default {
data() { data() {
return { return {
projectName: 'haoban', // 当前项目名 projectName: 'haoban', // 当前项目名
wxEnterpriseId: localStorage.getItem('haoBanUser') ? JSON.parse(localStorage.getItem('haoBanUser')).wxEnterpriseId : '',
activeBrand: '', activeBrand: '',
brandListData: [] brandListData: []
}; };
...@@ -64,7 +65,7 @@ export default { ...@@ -64,7 +65,7 @@ export default {
* @param {String} relocation * @param {String} relocation
*/ */
changeRoute(path, relocation) { changeRoute(path, relocation) {
let that = this; const that = this;
if (relocation) { if (relocation) {
window.location.href = path; window.location.href = path;
} else { } else {
...@@ -76,7 +77,7 @@ export default { ...@@ -76,7 +77,7 @@ export default {
* @param {String} val * @param {String} val
*/ */
changeSelect(val) { changeSelect(val) {
let that = this; const that = this;
let enterpriseId = ''; let enterpriseId = '';
that.brandListData.forEach(ele => { that.brandListData.forEach(ele => {
if (ele.enterpriseId == val) { if (ele.enterpriseId == val) {
...@@ -91,7 +92,7 @@ export default { ...@@ -91,7 +92,7 @@ export default {
*/ */
getBrandData() { getBrandData() {
const that = this; const that = this;
getWxEnterprise({}) getWxEnterprise({ wxEnterpriseId: that.wxEnterpriseId })
.then(res => { .then(res => {
if (!!res.result && !!res.result.length) { if (!!res.result && !!res.result.length) {
that.brandListData = res.result; that.brandListData = res.result;
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
* @Author: 无尘 * @Author: 无尘
* @Date: 2019-03-20 14:36:37 * @Date: 2019-03-20 14:36:37
* @LastEditors: 无尘 * @LastEditors: 无尘
* @LastEditTime: 2020-09-03 09:31:58 * @LastEditTime: 2020-09-03 09:50:19
--> -->
<template> <template>
<div class="my-customer-wrap common-set-wrap"> <div class="my-customer-wrap common-set-wrap">
...@@ -79,6 +79,16 @@ export default { ...@@ -79,6 +79,16 @@ export default {
}, },
methods: { methods: {
/** /**
* 返回 的 brandId
* @param {String} id
* @param {String} groupId
*/
selectBrandId(id, groupId) {
let that = this;
that.activeBrand = id;
that.activeGroup = groupId;
},
/**
* 路由跳转 * 路由跳转
* @param {String} path * @param {String} path
*/ */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment