diff --git a/ruoyi-admin/src/main/resources/application-prop.yml b/ruoyi-admin/src/main/resources/application-prop.yml index ddb00e3a6..8e2a891ce 100644 --- a/ruoyi-admin/src/main/resources/application-prop.yml +++ b/ruoyi-admin/src/main/resources/application-prop.yml @@ -6,7 +6,7 @@ spring: druid: # 主库数据源 master: - url: jdbc:mysql://120.77.157.122:3306/fantang?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true + url: jdbc:mysql:///fantang?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true username: fantang password: HdfzaPE8YbdWdjCw # 从库数据源 diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/controller/FtInvoiceDaoController.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/controller/FtInvoiceDaoController.java new file mode 100644 index 000000000..7a213cc64 --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/controller/FtInvoiceDaoController.java @@ -0,0 +1,107 @@ +package com.ruoyi.system.fantang.controller; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; + +import java.util.List; +import java.util.Arrays; + +import com.baomidou.mybatisplus.core.toolkit.Wrappers; +import com.ruoyi.common.utils.StringUtils; +import lombok.RequiredArgsConstructor; +import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.GetMapping; +import org.springframework.web.bind.annotation.PostMapping; +import org.springframework.web.bind.annotation.PutMapping; +import org.springframework.web.bind.annotation.DeleteMapping; +import org.springframework.web.bind.annotation.PathVariable; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RestController; +import com.ruoyi.common.annotation.Log; +import com.ruoyi.common.core.controller.BaseController; +import com.ruoyi.common.core.domain.AjaxResult; +import com.ruoyi.common.enums.BusinessType; +import com.ruoyi.system.fantang.domain.FtInvoiceDao; +import com.ruoyi.system.fantang.service.IFtInvoiceDaoService; +import com.ruoyi.common.utils.poi.ExcelUtil; +import com.ruoyi.common.core.page.TableDataInfo; + +/** + * 财务收费开票Controller + * + * @author ft + * @date 2020-12-08 + */ +@RequiredArgsConstructor(onConstructor_ = @Autowired) +@RestController +@RequestMapping("/fantang/invoice" ) +public class FtInvoiceDaoController extends BaseController { + + private final IFtInvoiceDaoService iFtInvoiceDaoService; + + /** + * 查询财务收费开票列表 + */ + @PreAuthorize("@ss.hasPermi('fantang:invoice:list')") + @GetMapping("/list") + public TableDataInfo list(FtInvoiceDao ftInvoiceDao) + { + startPage(); + LambdaQueryWrapper lqw = Wrappers.lambdaQuery(ftInvoiceDao); + List list = iFtInvoiceDaoService.list(lqw); + return getDataTable(list); + } + + /** + * 导出财务收费开票列表 + */ + @PreAuthorize("@ss.hasPermi('fantang:invoice:export')" ) + @Log(title = "财务收费开票" , businessType = BusinessType.EXPORT) + @GetMapping("/export" ) + public AjaxResult export(FtInvoiceDao ftInvoiceDao) { + LambdaQueryWrapper lqw = new LambdaQueryWrapper(ftInvoiceDao); + List list = iFtInvoiceDaoService.list(lqw); + ExcelUtil util = new ExcelUtil(FtInvoiceDao. class); + return util.exportExcel(list, "invoice" ); + } + + /** + * 获取财务收费开票详细信息 + */ + @PreAuthorize("@ss.hasPermi('fantang:invoice:query')" ) + @GetMapping(value = "/{id}" ) + public AjaxResult getInfo(@PathVariable("id" ) Long id) { + return AjaxResult.success(iFtInvoiceDaoService.getById(id)); + } + + /** + * 新增财务收费开票 + */ + @PreAuthorize("@ss.hasPermi('fantang:invoice:add')" ) + @Log(title = "财务收费开票" , businessType = BusinessType.INSERT) + @PostMapping + public AjaxResult add(@RequestBody FtInvoiceDao ftInvoiceDao) { + return toAjax(iFtInvoiceDaoService.save(ftInvoiceDao) ? 1 : 0); + } + + /** + * 修改财务收费开票 + */ + @PreAuthorize("@ss.hasPermi('fantang:invoice:edit')" ) + @Log(title = "财务收费开票" , businessType = BusinessType.UPDATE) + @PutMapping + public AjaxResult edit(@RequestBody FtInvoiceDao ftInvoiceDao) { + return toAjax(iFtInvoiceDaoService.updateById(ftInvoiceDao) ? 1 : 0); + } + + /** + * 删除财务收费开票 + */ + @PreAuthorize("@ss.hasPermi('fantang:invoice:remove')" ) + @Log(title = "财务收费开票" , businessType = BusinessType.DELETE) + @DeleteMapping("/{ids}" ) + public AjaxResult remove(@PathVariable Long[] ids) { + return toAjax(iFtInvoiceDaoService.removeByIds(Arrays.asList(ids)) ? 1 : 0); + } +} diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/domain/FtInvoiceDao.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/domain/FtInvoiceDao.java new file mode 100644 index 000000000..b9b833e4a --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/domain/FtInvoiceDao.java @@ -0,0 +1,62 @@ +package com.ruoyi.system.fantang.domain; + +import com.fasterxml.jackson.annotation.JsonFormat; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import lombok.ToString; +import lombok.experimental.Accessors; +import com.ruoyi.common.annotation.Excel; +import com.baomidou.mybatisplus.annotation.TableId; +import com.baomidou.mybatisplus.annotation.TableName; +import com.baomidou.mybatisplus.annotation.IdType; +import java.io.Serializable; +import java.util.Date; +import java.math.BigDecimal; +import com.ruoyi.common.core.domain.BaseEntity; + +/** + * 财务收费开票对象 ft_invoice + * + * @author ft + * @date 2020-12-08 + */ +@Data +@ToString +@EqualsAndHashCode +@NoArgsConstructor +@Accessors(chain = true) +@TableName("ft_invoice") +public class FtInvoiceDao implements Serializable { + +private static final long serialVersionUID=1L; + + + /** id */ + @TableId(value = "id") + private Long id; + + /** 发票单位 */ + private String invoiceUnit; + + /** 发票 id */ + private Long invoiceId; + + /** 日期 */ + private Date createAt; + + /** 开票人 */ + private String drawer; + + /** 收款方式 */ + private Integer collectionType; + + /** 应收 */ + private BigDecimal payable; + + /** 实收 */ + private BigDecimal receipts; + + /** 凭证列表 */ + private String voucherList; +} diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/mapper/FtInvoiceDaoMapper.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/mapper/FtInvoiceDaoMapper.java new file mode 100644 index 000000000..1271aca07 --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/mapper/FtInvoiceDaoMapper.java @@ -0,0 +1,14 @@ +package com.ruoyi.system.fantang.mapper; + +import com.ruoyi.system.fantang.domain.FtInvoiceDao; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; + +/** + * 财务收费开票Mapper接口 + * + * @author ft + * @date 2020-12-08 + */ +public interface FtInvoiceDaoMapper extends BaseMapper { + +} diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/IFtInvoiceDaoService.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/IFtInvoiceDaoService.java new file mode 100644 index 000000000..d5686f674 --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/IFtInvoiceDaoService.java @@ -0,0 +1,14 @@ +package com.ruoyi.system.fantang.service; + +import com.ruoyi.system.fantang.domain.FtInvoiceDao; +import com.baomidou.mybatisplus.extension.service.IService; + +/** + * 财务收费开票Service接口 + * + * @author ft + * @date 2020-12-08 + */ +public interface IFtInvoiceDaoService extends IService { + +} diff --git a/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/impl/FtInvoiceDaoServiceImpl.java b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/impl/FtInvoiceDaoServiceImpl.java new file mode 100644 index 000000000..f26e5bd12 --- /dev/null +++ b/ruoyi-system/src/main/java/com/ruoyi/system/fantang/service/impl/FtInvoiceDaoServiceImpl.java @@ -0,0 +1,18 @@ +package com.ruoyi.system.fantang.service.impl; + +import org.springframework.stereotype.Service; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.ruoyi.system.fantang.mapper.FtInvoiceDaoMapper; +import com.ruoyi.system.fantang.domain.FtInvoiceDao; +import com.ruoyi.system.fantang.service.IFtInvoiceDaoService; + +/** + * 财务收费开票Service业务层处理 + * + * @author ft + * @date 2020-12-08 + */ +@Service +public class FtInvoiceDaoServiceImpl extends ServiceImpl implements IFtInvoiceDaoService { + +} diff --git a/ruoyi-system/src/main/resources/mapper/fantang/FtInvoiceDaoMapper.xml b/ruoyi-system/src/main/resources/mapper/fantang/FtInvoiceDaoMapper.xml new file mode 100644 index 000000000..fdc38d089 --- /dev/null +++ b/ruoyi-system/src/main/resources/mapper/fantang/FtInvoiceDaoMapper.xml @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/ruoyi-ui/src/views/fantang/patient/index.vue b/ruoyi-ui/src/views/fantang/patient/index.vue index 4516510cd..bb8bcbcf4 100644 --- a/ruoyi-ui/src/views/fantang/patient/index.vue +++ b/ruoyi-ui/src/views/fantang/patient/index.vue @@ -209,6 +209,7 @@ export default { /** 查询病人管理列表 */ getList() { this.loading = true; + console.log("111------------------",this.queryParams) listPatient(this.queryParams).then(response => { this.patientList = response.rows; this.total = response.total; diff --git a/ruoyi-ui/src/views/fantang/prepayment/index.vue b/ruoyi-ui/src/views/fantang/prepayment/index.vue index 76206fc7a..04a70e8df 100644 --- a/ruoyi-ui/src/views/fantang/prepayment/index.vue +++ b/ruoyi-ui/src/views/fantang/prepayment/index.vue @@ -29,7 +29,7 @@ - + { this.prepaymentList = response.rows; this.total = response.total; - this.loadAll(); + // this.loadAll(); this.loading = false; }); }, @@ -385,7 +386,7 @@ settlementBy: null, settlementId: null, settlementFlag: null, - prepaid: 500, + prepaid: 700, prepaidAt: new Date(), hospitalId: null, name: null, diff --git a/ruoyi-ui/src/views/fantang/settle/index.vue b/ruoyi-ui/src/views/fantang/settle/index.vue index 38ae3e681..17a6b5b4f 100644 --- a/ruoyi-ui/src/views/fantang/settle/index.vue +++ b/ruoyi-ui/src/views/fantang/settle/index.vue @@ -194,15 +194,15 @@ - + - + - + - + @@ -492,6 +492,7 @@ export default { this.settleList = response.rows; this.total = response.total; this.loading = false; + console.log("list-------") }); }, diff --git a/ruoyi-ui/src/views/fantang/staffInfo/index.vue b/ruoyi-ui/src/views/fantang/staffInfo/index.vue index 5b6c4c4dc..cca822ebb 100644 --- a/ruoyi-ui/src/views/fantang/staffInfo/index.vue +++ b/ruoyi-ui/src/views/fantang/staffInfo/index.vue @@ -91,7 +91,7 @@ - + @@ -295,6 +295,11 @@ export default { return '禁用'; }, + //回显员工性别 + formatSex(row) { + return this.selectDictLabel(this.sexOptions, row.sex); + }, + /** 查询员工管理列表 */ getList() { this.loading = true;