|
|
@@ -45,7 +45,8 @@
|
|
|
<div class="tel info_msg">
|
|
|
<label>联系方式:</label>
|
|
|
<input
|
|
|
- type="text"
|
|
|
+ type="tel"
|
|
|
+ disabled="true"
|
|
|
class="card ipt"
|
|
|
v-model="question.contact_phone"
|
|
|
/>
|
|
|
@@ -68,13 +69,13 @@ export default {
|
|
|
imgIdList: [],
|
|
|
question: {
|
|
|
content: "",
|
|
|
- contact_name: getApp().globalData.contact_name,
|
|
|
+ contact_name: uni.getStorageSync('appealName') || '',
|
|
|
contact_phone: getApp().globalData.user_phone,
|
|
|
},
|
|
|
};
|
|
|
},
|
|
|
- onLoad(){
|
|
|
- console.log(getApp().globalData.contact_name);
|
|
|
+ onShow(){
|
|
|
+ this.question.contact_phone = getApp().globalData.user_phone
|
|
|
},
|
|
|
methods: {
|
|
|
getImage(type) {
|
|
|
@@ -164,6 +165,26 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
submit() {
|
|
|
+ if(!this.question.content){
|
|
|
+ uni.showToast({
|
|
|
+ title:'请输入诉求内容',
|
|
|
+ icon:'none'
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if(!this.question.contact_name){
|
|
|
+ uni.showToast({
|
|
|
+ title:'请输入联系人名称',
|
|
|
+ icon:'none'
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if(!this.question.contact_phone){
|
|
|
+ uni.navigateTo({
|
|
|
+ url:'../auth/index'
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
let md5Sign = md5(
|
|
|
"method=" +
|
|
|
"consult" +
|
|
|
@@ -198,13 +219,12 @@ export default {
|
|
|
title: "诉求提交成功",
|
|
|
icon: "none",
|
|
|
duration: 2500,
|
|
|
+ mask:true
|
|
|
});
|
|
|
-
|
|
|
- getApp().globalData.contact_name = this.question.contact_name,
|
|
|
- getApp().globalData.user_phone = this.question.contact_phone,
|
|
|
+ uni.setStorageSync('appealName',this.question.contact_name);
|
|
|
setTimeout(() => {
|
|
|
uni.navigateBack({});
|
|
|
- }, 2500);
|
|
|
+ }, 1000);
|
|
|
} else {
|
|
|
uni.showToast({
|
|
|
title: res.data.msg,
|