记得上下班打卡 | git大法好,push需谨慎

Commit 5f289cdf authored by jiangxiulong's avatar jiangxiulong

null

parent e36629a4
...@@ -5,6 +5,7 @@ import com.liquidnet.service.base.ResponseDto; ...@@ -5,6 +5,7 @@ import com.liquidnet.service.base.ResponseDto;
import com.liquidnet.service.sweet.param.SweetCityVoteParam; import com.liquidnet.service.sweet.param.SweetCityVoteParam;
import com.liquidnet.service.sweet.service.ISweetCityVoteService; import com.liquidnet.service.sweet.service.ISweetCityVoteService;
import com.liquidnet.service.sweet.vo.SweetCItyVoteStatVo; import com.liquidnet.service.sweet.vo.SweetCItyVoteStatVo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
...@@ -20,6 +21,7 @@ import java.util.List; ...@@ -20,6 +21,7 @@ import java.util.List;
* @author jiangxiulong * @author jiangxiulong
* @since 2021-09-15 * @since 2021-09-15
*/ */
@Api(tags = "城市投票")
@RestController @RestController
@RequestMapping("/sweetCityVote") @RequestMapping("/sweetCityVote")
public class SweetCityVoteController { public class SweetCityVoteController {
......
...@@ -493,6 +493,11 @@ public class RedisDataUtils { ...@@ -493,6 +493,11 @@ public class RedisDataUtils {
} }
public Integer getSweetCityVote(String cityCode) { public Integer getSweetCityVote(String cityCode) {
String redisKey = SweetConstant.REDIS_KEY_SWEET_CITY_VOTE_CITY_CODE.concat(cityCode); String redisKey = SweetConstant.REDIS_KEY_SWEET_CITY_VOTE_CITY_CODE.concat(cityCode);
return (Integer) redisUtil.get(redisKey); Object obj = redisUtil.get(redisKey);
if (null == obj) {
return 0;
} else {
return (Integer) obj;
}
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment