Merge branch 'master-沃文档' into uat_code
This commit is contained in:
@ -70,7 +70,7 @@ public class WpsController {
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@ApiOperation("沃文档回调-保存文档")
|
@ApiOperation("沃文档回调-保存文档")
|
||||||
@GetMapping("/file/save")
|
@PostMapping("/file/save")
|
||||||
@OperationLogDetail(businessModule = EbtpLogBusinessModule.OTHER,operationType = EbtpLogType.SELECT,detail = "沃文档回调-保存文档")
|
@OperationLogDetail(businessModule = EbtpLogBusinessModule.OTHER,operationType = EbtpLogType.SELECT,detail = "沃文档回调-保存文档")
|
||||||
public Object saveFile(@RequestHeader("X-Weboffice-Token") String token,
|
public Object saveFile(@RequestHeader("X-Weboffice-Token") String token,
|
||||||
@RequestParam("_w_third_user_id") String userId,
|
@RequestParam("_w_third_user_id") String userId,
|
||||||
|
@ -10,6 +10,7 @@ import com.chinaunicom.ebtp.mall.cloud.attachment.sdk.model.AttachmentEntity;
|
|||||||
import com.chinaunicom.ebtp.mall.cloud.attachment.sdk.model.UploadObject;
|
import com.chinaunicom.ebtp.mall.cloud.attachment.sdk.model.UploadObject;
|
||||||
import com.chinaunicom.mall.ebtp.common.base.service.IBaseCacheUserService;
|
import com.chinaunicom.mall.ebtp.common.base.service.IBaseCacheUserService;
|
||||||
import com.chinaunicom.mall.ebtp.common.exception.common.CommonExceptionEnum;
|
import com.chinaunicom.mall.ebtp.common.exception.common.CommonExceptionEnum;
|
||||||
|
import com.chinaunicom.mall.ebtp.common.log.OperationLogDetail;
|
||||||
import com.chinaunicom.mall.ebtp.common.log.enums.EbtpLogBusinessModule;
|
import com.chinaunicom.mall.ebtp.common.log.enums.EbtpLogBusinessModule;
|
||||||
import com.chinaunicom.mall.ebtp.common.log.enums.EbtpLogType;
|
import com.chinaunicom.mall.ebtp.common.log.enums.EbtpLogType;
|
||||||
import com.chinaunicom.mall.ebtp.common.log.service.OperationLogService;
|
import com.chinaunicom.mall.ebtp.common.log.service.OperationLogService;
|
||||||
@ -232,6 +233,7 @@ public class WpsServiceImpl implements WpsService {
|
|||||||
* ContentJson 没有就传空字符串
|
* ContentJson 没有就传空字符串
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
|
@OperationLogDetail(businessModule = EbtpLogBusinessModule.OTHER,operationType = EbtpLogType.SELECT,detail = "沃文档-获取应用权限")
|
||||||
public String getWpsAppToken(){
|
public String getWpsAppToken(){
|
||||||
if(redisTemplate.opsForValue().get("wpsAppToken:"+app_id)!=null){
|
if(redisTemplate.opsForValue().get("wpsAppToken:"+app_id)!=null){
|
||||||
return String.valueOf(redisTemplate.opsForValue().get("wpsAppToken:"+app_id));
|
return String.valueOf(redisTemplate.opsForValue().get("wpsAppToken:"+app_id));
|
||||||
@ -255,6 +257,7 @@ public class WpsServiceImpl implements WpsService {
|
|||||||
* @param bean
|
* @param bean
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
|
@OperationLogDetail(businessModule = EbtpLogBusinessModule.OTHER,operationType = EbtpLogType.SELECT,detail = "沃文档-调用天擎接口")
|
||||||
public Map<String, Object> callUniWpsInterfaceJson(CrypBean bean) {
|
public Map<String, Object> callUniWpsInterfaceJson(CrypBean bean) {
|
||||||
log.info("沃文档-天擎接口------callUniInterface:---入参-----" + JSON.toJSONString(bean));
|
log.info("沃文档-天擎接口------callUniInterface:---入参-----" + JSON.toJSONString(bean));
|
||||||
String url= "";
|
String url= "";
|
||||||
@ -354,6 +357,7 @@ public class WpsServiceImpl implements WpsService {
|
|||||||
* @param data
|
* @param data
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
|
@OperationLogDetail(businessModule = EbtpLogBusinessModule.OTHER,operationType = EbtpLogType.SELECT,detail = "沃文档-uniBssWpsHttpPost")
|
||||||
public String uniBssWpsHttpPost(String path, String data,String nlptDate,String nlptAuth,String nlptContentMd5,String contentType) {
|
public String uniBssWpsHttpPost(String path, String data,String nlptDate,String nlptAuth,String nlptContentMd5,String contentType) {
|
||||||
String str = "";
|
String str = "";
|
||||||
|
|
||||||
@ -374,6 +378,7 @@ public class WpsServiceImpl implements WpsService {
|
|||||||
conn.setDoOutput(true);
|
conn.setDoOutput(true);
|
||||||
conn.setDoInput(true);
|
conn.setDoInput(true);
|
||||||
conn.setRequestMethod("POST");
|
conn.setRequestMethod("POST");
|
||||||
|
|
||||||
out = new PrintWriter(conn.getOutputStream());
|
out = new PrintWriter(conn.getOutputStream());
|
||||||
out.print(data);
|
out.print(data);
|
||||||
out.flush();
|
out.flush();
|
||||||
@ -388,6 +393,7 @@ public class WpsServiceImpl implements WpsService {
|
|||||||
|
|
||||||
is.close();
|
is.close();
|
||||||
conn.disconnect();
|
conn.disconnect();
|
||||||
|
operationLogService.addOperationLog("沃文档天擎接口调用信息,HttpURLConnection={}"+JSONObject.toJSONString(conn)+",参数{}"+data+",返回信息{}"+str,true, EbtpLogBusinessModule.OTHER, EbtpLogType.INSERT);
|
||||||
} catch (Exception var9) {
|
} catch (Exception var9) {
|
||||||
var9.printStackTrace();
|
var9.printStackTrace();
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user