| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.information.controller; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import lombok.AllArgsConstructor; |
| | | import javax.validation.Valid; |
| | | |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.modules.information.entity.Information; |
| | | import org.springblade.modules.information.vo.InformationVO; |
| | | import org.springblade.modules.information.service.IInformationService; |
| | | import org.springblade.core.boot.ctrl.BladeController; |
| | | |
| | | /** |
| | | * 控制器 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @RestController |
| | | @AllArgsConstructor |
| | | @RequestMapping("/information") |
| | | @Api(value = "", tags = "接口") |
| | | public class InformationController extends BladeController { |
| | | |
| | | private final IInformationService informationService; |
| | | |
| | | /** |
| | | * 详情 |
| | | */ |
| | | @GetMapping("/detail") |
| | | @ApiOperationSupport(order = 1) |
| | | @ApiOperation(value = "详情", notes = "传入information") |
| | | public R<Information> detail(Information information) { |
| | | Information detail = informationService.getOne(Condition.getQueryWrapper(information)); |
| | | return R.data(detail); |
| | | } |
| | | |
| | | /** |
| | | * 分页 |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperationSupport(order = 2) |
| | | @ApiOperation(value = "分页", notes = "传入information") |
| | | public R<IPage<Information>> list(Information information, Query query) { |
| | | IPage<Information> pages = informationService.page(Condition.getPage(query), Condition.getQueryWrapper(information)); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | */ |
| | | @GetMapping("/page") |
| | | @ApiOperationSupport(order = 3) |
| | | @ApiOperation(value = "分页", notes = "传入information") |
| | | public R<IPage<InformationVO>> page(InformationVO information, Query query) { |
| | | IPage<InformationVO> pages = informationService.selectInformationPage(Condition.getPage(query), information); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @PostMapping("/save") |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入information") |
| | | public R save(@Valid @RequestBody Information information) { |
| | | return R.status(informationService.save(information)); |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入information") |
| | | public R update(@Valid @RequestBody Information information) { |
| | | return R.status(informationService.updateById(information)); |
| | | } |
| | | |
| | | /** |
| | | * 新增或修改 |
| | | */ |
| | | @PostMapping("/submit") |
| | | @ApiOperationSupport(order = 6) |
| | | @ApiOperation(value = "新增或修改", notes = "传入information") |
| | | public R submit(@Valid @RequestBody Information information) { |
| | | return R.status(informationService.saveOrUpdate(information)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | @PostMapping("/remove") |
| | | @ApiOperationSupport(order = 8) |
| | | @ApiOperation(value = "删除", notes = "传入ids") |
| | | public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
| | | return R.status(informationService.removeByIds(Func.toLongList(ids))); |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.information.dto; |
| | | |
| | | import org.springblade.modules.information.entity.Information; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | /** |
| | | * 数据传输对象实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class InformationDTO extends Information { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.information.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import java.time.LocalDateTime; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import java.io.Serializable; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | |
| | | /** |
| | | * 实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @TableName("sys_information") |
| | | @ApiModel(value = "Information对象", description = "Information对象") |
| | | public class Information implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | /** |
| | | * 统一社会信用代码 |
| | | */ |
| | | @ApiModelProperty(value = "统一社会信用代码") |
| | | @TableField("creditCode") |
| | | private String creditcode; |
| | | /** |
| | | * 企业名称 |
| | | */ |
| | | @ApiModelProperty(value = "企业名称") |
| | | @TableField("enterpriseName") |
| | | private String enterprisename; |
| | | /** |
| | | * 法定代表人 |
| | | */ |
| | | @ApiModelProperty(value = "法定代表人") |
| | | private String representative; |
| | | /** |
| | | * 登记状态 |
| | | */ |
| | | @ApiModelProperty(value = "登记状态") |
| | | @TableField(" registrationStatus") |
| | | private String registrationstatus; |
| | | /** |
| | | * 成立日期 |
| | | */ |
| | | @ApiModelProperty(value = "成立日期") |
| | | @TableField("establishTime") |
| | | private String establishtime; |
| | | /** |
| | | * 注册资本 |
| | | */ |
| | | @ApiModelProperty(value = "注册资本") |
| | | @TableField("registeredCapital") |
| | | private String registeredcapital; |
| | | /** |
| | | * 实缴资本 |
| | | */ |
| | | @ApiModelProperty(value = "实缴资本") |
| | | private String capital; |
| | | /** |
| | | * 组织机构代码 |
| | | */ |
| | | @ApiModelProperty(value = "组织机构代码") |
| | | @TableField("organizationCode") |
| | | private String organizationcode; |
| | | /** |
| | | * 工商注册号 |
| | | */ |
| | | @ApiModelProperty(value = "工商注册号") |
| | | @TableField("registrationNumber") |
| | | private Integer registrationnumber; |
| | | /** |
| | | * 纳税人识别号 |
| | | */ |
| | | @ApiModelProperty(value = "纳税人识别号") |
| | | @TableField("identificationNumber") |
| | | private Integer identificationnumber; |
| | | /** |
| | | * 企业类型 |
| | | */ |
| | | @ApiModelProperty(value = "企业类型") |
| | | private String enterprises; |
| | | /** |
| | | * 注册地址 |
| | | */ |
| | | @ApiModelProperty(value = "注册地址") |
| | | private String address; |
| | | /** |
| | | * 经营范围 |
| | | */ |
| | | @ApiModelProperty(value = "经营范围") |
| | | private String business; |
| | | /** |
| | | * 所属地区 |
| | | */ |
| | | @ApiModelProperty(value = "所属地区") |
| | | private String region; |
| | | /** |
| | | * 登记机关 |
| | | */ |
| | | @ApiModelProperty(value = "登记机关") |
| | | private String registration; |
| | | /** |
| | | * 所属行业 |
| | | */ |
| | | @ApiModelProperty(value = "所属行业") |
| | | private String industry; |
| | | /** |
| | | * 租户ID |
| | | */ |
| | | @ApiModelProperty(value = "租户ID") |
| | | @TableField("tenantId") |
| | | private String tenantid; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.information.mapper; |
| | | |
| | | import org.springblade.modules.information.entity.Information; |
| | | import org.springblade.modules.information.vo.InformationVO; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * Mapper 接口 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | public interface InformationMapper extends BaseMapper<Information> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param information |
| | | * @return |
| | | */ |
| | | List<InformationVO> selectInformationPage(IPage page, InformationVO information); |
| | | |
| | | } |
| New file |
| | |
| | | <?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="org.springblade.modules.information.mapper.InformationMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="informationResultMap" type="org.springblade.modules.information.entity.Information"> |
| | | <id column="id" property="id"/> |
| | | <result column="creditCode" property="creditcode"/> |
| | | <result column="enterpriseName" property="enterprisename"/> |
| | | <result column="representative" property="representative"/> |
| | | <result column=" |
| | | |
| | | registrationStatus |
| | | " property=" |
| | | |
| | | registrationstatus |
| | | "/> |
| | | <result column="establishTime" property="establishtime"/> |
| | | <result column="registeredCapital" property="registeredcapital"/> |
| | | <result column="capital" property="capital"/> |
| | | <result column="organizationCode" property="organizationcode"/> |
| | | <result column="registrationNumber" property="registrationnumber"/> |
| | | <result column="identificationNumber" property="identificationnumber"/> |
| | | <result column="enterprises" property="enterprises"/> |
| | | <result column="address" property="address"/> |
| | | <result column="business" property="business"/> |
| | | <result column="region" property="region"/> |
| | | <result column="registration" property="registration"/> |
| | | <result column="industry" property="industry"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <select id="selectInformationPage" resultMap="informationResultMap"> |
| | | select * from sys_information where is_deleted = 0 |
| | | </select> |
| | | |
| | | </mapper> |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.information.service; |
| | | |
| | | import org.springblade.modules.information.entity.Information; |
| | | import org.springblade.modules.information.vo.InformationVO; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 服务类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | public interface IInformationService extends IService<Information> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param information |
| | | * @return |
| | | */ |
| | | IPage<InformationVO> selectInformationPage(IPage<InformationVO> page, InformationVO information); |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.information.service.impl; |
| | | |
| | | import org.springblade.modules.information.entity.Information; |
| | | import org.springblade.modules.information.vo.InformationVO; |
| | | import org.springblade.modules.information.mapper.InformationMapper; |
| | | import org.springblade.modules.information.service.IInformationService; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 服务实现类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Service |
| | | public class InformationServiceImpl extends ServiceImpl<InformationMapper, Information> implements IInformationService { |
| | | |
| | | @Override |
| | | public IPage<InformationVO> selectInformationPage(IPage<InformationVO> page, InformationVO information) { |
| | | return page.setRecords(baseMapper.selectInformationPage(page, information)); |
| | | } |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.information.vo; |
| | | |
| | | import org.springblade.modules.information.entity.Information; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import io.swagger.annotations.ApiModel; |
| | | |
| | | /** |
| | | * 视图实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ApiModel(value = "InformationVO对象", description = "InformationVO对象") |
| | | public class InformationVO extends Information { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.member.controller; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import lombok.AllArgsConstructor; |
| | | import javax.validation.Valid; |
| | | |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.modules.member.entity.Member; |
| | | import org.springblade.modules.member.vo.MemberVO; |
| | | import org.springblade.modules.member.service.IMemberService; |
| | | import org.springblade.core.boot.ctrl.BladeController; |
| | | |
| | | /** |
| | | * 控制器 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @RestController |
| | | @AllArgsConstructor |
| | | @RequestMapping("/member") |
| | | @Api(value = "", tags = "接口") |
| | | public class MemberController extends BladeController { |
| | | |
| | | private final IMemberService memberService; |
| | | |
| | | /** |
| | | * 详情 |
| | | */ |
| | | @GetMapping("/detail") |
| | | @ApiOperationSupport(order = 1) |
| | | @ApiOperation(value = "详情", notes = "传入member") |
| | | public R<Member> detail(Member member) { |
| | | Member detail = memberService.getOne(Condition.getQueryWrapper(member)); |
| | | return R.data(detail); |
| | | } |
| | | |
| | | /** |
| | | * 分页 |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperationSupport(order = 2) |
| | | @ApiOperation(value = "分页", notes = "传入member") |
| | | public R<IPage<Member>> list(Member member, Query query) { |
| | | IPage<Member> pages = memberService.page(Condition.getPage(query), Condition.getQueryWrapper(member)); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | */ |
| | | @GetMapping("/page") |
| | | @ApiOperationSupport(order = 3) |
| | | @ApiOperation(value = "分页", notes = "传入member") |
| | | public R<IPage<MemberVO>> page(MemberVO member, Query query) { |
| | | IPage<MemberVO> pages = memberService.selectMemberPage(Condition.getPage(query), member); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @PostMapping("/save") |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入member") |
| | | public R save(@Valid @RequestBody Member member) { |
| | | return R.status(memberService.save(member)); |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入member") |
| | | public R update(@Valid @RequestBody Member member) { |
| | | return R.status(memberService.updateById(member)); |
| | | } |
| | | |
| | | /** |
| | | * 新增或修改 |
| | | */ |
| | | @PostMapping("/submit") |
| | | @ApiOperationSupport(order = 6) |
| | | @ApiOperation(value = "新增或修改", notes = "传入member") |
| | | public R submit(@Valid @RequestBody Member member) { |
| | | return R.status(memberService.saveOrUpdate(member)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | @PostMapping("/remove") |
| | | @ApiOperationSupport(order = 8) |
| | | @ApiOperation(value = "删除", notes = "传入ids") |
| | | public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
| | | return R.status(memberService.removeByIds(Func.toLongList(ids))); |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.member.dto; |
| | | |
| | | import org.springblade.modules.member.entity.Member; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | /** |
| | | * 数据传输对象实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class MemberDTO extends Member { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.member.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import java.io.Serializable; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | |
| | | /** |
| | | * 实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @TableName("sys_member") |
| | | @ApiModel(value = "Member对象", description = "Member对象") |
| | | public class Member implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | /** |
| | | * 姓名 |
| | | */ |
| | | @ApiModelProperty(value = "姓名") |
| | | private String name; |
| | | /** |
| | | * 职务 |
| | | */ |
| | | @ApiModelProperty(value = "职务") |
| | | private String post; |
| | | /** |
| | | * 身份证 |
| | | */ |
| | | @ApiModelProperty(value = "身份证") |
| | | private Integer cardid; |
| | | /** |
| | | * 联系电话 |
| | | */ |
| | | @ApiModelProperty(value = "联系电话") |
| | | private String cell; |
| | | /** |
| | | * 持股比例 |
| | | */ |
| | | @ApiModelProperty(value = "持股比例") |
| | | @TableField("shareholdingRatio") |
| | | private String shareholdingratio; |
| | | |
| | | /** |
| | | * 租户ID |
| | | */ |
| | | @ApiModelProperty(value = "租户ID") |
| | | @TableField("tenantId") |
| | | private String tenantid; |
| | | /** |
| | | * 统一社会信用代码 |
| | | */ |
| | | @ApiModelProperty(value = "统一社会信用代码") |
| | | @TableField("creditCode") |
| | | private String creditcode; |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.member.mapper; |
| | | |
| | | import org.springblade.modules.member.entity.Member; |
| | | import org.springblade.modules.member.vo.MemberVO; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * Mapper 接口 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | public interface MemberMapper extends BaseMapper<Member> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param member |
| | | * @return |
| | | */ |
| | | List<MemberVO> selectMemberPage(IPage page, MemberVO member); |
| | | |
| | | } |
| New file |
| | |
| | | <?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="org.springblade.modules.member.mapper.MemberMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="memberResultMap" type="org.springblade.modules.member.entity.Member"> |
| | | <id column="id" property="id"/> |
| | | <result column="name" property="name"/> |
| | | <result column="post" property="post"/> |
| | | <result column="cardid" property="cardid"/> |
| | | <result column="cell" property="cell"/> |
| | | <result column="shareholdingRatio" property="shareholdingratio"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <select id="selectMemberPage" resultMap="memberResultMap"> |
| | | select * from sys_member where is_deleted = 0 |
| | | </select> |
| | | |
| | | </mapper> |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.member.service; |
| | | |
| | | import org.springblade.modules.member.entity.Member; |
| | | import org.springblade.modules.member.vo.MemberVO; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 服务类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | public interface IMemberService extends IService<Member> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param member |
| | | * @return |
| | | */ |
| | | IPage<MemberVO> selectMemberPage(IPage<MemberVO> page, MemberVO member); |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.member.service.impl; |
| | | |
| | | import org.springblade.modules.member.entity.Member; |
| | | import org.springblade.modules.member.vo.MemberVO; |
| | | import org.springblade.modules.member.mapper.MemberMapper; |
| | | import org.springblade.modules.member.service.IMemberService; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 服务实现类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Service |
| | | public class MemberServiceImpl extends ServiceImpl<MemberMapper, Member> implements IMemberService { |
| | | |
| | | @Override |
| | | public IPage<MemberVO> selectMemberPage(IPage<MemberVO> page, MemberVO member) { |
| | | return page.setRecords(baseMapper.selectMemberPage(page, member)); |
| | | } |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.member.vo; |
| | | |
| | | import org.springblade.modules.member.entity.Member; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import io.swagger.annotations.ApiModel; |
| | | |
| | | /** |
| | | * 视图实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ApiModel(value = "MemberVO对象", description = "MemberVO对象") |
| | | public class MemberVO extends Member { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.shareholder.controller; |
| | | |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import lombok.AllArgsConstructor; |
| | | import javax.validation.Valid; |
| | | |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | | import org.springblade.core.tool.utils.Func; |
| | | import org.springframework.web.bind.annotation.*; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.modules.shareholder.entity.Shareholder; |
| | | import org.springblade.modules.shareholder.vo.ShareholderVO; |
| | | import org.springblade.modules.shareholder.service.IShareholderService; |
| | | import org.springblade.core.boot.ctrl.BladeController; |
| | | |
| | | /** |
| | | * 控制器 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @RestController |
| | | @AllArgsConstructor |
| | | @RequestMapping("/shareholder") |
| | | @Api(value = "", tags = "接口") |
| | | public class ShareholderController extends BladeController { |
| | | |
| | | private final IShareholderService shareholderService; |
| | | |
| | | /** |
| | | * 详情 |
| | | */ |
| | | @GetMapping("/detail") |
| | | @ApiOperationSupport(order = 1) |
| | | @ApiOperation(value = "详情", notes = "传入shareholder") |
| | | public R<Shareholder> detail(Shareholder shareholder) { |
| | | Shareholder detail = shareholderService.getOne(Condition.getQueryWrapper(shareholder)); |
| | | return R.data(detail); |
| | | } |
| | | |
| | | /** |
| | | * 分页 |
| | | */ |
| | | @GetMapping("/list") |
| | | @ApiOperationSupport(order = 2) |
| | | @ApiOperation(value = "分页", notes = "传入shareholder") |
| | | public R<IPage<Shareholder>> list(Shareholder shareholder, Query query) { |
| | | IPage<Shareholder> pages = shareholderService.page(Condition.getPage(query), Condition.getQueryWrapper(shareholder)); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | */ |
| | | @GetMapping("/page") |
| | | @ApiOperationSupport(order = 3) |
| | | @ApiOperation(value = "分页", notes = "传入shareholder") |
| | | public R<IPage<ShareholderVO>> page(ShareholderVO shareholder, Query query) { |
| | | IPage<ShareholderVO> pages = shareholderService.selectShareholderPage(Condition.getPage(query), shareholder); |
| | | return R.data(pages); |
| | | } |
| | | |
| | | /** |
| | | * 新增 |
| | | */ |
| | | @PostMapping("/save") |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "新增", notes = "传入shareholder") |
| | | public R save(@Valid @RequestBody Shareholder shareholder) { |
| | | return R.status(shareholderService.save(shareholder)); |
| | | } |
| | | |
| | | /** |
| | | * 修改 |
| | | */ |
| | | @PostMapping("/update") |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "修改", notes = "传入shareholder") |
| | | public R update(@Valid @RequestBody Shareholder shareholder) { |
| | | return R.status(shareholderService.updateById(shareholder)); |
| | | } |
| | | |
| | | /** |
| | | * 新增或修改 |
| | | */ |
| | | @PostMapping("/submit") |
| | | @ApiOperationSupport(order = 6) |
| | | @ApiOperation(value = "新增或修改", notes = "传入shareholder") |
| | | public R submit(@Valid @RequestBody Shareholder shareholder) { |
| | | return R.status(shareholderService.saveOrUpdate(shareholder)); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 删除 |
| | | */ |
| | | @PostMapping("/remove") |
| | | @ApiOperationSupport(order = 8) |
| | | @ApiOperation(value = "删除", notes = "传入ids") |
| | | public R remove(@ApiParam(value = "主键集合", required = true) @RequestParam String ids) { |
| | | return R.status(shareholderService.removeByIds(Func.toLongList(ids))); |
| | | } |
| | | |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.shareholder.dto; |
| | | |
| | | import org.springblade.modules.shareholder.entity.Shareholder; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | |
| | | /** |
| | | * 数据传输对象实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | public class ShareholderDTO extends Shareholder { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.shareholder.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | |
| | | import java.time.LocalDateTime; |
| | | |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | |
| | | /** |
| | | * 实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @TableName("sys_shareholder") |
| | | @ApiModel(value = "Shareholder对象", description = "Shareholder对象") |
| | | public class Shareholder implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Integer id; |
| | | /** |
| | | * 股东 |
| | | */ |
| | | @ApiModelProperty(value = "股东") |
| | | private String shareholder; |
| | | /** |
| | | * 持股比例 |
| | | */ |
| | | @ApiModelProperty(value = "持股比例") |
| | | @TableField("shareholdingRatio") |
| | | private String shareholdingratio; |
| | | /** |
| | | * 最终受益股份 |
| | | */ |
| | | @ApiModelProperty(value = "最终受益股份") |
| | | private String beneficial; |
| | | /** |
| | | * 出资金额 |
| | | */ |
| | | @ApiModelProperty(value = "出资金额") |
| | | private String capital; |
| | | /** |
| | | * 出资时间 |
| | | */ |
| | | @ApiModelProperty(value = "出资时间") |
| | | @TableField("capitalTime") |
| | | private LocalDateTime capitaltime; |
| | | /** |
| | | * 身份证 |
| | | */ |
| | | @ApiModelProperty(value = "身份证") |
| | | private Integer cardid; |
| | | /** |
| | | * 联系电话 |
| | | */ |
| | | @ApiModelProperty(value = "联系电话") |
| | | private String cell; |
| | | |
| | | /** |
| | | * 租户ID |
| | | */ |
| | | @ApiModelProperty(value = "租户ID") |
| | | @TableField("tenantId") |
| | | private String tenantid; |
| | | /** |
| | | * 统一社会信用代码 |
| | | */ |
| | | @ApiModelProperty(value = "统一社会信用代码") |
| | | @TableField("creditCode") |
| | | private String creditcode; |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.shareholder.mapper; |
| | | |
| | | import org.springblade.modules.shareholder.entity.Shareholder; |
| | | import org.springblade.modules.shareholder.vo.ShareholderVO; |
| | | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import java.util.List; |
| | | |
| | | /** |
| | | * Mapper 接口 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | public interface ShareholderMapper extends BaseMapper<Shareholder> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param shareholder |
| | | * @return |
| | | */ |
| | | List<ShareholderVO> selectShareholderPage(IPage page, ShareholderVO shareholder); |
| | | |
| | | } |
| New file |
| | |
| | | <?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="org.springblade.modules.shareholder.mapper.ShareholderMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="shareholderResultMap" type="org.springblade.modules.shareholder.entity.Shareholder"> |
| | | <id column="id" property="id"/> |
| | | <result column="shareholder" property="shareholder"/> |
| | | <result column=" |
| | | |
| | | shareholdingRatio" property=" |
| | | |
| | | shareholdingratio"/> |
| | | <result column="beneficial" property="beneficial"/> |
| | | <result column="capital" property="capital"/> |
| | | <result column="capitalTime" property="capitaltime"/> |
| | | <result column="cardid" property="cardid"/> |
| | | <result column="cell" property="cell"/> |
| | | </resultMap> |
| | | |
| | | |
| | | <select id="selectShareholderPage" resultMap="shareholderResultMap"> |
| | | select * from sys_shareholder where is_deleted = 0 |
| | | </select> |
| | | |
| | | </mapper> |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.shareholder.service; |
| | | |
| | | import org.springblade.modules.shareholder.entity.Shareholder; |
| | | import org.springblade.modules.shareholder.vo.ShareholderVO; |
| | | import com.baomidou.mybatisplus.extension.service.IService; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 服务类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | public interface IShareholderService extends IService<Shareholder> { |
| | | |
| | | /** |
| | | * 自定义分页 |
| | | * |
| | | * @param page |
| | | * @param shareholder |
| | | * @return |
| | | */ |
| | | IPage<ShareholderVO> selectShareholderPage(IPage<ShareholderVO> page, ShareholderVO shareholder); |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.shareholder.service.impl; |
| | | |
| | | import org.springblade.modules.shareholder.entity.Shareholder; |
| | | import org.springblade.modules.shareholder.vo.ShareholderVO; |
| | | import org.springblade.modules.shareholder.mapper.ShareholderMapper; |
| | | import org.springblade.modules.shareholder.service.IShareholderService; |
| | | import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | |
| | | /** |
| | | * 服务实现类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Service |
| | | public class ShareholderServiceImpl extends ServiceImpl<ShareholderMapper, Shareholder> implements IShareholderService { |
| | | |
| | | @Override |
| | | public IPage<ShareholderVO> selectShareholderPage(IPage<ShareholderVO> page, ShareholderVO shareholder) { |
| | | return page.setRecords(baseMapper.selectShareholderPage(page, shareholder)); |
| | | } |
| | | |
| | | } |
| New file |
| | |
| | | /* |
| | | * Copyright (c) 2018-2028, Chill Zhuang All rights reserved. |
| | | * |
| | | * Redistribution and use in source and binary forms, with or without |
| | | * modification, are permitted provided that the following conditions are met: |
| | | * |
| | | * Redistributions of source code must retain the above copyright notice, |
| | | * this list of conditions and the following disclaimer. |
| | | * Redistributions in binary form must reproduce the above copyright |
| | | * notice, this list of conditions and the following disclaimer in the |
| | | * documentation and/or other materials provided with the distribution. |
| | | * Neither the name of the dreamlu.net developer nor the names of its |
| | | * contributors may be used to endorse or promote products derived from |
| | | * this software without specific prior written permission. |
| | | * Author: Chill 庄骞 (smallchill@163.com) |
| | | */ |
| | | package org.springblade.modules.shareholder.vo; |
| | | |
| | | import org.springblade.modules.shareholder.entity.Shareholder; |
| | | import lombok.Data; |
| | | import lombok.EqualsAndHashCode; |
| | | import io.swagger.annotations.ApiModel; |
| | | |
| | | /** |
| | | * 视图实体类 |
| | | * |
| | | * @author BladeX |
| | | * @since 2021-07-06 |
| | | */ |
| | | @Data |
| | | @EqualsAndHashCode(callSuper = true) |
| | | @ApiModel(value = "ShareholderVO对象", description = "ShareholderVO对象") |
| | | public class ShareholderVO extends Shareholder { |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | } |