const _my = require("../../__antmove/api/index.js")(my); const wx = _my; // components/navigator/index.js const app = getApp(); Component({ /** * 组件的属性列表 */ properties: { title: { type: String, value: "杭州壹芯" }, showArrow: { type: Boolean, value: true }, titleStyle: { type: String, value: "black" }, bgColor: { type: String, value: "white" } }, externalClasses: [], /** * 组件的初始数据 */ data: { statusBarHeight: 0, titleBarHeight: 0, }, /** * 组件的方法列表 */ methods: { back() { if (this.data.showArrow) { wx.navigateBack({ delta: 1 }); } else { wx.reLaunch({ url: '/pages/resitor_scence/resitor_scence' }) } }, antmoveAction: function () { //执行时动态赋值,请勿删除 } }, onInit: function() { this.setData({ statusBarHeight: app.globalData.statusBarHeight, titleBarHeight: app.globalData.titleBarHeight }) } });