|
@@ -39,7 +39,8 @@
|
|
|
<view class="user-btn">
|
|
|
<u-button type="success" :custom-style="{background:$config('primaryColor')}" hover-class="none" @click="quitOutSys" shape="circle">退出登录</u-button>
|
|
|
</view>
|
|
|
- <u-action-sheet :list="orglist" v-model="show" @click="changeAcount" :tips="tips" :cancel-btn="true"></u-action-sheet>
|
|
|
+ <u-select v-model="show" value-name="orgSn" label-name="orgName" :list="orglist" title="切换帐户" @confirm = "changeAcount"></u-select>
|
|
|
+ <!-- <u-action-sheet :list="orglist" v-model="show" @click="changeAcount" :tips="tips" :cancel-btn="true"></u-action-sheet> -->
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
@@ -127,12 +128,10 @@
|
|
|
});
|
|
|
},
|
|
|
// 切换账户
|
|
|
- changeAcount(index){
|
|
|
+ changeAcount(item){
|
|
|
const _this = this
|
|
|
- const item = this.orglist[index]
|
|
|
- console.log(index,item)
|
|
|
- this.$store.state.vuex_changeOrg = item.orgSn
|
|
|
- this.$set(getApp().globalData,'changeOrg',item.orgSn)
|
|
|
+ this.$store.state.vuex_changeOrg = item.value
|
|
|
+ this.$set(getApp().globalData,'changeOrg',item.value)
|
|
|
setTimeout(()=>{
|
|
|
// 登录
|
|
|
login({ username: '', password: '' }).then(res => {
|