Commit db1bf4b9 authored by 黄奎's avatar 黄奎

页面修改

parent 1d3453a6
...@@ -101,19 +101,7 @@ Vue.prototype.apiJavaPost = function (cmd, msg, successCall, faildCall) { ...@@ -101,19 +101,7 @@ Vue.prototype.apiJavaPost = function (cmd, msg, successCall, faildCall) {
} }
}) })
.then(res => { .then(res => {
if (res.data.resultCode == 10000 || res.data.resultCode == 10001) { successCall(res)
this.$router.push({
path: '/login'
})
} else if (res.data.resultCode == 10005) {
this.$router.go(-1)
} else {
if (res.data.award && res.data.award.mName !== null) {
this.MsgBus.$emit('openRaffleTickets', res.data.award)
}
successCall(res)
}
}, faildCall) }, faildCall)
}, },
...@@ -248,6 +236,9 @@ Vue.prototype.getUrlKey = function (name, url) { ...@@ -248,6 +236,9 @@ Vue.prototype.getUrlKey = function (name, url) {
return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(url) || [, ""])[1].replace(/\+/g, '%20')) || null return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(url) || [, ""])[1].replace(/\+/g, '%20')) || null
} }
Vue.prototype.GetHtml = function (str) { Vue.prototype.GetHtml = function (str) {
return str.replace(/&lt;/g, '<').replace(/&gt;/g, '>') if (str && str != "") {
.replace(/&amp;/g, '&').replace(/&quot;/g, '"').replace(/&apos;/g, "'"); return str.replace(/&lt;/g, '<').replace(/&gt;/g, '>')
.replace(/&amp;/g, '&').replace(/&quot;/g, '"').replace(/&apos;/g, "'");
}
return str;
} }
...@@ -187,6 +187,9 @@ ...@@ -187,6 +187,9 @@
this.accountMsg.Mobile = jsonData.Mobile; this.accountMsg.Mobile = jsonData.Mobile;
this.accountMsg.Name = jsonData.Name; this.accountMsg.Name = jsonData.Name;
this.accountMsg.Sex = jsonData.Sex; this.accountMsg.Sex = jsonData.Sex;
}else if (res.data.resultCode == 10000 || res.data.resultCode == 10001) {
localStorage.removeItem("b2bUser");
this.CommonJump('/login', {})
} }
}, },
err => {} err => {}
...@@ -225,9 +228,9 @@ ...@@ -225,9 +228,9 @@
position:'top', position:'top',
timeout: 2000, // 以毫秒为单位; 0意味着没有超时 timeout: 2000, // 以毫秒为单位; 0意味着没有超时
}) })
// var jsonData = JSON.stringify(res.data.data); }else if (res.data.resultCode == 10000 || res.data.resultCode == 10001) {
// window.localStorage.setItem("b2bUser", jsonData); localStorage.removeItem("b2bUser");
this.CommonJump('/login', {})
} }
}, },
err => {} err => {}
...@@ -283,6 +286,9 @@ ...@@ -283,6 +286,9 @@
position:'top', position:'top',
timeout: 2000, // 以毫秒为单位; 0意味着没有超时 timeout: 2000, // 以毫秒为单位; 0意味着没有超时
}) })
}else if (res.data.resultCode == 10000 || res.data.resultCode == 10001) {
localStorage.removeItem("b2bUser");
this.CommonJump('/login', {})
} }
}, },
err => {} err => {}
......
...@@ -152,6 +152,10 @@ ...@@ -152,6 +152,10 @@
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.InfoData = res.data.data; this.InfoData = res.data.data;
} }
else if (res.data.resultCode == 10000 || res.data.resultCode == 10001) {
localStorage.removeItem("b2bUser");
this.CommonJump('/login', {})
}
}, },
err => {} err => {}
); );
......
...@@ -247,6 +247,10 @@ ...@@ -247,6 +247,10 @@
this.DataList = res.data.data.pageData; this.DataList = res.data.data.pageData;
this.pageCount = res.data.data.pageCount; this.pageCount = res.data.data.pageCount;
} }
else if (res.data.resultCode == 10000 || res.data.resultCode == 10001) {
localStorage.removeItem("b2bUser");
this.CommonJump('/login', {})
}
}, },
err => {} err => {}
); );
......
...@@ -239,7 +239,6 @@ ...@@ -239,7 +239,6 @@
res => { res => {
this.$q.loading.hide() this.$q.loading.hide()
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
console.log(" res.data.data", res.data.data);
this.InfoData = res.data.data.model; this.InfoData = res.data.data.model;
this.modelPrice = res.data.data.modelPrice; this.modelPrice = res.data.data.modelPrice;
} }
......
...@@ -50,9 +50,11 @@ ...@@ -50,9 +50,11 @@
display: block; display: block;
padding: 20px 25px; padding: 20px 25px;
} }
.order-list{
padding:0; .order-list {
padding: 0;
} }
.order-list li { .order-list li {
margin-bottom: 15px; margin-bottom: 15px;
font-size: 0; font-size: 0;
...@@ -118,18 +120,20 @@ ...@@ -118,18 +120,20 @@
} }
} }
.text-my{ .text-my {
color:#00afff; color: #00afff;
} }
.order_titleMobile{
margin:20px 0 10px 0; .order_titleMobile {
font-size:25px; margin: 20px 0 10px 0;
color:#666; font-size: 25px;
color: #666;
} }
@media only screen and (max-width: 1200px) { @media only screen and (max-width: 1200px) {
.order_tour { .order_tour {
width: 100%!important; width: 100% !important;
padding-right:0!important; padding-right: 0 !important;
} }
} }
...@@ -140,24 +144,18 @@ ...@@ -140,24 +144,18 @@
<template v-if="!$q.screen.xs"> <template v-if="!$q.screen.xs">
<div class="order-header"> <div class="order-header">
<div class="order_title">我的訂單</div> <div class="order_title">我的訂單</div>
<q-tabs <q-tabs v-model="tab" inline-label class="text-my">
v-model="tab" <q-tab :name="item.Type" :label="item.Type" v-for="(item,index) in TitList" @click="handleClick(item)"
inline-label :key="index" />
class="text-my"
>
<q-tab :name="item.Type" :label="item.Type" v-for="(item,index) in TitList" @click="handleClick(item)" :key="index" />
</q-tabs> </q-tabs>
</div> </div>
</template> </template>
<template v-if="$q.screen.xs"> <template v-if="$q.screen.xs">
<div> <div>
<div class="order_titleMobile">我的訂單</div> <div class="order_titleMobile">我的訂單</div>
<q-tabs <q-tabs v-model="tab" inline-label class="text-my">
v-model="tab" <q-tab :name="item.Type" :label="item.Type" v-for="(item,index) in TitList" @click="handleClick(item)"
inline-label :key="index" />
class="text-my"
>
<q-tab :name="item.Type" :label="item.Type" v-for="(item,index) in TitList" @click="handleClick(item)" :key="index" />
</q-tabs> </q-tabs>
</div> </div>
</template> </template>
...@@ -216,7 +214,7 @@ ...@@ -216,7 +214,7 @@
props: [], props: [],
data() { data() {
return { return {
tab:'全部', tab: '全部',
qMsg: { qMsg: {
PageIndex: 1, PageIndex: 1,
PageSize: 10, PageSize: 10,
...@@ -281,11 +279,15 @@ ...@@ -281,11 +279,15 @@
"/api/b2b/user/getrecentorder", "/api/b2b/user/getrecentorder",
this.getOrderMsg, this.getOrderMsg,
res => { res => {
this.$q.loading.hide() this.$q.loading.hide();
console.log("res",res);
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.DataList = res.data.data.pageData; this.DataList = res.data.data.pageData;
this.pageCount = res.data.data.pageCount; this.pageCount = res.data.data.pageCount;
} } else if (res.data.resultCode == 10000 || res.data.resultCode == 10001) {
localStorage.removeItem("b2bUser");
this.CommonJump('/login', {})
}
}, },
null null
); );
......
This diff is collapsed.
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