|
|
@@ -79,9 +79,19 @@ Page({
|
|
|
* @author : 姜永辉
|
|
|
*/
|
|
|
saveData() {
|
|
|
+
|
|
|
return this.excute(this.data.service, this.data.service.insert, this.data.params);
|
|
|
},
|
|
|
|
|
|
+ /**
|
|
|
+ * @desc : 编辑查询
|
|
|
+ * @date : 2024/2/1 15:49
|
|
|
+ * @author : 姜永辉
|
|
|
+ */
|
|
|
+ selectById(params) {
|
|
|
+ return this.excute(this.data.service, params.id, null);
|
|
|
+ },
|
|
|
+
|
|
|
/**
|
|
|
* 生命周期函数--监听页面加载
|
|
|
*/
|
|
|
@@ -92,6 +102,8 @@ Page({
|
|
|
eventChannel.on('params', function (data) {
|
|
|
// 获取参数
|
|
|
console.log("onLoad", data);
|
|
|
+ _this.selectById(data)
|
|
|
+
|
|
|
})
|
|
|
}
|
|
|
})
|