|
@@ -289,8 +289,9 @@ public class ESignServiceImpl implements IESignService {
|
|
|
|
|
|
int x = position.get("componentPositionX").getAsInt();
|
|
int x = position.get("componentPositionX").getAsInt();
|
|
int y = position.get("componentPositionY").getAsInt();
|
|
int y = position.get("componentPositionY").getAsInt();
|
|
|
|
+ int pageNum = position.get("componentPageNum").getAsInt();
|
|
|
|
|
|
- SignPositionGroup.ComponentPosition cp = new SignPositionGroup.ComponentPosition(x, y);
|
|
|
|
|
|
+ SignPositionGroup.ComponentPosition cp = new SignPositionGroup.ComponentPosition(x, y ,pageNum);
|
|
|
|
|
|
if ("商户".equals(role)) {
|
|
if ("商户".equals(role)) {
|
|
merchant.add(cp);
|
|
merchant.add(cp);
|
|
@@ -329,7 +330,9 @@ public class ESignServiceImpl implements IESignService {
|
|
|
|
|
|
signer1.add("psnSignerInfo", psnSignerInfo);
|
|
signer1.add("psnSignerInfo", psnSignerInfo);
|
|
positionGroup.getCustomer().forEach(position -> {
|
|
positionGroup.getCustomer().forEach(position -> {
|
|
- signer1.add("signFields", buildSignFields(contractInfo.getFileId(), position.getX(), position.getY(), 100, 0, 0,false,""));
|
|
|
|
|
|
+ signer1.add("signFields", buildSignFields(contractInfo.getFileId(),
|
|
|
|
+ position.getX(), position.getY(),
|
|
|
|
+ 100, 0, 0,false,"", position.getPageNum()));
|
|
});
|
|
});
|
|
// 企业签署人
|
|
// 企业签署人
|
|
JsonObject signer2 = new JsonObject();
|
|
JsonObject signer2 = new JsonObject();
|
|
@@ -338,7 +341,9 @@ public class ESignServiceImpl implements IESignService {
|
|
orgSignerInfo.addProperty("orgId", orgId);
|
|
orgSignerInfo.addProperty("orgId", orgId);
|
|
positionGroup.getMerchant().forEach(position -> {
|
|
positionGroup.getMerchant().forEach(position -> {
|
|
try {
|
|
try {
|
|
- signer2.add("signFields", buildSignFields(contractInfo.getFileId(), position.getX(), position.getY(), 100, 0, 0,true,orgAuthorizedSeal(orgId)));
|
|
|
|
|
|
+ signer2.add("signFields", buildSignFields(contractInfo.getFileId(),
|
|
|
|
+ position.getX(),
|
|
|
|
+ position.getY(), 100, 0, 0,true,orgAuthorizedSeal(orgId),position.getPageNum()));
|
|
} catch (EsignDemoException e) {
|
|
} catch (EsignDemoException e) {
|
|
throw new RuntimeException(e);
|
|
throw new RuntimeException(e);
|
|
}
|
|
}
|
|
@@ -371,9 +376,13 @@ public class ESignServiceImpl implements IESignService {
|
|
* 构建签署区域
|
|
* 构建签署区域
|
|
*/
|
|
*/
|
|
private JsonArray buildSignFields(String fileId,
|
|
private JsonArray buildSignFields(String fileId,
|
|
- int x, int y,
|
|
|
|
|
|
+ float x, float y,
|
|
int size,
|
|
int size,
|
|
- int dateX, int dateY,boolean autoSign,String signature) {
|
|
|
|
|
|
+ int dateX,
|
|
|
|
+ int dateY,
|
|
|
|
+ boolean autoSign,
|
|
|
|
+ String signature,
|
|
|
|
+ int positionPage) {
|
|
JsonArray signFields = new JsonArray();
|
|
JsonArray signFields = new JsonArray();
|
|
JsonObject field = new JsonObject();
|
|
JsonObject field = new JsonObject();
|
|
|
|
|
|
@@ -393,7 +402,7 @@ public class ESignServiceImpl implements IESignService {
|
|
|
|
|
|
// 位置配置
|
|
// 位置配置
|
|
JsonObject position = new JsonObject();
|
|
JsonObject position = new JsonObject();
|
|
- position.addProperty("positionPage", "1");
|
|
|
|
|
|
+ position.addProperty("positionPage", positionPage);
|
|
position.addProperty("positionX", x);
|
|
position.addProperty("positionX", x);
|
|
position.addProperty("positionY", y);
|
|
position.addProperty("positionY", y);
|
|
normalConfig.add("signFieldPosition", position);
|
|
normalConfig.add("signFieldPosition", position);
|