|
|
@@ -1,49 +0,0 @@
|
|
|
-//package com.x.processplatform.assemble.designer.jaxrs.projection;
|
|
|
-//
|
|
|
-//import com.x.base.core.container.EntityManagerContainer;
|
|
|
-//import com.x.base.core.container.factory.EntityManagerContainerFactory;
|
|
|
-//import com.x.base.core.project.exception.ExceptionAccessDenied;
|
|
|
-//import com.x.base.core.project.exception.ExceptionEntityNotExist;
|
|
|
-//import com.x.base.core.project.http.ActionResult;
|
|
|
-//import com.x.base.core.project.http.EffectivePerson;
|
|
|
-//import com.x.base.core.project.jaxrs.WrapBoolean;
|
|
|
-//import com.x.processplatform.assemble.designer.Business;
|
|
|
-//import com.x.processplatform.assemble.designer.ThisApplication;
|
|
|
-//import com.x.processplatform.core.entity.element.Application;
|
|
|
-//import com.x.processplatform.core.entity.element.Process;
|
|
|
-//import com.x.processplatform.core.entity.element.Projection;
|
|
|
-//
|
|
|
-//class ActionExecute extends BaseAction {
|
|
|
-//
|
|
|
-// ActionResult<Wo> execute(EffectivePerson effectivePerson, String flag) throws Exception {
|
|
|
-// try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {
|
|
|
-// ActionResult<Wo> result = new ActionResult<>();
|
|
|
-// Business business = new Business(emc);
|
|
|
-// Projection projection = emc.flag(flag, Projection.class);
|
|
|
-// if (null == projection) {
|
|
|
-// throw new ExceptionEntityNotExist(flag, Projection.class);
|
|
|
-// }
|
|
|
-// Application application = emc.flag(projection.getApplication(), Application.class);
|
|
|
-// if (null == application) {
|
|
|
-// throw new ExceptionEntityNotExist(projection.getApplication(), Application.class);
|
|
|
-// }
|
|
|
-// if (!business.editable(effectivePerson, application)) {
|
|
|
-// throw new ExceptionAccessDenied(effectivePerson.getDistinguishedName());
|
|
|
-// }
|
|
|
-// if (!ThisApplication.projectionExecuteQueue.contains(projection.getId())) {
|
|
|
-// ThisApplication.projectionExecuteQueue.send(projection.getId());
|
|
|
-// } else {
|
|
|
-// throw new ExceptionAlreadyAddQueue();
|
|
|
-// }
|
|
|
-// Wo wo = new Wo();
|
|
|
-// wo.setValue(true);
|
|
|
-// result.setData(wo);
|
|
|
-// return result;
|
|
|
-// }
|
|
|
-// }
|
|
|
-//
|
|
|
-// public static class Wo extends WrapBoolean {
|
|
|
-//
|
|
|
-// }
|
|
|
-//
|
|
|
-//}
|