|
@@ -10,6 +10,8 @@ import com.timevale.esign.sdk.tech.bean.OrganizeBean;
|
|
import com.timevale.esign.sdk.tech.bean.PersonBean;
|
|
import com.timevale.esign.sdk.tech.bean.PersonBean;
|
|
import com.timevale.esign.sdk.tech.bean.PosBean;
|
|
import com.timevale.esign.sdk.tech.bean.PosBean;
|
|
import com.timevale.esign.sdk.tech.bean.SignPDFFileBean;
|
|
import com.timevale.esign.sdk.tech.bean.SignPDFFileBean;
|
|
|
|
+import com.timevale.esign.sdk.tech.bean.UpdateOrganizeBean;
|
|
|
|
+import com.timevale.esign.sdk.tech.bean.UpdatePersonBean;
|
|
import com.timevale.esign.sdk.tech.bean.result.AddAccountResult;
|
|
import com.timevale.esign.sdk.tech.bean.result.AddAccountResult;
|
|
import com.timevale.esign.sdk.tech.bean.result.AddSealResult;
|
|
import com.timevale.esign.sdk.tech.bean.result.AddSealResult;
|
|
import com.timevale.esign.sdk.tech.bean.result.FileDigestSignResult;
|
|
import com.timevale.esign.sdk.tech.bean.result.FileDigestSignResult;
|
|
@@ -32,6 +34,9 @@ import com.timevale.tech.sdk.bean.ProjectConfig;
|
|
import com.ym.mec.thirdparty.eseal.ESealPlugin;
|
|
import com.ym.mec.thirdparty.eseal.ESealPlugin;
|
|
import com.ym.mec.thirdparty.exception.ThirdpartyException;
|
|
import com.ym.mec.thirdparty.exception.ThirdpartyException;
|
|
|
|
|
|
|
|
+/**
|
|
|
|
+ * 接口文档地址 https://open.esign.cn/doc/detail?id=opendoc%2Fpaas_sdk%2Fbzu9e8&namespace=opendoc%2Fpaas_sdk&searchText=
|
|
|
|
+ */
|
|
@Service
|
|
@Service
|
|
public class TsignPlugin implements ESealPlugin, InitializingBean, DisposableBean {
|
|
public class TsignPlugin implements ESealPlugin, InitializingBean, DisposableBean {
|
|
|
|
|
|
@@ -97,7 +102,23 @@ public class TsignPlugin implements ESealPlugin, InitializingBean, DisposableBea
|
|
throw new ThirdpartyException(result.getMsg());
|
|
throw new ThirdpartyException(result.getMsg());
|
|
}
|
|
}
|
|
|
|
|
|
- /**
|
|
|
|
|
|
+ @Override
|
|
|
|
+ public boolean updateUserAccount(String accountId, String realName, String idcard, String mobile) {
|
|
|
|
+
|
|
|
|
+ UpdatePersonBean updatePersonBean = new UpdatePersonBean();
|
|
|
|
+ updatePersonBean.setMobile(mobile);// 手机号码,可空
|
|
|
|
+ updatePersonBean.setName(realName);// 姓名,可空
|
|
|
|
+
|
|
|
|
+ AccountService service = serviceClient.accountService();
|
|
|
|
+ Result result = service.updateAccount(accountId, updatePersonBean, null);
|
|
|
|
+
|
|
|
|
+ if (result.getErrCode() == 0) {
|
|
|
|
+ return true;
|
|
|
|
+ }
|
|
|
|
+ throw new ThirdpartyException(result.getMsg());
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ /**
|
|
* 创建用户账户(企业)
|
|
* 创建用户账户(企业)
|
|
*
|
|
*
|
|
* @param orgName 机构名称
|
|
* @param orgName 机构名称
|
|
@@ -119,6 +140,22 @@ public class TsignPlugin implements ESealPlugin, InitializingBean, DisposableBea
|
|
throw new ThirdpartyException("创建企业账户接口调用失败code=" + result.getErrCode() + "msg=" + result.getMsg());
|
|
throw new ThirdpartyException("创建企业账户接口调用失败code=" + result.getErrCode() + "msg=" + result.getMsg());
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ @Override
|
|
|
|
+ public boolean updateOrganAccount(String accountId, String orgName, String organCode) {
|
|
|
|
+
|
|
|
|
+ UpdateOrganizeBean updateOrganizeBean = new UpdateOrganizeBean();
|
|
|
|
+ updateOrganizeBean.setName(orgName);//机构名称,可空
|
|
|
|
+
|
|
|
|
+ AccountService service = serviceClient.accountService();
|
|
|
|
+ Result result = service.updateAccount(accountId, updateOrganizeBean, null);
|
|
|
|
+
|
|
|
|
+ if (result.getErrCode() == 0) {
|
|
|
|
+ return true;
|
|
|
|
+ }
|
|
|
|
+ throw new ThirdpartyException(result.getMsg());
|
|
|
|
+
|
|
|
|
+ }
|
|
|
|
+
|
|
/**
|
|
/**
|
|
* 创建印章
|
|
* 创建印章
|
|
*
|
|
*
|