Commit 8eab645d authored by tangwei's avatar tangwei

修改接口

parent 32b4d8cc
...@@ -21,7 +21,10 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper; ...@@ -21,7 +21,10 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import java.text.DecimalFormat; import java.text.DecimalFormat;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map;
/** /**
* @description: * @description:
...@@ -116,7 +119,7 @@ public class IdxBizFanWeightController extends BaseController { ...@@ -116,7 +119,7 @@ public class IdxBizFanWeightController extends BaseController {
@Transactional @Transactional
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
@PostMapping(value = "/update") @PostMapping(value = "/update")
@ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新", notes = "根据sequenceNbr更新") @ApiOperation(httpMethod = "PUT", value = "根据sequenceNbr更新", notes = "根据sequenceNbr更新")
public ResponseModel<IdxBizFanWeight> update(@RequestBody List<IdxBizFanWeight> list) { public ResponseModel<IdxBizFanWeight> update(@RequestBody List<IdxBizFanWeight> list) {
...@@ -159,14 +162,18 @@ public class IdxBizFanWeightController extends BaseController { ...@@ -159,14 +162,18 @@ public class IdxBizFanWeightController extends BaseController {
} }
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
@GetMapping (value = "/list") @GetMapping (value = "/list")
@ApiOperation(httpMethod = "get", value = "根据sequenceNbr更新", notes = "根据sequenceNbr更新") @ApiOperation(httpMethod = "get", value = "根据sequenceNbr更新", notes = "根据sequenceNbr更新")
public ResponseModel<List<IdxBizFanWeight>> list(@RequestBody List<String> list) { public ResponseModel<Map<String,Object>> list( String ids
) {
List<String> list= Arrays.asList(ids.split(","));
LambdaQueryWrapper<IdxBizFanWeight> qu=new LambdaQueryWrapper<>(); LambdaQueryWrapper<IdxBizFanWeight> qu=new LambdaQueryWrapper<>();
qu.in(!list.isEmpty(),IdxBizFanWeight::getSequenceNbr,list); qu.in(!list.isEmpty(),IdxBizFanWeight::getSequenceNbr,list);
List<IdxBizFanWeight> listdata = idxBizFanWeightMapper.selectList(qu); List<IdxBizFanWeight> listdata = idxBizFanWeightMapper.selectList(qu);
return ResponseHelper.buildResponse(listdata); Map<String,Object> data=new HashMap<>();
data.put("data",listdata);
return ResponseHelper.buildResponse(data);
} }
} }
...@@ -23,7 +23,10 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper; ...@@ -23,7 +23,10 @@ import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import java.text.DecimalFormat; import java.text.DecimalFormat;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map;
/** /**
* @description: * @description:
...@@ -167,14 +170,18 @@ public class IdxBizPvWeightController extends BaseController { ...@@ -167,14 +170,18 @@ public class IdxBizPvWeightController extends BaseController {
} }
return ResponseHelper.buildResponse(null); return ResponseHelper.buildResponse(null);
} }
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
@GetMapping (value = "/list") @GetMapping (value = "/list")
@ApiOperation(httpMethod = "get", value = "根据sequenceNbr更新", notes = "根据sequenceNbr更新") @ApiOperation(httpMethod = "get", value = "根据sequenceNbr更新", notes = "根据sequenceNbr更新")
public ResponseModel<List<IdxBizPvWeight>> list(@RequestBody List<String> list) { public ResponseModel<Map<String,Object>> list( String ids
) {
List<String> list= Arrays.asList(ids.split(","));
LambdaQueryWrapper<IdxBizPvWeight> qu=new LambdaQueryWrapper<>(); LambdaQueryWrapper<IdxBizPvWeight> qu=new LambdaQueryWrapper<>();
qu.in(!list.isEmpty(),IdxBizPvWeight::getSequenceNbr,list); qu.in(!list.isEmpty(),IdxBizPvWeight::getSequenceNbr,list);
List<IdxBizPvWeight> listdata = idxBizPvWeightMapper.selectList(qu); List<IdxBizPvWeight> listdata = idxBizPvWeightMapper.selectList(qu);
return ResponseHelper.buildResponse(listdata); Map<String,Object> data=new HashMap<>();
data.put("data",listdata);
return ResponseHelper.buildResponse(data);
} }
} }
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