{"hidden":false,"children":[{"configs":{"serverScript":"var recs1, recs2, data = Wb.decode(app.get('data')),beanname=app.get(\"bean\"),methodname=app.get(\"method\");\n\n\n/*//更新表1\nrecs1 = data[0].create;\nWb.each(recs1, function(rec) {\n  Wb.apply(rec, {\n    EMPLOYEE_ID: SysUtil.getId(),\n    DEPT_ID: '0040CCVTQ71Q7' //部门ID设置为常量，仅用于演示目的\n  });\n});\napp.set({\n  create: Wb.encode(recs1),\n  update: Wb.encode(data[0].update),\n  destroy: Wb.encode(data[0].destroy)\n});\napp.update({\n  tableName: 'WB_EMPLOYEE'\n}); //使用app.update方法默认自动启用数据库事务，无需再显式启用事务\n\n//更新表2\nrecs2 = data[1].create;\nWb.each(recs2, function(rec) {\n  rec.COMPANY_ID = SysUtil.getId();\n});\napp.set({\n  create: Wb.encode(recs2),\n  update: Wb.encode(data[1].update),\n  destroy: Wb.encode(data[1].destroy)\n});\napp.update({\n  tableName: 'WB_COMPANY'\n});\n\n//更新表单数据\n//var panelData=data[2];数据可视业务需要取用\napp.send([recs1, recs2]);*/\napp.rundomain(beanname,methodname);","itemId":"module"},"expanded":false,"children":[],"type":"module"}],"roles":{},"title":"保存全部","iconCls":"","inframe":false,"pageLink":""}