Commit 7146d594 by 庄冰

aaa

parent 2099b35c
...@@ -7,7 +7,9 @@ class FormItemCtl extends CtlBase { ...@@ -7,7 +7,9 @@ class FormItemCtl extends CtlBase {
constructor() { constructor() {
super("configmag", CtlBase.getServiceName(FormItemCtl)); super("configmag", CtlBase.getServiceName(FormItemCtl));
} }
async getFormItemListByFormId(pobj){
return this.service.getFormItemListByFormId(pobj);
}
/** /**
* 重写添加方法 * 重写添加方法
* @param pobj * @param pobj
......
...@@ -7,7 +7,18 @@ class FormitemService extends ServiceBase { ...@@ -7,7 +7,18 @@ class FormitemService extends ServiceBase {
super("configmag", ServiceBase.getDaoName(FormitemService)); super("configmag", ServiceBase.getDaoName(FormitemService));
} }
async getFormItemListByFormId(pobj){
if(!pobj || !pobj.form_id){
return system.getResultFail(-101,"表单id不能为空");
}
var list = await this.dao.model.findAll({
attributes:[["code","key"],["name","title"]],
where:{form_id:pobj.form_id},
raw:true,
order:[["sequence","asc"]]
});
return system.getResultSuccess(list);
}
/** /**
* 创建表单项 * 创建表单项
* @param pobj * @param pobj
......
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