如果不是全功能用户直接返回

This commit is contained in:
yuxueliang0813 2025-07-18 17:15:19 +08:00
parent 1ba724bf57
commit be78f71051
1 changed files with 6 additions and 0 deletions

View File

@ -1,11 +1,13 @@
package shjh.jhzj7.fi.fi.plugin.form;
import kd.bos.context.RequestContext;
import kd.bos.db.DB;
import kd.bos.db.DBRoute;
import kd.bos.form.events.AfterDoOperationEventArgs;
import kd.bos.form.plugin.AbstractFormPlugin;
import kd.bos.logging.Log;
import kd.bos.logging.LogFactory;
import kd.bos.servicehelper.permission.PermissionServiceHelper;
public class TestDBFormPlugin extends AbstractFormPlugin {
@ -15,6 +17,10 @@ public class TestDBFormPlugin extends AbstractFormPlugin {
public void afterDoOperation(AfterDoOperationEventArgs e) {
super.afterDoOperation(e);
if("shjh_btnok".equals(e.getOperateKey())){
//如果不是全功能用户直接返回
if(PermissionServiceHelper.isSuperUser(RequestContext.get().getCurrUserId())){
return;
}
String dbnum = (String) this.getModel().getValue("shjh_dbnum");//标识
String sql = (String) this.getModel().getValue("shjh_sqls");//sql语句
try{