| | |
| | | <template> |
| | | <view class=""> |
| | | <view class="content chuany-flex chuany-align-end chuany-justify-center"> |
| | | <up-avatar src="/static/avatar.jpg" shape="circle" size='80'></up-avatar> |
| | | </view> |
| | | <fui-list> |
| | | <fui-list-cell arrow> |
| | | <!-- <view class="content chuany-flex chuany-align-end chuany-justify-center"> |
| | | <up-avatar :src="avatarUrlImg" shape="circle" size='80'></up-avatar> |
| | | </view> --> |
| | | <fui-list :topBorder='false'> |
| | | <fui-list-cell :bottomBorder='false' :padding="['20rpx', '32rpx', '20rpx', '32rpx']"> |
| | | <view class="fui-list__item"> |
| | | <text>企业名称</text> |
| | | <text class="chuany-font30">企业名称</text> |
| | | <text class="fui-text__explain">{{enterpriseInfo.suppliername}}</text> |
| | | </view> |
| | | </fui-list-cell> |
| | | <fui-list-cell arrow> |
| | | <fui-list-cell :bottomBorder='false' :padding="['20rpx', '32rpx', '20rpx', '32rpx']"> |
| | | <view class="fui-list__item"> |
| | | <text>企业注册地址</text> |
| | | <text class="chuany-font30">企业地址</text> |
| | | <text class="fui-text__explain address">{{enterpriseInfo.address}}</text> |
| | | </view> |
| | | </fui-list-cell> |
| | | <fui-list-cell arrow> |
| | | <fui-list-cell :bottomBorder='false' :padding="['20rpx', '32rpx', '20rpx', '32rpx']"> |
| | | <view class="fui-list__item"> |
| | | <text>联系电话</text> |
| | | <text class="chuany-font30">联系电话</text> |
| | | <text class="fui-text__explain">{{enterpriseInfo.phone}}</text> |
| | | </view> |
| | | </fui-list-cell> |
| | | <up-collapse> |
| | | <up-collapse-item title="公司简介" name="Numerous tools"> |
| | | <text class="u-collapse-content">{{enterpriseInfo.resume}}</text> |
| | | </up-collapse-item> |
| | | </up-collapse> |
| | | <fui-list-cell arrow @click="goApply"> |
| | | <text>完善企业资料</text> |
| | | <fui-collapse-item :isBorder='false' open> |
| | | <view class="fui-item__box"> |
| | | <!-- <image src="/static/images/common/logo.png" class="fui-logo"></image> --> |
| | | <text>公司简介</text> |
| | | </view> |
| | | <template v-slot:content> |
| | | <view class="fui-descr">{{enterpriseInfo.resume}}</view> |
| | | </template> |
| | | </fui-collapse-item> |
| | | <fui-list-cell arrow @click="goApply" :bottomBorder='false' :padding="['20rpx', '32rpx', '20rpx', '32rpx']"> |
| | | <text class="chuany-font30">{{workerInfo?'修改企业资料':'完善企业资料'}}</text> |
| | | </fui-list-cell> |
| | | </fui-list> |
| | | </view> |
| | |
| | | onLoad, |
| | | onShow |
| | | } from "@dcloudio/uni-app"; |
| | | |
| | | import { |
| | | ref, |
| | | reactive, |
| | | getCurrentInstance |
| | | getCurrentInstance, |
| | | watch, |
| | | computed |
| | | } from 'vue'; |
| | | const { |
| | | $db |
| | | } = getCurrentInstance().appContext.config.globalProperties |
| | | import { |
| | | useStore |
| | | } from 'vuex' |
| | | const store = useStore() |
| | | onShow(() => { |
| | | let data = JSON.parse($db.get('userInfo')).userCompany |
| | | if (data) { |
| | | enterpriseInfo.businessLicense = data.businessLicense |
| | | enterpriseInfo.suppliername = data.suppliername //企业名称 |
| | | enterpriseInfo.regtime = data.regtime //注册时间 |
| | | enterpriseInfo.address = data.address //联系地址 |
| | | enterpriseInfo.suppliercode = data.suppliercode //企业注册号 |
| | | enterpriseInfo.contact = data.contact //联系人 |
| | | enterpriseInfo.phone = data.phone //联系电话 |
| | | enterpriseInfo.id = data.id |
| | | enterpriseInfo.resume = data.resume |
| | | } |
| | | // getUserInfo() |
| | | // let data = $db.get('userInfo') ? $db.get('userInfo').userCompany : null |
| | | // console.log(data,'data’'); |
| | | // if (data) { |
| | | // enterpriseInfo.businessLicense = data.businessLicense |
| | | // enterpriseInfo.suppliername = data.suppliername //企业名称 |
| | | // enterpriseInfo.regtime = data.regtime //注册时间 |
| | | // enterpriseInfo.address = data.address //联系地址 |
| | | // enterpriseInfo.suppliercode = data.suppliercode //企业注册号 |
| | | // enterpriseInfo.contact = data.contact //联系人 |
| | | enterpriseInfo.phone = 123 //联系电话 |
| | | console.log(enterpriseInfo, enterpriseInfo.phone, 'enterpriseInfo’'); |
| | | // enterpriseInfo.id = data.id |
| | | // enterpriseInfo.resume = data.resume |
| | | // } |
| | | }) |
| | | const enterpriseInfo = reactive({ |
| | | id: 0, //用户公司Id |
| | | businessLicense: '', //营业执照路径 |
| | | suppliername: '', //企业名称 |
| | | regtime: '', //注册时间 |
| | | address: '', //联系地址 |
| | | suppliercode: '', //企业注册号 |
| | | contact: '', //联系人 |
| | | phone: '', //联系电话 |
| | | resume: '', //公司简介 |
| | | }) |
| | | |
| | | let avatarUrlImg = ref('') |
| | | onLoad(() => {}) |
| | | // let enterpriseInfo = reactive({ |
| | | // // id: 0, //用户公司Id |
| | | // // businessLicense: '', //营业执照路径 |
| | | // // suppliername: '', //企业名称 |
| | | // // regtime: '', //注册时间 |
| | | // // address: '', //联系地址 |
| | | // // suppliercode: '', //企业注册号 |
| | | // // contact: '', //联系人 |
| | | // // phone: '', //联系电话 |
| | | // // resume: '', //公司简介 |
| | | // }) |
| | | const getUserInfo = () => { |
| | | store.dispatch('getUserInfo') |
| | | } |
| | | let enterpriseInfo = computed(() => store.getters.userInfo.userCompany || {}) |
| | | let workerInfo = computed(() => store.getters.userInfo.userWorker ? true : false) |
| | | // watch(store.getters.userInfo, (newVal, oldVal) => { |
| | | // enterpriseInfo = newVal |
| | | // if (!enterpriseInfo.userCompany) { |
| | | // enterpriseInfo.userCompany = {} |
| | | // } |
| | | // console.log(enterpriseInfo,'wacth----------'); |
| | | // }, { |
| | | // deep: true, // 深度监听 |
| | | // immediate: true |
| | | // }); |
| | | // let src = "http://pic2.sc.chinaz.com/Files/pic/pic9/202002/hpic2119_s.jpg" |
| | | const goApply = () => { |
| | | uni.navigateTo({ |
| | |
| | | .address { |
| | | width: 65%; |
| | | } |
| | | |
| | | .fui-item__box { |
| | | font-size: 30rpx; |
| | | width: 100%; |
| | | padding: 26rpx 32rpx; |
| | | box-sizing: border-box; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .fui-logo { |
| | | width: 48rpx; |
| | | height: 48rpx; |
| | | margin-right: 24rpx; |
| | | display: block; |
| | | } |
| | | |
| | | .fui-descr { |
| | | width: 100%; |
| | | padding: 32rpx; |
| | | font-size: 28rpx; |
| | | line-height: 52rpx; |
| | | color: #7F7F7F; |
| | | word-break: break-all; |
| | | box-sizing: border-box; |
| | | } |
| | | </style> |