更新最新代码
This commit is contained in:
@@ -0,0 +1,12 @@
|
||||
const { getLayout } = require('../../utils/layout');
|
||||
Component({
|
||||
properties: { title: String, back: Boolean },
|
||||
data: { statusBarHeight: 20, barHeight: 44, navSide: 100 },
|
||||
lifetimes: { attached: function() { this.setData(getLayout()); } },
|
||||
pageLifetimes: { resize: function() { this.setData(getLayout()); } },
|
||||
methods: { goBack: function() {
|
||||
this.triggerEvent('back');
|
||||
if (getCurrentPages().length > 1) wx.navigateBack();
|
||||
else wx.switchTab({ url: '/pages/index/index' });
|
||||
} }
|
||||
});
|
||||
Reference in New Issue
Block a user