Commit 2a970119 by 程默

fix session

parent dc270954
...@@ -41,10 +41,9 @@ export default { ...@@ -41,10 +41,9 @@ export default {
Object.assign(this.$data, this.$options.data()); Object.assign(this.$data, this.$options.data());
this.options = options; this.options = options;
if(options.sessionid){ if(options.sessionid){
wx.setStorageSync({ try {
key: "sessionid", wx.setStorageSync('sessionid', options.sessionid)
data: options.sessionid } catch (e) { }
});
} }
console.log("onload"); console.log("onload");
this.init(); this.init();
......
...@@ -31,12 +31,11 @@ export default { ...@@ -31,12 +31,11 @@ export default {
this.options_orderType = options.orderType; this.options_orderType = options.orderType;
this.options_isCard= options.isCard; this.options_isCard= options.isCard;
this.options_isCardTitle= options.isCardTit; this.options_isCardTitle= options.isCardTit;
if(options.sessionid){ if(options.sessionid){
wx.setStorageSync({ try {
key: "sessionid", wx.setStorageSync('sessionid', options.sessionid)
data: options.sessionid } catch (e) { }
}); }
}
let that = this; let that = this;
wx.getStorage({ wx.getStorage({
key: "openid", key: "openid",
......
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