Commit 3f1feab9 by wkliang

诊断 新建方案

parent 81d7406e
...@@ -40,12 +40,12 @@ class DiagnosisNeedBusAPI extends APIBase { ...@@ -40,12 +40,12 @@ class DiagnosisNeedBusAPI extends APIBase {
case 'getNeedDetail': // 需求详情 case 'getNeedDetail': // 需求详情
opResult = await this.needSve.getItemByNeedNo(pobj); opResult = await this.needSve.getItemByNeedNo(pobj);
break break
case 'addCase': case 'addCase': // 新建方案
opResult = await this.dnbSve.addCase(pobj) opResult = await this.dnbSve.addCase(pobj, pobj.actionBody)
break break
default: default:
opResult = system.getResult(null, "actionType参数错误"); opResult = system.getResult(null, "actionType参数错误");
break; break
} }
return opResult; return opResult;
} }
......
...@@ -2,10 +2,10 @@ ...@@ -2,10 +2,10 @@
module.exports = function(sequelize, DataTypes) { module.exports = function(sequelize, DataTypes) {
return sequelize.define('diagnosisneedsolution', { return sequelize.define('diagnosisneedsolution', {
diagnosisNo: DataTypes.STRING, diagnosis_no: DataTypes.STRING,
solutionContent: DataTypes.JSON, solution_content: DataTypes.JSON,
creatorId: DataTypes.INTEGER, creator_id: DataTypes.INTEGER,
updatorId: DataTypes.INTEGER, updator_id: DataTypes.INTEGER,
}, { }, {
tableName: 'n_zzzd_need_solution', tableName: 'n_zzzd_need_solution',
paranoid: true,//假的删除 paranoid: true,//假的删除
......
...@@ -102,8 +102,11 @@ class diagnosisneedbusService extends ServiceBase { ...@@ -102,8 +102,11 @@ class diagnosisneedbusService extends ServiceBase {
let param = { let param = {
diagnosis_no: data.diagnosisNo, diagnosis_no: data.diagnosisNo,
solution_content: data.solutionContent, solution_content: data.solutionContent,
creator_id: pobj.userInfo.id, }
updator_id: pobj.userInfo.id
if (pobj.userInfo && pobj.userInfo.id) {
param.creator_id = pobj.userInfo.id,
param.updator_id = pobj.userInfo.id
} }
let res = await this.solDao.create(param) let res = await this.solDao.create(param)
return System.getResultSuccess(res) return System.getResultSuccess(res)
......
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