|
@@ -28,6 +28,7 @@ import org.springframework.stereotype.Service;
|
|
import java.io.BufferedReader;
|
|
import java.io.BufferedReader;
|
|
import java.io.IOException;
|
|
import java.io.IOException;
|
|
import java.io.InputStreamReader;
|
|
import java.io.InputStreamReader;
|
|
|
|
+import java.math.BigDecimal;
|
|
import java.net.URI;
|
|
import java.net.URI;
|
|
import java.util.HashMap;
|
|
import java.util.HashMap;
|
|
import java.util.List;
|
|
import java.util.List;
|
|
@@ -83,7 +84,7 @@ public class MarketingServiceImpl implements MarketingService{
|
|
* @return: java.util.Map<java.lang.String,java.lang.Object>
|
|
* @return: java.util.Map<java.lang.String,java.lang.Object>
|
|
*/
|
|
*/
|
|
@Override
|
|
@Override
|
|
- public Result updateBudget(CtopOauthToken token, String budgetMode, String budget) {
|
|
|
|
|
|
+ public Result updateBudget(CtopOauthToken token, String budgetMode, BigDecimal budget) {
|
|
JSONObject params = new JSONObject();
|
|
JSONObject params = new JSONObject();
|
|
//广告主ID
|
|
//广告主ID
|
|
params.put("advertiser_id", token.getAccountId());
|
|
params.put("advertiser_id", token.getAccountId());
|
|
@@ -102,7 +103,7 @@ public class MarketingServiceImpl implements MarketingService{
|
|
log.info("修改计划预算接口异常==》accountId:{},message:{}", token.getAccountId(), jsonObject.getString("message"));
|
|
log.info("修改计划预算接口异常==》accountId:{},message:{}", token.getAccountId(), jsonObject.getString("message"));
|
|
return Result.error(jsonObject.getString("message"));
|
|
return Result.error(jsonObject.getString("message"));
|
|
}
|
|
}
|
|
- return Result.successMsg("修改计划预算成功",null);
|
|
|
|
|
|
+ return Result.successMsg("修改账户预算成功",null);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
@@ -891,12 +892,12 @@ public class MarketingServiceImpl implements MarketingService{
|
|
String message = jsonObject.getString("message");
|
|
String message = jsonObject.getString("message");
|
|
if (null == code || !code.equals(0)) {
|
|
if (null == code || !code.equals(0)) {
|
|
log.info("获取行业类别信息接口异常==》accountId:{},message:{}", token.getAccountId(), message);
|
|
log.info("获取行业类别信息接口异常==》accountId:{},message:{}", token.getAccountId(), message);
|
|
- return Result.errorMsg(message);
|
|
|
|
|
|
+ return Result.error(message);
|
|
}
|
|
}
|
|
JSONArray data = jsonObject.getJSONObject("data").getJSONArray("list");
|
|
JSONArray data = jsonObject.getJSONObject("data").getJSONArray("list");
|
|
if (null == data || data.isEmpty()) {
|
|
if (null == data || data.isEmpty()) {
|
|
log.info("行业类别信息不存在==》accountId:{},message:{}", token.getAccountId(), message);
|
|
log.info("行业类别信息不存在==》accountId:{},message:{}", token.getAccountId(), message);
|
|
- return Result.errorMsg("行业类别信息不存在");
|
|
|
|
|
|
+ return Result.error("行业类别信息不存在");
|
|
}
|
|
}
|
|
|
|
|
|
return Result.successMsg("行业类别信息获取成功",data);
|
|
return Result.successMsg("行业类别信息获取成功",data);
|