通讯录查询修改
parent
1a2f5489c0
commit
16962b6dc9
|
|
@ -9,10 +9,9 @@ import io.swagger.annotations.Api;
|
|||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* @author xusan
|
||||
|
|
@ -45,5 +44,20 @@ public class VersionsController {
|
|||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@ApiOperation(value = "删除")
|
||||
@GetMapping(value = "del/{id}")
|
||||
public ResultJson delete(@PathVariable("id") Integer id) {
|
||||
|
||||
|
||||
if (Objects.isNull(service.getById(id))) {
|
||||
|
||||
return ResultJson.error("当前数据不存在");
|
||||
|
||||
}
|
||||
|
||||
return ResultJson.ok(service.removeById(id));
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue