首次登录没有头像
This commit is contained in:
parent
96d2552de2
commit
6dc0e69392
@ -7,7 +7,7 @@
|
|||||||
<view class="price" v-else>0.00</view>
|
<view class="price" v-else>0.00</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="item" @click="navTo('/subpkg/withdrawDeposit/company')">
|
<view class="item" @click="navTo('/subpkg/withdrawDeposit/company')">
|
||||||
<view>公司收益总金额(元)</view>
|
<view>公司预计收益总金额(元)</view>
|
||||||
<view class="price" v-if="company.company_money">{{cCount(+company.company_money)}}</view>
|
<view class="price" v-if="company.company_money">{{cCount(+company.company_money)}}</view>
|
||||||
<view class="price" v-else>0.00</view>
|
<view class="price" v-else>0.00</view>
|
||||||
</view>
|
</view>
|
||||||
@ -45,9 +45,10 @@
|
|||||||
<view class="t_item">
|
<view class="t_item">
|
||||||
<view class="t_title">收益来源:</view>
|
<view class="t_title">收益来源:</view>
|
||||||
<view class="tips">
|
<view class="tips">
|
||||||
<text v-if="item.change_type==202" style="color: #46be61;">{{item.type_desc}}</text>
|
<text v-if="item.change_type==202" style="color: #46be61;">{{item.type_desc}}</text>
|
||||||
<text v-else-if="item.change_type==203" style="color: #ff7c32;">{{item.type_desc}}</text>
|
<text v-else-if="item.change_type==203"
|
||||||
<text v-else="item.change_type==203">{{item.type_desc}}</text>
|
style="color: #ff7c32;">{{item.type_desc}}</text>
|
||||||
|
<text v-else="item.change_type==203">{{item.type_desc}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -69,7 +70,7 @@
|
|||||||
import {
|
import {
|
||||||
accountMonthList,
|
accountMonthList,
|
||||||
accountDateList,
|
accountDateList,
|
||||||
companyView
|
companyView
|
||||||
} from "@/api/company.js"
|
} from "@/api/company.js"
|
||||||
import {
|
import {
|
||||||
Toast
|
Toast
|
||||||
@ -96,28 +97,30 @@
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
this.loadCompany();
|
this.loadCompany();
|
||||||
this.initLoad();
|
this.initLoad();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async loadCompany(){
|
async loadCompany() {
|
||||||
let res = await companyView();
|
let res = await companyView();
|
||||||
this.company = res.data.company;
|
this.company = res.data.company;
|
||||||
},
|
},
|
||||||
navTo(url) {
|
navTo(url) {
|
||||||
if(url){
|
if (url) {
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title: '加载中',
|
title: '加载中',
|
||||||
mask: true
|
mask: true
|
||||||
});
|
});
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: url,
|
url: url,
|
||||||
success:(res)=> {
|
success: (res) => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
res.eventChannel.emit('company_money', { company_money: this.company.company_money })
|
res.eventChannel.emit('company_money', {
|
||||||
}
|
company_money: this.company.company_money
|
||||||
})
|
})
|
||||||
}else Toast('暂未开放')
|
}
|
||||||
|
})
|
||||||
|
} else Toast('暂未开放')
|
||||||
},
|
},
|
||||||
initLoad() {
|
initLoad() {
|
||||||
this.loadConfig.page = 1;
|
this.loadConfig.page = 1;
|
||||||
@ -251,7 +254,7 @@
|
|||||||
|
|
||||||
&:before {
|
&:before {
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
content: '账户收益';
|
content: '预计收益';
|
||||||
width: 137rpx;
|
width: 137rpx;
|
||||||
height: 49rpx;
|
height: 49rpx;
|
||||||
line-height: 49rpx;
|
line-height: 49rpx;
|
||||||
|
@ -270,7 +270,14 @@
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
async onLoad() {
|
async onLoad() {
|
||||||
|
// console.log('asdashg')
|
||||||
|
if (uni.getStorageSync('USER_INFO')) {
|
||||||
|
let userData = JSON.parse(uni.getStorageSync('USER_INFO'))
|
||||||
|
|
||||||
|
this.initUserInfo(userData);
|
||||||
|
// console.log(545)
|
||||||
|
}
|
||||||
|
console.log(7787878)
|
||||||
await this.$onLaunched;
|
await this.$onLaunched;
|
||||||
this.is_captain = JSON.parse(uni.getStorageSync("USER_INFO") || '{}')?.is_captain
|
this.is_captain = JSON.parse(uni.getStorageSync("USER_INFO") || '{}')?.is_captain
|
||||||
this.options.data = bj;
|
this.options.data = bj;
|
||||||
@ -286,6 +293,10 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
// #endif
|
// #endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
onReachBottom() {
|
onReachBottom() {
|
||||||
if (this.flag) return
|
if (this.flag) return
|
||||||
@ -314,6 +325,9 @@
|
|||||||
// }
|
// }
|
||||||
// this.getUserIndex()
|
// this.getUserIndex()
|
||||||
// this.getIndexList()
|
// this.getIndexList()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
let user_id = JSON.parse(uni.getStorageSync("USER_INFO")).id
|
let user_id = JSON.parse(uni.getStorageSync("USER_INFO")).id
|
||||||
this.getOrderList();
|
this.getOrderList();
|
||||||
console.log("show")
|
console.log("show")
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -46,7 +46,8 @@
|
|||||||
<u--input v-model="formData.id_card" placeholder="请输入身份证号" @input="c_idcard"
|
<u--input v-model="formData.id_card" placeholder="请输入身份证号" @input="c_idcard"
|
||||||
type="idcard"></u--input>
|
type="idcard"></u--input>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item v-if="$store.state.app.userInfo.company.company_type==18" labelWidth="auto" label="是否为小队长" required prop="is_captain" borderBottom>
|
<u-form-item v-if="$store.state.app.userInfo.company.company_type==18" labelWidth="auto"
|
||||||
|
label="是否为小队长" required prop="is_captain" borderBottom>
|
||||||
<u-radio-group v-model="formData.is_captain" style="margin: 16rpx;">
|
<u-radio-group v-model="formData.is_captain" style="margin: 16rpx;">
|
||||||
<u-radio activeColor="#0122C7" :customStyle="{marginRight: '16px'}"
|
<u-radio activeColor="#0122C7" :customStyle="{marginRight: '16px'}"
|
||||||
v-for="(item, index) in [{value:1,label:'是'},{value:0,label:'否'}]" :key="index"
|
v-for="(item, index) in [{value:1,label:'是'},{value:0,label:'否'}]" :key="index"
|
||||||
@ -54,14 +55,15 @@
|
|||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</u-form-item>
|
</u-form-item>
|
||||||
<u-form-item v-if="$store.state.app.userInfo.company.company_type==41" labelWidth="auto" label="是否为服务部长" required prop="is_service_manager" borderBottom>
|
<u-form-item v-if="$store.state.app.userInfo.company.company_type==16" labelWidth="auto"
|
||||||
<u-radio-group v-model="formData.is_service_manager" style="margin: 16rpx;">
|
label="是否为服务部长" required prop="is_service_manager" borderBottom>
|
||||||
<u-radio activeColor="#0122C7" :customStyle="{marginRight: '16px'}"
|
<u-radio-group v-model="formData.is_service_manager" style="margin: 16rpx;">
|
||||||
v-for="(item, index) in [{value:1,label:'是'},{value:0,label:'否'}]" :key="index"
|
<u-radio activeColor="#0122C7" :customStyle="{marginRight: '16px'}"
|
||||||
:label="item.label" :name="item.value">
|
v-for="(item, index) in [{value:1,label:'是'},{value:0,label:'否'}]" :key="index"
|
||||||
</u-radio>
|
:label="item.label" :name="item.value">
|
||||||
</u-radio-group>
|
</u-radio>
|
||||||
</u-form-item>
|
</u-radio-group>
|
||||||
|
</u-form-item>
|
||||||
<districtSelectorTow style="margin-top: 30rpx;" ref="districtSelectorRef"></districtSelectorTow>
|
<districtSelectorTow style="margin-top: 30rpx;" ref="districtSelectorRef"></districtSelectorTow>
|
||||||
</view>
|
</view>
|
||||||
<view class="cards">
|
<view class="cards">
|
||||||
@ -295,11 +297,10 @@
|
|||||||
</u-upload>
|
</u-upload>
|
||||||
</u-form-item> -->
|
</u-form-item> -->
|
||||||
</u--form>
|
</u--form>
|
||||||
<button @click="modelShow=true" type="primary" class="btn"
|
<button @click="modelShow=true" type="primary" class="btn" style="margin: 28rpx;">创建</button>
|
||||||
style="margin: 28rpx;">创建</button>
|
|
||||||
</view>
|
</view>
|
||||||
<u-modal :show="modelShow" title="提示" content='请确认人员信息无误后再创建' closeOnClickOverlay showCancelButton
|
<u-modal :show="modelShow" title="提示" content='请确认人员信息无误后再创建' closeOnClickOverlay showCancelButton
|
||||||
@close="modelShow=false" @cancel="modelShow=false" @confirm="$u.throttle(addAcountNum, 2000)"></u-modal>
|
@close="modelShow=false" @cancel="modelShow=false" @confirm="$u.throttle(addAcountNum, 2000)"></u-modal>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -309,7 +310,7 @@
|
|||||||
} from "@/api/file.js"
|
} from "@/api/file.js"
|
||||||
import {
|
import {
|
||||||
loginAdd,
|
loginAdd,
|
||||||
} from "@/api/oaUser.js"
|
} from "@/api/oaUser.js"
|
||||||
import districtSelector from "@/components/districtSelector/districtSelector.vue" //地区选择器
|
import districtSelector from "@/components/districtSelector/districtSelector.vue" //地区选择器
|
||||||
import districtSelectorTow from "@/components/districtSelector/districtSelectorTow.vue" //地区选择器
|
import districtSelectorTow from "@/components/districtSelector/districtSelectorTow.vue" //地区选择器
|
||||||
import {
|
import {
|
||||||
@ -322,7 +323,7 @@
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
modelShow: false,
|
modelShow: false,
|
||||||
formData: {
|
formData: {
|
||||||
account: '', //账号
|
account: '', //账号
|
||||||
password: '123456', //密码
|
password: '123456', //密码
|
||||||
@ -330,7 +331,7 @@
|
|||||||
// channel: 6, //注册渠道[1-微信小程序 2-微信公众号 3-手机H5 4-电脑PC 5-苹果APP 6-安卓APP]
|
// channel: 6, //注册渠道[1-微信小程序 2-微信公众号 3-手机H5 4-电脑PC 5-苹果APP 6-安卓APP]
|
||||||
id_card: '',
|
id_card: '',
|
||||||
is_captain: '', // 队长标识
|
is_captain: '', // 队长标识
|
||||||
is_service_manager: '', //服务部长标识
|
is_service_manager: '', //服务部长标识
|
||||||
sex: '',
|
sex: '',
|
||||||
avatar: '',
|
avatar: '',
|
||||||
nickname: '',
|
nickname: '',
|
||||||
@ -381,12 +382,12 @@
|
|||||||
},
|
},
|
||||||
trigger: ['change', 'blur']
|
trigger: ['change', 'blur']
|
||||||
},
|
},
|
||||||
is_service_manager: {
|
is_service_manager: {
|
||||||
validator: (rule, value, callback) => {
|
validator: (rule, value, callback) => {
|
||||||
typeof value === 'number' ? callback() : callback('不能为空')
|
typeof value === 'number' ? callback() : callback('不能为空')
|
||||||
},
|
},
|
||||||
trigger: ['change', 'blur']
|
trigger: ['change', 'blur']
|
||||||
},
|
},
|
||||||
'qualification.id_card': {
|
'qualification.id_card': {
|
||||||
type: 'string',
|
type: 'string',
|
||||||
required: true,
|
required: true,
|
||||||
@ -428,17 +429,17 @@
|
|||||||
},
|
},
|
||||||
// 上传头像
|
// 上传头像
|
||||||
async afterReadAvatar(event) {
|
async afterReadAvatar(event) {
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title:'上传中'
|
title: '上传中'
|
||||||
})
|
})
|
||||||
upLoadImage({
|
upLoadImage({
|
||||||
filePath: event.file.url,
|
filePath: event.file.url,
|
||||||
name: 'file'
|
name: 'file'
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
this.formData.avatar = res.data.uri;
|
this.formData.avatar = res.data.uri;
|
||||||
}).finally(()=>{
|
}).finally(() => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 新增图片
|
// 新增图片
|
||||||
async afterRead(event) {
|
async afterRead(event) {
|
||||||
@ -446,27 +447,29 @@
|
|||||||
},
|
},
|
||||||
// 上传图片
|
// 上传图片
|
||||||
upLoad(url, type) {
|
upLoad(url, type) {
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title:'上传中请稍后'
|
title: '上传中请稍后'
|
||||||
})
|
})
|
||||||
upLoadImage({
|
upLoadImage({
|
||||||
filePath: url,
|
filePath: url,
|
||||||
name: 'file'
|
name: 'file'
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
this.formData.qualification[type] = res.data.uri
|
this.formData.qualification[type] = res.data.uri
|
||||||
}).finally(()=>{
|
}).finally(() => {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 创建账号
|
// 创建账号
|
||||||
async addAcountNum() {
|
async addAcountNum() {
|
||||||
this.modelShow = false;
|
this.modelShow = false;
|
||||||
await this.$nextTick();
|
await this.$nextTick();
|
||||||
if (!this.formData.avatar) return Toast('头像未上传');
|
if (!this.formData.avatar) return Toast('头像未上传');
|
||||||
let flag = this.$refs.districtSelectorRef.validate();
|
let flag = this.$refs.districtSelectorRef.validate();
|
||||||
if (!this.formData.qualification.id_card || !this.formData.qualification.id_card_b) return Toast('身份证未上传');
|
if (!this.formData.qualification.id_card || !this.formData.qualification.id_card_b) return Toast(
|
||||||
if (!this.formData.qualification.bank_account || !this.formData.qualification.bank_account_b) return Toast(
|
'身份证未上传');
|
||||||
'银行卡未上传');
|
if (!this.formData.qualification.bank_account || !this.formData.qualification.bank_account_b)
|
||||||
|
return Toast(
|
||||||
|
'银行卡未上传');
|
||||||
this.$refs.uForm.validate().then(async (e) => {
|
this.$refs.uForm.validate().then(async (e) => {
|
||||||
if (e && flag) {
|
if (e && flag) {
|
||||||
uni.showLoading()
|
uni.showLoading()
|
||||||
|
@ -109,7 +109,9 @@
|
|||||||
:loadmore-text="loadConfig.loadmoreText" :nomore-text="loadConfig.nomoreText" />
|
:loadmore-text="loadConfig.loadmoreText" :nomore-text="loadConfig.nomoreText" />
|
||||||
</view>
|
</view>
|
||||||
<!-- <button class="new_btn" @click.stop="navTo('/subpkg/newPersonnel/newPersonnel')">创建账号</button> -->
|
<!-- <button class="new_btn" @click.stop="navTo('/subpkg/newPersonnel/newPersonnel')">创建账号</button> -->
|
||||||
<mybtn v-if="$store.state.app.userInfo.company && ($store.state.app.userInfo.company.company_type==18||$store.state.app.userInfo.company.company_type==41)" text="创建账号" @click="navTo('/subpkg/newPersonnel/newPersonnel')"></mybtn>
|
<mybtn
|
||||||
|
v-if="$store.state.app.userInfo.company && ($store.state.app.userInfo.company.company_type==18||$store.state.app.userInfo.company.company_type==16)"
|
||||||
|
text="创建账号" @click="navTo('/subpkg/newPersonnel/newPersonnel')"></mybtn>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -146,18 +148,18 @@
|
|||||||
// console.log(a.substring(0, 10))
|
// console.log(a.substring(0, 10))
|
||||||
},
|
},
|
||||||
navTo(url) {
|
navTo(url) {
|
||||||
if(url){
|
if (url) {
|
||||||
uni.showLoading({
|
uni.showLoading({
|
||||||
title: '加载中',
|
title: '加载中',
|
||||||
mask: true
|
mask: true
|
||||||
});
|
});
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: url,
|
url: url,
|
||||||
success() {
|
success() {
|
||||||
uni.hideLoading()
|
uni.hideLoading()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}else Toast('暂未开放')
|
} else Toast('暂未开放')
|
||||||
},
|
},
|
||||||
async initLoad() {
|
async initLoad() {
|
||||||
this.loadConfig.page = 1;
|
this.loadConfig.page = 1;
|
||||||
@ -202,8 +204,9 @@
|
|||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.personnel {
|
.personnel {
|
||||||
padding: 28rpx 0;
|
padding: 28rpx 0;
|
||||||
padding-bottom: 160rpx;
|
padding-bottom: 160rpx;
|
||||||
|
|
||||||
.new_btn {
|
.new_btn {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
bottom: 30rpx;
|
bottom: 30rpx;
|
||||||
|
@ -401,8 +401,8 @@
|
|||||||
},
|
},
|
||||||
],
|
],
|
||||||
formData: {
|
formData: {
|
||||||
"entityName": "5",
|
"entityName": "",
|
||||||
phone: "15884967539",
|
phone: "",
|
||||||
employee: "",
|
employee: "",
|
||||||
arableLand: "",
|
arableLand: "",
|
||||||
"breeding_training": 1, //有无养殖培训
|
"breeding_training": 1, //有无养殖培训
|
||||||
@ -466,15 +466,12 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(option) {
|
onLoad(option) {
|
||||||
|
|
||||||
|
|
||||||
this.taskId = option.task_id
|
this.taskId = option.task_id
|
||||||
if (option.type == 'supply') this.page = 0
|
if (option.type == 'supply') this.page = 0
|
||||||
|
|
||||||
townMasterTask3List({
|
townMasterTask3List({
|
||||||
id: option.task_id
|
id: option.task_id
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
this.pas_Info = res.data.template_info.extend.purchase_sales_info
|
this.pas_Info = res.data.template_info.extend.purchase_sales_info || this.pas_Info
|
||||||
if (option.index) {
|
if (option.index) {
|
||||||
this.readonly = true
|
this.readonly = true
|
||||||
this.flag = true
|
this.flag = true
|
||||||
@ -601,6 +598,7 @@
|
|||||||
},
|
},
|
||||||
async commit() {
|
async commit() {
|
||||||
console.log(this.pas_Info)
|
console.log(this.pas_Info)
|
||||||
|
|
||||||
if (this.page) {
|
if (this.page) {
|
||||||
this.pas_Info.planting.push(this.formData)
|
this.pas_Info.planting.push(this.formData)
|
||||||
await townMasterTask3Commit({
|
await townMasterTask3Commit({
|
||||||
|
Loading…
x
Reference in New Issue
Block a user