|
|
@@ -188,20 +188,27 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
|
- // ...mapGetters({ categoryData: 'getCategory' }),
|
|
|
- // ...mapGetters({ usageData: 'getUsage' })
|
|
|
},
|
|
|
mounted() {
|
|
|
+ console.log(1111,this.option.tabIndex)
|
|
|
// getCategory()
|
|
|
// getUsage()
|
|
|
},
|
|
|
- onLoad: function() {},
|
|
|
+ onLoad(option) {
|
|
|
+ let tabIndex = uni.getStorageSync("switchTabQuery") || null;
|
|
|
+ if (tabIndex) {
|
|
|
+ uni.removeStorageSync("switchTabQuery");
|
|
|
+ this.tabIndex = parseInt(tabIndex.tabIndex);
|
|
|
+ this._list();
|
|
|
+ }
|
|
|
+ },
|
|
|
onShow() {
|
|
|
- // let tabIndex = uni.getStorageSync("switchTabQuery") || null;
|
|
|
- // if (tabIndex) {
|
|
|
- // uni.removeStorageSync("switchTabQuery");
|
|
|
- // this.tabIndex = parseInt(tabIndex.tabIndex);
|
|
|
- // }
|
|
|
+ let tabIndex = uni.getStorageSync("switchTabQuery") || null;
|
|
|
+ if (tabIndex) {
|
|
|
+ uni.removeStorageSync("switchTabQuery");
|
|
|
+ this.tabIndex = parseInt(tabIndex.tabIndex);
|
|
|
+ this._list();
|
|
|
+ }
|
|
|
},
|
|
|
methods: {
|
|
|
statusFormat(status) {
|
|
|
@@ -249,9 +256,6 @@ export default {
|
|
|
console.log(val);
|
|
|
},
|
|
|
searchFn() {},
|
|
|
- init() {
|
|
|
- this._list();
|
|
|
- },
|
|
|
_list() {
|
|
|
return getListB({
|
|
|
status: this.tabs[this.tabIndex].id,
|
|
|
@@ -291,7 +295,7 @@ export default {
|
|
|
// this.$set(this.list.data[this.operateIndex], "status", 5);
|
|
|
// this.$set(this.list.data[this.operateIndex], "sendType", 1);
|
|
|
freeShipping({ id: this.operateData.id }).then(res => {
|
|
|
- this.init();
|
|
|
+ this._list();
|
|
|
this.$msg("操作成功!");
|
|
|
this.modalCancel();
|
|
|
});
|