diff --git a/api/user.js b/api/user.js index 373eb0c..e9e78db 100644 --- a/api/user.js +++ b/api/user.js @@ -695,4 +695,16 @@ export function getBankInfo() { */ export function getBrandList() { return request.get('user/getBrandList'); +} + +/** + * 检测用户补全信息 + * + */ +export function getCheck() { + return request.get('user/getCheck'); +} +/** 修改用户信息 */ +export function modifyMes(data) { + return request.get(`user/update`, data) } \ No newline at end of file diff --git a/config/app.js b/config/app.js index 560026d..437f178 100644 --- a/config/app.js +++ b/config/app.js @@ -8,7 +8,7 @@ let openPlantGrass = '-openPlantGrass-' // let httpApi = 'http://192.168.31.110:8324' //测试 // let httpApi = 'https://mer.crmeb.net' //生产 // let httpApi = 'https://b2b2c.njrenzhou.cn' //生产 -let httpApi = 'https://shop.freelycar.cn' //生产 +let httpApi = 'https://shop.freelycar.cn' //生产 // 聊天接口修改此字符 小程序聊天要求wss 例如:wss://mer.crmeb.net // let wsApi = 'ws://192.168.3.20:8324' diff --git a/pages.json b/pages.json index d0ca4aa..92b08b8 100644 --- a/pages.json +++ b/pages.json @@ -273,6 +273,12 @@ "navigationBarTitleText": "修改密码" } }, + { + "path": "user_modify_mes/index", + "style": { + "navigationBarTitleText": "补全信息" + } + }, { "path": "user_payment/index", "style": { diff --git a/pages/user/index.vue b/pages/user/index.vue index 728a9ea..877b29e 100644 --- a/pages/user/index.vue +++ b/pages/user/index.vue @@ -224,7 +224,7 @@ // | Author: CRMEB Team // +---------------------------------------------------------------------- let sysHeight = uni.getSystemInfoSync().statusBarHeight + 'px'; - import { getMenuList, getUserInfo, setVisit, getBrandList } from '@/api/user.js'; + import { getMenuList, getUserInfo, setVisit, getBrandList, getCheck } from '@/api/user.js'; import { getVersion } from "@/api/public"; import { orderData } from '@/api/order.js' import { mapGetters } from "vuex"; @@ -335,11 +335,12 @@ activeRouter: '', sysHeight: sysHeight, brandInfo: {}, - + realInfo:{} } }, onLoad() { this.getBrandList(); + this.getCheck(); }, onReady() { this.isNodes++; @@ -348,6 +349,7 @@ this.getVersion() }, onShow: function() { + this.getCheck(); let that = this; let routes = getCurrentPages(); let curRoute = routes[routes.length - 1].route @@ -368,6 +370,23 @@ }, 500) }, methods: { + getCheck:function(){ + let that = this; + getCheck().then(res =>{ + that.$set(that, 'realInfo', res.data); + if(that.realInfo.real_name.length == 0 || that.realInfo.card.length == 0 || that.realInfo.age.length == 0 || that.realInfo.spread_phone.length == 0){ + that.$util.Tips({ + title: '请补全身份信息', + icon: 'error' + }); + setTimeout(function(){ + uni.navigateTo({ + url: '/pages/users/user_modify_mes/index' + }); + },1000) + } + }) + }, getBrandList(){ getBrandList().then(res=>{ this.brandInfo = res.data.user; diff --git a/pages/users/user_info/index.vue b/pages/users/user_info/index.vue index 125f05c..b74e7b3 100644 --- a/pages/users/user_info/index.vue +++ b/pages/users/user_info/index.vue @@ -91,6 +91,34 @@ + + 姓名 + + + + + + + 身份证 + + + + + + + 年龄 + + + + + + + 推荐人电话 + + + + +