日照项目的居民端小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

34 lines
581 B

let tempReslove = () => {};
Component({
data: {
hidden: true,
showCancel: true,
title: "",
content: "",
confirmText: "确认",
cancelText: "取消"
},
methods: {
show(opts) {
this.setData({
...opts,
hidden: false
});
return new Promise(reslove => {
tempReslove = reslove;
});
},
hide() {
this.setData({ hidden: true });
},
confirm() {
tempReslove(true);
},
cancel() {
tempReslove(false);
this.hide();
}
}
});