Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
8
8timerapiv200
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
8timerv2
8timerapiv200
Commits
ebba5975
Commit
ebba5975
authored
4 years ago
by
邓实川
Committed by
chenzg
3 years ago
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
电子合同报错信息优化
parent
88027c2a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
27 additions
and
15 deletions
+27
-15
src/main/java/cn/timer/api/controller/dzht/DzhtController2.java
+13
-6
src/main/java/cn/timer/api/controller/dzht/cn/tign/hz/helper/SignHelper.java
+13
-8
src/main/java/cn/timer/api/utils/CheckUtil.java
+1
-1
No files found.
src/main/java/cn/timer/api/controller/dzht/DzhtController2.java
View file @
ebba5975
...
@@ -895,19 +895,21 @@ public class DzhtController2 {
...
@@ -895,19 +895,21 @@ public class DzhtController2 {
@ApiOperation
(
value
=
"获取签署地址"
,
httpMethod
=
"GET"
,
notes
=
"接口发布说明"
)
@ApiOperation
(
value
=
"获取签署地址"
,
httpMethod
=
"GET"
,
notes
=
"接口发布说明"
)
public
Result
<
Object
>
qrySignUrl
(
@CurrentUser
UserBean
userBean
,
@RequestParam
String
flowId
,
public
Result
<
Object
>
qrySignUrl
(
@CurrentUser
UserBean
userBean
,
@RequestParam
String
flowId
,
@RequestParam
(
required
=
false
)
String
organizeId
,
@RequestParam
(
required
=
false
)
String
urlType
)
{
@RequestParam
(
required
=
false
)
String
organizeId
,
@RequestParam
(
required
=
false
)
String
urlType
)
{
JSONObject
json
Object
=
null
;
JSONObject
json
=
null
;
try
{
try
{
QueryWrapper
<
DzhtAssoGrzc
>
queryWrapper
=
new
QueryWrapper
<
DzhtAssoGrzc
>();
QueryWrapper
<
DzhtAssoGrzc
>
queryWrapper
=
new
QueryWrapper
<
DzhtAssoGrzc
>();
queryWrapper
.
eq
(
"emp_num"
,
userBean
.
getEmpNum
()).
select
(
"account_id"
);
queryWrapper
.
eq
(
"emp_num"
,
userBean
.
getEmpNum
()).
select
(
"account_id"
);
String
accountId
=
DzhtAssoGrzc
.
builder
().
build
().
selectOne
(
queryWrapper
).
getAccountId
();
String
accountId
=
DzhtAssoGrzc
.
builder
().
build
().
selectOne
(
queryWrapper
).
getAccountId
();
TokenHelper
.
getTokenData
();
// 获取鉴权
TokenHelper
.
getTokenData
();
// 获取鉴权
json
Object
=
SignHelper
.
qrySignUrl
(
flowId
,
accountId
,
organizeId
,
urlType
);
json
=
SignHelper
.
qrySignUrl
(
flowId
,
accountId
,
organizeId
,
urlType
);
}
catch
(
DefineException
e
)
{
}
catch
(
DefineException
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
return
ResultUtil
.
error
();
return
ResultUtil
.
error
();
}
}
return
ResultUtil
.
data
(
jsonObject
,
"获取成功"
);
if
(
json
!=
null
&&
json
.
getLong
(
"code"
)
!=
0
)
return
ResultUtil
.
error
(
json
.
getString
(
"message"
));
return
ResultUtil
.
data
(
json
.
getJSONObject
(
"data"
),
"成功"
);
}
}
// 流程签署人催签
// 流程签署人催签
...
@@ -943,7 +945,11 @@ public class DzhtController2 {
...
@@ -943,7 +945,11 @@ public class DzhtController2 {
if
(
grzc
!=
null
)
{
if
(
grzc
!=
null
)
{
operatorId
=
grzc
.
getAccountId
();
operatorId
=
grzc
.
getAccountId
();
}
}
SignHelper
.
revokeSignFlow
(
flowId
,
revokeReason
,
operatorId
);
JSONObject
json
=
SignHelper
.
revokeSignFlow
(
flowId
,
revokeReason
,
operatorId
);
if
(
json
!=
null
&&
json
.
getLong
(
"code"
)
!=
0
)
{
return
ResultUtil
.
error
(
json
.
getString
(
"message"
));
}
}
catch
(
DefineException
e
)
{
}
catch
(
DefineException
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
return
ResultUtil
.
error
();
return
ResultUtil
.
error
();
...
@@ -975,9 +981,10 @@ public class DzhtController2 {
...
@@ -975,9 +981,10 @@ public class DzhtController2 {
json
=
SignHelper
.
downloadFlowDoc
(
flowId
);
json
=
SignHelper
.
downloadFlowDoc
(
flowId
);
}
catch
(
DefineException
e
)
{
}
catch
(
DefineException
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
return
ResultUtil
.
error
();
}
}
return
ResultUtil
.
data
(
json
,
"成功"
);
if
(
json
!=
null
&&
json
.
getLong
(
"code"
)
!=
0
)
return
ResultUtil
.
error
(
json
.
getString
(
"message"
));
return
ResultUtil
.
data
(
json
.
getJSONObject
(
"data"
),
"成功"
);
}
}
/**
/**
...
...
This diff is collapsed.
Click to expand it.
src/main/java/cn/timer/api/controller/dzht/cn/tign/hz/helper/SignHelper.java
View file @
ebba5975
...
@@ -89,13 +89,16 @@ public class SignHelper {
...
@@ -89,13 +89,16 @@ public class SignHelper {
* @param flowId 创建签署流程时返回的签署流程ID
* @param flowId 创建签署流程时返回的签署流程ID
* @throws DefineException
* @throws DefineException
* @author 宫清
* @author 宫清
* @param operatorId
* @param operatorId
* @return
* @date 2019年7月21日 下午5:38:42
* @date 2019年7月21日 下午5:38:42
*/
*/
public
static
void
revokeSignFlow
(
String
flowId
,
String
revokeReason
,
String
operatorId
)
throws
DefineException
{
public
static
JSONObject
revokeSignFlow
(
String
flowId
,
String
revokeReason
,
String
operatorId
)
throws
DefineException
{
String
param
=
SignParamUtil
.
revokeSignFlowParam
(
revokeReason
,
operatorId
);
String
param
=
SignParamUtil
.
revokeSignFlowParam
(
revokeReason
,
operatorId
);
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
PUT
,
ConfigConstant
.
revokeFlows_URL
(
flowId
),
param
);
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
PUT
,
ConfigConstant
.
revokeFlows_URL
(
flowId
),
param
);
JSONHelper
.
castDataJson
(
json
,
Object
.
class
);
// JSONHelper.castDataJson(json, Object.class);
return
json
;
}
}
/**
/**
...
@@ -176,7 +179,8 @@ public class SignHelper {
...
@@ -176,7 +179,8 @@ public class SignHelper {
*/
*/
public
static
JSONObject
downloadFlowDoc
(
String
flowId
)
throws
DefineException
{
public
static
JSONObject
downloadFlowDoc
(
String
flowId
)
throws
DefineException
{
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
GET
,
ConfigConstant
.
aboutDocument_URL
(
flowId
,
null
),
null
);
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
GET
,
ConfigConstant
.
aboutDocument_URL
(
flowId
,
null
),
null
);
return
JSONHelper
.
castDataJson
(
json
,
JSONObject
.
class
);
// return JSONHelper.castDataJson(json, JSONObject.class);
return
json
;
}
}
// ------------------------------------------------------------------------------------------------流程文档相关end-----------------------
// ------------------------------------------------------------------------------------------------流程文档相关end-----------------------
...
@@ -360,7 +364,7 @@ public class SignHelper {
...
@@ -360,7 +364,7 @@ public class SignHelper {
* @author 宫清
* @author 宫清
* @date 2019年7月21日 下午8:09:07
* @date 2019年7月21日 下午8:09:07
*/
*/
public
static
JSONObject
addSignerHandSignArea
(
String
flowId
,
List
<
Signfield
>
list
)
throws
DefineException
{
public
static
JSONObject
addSignerHandSignArea
(
String
flowId
,
List
<
Signfield
>
list
)
throws
DefineException
{
String
param
=
SignParamUtil
.
addSignerHandSignAreaParam
(
list
);
String
param
=
SignParamUtil
.
addSignerHandSignAreaParam
(
list
);
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
POST
,
ConfigConstant
.
addHandSignfieldsForPerson_URL
(
flowId
),
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
POST
,
ConfigConstant
.
addHandSignfieldsForPerson_URL
(
flowId
),
...
@@ -426,7 +430,7 @@ public class SignHelper {
...
@@ -426,7 +430,7 @@ public class SignHelper {
* @param flowId 创建签署流程时返回的签署流程ID
* @param flowId 创建签署流程时返回的签署流程ID
* @throws DefineException
* @throws DefineException
* @author 宫清
* @author 宫清
* @return
* @return
* @date 2019年7月21日 下午9:27:41
* @date 2019年7月21日 下午9:27:41
*/
*/
public
static
JSONObject
rushSign
(
String
flowId
,
String
accoundId
,
String
noticeTypes
,
String
rushsignAccountId
)
public
static
JSONObject
rushSign
(
String
flowId
,
String
accoundId
,
String
noticeTypes
,
String
rushsignAccountId
)
...
@@ -458,7 +462,8 @@ public class SignHelper {
...
@@ -458,7 +462,8 @@ public class SignHelper {
throws
DefineException
{
throws
DefineException
{
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
GET
,
JSONObject
json
=
HttpHelper
.
doCommHttp
(
RequestType
.
GET
,
ConfigConstant
.
Sign_URL
(
flowId
,
accountId
,
organizeId
,
urlType
),
null
);
ConfigConstant
.
Sign_URL
(
flowId
,
accountId
,
organizeId
,
urlType
),
null
);
return
JSONHelper
.
castDataJson
(
json
,
JSONObject
.
class
);
// return JSONHelper.castDataJson(json, JSONObject.class);
return
json
;
}
}
// ------------------------------------------------------------------------------------------------流程签署人相关end----------------------
// ------------------------------------------------------------------------------------------------流程签署人相关end----------------------
...
...
This diff is collapsed.
Click to expand it.
src/main/java/cn/timer/api/utils/CheckUtil.java
View file @
ebba5975
...
@@ -31,7 +31,7 @@ public class CheckUtil {
...
@@ -31,7 +31,7 @@ public class CheckUtil {
* @param obj 实体对象
* @param obj 实体对象
* @return 有则返回true
* @return 有则返回true
*/
*/
public
static
boolean
checkObjFieldIsNull
(
Object
obj
)
{
public
static
<
T
>
boolean
checkObjFieldIsNull
(
T
obj
)
{
boolean
flag
=
false
;
boolean
flag
=
false
;
for
(
Field
f
:
obj
.
getClass
().
getDeclaredFields
())
{
for
(
Field
f
:
obj
.
getClass
().
getDeclaredFields
())
{
f
.
setAccessible
(
true
);
f
.
setAccessible
(
true
);
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment