对参数添加try验证

This commit is contained in:
wangxiaowei 2024-06-27 09:55:36 +08:00
parent 129e1954c5
commit 2c20346f41

@ -68,11 +68,14 @@
},
onLoad(options) {
let title = '添加商品'
if (options.id) {
// 通过id去获取信息,然后重新编辑提交
title = '商品修改'
this.shop_id = options.id
}
try {
if (options.id) {
// 通过id去获取信息,然后重新编辑提交
title = '商品修改'
this.shop_id = options.id
}
} catch(e) {}
uni.setNavigationBarTitle({
title: title
})