Commit b63ae168 authored by zhangjianguo's avatar zhangjianguo

卡券接口注释

parent eb07179b
...@@ -88,7 +88,6 @@ export default { ...@@ -88,7 +88,6 @@ export default {
this.contentHeight = this.$utils.calcContentHeight(-40) + "px"; this.contentHeight = this.$utils.calcContentHeight(-40) + "px";
this.mainColor = this.$uiConfig.mainColor; this.mainColor = this.$uiConfig.mainColor;
this.u = uni.getStorageSync("mall_UserInfo"); this.u = uni.getStorageSync("mall_UserInfo");
console.log(this.u)
if (!this.u) { if (!this.u) {
this.u = { this.u = {
nickName: "未登录", nickName: "未登录",
...@@ -117,7 +116,7 @@ export default { ...@@ -117,7 +116,7 @@ export default {
}, },
methods: { methods: {
change(index) { change(index) {
console.log(index)
this.current = index; this.current = index;
this.page = 1; this.page = 1;
this.g = []; this.g = [];
...@@ -127,30 +126,31 @@ export default { ...@@ -127,30 +126,31 @@ export default {
init() { init() {
this.isover = false; this.isover = false;
let h = this.apiheader(); let h = this.apiheader();
this.request( this.loading = false;
{ // this.request(
url: "", // {
header: h, // url: "",
data: { // header: h,
r: "api/card/user-card", // data: {
status: this.current+1, // r: "api/card/user-card",
page: this.page, // status: this.current+1,
}, // page: this.page,
}, // },
(res) => { // },
this.loading = false; // (res) => {
// this.loading = false;
if(res.data.list.length>0){ // if(res.data.list.length>0){
this.g = this.g.concat(res.data.list); // this.g = this.g.concat(res.data.list);
// TODO 这里没返一共多少页 注意下 // // TODO 这里没返一共多少页 注意下
// this.page_count = res.data.pagination.page_count; // // this.page_count = res.data.pagination.page_count;
// if (this.page_count == 1) { // // if (this.page_count == 1) {
// this.isover = true; // // this.isover = true;
// } // // }
} // }
} // }
); // );
}, },
lower(e) { lower(e) {
if (this.page < this.page_count) { if (this.page < this.page_count) {
......
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