fix(测试跟踪): 禅道GET方式附件同步问题
--bug=1018812 --user=宋昌昌 【测试跟踪】Zentao平台创建缺陷,上传附件未同步上传到缺陷平台里 https://www.tapd.cn/55049933/s/1276291
This commit is contained in:
parent
833adc13ce
commit
a8c722e56a
|
@ -223,7 +223,7 @@ public abstract class ZentaoClient extends BaseClient {
|
|||
|
||||
try {
|
||||
restTemplate.exchange(requestUrl.getFileUpload(), HttpMethod.POST, requestEntity,
|
||||
String.class, objectType, objectId, sessionId);
|
||||
String.class, objectId, sessionId);
|
||||
} catch (Exception e) {
|
||||
LogUtil.info("upload zentao attachment error");
|
||||
}
|
||||
|
|
|
@ -16,7 +16,7 @@ public class ZentaoGetClient extends ZentaoClient {
|
|||
private static final String STORY_GET="&module=story&methodName=getProductStories¶ms=productID={key}&t=json&zentaosid=";
|
||||
private static final String USER_GET="&module=user&methodName=getList&t=json&zentaosid=";
|
||||
private static final String BUILDS_GET="&module=build&methodName=getProductBuildPairs&productID={0}&zentaosid={1}";
|
||||
private static final String FILE_UPLOAD="&module=file&methodName=saveUpload¶ms=objectType=bug&zentaosid={1}";
|
||||
private static final String FILE_UPLOAD="&module=file&methodName=saveUpload¶ms=objectType=bug,objectID={1}&zentaosid={2}";
|
||||
private static final String FILE_DELETE="/?m=file&f=delete&t=json&fileID={1}&confirm=yes&zentaosid={2}";
|
||||
private static final String FILE_DOWNLOAD="/?m=file&f=download&t=json&fileID={1}&mouse=click&zentaosid={2}";
|
||||
private static final String CREATE_META_DATA="?m=bug&f=create&productID={0}&t=json&zentaosid={1}";
|
||||
|
|
|
@ -16,7 +16,7 @@ public class ZentaoPathInfoClient extends ZentaoClient {
|
|||
private static final String USER_GET = "/api-getModel-user-getList?zentaosid=";
|
||||
private static final String BUILDS_GET = "/api-getModel-build-getProductBuildPairs-productID={0}?zentaosid={1}";
|
||||
private static final String CREATE_META_DATA="/bug-create-{0}.json?zentaosid={1}";
|
||||
private static final String FILE_UPLOAD = "/api-getModel-file-saveUpload-objectType=bug?zentaosid={1}";
|
||||
private static final String FILE_UPLOAD = "/api-getModel-file-saveUpload-objectType=bug,objectID={1}?zentaosid={2}";
|
||||
private static final String FILE_DELETE = "/file-delete-{1}-.yes.json?zentaosid={2}";
|
||||
private static final String FILE_DOWNLOAD="/file-download-{1}-.click.json?zentaosid={2}";
|
||||
private static final String REPLACE_IMG_URL = "<img src=\"%s/file-read-$1\"/>";
|
||||
|
|
|
@ -445,7 +445,7 @@ public class ZentaoPlatform extends AbstractIssuePlatform {
|
|||
try {
|
||||
String fileUpload = zentaoClient.requestUrl.getFileUpload();
|
||||
ResponseEntity<String> responseEntity = restTemplate.exchange(fileUpload, HttpMethod.POST, requestEntity,
|
||||
String.class, session);
|
||||
String.class, null, session);
|
||||
String body = responseEntity.getBody();
|
||||
Map obj = JSON.parseMap(body);
|
||||
Map data = (Map) JSON.parseObject(obj.get("data").toString());
|
||||
|
|
Loading…
Reference in New Issue