You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
zhishifufei_uniapp/pages/merchant/info.vue

155 lines
3.3 KiB

<template>
<BaseContainer>
<NavBar :title="type == 1 ? '讲师信息' : '机构信息'" />
<view class="list" v-if="merchant.id">
<view class="item">
<view>后台地址</view>
<view>{{ url }}</view>
</view>
<view class="item">
<view>登录账号</view>
<view>{{ admin.account }}可使用短信登录</view>
</view>
<view class="item">
<view>登录密码</view>
<view>123456默认密码若已修改则以修改的为准</view>
</view>
<view class="item">
<view>分成比列</view>
<view>
<view class="table">
<view class="tr">
<view class="td">专题</view>
<view class="td">{{ merchant.mer_special_divide }}%</view>
</view>
<view class="tr">
<view class="td">商品</view>
<view class="td">{{ merchant.mer_store_divide }}% + 运费</view>
</view>
<view class="tr">
<view class="td">活动</view>
<view class="td">{{ merchant.mer_event_divide }}%</view>
</view>
<view class="tr">
<view class="td">资料</view>
<view class="td">{{ merchant.mer_data_divide }}%</view>
</view>
<view class="tr">
<view class="td">直播</view>
<view class="td">{{ merchant.gold_divide }}%</view>
</view>
</view>
</view>
</view>
</view>
<view class="btn-group">
<button class="btn flex flex-center" type="button" @click="goBack">返回</button>
</view>
</BaseContainer>
</template>
<script>
import { getMerchantInfo } from "@/api/merchant";
import { getInstitutionInfo } from "@/api/institution";
export default {
data() {
return {
mer_id: 0,
url: "",
admin: {},
merchant: {},
type:1
};
},
onLoad({ mer_id,type }) {
this.mer_id = mer_id;
this.type = type;
if(type == 1){
this.getData();
}else{
this.getInsData();
}
},
methods: {
getData() {
getMerchantInfo(this.mer_id).then(({ data }) => {
const { url, admin, merchant } = data;
Object.assign(this, {
url,
admin,
merchant,
});
});
},
getInsData() {
getInstitutionInfo(this.mer_id).then(({ data }) => {
const { url, admin, merchant } = data;
Object.assign(this, {
url,
admin,
merchant,
});
});
},
goBack() {
uni.navigateBack();
},
},
};
</script>
<style scoped lang="scss">
.list {
padding-left: 30rpx;
background-color: #ffffff;
}
.list .item {
display: flex;
padding: 35rpx 30rpx 35rpx 0;
border-top: 1px solid #dddddd;
}
.list .item > view:first-child {
width: 178rpx;
}
.list .item > view:last-child {
flex: 1;
min-width: 0;
word-break: break-all;
}
.btn-group {
padding: 80rpx 30rpx 0;
}
.btn-group .btn {
width: 100%;
height: 90rpx;
border: 1px solid #2c8eff;
border-radius: 45rpx;
background-color: #ffffff;
font-size: 32rpx;
color: #2c8eff;
}
.table {
width: 100%;
display: table;
}
.table,
.th,
.td {
border: 1px solid #eeeeee;
}
.td {
padding: 10rpx;
text-align: center;
}
.tr {
display: table-row;
}
.td {
display: table-cell;
}
</style>