【泛微E9】巧用计划任务更新建模授权

\WEAVER\ecology\classbean\weaver\interfaces\schedule\oft\XmSetHrmCronJob.java

package weaver.interfaces.schedule.oft;

import weaver.conn.RecordSet;
import weaver.formmode.setup.ModeRightInfo;
import weaver.interfaces.schedule.BaseCronJob;


public class XmSetHrmCronJob extends BaseCronJob {

	public void execute() {

		RecordSet rs = new RecordSet();
		rs.writeLog("cf====开始执行定时任务:");
		ModeRightInfo ModeRight = new ModeRightInfo();
		String sql = "select id from formtable_main_358";
		rs.execute(sql);
		while(rs.next()){
			int id = rs.getInt("id");
			ModeRight.rebuildModeDataShareByEdit(1, 1105, id);
		}
		
		sql = "select id from uf_nscgddxz";
		rs.execute(sql);
		while(rs.next()){
			int id = rs.getInt("id");
			ModeRight.rebuildModeDataShareByEdit(1, 1097, id);
		}
		
		sql = "select id from uf_mrg_fm723info";
		rs.execute(sql);
		while(rs.next()){
			int id = rs.getInt("id");
			ModeRight.rebuildModeDataShareByEdit(1, 1267, id);
		}
		 
		
		rs.writeLog("cf====执行定时任务结束:");
	}
}

使用方法参考:http://www.chillifish.cn/2021/09/02/2763.html

THE END
分享
二维码
打赏
海报
【泛微E9】巧用计划任务更新建模授权
\WEAVER\ecology\classbean\weaver\interfaces\schedule\oft\XmSetHrmCronJob.java package weaver.interfaces.schedule.oft; import weaver.conn.Record……
<<上一篇
下一篇>>