Browse Source

添加 弹出信息

feature/feature-compatible
fengchengzhi 7 years ago
parent
commit
19ec410c4e
2 changed files with 17 additions and 6 deletions
  1. 5
      src/view/put-money.vue
  2. 18
      src/view/service-evaluation.vue

5
src/view/put-money.vue

@ -44,6 +44,7 @@
export default{ export default{
data() { data() {
return { return {
//
inputCue : '(请输入整数金额)', inputCue : '(请输入整数金额)',
// //
isActive:false, isActive:false,
@ -73,7 +74,8 @@
methods:{ methods:{
// //
submit() { submit() {
if(this.isActive) {
if(this.isActive) {
console.log(this.inputVal)
putMoney.putMoney( putMoney.putMoney(
{amount:this.inputVal} {amount:this.inputVal}
).then(res => { ).then(res => {
@ -82,6 +84,7 @@
}else { }else {
this.$vux.toast.text(res.msg,'middle') this.$vux.toast.text(res.msg,'middle')
} }
this.$vux.toast.text(res)
}) })
} }
}, },

18
src/view/service-evaluation.vue

@ -68,7 +68,7 @@
</transition> </transition>
<transition name="alertFade"> <transition name="alertFade">
<div class="tips" v-show="alertShow"> <div class="tips" v-show="alertShow">
请完整填写评价
{{alertTip}}
</div> </div>
</transition> </transition>
<status :code="code" v-show="statusShow"></status> <status :code="code" v-show="statusShow"></status>
@ -94,7 +94,9 @@ export default {
content: "", content: "",
alertShow: false, alertShow: false,
code: 4, code: 4,
statusShow: false
statusShow: false,
//
alertTip: '请完整填写评价',
}; };
}, },
components: { components: {
@ -118,6 +120,7 @@ export default {
this.serviceScore == 0 || this.serviceScore == 0 ||
this.professionScore == 0 this.professionScore == 0
) { ) {
this.alertTip = '请完整填写评价'
this.alertShow = true; this.alertShow = true;
setTimeout(() => { setTimeout(() => {
this.alertShow = false; this.alertShow = false;
@ -146,6 +149,11 @@ export default {
this.statusShow = true; this.statusShow = true;
} else if (code == 1) { } else if (code == 1) {
// //
this.alertTip = res.msg
this.alertShow = true;
setTimeout(() => {
this.alertShow = false;
}, 3000);
} else if (code == 2) { } else if (code == 2) {
// //
this.code = 2; this.code = 2;
@ -164,9 +172,9 @@ export default {
}, },
getParam(name) { getParam(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)"); var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
// var r = window.location.search.substr(1).match(reg);
var url = '?name=林同学&time=2018:07:07';
var r = url.substr(1).match(reg);
var r = window.location.search.substr(1).match(reg);
// var url = '?name=&time=2018:07:07';
// var r = url.substr(1).match(reg);
if (r != null) return unescape(r[2]); if (r != null) return unescape(r[2]);
return null; return null;
}, },

Loading…
Cancel
Save