o2sword 5 лет назад
Родитель
Сommit
4db903eb6d

+ 2 - 2
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/form/FormAction.java

@@ -254,7 +254,7 @@ public class FormAction extends StandardJaxrsAction {
 	@Path("v2/lookup/document/{docId}/mode/{openMode}")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
-	public void V2LookupWorkOrWorkCompleted(@Suspended final AsyncResponse asyncResponse,
+	public void V2LookupDoc(@Suspended final AsyncResponse asyncResponse,
 											@Context HttpServletRequest request,
 											@JaxrsParameterDescribe("文档ID") @PathParam("docId") String docId,
 											@JaxrsParameterDescribe("文档打开模式:read(只读模式)|edit(编辑模式)") @PathParam("openMode") String openMode) {
@@ -274,7 +274,7 @@ public class FormAction extends StandardJaxrsAction {
 	@Path("v2/lookup/document/{docId}/mode/{openMode}/mobile")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
-	public void V2LookupWorkOrWorkCompletedMobile(@Suspended final AsyncResponse asyncResponse,
+	public void V2LookupDocMobile(@Suspended final AsyncResponse asyncResponse,
 												  @Context HttpServletRequest request,
 												  @JaxrsParameterDescribe("文档ID") @PathParam("docId") String docId,
 												  @JaxrsParameterDescribe("文档打开模式:read(只读模式)|edit(编辑模式)") @PathParam("openMode") String openMode) {

+ 2 - 2
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/form/FormAnonymousAction.java

@@ -53,7 +53,7 @@ public class FormAnonymousAction extends StandardJaxrsAction {
 	@Path("v2/lookup/document/{docId}/mode/{openMode}")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
-	public void V2LookupWorkOrWorkCompleted(@Suspended final AsyncResponse asyncResponse,
+	public void V2LookupDoc(@Suspended final AsyncResponse asyncResponse,
 											@Context HttpServletRequest request,
 											@JaxrsParameterDescribe("文档ID") @PathParam("docId") String docId,
 											@JaxrsParameterDescribe("文档打开模式:read(只读模式)|edit(编辑模式)") @PathParam("openMode") String openMode) {
@@ -73,7 +73,7 @@ public class FormAnonymousAction extends StandardJaxrsAction {
 	@Path("v2/lookup/document/{docId}/mode/{openMode}/mobile")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
-	public void V2LookupWorkOrWorkCompletedMobile(@Suspended final AsyncResponse asyncResponse,
+	public void V2LookupDocMobile(@Suspended final AsyncResponse asyncResponse,
 												  @Context HttpServletRequest request,
 												  @JaxrsParameterDescribe("文档ID") @PathParam("docId") String docId,
 												  @JaxrsParameterDescribe("文档打开模式:read(只读模式)|edit(编辑模式)") @PathParam("openMode") String openMode) {

+ 1 - 1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/form/V2LookupDoc.java

@@ -95,7 +95,7 @@ class V2LookupDoc extends BaseAction {
 				try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {
 					Form f;
 					for (String id : properties.getRelatedFormList()) {
-						f = emc.find(id, Form.class);
+						f = emc.fetch(id, Form.class, ListTools.toList(JpaObject.id_FIELDNAME, JpaObject.updateTime_FIELDNAME));
 						if (null != f) {
 							list.add(f.getId() + f.getUpdateTime().getTime());
 						}

+ 1 - 1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/form/V2LookupDocMobile.java

@@ -96,7 +96,7 @@ class V2LookupDocMobile extends BaseAction {
 					Business business = new Business(emc);
 					Form f;
 					for (String id : properties.getMobileRelatedFormList()) {
-						f = business.getFormFactory().pick(id);
+						f = emc.fetch(id, Form.class, ListTools.toList(JpaObject.id_FIELDNAME, JpaObject.updateTime_FIELDNAME));
 						if (null != f) {
 							list.add(f.getId() + f.getUpdateTime().getTime());
 						}