|
@@ -0,0 +1,76 @@
|
|
|
+package com.imed.costaccount.web;
|
|
|
+
|
|
|
+import com.imed.costaccount.common.util.PageUtils;
|
|
|
+import com.imed.costaccount.common.util.Result;
|
|
|
+import com.imed.costaccount.common.util.UserContext;
|
|
|
+import com.imed.costaccount.model.CostOtherPaymentsData;
|
|
|
+import com.imed.costaccount.service.CostOtherPaymentsDataService;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
+
|
|
|
+import java.util.Arrays;
|
|
|
+
|
|
|
+
|
|
|
+/**
|
|
|
+ * 全院其他收支数据
|
|
|
+ *
|
|
|
+ * @author KCYG
|
|
|
+ * @date 2021-08-17 08:53:35
|
|
|
+ */
|
|
|
+@RestController
|
|
|
+@RequestMapping("/costAccount/costotherpaymentsdata")
|
|
|
+public class CostOtherPaymentsDataController {
|
|
|
+ @Autowired
|
|
|
+ private CostOtherPaymentsDataService costOtherPaymentsDataService;
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 分页查询列表
|
|
|
+ * 查询的是
|
|
|
+ */
|
|
|
+ @RequestMapping("/list")
|
|
|
+ public Result list(@RequestParam(value = "current", defaultValue = "1") Integer current,
|
|
|
+ @RequestParam(value = "pageSize", defaultValue = "10") Integer pageSize,
|
|
|
+ @RequestParam(value = "dateTime",required = false) String datetime){
|
|
|
+ Long hospId = UserContext.getHospId();
|
|
|
+ PageUtils pageUtils = costOtherPaymentsDataService.queryList(current,pageSize,datetime,hospId);
|
|
|
+ return Result.ok(pageSize);
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 信息
|
|
|
+ */
|
|
|
+ @RequestMapping("/info/{id}")
|
|
|
+ public Result info(@PathVariable("id") Long id){
|
|
|
+ CostOtherPaymentsData costOtherPaymentsData = costOtherPaymentsDataService.getById(id);
|
|
|
+ return Result.ok(costOtherPaymentsData);
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 保存
|
|
|
+ */
|
|
|
+ @RequestMapping("/save")
|
|
|
+ public Result save(@RequestBody CostOtherPaymentsData costOtherPaymentsData){
|
|
|
+ costOtherPaymentsDataService.save(costOtherPaymentsData);
|
|
|
+ return Result.ok();
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 修改
|
|
|
+ */
|
|
|
+ @RequestMapping("/update")
|
|
|
+ public Result update(@RequestBody CostOtherPaymentsData costOtherPaymentsData){
|
|
|
+ costOtherPaymentsDataService.updateById(costOtherPaymentsData);
|
|
|
+ return Result.ok();
|
|
|
+ }
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 删除
|
|
|
+ */
|
|
|
+ @RequestMapping("/delete")
|
|
|
+ public Result delete(@RequestBody Long[] ids){
|
|
|
+ costOtherPaymentsDataService.removeByIds(Arrays.asList(ids));
|
|
|
+ return Result.ok();
|
|
|
+ }
|
|
|
+
|
|
|
+}
|