Commit a662f1bf authored by linwenqing's avatar linwenqing

Merge branch 'test'

parents c5fad040 07663669
......@@ -98,6 +98,23 @@
<text class="font-default-color" :class="{'font-active-color':courselist[2].percent}" v-text="courselist[2].status"></text>
</view>
</view>
<!-- <view class="learn-class1 u-margin-left-30" @click="goPlay(courselist[3])">
<image class="learn-img" :src="courselist[3].pic" mode=""></image>
<image class="bofang" :src="bofang" mode=""></image>
<view class="learn-desc">
<view class="u-font-28 font-bold h68">
{{ courselist[3].title }}
</view>
<view class="u-font-20 learn-intro h48">
{{ courselist[3].desc }}
</view>
</view>
<view class="line-percent u-margin-top-35">
<u-line-progress active-color="#2979ff" :percent="courselist[3].percent" :show-percent="false">
</u-line-progress>
<text class="font-default-color" :class="{'font-active-color':courselist[3].percent}" v-text="courselist[3].status"></text>
</view>
</view> -->
</view>
</scroll-view>
</swiper-item>
......@@ -175,6 +192,15 @@ var json = {
id: 173,
sectionId: "",
},
// {
// title: "充电桩安装要点提示",
// desc: "在充电装安装过程中需要着重注意的要点",
// pic: process.uniEnv.qn_base_url + "cdz-3x-v2.png",
// percent: 0,
// status: "",
// id: 173,
// sectionId: "",
// },
],
test: [
{
......@@ -204,6 +230,15 @@ var json = {
id: 151,
sectionId: "",
},
// {
// title: "充电桩安装要点提示",
// desc: "在充电装安装过程中需要着重注意的要点",
// pic: process.uniEnv.qn_base_url + "cdz-3x-v2.png",
// percent: 0,
// status: "",
// id: 151,
// sectionId: "",
// },
],
prod: [
{
......@@ -233,6 +268,15 @@ var json = {
id: 599,
sectionId: "",
},
// {
// title: "学习-我的模块",
// desc: "学习-我的模块",
// pic: process.uniEnv.qn_base_url + "yaodiantishi.png",
// percent: 0,
// status: "",
// id: 600,
// sectionId: "",
// },
],
};
......@@ -374,7 +418,17 @@ export default {
pic: courseListJson[2].pic,
id: courseListJson[2].id,
sectionId: courseListJson[2].sectionId,
},
}
// ,
// {
// title: courseListJson[3].title,
// desc: courseListJson[3].desc,
// percent: courseListJson[3].percent,
// status: courseListJson[3].status,
// pic: courseListJson[3].pic,
// id: courseListJson[3].id,
// sectionId: courseListJson[3].sectionId,
// },
],
examList: [
{
......
......@@ -33,6 +33,7 @@
keyName: "id_card",
color: "#999999",
desc: ['身份证人像面', '身份证国徽面'],
data: {}
},
electrician_certificate: {
name: "电工证",
......@@ -40,8 +41,8 @@
isUploadName: "未上传",
keyName: "electrician_certificate",
color: "#999999",
desc: ['电工证正面'],
data: {}
},
driver_license: {
name: "驾驶证",
......@@ -50,6 +51,7 @@
keyName: "driver_license",
color: "#999999",
desc: ['驾驶证正面'],
data: {}
},
driving_license: {
name: "行驶证",
......@@ -58,6 +60,7 @@
keyName: "driving_license",
color: "#999999",
desc: ['行驶证正面'],
data: {}
},
vehicle: {
name: "车辆照",
......@@ -66,6 +69,7 @@
keyName: "vehicle",
color: "#999999",
desc: ['车辆正面/看到车牌', '车辆侧面/看到外观'],
data: {}
},
high_sky_license: {
name: "高空证",
......@@ -74,6 +78,7 @@
keyName: "high_sky_license",
color: "#999999",
desc: ['高空证正面'],
data: {}
},
refrigeration_license: {
name: "制冷证",
......@@ -82,6 +87,7 @@
keyName: "refrigeration_license",
color: "#999999",
desc: ['制冷证正面'],
data: {}
},
business_license: {
name: "营业执照",
......@@ -90,8 +96,10 @@
keyName: "business_license",
color: "#999999",
desc: ['营业执照正面'],
data: {}
},
}
},
isRuZhu: false,
}
},
onLoad() {
......@@ -103,24 +111,51 @@
if(res.code != 200){
return
}
this.isRuZhu = true
for(let key in this.list){
let getData = res.data[key];
this.list[key].isUpload = getData.status;
this.list[key].isUploadName = getData.status == 1 ? '已上传' : '未上传';
this.list[key].color = getData.status == 1 ? "#999999" : "#2272FF";
this.list[key].iconColor = getData.status == 1 ? "#2272FF" : "#999999";
this.list[key].data = getData;
if(res.data.length <= 0){
this.list[key].data = {}
}else{
let getData = res.data[key];
this.list[key].isUpload = getData.status;
this.list[key].isUploadName = getData.status == 1 ? '已上传' : '未上传';
this.list[key].color = getData.status != 1 ? "#999999" : "#2272FF";
this.list[key].iconColor = getData.status != 1 ? "#999999" : "#2272FF";
this.list[key].data = getData;
}
}
}).catch((err) => {
this.isRuZhu = false;
});
},
onUnload() {
uni.switchTab({
url: '/pages/index/mine'
});
},
methods: {
isUpload(typeBool) {
return typeBool ? '已上传' : '未上传'
},
toDetail(key) {
let data = this.list[key].data;
data.desc = this.list[key].desc;
let data = null;
if(!this.isRuZhu){
uni.showToast({
icon: "none",
title: "您当前未入驻,暂无法上传证件",
});
return
// data = {
// type: key,
// url: "",
// desc: this.list[key].desc,
// status: 0,
// type_key: key
// }
}else{
data = this.list[key].data;
data.desc = this.list[key].desc;
}
if(data.status != 1){
wx.navigateTo({
url: '/pages/mine/cert/upload?type=' + data.type_key
......
......@@ -139,7 +139,7 @@
this.param.type = this.type;
this.$u.api.submitCert(this.param)
.then((res) => {
if(res.status != 200){
if(res.code != 200){
uni.showToast({
icon: "none",
title: res.message,
......@@ -149,9 +149,6 @@
url: '/pages/mine/cert/index'
});
})
.catch((err) => {
console.log(err);
});
}
}
}
......
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