Commit ac1a3a06 by wkliang

修正 response

parent ab6b77e7
...@@ -22,45 +22,45 @@ class ProductCtl extends CtlBase { ...@@ -22,45 +22,45 @@ class ProductCtl extends CtlBase {
async getPage (pobj, pobj2, req) { async getPage (pobj, pobj2, req) {
try { try {
let res = await this.prodSve.getPage(pobj) let res = await this.prodSve.getPage(pobj)
return system.getResultSuccess(res) return res
} catch (error) { } catch (error) {
return system.getResultFail(500, err,message) return system.getResultFail(500, err.message)
} }
} }
async getAllDic (pobj, pobj2, req) { async getAllDic (pobj, pobj2, req) {
try { try {
let res = await this.prodSve.getAllDic(pobj) let res = await this.prodSve.getAllDic(pobj)
return system.getResultSuccess(res) return res
} catch (error) { } catch (error) {
return system.getResultFail(500, err,message) return system.getResultFail(500, err.message)
} }
} }
async getByIds (pobj, pobj2, req) { async getByIds (pobj, pobj2, req) {
try { try {
let res = await this.prodSve.getByIds(pobj) let res = await this.prodSve.getByIds(pobj)
return system.getResultSuccess(res) return res
} catch (error) { } catch (error) {
return system.getResultFail(500, err,message) return system.getResultFail(500, err.message)
} }
} }
async getItems (pobj, pobj2, req) { async getItems (pobj, pobj2, req) {
try { try {
let res = await this.prodSve.getItems(pobj) let res = await this.prodSve.getItems(pobj)
return system.getResultSuccess(res) return res
} catch (error) { } catch (error) {
return system.getResultFail(500, err,message) return system.getResultFail(500, err.message)
} }
} }
async createOrUpdate (pobj, pobj2, req) { async createOrUpdate (pobj, pobj2, req) {
try { try {
let res = await this.prodSve.createOrUpdate(pobj) let res = await this.prodSve.createOrUpdate(pobj)
return system.getResultSuccess(res) return res
} catch (error) { } catch (error) {
return system.getResultFail(500, err,message) return system.getResultFail(500, err.message)
} }
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment