Commit ff67fdee by Jings

Merge remote-tracking branch 'origin/feature/九月迭代' into dev

parents 68e58ac3 4883005c
<template>
<div v-if="storeList.length > 1">
<div>
<el-dropdown @command="onChangeStore">
<span class="change-store-btn">
{{ getActiveStoreName }}
......@@ -9,8 +9,11 @@
<div class="store-list">
<el-dropdown-item v-for="el in storeList" :key="el.enterpriseId" :class="['store-item', { actived: el.enterpriseId == activedStoreId }]" :command="el.enterpriseId">
<div>
<div class="store-name">{{ el.brandName }}</div>
<div class="default-store-tag" v-if="el.defaultFlag == 1">默认商户</div>
<div class="dis_f ai_c">
<div class="store-name txt_ellipsis" :class="[el.defaultFlag == 1 ? 'maxW_170' : 'maxW_250']">{{ el.brandName }}</div>
<div class="default-store-tag" v-if="el.defaultFlag == 1">默认商户</div>
</div>
<div class="txt_ellipsis maxW_250 FS_12">{{ el.enterpriseName }}</div>
</div>
<i class="el-icon-check checked" v-if="el.enterpriseId == activedStoreId"></i>
</el-dropdown-item>
......@@ -123,6 +126,26 @@ export default {
</script>
<style lang="scss" scoped>
.FS_12 {
font-size: 12px;
}
.maxW_170 {
max-width: 170px;
}
.maxW_250 {
max-width: 250px;
}
.txt_ellipsis {
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.dis_f {
display: flex;
}
.ai_c {
align-items: center;
}
.change-store-btn {
display: flex;
justify-content: center;
......@@ -171,7 +194,7 @@ export default {
<style lang="scss">
.change-store-popper {
padding: 7px 0 0 !important;
width: 200px;
width: 300px;
box-sizing: border-box;
.el-dropdown-menu__item {
padding: 0;
......@@ -202,12 +225,14 @@ export default {
background: #f7f8fa;
}
.store-name {
margin-right: 5px;
font-size: 14px;
font-weight: 400;
color: #303133;
line-height: 20px;
}
.default-store-tag {
padding: 0 4px;
height: 18px;
text-align: center;
line-height: 18px;
......
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