Commit a5e90591 authored by 董天德's avatar 董天德

Merge remote-tracking branch 'origin/dev_20230128_mq'

parents 37c6d6f1 3887f5ba
......@@ -3,18 +3,23 @@ package com.hungraim.ltc.account.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ltc.account.service.AccountService;
import com.hungraim.ltc.pojo.entity.account.ChAssessDetailAccounts;
import com.hungraim.ltc.pojo.entity.account.ChDisabAccounts;
import com.hungraim.ltc.pojo.entity.account.ChDisabDetailAccounts;
import com.hungraim.ltc.pojo.vo.account.*;
import com.hungraim.ltc.util.FileUtils;
import com.hungraim.ltc.util.Result;
import com.hungraim.ltc.util.ResultCode;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang.StringUtils;
import org.apache.poi.ss.usermodel.Workbook;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.servlet.http.HttpServletResponse;
import java.text.ParseException;
import java.util.Date;
import java.util.List;
......@@ -81,7 +86,7 @@ public class AccountController {
/**
* 费用结算
*
* @return 返回机构结当月算详情
* @return 返回机构结当月算详情
*/
@GetMapping("/expenseSettlement")
public Result<ExpenseVo> expenseSettlement(ExpenseSettlementReq req) throws ParseException {
......@@ -96,4 +101,125 @@ public class AccountController {
}
return Result.success(accountService.expenseSettlement(req));
}
// todo 后续改成每月定时
@GetMapping("/organAccount")
public void organAccount(){
accountService.organAccount();
}
// todo 后续改成每月定时
@GetMapping("/assessAccount")
public void getAssessAccount(){
accountService.getAssessAccount();
}
/**
* 查询机构结算列表
*
* @param srvOrganListReq 请求参数对象
* @return 返回
*/
@GetMapping("/searchSrvOrganAccountList")
public Result<Page<SrvOrganAccountListResp>> searchSrvOrganAccountList(SrvOrganListReq srvOrganListReq) {
return Result.success(accountService.searchSrvOrganAccountList(srvOrganListReq));
}
/**
* 机构结算明细导出
*
*/
@GetMapping("/srvOrganAccountExport")
public void srvOrganAccountExport(String accountsId,HttpServletResponse response){
Workbook workbook = accountService.srvOrganAccountExport(accountsId);
// 命名表格
String fileName = "srvOrganAccount.xlsx";
FileUtils.exportResponse(workbook,fileName,response);
}
/**
* 查询评估结算列表
*
* @param srvOrganListReq 请求参数对象
* @return 返回
*/
@GetMapping("/searchAssessAccountsList")
public Result<Page<AssessAccountsListResp>> searchAssessAccountsList(SrvOrganListReq srvOrganListReq) {
return Result.success(accountService.searchAssessAccountsList(srvOrganListReq));
}
/**
* 评估结算导出明细
*
*/
@GetMapping("/assessAccountExport")
public void assessAccountExport(String assessAccountsId,HttpServletResponse response){
Workbook workbook = accountService.assessAccountExport(assessAccountsId);
// 命名表格
String fileName = "assessAccount.xlsx";
FileUtils.exportResponse(workbook,fileName,response);
}
/**
* 评估人员结算列表明细
*
* @param id 结算id
* @return 返回雷彪
*/
@GetMapping("/QueryDisabOrganAccountsDetail")
public Result<List<ChAssessDetailAccounts>> QueryDisabOrganAccountsDetail(int id) {
List<ChAssessDetailAccounts> chAssessDetailAccounts = accountService.queryDisabOrganAccountsDetail(id);
return Result.success(chAssessDetailAccounts);
}
/**
* 查询机构结算信息列表明细
*
* @param id 结算id
* @return 返回雷彪
*/
@GetMapping("/QuerySearchAssessAccounts")
public Result<List<ChDisabDetailAccounts>> QuerySearchAssessAccounts(int id) {
List<ChDisabDetailAccounts> chAssessDetailAccounts = accountService.querySearchAssessAccounts(id);
return Result.success(chAssessDetailAccounts);
}
/**
* 机构结算管理提交复核
*
* @param id 结算id
* @return 返回雷彪
*/
@PostMapping("/updatechDisabAccounts")
public Result updateChDisabAccounts(int id) {
int bl = accountService.updateChDisabAccounts(id);
if(bl>0){
return Result.success();
}else{
return Result.failed();
}
}
/**
* 评估人员结算提交复核
*
* @param id 结算id
* @return 返回雷彪
*/
@PostMapping("/updateChAssessAccounts")
public Result updateChAssessAccounts(int id) {
int bl = accountService.updateChAssessAccounts(id);
if(bl>0){
return Result.success();
}else{
return Result.failed();
}
}
}
package com.hungraim.ltc.account.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.account.ChAssessDetailAccounts;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
@Mapper
@Repository
public interface ChAssessAccountsDetailMapper extends BaseMapper<ChAssessDetailAccounts> {
}
\ No newline at end of file
package com.hungraim.ltc.account.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ltc.pojo.entity.account.ChAssessAccounts;
import com.hungraim.ltc.pojo.vo.account.AssessAccountsExportResp;
import com.hungraim.ltc.pojo.vo.account.AssessAccountsListResp;
import com.hungraim.ltc.pojo.vo.account.AssessAccountsVO;
import com.hungraim.ltc.pojo.vo.account.SrvOrganListReq;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
import java.util.List;
@Mapper
@Repository
public interface ChAssessAccountsMapper extends BaseMapper<ChAssessAccounts> {
List<AssessAccountsVO> getAssessAccountsList();
Page<AssessAccountsListResp> searchAssessAccountList(Page page, List<Long> organIds, SrvOrganListReq req);
List<AssessAccountsExportResp> assessAccountDetailExport(String assessAccountsId);
}
\ No newline at end of file
package com.hungraim.ltc.account.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.account.ChAssessDetailAccounts;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
/**
* @author mq
*/
@Mapper
@Repository
public interface ChAssessDetailAccountsMapper extends BaseMapper<ChAssessDetailAccounts> {
}
package com.hungraim.ltc.account.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ltc.pojo.entity.account.ChDisabAccounts;
import com.hungraim.ltc.pojo.entity.account.ChDisabDetailAccounts;
import com.hungraim.ltc.pojo.vo.account.AccountOperVo;
import com.hungraim.ltc.pojo.vo.account.SrvOrganListReq;
import com.hungraim.ltc.pojo.vo.account.SrvOrganListResp;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;
import java.util.List;
@Mapper
@Repository
public interface ChDisabAccountsDetailMapper extends BaseMapper<ChDisabDetailAccounts> {
}
\ No newline at end of file
package com.hungraim.ltc.account.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.account.ChDisabDetailAccounts;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
/**
* @author mq
*/
@Mapper
@Repository
public interface ChDisabDetailAccountsMapper extends BaseMapper<ChDisabDetailAccounts> {
}
package com.hungraim.ltc.account.dao;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ltc.pojo.vo.account.*;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
import java.util.List;
@Repository
@Mapper
public interface ChOrganAccountsMapper {
List<OrganAccountsVO> getOrganAccountsList(String lastMonth);
Page<SrvOrganAccountListResp> searchSrvOrganAccountList(Page page, List<Long> organIds, SrvOrganListReq req);
List<AccountExportDetailListResp> searchSrvOrganAccountDetailExport(String accountsId);
}
......@@ -2,10 +2,14 @@ package com.hungraim.ltc.account.service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hungraim.ltc.pojo.entity.account.ChAssessDetailAccounts;
import com.hungraim.ltc.pojo.entity.account.ChDisabAccounts;
import com.hungraim.ltc.pojo.entity.account.ChDisabDetailAccounts;
import com.hungraim.ltc.pojo.vo.account.*;
import org.apache.poi.ss.usermodel.Workbook;
import java.text.ParseException;
import java.util.List;
public interface AccountService extends IService<ChDisabAccounts> {
......@@ -16,7 +20,32 @@ public interface AccountService extends IService<ChDisabAccounts> {
Page<SrvOrganListResp> searchSrvOrganList(SrvOrganListReq srvOrganListReq);
Page<SrvOrganAccountListResp> searchSrvOrganAccountList(SrvOrganListReq srvOrganListReq);
AccountOperVo getSrvOrganDetail(Long accountsId);
ExpenseVo expenseSettlement(ExpenseSettlementReq req) throws ParseException;
void organAccount();
void getAssessAccount();
Workbook srvOrganAccountExport(String accountsId);
Page<AssessAccountsListResp> searchAssessAccountsList(SrvOrganListReq srvOrganListReq);
Workbook assessAccountExport(String assessAccountsId);
/**
* 列表明细
* @param id
* @return
*/
List<ChAssessDetailAccounts> queryDisabOrganAccountsDetail(int id);
List<ChDisabDetailAccounts> querySearchAssessAccounts(int id);
int updateChDisabAccounts(int id);
int updateChAssessAccounts(int id);
}
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hungraim.ltc.account.dao.ChAssessAccountsMapper">
<!--查询评估信息-->
<select id="getAssessAccountsList" resultType="com.hungraim.ltc.pojo.vo.account.AssessAccountsVO">
select
DISTINCT task.task_id taskId,
fndOrgan.ORGAN_NAME organName,
task.ORGAN_ID aprOrganId,
(select DISTRICT_NAME from CH_FND_DISTRICT dis where task.DISTRICT_PROVINCIAL = dis.DISTRICT_CODE) districtProvincial,
(select DISTRICT_NAME from CH_FND_DISTRICT dis where task.DISTRICT_CITY = dis.DISTRICT_CODE) districtCity,
(select DISTRICT_NAME from CH_FND_DISTRICT dis where task.DISTRICT_AREA = dis.DISTRICT_CODE) districtArea,
disable.DISAB_INFO_ID disabInfoId,
disable.real_name realName,
disable.certi_code certiCode,
disable.BIRTHDAY birthday,
disable.tel tel,
disable.gender gender,
(SELECT dis.DISTRICT_NAME FROM CH_FND_DISTRICT dis WHERE disable.DISTRICT_PROVINCIAL = dis.DISTRICT_CODE) disDistrictProvincial,
(SELECT dis.DISTRICT_NAME FROM CH_FND_DISTRICT dis WHERE disable.district_city = dis.DISTRICT_CODE) disDistrictCity,
(SELECT dis.DISTRICT_NAME FROM CH_FND_DISTRICT dis WHERE disable.district_area = dis.DISTRICT_CODE) disDistrictArea,
disable.end_time endTime,
task.finish_time finishTime,
emp.APREMP_TYPE_NAME_F aprempTypeName
from CH_APR_TASK task
left join ch_apr_organ aprOrgan on task.apr_organ_id = aprOrgan.apr_organ_id
left join ch_disable_info disable on task.disable_info_id = disable.disab_info_id
left join ch_apr_emp emp on task.apr_emp_id = emp.emp_id and emp.IS_LOCK = 0
left join ch_apr_report report on report.TASK_ID = task.TASK_ID
left join CH_FND_ORGAN fndOrgan on task.ORGAN_ID = fndOrgan.ORGAN_ID
where task.task_status = 2 and emp.APREMP_TYPE_NAME_F is not null
</select>
<select id="searchAssessAccountList" resultType="com.hungraim.ltc.pojo.vo.account.AssessAccountsListResp">
SELECT
t1.ASSESS_ACCOUNTS_ID,
t3.ORGAN_ID,
t3.ORGAN_NAME,
t2.SRV_ORGAN_ID,
t2.SRV_ORGAN_NAME,
t1.ACCOUNTS_TIME,
t1.ACCOUNTS_STATUS,
t1.ASSESS_ALL_COST,
t1.ASSESS_START_TIME,
t1.ASSESS_END_TIME
FROM
CH_ASSESS_ACCOUNTS t1
LEFT JOIN CH_SRV_ORGAN t2 ON t1.APR_ORGAN_ID = t2.SRV_ORGAN_ID
LEFT JOIN CH_FND_ORGAN t3 ON t2.ORGAN_ID = t3.ORGAN_ID
<where>
<if test='organIds != null and organIds.size()>0'>
t3.ORGAN_ID IN
<foreach collection="organIds" open="(" close=")" item="organId" separator=",">
#{organId}
</foreach>
</if>
<if test='req.srvOrganId != null'>
AND t2.SRV_ORGAN_ID = #{req.srvOrganId}
</if>
<if test='req.accountsTime != null'>
AND t1.ACCOUNTS_TIME = #{req.accountsTime}
</if>
</where>
</select>
<select id="searchAssessAccountExportList" resultType="com.hungraim.ltc.pojo.vo.account.AssessAccountsExportResp">
SELECT
t1.ASSESS_ACCOUNTS_ID,
t3.ORGAN_ID,
t3.ORGAN_NAME,
t2.SRV_ORGAN_ID,
t2.SRV_ORGAN_NAME,
to_char(t1.ACCOUNTS_TIME,'yyyy-MM') accountsTime,
DECODE(t1.ACCOUNTS_STATUS, '0','待提交','1', '待审核','2', '已审核','3', '已失效') accountsStatus,
t1.ASSESS_ALL_COST,
to_char(t1.ASSESS_START_TIME,'yyyy-MM-dd') assessStartTime,
to_char(t1.ASSESS_END_TIME,'yyyy-MM-dd') assessEndTime
FROM
CH_ASSESS_ACCOUNTS t1
LEFT JOIN CH_SRV_ORGAN t2 ON t1.APR_ORGAN_ID = t2.SRV_ORGAN_ID
LEFT JOIN CH_FND_ORGAN t3 ON t2.ORGAN_ID = t3.ORGAN_ID
<where>
<if test='organIds != null and organIds.size()>0'>
t3.ORGAN_ID IN
<foreach collection="organIds" open="(" close=")" item="organId" separator=",">
#{organId}
</foreach>
</if>
<if test='req.srvOrganId != null'>
AND t2.SRV_ORGAN_ID = #{req.srvOrganId}
</if>
<if test='req.accountsTime != null'>
AND t1.ACCOUNTS_TIME = #{req.accountsTime}
</if>
</where>
</select>
<select id="assessAccountDetailExport" resultType="com.hungraim.ltc.pojo.vo.account.AssessAccountsExportResp">
SELECT
t3.SRV_ORGAN_NAME,
to_char(t1.ACCOUNTS_TIME,'yyyy-MM') accountsTime,
t1.ASSESS_ALL_COST assessCost,
to_char(t1.ASSESS_START_TIME,'yyyy-MM-dd') assessStartTime,
to_char(t1.ASSESS_END_TIME,'yyyy-MM-dd') assessEndTime
FROM
CH_ASSESS_ACCOUNTS_DETAIL t1
left join ch_disable_info t2 on t1.disab_info_id = t2.disab_info_id
LEFT JOIN CH_SRV_ORGAN t3 ON t1.SRV_ORGAN_ID = t3.SRV_ORGAN_ID
where t1.ASSESS_ACCOUNTS_ID = #{assessAccountsId}
</select>
</mapper>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hungraim.ltc.account.dao.ChOrganAccountsMapper">
<!--查询机构失能人员信息-->
<select id="getOrganAccountsList" resultType="com.hungraim.ltc.pojo.vo.account.OrganAccountsVO">
select
--失能人员姓名
disable.real_name realName,
disable.DISAB_INFO_ID disabInfoId,
--身份证号
disable.CERTI_CODE certiCode,
--所在省市
disable.district_provincial districtProvincial,
disable.district_city districtCity,
disable.DISTRICT_AREA districtArea,
mode1.MODE_ID modeId,
--服务方式
mode1.mode_name srvModeName,
--护理机构名称
organ.srv_organ_id srvOrganId,
--护理机构名称
organ.srv_organ_name srvOrganName,
--护理服务人员
emp.emp_name empName,
--任务时间
detail.SRV_DATE srvDate,
--机构等级
organ.LEVEL_CODE levelCode,
--失能等级
level1.DISABLE_LEVEL_NAME disableLevelName
from ch_srv_task_detail detail--服务计划
left join ch_srv_task task on task.srv_task_id = detail.srv_task_id--服务计划详情
left join ch_disable_info disable on task.disab_info_id = disable.disab_info_id--失能人员
left join ch_apr_task aprtask on disable.last_task_id = aprtask.task_id--评定任务
left join ch_apr_report report on aprtask.task_id = report.task_id--评定报告
left join ch_srv_program program on task.program_id = program.program_id--服务方案
left join ch_srv_organ organ on program.srv_organ_id = organ.srv_organ_id--服务机构
left join ch_cfg_srv_mode mode1 on program.srv_mode_id = mode1.mode_id--服务方式
left join ch_srv_organ_emp emp on task.srv_emp_id = emp.emp_id--护理人员
--失能等级
left join ch_cfg_srv_disable_level level1 on report.disable_level_id = level1.disable_level_id
where detail.STATUS=4 and organ.LEVEL_CODE is not null
</select>
<!--查询评估信息-->
<select id="getAssessAccountsList" resultType="com.hungraim.ltc.pojo.vo.account.AssessAccountsVO">
select
DISTINCT task.task_id taskId,
fndOrgan.ORGAN_NAME organName,
task.ORGAN_ID aprOrganId,
(select DISTRICT_NAME from CH_FND_DISTRICT dis where task.DISTRICT_PROVINCIAL = dis.DISTRICT_CODE) districtProvincial,
(select DISTRICT_NAME from CH_FND_DISTRICT dis where task.DISTRICT_CITY = dis.DISTRICT_CODE) districtCity,
(select DISTRICT_NAME from CH_FND_DISTRICT dis where task.DISTRICT_AREA = dis.DISTRICT_CODE) districtArea,
disable.real_name realName,
disable.certi_code certiCode,
disable.BIRTHDAY birthday,
disable.tel tel,
disable.gender gender,
(SELECT dis.DISTRICT_NAME FROM CH_FND_DISTRICT dis WHERE disable.DISTRICT_PROVINCIAL = dis.DISTRICT_CODE) disDistrictProvincial,
(SELECT dis.DISTRICT_NAME FROM CH_FND_DISTRICT dis WHERE disable.district_city = dis.DISTRICT_CODE) disDistrictCity,
(SELECT dis.DISTRICT_NAME FROM CH_FND_DISTRICT dis WHERE disable.district_area = dis.DISTRICT_CODE) disDistrictArea,
disable.end_time endTime,
task.finish_time finishTime,
emp.APREMP_TYPE_NAME_F aprempTypeName
from CH_APR_TASK task
left join ch_apr_organ aprOrgan on task.apr_organ_id = aprOrgan.apr_organ_id
left join ch_disable_info disable on task.disable_info_id = disable.disab_info_id
left join ch_apr_emp emp on task.apr_emp_id = emp.emp_id and emp.IS_LOCK = 0
left join ch_apr_report report on report.TASK_ID = task.TASK_ID
left join CH_FND_ORGAN fndOrgan on task.ORGAN_ID = fndOrgan.ORGAN_ID
where task.task_status = 2 and emp.APREMP_TYPE_NAME_F is not null
</select>
<select id="searchSrvOrganAccountList" resultType="com.hungraim.ltc.pojo.vo.account.SrvOrganAccountListResp">
SELECT
t1.ACCOUNTS_ID,
t3.ORGAN_ID,
t3.ORGAN_NAME,
t2.SRV_ORGAN_ID,
t2.SRV_ORGAN_NAME,
t1.ACCOUNTS_TIME,
t1.ACCOUNTS_STATUS,
t1.ALL_COST,
t1.OVERALL_COST,
t1.PERSONAL_COST,
t1.SVR_START_TIME,
t1.SVR_END_TIME
FROM
CH_DISAB_ACCOUNTS t1
LEFT JOIN CH_SRV_ORGAN t2 ON t1.SRV_ORGAN_ID = t2.SRV_ORGAN_ID
LEFT JOIN CH_FND_ORGAN t3 ON t2.ORGAN_ID = t3.ORGAN_ID
<where>
<if test='organIds != null and organIds.size()>0'>
t3.ORGAN_ID IN
<foreach collection="organIds" open="(" close=")" item="organId" separator=",">
#{organId}
</foreach>
</if>
<if test='req.srvOrganId != null'>
AND t2.SRV_ORGAN_ID = #{req.srvOrganId}
</if>
<if test='req.accountsTime != null'>
AND t1.ACCOUNTS_TIME = #{req.accountsTime}
</if>
</where>
</select>
<select id="searchSrvOrganAccountDetailExport" resultType="com.hungraim.ltc.pojo.vo.account.AccountExportDetailListResp">
select
t3.SRV_ORGAN_NAME srvOrganName,
to_char(t1.ACCOUNTS_TIME,'yyyy-MM') accountsTime,
t1.ACCOUNTS_ALL_COST accountsAllCost,
t1.ACCOUNTS_OVERALL_COST accountsOverallCost,
t1.ACCOUNTS_PERSONAL_COST accountsPersonalCost,
to_char(t1.ACCOUNTS_START_TIME,'yyyy-MM-dd') accountsStartTime,
to_char(t1.ACCOUNTS_END_TIME,'yyyy-MM-dd') accountsEndTime
from CH_DISAB_ACCOUNTS_DETAIL t1
left join ch_disable_info t2 on t1.disab_info_id = t2.disab_info_id
LEFT JOIN CH_SRV_ORGAN t3 ON t1.SRV_ORGAN_ID = t3.SRV_ORGAN_ID
where t1.ACCOUNTS_ID = #{accountsId}
</select>
</mapper>
package com.hungraim.ltc.pojo.entity.account;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.util.Date;
/**
* CH_DISAB_ACCOUNTS
* @author zwl
*/
@Data
@TableName("CH_ASSESS_ACCOUNTS")
@KeySequence("SEQ_CH_ASSESS_ACCOUNTS")
public class ChAssessAccounts implements Serializable {
/**
* 评估结算id
*/
@TableId(value = "ASSESS_ACCOUNTS_ID", type = IdType.INPUT)
private Long assessAccountsId;
/**
* 机构id
*/
private Long aprOrganId;
/**
* 创建时间
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
private Date creationTime;
/**
* 结算月份
*/
@DateTimeFormat(pattern = "yyyy-MM")
@JsonFormat(pattern = "yyyy-MM",timezone = "GMT+8")
private Date accountsTime;
/**
* 是否结算(0未结算,1已结算)
*/
private Short chooseSettle;
/**
* 状态(0-待提交;1-待审核;2-已审核;3-已失效;)
*/
private Short accountsStatus;
/**
* 审核人姓名
*/
private String checkName;
/**
* 审核备注
*/
private String checkRemark;
/**
* 省
*/
private String districtProvincial;
/**
* 市
*/
private String districtCity;
/**
* 区
*/
private String districtArea;
/**
* 费用开始日期
*/
private Date assessStartTime;
/**
* 费用结束日期
*/
private Date assessEndTime;
/**
* 总费用合计
*/
private String assessAllCost;
private static final long serialVersionUID = 1L;
}
\ No newline at end of file
package com.hungraim.ltc.pojo.entity.account;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
/**
* CH_DISAB_ACCOUNTS_DETAIL
*/
@Data
@TableName("CH_ASSESS_ACCOUNTS_DETAIL")
@KeySequence("SEQ_CH_ASSESS_ACCOUNTS_DETAIL")
public class ChAssessDetailAccounts implements Serializable {
/**
* 结算id
*/
@TableId(value = "ASSESS_ACCOUNTS_DETAIL_ID", type = IdType.INPUT)
private Long assessAccountsDetailId;
private Long assessAccountsId;
private String disabInfoId;
/**
* 护理机构id
*/
private String srvOrganId;
/**
* 创建时间
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
private Date creationTime;
/**
* 结算月份
*/
@DateTimeFormat(pattern = "yyyy-MM")
@JsonFormat(pattern = "yyyy-MM",timezone = "GMT+8")
private Date accountsTime;
private String assessAllCost;
private String assessOverallCost;
private String assessPersonalCost;
/**
* 费用开始日期
*/
private Date assessStartTime;
/**
* 费用结束日期
*/
private Date assessEndTime;
private static final long serialVersionUID = 1L;
}
\ No newline at end of file
......@@ -74,5 +74,33 @@ public class ChDisabAccounts implements Serializable {
*/
private String checkRemark;
/**
* 服务方式
*/
private String modeName;
/**
* 费用开始日期
*/
private Date svrStartTime;
/**
* 费用结束日期
*/
private Date svrEndTime;
/**
* 总费用合计
*/
private String allCost;
/**
* 统筹支出
*/
private String overallCost;
/**
* 个人支出
*/
private String personalCost;
private static final long serialVersionUID = 1L;
}
\ No newline at end of file
package com.hungraim.ltc.pojo.entity.account;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.KeySequence;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
/**
* CH_DISAB_ACCOUNTS_DETAIL
*/
@Data
@TableName("CH_DISAB_ACCOUNTS_DETAIL")
@KeySequence("SEQ_CH_DISAB_DETAIL_ACCOUNTS")
public class ChDisabDetailAccounts implements Serializable {
/**
* 结算id
*/
@TableId(value = "ACCOUNTS_DETAIL_ID", type = IdType.INPUT)
private Long accountsDetailId;
private Long accountsId;
private String disabInfoId;
/**
* 护理机构id
*/
private String srvOrganId;
/**
* 创建时间
*/
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
private Date creationTime;
/**
* 结算月份
*/
@DateTimeFormat(pattern = "yyyy-MM")
@JsonFormat(pattern = "yyyy-MM",timezone = "GMT+8")
private Date accountsTime;
/**
* 应拨总费用
*/
private BigDecimal accountsAllCost;
private BigDecimal accountsOverallCost;
private BigDecimal accountsPersonalCost;
/**
* 服务方式
*/
private String modeName;
/**
* 费用开始日期
*/
private Date accountsStartTime;
/**
* 费用结束日期
*/
private Date accountsEndTime;
private static final long serialVersionUID = 1L;
}
\ No newline at end of file
package com.hungraim.ltc.pojo.vo.account;
import cn.afterturn.easypoi.excel.annotation.Excel;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
@Data
public class AccountExportDetailListResp {
/**
* 适用机构名称
*/
@Excel(name = "适用机构名称",width = 20)
private String organName;
/**
* 护理机构名称
*/
@Excel(name = "护理机构名称",width = 20)
private String srvOrganName;
/**
* 结算月份
*/
@Excel(name = "结算月份",width = 20)
private String accountsTime;
/**
* 费用开始时间
*/
@Excel(name = "费用开始时间",width = 20)
private String accountsStartTime;
/**
* 费用结束时间
*/
@Excel(name = "费用结束时间",width = 20)
private String accountsEndTime;
/**
* 总费用
*/
@Excel(name = "总费用")
private String accountsAllCost;
/**
* 统筹费用
*/
@Excel(name = "统筹支出")
private String accountsOverallCost;
/**
* 个人支付
*/
@Excel(name = "个人支付")
private String accountsPersonalCost;
}
package com.hungraim.ltc.pojo.vo.account;
import cn.afterturn.easypoi.excel.annotation.Excel;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
@Data
public class AssessAccountsExportResp {
@Excel(name = "适用机构名称",width = 20)
private String organName;
/**
* 护理机构名称
*/
@Excel(name = "护理机构名称",width = 20)
private String srvOrganName;
/**
* 结算月份
*/
@Excel(name = "结算月份",width = 20)
private String accountsTime;
/**
* 总费用
*/
@Excel(name = "总费用")
private String assessCost;
/**
* 费用开始时间
*/
@Excel(name = "费用开始时间",width = 20)
private String assessStartTime;
/**
* 费用结束时间
*/
@Excel(name = "费用结束时间",width = 20)
private String assessEndTime;
}
package com.hungraim.ltc.pojo.vo.account;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
@Data
public class AssessAccountsListResp {
/**
* 结算id
*/
private Long assessAccountsId;
/**
* 适用机构id
*/
private Long organId;
/**
* 适用机构名称
*/
private String organName;
/**
* 护理机构id
*/
private String srvOrganId;
private String disabInfoId;
/**
* 护理机构名称
*/
private String srvOrganName;
/**
* 结算月份
*/
@DateTimeFormat(pattern = "yyyy-MM")
@JsonFormat(pattern = "yyyy-MM",timezone = "GMT+8")
private Date accountsTime;
/**
* 状态(0-待提交;1-待审核;2-已审核;3-已失效;)
*/
private Short accountsStatus;
/**
* 总费用
*/
private String assessCost;
/**
* 费用开始时间
*/
private String assessStartTime;
/**
* 费用结束时间
*/
private String assessEndTime;
private String aprempTypeName;
}
package com.hungraim.ltc.pojo.vo.account;
import lombok.Data;
/**
* 评估结算VO
*/
@Data
public class AssessAccountsVO {
private String organName;
private String aprOrganId;
private String districtProvincial;
private String districtCity;
private String districtArea;
private String aprempTypeName;
private String disabInfoId;
}
package com.hungraim.ltc.pojo.vo.account;
import lombok.Data;
import java.math.BigDecimal;
/**
* 机构结算VO
*/
@Data
public class OrganAccountsVO {
private String disabInfoId;
/**
* 失能人员姓名
*/
private String realName;
/**
* 身份证号
*/
private String certiCode;
/**
* 服务方式id
*/
private String modeId;
/**
* 服务方式
*/
private String srvModeName;
/**
* 护理机构id
*/
private String srvOrganId;
/**
* 护理机构名称
*/
private String srvOrganName;
/**
* 所在省市
*/
private String districtProvincial;
private String districtCity;
private String districtArea;
/**
* 护理服务人员
*/
private String empName;
/**
* 任务时间
*/
private String srvDate;
/**
* 机构等级
*/
private String levelCode;
/**
* 失能等级
*/
private String disableLevelName;
/**
* 总费用
*/
private BigDecimal allCost;
/**
* 统筹支出
*/
private BigDecimal overallCost;
/**
* 个人支出
*/
private BigDecimal personalCost;
}
package com.hungraim.ltc.pojo.vo.account;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.checkerframework.checker.units.qual.C;
import org.springframework.format.annotation.DateTimeFormat;
import java.util.Date;
@Data
public class SrvOrganAccountListResp {
/**
* 结算id
*/
private Long accountsId;
/**
* 适用机构id
*/
private Long organId;
/**
* 适用机构名称
*/
private String organName;
/**
* 护理机构id
*/
private Long srvOrganId;
/**
* 护理机构名称
*/
private String srvOrganName;
/**
* 结算月份
*/
@DateTimeFormat(pattern = "yyyy-MM")
@JsonFormat(pattern = "yyyy-MM",timezone = "GMT+8")
private Date accountsTime;
/**
* 状态(0-待提交;1-待审核;2-已审核;3-已失效;)
*/
private Short accountsStatus;
/**
* 总费用
*/
private String allCost;
/**
* 统筹费用
*/
private String overallCost;
/**
* 个人支付
*/
private String personalCost;
/**
* 费用开始时间
*/
private String svrStartTime;
/**
* 费用结束时间
*/
private String svrEndTime;
}
......@@ -3,6 +3,7 @@ package com.hungraim.ltc.util;
import cn.hutool.core.util.StrUtil;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.ParsePosition;
import java.text.SimpleDateFormat;
......@@ -32,6 +33,8 @@ public class DateUtils {
*/
public static final String DATE_PATTERN_yyyy_MM_dd = "yyyy-MM-dd";
public static final String DATE_PATTERN_yyyy_MM = "yyyy-MM";
/**
* MM-dd 12月25日
*/
......@@ -854,4 +857,33 @@ public class DateUtils {
}
return flag;
}
/**
* 获取当前月份的上个月
*
* @return
*/
public static String getlastMonth(){
SimpleDateFormat ym=new SimpleDateFormat(DATE_PATTERN_yyyy_MM);
Calendar calendar = Calendar.getInstance();
calendar.add(Calendar.MONTH,-1);
String lastMonth =ym.format(calendar.getTime());
return lastMonth;
}
/**
* 获取当前月份的上个月
*
* @return
*/
public static Date getlastMonth(String str){
DateFormat fmt =new SimpleDateFormat(DATE_PATTERN_yyyy_MM);
Date date = null;
try {
date = fmt.parse(str);
} catch (ParseException e) {
e.printStackTrace();
}
return date;
}
}
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