Pre Merge pull request !210 from 毒匠/4.4
This commit is contained in:
commit
86d6af04ac
9
pom.xml
9
pom.xml
|
|
@ -202,6 +202,14 @@
|
|||
<version>${ruoyi.version}</version>
|
||||
</dependency>
|
||||
|
||||
<!--外部依赖 BOM-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-dependencies-bom</artifactId>
|
||||
<version>${ruoyi.version}</version>
|
||||
<type>pom</type>
|
||||
<scope>import</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</dependencyManagement>
|
||||
|
||||
|
|
@ -212,6 +220,7 @@
|
|||
<module>ruoyi-quartz</module>
|
||||
<module>ruoyi-generator</module>
|
||||
<module>ruoyi-common</module>
|
||||
<module>ruoyi-his</module>
|
||||
</modules>
|
||||
<packaging>pom</packaging>
|
||||
|
||||
|
|
|
|||
|
|
@ -79,6 +79,12 @@
|
|||
<artifactId>ruoyi-generator</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- HIS 管理模块-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-his</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
|
|
|
|||
|
|
@ -6,9 +6,9 @@ spring:
|
|||
druid:
|
||||
# 主库数据源
|
||||
master:
|
||||
url: jdbc:mysql://localhost:3306/ry?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: root
|
||||
password: password
|
||||
url: jdbc:mysql://39.97.252.22:3306/ry?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: devry
|
||||
password: Devry@#123
|
||||
# 从库数据源
|
||||
slave:
|
||||
# 从数据源开关/默认关闭
|
||||
|
|
@ -54,4 +54,13 @@ spring:
|
|||
merge-sql: true
|
||||
wall:
|
||||
config:
|
||||
multi-statement-allow: true
|
||||
multi-statement-allow: true
|
||||
|
||||
#HIS WEBSERVICE CONFIG
|
||||
his:
|
||||
client:
|
||||
his-url: http://47.111.29.88:11013/WebService.asmx
|
||||
his-public-url: http://47.111.29.88:11004/webservice.asmx
|
||||
auth-code: 44200F7B173B00E136C04106FB29AA4A
|
||||
his-host: http://127.0.0.1:8082
|
||||
vendor-id: 510303001
|
||||
|
|
@ -80,6 +80,10 @@ mybatis:
|
|||
mapperLocations: classpath*:mapper/**/*Mapper.xml
|
||||
# 加载全局的配置文件
|
||||
configLocation: classpath:mybatis/mybatis-config.xml
|
||||
mapper:
|
||||
mappers: com.ruoyi.common.mappers.RuoYiBaseMapper
|
||||
identity: mysql
|
||||
not-empty: false
|
||||
|
||||
# PageHelper分页插件
|
||||
pagehelper:
|
||||
|
|
@ -111,7 +115,7 @@ shiro:
|
|||
# 设置Cookie的过期时间,天为单位
|
||||
maxAge: 30
|
||||
# 设置密钥,务必保持唯一性(生成方式,直接拷贝到main运行即可)KeyGenerator keygen = KeyGenerator.getInstance("AES"); SecretKey deskey = keygen.generateKey(); System.out.println(Base64.encodeToString(deskey.getEncoded()));
|
||||
cipherKey: zSyK5Kp6PZAAjlT+eeNMlg==
|
||||
cipherKey: +6sYiFMubS5NNEtC9xdMIw==
|
||||
session:
|
||||
# Session超时时间,-1代表永不过期(默认30分钟)
|
||||
expireTime: 30
|
||||
|
|
@ -129,9 +133,9 @@ xss:
|
|||
# 过滤开关
|
||||
enabled: true
|
||||
# 排除链接(多个用逗号分隔)
|
||||
excludes: /system/notice/*
|
||||
excludes: /system/notice/*,/bend/article/*,/bend/agreement/*
|
||||
# 匹配链接
|
||||
urlPatterns: /system/*,/monitor/*,/tool/*
|
||||
urlPatterns: /system/*,/monitor/*,/tool/*,/his/*,/bend/*
|
||||
|
||||
# Swagger配置
|
||||
swagger:
|
||||
|
|
|
|||
|
|
@ -1,24 +1,2 @@
|
|||
Application Version: ${ruoyi.version}
|
||||
Spring Boot Version: ${spring-boot.version}
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// _ooOoo_ //
|
||||
// o8888888o //
|
||||
// 88" . "88 //
|
||||
// (| ^_^ |) //
|
||||
// O\ = /O //
|
||||
// ____/`---'\____ //
|
||||
// .' \\| |// `. //
|
||||
// / \\||| : |||// \ //
|
||||
// / _||||| -:- |||||- \ //
|
||||
// | | \\\ - /// | | //
|
||||
// | \_| ''\---/'' | | //
|
||||
// \ .-\__ `-` ___/-. / //
|
||||
// ___`. .' /--.--\ `. . ___ //
|
||||
// ."" '< `.___\_<|>_/___.' >'"". //
|
||||
// | | : `- \`.;`\ _ /`;.`/ - ` : | | //
|
||||
// \ \ `-. \_ __\ /__ _/ .-` / / //
|
||||
// ========`-.____`-.___\_____/___.-`____.-'======== //
|
||||
// `=---=' //
|
||||
// ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ //
|
||||
// 佛祖保佑 永不宕机 永无BUG //
|
||||
////////////////////////////////////////////////////////////////////
|
||||
Spring Boot Version: ${spring-boot.version}
|
||||
|
|
@ -101,6 +101,27 @@
|
|||
<artifactId>javax.servlet-api</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!--自定义添加Jar依赖:2020/08/30-->
|
||||
<dependency>
|
||||
<groupId>com.bending.core</groupId>
|
||||
<artifactId>bending-his-core</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.google.code.findbugs</groupId>
|
||||
<artifactId>annotations</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>tk.mybatis</groupId>
|
||||
<artifactId>mapper</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
</project>
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
package com.ruoyi.common.annotation;
|
||||
|
||||
import java.lang.annotation.*;
|
||||
|
||||
/**
|
||||
* 自定义 @TraceId
|
||||
*/
|
||||
@Documented
|
||||
@Retention(RetentionPolicy.RUNTIME)
|
||||
@Target(ElementType.METHOD)
|
||||
public @interface TraceId {
|
||||
|
||||
}
|
||||
|
|
@ -5,99 +5,65 @@ import java.util.Date;
|
|||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.persistence.*;
|
||||
|
||||
/**
|
||||
* Entity基类
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
@ApiModel(value = "Entity基类")
|
||||
@Data
|
||||
public class BaseEntity implements Serializable
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty(notes = "主键ID")
|
||||
@Id
|
||||
@Column(name = "id")
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
|
||||
/** 搜索值 */
|
||||
@ApiModelProperty(notes = "搜索值",hidden = true)
|
||||
@Transient
|
||||
private String searchValue;
|
||||
|
||||
/** 创建者 */
|
||||
@ApiModelProperty(notes = "创建者",hidden = true)
|
||||
@Transient
|
||||
private String createBy;
|
||||
|
||||
/** 创建时间 */
|
||||
@ApiModelProperty(notes = "创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date createTime;
|
||||
|
||||
/** 更新者 */
|
||||
@ApiModelProperty(notes = "更新者",hidden = true)
|
||||
@Transient
|
||||
private String updateBy;
|
||||
|
||||
/** 更新时间 */
|
||||
@ApiModelProperty(notes = "更新时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Transient
|
||||
private Date updateTime;
|
||||
|
||||
/** 备注 */
|
||||
@ApiModelProperty(notes = "备注",hidden = true)
|
||||
@Transient
|
||||
private String remark;
|
||||
|
||||
/** 请求参数 */
|
||||
@ApiModelProperty(notes = "请求参数",hidden = true)
|
||||
@Transient
|
||||
private Map<String, Object> params;
|
||||
|
||||
public String getSearchValue()
|
||||
{
|
||||
return searchValue;
|
||||
}
|
||||
|
||||
public void setSearchValue(String searchValue)
|
||||
{
|
||||
this.searchValue = searchValue;
|
||||
}
|
||||
|
||||
public String getCreateBy()
|
||||
{
|
||||
return createBy;
|
||||
}
|
||||
|
||||
public void setCreateBy(String createBy)
|
||||
{
|
||||
this.createBy = createBy;
|
||||
}
|
||||
|
||||
public Date getCreateTime()
|
||||
{
|
||||
return createTime;
|
||||
}
|
||||
|
||||
public void setCreateTime(Date createTime)
|
||||
{
|
||||
this.createTime = createTime;
|
||||
}
|
||||
|
||||
public String getUpdateBy()
|
||||
{
|
||||
return updateBy;
|
||||
}
|
||||
|
||||
public void setUpdateBy(String updateBy)
|
||||
{
|
||||
this.updateBy = updateBy;
|
||||
}
|
||||
|
||||
public Date getUpdateTime()
|
||||
{
|
||||
return updateTime;
|
||||
}
|
||||
|
||||
public void setUpdateTime(Date updateTime)
|
||||
{
|
||||
this.updateTime = updateTime;
|
||||
}
|
||||
|
||||
public String getRemark()
|
||||
{
|
||||
return remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark)
|
||||
{
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
public Map<String, Object> getParams()
|
||||
{
|
||||
if (params == null)
|
||||
|
|
|
|||
|
|
@ -0,0 +1,90 @@
|
|||
package com.ruoyi.common.func;
|
||||
|
||||
import com.ruoyi.common.func.support.FastStringWriter;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import org.apache.commons.lang3.exception.ExceptionUtils;
|
||||
|
||||
import java.io.PrintWriter;
|
||||
import java.io.StringWriter;
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.lang.reflect.UndeclaredThrowableException;
|
||||
|
||||
/**
|
||||
* 错误信息处理类。
|
||||
*
|
||||
* @author ruoyi
|
||||
*/
|
||||
public class ExceptionUtil {
|
||||
/**
|
||||
* 获取exception的详细错误信息。
|
||||
*/
|
||||
public static String getExceptionMessage(Throwable e) {
|
||||
StringWriter sw = new StringWriter();
|
||||
e.printStackTrace(new PrintWriter(sw, true));
|
||||
String str = sw.toString();
|
||||
return str;
|
||||
}
|
||||
|
||||
public static String getRootErrorMseeage(Exception e) {
|
||||
Throwable root = ExceptionUtils.getRootCause(e);
|
||||
root = (root == null ? e : root);
|
||||
if (root == null) {
|
||||
return "";
|
||||
}
|
||||
String msg = root.getMessage();
|
||||
if (msg == null) {
|
||||
return "null";
|
||||
}
|
||||
return StringUtils.defaultString(msg);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将CheckedException转换为UncheckedException.
|
||||
*
|
||||
* @param e Throwable
|
||||
* @return {RuntimeException}
|
||||
*/
|
||||
public static RuntimeException unchecked(Throwable e) {
|
||||
if (e instanceof IllegalAccessException || e instanceof IllegalArgumentException
|
||||
|| e instanceof NoSuchMethodException) {
|
||||
return new IllegalArgumentException(e);
|
||||
} else if (e instanceof InvocationTargetException) {
|
||||
return new RuntimeException(((InvocationTargetException) e).getTargetException());
|
||||
} else if (e instanceof RuntimeException) {
|
||||
return (RuntimeException) e;
|
||||
} else {
|
||||
return new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 代理异常解包
|
||||
*
|
||||
* @param wrapped 包装过得异常
|
||||
* @return 解包后的异常
|
||||
*/
|
||||
public static Throwable unwrap(Throwable wrapped) {
|
||||
Throwable unwrapped = wrapped;
|
||||
while (true) {
|
||||
if (unwrapped instanceof InvocationTargetException) {
|
||||
unwrapped = ((InvocationTargetException) unwrapped).getTargetException();
|
||||
} else if (unwrapped instanceof UndeclaredThrowableException) {
|
||||
unwrapped = ((UndeclaredThrowableException) unwrapped).getUndeclaredThrowable();
|
||||
} else {
|
||||
return unwrapped;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 将ErrorStack转化为String.
|
||||
*
|
||||
* @param ex Throwable
|
||||
* @return {String}
|
||||
*/
|
||||
public static String getStackTraceAsString(Throwable ex) {
|
||||
FastStringWriter stringWriter = new FastStringWriter();
|
||||
ex.printStackTrace(new PrintWriter(stringWriter));
|
||||
return stringWriter.toString();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,842 @@
|
|||
package com.ruoyi.common.func;
|
||||
|
||||
import com.ruoyi.common.func.support.BaseBeanCopier;
|
||||
import com.ruoyi.common.func.support.ConcurrentDateFormat;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.bean.BeanUtils;
|
||||
import org.apache.commons.lang3.math.NumberUtils;
|
||||
import org.springframework.beans.BeansException;
|
||||
import org.springframework.cglib.core.CodeGenerationException;
|
||||
import org.springframework.lang.Nullable;
|
||||
import org.springframework.util.Assert;
|
||||
|
||||
import java.beans.PropertyDescriptor;
|
||||
import java.text.ParseException;
|
||||
import java.time.Duration;
|
||||
import java.time.Instant;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.ZoneId;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.time.temporal.ChronoField;
|
||||
import java.time.temporal.TemporalAmount;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.ThreadLocalRandom;
|
||||
|
||||
/**
|
||||
* 工具包集合,只做简单的调用,不删除原有工具类
|
||||
*
|
||||
* @author L.cm
|
||||
*/
|
||||
public class Func {
|
||||
/**
|
||||
* Check whether the given {@code CharSequence} contains actual <em>text</em>.
|
||||
* <p>More specifically, this method returns {@code true} if the
|
||||
* {@code CharSequence} is not {@code null}, its length is greater than
|
||||
* 0, and it contains at least one non-whitespace character.
|
||||
* <pre class="code">
|
||||
* $.isBlank(null) = true
|
||||
* $.isBlank("") = true
|
||||
* $.isBlank(" ") = true
|
||||
* $.isBlank("12345") = false
|
||||
* $.isBlank(" 12345 ") = false
|
||||
* </pre>
|
||||
*
|
||||
* @param cs the {@code CharSequence} to check (may be {@code null})
|
||||
* @return {@code true} if the {@code CharSequence} is not {@code null},
|
||||
* its length is greater than 0, and it does not contain whitespace only
|
||||
* @see Character#isWhitespace
|
||||
*/
|
||||
public static boolean isBlank(@Nullable final CharSequence cs) {
|
||||
return StringUtils.isBlank(cs);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Checks if a CharSequence is not empty (""), not null and not whitespace only.</p>
|
||||
* <pre>
|
||||
* $.isNotBlank(null) = false
|
||||
* $.isNotBlank("") = false
|
||||
* $.isNotBlank(" ") = false
|
||||
* $.isNotBlank("bob") = true
|
||||
* $.isNotBlank(" bob ") = true
|
||||
* </pre>
|
||||
*
|
||||
* @param cs the CharSequence to check, may be null
|
||||
* @return {@code true} if the CharSequence is
|
||||
* not empty and not null and not whitespace
|
||||
* @see Character#isWhitespace
|
||||
*/
|
||||
public static boolean isNotBlank(@Nullable final CharSequence cs) {
|
||||
return StringUtils.isNotBlank(cs);
|
||||
}
|
||||
|
||||
/**
|
||||
* Determine whether the given object is not empty:
|
||||
* i.e. {@code null} or of zero length.
|
||||
*
|
||||
* @param obj the object to check
|
||||
* @return 是否不为空
|
||||
*/
|
||||
public static boolean isNotEmpty(@Nullable Object obj) {
|
||||
return !ObjectUtil.isEmpty(obj);
|
||||
}
|
||||
|
||||
/**
|
||||
* Determine whether the given array is empty:
|
||||
* i.e. {@code null} or of zero length.
|
||||
*
|
||||
* @param array the array to check
|
||||
* @return 数组是否为空
|
||||
*/
|
||||
public static boolean isEmpty(@Nullable Object[] array) {
|
||||
return ObjectUtil.isEmpty(array);
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为String数组<br>
|
||||
*
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static String[] toStrArray(String str) {
|
||||
return toStrArray(",", str);
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为String数组<br>
|
||||
*
|
||||
* @param split 分隔符
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static String[] toStrArray(String split, String str) {
|
||||
if (isBlank(str)) {
|
||||
return new String[]{};
|
||||
}
|
||||
return str.split(split);
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为String集合<br>
|
||||
*
|
||||
* @param str 结果被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static List<String> toStrList(String str) {
|
||||
return Arrays.asList(toStrArray(str));
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为String集合<br>
|
||||
*
|
||||
* @param split 分隔符
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static List<String> toStrList(String split, String str) {
|
||||
return Arrays.asList(toStrArray(split, str));
|
||||
}
|
||||
|
||||
/**
|
||||
* 清理字符串,清理出某些不可见字符
|
||||
*
|
||||
* @param txt 字符串
|
||||
* @return {String}
|
||||
*/
|
||||
public static String cleanChars(String txt) {
|
||||
return txt.replaceAll("[ `·•<C2B7>\\f\\t\\v\\s]", "");
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert a {@code Collection} into a delimited {@code String} (e.g., CSV).
|
||||
* <p>Useful for {@code toString()} implementations.
|
||||
*
|
||||
* @param coll the {@code Collection} to convert
|
||||
* @return the delimited {@code String}
|
||||
*/
|
||||
public static String join(Collection<?> coll) {
|
||||
return StringUtils.join(coll);
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert a {@code Collection} into a delimited {@code String} (e.g. CSV).
|
||||
* <p>Useful for {@code toString()} implementations.
|
||||
*
|
||||
* @param coll the {@code Collection} to convert
|
||||
* @param delim the delimiter to use (typically a ",")
|
||||
* @return the delimited {@code String}
|
||||
*/
|
||||
public static String join(Collection<?> coll, String delim) {
|
||||
return StringUtils.join(coll, delim);
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert a {@code String} array into a comma delimited {@code String}
|
||||
* (i.e., CSV).
|
||||
* <p>Useful for {@code toString()} implementations.
|
||||
*
|
||||
* @param arr the array to display
|
||||
* @return the delimited {@code String}
|
||||
*/
|
||||
public static String join(Object[] arr) {
|
||||
return StringUtils.join(arr);
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert a {@code String} array into a delimited {@code String} (e.g. CSV).
|
||||
* <p>Useful for {@code toString()} implementations.
|
||||
*
|
||||
* @param arr the array to display
|
||||
* @param delim the delimiter to use (typically a ",")
|
||||
* @return the delimited {@code String}
|
||||
*/
|
||||
public static String join(Object[] arr, String delim) {
|
||||
return StringUtils.join(arr, delim);
|
||||
}
|
||||
|
||||
/**
|
||||
* Trim leading and trailing whitespace from the given {@code String}.
|
||||
*
|
||||
* @param str the {@code String} to check
|
||||
* @return the trimmed {@code String}
|
||||
* @see java.lang.Character#isWhitespace
|
||||
*/
|
||||
public static String trimWhitespace(String str) {
|
||||
if (!hasLength(str)) {
|
||||
return str;
|
||||
}
|
||||
|
||||
int beginIndex = 0;
|
||||
int endIndex = str.length() - 1;
|
||||
|
||||
while (beginIndex <= endIndex && Character.isWhitespace(str.charAt(beginIndex))) {
|
||||
beginIndex++;
|
||||
}
|
||||
|
||||
while (endIndex > beginIndex && Character.isWhitespace(str.charAt(endIndex))) {
|
||||
endIndex--;
|
||||
}
|
||||
|
||||
return str.substring(beginIndex, endIndex + 1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Check that the given {@code String} is neither {@code null} nor of length 0.
|
||||
* <p>Note: this method returns {@code true} for a {@code String} that
|
||||
* purely consists of whitespace.
|
||||
*
|
||||
* @param str the {@code String} to check (may be {@code null})
|
||||
* @return {@code true} if the {@code String} is not {@code null} and has length
|
||||
*/
|
||||
public static boolean hasLength(@Nullable String str) {
|
||||
return (str != null && !str.isEmpty());
|
||||
}
|
||||
|
||||
/**
|
||||
* copy 对象属性到另一个对象,默认不使用Convert
|
||||
* <p>
|
||||
* 注意:不支持链式Bean,链式用 copyProperties
|
||||
*
|
||||
* @param source 源对象
|
||||
* @param clazz 类名
|
||||
* @param <T> 泛型标记
|
||||
* @return T
|
||||
*/
|
||||
public static <T> T copy(Object source, Class<T> clazz) {
|
||||
BaseBeanCopier copier = BaseBeanCopier.create(source.getClass(), clazz, false);
|
||||
T to = org.springframework.beans.BeanUtils.instantiateClass(clazz);
|
||||
copier.copy(source, to, null);
|
||||
return to;
|
||||
}
|
||||
|
||||
/**
|
||||
* 拷贝对象
|
||||
* <p>
|
||||
* 注意:不支持链式Bean,链式用 copyProperties
|
||||
*
|
||||
* @param source 源对象
|
||||
* @param targetBean 需要赋值的对象
|
||||
*/
|
||||
public static void copy(Object source, Object targetBean) {
|
||||
BaseBeanCopier copier = BaseBeanCopier.create(source.getClass(), targetBean.getClass(), false);
|
||||
copier.copy(source, targetBean, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断一个字符串是否是数字
|
||||
*
|
||||
* @param cs the CharSequence to check, may be null
|
||||
* @return {boolean}
|
||||
*/
|
||||
public static boolean isNumeric(final CharSequence cs) {
|
||||
return StringUtils.isNumeric(cs);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>int</code>, returning
|
||||
* <code>zero</code> if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, <code>zero</code> is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toInt(null) = 0
|
||||
* $.toInt("") = 0
|
||||
* $.toInt("1") = 1
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @return the int represented by the string, or <code>zero</code> if
|
||||
* conversion fails
|
||||
*/
|
||||
public static int toInt(final Object value) {
|
||||
return NumberUtils.toInt(String.valueOf(value));
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>int</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toInt(null, 1) = 1
|
||||
* $.toInt("", 1) = 1
|
||||
* $.toInt("1", 0) = 1
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @param defaultValue the default value
|
||||
* @return the int represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static int toInt(final Object value, final int defaultValue) {
|
||||
return NumberUtils.toInt(String.valueOf(value), defaultValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to a <code>long</code>, returning
|
||||
* <code>zero</code> if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, <code>zero</code> is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toLong(null) = 0L
|
||||
* $.toLong("") = 0L
|
||||
* $.toLong("1") = 1L
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @return the long represented by the string, or <code>0</code> if
|
||||
* conversion fails
|
||||
*/
|
||||
public static long toLong(final Object value) {
|
||||
return NumberUtils.toLong(String.valueOf(value));
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to a <code>long</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toLong(null, 1L) = 1L
|
||||
* $.toLong("", 1L) = 1L
|
||||
* $.toLong("1", 0L) = 1L
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @param defaultValue the default value
|
||||
* @return the long represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static long toLong(final Object value, final long defaultValue) {
|
||||
return NumberUtils.toLong(String.valueOf(value), defaultValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>Double</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toDouble(null, 1) = 1.0
|
||||
* $.toDouble("", 1) = 1.0
|
||||
* $.toDouble("1", 0) = 1.0
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @return the int represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static Double toDouble(Object value) {
|
||||
return toDouble(String.valueOf(value), -1.00);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>Double</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toDouble(null, 1) = 1.0
|
||||
* $.toDouble("", 1) = 1.0
|
||||
* $.toDouble("1", 0) = 1.0
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @param defaultValue the default value
|
||||
* @return the int represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static Double toDouble(Object value, Double defaultValue) {
|
||||
return NumberUtils.toDouble(String.valueOf(value), defaultValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>Float</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toFloat(null, 1) = 1.00f
|
||||
* $.toFloat("", 1) = 1.00f
|
||||
* $.toFloat("1", 0) = 1.00f
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @return the int represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static Float toFloat(Object value) {
|
||||
return toFloat(String.valueOf(value), -1.0f);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>Float</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toFloat(null, 1) = 1.00f
|
||||
* $.toFloat("", 1) = 1.00f
|
||||
* $.toFloat("1", 0) = 1.00f
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @param defaultValue the default value
|
||||
* @return the int represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static Float toFloat(Object value, Float defaultValue) {
|
||||
return NumberUtils.toFloat(String.valueOf(value), defaultValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>Boolean</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toBoolean("true", true) = true
|
||||
* $.toBoolean("false") = false
|
||||
* $.toBoolean("", false) = false
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @return the int represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static Boolean toBoolean(Object value) {
|
||||
return toBoolean(value, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* <p>Convert a <code>String</code> to an <code>Boolean</code>, returning a
|
||||
* default value if the conversion fails.</p>
|
||||
*
|
||||
* <p>If the string is <code>null</code>, the default value is returned.</p>
|
||||
*
|
||||
* <pre>
|
||||
* $.toBoolean("true", true) = true
|
||||
* $.toBoolean("false") = false
|
||||
* $.toBoolean("", false) = false
|
||||
* </pre>
|
||||
*
|
||||
* @param value the string to convert, may be null
|
||||
* @param defaultValue the default value
|
||||
* @return the int represented by the string, or the default if conversion fails
|
||||
*/
|
||||
public static Boolean toBoolean(Object value, Boolean defaultValue) {
|
||||
if (value != null) {
|
||||
String val = String.valueOf(value);
|
||||
val = val.toLowerCase().trim();
|
||||
return Boolean.parseBoolean(val);
|
||||
}
|
||||
return defaultValue;
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Integer数组<br>
|
||||
*
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static Integer[] toIntArray(String str) {
|
||||
return toIntArray(",", str);
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Integer数组<br>
|
||||
*
|
||||
* @param split 分隔符
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static Integer[] toIntArray(String split, String str) {
|
||||
if (StringUtils.isEmpty(str)) {
|
||||
return new Integer[]{};
|
||||
}
|
||||
String[] arr = str.split(split);
|
||||
final Integer[] ints = new Integer[arr.length];
|
||||
for (int i = 0; i < arr.length; i++) {
|
||||
final int v = toInt(arr[i], 0);
|
||||
ints[i] = v;
|
||||
}
|
||||
return ints;
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Integer集合<br>
|
||||
*
|
||||
* @param str 结果被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static List<Integer> toIntList(String str) {
|
||||
return Arrays.asList(toIntArray(str));
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Integer集合<br>
|
||||
*
|
||||
* @param split 分隔符
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static List<Integer> toIntList(String split, String str) {
|
||||
return Arrays.asList(toIntArray(split, str));
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Long数组<br>
|
||||
*
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static Long[] toLongArray(String str) {
|
||||
return toLongArray(",", str);
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Long数组<br>
|
||||
*
|
||||
* @param split 分隔符
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static Long[] toLongArray(String split, String str) {
|
||||
if (StringUtils.isEmpty(str)) {
|
||||
return new Long[]{};
|
||||
}
|
||||
String[] arr = str.split(split);
|
||||
final Long[] longs = new Long[arr.length];
|
||||
for (int i = 0; i < arr.length; i++) {
|
||||
final Long v = toLong(arr[i], 0);
|
||||
longs[i] = v;
|
||||
}
|
||||
return longs;
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Long集合<br>
|
||||
*
|
||||
* @param str 结果被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static List<Long> toLongList(String str) {
|
||||
return Arrays.asList(toLongArray(str));
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换为Long集合<br>
|
||||
*
|
||||
* @param split 分隔符
|
||||
* @param str 被转换的值
|
||||
* @return 结果
|
||||
*/
|
||||
public static List<Long> toLongList(String split, String str) {
|
||||
return Arrays.asList(toLongArray(split, str));
|
||||
}
|
||||
|
||||
/**
|
||||
* 强转string,并去掉多余空格
|
||||
*
|
||||
* @param str 字符串
|
||||
* @return String
|
||||
*/
|
||||
public static String toStr(Object str) {
|
||||
return toStr(str, "");
|
||||
}
|
||||
|
||||
/**
|
||||
* 强转string,并去掉多余空格
|
||||
*
|
||||
* @param str 字符串
|
||||
* @param defaultValue 默认值
|
||||
* @return String
|
||||
*/
|
||||
public static String toStr(Object str, String defaultValue) {
|
||||
if (null == str) {
|
||||
return defaultValue;
|
||||
}
|
||||
return String.valueOf(str);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取 Bean 的所有 get方法
|
||||
*
|
||||
* @param type 类
|
||||
* @return PropertyDescriptor数组
|
||||
*/
|
||||
public static PropertyDescriptor[] getBeanGetters(Class type) {
|
||||
return getPropertiesHelper(type, true, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取 Bean 的所有 set方法
|
||||
*
|
||||
* @param type 类
|
||||
* @return PropertyDescriptor数组
|
||||
*/
|
||||
public static PropertyDescriptor[] getBeanSetters(Class type) {
|
||||
return getPropertiesHelper(type, false, true);
|
||||
}
|
||||
|
||||
private static PropertyDescriptor[] getPropertiesHelper(Class type, boolean read, boolean write) {
|
||||
try {
|
||||
PropertyDescriptor[] all = BeanUtils.getPropertyDescriptors(type);
|
||||
if (read && write) {
|
||||
return all;
|
||||
} else {
|
||||
List<PropertyDescriptor> properties = new ArrayList<>(all.length);
|
||||
for (PropertyDescriptor pd : all) {
|
||||
if (read && pd.getReadMethod() != null) {
|
||||
properties.add(pd);
|
||||
} else if (write && pd.getWriteMethod() != null) {
|
||||
properties.add(pd);
|
||||
}
|
||||
}
|
||||
return properties.toArray(new PropertyDescriptor[0]);
|
||||
}
|
||||
} catch (BeansException ex) {
|
||||
throw new CodeGenerationException(ex);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期减少时间量
|
||||
*
|
||||
* @param date 时间
|
||||
* @param amount 时间量
|
||||
* @return 设置后的时间
|
||||
*/
|
||||
public static Date minus(Date date, TemporalAmount amount) {
|
||||
Instant instant = date.toInstant();
|
||||
return Date.from(instant.minus(amount));
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期添加时间量
|
||||
*
|
||||
* @param date 时间
|
||||
* @param amount 时间量
|
||||
* @return 设置后的时间
|
||||
*/
|
||||
public static Date plus(Date date, TemporalAmount amount) {
|
||||
Instant instant = date.toInstant();
|
||||
return Date.from(instant.plus(amount));
|
||||
}
|
||||
|
||||
/**
|
||||
* 添加天
|
||||
*
|
||||
* @param date 时间
|
||||
* @param daysToAdd 添加的天数
|
||||
* @return 设置后的时间
|
||||
*/
|
||||
public static Date plusDays(Date date, long daysToAdd) {
|
||||
return plus(date, Duration.ofDays(daysToAdd));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 减少天
|
||||
*
|
||||
* @param date 时间
|
||||
* @param days 减少的天数
|
||||
* @return 设置后的时间
|
||||
*/
|
||||
public static Date minusDays(Date date, long days) {
|
||||
return minus(date, Duration.ofDays(days));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据小时判断是否为上午、中午、下午
|
||||
*/
|
||||
public static String getDuringDay(LocalDateTime localDateTime) {
|
||||
int i = localDateTime.get(ChronoField.AMPM_OF_DAY);
|
||||
return i == 0 ? "上午" : "下午";
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据小时判断是否为上午、中午、下午
|
||||
*/
|
||||
public static String getDuringDay(Date date) {
|
||||
LocalDateTime localDateTime = fromDate(date);
|
||||
return getDuringDay(localDateTime);
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换成java8 时间
|
||||
*
|
||||
* @param date Date
|
||||
* @return LocalDateTime
|
||||
*/
|
||||
public static LocalDateTime fromDate(final Date date) {
|
||||
return LocalDateTime.ofInstant(date.toInstant(), ZoneId.systemDefault());
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期格式化:yyyy-MM-dd HH:mm:ss
|
||||
*
|
||||
* @param date 时间,
|
||||
* @return 格式化后的时间 ,yyyy-MM-dd HH:mm:ss
|
||||
*/
|
||||
public static String formatDate(Date date) {
|
||||
return ConcurrentDateFormat.of(DateUtils.YYYY_MM_DD_HH_MM_SS).format(date);
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期格式化:yyyy-MM-dd HH:mm:ss
|
||||
*
|
||||
* @param date 时间
|
||||
* @return 格式化后的时间, yyyy-MM-dd HH:mm:ss
|
||||
*/
|
||||
public static String formatDate(LocalDateTime date) {
|
||||
return DateTimeFormatter.ofPattern(DateUtils.YYYY_MM_DD_HH_MM_SS).format(date);
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期格式化
|
||||
*
|
||||
* @param date 时间
|
||||
* @param pattern 格式
|
||||
* @return 格式化后的时间
|
||||
*/
|
||||
public static String formatDate(Date date, String pattern) {
|
||||
return ConcurrentDateFormat.of(pattern).format(date);
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期格式化
|
||||
*
|
||||
* @param date 时间
|
||||
* @param pattern 格式
|
||||
* @return 格式化后的时间
|
||||
*/
|
||||
public static String formatDate(LocalDateTime date, String pattern) {
|
||||
return DateTimeFormatter.ofPattern(pattern).format(date);
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期时间格式化
|
||||
*
|
||||
* @param date 时间
|
||||
* @return 格式化后的时间
|
||||
*/
|
||||
public static String formatDateTime(Date date) {
|
||||
return ConcurrentDateFormat.of(DateUtils.YYYY_MM_DD_HH_MM_SS).format(date);
|
||||
}
|
||||
|
||||
/**
|
||||
* 日期时间格式化
|
||||
*
|
||||
* @param date 时间
|
||||
* @return 格式化后的时间
|
||||
*/
|
||||
public static String formatDateTime(LocalDateTime date) {
|
||||
return DateTimeFormatter.ofPattern(DateUtils.YYYY_MM_DD_HH_MM_SS).format(date);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将字符串转换为时间
|
||||
*
|
||||
* @param dateStr 时间字符串
|
||||
* @param pattern 表达式
|
||||
* @return 时间
|
||||
*/
|
||||
public static Date parse(String dateStr, String pattern) {
|
||||
ConcurrentDateFormat format = ConcurrentDateFormat.of(pattern);
|
||||
try {
|
||||
return format.parse(dateStr);
|
||||
} catch (ParseException e) {
|
||||
throw ExceptionUtil.unchecked(e);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 将字符串转换为时间
|
||||
*
|
||||
* @param dateStr 时间字符串
|
||||
* @param format ConcurrentDateFormat
|
||||
* @return 时间
|
||||
*/
|
||||
public static Date parse(String dateStr, ConcurrentDateFormat format) {
|
||||
try {
|
||||
return format.parse(dateStr);
|
||||
} catch (ParseException e) {
|
||||
throw ExceptionUtil.unchecked(e);
|
||||
}
|
||||
}
|
||||
|
||||
private static final String S_INT = "0123456789";
|
||||
private static final String S_STR = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
|
||||
private static final String S_ALL = S_INT + S_STR;
|
||||
|
||||
/**
|
||||
* 随机数生成
|
||||
*
|
||||
* @param count 字符长度
|
||||
* @param randomType 随机数类别
|
||||
* @return 随机数
|
||||
*/
|
||||
public static String random(int count, RandomType randomType) {
|
||||
if (count == 0) {
|
||||
return "";
|
||||
}
|
||||
Assert.isTrue(count > 0, "Requested random string length " + count + " is less than 0.");
|
||||
final ThreadLocalRandom random = ThreadLocalRandom.current();
|
||||
char[] buffer = new char[count];
|
||||
for (int i = 0; i < count; i++) {
|
||||
if (RandomType.INT == randomType) {
|
||||
buffer[i] = S_INT.charAt(random.nextInt(S_INT.length()));
|
||||
} else if (RandomType.STRING == randomType) {
|
||||
buffer[i] = S_STR.charAt(random.nextInt(S_STR.length()));
|
||||
} else {
|
||||
buffer[i] = S_ALL.charAt(random.nextInt(S_ALL.length()));
|
||||
}
|
||||
}
|
||||
return new String(buffer);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,26 @@
|
|||
package com.ruoyi.common.func;
|
||||
|
||||
public enum IConstant {
|
||||
MINUS_ONE(-1),
|
||||
ZERO(0),
|
||||
ONE(1),
|
||||
TWO(2),
|
||||
THREE(3),
|
||||
FOURTH(4),
|
||||
FIFTH(5),
|
||||
SIXTH(6),
|
||||
SEVENTH(7),
|
||||
EIGHTH(8),
|
||||
NINTH(9),
|
||||
TENTH(10);
|
||||
|
||||
private int value;
|
||||
|
||||
private IConstant(int value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public int getValue() {
|
||||
return this.value;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,262 @@
|
|||
package com.ruoyi.common.func;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import java.text.ParseException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Calendar;
|
||||
import java.util.GregorianCalendar;
|
||||
import java.util.Hashtable;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
/**
|
||||
* 身份证号码的格式:610821-20061222-612-X 由18位数字组成:前6位为地址码,第7至14位为出生日期码,第15至17位为顺序码,
|
||||
* 第18位为校验码。检验码分别是0-10共11个数字,当检验码为“10”时,为了保证公民身份证号码18位,所以用“X”表示。虽然校验码为“X”不能更换,但若需全用数字表示,只需将18位公民身份号码转换成15位居民身份证号码,去掉第7至8位和最后1位3个数码。
|
||||
* 当今的身份证号码有15位和18位之分。1985年我国实行居民身份证制度,当时签发的身份证号码是15位的,1999年签发的身份证由于年份的扩展(由两位变为四位)和末尾加了效验码,就成了18位。
|
||||
* (1)前1、2位数字表示:所在省份的代码;
|
||||
* (2)第3、4位数字表示:所在城市的代码;
|
||||
* (3)第5、6位数字表示:所在区县的代码;
|
||||
* (4)第7~14位数字表示:出生年、月、日;
|
||||
* (5)第15、16位数字表示:所在地的派出所的代码;
|
||||
* (6)第17位数字表示性别:奇数表示男性,偶数表示女性
|
||||
* (7)第18位数字是校检码:根据一定算法生成
|
||||
* <p>
|
||||
* ————————————————
|
||||
* 版权声明:本文为CSDN博主「mazaiting」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
|
||||
* 原文链接:https://blog.csdn.net/mazaiting/article/details/79707923=
|
||||
*/
|
||||
public class IdCardUtil {
|
||||
|
||||
private static final Logger logger = LoggerFactory.getLogger(IdCardUtil.class);
|
||||
/**
|
||||
* 身份证有效
|
||||
*/
|
||||
private static final String VALIDITY = "该身份证有效!";
|
||||
/**
|
||||
* 位数不足
|
||||
*/
|
||||
private static final String LACKDIGITS = "身份证号码长度应该为15位或18位。";
|
||||
/**
|
||||
* 最后一位应为数字
|
||||
*/
|
||||
private static final String LASTOFNUMBER = "身份证15位号码都应为数字 ; 18位号码除最后一位外,都应为数字。";
|
||||
/**
|
||||
* 出生日期无效
|
||||
*/
|
||||
private static final String INVALIDBIRTH = "身份证出生日期无效。";
|
||||
/**
|
||||
* 生日不在有效范围
|
||||
*/
|
||||
private static final String INVALIDSCOPE = "身份证生日不在有效范围。";
|
||||
/**
|
||||
* 月份无效
|
||||
*/
|
||||
private static final String INVALIDMONTH = "身份证月份无效";
|
||||
/**
|
||||
* 日期无效
|
||||
*/
|
||||
private static final String INVALIDDAY = "身份证日期无效";
|
||||
/**
|
||||
* 身份证地区编码错误
|
||||
*/
|
||||
private static final String CODINGERROR = "身份证地区编码错误。";
|
||||
/**
|
||||
* 身份证校验码无效
|
||||
*/
|
||||
private static final String INVALIDCALIBRATION = "身份证校验码无效,不是合法的身份证号码";
|
||||
|
||||
/**
|
||||
* 检验身份证号码是否符合规范
|
||||
*
|
||||
* @param IDStr 身份证号码
|
||||
* @return 错误信息或成功信息
|
||||
*/
|
||||
public static boolean validate(String IDStr) {
|
||||
String tipMsg = VALIDITY;// 记录错误信息
|
||||
String Ai = "";
|
||||
// 判断号码的长度 15位或18位
|
||||
if (IDStr.length() != 15 && IDStr.length() != 18) {
|
||||
tipMsg = LACKDIGITS;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
|
||||
// 18位身份证前17位位数字,如果是15位的身份证则所有号码都为数字
|
||||
if (IDStr.length() == 18) Ai = IDStr.substring(0, 17);
|
||||
if (IDStr.length() == 15) Ai = IDStr.substring(0, 6) + "19" + IDStr.substring(6, 15);
|
||||
if (!isNumeric(Ai)) {
|
||||
tipMsg = LASTOFNUMBER;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
|
||||
// 判断出生年月是否有效
|
||||
String strYear = Ai.substring(6, 10);// 年份
|
||||
String strMonth = Ai.substring(10, 12);// 月份
|
||||
String strDay = Ai.substring(12, 14);// 日期
|
||||
if (!isDate(strYear + "-" + strMonth + "-" + strDay)) {
|
||||
tipMsg = INVALIDBIRTH;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
GregorianCalendar gc = new GregorianCalendar();
|
||||
SimpleDateFormat s = new SimpleDateFormat("yyyy-MM-dd");
|
||||
try {
|
||||
if ((gc.get(Calendar.YEAR) - Integer.parseInt(strYear)) > 150
|
||||
|| (gc.getTime().getTime() - s.parse(strYear + "-" + strMonth + "-" + strDay).getTime()) < 0) {
|
||||
tipMsg = INVALIDSCOPE;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
} catch (NumberFormatException | ParseException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
if (Integer.parseInt(strMonth) > 12 || Integer.parseInt(strMonth) == 0) {
|
||||
tipMsg = INVALIDMONTH;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
if (Integer.parseInt(strDay) > 31 || Integer.parseInt(strDay) == 0) {
|
||||
tipMsg = INVALIDDAY;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
// 判断地区码是否有效
|
||||
Hashtable<String, String> areaCode = getAreaCode();
|
||||
// 如果身份证前两位的地区码不在Hashtable,则地区码有误
|
||||
if (areaCode.get(Ai.substring(0, 2)) == null) {
|
||||
tipMsg = CODINGERROR;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
if (!isVerifyCode(Ai, IDStr)) {
|
||||
tipMsg = INVALIDCALIBRATION;
|
||||
logger.error("{}:{}", IDStr, tipMsg);
|
||||
return false;
|
||||
}
|
||||
//logger.debug("{}:{}", IDStr, tipMsg);
|
||||
return true;
|
||||
}
|
||||
|
||||
/*
|
||||
* 判断第18位校验码是否正确 第18位校验码的计算方式:
|
||||
* 1. 对前17位数字本体码加权求和 公式为:S = Sum(Ai * Wi), i =
|
||||
* 0, ... , 16 其中Ai表示第i个位置上的身份证号码数字值,Wi表示第i位置上的加权因子,其各位对应的值依次为: 7 9 10 5 8 4
|
||||
* 2 1 6 3 7 9 10 5 8 4 2
|
||||
* 2. 用11对计算结果取模 Y = mod(S, 11)
|
||||
* 3. 根据模的值得到对应的校验码
|
||||
* 对应关系为: Y值: 0 1 2 3 4 5 6 7 8 9 10 校验码: 1 0 X 9 8 7 6 5 4 3 2
|
||||
*/
|
||||
private static boolean isVerifyCode(String Ai, String IDStr) {
|
||||
String[] verifyCode = {"1", "0", "X", "9", "8", "7", "6", "5", "4", "3", "2"};
|
||||
String[] Wi = {"7", "9", "10", "5", "8", "4", "2", "1", "6", "3", "7", "9", "10", "5", "8", "4", "2"};
|
||||
int sum = 0;
|
||||
for (int i = 0; i < 17; i++) {
|
||||
sum = sum + Integer.parseInt(String.valueOf(Ai.charAt(i))) * Integer.parseInt(Wi[i]);
|
||||
}
|
||||
int modValue = sum % 11;
|
||||
String strVerifyCode = verifyCode[modValue];
|
||||
Ai = Ai + strVerifyCode;
|
||||
if (IDStr.length() == 18) {
|
||||
return Ai.equals(IDStr);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* 将所有地址编码保存在一个Hashtable中
|
||||
*
|
||||
* @return Hashtable 对象
|
||||
*/
|
||||
|
||||
private static Hashtable<String, String> getAreaCode() {
|
||||
Hashtable<String, String> hashtable = new Hashtable<String, String>();
|
||||
hashtable.put("11", "北京");
|
||||
hashtable.put("12", "天津");
|
||||
hashtable.put("13", "河北");
|
||||
hashtable.put("14", "山西");
|
||||
hashtable.put("15", "内蒙古");
|
||||
hashtable.put("21", "辽宁");
|
||||
hashtable.put("22", "吉林");
|
||||
hashtable.put("23", "黑龙江");
|
||||
hashtable.put("31", "上海");
|
||||
hashtable.put("32", "江苏");
|
||||
hashtable.put("33", "浙江");
|
||||
hashtable.put("34", "安徽");
|
||||
hashtable.put("35", "福建");
|
||||
hashtable.put("36", "江西");
|
||||
hashtable.put("37", "山东");
|
||||
hashtable.put("41", "河南");
|
||||
hashtable.put("42", "湖北");
|
||||
hashtable.put("43", "湖南");
|
||||
hashtable.put("44", "广东");
|
||||
hashtable.put("45", "广西");
|
||||
hashtable.put("46", "海南");
|
||||
hashtable.put("50", "重庆");
|
||||
hashtable.put("51", "四川");
|
||||
hashtable.put("52", "贵州");
|
||||
hashtable.put("53", "云南");
|
||||
hashtable.put("54", "西藏");
|
||||
hashtable.put("61", "陕西");
|
||||
hashtable.put("62", "甘肃");
|
||||
hashtable.put("63", "青海");
|
||||
hashtable.put("64", "宁夏");
|
||||
hashtable.put("65", "新疆");
|
||||
hashtable.put("71", "台湾");
|
||||
hashtable.put("81", "香港");
|
||||
hashtable.put("82", "澳门");
|
||||
hashtable.put("91", "国外");
|
||||
return hashtable;
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断字符串是否为数字,0-9重复0次或者多次
|
||||
*
|
||||
* @param strNum
|
||||
* @return true, 符合; false, 不符合。
|
||||
*/
|
||||
private static boolean isNumeric(String strNum) {
|
||||
Pattern pattern = Pattern.compile("[0-9]*");
|
||||
Matcher isNum = pattern.matcher(strNum);
|
||||
return isNum.matches();
|
||||
}
|
||||
|
||||
/**
|
||||
* 功能:判断字符串出生日期是否符合正则表达式:包括年月日,闰年、平年和每月31天、30天和闰月的28天或者29天
|
||||
*
|
||||
* @param strDate
|
||||
* @return true, 符合; false, 不符合。
|
||||
*/
|
||||
public static boolean isDate(String strDate) {
|
||||
Pattern pattern = Pattern.compile(
|
||||
"^((\\d{2}(([02468][048])|([13579][26]))[\\-\\/\\s]?((((0?[13578])|(1[02]))[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])))))|(\\d{2}(([02468][1235679])|([13579][01345789]))[\\-\\/\\s]?((((0?[13578])|(1[02]))[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])|(3[01])))|(((0?[469])|(11))[\\-\\/\\s]?((0?[1-9])|([1-2][0-9])|(30)))|(0?2[\\-\\/\\s]?((0?[1-9])|(1[0-9])|(2[0-8]))))))?$");
|
||||
Matcher m = pattern.matcher(strDate);
|
||||
return m.matches();
|
||||
}
|
||||
|
||||
/***
|
||||
* 性别判断 可以根据身份证号码的第十七位判断性别,如果为奇数则为男性,偶数则为女性。
|
||||
* @param IDStr 身份证
|
||||
* @return 0:未知,1:男,2:女
|
||||
*/
|
||||
public static Integer verifyGender(String IDStr) {
|
||||
IDStr = IDStr.trim();
|
||||
if (IDStr.length() == 15) {
|
||||
if (Integer.parseInt(IDStr.substring(14, 15)) % 2 == 0) {
|
||||
return 2;
|
||||
} else {
|
||||
return 1;
|
||||
}
|
||||
} else if (IDStr.length() == 18) {
|
||||
if (Integer.parseInt(IDStr.substring(16).substring(0, 1)) % 2 == 0) {
|
||||
return 2;
|
||||
} else {
|
||||
return 1;
|
||||
}
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
package com.ruoyi.common.func;
|
||||
|
||||
import org.springframework.lang.Nullable;
|
||||
|
||||
/**
|
||||
* 对象工具类
|
||||
*
|
||||
* @author L.cm
|
||||
*/
|
||||
public class ObjectUtil extends org.springframework.util.ObjectUtils {
|
||||
|
||||
/**
|
||||
* 判断元素不为空
|
||||
*
|
||||
* @param obj object
|
||||
* @return boolean
|
||||
*/
|
||||
public static boolean isNotEmpty(@Nullable Object obj) {
|
||||
return !ObjectUtil.isEmpty(obj);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
package com.ruoyi.common.func;
|
||||
|
||||
/**
|
||||
* 生成的随机数类型
|
||||
*
|
||||
* @author L.cm
|
||||
*/
|
||||
public enum RandomType {
|
||||
/**
|
||||
* INT STRING ALL
|
||||
*/
|
||||
INT, STRING, ALL
|
||||
}
|
||||
|
|
@ -0,0 +1,74 @@
|
|||
package com.ruoyi.common.func;
|
||||
|
||||
/**
|
||||
* 静态 String 池
|
||||
*
|
||||
* @author L.cm
|
||||
*/
|
||||
public interface StringPool {
|
||||
|
||||
String AMPERSAND = "&";
|
||||
String AND = "and";
|
||||
String AT = "@";
|
||||
String ASTERISK = "*";
|
||||
String STAR = ASTERISK;
|
||||
String SLASH = "/";
|
||||
char BACK_SLASH = '\\';
|
||||
String DOUBLE_SLASH = "#//";
|
||||
String COLON = ":";
|
||||
String COMMA = ",";
|
||||
String DASH = "-";
|
||||
String DOLLAR = "$";
|
||||
String DOT = ".";
|
||||
String EMPTY = "";
|
||||
String EMPTY_JSON = "{}";
|
||||
String EQUALS = "=";
|
||||
String FALSE = "false";
|
||||
String HASH = "#";
|
||||
String HAT = "^";
|
||||
String LEFT_BRACE = "{";
|
||||
String LEFT_BRACKET = "(";
|
||||
String LEFT_CHEV = "<";
|
||||
String NEWLINE = "\n";
|
||||
String N = "n";
|
||||
String NO = "no";
|
||||
String NULL = "null";
|
||||
String OFF = "off";
|
||||
String ON = "on";
|
||||
String PERCENT = "%";
|
||||
String PIPE = "|";
|
||||
String PLUS = "+";
|
||||
String QUESTION_MARK = "?";
|
||||
String EXCLAMATION_MARK = "!";
|
||||
String QUOTE = "\"";
|
||||
String RETURN = "\r";
|
||||
String TAB = "\t";
|
||||
String RIGHT_BRACE = "}";
|
||||
String RIGHT_BRACKET = ")";
|
||||
String RIGHT_CHEV = ">";
|
||||
String SEMICOLON = ";";
|
||||
String SINGLE_QUOTE = "'";
|
||||
String BACKTICK = "`";
|
||||
String SPACE = " ";
|
||||
String TILDA = "~";
|
||||
String LEFT_SQ_BRACKET = "[";
|
||||
String RIGHT_SQ_BRACKET = "]";
|
||||
String TRUE = "true";
|
||||
String UNDERSCORE = "_";
|
||||
String UTF_8 = "UTF-8";
|
||||
String GBK = "GBK";
|
||||
String ISO_8859_1 = "ISO-8859-1";
|
||||
String Y = "y";
|
||||
String YES = "yes";
|
||||
String ONE = "1";
|
||||
String ZERO = "0";
|
||||
String DOLLAR_LEFT_BRACE= "${";
|
||||
char U_A = 'A';
|
||||
char L_A = 'a';
|
||||
char U_Z = 'Z';
|
||||
char L_Z = 'z';
|
||||
String UNKNOWN = "unknown";
|
||||
String GET = "GET";
|
||||
String POST = "POST";
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,196 @@
|
|||
package com.ruoyi.common.func.support;
|
||||
|
||||
import com.ruoyi.common.func.Func;
|
||||
import org.springframework.asm.ClassVisitor;
|
||||
import org.springframework.asm.Type;
|
||||
import org.springframework.cglib.core.*;
|
||||
|
||||
import java.beans.PropertyDescriptor;
|
||||
import java.lang.reflect.Modifier;
|
||||
import java.security.ProtectionDomain;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* spring cglib 魔改
|
||||
*
|
||||
* <p>
|
||||
* 1. 支持链式 bean
|
||||
* 2. 自定义的 BeanCopier 解决 spring boot 和 cglib ClassLoader classLoader 不一致的问题
|
||||
* </p>
|
||||
*
|
||||
* @author L.cm
|
||||
*/
|
||||
public abstract class BaseBeanCopier {
|
||||
private static final BeanCopierKey KEY_FACTORY = (BeanCopierKey) KeyFactory.create(BeanCopierKey.class);
|
||||
private static final Type CONVERTER = TypeUtils.parseType("org.springframework.cglib.core.Converter");
|
||||
private static final Type BEAN_COPIER = TypeUtils.parseType(BaseBeanCopier.class.getName());
|
||||
private static final Signature COPY = new Signature("copy", Type.VOID_TYPE, new Type[]{Constants.TYPE_OBJECT, Constants.TYPE_OBJECT, CONVERTER});
|
||||
private static final Signature CONVERT = TypeUtils.parseSignature("Object convert(Object, Class, Object)");
|
||||
|
||||
interface BeanCopierKey {
|
||||
/**
|
||||
* 实例化
|
||||
* @param source 源
|
||||
* @param target 目标
|
||||
* @param useConverter 是否使用转换
|
||||
* @return
|
||||
*/
|
||||
Object newInstance(String source, String target, boolean useConverter);
|
||||
}
|
||||
|
||||
public static BaseBeanCopier create(Class source, Class target, boolean useConverter) {
|
||||
return BaseBeanCopier.create(source, target, null, useConverter);
|
||||
}
|
||||
|
||||
public static BaseBeanCopier create(Class source, Class target, ClassLoader classLoader, boolean useConverter) {
|
||||
Generator gen;
|
||||
if (classLoader == null) {
|
||||
gen = new Generator();
|
||||
} else {
|
||||
gen = new Generator(classLoader);
|
||||
}
|
||||
gen.setSource(source);
|
||||
gen.setTarget(target);
|
||||
gen.setUseConverter(useConverter);
|
||||
return gen.create();
|
||||
}
|
||||
|
||||
/**
|
||||
* 拷贝
|
||||
* @param from 源
|
||||
* @param to 目标
|
||||
* @param converter 转换器
|
||||
*/
|
||||
abstract public void copy(Object from, Object to, Converter converter);
|
||||
|
||||
public static class Generator extends AbstractClassGenerator {
|
||||
private static final Source SOURCE = new Source(BaseBeanCopier.class.getName());
|
||||
private final ClassLoader classLoader;
|
||||
private Class source;
|
||||
private Class target;
|
||||
private boolean useConverter;
|
||||
|
||||
Generator() {
|
||||
super(SOURCE);
|
||||
this.classLoader = null;
|
||||
}
|
||||
|
||||
Generator(ClassLoader classLoader) {
|
||||
super(SOURCE);
|
||||
this.classLoader = classLoader;
|
||||
}
|
||||
|
||||
public void setSource(Class source) {
|
||||
if (!Modifier.isPublic(source.getModifiers())) {
|
||||
setNamePrefix(source.getName());
|
||||
}
|
||||
this.source = source;
|
||||
}
|
||||
|
||||
public void setTarget(Class target) {
|
||||
if (!Modifier.isPublic(target.getModifiers())) {
|
||||
setNamePrefix(target.getName());
|
||||
}
|
||||
|
||||
this.target = target;
|
||||
}
|
||||
|
||||
public void setUseConverter(boolean useConverter) {
|
||||
this.useConverter = useConverter;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected ClassLoader getDefaultClassLoader() {
|
||||
return target.getClassLoader();
|
||||
}
|
||||
|
||||
@Override
|
||||
protected ProtectionDomain getProtectionDomain() {
|
||||
return ReflectUtils.getProtectionDomain(source);
|
||||
}
|
||||
|
||||
public BaseBeanCopier create() {
|
||||
Object key = KEY_FACTORY.newInstance(source.getName(), target.getName(), useConverter);
|
||||
return (BaseBeanCopier) super.create(key);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void generateClass(ClassVisitor v) {
|
||||
Type sourceType = Type.getType(source);
|
||||
Type targetType = Type.getType(target);
|
||||
ClassEmitter ce = new ClassEmitter(v);
|
||||
ce.begin_class(Constants.V1_2,
|
||||
Constants.ACC_PUBLIC,
|
||||
getClassName(),
|
||||
BEAN_COPIER,
|
||||
null,
|
||||
Constants.SOURCE_FILE);
|
||||
|
||||
EmitUtils.null_constructor(ce);
|
||||
CodeEmitter e = ce.begin_method(Constants.ACC_PUBLIC, COPY, null);
|
||||
|
||||
// 2018.12.27 by L.cm 支持链式 bean
|
||||
PropertyDescriptor[] getters = Func.getBeanGetters(source);
|
||||
PropertyDescriptor[] setters = Func.getBeanSetters(target);
|
||||
Map<String, Object> names = new HashMap<>(16);
|
||||
for (PropertyDescriptor getter : getters) {
|
||||
names.put(getter.getName(), getter);
|
||||
}
|
||||
|
||||
Local targetLocal = e.make_local();
|
||||
Local sourceLocal = e.make_local();
|
||||
e.load_arg(1);
|
||||
e.checkcast(targetType);
|
||||
e.store_local(targetLocal);
|
||||
e.load_arg(0);
|
||||
e.checkcast(sourceType);
|
||||
e.store_local(sourceLocal);
|
||||
|
||||
for (int i = 0; i < setters.length; i++) {
|
||||
PropertyDescriptor setter = setters[i];
|
||||
PropertyDescriptor getter = (PropertyDescriptor) names.get(setter.getName());
|
||||
if (getter != null) {
|
||||
MethodInfo read = ReflectUtils.getMethodInfo(getter.getReadMethod());
|
||||
MethodInfo write = ReflectUtils.getMethodInfo(setter.getWriteMethod());
|
||||
if (useConverter) {
|
||||
Type setterType = write.getSignature().getArgumentTypes()[0];
|
||||
e.load_local(targetLocal);
|
||||
e.load_arg(2);
|
||||
e.load_local(sourceLocal);
|
||||
e.invoke(read);
|
||||
e.box(read.getSignature().getReturnType());
|
||||
EmitUtils.load_class(e, setterType);
|
||||
e.push(write.getSignature().getName());
|
||||
e.invoke_interface(CONVERTER, CONVERT);
|
||||
e.unbox_or_zero(setterType);
|
||||
e.invoke(write);
|
||||
} else if (compatible(getter, setter)) {
|
||||
// 2018.12.27 by L.cm 支持链式 bean
|
||||
e.load_local(targetLocal);
|
||||
e.load_local(sourceLocal);
|
||||
e.invoke(read);
|
||||
e.invoke(write);
|
||||
}
|
||||
}
|
||||
}
|
||||
e.return_value();
|
||||
e.end_method();
|
||||
ce.end_class();
|
||||
}
|
||||
|
||||
private static boolean compatible(PropertyDescriptor getter, PropertyDescriptor setter) {
|
||||
return setter.getPropertyType().isAssignableFrom(getter.getPropertyType());
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Object firstInstance(Class type) {
|
||||
return ReflectUtils.newInstance(type);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Object nextInstance(Object instance) {
|
||||
return instance;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
package com.ruoyi.common.func.support;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* Bean属性
|
||||
*
|
||||
* @author Chill
|
||||
*/
|
||||
@Getter
|
||||
@AllArgsConstructor
|
||||
public class BeanProperty {
|
||||
private final String name;
|
||||
private final Class<?> type;
|
||||
}
|
||||
|
|
@ -0,0 +1,86 @@
|
|||
/**
|
||||
* Copyright (c) 2018-2028, DreamLu 卢春梦 (qq596392912@gmail.com).
|
||||
* <p>
|
||||
* Licensed under the GNU LESSER GENERAL PUBLIC LICENSE 3.0;
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
* <p>
|
||||
* http://www.gnu.org/licenses/lgpl.html
|
||||
* <p>
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package com.ruoyi.common.func.support;
|
||||
|
||||
import java.text.ParseException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.Locale;
|
||||
import java.util.Queue;
|
||||
import java.util.TimeZone;
|
||||
import java.util.concurrent.ConcurrentLinkedQueue;
|
||||
|
||||
/**
|
||||
* 参考tomcat8中的并发DateFormat
|
||||
* <p>
|
||||
* {@link SimpleDateFormat}的线程安全包装器。
|
||||
* 不使用ThreadLocal,创建足够的SimpleDateFormat对象来满足并发性要求。
|
||||
* </p>
|
||||
*
|
||||
* @author L.cm
|
||||
*/
|
||||
public class ConcurrentDateFormat {
|
||||
private final String format;
|
||||
private final Locale locale;
|
||||
private final TimeZone timezone;
|
||||
private final Queue<SimpleDateFormat> queue = new ConcurrentLinkedQueue<>();
|
||||
|
||||
private ConcurrentDateFormat(String format, Locale locale, TimeZone timezone) {
|
||||
this.format = format;
|
||||
this.locale = locale;
|
||||
this.timezone = timezone;
|
||||
SimpleDateFormat initial = createInstance();
|
||||
queue.add(initial);
|
||||
}
|
||||
|
||||
public static ConcurrentDateFormat of(String format) {
|
||||
return new ConcurrentDateFormat(format, Locale.getDefault(), TimeZone.getDefault());
|
||||
}
|
||||
|
||||
public static ConcurrentDateFormat of(String format, TimeZone timezone) {
|
||||
return new ConcurrentDateFormat(format, Locale.getDefault(), timezone);
|
||||
}
|
||||
|
||||
public static ConcurrentDateFormat of(String format, Locale locale, TimeZone timezone) {
|
||||
return new ConcurrentDateFormat(format, locale, timezone);
|
||||
}
|
||||
|
||||
public String format(Date date) {
|
||||
SimpleDateFormat sdf = queue.poll();
|
||||
if (sdf == null) {
|
||||
sdf = createInstance();
|
||||
}
|
||||
String result = sdf.format(date);
|
||||
queue.add(sdf);
|
||||
return result;
|
||||
}
|
||||
|
||||
public Date parse(String source) throws ParseException {
|
||||
SimpleDateFormat sdf = queue.poll();
|
||||
if (sdf == null) {
|
||||
sdf = createInstance();
|
||||
}
|
||||
Date result = sdf.parse(source);
|
||||
queue.add(sdf);
|
||||
return result;
|
||||
}
|
||||
|
||||
private SimpleDateFormat createInstance() {
|
||||
SimpleDateFormat sdf = new SimpleDateFormat(format, locale);
|
||||
sdf.setTimeZone(timezone);
|
||||
return sdf;
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,103 @@
|
|||
package com.ruoyi.common.func.support;
|
||||
|
||||
import com.ruoyi.common.func.StringPool;
|
||||
import org.springframework.lang.Nullable;
|
||||
|
||||
import java.io.Writer;
|
||||
|
||||
/**
|
||||
* FastStringWriter
|
||||
*
|
||||
* @author L.cm
|
||||
*/
|
||||
public class FastStringWriter extends Writer {
|
||||
private final StringBuilder builder;
|
||||
|
||||
public FastStringWriter() {
|
||||
builder = new StringBuilder(64);
|
||||
}
|
||||
|
||||
public FastStringWriter(final int capacity) {
|
||||
if (capacity < 0) {
|
||||
throw new IllegalArgumentException("Negative builderfer size");
|
||||
}
|
||||
builder = new StringBuilder(capacity);
|
||||
}
|
||||
|
||||
public FastStringWriter(@Nullable final StringBuilder builder) {
|
||||
this.builder = builder != null ? builder : new StringBuilder(64);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the underlying StringBuilder.
|
||||
*
|
||||
* @return StringBuilder
|
||||
*/
|
||||
public StringBuilder getBuilder() {
|
||||
return builder;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void write(int c) {
|
||||
builder.append((char) c);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void write(char[] cbuilder, int off, int len) {
|
||||
if ((off < 0) || (off > cbuilder.length) || (len < 0) ||
|
||||
((off + len) > cbuilder.length) || ((off + len) < 0)) {
|
||||
throw new IndexOutOfBoundsException();
|
||||
} else if (len == 0) {
|
||||
return;
|
||||
}
|
||||
builder.append(cbuilder, off, len);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void write(String str) {
|
||||
builder.append(str);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void write(String str, int off, int len) {
|
||||
builder.append(str.substring(off, off + len));
|
||||
}
|
||||
|
||||
@Override
|
||||
public FastStringWriter append(CharSequence csq) {
|
||||
if (csq == null) {
|
||||
write(StringPool.NULL);
|
||||
} else {
|
||||
write(csq.toString());
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FastStringWriter append(CharSequence csq, int start, int end) {
|
||||
CharSequence cs = (csq == null ? StringPool.NULL : csq);
|
||||
write(cs.subSequence(start, end).toString());
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public FastStringWriter append(char c) {
|
||||
write(c);
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return builder.toString();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void flush() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void close() {
|
||||
builder.setLength(0);
|
||||
builder.trimToSize();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,190 @@
|
|||
package com.ruoyi.common.func.support;
|
||||
|
||||
import com.ruoyi.common.func.Func;
|
||||
import org.springframework.util.LinkedCaseInsensitiveMap;
|
||||
|
||||
import java.sql.Time;
|
||||
import java.sql.Timestamp;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
|
||||
/**
|
||||
* 链式map
|
||||
*
|
||||
* @author Chill
|
||||
*/
|
||||
public class Kv extends LinkedCaseInsensitiveMap<Object> {
|
||||
|
||||
|
||||
private Kv() {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建Kv
|
||||
*
|
||||
* @return Kv
|
||||
*/
|
||||
public static Kv init() {
|
||||
return new Kv();
|
||||
}
|
||||
|
||||
public static HashMap newMap() {
|
||||
return new HashMap(16);
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置列
|
||||
*
|
||||
* @param attr 属性
|
||||
* @param value 值
|
||||
* @return 本身
|
||||
*/
|
||||
public Kv set(String attr, Object value) {
|
||||
this.put(attr, value);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置列,当键或值为null时忽略
|
||||
*
|
||||
* @param attr 属性
|
||||
* @param value 值
|
||||
* @return 本身
|
||||
*/
|
||||
public Kv setIgnoreNull(String attr, Object value) {
|
||||
if (null != attr && null != value) {
|
||||
set(attr, value);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public Object getObj(String key) {
|
||||
return super.get(key);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param <T> 值类型
|
||||
* @param attr 字段名
|
||||
* @param defaultValue 默认值
|
||||
* @return 字段值
|
||||
*/
|
||||
@SuppressWarnings("unchecked")
|
||||
public <T> T get(String attr, T defaultValue) {
|
||||
final Object result = get(attr);
|
||||
return (T) (result != null ? result : defaultValue);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public String getStr(String attr) {
|
||||
return Func.toStr(get(attr), null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Integer getInt(String attr) {
|
||||
return Func.toInt(get(attr), -1);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Long getLong(String attr) {
|
||||
return Func.toLong(get(attr), -1L);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Float getFloat(String attr) {
|
||||
return Func.toFloat(get(attr), null);
|
||||
}
|
||||
|
||||
public Double getDouble(String attr) {
|
||||
return Func.toDouble(get(attr), null);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Boolean getBool(String attr) {
|
||||
return Func.toBoolean(get(attr), null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public byte[] getBytes(String attr) {
|
||||
return get(attr, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Date getDate(String attr) {
|
||||
return get(attr, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Time getTime(String attr) {
|
||||
return get(attr, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Timestamp getTimestamp(String attr) {
|
||||
return get(attr, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得特定类型值
|
||||
*
|
||||
* @param attr 字段名
|
||||
* @return 字段值
|
||||
*/
|
||||
public Number getNumber(String attr) {
|
||||
return get(attr, null);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Kv clone() {
|
||||
return (Kv) super.clone();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
package com.ruoyi.common.mappers;
|
||||
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import tk.mybatis.mapper.common.IdsMapper;
|
||||
import tk.mybatis.mapper.common.Mapper;
|
||||
import tk.mybatis.mapper.common.MySqlMapper;
|
||||
import tk.mybatis.mapper.common.special.InsertListMapper;
|
||||
|
||||
/**
|
||||
* 通用Mapper继承Mapper、MySqlMapper
|
||||
* @param <T>
|
||||
*/
|
||||
public interface RuoYiBaseMapper<T extends BaseEntity> extends Mapper<T>, MySqlMapper<T>, IdsMapper<T>, InsertListMapper<T> {
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,137 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-dependencies-bom</artifactId>
|
||||
<version>4.4.0</version>
|
||||
<packaging>pom</packaging>
|
||||
<url>http://www.ruoyi.vip</url>
|
||||
<name>${project.artifactId}</name>
|
||||
<description>RuoYi dependencies BOM</description>
|
||||
|
||||
<properties>
|
||||
<ruoyi.version>4.4.0</ruoyi.version>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
||||
<java.version>1.8</java.version>
|
||||
<knife4j.version>2.0.3</knife4j.version>
|
||||
</properties>
|
||||
<!-- 依赖声明 -->
|
||||
<dependencyManagement>
|
||||
<dependencies>
|
||||
<!--自定义添加Jar依赖:2020/08/30-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-his</artifactId>
|
||||
<version>${ruoyi.version}</version>
|
||||
</dependency>
|
||||
<!-- HIS Core模块-->
|
||||
<dependency>
|
||||
<groupId>com.bending.core</groupId>
|
||||
<artifactId>bending-his-core</artifactId>
|
||||
<version>1.0.5-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<!--Other Jars-->
|
||||
<dependency>
|
||||
<groupId>com.google.code.findbugs</groupId>
|
||||
<artifactId>annotations</artifactId>
|
||||
<version>3.0.1</version>
|
||||
</dependency>
|
||||
<!--MyBatis integration with Spring Boot-->
|
||||
<dependency>
|
||||
<groupId>org.mybatis.spring.boot</groupId>
|
||||
<artifactId>mybatis-spring-boot-starter</artifactId>
|
||||
<version>2.1.3</version>
|
||||
</dependency>
|
||||
<!--通用Mapper-->
|
||||
<dependency>
|
||||
<groupId>tk.mybatis</groupId>
|
||||
<artifactId>mapper</artifactId>
|
||||
<version>4.1.5</version>
|
||||
</dependency>
|
||||
<!--swagger-->
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-models</artifactId>
|
||||
<version>1.5.21</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>io.swagger</groupId>
|
||||
<artifactId>swagger-annotations</artifactId>
|
||||
<version>1.5.21</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>1.18.12</version>
|
||||
</dependency>
|
||||
<!--SwaggerUI-->
|
||||
<dependency>
|
||||
<groupId>com.github.xiaoymin</groupId>
|
||||
<artifactId>knife4j-spring-boot-starter</artifactId>
|
||||
<version>${knife4j.version}</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.github.xiaoymin</groupId>
|
||||
<artifactId>knife4j-spring-ui</artifactId>
|
||||
<version>${knife4j.version}</version>
|
||||
</dependency>
|
||||
<!--zipkin-->
|
||||
<dependency>
|
||||
<groupId>io.zipkin.brave</groupId>
|
||||
<artifactId>brave-bom</artifactId>
|
||||
<version>5.9.1</version>
|
||||
<type>pom</type>
|
||||
<scope>import</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</dependencyManagement>
|
||||
|
||||
<build>
|
||||
|
||||
</build>
|
||||
|
||||
<distributionManagement>
|
||||
<repository>
|
||||
<id>nexus</id>
|
||||
<name>maven-releases</name>
|
||||
<url>http://nexus.liudebin.cn/repository/maven-releases/</url>
|
||||
</repository>
|
||||
<snapshotRepository>
|
||||
<id>snapshots</id>
|
||||
<name>maven-snapshots</name>
|
||||
<url>http://nexus.liudebin.cn/repository/maven-snapshots/</url>
|
||||
</snapshotRepository>
|
||||
</distributionManagement>
|
||||
|
||||
<repositories>
|
||||
<repository>
|
||||
<id>public</id>
|
||||
<name>aliyun nexus</name>
|
||||
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
|
||||
<releases>
|
||||
<enabled>true</enabled>
|
||||
</releases>
|
||||
</repository>
|
||||
</repositories>
|
||||
|
||||
<pluginRepositories>
|
||||
<pluginRepository>
|
||||
<id>public</id>
|
||||
<name>aliyun nexus</name>
|
||||
<url>http://maven.aliyun.com/nexus/content/groups/public/</url>
|
||||
<releases>
|
||||
<enabled>true</enabled>
|
||||
</releases>
|
||||
<snapshots>
|
||||
<enabled>false</enabled>
|
||||
</snapshots>
|
||||
</pluginRepository>
|
||||
</pluginRepositories>
|
||||
|
||||
</project>
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
package com.ruoyi.framework.config;
|
||||
|
||||
import org.mybatis.spring.annotation.MapperScan;
|
||||
import tk.mybatis.spring.annotation.MapperScan;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.context.annotation.EnableAspectJAutoProxy;
|
||||
|
||||
|
|
@ -13,6 +13,7 @@ import org.springframework.context.annotation.EnableAspectJAutoProxy;
|
|||
// 表示通过aop框架暴露该代理对象,AopContext能够访问
|
||||
@EnableAspectJAutoProxy(exposeProxy = true)
|
||||
// 指定要扫描的Mapper类的包的路径
|
||||
//@MapperScan("com.ruoyi.**.mapper")
|
||||
@MapperScan("com.ruoyi.**.mapper")
|
||||
public class ApplicationConfig
|
||||
{
|
||||
|
|
|
|||
|
|
@ -0,0 +1,15 @@
|
|||
package com.ruoyi.framework.config;
|
||||
|
||||
import com.bending.core.props.HisClientProperties;
|
||||
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
||||
import org.springframework.context.annotation.ComponentScan;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
/**
|
||||
* HIS客户端配置
|
||||
*/
|
||||
@Configuration
|
||||
@EnableConfigurationProperties({HisClientProperties.class})
|
||||
@ComponentScan(basePackages = "com.bending.core")
|
||||
public class HisConfig {
|
||||
}
|
||||
|
|
@ -2,10 +2,10 @@
|
|||
# 代码生成
|
||||
gen:
|
||||
# 作者
|
||||
author: ruoyi
|
||||
author: bend
|
||||
# 默认生成包路径 system 需改成自己的模块名称 如 system monitor tool
|
||||
packageName: com.ruoyi.system
|
||||
packageName: com.ruoyi.his
|
||||
# 自动去除表前缀,默认是false
|
||||
autoRemovePre: false
|
||||
autoRemovePre: true
|
||||
# 表前缀(生成类名不会包含表前缀,多个用逗号分隔)
|
||||
tablePrefix: sys_
|
||||
tablePrefix: sys_,bend_,his_
|
||||
|
|
@ -3,14 +3,17 @@ package ${packageName}.domain;
|
|||
#foreach ($import in $importList)
|
||||
import ${import};
|
||||
#end
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
#if($table.crud || $table.sub)
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
#elseif($table.tree)
|
||||
import com.ruoyi.common.core.domain.TreeEntity;
|
||||
#end
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* ${functionName}对象 ${tableName}
|
||||
|
|
@ -18,6 +21,10 @@ import com.ruoyi.common.core.domain.TreeEntity;
|
|||
* @author ${author}
|
||||
* @date ${datetime}
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "${functionName}")
|
||||
@Table(name = "${tableName}")
|
||||
#if($table.crud || $table.sub)
|
||||
#set($Entity="BaseEntity")
|
||||
#elseif($table.tree)
|
||||
|
|
@ -30,6 +37,7 @@ public class ${ClassName} extends ${Entity}
|
|||
#foreach ($column in $columns)
|
||||
#if(!$table.isSuperColumn($column.javaField))
|
||||
/** $column.columnComment */
|
||||
@ApiModelProperty(notes = "$column.columnComment")
|
||||
#if($column.list)
|
||||
#set($parentheseIndex=$column.columnComment.indexOf("("))
|
||||
#if($parentheseIndex != -1)
|
||||
|
|
@ -51,54 +59,8 @@ public class ${ClassName} extends ${Entity}
|
|||
#end
|
||||
#if($table.sub)
|
||||
/** $table.subTable.functionName信息 */
|
||||
@ApiModelProperty(notes = "$table.subTable.functionName信息")
|
||||
private List<${subClassName}> ${subclassName}List;
|
||||
|
||||
#end
|
||||
#foreach ($column in $columns)
|
||||
#if(!$table.isSuperColumn($column.javaField))
|
||||
#if($column.javaField.length() > 2 && $column.javaField.substring(1,2).matches("[A-Z]"))
|
||||
#set($AttrName=$column.javaField)
|
||||
#else
|
||||
#set($AttrName=$column.javaField.substring(0,1).toUpperCase() + ${column.javaField.substring(1)})
|
||||
#end
|
||||
public void set${AttrName}($column.javaType $column.javaField)
|
||||
{
|
||||
this.$column.javaField = $column.javaField;
|
||||
}
|
||||
|
||||
public $column.javaType get${AttrName}()
|
||||
{
|
||||
return $column.javaField;
|
||||
}
|
||||
#end
|
||||
#end
|
||||
|
||||
#if($table.sub)
|
||||
public List<${subClassName}> get${subClassName}List()
|
||||
{
|
||||
return ${subclassName}List;
|
||||
}
|
||||
|
||||
public void set${subClassName}List(List<${subClassName}> ${subclassName}List)
|
||||
{
|
||||
this.${subclassName}List = ${subclassName}List;
|
||||
}
|
||||
|
||||
#end
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
#foreach ($column in $columns)
|
||||
#if($column.javaField.length() > 2 && $column.javaField.substring(1,2).matches("[A-Z]"))
|
||||
#set($AttrName=$column.javaField)
|
||||
#else
|
||||
#set($AttrName=$column.javaField.substring(0,1).toUpperCase() + ${column.javaField.substring(1)})
|
||||
#end
|
||||
.append("${column.javaField}", get${AttrName}())
|
||||
#end
|
||||
#if($table.sub)
|
||||
.append("${subclassName}List", get${subClassName}List())
|
||||
#end
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,10 +1,11 @@
|
|||
package ${packageName}.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import ${packageName}.domain.${ClassName};
|
||||
#if($table.sub)
|
||||
import ${packageName}.domain.${subClassName};
|
||||
#end
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* ${functionName}Mapper接口
|
||||
|
|
@ -12,7 +13,7 @@ import ${packageName}.domain.${subClassName};
|
|||
* @author ${author}
|
||||
* @date ${datetime}
|
||||
*/
|
||||
public interface ${ClassName}Mapper
|
||||
public interface ${ClassName}Mapper extends RuoYiBaseMapper<${ClassName}>
|
||||
{
|
||||
/**
|
||||
* 查询${functionName}
|
||||
|
|
@ -66,7 +67,7 @@ public interface ${ClassName}Mapper
|
|||
/**
|
||||
* 批量删除${subTable.functionName}
|
||||
*
|
||||
* @param customerIds 需要删除的数据ID
|
||||
* @param ${pkColumn.javaField}s 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int delete${subClassName}By${subTableFkClassName}s(String[] ${pkColumn.javaField}s);
|
||||
|
|
@ -83,7 +84,7 @@ public interface ${ClassName}Mapper
|
|||
/**
|
||||
* 通过${functionName}ID删除${subTable.functionName}信息
|
||||
*
|
||||
* @param roleId 角色ID
|
||||
* @param ${pkColumn.javaField} ${functionName}ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int delete${subClassName}By${subTableFkClassName}(${pkColumn.javaType} ${pkColumn.javaField});
|
||||
|
|
|
|||
|
|
@ -3,10 +3,13 @@ package ${packageName}.domain;
|
|||
#foreach ($import in $subImportList)
|
||||
import ${import};
|
||||
#end
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* ${subTable.functionName}对象 ${subTableName}
|
||||
|
|
@ -14,6 +17,10 @@ import com.ruoyi.common.core.domain.BaseEntity;
|
|||
* @author ${author}
|
||||
* @date ${datetime}
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "${functionName}")
|
||||
@Table(name = "${subTableName}")
|
||||
public class ${subClassName} extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
|
@ -21,6 +28,7 @@ public class ${subClassName} extends BaseEntity
|
|||
#foreach ($column in $subTable.columns)
|
||||
#if(!$table.isSuperColumn($column.javaField))
|
||||
/** $column.columnComment */
|
||||
@ApiModelProperty(notes = "$column.columnComment")
|
||||
#if($column.list)
|
||||
#set($parentheseIndex=$column.columnComment.indexOf("("))
|
||||
#if($parentheseIndex != -1)
|
||||
|
|
@ -40,36 +48,4 @@ public class ${subClassName} extends BaseEntity
|
|||
|
||||
#end
|
||||
#end
|
||||
#foreach ($column in $subTable.columns)
|
||||
#if(!$table.isSuperColumn($column.javaField))
|
||||
#if($column.javaField.length() > 2 && $column.javaField.substring(1,2).matches("[A-Z]"))
|
||||
#set($AttrName=$column.javaField)
|
||||
#else
|
||||
#set($AttrName=$column.javaField.substring(0,1).toUpperCase() + ${column.javaField.substring(1)})
|
||||
#end
|
||||
public void set${AttrName}($column.javaType $column.javaField)
|
||||
{
|
||||
this.$column.javaField = $column.javaField;
|
||||
}
|
||||
|
||||
public $column.javaType get${AttrName}()
|
||||
{
|
||||
return $column.javaField;
|
||||
}
|
||||
#end
|
||||
#end
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
#foreach ($column in $subTable.columns)
|
||||
#if($column.javaField.length() > 2 && $column.javaField.substring(1,2).matches("[A-Z]"))
|
||||
#set($AttrName=$column.javaField)
|
||||
#else
|
||||
#set($AttrName=$column.javaField.substring(0,1).toUpperCase() + ${column.javaField.substring(1)})
|
||||
#end
|
||||
.append("${column.javaField}", get${AttrName}())
|
||||
#end
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,37 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<artifactId>ruoyi</artifactId>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<version>4.4.0</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>ruoyi-his</artifactId>
|
||||
|
||||
<description>
|
||||
HIS 系统模块
|
||||
</description>
|
||||
|
||||
<dependencies>
|
||||
<!-- 通用工具-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common</artifactId>
|
||||
</dependency>
|
||||
<!--核心模块-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-framework</artifactId>
|
||||
</dependency>
|
||||
<!--HIS Core模块-->
|
||||
<dependency>
|
||||
<groupId>com.bending.core</groupId>
|
||||
<artifactId>bending-his-core</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
||||
</project>
|
||||
|
|
@ -0,0 +1,132 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.framework.util.ShiroUtils;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.Agreement;
|
||||
import com.ruoyi.bend.service.IAgreementService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 协议管理Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/agreement")
|
||||
public class AgreementController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/agreement";
|
||||
|
||||
@Autowired
|
||||
private IAgreementService agreementService;
|
||||
|
||||
@RequiresPermissions("bend:agreement:view")
|
||||
@GetMapping()
|
||||
public String agreement()
|
||||
{
|
||||
return prefix + "/agreement";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询协议管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:agreement:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(Agreement agreement)
|
||||
{
|
||||
startPage();
|
||||
List<Agreement> list = agreementService.selectAgreementList(agreement);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出协议管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:agreement:export")
|
||||
@Log(title = "协议管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(Agreement agreement)
|
||||
{
|
||||
List<Agreement> list = agreementService.selectAgreementList(agreement);
|
||||
ExcelUtil<Agreement> util = new ExcelUtil<Agreement>(Agreement.class);
|
||||
return util.exportExcel(list, "agreement");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增协议管理
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存协议管理
|
||||
*/
|
||||
@RequiresPermissions("bend:agreement:add")
|
||||
@Log(title = "协议管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(Agreement agreement)
|
||||
{
|
||||
String operName = ShiroUtils.getSysUser().getLoginName();
|
||||
agreement.setCreateBy(operName);
|
||||
return toAjax(agreementService.insertAgreement(agreement));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改协议管理
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
Agreement agreement = agreementService.selectAgreementById(id);
|
||||
mmap.put("agreement", agreement);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存协议管理
|
||||
*/
|
||||
@RequiresPermissions("bend:agreement:edit")
|
||||
@Log(title = "协议管理", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(Agreement agreement)
|
||||
{
|
||||
String operName = ShiroUtils.getSysUser().getLoginName();
|
||||
agreement.setCreateBy(operName);
|
||||
return toAjax(agreementService.updateAgreement(agreement));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除协议管理
|
||||
*/
|
||||
@RequiresPermissions("bend:agreement:remove")
|
||||
@Log(title = "协议管理", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(agreementService.deleteAgreementByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,164 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import com.ruoyi.bend.domain.Article;
|
||||
import com.ruoyi.bend.service.IArticleService;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.framework.util.ShiroUtils;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 内容管理Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/article")
|
||||
public class ArticleController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/article";
|
||||
|
||||
@Autowired
|
||||
private IArticleService articleService;
|
||||
|
||||
@RequiresPermissions("bend:article:view")
|
||||
@GetMapping()
|
||||
public String article()
|
||||
{
|
||||
return prefix + "/article";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询内容管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:article:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(Article article)
|
||||
{
|
||||
startPage();
|
||||
List<Article> list = articleService.selectArticleList(article);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出内容管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:article:export")
|
||||
@Log(title = "内容管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(Article article)
|
||||
{
|
||||
List<Article> list = articleService.selectArticleList(article);
|
||||
ExcelUtil<Article> util = new ExcelUtil<Article>(Article.class);
|
||||
return util.exportExcel(list, "article");
|
||||
}
|
||||
|
||||
/**
|
||||
* 草稿箱 页面
|
||||
*/
|
||||
@RequiresPermissions("bend:article:view")
|
||||
@GetMapping("/draft")
|
||||
public String draftArticle(@RequestParam(value = "articleStatus")Integer articleStatus, ModelMap mmap)
|
||||
{
|
||||
mmap.put("articleStatus", articleStatus);
|
||||
return prefix + "/draft";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询草稿箱内容列表
|
||||
* @param article 内容
|
||||
* @return 列表
|
||||
*/
|
||||
@RequiresPermissions("bend:article:draft")
|
||||
@PostMapping("/draft/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo draftList(Article article)
|
||||
{
|
||||
startPage();
|
||||
List<Article> list = articleService.selectArticleList(article);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增内容管理
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存内容管理
|
||||
*/
|
||||
@RequiresPermissions("bend:article:add")
|
||||
@Log(title = "内容管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(Article article)
|
||||
{
|
||||
//根据文章发布状态(文章状态(0草稿 1正常 2删除)),添加额外数据
|
||||
if(article.getArticleStatus().equals(1)){
|
||||
article.setReleaseTime(DateUtils.getNowDate());
|
||||
}
|
||||
String operName = ShiroUtils.getSysUser().getLoginName();
|
||||
article.setCreateBy(operName);
|
||||
return toAjax(articleService.insertArticle(article));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改内容管理
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
Article article = articleService.selectArticleById(id);
|
||||
mmap.put("article", article);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存内容管理
|
||||
*/
|
||||
@RequiresPermissions("bend:article:edit")
|
||||
@Log(title = "内容管理", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(Article article)
|
||||
{
|
||||
//根据文章发布状态(文章状态(0草稿 1正常 2删除)),添加额外数据
|
||||
if(article.getArticleStatus().equals(1)){
|
||||
article.setReleaseTime(DateUtils.getNowDate());
|
||||
}
|
||||
String operName = ShiroUtils.getSysUser().getLoginName();
|
||||
article.setCreateBy(operName);
|
||||
return toAjax(articleService.updateArticle(article));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除内容管理
|
||||
*/
|
||||
@RequiresPermissions("bend:article:remove")
|
||||
@Log(title = "内容管理", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(articleService.deleteArticleByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.Banner;
|
||||
import com.ruoyi.bend.service.IBannerService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 首页管理Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/banner")
|
||||
public class BannerController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/banner";
|
||||
|
||||
@Autowired
|
||||
private IBannerService bannerService;
|
||||
|
||||
@RequiresPermissions("bend:banner:view")
|
||||
@GetMapping()
|
||||
public String banner()
|
||||
{
|
||||
return prefix + "/banner";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询首页管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:banner:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(Banner banner)
|
||||
{
|
||||
startPage();
|
||||
List<Banner> list = bannerService.selectBannerList(banner);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出首页管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:banner:export")
|
||||
@Log(title = "首页管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(Banner banner)
|
||||
{
|
||||
List<Banner> list = bannerService.selectBannerList(banner);
|
||||
ExcelUtil<Banner> util = new ExcelUtil<Banner>(Banner.class);
|
||||
return util.exportExcel(list, "banner");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增首页管理
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存首页管理
|
||||
*/
|
||||
@RequiresPermissions("bend:banner:add")
|
||||
@Log(title = "首页管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(Banner banner)
|
||||
{
|
||||
return toAjax(bannerService.insertBanner(banner));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改首页管理
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
Banner banner = bannerService.selectBannerById(id);
|
||||
mmap.put("banner", banner);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存首页管理
|
||||
*/
|
||||
@RequiresPermissions("bend:banner:edit")
|
||||
@Log(title = "首页管理", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(Banner banner)
|
||||
{
|
||||
return toAjax(bannerService.updateBanner(banner));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除首页管理
|
||||
*/
|
||||
@RequiresPermissions("bend:banner:remove")
|
||||
@Log(title = "首页管理", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(bannerService.deleteBannerByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.Member;
|
||||
import com.ruoyi.bend.service.IMemberService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 会员列表Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/member")
|
||||
public class MemberController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/member";
|
||||
|
||||
@Autowired
|
||||
private IMemberService memberService;
|
||||
|
||||
@RequiresPermissions("bend:member:view")
|
||||
@GetMapping()
|
||||
public String member()
|
||||
{
|
||||
return prefix + "/member";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询会员列表列表
|
||||
*/
|
||||
@RequiresPermissions("bend:member:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(Member member)
|
||||
{
|
||||
startPage();
|
||||
List<Member> list = memberService.selectMemberList(member);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出会员列表列表
|
||||
*/
|
||||
@RequiresPermissions("bend:member:export")
|
||||
@Log(title = "会员列表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(Member member)
|
||||
{
|
||||
List<Member> list = memberService.selectMemberList(member);
|
||||
ExcelUtil<Member> util = new ExcelUtil<Member>(Member.class);
|
||||
return util.exportExcel(list, "member");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增会员列表
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存会员列表
|
||||
*/
|
||||
@RequiresPermissions("bend:member:add")
|
||||
@Log(title = "会员列表", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(Member member)
|
||||
{
|
||||
return toAjax(memberService.insertMember(member));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改会员列表
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
Member member = memberService.selectMemberById(id);
|
||||
mmap.put("member", member);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存会员列表
|
||||
*/
|
||||
@RequiresPermissions("bend:member:edit")
|
||||
@Log(title = "会员列表", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(Member member)
|
||||
{
|
||||
return toAjax(memberService.updateMember(member));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除会员列表
|
||||
*/
|
||||
@RequiresPermissions("bend:member:remove")
|
||||
@Log(title = "会员列表", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(memberService.deleteMemberByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.MessageCode;
|
||||
import com.ruoyi.bend.service.IMessageCodeService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 短信管理Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/messageCode")
|
||||
public class MessageCodeController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/messageCode";
|
||||
|
||||
@Autowired
|
||||
private IMessageCodeService messageCodeService;
|
||||
|
||||
@RequiresPermissions("bend:messageCode:view")
|
||||
@GetMapping()
|
||||
public String messageCode()
|
||||
{
|
||||
return prefix + "/messageCode";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询短信管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:messageCode:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(MessageCode messageCode)
|
||||
{
|
||||
startPage();
|
||||
List<MessageCode> list = messageCodeService.selectMessageCodeList(messageCode);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出短信管理列表
|
||||
*/
|
||||
@RequiresPermissions("bend:messageCode:export")
|
||||
@Log(title = "短信管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(MessageCode messageCode)
|
||||
{
|
||||
List<MessageCode> list = messageCodeService.selectMessageCodeList(messageCode);
|
||||
ExcelUtil<MessageCode> util = new ExcelUtil<MessageCode>(MessageCode.class);
|
||||
return util.exportExcel(list, "messageCode");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增短信管理
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存短信管理
|
||||
*/
|
||||
@RequiresPermissions("bend:messageCode:add")
|
||||
@Log(title = "短信管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(MessageCode messageCode)
|
||||
{
|
||||
return toAjax(messageCodeService.insertMessageCode(messageCode));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改短信管理
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
MessageCode messageCode = messageCodeService.selectMessageCodeById(id);
|
||||
mmap.put("messageCode", messageCode);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存短信管理
|
||||
*/
|
||||
@RequiresPermissions("bend:messageCode:edit")
|
||||
@Log(title = "短信管理", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(MessageCode messageCode)
|
||||
{
|
||||
return toAjax(messageCodeService.updateMessageCode(messageCode));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除短信管理
|
||||
*/
|
||||
@RequiresPermissions("bend:messageCode:remove")
|
||||
@Log(title = "短信管理", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(messageCodeService.deleteMessageCodeByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.PatientList;
|
||||
import com.ruoyi.bend.service.IPatientListService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 就诊人列表Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/patientList")
|
||||
public class PatientListController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/patientList";
|
||||
|
||||
@Autowired
|
||||
private IPatientListService patientListService;
|
||||
|
||||
@RequiresPermissions("bend:patientList:view")
|
||||
@GetMapping()
|
||||
public String patientList()
|
||||
{
|
||||
return prefix + "/patientList";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询就诊人列表列表
|
||||
*/
|
||||
@RequiresPermissions("bend:patientList:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(PatientList patientList)
|
||||
{
|
||||
startPage();
|
||||
List<PatientList> list = patientListService.selectPatientListList(patientList);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出就诊人列表列表
|
||||
*/
|
||||
@RequiresPermissions("bend:patientList:export")
|
||||
@Log(title = "就诊人列表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(PatientList patientList)
|
||||
{
|
||||
List<PatientList> list = patientListService.selectPatientListList(patientList);
|
||||
ExcelUtil<PatientList> util = new ExcelUtil<PatientList>(PatientList.class);
|
||||
return util.exportExcel(list, "patientList");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增就诊人列表
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存就诊人列表
|
||||
*/
|
||||
@RequiresPermissions("bend:patientList:add")
|
||||
@Log(title = "就诊人列表", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(PatientList patientList)
|
||||
{
|
||||
return toAjax(patientListService.insertPatientList(patientList));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改就诊人列表
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
PatientList patientList = patientListService.selectPatientListById(id);
|
||||
mmap.put("patientList", patientList);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存就诊人列表
|
||||
*/
|
||||
@RequiresPermissions("bend:patientList:edit")
|
||||
@Log(title = "就诊人列表", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(PatientList patientList)
|
||||
{
|
||||
return toAjax(patientListService.updatePatientList(patientList));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除就诊人列表
|
||||
*/
|
||||
@RequiresPermissions("bend:patientList:remove")
|
||||
@Log(title = "就诊人列表", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(patientListService.deletePatientListByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOfflineOrdersService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 线下订单Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/offlineOrders")
|
||||
public class ScrcuOfflineOrdersController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/offlineOrders";
|
||||
|
||||
@Autowired
|
||||
private IScrcuOfflineOrdersService scrcuOfflineOrdersService;
|
||||
|
||||
@RequiresPermissions("bend:offlineOrders:view")
|
||||
@GetMapping()
|
||||
public String offlineOrders()
|
||||
{
|
||||
return prefix + "/offlineOrders";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询线下订单列表
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineOrders:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(ScrcuOfflineOrders scrcuOfflineOrders)
|
||||
{
|
||||
startPage();
|
||||
List<ScrcuOfflineOrders> list = scrcuOfflineOrdersService.selectScrcuOfflineOrdersList(scrcuOfflineOrders);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出线下订单列表
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineOrders:export")
|
||||
@Log(title = "线下订单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(ScrcuOfflineOrders scrcuOfflineOrders)
|
||||
{
|
||||
List<ScrcuOfflineOrders> list = scrcuOfflineOrdersService.selectScrcuOfflineOrdersList(scrcuOfflineOrders);
|
||||
ExcelUtil<ScrcuOfflineOrders> util = new ExcelUtil<ScrcuOfflineOrders>(ScrcuOfflineOrders.class);
|
||||
return util.exportExcel(list, "offlineOrders");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增线下订单
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存线下订单
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineOrders:add")
|
||||
@Log(title = "线下订单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(ScrcuOfflineOrders scrcuOfflineOrders)
|
||||
{
|
||||
return toAjax(scrcuOfflineOrdersService.insertScrcuOfflineOrders(scrcuOfflineOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改线下订单
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
ScrcuOfflineOrders scrcuOfflineOrders = scrcuOfflineOrdersService.selectScrcuOfflineOrdersById(id);
|
||||
mmap.put("scrcuOfflineOrders", scrcuOfflineOrders);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存线下订单
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineOrders:edit")
|
||||
@Log(title = "线下订单", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(ScrcuOfflineOrders scrcuOfflineOrders)
|
||||
{
|
||||
return toAjax(scrcuOfflineOrdersService.updateScrcuOfflineOrders(scrcuOfflineOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除线下订单
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineOrders:remove")
|
||||
@Log(title = "线下订单", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(scrcuOfflineOrdersService.deleteScrcuOfflineOrdersByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineRefundOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOfflineRefundOrdersService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 扫码退款Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/offlineRefund")
|
||||
public class ScrcuOfflineRefundOrdersController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/offlineRefund";
|
||||
|
||||
@Autowired
|
||||
private IScrcuOfflineRefundOrdersService scrcuOfflineRefundOrdersService;
|
||||
|
||||
@RequiresPermissions("bend:offlineRefund:view")
|
||||
@GetMapping()
|
||||
public String offlineRefund()
|
||||
{
|
||||
return prefix + "/offlineRefund";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询扫码退款列表
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineRefund:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders)
|
||||
{
|
||||
startPage();
|
||||
List<ScrcuOfflineRefundOrders> list = scrcuOfflineRefundOrdersService.selectScrcuOfflineRefundOrdersList(scrcuOfflineRefundOrders);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出扫码退款列表
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineRefund:export")
|
||||
@Log(title = "扫码退款", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders)
|
||||
{
|
||||
List<ScrcuOfflineRefundOrders> list = scrcuOfflineRefundOrdersService.selectScrcuOfflineRefundOrdersList(scrcuOfflineRefundOrders);
|
||||
ExcelUtil<ScrcuOfflineRefundOrders> util = new ExcelUtil<ScrcuOfflineRefundOrders>(ScrcuOfflineRefundOrders.class);
|
||||
return util.exportExcel(list, "offlineRefund");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增扫码退款
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存扫码退款
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineRefund:add")
|
||||
@Log(title = "扫码退款", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders)
|
||||
{
|
||||
return toAjax(scrcuOfflineRefundOrdersService.insertScrcuOfflineRefundOrders(scrcuOfflineRefundOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改扫码退款
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
ScrcuOfflineRefundOrders scrcuOfflineRefundOrders = scrcuOfflineRefundOrdersService.selectScrcuOfflineRefundOrdersById(id);
|
||||
mmap.put("scrcuOfflineRefundOrders", scrcuOfflineRefundOrders);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存扫码退款
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineRefund:edit")
|
||||
@Log(title = "扫码退款", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders)
|
||||
{
|
||||
return toAjax(scrcuOfflineRefundOrdersService.updateScrcuOfflineRefundOrders(scrcuOfflineRefundOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除扫码退款
|
||||
*/
|
||||
@RequiresPermissions("bend:offlineRefund:remove")
|
||||
@Log(title = "扫码退款", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(scrcuOfflineRefundOrdersService.deleteScrcuOfflineRefundOrdersByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,166 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrderDetails;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOnlineOrderDetailsService;
|
||||
import com.ruoyi.bend.service.IScrcuOnlineOrdersService;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 收单列表Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/onlineOrders")
|
||||
public class ScrcuOnlineOrdersController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/onlineOrders";
|
||||
|
||||
@Autowired
|
||||
private IScrcuOnlineOrdersService scrcuOnlineOrdersService;
|
||||
|
||||
@Resource
|
||||
private IScrcuOnlineOrderDetailsService orderDetailsService;
|
||||
|
||||
|
||||
@RequiresPermissions("bend:onlineOrders:view")
|
||||
@GetMapping()
|
||||
public String onlineOrders()
|
||||
{
|
||||
return prefix + "/onlineOrders";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询收单列表列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineOrders:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
startPage();
|
||||
List<ScrcuOnlineOrders> list = scrcuOnlineOrdersService.selectScrcuOnlineOrdersList(scrcuOnlineOrders);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出收单列表列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineOrders:export")
|
||||
@Log(title = "收单列表", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
List<ScrcuOnlineOrders> list = scrcuOnlineOrdersService.selectScrcuOnlineOrdersList(scrcuOnlineOrders);
|
||||
ExcelUtil<ScrcuOnlineOrders> util = new ExcelUtil<ScrcuOnlineOrders>(ScrcuOnlineOrders.class);
|
||||
return util.exportExcel(list, "onlineOrders");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增收单列表
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存收单列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineOrders:add")
|
||||
@Log(title = "收单列表", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
return toAjax(scrcuOnlineOrdersService.insertScrcuOnlineOrders(scrcuOnlineOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改收单列表
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
ScrcuOnlineOrders scrcuOnlineOrders = scrcuOnlineOrdersService.selectScrcuOnlineOrdersById(id);
|
||||
mmap.put("scrcuOnlineOrders", scrcuOnlineOrders);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存收单列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineOrders:edit")
|
||||
@Log(title = "收单列表", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
return toAjax(scrcuOnlineOrdersService.updateScrcuOnlineOrders(scrcuOnlineOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除收单列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineOrders:remove")
|
||||
@Log(title = "收单列表", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(scrcuOnlineOrdersService.deleteScrcuOnlineOrdersByIds(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 收单详情页面
|
||||
* @param orderNumber 收单单号
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineOrders:detail")
|
||||
@GetMapping("/detail/{orderNumber}")
|
||||
public String onlineOrdersDetail(@PathVariable("orderNumber") String orderNumber, ModelMap mmap)
|
||||
{
|
||||
if (StringUtils.isNotEmpty(orderNumber))
|
||||
{
|
||||
ScrcuOnlineOrders scrcuOnlineOrders = new ScrcuOnlineOrders();
|
||||
scrcuOnlineOrders.setOrderNumber(orderNumber);
|
||||
ScrcuOnlineOrders onlineOrders = scrcuOnlineOrdersService.selectScrcuOnlineOrders(scrcuOnlineOrders);
|
||||
mmap.put("onlineOrders",onlineOrders);
|
||||
}
|
||||
return prefix + "/onlineOrderDetails";
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 收单详情列表
|
||||
* @param detail 收单详情
|
||||
* @return 列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineOrders:list")
|
||||
@PostMapping("/detail/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo onlineOrdersDetailList(ScrcuOnlineOrderDetails detail)
|
||||
{
|
||||
startPage();
|
||||
List<ScrcuOnlineOrderDetails> list = orderDetailsService.selectScrcuOnlineOrderDetailsList(detail);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineRefundOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOnlineRefundOrdersService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 退款订单Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/onlineRefund")
|
||||
public class ScrcuOnlineRefundOrdersController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/onlineRefund";
|
||||
|
||||
@Autowired
|
||||
private IScrcuOnlineRefundOrdersService scrcuOnlineRefundOrdersService;
|
||||
|
||||
@RequiresPermissions("bend:onlineRefund:view")
|
||||
@GetMapping()
|
||||
public String onlineRefund()
|
||||
{
|
||||
return prefix + "/onlineRefund";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询退款订单列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineRefund:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders)
|
||||
{
|
||||
startPage();
|
||||
List<ScrcuOnlineRefundOrders> list = scrcuOnlineRefundOrdersService.selectScrcuOnlineRefundOrdersList(scrcuOnlineRefundOrders);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出退款订单列表
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineRefund:export")
|
||||
@Log(title = "退款订单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders)
|
||||
{
|
||||
List<ScrcuOnlineRefundOrders> list = scrcuOnlineRefundOrdersService.selectScrcuOnlineRefundOrdersList(scrcuOnlineRefundOrders);
|
||||
ExcelUtil<ScrcuOnlineRefundOrders> util = new ExcelUtil<ScrcuOnlineRefundOrders>(ScrcuOnlineRefundOrders.class);
|
||||
return util.exportExcel(list, "onlineRefund");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增退款订单
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存退款订单
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineRefund:add")
|
||||
@Log(title = "退款订单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders)
|
||||
{
|
||||
return toAjax(scrcuOnlineRefundOrdersService.insertScrcuOnlineRefundOrders(scrcuOnlineRefundOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改退款订单
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
ScrcuOnlineRefundOrders scrcuOnlineRefundOrders = scrcuOnlineRefundOrdersService.selectScrcuOnlineRefundOrdersById(id);
|
||||
mmap.put("scrcuOnlineRefundOrders", scrcuOnlineRefundOrders);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存退款订单
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineRefund:edit")
|
||||
@Log(title = "退款订单", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders)
|
||||
{
|
||||
return toAjax(scrcuOnlineRefundOrdersService.updateScrcuOnlineRefundOrders(scrcuOnlineRefundOrders));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除退款订单
|
||||
*/
|
||||
@RequiresPermissions("bend:onlineRefund:remove")
|
||||
@Log(title = "退款订单", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(scrcuOnlineRefundOrdersService.deleteScrcuOnlineRefundOrdersByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.bend.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.bend.domain.WechatMember;
|
||||
import com.ruoyi.bend.service.IWechatMemberService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 微信用户Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/bend/wechatMember")
|
||||
public class WechatMemberController extends BaseController
|
||||
{
|
||||
private String prefix = "bend/wechatMember";
|
||||
|
||||
@Autowired
|
||||
private IWechatMemberService wechatMemberService;
|
||||
|
||||
@RequiresPermissions("bend:wechatMember:view")
|
||||
@GetMapping()
|
||||
public String wechatMember()
|
||||
{
|
||||
return prefix + "/wechatMember";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询微信用户列表
|
||||
*/
|
||||
@RequiresPermissions("bend:wechatMember:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(WechatMember wechatMember)
|
||||
{
|
||||
startPage();
|
||||
List<WechatMember> list = wechatMemberService.selectWechatMemberList(wechatMember);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出微信用户列表
|
||||
*/
|
||||
@RequiresPermissions("bend:wechatMember:export")
|
||||
@Log(title = "微信用户", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(WechatMember wechatMember)
|
||||
{
|
||||
List<WechatMember> list = wechatMemberService.selectWechatMemberList(wechatMember);
|
||||
ExcelUtil<WechatMember> util = new ExcelUtil<WechatMember>(WechatMember.class);
|
||||
return util.exportExcel(list, "wechatMember");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增微信用户
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存微信用户
|
||||
*/
|
||||
@RequiresPermissions("bend:wechatMember:add")
|
||||
@Log(title = "微信用户", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(WechatMember wechatMember)
|
||||
{
|
||||
return toAjax(wechatMemberService.insertWechatMember(wechatMember));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改微信用户
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
WechatMember wechatMember = wechatMemberService.selectWechatMemberById(id);
|
||||
mmap.put("wechatMember", wechatMember);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存微信用户
|
||||
*/
|
||||
@RequiresPermissions("bend:wechatMember:edit")
|
||||
@Log(title = "微信用户", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(WechatMember wechatMember)
|
||||
{
|
||||
return toAjax(wechatMemberService.updateWechatMember(wechatMember));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除微信用户
|
||||
*/
|
||||
@RequiresPermissions("bend:wechatMember:remove")
|
||||
@Log(title = "微信用户", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(wechatMemberService.deleteWechatMemberByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,49 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 协议管理对象 bend_agreement
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "协议管理")
|
||||
@Table(name = "bend_agreement")
|
||||
public class Agreement extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
/** 协议标题 */
|
||||
@ApiModelProperty(notes = "协议标题")
|
||||
@Excel(name = "协议标题")
|
||||
private String agreementTitle;
|
||||
|
||||
/** 协议类型 */
|
||||
@ApiModelProperty(notes = "协议类型")
|
||||
@Excel(name = "协议类型")
|
||||
private Integer agreementType;
|
||||
|
||||
/** 状态(0正常 1关闭) */
|
||||
@ApiModelProperty(notes = "状态(0正常 1关闭)")
|
||||
@Excel(name = "状态", readConverterExp = "0=正常,1=关闭")
|
||||
private Integer status;
|
||||
|
||||
/** 协议内容 */
|
||||
@ApiModelProperty(notes = "协议内容")
|
||||
private String agreementContent;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,113 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 内容管理对象 bend_article
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "内容管理")
|
||||
@Table(name = "bend_article")
|
||||
public class Article extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 文章标题 */
|
||||
@ApiModelProperty(notes = "文章标题")
|
||||
@Excel(name = "文章标题")
|
||||
private String title;
|
||||
|
||||
/** 副标题 */
|
||||
@ApiModelProperty(notes = "副标题")
|
||||
@Excel(name = "副标题")
|
||||
private String subTitle;
|
||||
|
||||
/** 文章封面 */
|
||||
@ApiModelProperty(notes = "文章封面")
|
||||
@Excel(name = "文章封面")
|
||||
private String articleCover;
|
||||
|
||||
/** 浏览量 */
|
||||
@ApiModelProperty(notes = "浏览量")
|
||||
@Excel(name = "浏览量")
|
||||
private Long pvCount;
|
||||
|
||||
/** 评论数 */
|
||||
@ApiModelProperty(notes = "评论数")
|
||||
@Excel(name = "评论数")
|
||||
private Long commentCount;
|
||||
|
||||
/** 转载量 */
|
||||
@ApiModelProperty(notes = "转载量")
|
||||
@Excel(name = "转载量")
|
||||
private Long quoteCount;
|
||||
|
||||
/** 微信公众号 */
|
||||
@ApiModelProperty(notes = "微信公众号")
|
||||
@Excel(name = "微信公众号")
|
||||
private String wechatAccount;
|
||||
|
||||
/** 署名名称(医生名称或医院名称) */
|
||||
@ApiModelProperty(notes = "署名名称(医生名称或医院名称)")
|
||||
@Excel(name = "署名名称(医生名称或医院名称)")
|
||||
private String signatureName;
|
||||
|
||||
/** 文章类型(0公众号 1平台文章 2医院文章 3医生文章) */
|
||||
@ApiModelProperty(notes = "文章类型(0公众号 1平台文章 2医院文章 3医生文章)")
|
||||
@Excel(name = "文章类型", readConverterExp = "0=公众号,1=平台文章,2=医院文章,3=医生文章")
|
||||
private Integer articleType;
|
||||
|
||||
/** 文章类别(0内容文章 1活动文章) */
|
||||
@ApiModelProperty(notes = "文章类别(0内容文章 1活动文章)")
|
||||
@Excel(name = "文章类别", readConverterExp = "0=内容文章,1=活动文章")
|
||||
private Integer articleClassify;
|
||||
|
||||
/** 文章分类(0健康资讯 1惠民政策) */
|
||||
@ApiModelProperty(notes = "文章分类(0健康资讯 1惠民政策)")
|
||||
@Excel(name = "文章分类", readConverterExp = "0=健康资讯,1=惠民政策")
|
||||
private Integer articleCategory;
|
||||
|
||||
/** 文章状态(0草稿 1正常 2删除) */
|
||||
@ApiModelProperty(notes = "文章状态(0草稿 1正常 2删除)")
|
||||
@Excel(name = "文章状态", readConverterExp = "0=草稿,1=正常,2=删除")
|
||||
private Integer articleStatus;
|
||||
|
||||
/** 审核状态(0正常/审核通过 1审核中 2审核驳回) */
|
||||
@ApiModelProperty(notes = "审核状态(0正常/审核通过 1审核中 2审核驳回)")
|
||||
@Excel(name = "审核状态", readConverterExp = "0=正常/审核通过,1=审核中,2=审核驳回")
|
||||
private Integer approveStatus;
|
||||
|
||||
/** 排序号 */
|
||||
@ApiModelProperty(notes = "排序号")
|
||||
@Excel(name = "排序号")
|
||||
private Long sortNo;
|
||||
|
||||
/** 审核时间 */
|
||||
@ApiModelProperty(notes = "审核时间")
|
||||
private Date auditTime;
|
||||
|
||||
/** 发布时间 */
|
||||
@ApiModelProperty(notes = "发布时间")
|
||||
@Excel(name = "发布时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date releaseTime;
|
||||
|
||||
/** 文章内容 */
|
||||
@ApiModelProperty(notes = "文章内容")
|
||||
private String content;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,49 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 首页管理对象 bend_banner
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "首页管理")
|
||||
@Table(name = "bend_banner")
|
||||
public class Banner extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 广告标题 */
|
||||
@ApiModelProperty(notes = "广告标题")
|
||||
@Excel(name = "广告标题")
|
||||
private String adTitle;
|
||||
|
||||
/** 图片地址 */
|
||||
@ApiModelProperty(notes = "图片地址")
|
||||
@Excel(name = "图片地址")
|
||||
private String adUrl;
|
||||
|
||||
/** 活动详情 */
|
||||
@ApiModelProperty(notes = "活动详情")
|
||||
@Excel(name = "活动详情")
|
||||
private String adDetailUrl;
|
||||
|
||||
/** 广告类型(0广告 1活动) */
|
||||
@ApiModelProperty(notes = "广告类型(0广告 1活动)")
|
||||
@Excel(name = "广告类型", readConverterExp = "0=广告,1=活动")
|
||||
private Integer adType;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,58 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 会员列表对象 bend_member
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "会员列表")
|
||||
@Table(name = "bend_member")
|
||||
public class Member extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 手机号 */
|
||||
@ApiModelProperty(notes = "手机号")
|
||||
@Excel(name = "手机号")
|
||||
private String mobilePhone;
|
||||
|
||||
/** 密码 */
|
||||
@ApiModelProperty(notes = "密码")
|
||||
private String password;
|
||||
|
||||
/** 真实姓名 */
|
||||
@ApiModelProperty(notes = "真实姓名")
|
||||
@Excel(name = "真实姓名")
|
||||
private String realName;
|
||||
|
||||
/** 身份证号 */
|
||||
@ApiModelProperty(notes = "身份证号")
|
||||
@Excel(name = "身份证号")
|
||||
private String idCardNo;
|
||||
|
||||
/** 用户状态(0正常 1冻结) */
|
||||
@ApiModelProperty(notes = "用户状态(0正常 1冻结)")
|
||||
@Excel(name = "用户状态", readConverterExp = "0=正常,1=冻结")
|
||||
private Integer memberStatus;
|
||||
|
||||
/** 会员类型(0普通 1医生 2管理员) */
|
||||
@ApiModelProperty(notes = "会员类型(0普通 1医生 2管理员)")
|
||||
@Excel(name = "会员类型", readConverterExp = "0=普通,1=医生,2=管理员")
|
||||
private Integer memberType;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,68 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 短信管理对象 bend_message_code
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "短信管理")
|
||||
@Table(name = "bend_message_code")
|
||||
public class MessageCode extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 手机号 */
|
||||
@ApiModelProperty(notes = "手机号")
|
||||
@Excel(name = "手机号")
|
||||
private String mobilePhone;
|
||||
|
||||
/** 短信签名 */
|
||||
@ApiModelProperty(notes = "短信签名")
|
||||
@Excel(name = "短信签名")
|
||||
private String signName;
|
||||
|
||||
/** 短信类型 */
|
||||
@ApiModelProperty(notes = "短信类型")
|
||||
private Integer smsType;
|
||||
|
||||
/** 验证码 */
|
||||
@ApiModelProperty(notes = "验证码")
|
||||
@Excel(name = "验证码")
|
||||
private String smsCode;
|
||||
|
||||
/** 短信内容 */
|
||||
@ApiModelProperty(notes = "短信内容")
|
||||
@Excel(name = "短信内容")
|
||||
private String messageText;
|
||||
|
||||
/** 模板编号 */
|
||||
@ApiModelProperty(notes = "模板编号")
|
||||
@Excel(name = "模板编号")
|
||||
private String templateCode;
|
||||
|
||||
/** 模板参数 */
|
||||
@ApiModelProperty(notes = "模板参数")
|
||||
@Excel(name = "模板参数")
|
||||
private String templateParam;
|
||||
|
||||
/** 状态(0未使用 1已使用) */
|
||||
@ApiModelProperty(notes = "状态(0未使用 1已使用)")
|
||||
@Excel(name = "状态", readConverterExp = "0=未使用,1=已使用")
|
||||
private Integer smsStatus;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,73 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 就诊人列表对象 bend_patient_list
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "就诊人列表")
|
||||
@Table(name = "bend_patient_list")
|
||||
public class PatientList extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 用户ID */
|
||||
@ApiModelProperty(notes = "用户ID")
|
||||
private Long memberId;
|
||||
|
||||
/** 真实姓名 */
|
||||
@ApiModelProperty(notes = "真实姓名")
|
||||
@Excel(name = "真实姓名")
|
||||
private String realName;
|
||||
|
||||
/** 身份证号 */
|
||||
@ApiModelProperty(notes = "身份证号")
|
||||
@Excel(name = "身份证号")
|
||||
private String idCardNo;
|
||||
|
||||
/** 手机号 */
|
||||
@ApiModelProperty(notes = "手机号")
|
||||
@Excel(name = "手机号")
|
||||
private String mobilePhone;
|
||||
|
||||
/** 是否默认(0否 1是) */
|
||||
@ApiModelProperty(notes = "是否默认(0否 1是)")
|
||||
@Excel(name = "是否默认", readConverterExp = "0=否,1=是")
|
||||
private Integer defaultPatient;
|
||||
|
||||
/** 就诊人关系(0未指定 1本人 2配偶 3父亲 4母亲 5儿子 6女儿 7亲友 8朋友 9其他) */
|
||||
@ApiModelProperty(notes = "就诊人关系(0未指定 1本人 2配偶 3父亲 4母亲 5儿子 6女儿 7亲友 8朋友 9其他)")
|
||||
@Excel(name = "就诊人关系", readConverterExp = "0=未指定,1=本人,2=配偶,3=父亲,4=母亲,5=儿子,6=女儿,7=亲友,8=朋友,9=其他")
|
||||
private Integer relationShip;
|
||||
|
||||
/** 家庭关系(0未指定 1配偶 2父子 3母子 4儿子 5女儿) */
|
||||
@ApiModelProperty(notes = "家庭关系(0未指定 1配偶 2父子 3母子 4儿子 5女儿)")
|
||||
@Excel(name = "家庭关系", readConverterExp = "0=未指定,1=配偶,2=父子,3=母子,4=儿子,5=女儿")
|
||||
private Integer familyRelationship;
|
||||
|
||||
/** 性别(0未知 1男 2女) */
|
||||
@ApiModelProperty(notes = "性别(0未知 1男 2女)")
|
||||
@Excel(name = "性别", readConverterExp = "0=未知,1=男,2=女")
|
||||
private Integer sex;
|
||||
|
||||
/** 绑定状态(0绑定中 1已解绑) */
|
||||
@ApiModelProperty(notes = "绑定状态(0绑定中 1已解绑)")
|
||||
@Excel(name = "绑定状态", readConverterExp = "0=绑定中,1=已解绑")
|
||||
private Integer bindStatus;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,130 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 线下订单对象 scrcu_offline_orders
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "线下订单")
|
||||
@Table(name = "scrcu_offline_orders")
|
||||
public class ScrcuOfflineOrders extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
/** 用户ID */
|
||||
@ApiModelProperty(notes = "用户ID")
|
||||
private Long memberId;
|
||||
|
||||
/** 订单号 */
|
||||
@ApiModelProperty(notes = "订单号")
|
||||
@Excel(name = "订单号")
|
||||
private String reqSsn;
|
||||
|
||||
/** 请求时间 */
|
||||
@ApiModelProperty(notes = "请求时间")
|
||||
@Excel(name = "请求时间")
|
||||
private String reqTime;
|
||||
|
||||
/** 商户编号 */
|
||||
@ApiModelProperty(notes = "商户编号")
|
||||
@Excel(name = "商户编号")
|
||||
private String mchtNo;
|
||||
|
||||
/** 行政区划 */
|
||||
@ApiModelProperty(notes = "行政区划")
|
||||
private String txnAreaInfo;
|
||||
|
||||
/** 交易结果通知地址 */
|
||||
@ApiModelProperty(notes = "交易结果通知地址")
|
||||
private String notifyUrl;
|
||||
|
||||
/** 订单金额 */
|
||||
@ApiModelProperty(notes = "订单金额")
|
||||
@Excel(name = "订单金额")
|
||||
private String orderAmt;
|
||||
|
||||
/** 有效时间,单位为秒;超过该时间订单自动关闭; */
|
||||
@ApiModelProperty(notes = "有效时间,单位为秒;超过该时间订单自动关闭;")
|
||||
private String validTime;
|
||||
|
||||
/** 订单描述 */
|
||||
@ApiModelProperty(notes = "订单描述")
|
||||
@Excel(name = "订单描述")
|
||||
private String orderDesc;
|
||||
|
||||
/** 商户二维码 */
|
||||
@ApiModelProperty(notes = "商户二维码")
|
||||
private String mchToken;
|
||||
|
||||
/** 用户付款码 */
|
||||
@ApiModelProperty(notes = "用户付款码")
|
||||
private String userToken;
|
||||
|
||||
/** 扫码类别(1用户主扫 2用户被扫) */
|
||||
@ApiModelProperty(notes = "扫码类别(1用户主扫 2用户被扫)")
|
||||
@Excel(name = "扫码类别", readConverterExp = "1=用户主扫,2=用户被扫")
|
||||
private String sacnType;
|
||||
|
||||
/** 交易类型(01支付 02退款) */
|
||||
@ApiModelProperty(notes = "交易类型(01支付 02退款)")
|
||||
@Excel(name = "交易类型", readConverterExp = "0=1支付,0=2退款")
|
||||
private String txnType;
|
||||
|
||||
/** 系统流水号 */
|
||||
@ApiModelProperty(notes = "系统流水号")
|
||||
@Excel(name = "系统流水号")
|
||||
private String payNo;
|
||||
|
||||
/** 机构编码 */
|
||||
@ApiModelProperty(notes = "机构编码")
|
||||
@Excel(name = "机构编码")
|
||||
private String orgCode;
|
||||
|
||||
/** HIS交易号 */
|
||||
@ApiModelProperty(notes = "HIS交易号")
|
||||
@Excel(name = "HIS交易号")
|
||||
private String hisTradeNo;
|
||||
|
||||
/** 响应流水号 */
|
||||
@ApiModelProperty(notes = "响应流水号")
|
||||
@Excel(name = "响应流水号")
|
||||
private String respSsn;
|
||||
|
||||
/** 响应时间 */
|
||||
@ApiModelProperty(notes = "响应时间")
|
||||
@Excel(name = "响应时间")
|
||||
private String respTime;
|
||||
|
||||
/** 订单状态(00订单成功 01已撤销 02已发生退款 03已关闭 09订单失败 10订单已受理 11订单处理中 12用户输密中 13订单处理超时)] */
|
||||
@ApiModelProperty(notes = "订单状态(00订单成功 01已撤销 02已发生退款 03已关闭 09订单失败 10订单已受理 11订单处理中 12用户输密中 13订单处理超时)]")
|
||||
@Excel(name = "订单状态", readConverterExp = "0=0订单成功,0=1已撤销,0=2已发生退款,0=3已关闭,0=9订单失败,1=0订单已受理,1=1订单处理中,1=2用户输密中,1=3订单处理超时")
|
||||
private String orderState;
|
||||
|
||||
/** 订单种类(0免费支付 1收单支付 2扫码支付 3微信支付) */
|
||||
@ApiModelProperty(notes = "订单种类(0免费支付 1收单支付 2扫码支付 3微信支付)")
|
||||
@Excel(name = "订单种类", readConverterExp = "0=免费支付,1=收单支付,2=扫码支付,3=微信支付")
|
||||
private Integer orderSpecies;
|
||||
|
||||
/** 费用来源(0微信挂号 1微信门诊缴费 2微信住院预交 3分诊挂号 4分诊门诊缴费 5线下扫码支付 6诊间支付) */
|
||||
@ApiModelProperty(notes = "费用来源(0微信挂号 1微信门诊缴费 2微信住院预交 3分诊挂号 4分诊门诊缴费 5线下扫码支付 6诊间支付)")
|
||||
@Excel(name = "费用来源", readConverterExp = "0=微信挂号,1=微信门诊缴费,2=微信住院预交,3=分诊挂号,4=分诊门诊缴费,5=线下扫码支付,6=诊间支付")
|
||||
private Integer expenseType;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,89 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 扫码退款对象 scrcu_offline_refund_orders
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "扫码退款")
|
||||
@Table(name = "scrcu_offline_refund_orders")
|
||||
public class ScrcuOfflineRefundOrders extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 商户编号 */
|
||||
@ApiModelProperty(notes = "商户编号")
|
||||
@Excel(name = "商户编号")
|
||||
private String mchtNo;
|
||||
|
||||
/** 退款订单 */
|
||||
@ApiModelProperty(notes = "退款订单")
|
||||
@Excel(name = "退款订单")
|
||||
private String reqSsn;
|
||||
|
||||
/** 请求时间 */
|
||||
@ApiModelProperty(notes = "请求时间")
|
||||
@Excel(name = "请求时间")
|
||||
private String reqTime;
|
||||
|
||||
/** 原订单号 */
|
||||
@ApiModelProperty(notes = "原订单号")
|
||||
@Excel(name = "原订单号")
|
||||
private String origReqSsn;
|
||||
|
||||
/** 原请求时间 */
|
||||
@ApiModelProperty(notes = "原请求时间")
|
||||
@Excel(name = "原请求时间")
|
||||
private String origReqTime;
|
||||
|
||||
/** 原响应流水 */
|
||||
@ApiModelProperty(notes = "原响应流水")
|
||||
@Excel(name = "原响应流水")
|
||||
private String origRespSsn;
|
||||
|
||||
/** 原响应时间 */
|
||||
@ApiModelProperty(notes = "原响应时间")
|
||||
@Excel(name = "原响应时间")
|
||||
private String origRespTime;
|
||||
|
||||
/** 退款金额 */
|
||||
@ApiModelProperty(notes = "退款金额")
|
||||
@Excel(name = "退款金额")
|
||||
private String orderAmt;
|
||||
|
||||
/** 退款描述 */
|
||||
@ApiModelProperty(notes = "退款描述")
|
||||
@Excel(name = "退款描述")
|
||||
private String orderDesc;
|
||||
|
||||
/** 退款响应流水号 */
|
||||
@ApiModelProperty(notes = "退款响应流水号")
|
||||
@Excel(name = "退款响应流水号")
|
||||
private String respSsn;
|
||||
|
||||
/** 退款响应时间 */
|
||||
@ApiModelProperty(notes = "退款响应时间")
|
||||
@Excel(name = "退款响应时间")
|
||||
private String respTime;
|
||||
|
||||
/** 订单状态(00订单成功 01已撤销 02已发生退款 03已关闭 09订单失败 10订单已受理 11订单处理中 12用户输密中 13订单处理超时)] */
|
||||
@ApiModelProperty(notes = "订单状态(00订单成功 01已撤销 02已发生退款 03已关闭 09订单失败 10订单已受理 11订单处理中 12用户输密中 13订单处理超时)]")
|
||||
@Excel(name = "订单状态", readConverterExp = "0=0订单成功,0=1已撤销,0=2已发生退款,0=3已关闭,0=9订单失败,1=0订单已受理,1=1订单处理中,1=2用户输密中,1=3订单处理超时")
|
||||
private String orderState;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,82 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 收单详情对象 scrcu_online_order_details
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "收单列表")
|
||||
@Table(name = "scrcu_online_order_details")
|
||||
public class ScrcuOnlineOrderDetails extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 商户号 */
|
||||
@ApiModelProperty(notes = "商户号")
|
||||
@Excel(name = "商户号")
|
||||
private String merId;
|
||||
|
||||
/** 父商户号 */
|
||||
@ApiModelProperty(notes = "父商户号")
|
||||
@Excel(name = "父商户号")
|
||||
private String parentMerId;
|
||||
|
||||
/** 机构编码 */
|
||||
@ApiModelProperty(notes = "机构编码")
|
||||
@Excel(name = "机构编码")
|
||||
private String orgCode;
|
||||
|
||||
/** 主订单号 */
|
||||
@ApiModelProperty(notes = "主订单号")
|
||||
@Excel(name = "主订单号")
|
||||
private String orderNumber;
|
||||
|
||||
/** 子订单号 */
|
||||
@ApiModelProperty(notes = "子订单号")
|
||||
@Excel(name = "子订单号")
|
||||
private String subOrderNumber;
|
||||
|
||||
/** 交易金额 */
|
||||
@ApiModelProperty(notes = "交易金额")
|
||||
@Excel(name = "交易金额")
|
||||
private String subOrderAmt;
|
||||
|
||||
/** 支付金额 */
|
||||
@ApiModelProperty(notes = "支付金额")
|
||||
@Excel(name = "支付金额")
|
||||
private String subPayAmt;
|
||||
|
||||
/** 物流码 */
|
||||
@ApiModelProperty(notes = "物流码")
|
||||
private String logisCode;
|
||||
|
||||
/** 机构红包 */
|
||||
@ApiModelProperty(notes = "机构红包")
|
||||
private String redPacketOrgNo;
|
||||
|
||||
/** 结算标记(0不自动结算 1自动结算) */
|
||||
@ApiModelProperty(notes = "结算标记(0不自动结算 1自动结算)")
|
||||
@Excel(name = "结算标记", readConverterExp = "0=不自动结算,1=自动结算")
|
||||
private String autoSettleFlag;
|
||||
|
||||
/** 商品信息 */
|
||||
@ApiModelProperty(notes = "商品信息")
|
||||
@Excel(name = "商品信息")
|
||||
private String goodsInfo;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,157 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Date;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 收单列表对象 scrcu_online_orders
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "收单列表")
|
||||
@Table(name = "scrcu_online_orders")
|
||||
public class ScrcuOnlineOrders extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 用户ID */
|
||||
@ApiModelProperty(notes = "用户ID")
|
||||
@Excel(name = "用户ID")
|
||||
private Long memberId;
|
||||
|
||||
/** 商户代码 */
|
||||
@ApiModelProperty(notes = "商户代码")
|
||||
@Excel(name = "商户代码")
|
||||
private String merId;
|
||||
|
||||
/** 订单类型(01实物消费订单,固定值) */
|
||||
@ApiModelProperty(notes = "订单类型(01实物消费订单,固定值)")
|
||||
private String orderType;
|
||||
|
||||
/** 订单号 */
|
||||
@ApiModelProperty(notes = "订单号")
|
||||
@Excel(name = "订单号")
|
||||
private String orderNumber;
|
||||
|
||||
/** 订单发送时间,格式: yyyyMMddHHmmss */
|
||||
@ApiModelProperty(notes = "订单发送时间,格式: yyyyMMddHHmmss")
|
||||
@Excel(name = "订单发送时间,格式: yyyyMMddHHmmss")
|
||||
private String orderSendTime;
|
||||
|
||||
/** 订单总金额,单位为分 */
|
||||
@ApiModelProperty(notes = "订单总金额,单位为分")
|
||||
@Excel(name = "订单总金额,单位为分")
|
||||
private String orderAmt;
|
||||
|
||||
/** 支付总金额,单位为分(包含物流,不包含红包) */
|
||||
@ApiModelProperty(notes = "支付总金额,单位为分(包含物流,不包含红包)")
|
||||
@Excel(name = "支付总金额,单位为分(包含物流,不包含红包)")
|
||||
private String payAmt;
|
||||
|
||||
/** 商品名称 */
|
||||
@ApiModelProperty(notes = "商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String goodsSubject;
|
||||
|
||||
/** 交易币种(01人民币) */
|
||||
@ApiModelProperty(notes = "交易币种(01人民币)")
|
||||
@Excel(name = "交易币种", readConverterExp = "0=1人民币")
|
||||
private String orderCurrency;
|
||||
|
||||
/** 接入渠道(01PC 02手机) */
|
||||
@ApiModelProperty(notes = "接入渠道(01PC 02手机)")
|
||||
@Excel(name = "接入渠道", readConverterExp = "0=1PC,0=2手机")
|
||||
private String channel;
|
||||
|
||||
/** 接入方式(01H5商城 02APP商城 03微信公众号商城 04小程序商城 05其它(当channel为02时必填)) */
|
||||
@ApiModelProperty(notes = "接入方式(01H5商城 02APP商城 03微信公众号商城 04小程序商城 05其它(当channel为02时必填))")
|
||||
@Excel(name = "接入方式", readConverterExp = "0=1H5商城,0=2APP商城,0=3微信公众号商城,0=4小程序商城,0=5其它(当channel为02时必填)")
|
||||
private String mobileWay;
|
||||
|
||||
/** 手机接入类型(01安卓 02IOS系统(当mobileWay为02时必填)) */
|
||||
@ApiModelProperty(notes = "手机接入类型(01安卓 02IOS系统(当mobileWay为02时必填))")
|
||||
@Excel(name = "手机接入类型", readConverterExp = "0=1安卓,0=2IOS系统(当mobileWay为02时必填)")
|
||||
private String mobileType;
|
||||
|
||||
/** 前端通知地址 */
|
||||
@ApiModelProperty(notes = "前端通知地址")
|
||||
private String frontEndUrl;
|
||||
|
||||
/** 后台通知地址 */
|
||||
@ApiModelProperty(notes = "后台通知地址")
|
||||
private String backEndUrl;
|
||||
|
||||
/** 收单主订单号 */
|
||||
@ApiModelProperty(notes = "收单主订单号")
|
||||
@Excel(name = "收单主订单号")
|
||||
private String orderSeqId;
|
||||
|
||||
/** 支付类型(00蜀信e支付 01蜀信卡快捷支付 02银联支付 03微信支付 04支付宝支付 05授信支付 10积分支付) */
|
||||
@ApiModelProperty(notes = "支付类型(00蜀信e支付 01蜀信卡快捷支付 02银联支付 03微信支付 04支付宝支付 05授信支付 10积分支付)")
|
||||
@Excel(name = "支付类型", readConverterExp = "0=0蜀信e支付,0=1蜀信卡快捷支付,0=2银联支付,0=3微信支付,0=4支付宝支付,0=5授信支付,1=0积分支付")
|
||||
private String payType;
|
||||
|
||||
/** 交易类型(01消费 02退货 03撤销 04查询) */
|
||||
@ApiModelProperty(notes = "交易类型(01消费 02退货 03撤销 04查询)")
|
||||
@Excel(name = "交易类型", readConverterExp = "0=1消费,0=2退货,0=3撤销,0=4查询")
|
||||
private String transType;
|
||||
|
||||
/** 交易状态(02成功) */
|
||||
@ApiModelProperty(notes = "交易状态(02成功)")
|
||||
@Excel(name = "交易状态", readConverterExp = "0=2成功")
|
||||
private String payStatus;
|
||||
|
||||
/** 订单种类(1收单支付 2扫码支付) */
|
||||
@ApiModelProperty(notes = "订单种类(1收单支付 2扫码支付)")
|
||||
@Excel(name = "订单种类", readConverterExp = "1=收单支付,2=扫码支付")
|
||||
private Integer orderSpecies;
|
||||
|
||||
/** 订单状态(01交易中 02交易成功 03交易失败) */
|
||||
@ApiModelProperty(notes = "订单状态(01交易中 02交易成功 03交易失败)")
|
||||
@Excel(name = "订单状态", readConverterExp = "0=1交易中,0=2交易成功,0=3交易失败")
|
||||
private String orderState;
|
||||
|
||||
/** 支付完成时间,格式: yyyyMMddHHmmss */
|
||||
@ApiModelProperty(notes = "支付完成时间,格式: yyyyMMddHHmmss")
|
||||
@Excel(name = "支付完成时间,格式: yyyyMMddHHmmss", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date orderTranTime;
|
||||
|
||||
/** 订单创建时间,格式: yyyyMMddHHmmss */
|
||||
@ApiModelProperty(notes = "订单创建时间,格式: yyyyMMddHHmmss")
|
||||
@Excel(name = "订单创建时间,格式: yyyyMMddHHmmss", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date orderCreateTime;
|
||||
|
||||
/** 费用来源(0微信挂号 1微信门诊缴费 2微信住院预交 3分诊挂号 4分诊门诊缴费 5线下扫码支付 6诊间支付) */
|
||||
@ApiModelProperty(notes = "费用来源(0微信挂号 1微信门诊缴费 2微信住院预交 3分诊挂号 4分诊门诊缴费 5线下扫码支付 6诊间支付)")
|
||||
@Excel(name = "费用来源", readConverterExp = "0=微信挂号,1=微信门诊缴费,2=微信住院预交,3=分诊挂号,4=分诊门诊缴费,5=线下扫码支付,6=诊间支付")
|
||||
private Integer expenseType;
|
||||
|
||||
/** 支付方式类别(1微信支付 2支付宝 3农信支付) */
|
||||
@ApiModelProperty(notes = "支付方式类别(1微信支付 2支付宝 3农信支付)")
|
||||
@Excel(name = "支付方式类别", readConverterExp = "1=微信支付,2=支付宝,3=农信支付")
|
||||
private Integer payWayType;
|
||||
|
||||
/** 流水号 */
|
||||
@ApiModelProperty(notes = "流水号")
|
||||
@Excel(name = "流水号")
|
||||
private String payNo;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
/** 收单详情信息 */
|
||||
@ApiModelProperty(notes = "收单详情信息")
|
||||
private List<ScrcuOnlineOrderDetails> scrcuOnlineOrderDetailsList;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,78 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 退款订单对象 scrcu_online_refund_orders
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "退款订单")
|
||||
@Table(name = "scrcu_online_refund_orders")
|
||||
public class ScrcuOnlineRefundOrders extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 商户代码 */
|
||||
@ApiModelProperty(notes = "商户代码")
|
||||
@Excel(name = "商户代码")
|
||||
private String merId;
|
||||
|
||||
/** 退货商户号 */
|
||||
@ApiModelProperty(notes = "退货商户号")
|
||||
@Excel(name = "退货商户号")
|
||||
private String merNo;
|
||||
|
||||
/** 退款订单号 */
|
||||
@ApiModelProperty(notes = "退款订单号")
|
||||
@Excel(name = "退款订单号")
|
||||
private String orderNumber;
|
||||
|
||||
/** 发送时间 */
|
||||
@ApiModelProperty(notes = "发送时间")
|
||||
@Excel(name = "发送时间")
|
||||
private String orderSendTime;
|
||||
|
||||
/** 后台通知地址 */
|
||||
@ApiModelProperty(notes = "后台通知地址")
|
||||
private String backEndUrl;
|
||||
|
||||
/** 原支付主订单号 */
|
||||
@ApiModelProperty(notes = "原支付主订单号")
|
||||
@Excel(name = "原支付主订单号")
|
||||
private String oriOrderNumber;
|
||||
|
||||
/** 原支付子订单号 */
|
||||
@ApiModelProperty(notes = "原支付子订单号")
|
||||
@Excel(name = "原支付子订单号")
|
||||
private String oriSubOrderNumber;
|
||||
|
||||
/** 退款金额 */
|
||||
@ApiModelProperty(notes = "退款金额")
|
||||
@Excel(name = "退款金额")
|
||||
private String orderAmt;
|
||||
|
||||
/** 接入渠道(01PC 02手机wap) */
|
||||
@ApiModelProperty(notes = "接入渠道(01PC 02手机wap)")
|
||||
@Excel(name = "接入渠道", readConverterExp = "0=1PC,0=2手机wap")
|
||||
private String channel;
|
||||
|
||||
/** 订单状态(01交易中 02交易成功 03交易失败) */
|
||||
@ApiModelProperty(notes = "订单状态(01交易中 02交易成功 03交易失败)")
|
||||
@Excel(name = "订单状态", readConverterExp = "0=1交易中,0=2交易成功,0=3交易失败")
|
||||
private String orderState;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,130 @@
|
|||
package com.ruoyi.bend.domain;
|
||||
|
||||
import java.util.Date;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import javax.persistence.Table;
|
||||
|
||||
/**
|
||||
* 微信用户对象 bend_wechat_member
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
@ApiModel(value = "微信用户")
|
||||
@Table(name = "bend_wechat_member")
|
||||
public class WechatMember extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 用户ID */
|
||||
@ApiModelProperty(notes = "用户ID")
|
||||
private Long memberId;
|
||||
|
||||
/** 手机号 */
|
||||
@ApiModelProperty(notes = "手机号")
|
||||
@Excel(name = "手机号")
|
||||
private String mobilePhone;
|
||||
|
||||
/** AppId */
|
||||
@ApiModelProperty(notes = "AppId")
|
||||
@Excel(name = "AppId")
|
||||
private String appId;
|
||||
|
||||
/** OpenId */
|
||||
@ApiModelProperty(notes = "OpenId")
|
||||
@Excel(name = "OpenId")
|
||||
private String openId;
|
||||
|
||||
/** 微信昵称 */
|
||||
@ApiModelProperty(notes = "微信昵称")
|
||||
@Excel(name = "微信昵称")
|
||||
private String nickname;
|
||||
|
||||
/** 真实姓名 */
|
||||
@ApiModelProperty(notes = "真实姓名")
|
||||
@Excel(name = "真实姓名")
|
||||
private String realName;
|
||||
|
||||
/** 性别(0未知 1男 2女) */
|
||||
@ApiModelProperty(notes = "性别(0未知 1男 2女)")
|
||||
private Integer sex;
|
||||
|
||||
/** 性别描述 */
|
||||
@ApiModelProperty(notes = "性别描述")
|
||||
@Excel(name = "性别描述")
|
||||
private String sexDesc;
|
||||
|
||||
/** 关注状态(0未关注 1关注中 2已取消) */
|
||||
@ApiModelProperty(notes = "关注状态(0未关注 1关注中 2已取消)")
|
||||
@Excel(name = "关注状态", readConverterExp = "0=未关注,1=关注中,2=已取消")
|
||||
private Integer followStatus;
|
||||
|
||||
/** 订阅标识(0未订阅 1订阅中 2已取消) */
|
||||
@ApiModelProperty(notes = "订阅标识(0未订阅 1订阅中 2已取消)")
|
||||
@Excel(name = "订阅标识", readConverterExp = "0=未订阅,1=订阅中,2=已取消")
|
||||
private Integer subscribe;
|
||||
|
||||
/** 所在城市 */
|
||||
@ApiModelProperty(notes = "所在城市")
|
||||
@Excel(name = "所在城市")
|
||||
private String city;
|
||||
|
||||
/** 所在省份 */
|
||||
@ApiModelProperty(notes = "所在省份")
|
||||
@Excel(name = "所在省份")
|
||||
private String province;
|
||||
|
||||
/** 所在国家 */
|
||||
@ApiModelProperty(notes = "所在国家")
|
||||
private String country;
|
||||
|
||||
/** 用户语言 */
|
||||
@ApiModelProperty(notes = "用户语言")
|
||||
private String language;
|
||||
|
||||
/** 用户头像 */
|
||||
@ApiModelProperty(notes = "用户头像")
|
||||
@Excel(name = "用户头像")
|
||||
private String headImgUrl;
|
||||
|
||||
/** 关注时间 */
|
||||
@ApiModelProperty(notes = "关注时间")
|
||||
@Excel(name = "关注时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date subscribeTime;
|
||||
|
||||
/** UnionID */
|
||||
@ApiModelProperty(notes = "UnionID")
|
||||
private String unionid;
|
||||
|
||||
/** 分组ID */
|
||||
@ApiModelProperty(notes = "分组ID")
|
||||
private String groupId;
|
||||
|
||||
/** 标签列表 */
|
||||
@ApiModelProperty(notes = "标签列表")
|
||||
private String tagIds;
|
||||
|
||||
/** 关注渠道 */
|
||||
@ApiModelProperty(notes = "关注渠道")
|
||||
private String subscribeScene;
|
||||
|
||||
/** 扫码场景 */
|
||||
@ApiModelProperty(notes = "扫码场景")
|
||||
private String qrScene;
|
||||
|
||||
/** 场景描述 */
|
||||
@ApiModelProperty(notes = "场景描述")
|
||||
private String qrSceneStr;
|
||||
|
||||
/** 删除标记(0否 1是) */
|
||||
@ApiModelProperty(notes = "删除标记(0否 1是)")
|
||||
private Integer deleted;
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.Agreement;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 协议管理Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface AgreementMapper extends RuoYiBaseMapper<Agreement>
|
||||
{
|
||||
/**
|
||||
* 查询协议管理
|
||||
*
|
||||
* @param id 协议管理ID
|
||||
* @return 协议管理
|
||||
*/
|
||||
public Agreement selectAgreementById(Long id);
|
||||
|
||||
/**
|
||||
* 查询协议管理列表
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 协议管理集合
|
||||
*/
|
||||
public List<Agreement> selectAgreementList(Agreement agreement);
|
||||
|
||||
/**
|
||||
* 新增协议管理
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertAgreement(Agreement agreement);
|
||||
|
||||
/**
|
||||
* 修改协议管理
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateAgreement(Agreement agreement);
|
||||
|
||||
/**
|
||||
* 删除协议管理
|
||||
*
|
||||
* @param id 协议管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAgreementById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除协议管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAgreementByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.Article;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 内容管理Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface ArticleMapper extends RuoYiBaseMapper<Article>
|
||||
{
|
||||
/**
|
||||
* 查询内容管理
|
||||
*
|
||||
* @param id 内容管理ID
|
||||
* @return 内容管理
|
||||
*/
|
||||
public Article selectArticleById(Long id);
|
||||
|
||||
/**
|
||||
* 查询内容管理列表
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 内容管理集合
|
||||
*/
|
||||
public List<Article> selectArticleList(Article article);
|
||||
|
||||
/**
|
||||
* 新增内容管理
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertArticle(Article article);
|
||||
|
||||
/**
|
||||
* 修改内容管理
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateArticle(Article article);
|
||||
|
||||
/**
|
||||
* 删除内容管理
|
||||
*
|
||||
* @param id 内容管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteArticleById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除内容管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteArticleByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.Banner;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 首页管理Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface BannerMapper extends RuoYiBaseMapper<Banner>
|
||||
{
|
||||
/**
|
||||
* 查询首页管理
|
||||
*
|
||||
* @param id 首页管理ID
|
||||
* @return 首页管理
|
||||
*/
|
||||
public Banner selectBannerById(Long id);
|
||||
|
||||
/**
|
||||
* 查询首页管理列表
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 首页管理集合
|
||||
*/
|
||||
public List<Banner> selectBannerList(Banner banner);
|
||||
|
||||
/**
|
||||
* 新增首页管理
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBanner(Banner banner);
|
||||
|
||||
/**
|
||||
* 修改首页管理
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBanner(Banner banner);
|
||||
|
||||
/**
|
||||
* 删除首页管理
|
||||
*
|
||||
* @param id 首页管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBannerById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除首页管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBannerByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.Member;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 会员列表Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface MemberMapper extends RuoYiBaseMapper<Member>
|
||||
{
|
||||
/**
|
||||
* 查询会员列表
|
||||
*
|
||||
* @param id 会员列表ID
|
||||
* @return 会员列表
|
||||
*/
|
||||
public Member selectMemberById(Long id);
|
||||
|
||||
/**
|
||||
* 查询会员列表列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 会员列表集合
|
||||
*/
|
||||
public List<Member> selectMemberList(Member member);
|
||||
|
||||
/**
|
||||
* 新增会员列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMember(Member member);
|
||||
|
||||
/**
|
||||
* 修改会员列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMember(Member member);
|
||||
|
||||
/**
|
||||
* 删除会员列表
|
||||
*
|
||||
* @param id 会员列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMemberById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除会员列表
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMemberByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.MessageCode;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 短信管理Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface MessageCodeMapper extends RuoYiBaseMapper<MessageCode>
|
||||
{
|
||||
/**
|
||||
* 查询短信管理
|
||||
*
|
||||
* @param id 短信管理ID
|
||||
* @return 短信管理
|
||||
*/
|
||||
public MessageCode selectMessageCodeById(Long id);
|
||||
|
||||
/**
|
||||
* 查询短信管理列表
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 短信管理集合
|
||||
*/
|
||||
public List<MessageCode> selectMessageCodeList(MessageCode messageCode);
|
||||
|
||||
/**
|
||||
* 新增短信管理
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMessageCode(MessageCode messageCode);
|
||||
|
||||
/**
|
||||
* 修改短信管理
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMessageCode(MessageCode messageCode);
|
||||
|
||||
/**
|
||||
* 删除短信管理
|
||||
*
|
||||
* @param id 短信管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMessageCodeById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除短信管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMessageCodeByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.PatientList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 就诊人列表Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface PatientListMapper extends RuoYiBaseMapper<PatientList>
|
||||
{
|
||||
/**
|
||||
* 查询就诊人列表
|
||||
*
|
||||
* @param id 就诊人列表ID
|
||||
* @return 就诊人列表
|
||||
*/
|
||||
public PatientList selectPatientListById(Long id);
|
||||
|
||||
/**
|
||||
* 查询就诊人列表列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 就诊人列表集合
|
||||
*/
|
||||
public List<PatientList> selectPatientListList(PatientList patientList);
|
||||
|
||||
/**
|
||||
* 新增就诊人列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPatientList(PatientList patientList);
|
||||
|
||||
/**
|
||||
* 修改就诊人列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int updatePatientList(PatientList patientList);
|
||||
|
||||
/**
|
||||
* 删除就诊人列表
|
||||
*
|
||||
* @param id 就诊人列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePatientListById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除就诊人列表
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePatientListByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineOrders;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 线下订单Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface ScrcuOfflineOrdersMapper extends RuoYiBaseMapper<ScrcuOfflineOrders>
|
||||
{
|
||||
/**
|
||||
* 查询线下订单
|
||||
*
|
||||
* @param id 线下订单ID
|
||||
* @return 线下订单
|
||||
*/
|
||||
public ScrcuOfflineOrders selectScrcuOfflineOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询线下订单列表
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 线下订单集合
|
||||
*/
|
||||
public List<ScrcuOfflineOrders> selectScrcuOfflineOrdersList(ScrcuOfflineOrders scrcuOfflineOrders);
|
||||
|
||||
/**
|
||||
* 新增线下订单
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOfflineOrders(ScrcuOfflineOrders scrcuOfflineOrders);
|
||||
|
||||
/**
|
||||
* 修改线下订单
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOfflineOrders(ScrcuOfflineOrders scrcuOfflineOrders);
|
||||
|
||||
/**
|
||||
* 删除线下订单
|
||||
*
|
||||
* @param id 线下订单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除线下订单
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineOrdersByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineRefundOrders;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 扫码退款Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface ScrcuOfflineRefundOrdersMapper extends RuoYiBaseMapper<ScrcuOfflineRefundOrders>
|
||||
{
|
||||
/**
|
||||
* 查询扫码退款
|
||||
*
|
||||
* @param id 扫码退款ID
|
||||
* @return 扫码退款
|
||||
*/
|
||||
public ScrcuOfflineRefundOrders selectScrcuOfflineRefundOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询扫码退款列表
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 扫码退款集合
|
||||
*/
|
||||
public List<ScrcuOfflineRefundOrders> selectScrcuOfflineRefundOrdersList(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders);
|
||||
|
||||
/**
|
||||
* 新增扫码退款
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOfflineRefundOrders(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders);
|
||||
|
||||
/**
|
||||
* 修改扫码退款
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOfflineRefundOrders(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders);
|
||||
|
||||
/**
|
||||
* 删除扫码退款
|
||||
*
|
||||
* @param id 扫码退款ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineRefundOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除扫码退款
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineRefundOrdersByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrderDetails;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 收单详情Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface ScrcuOnlineOrderDetailsMapper extends RuoYiBaseMapper<ScrcuOnlineOrderDetails>
|
||||
{
|
||||
/**
|
||||
* 查询收单详情
|
||||
*
|
||||
* @param id 收单详情ID
|
||||
* @return 收单详情
|
||||
*/
|
||||
public ScrcuOnlineOrderDetails selectScrcuOnlineOrderDetailsById(Long id);
|
||||
|
||||
/**
|
||||
* 查询收单详情列表
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 收单详情集合
|
||||
*/
|
||||
public List<ScrcuOnlineOrderDetails> selectScrcuOnlineOrderDetailsList(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails);
|
||||
|
||||
/**
|
||||
* 新增收单详情
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOnlineOrderDetails(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails);
|
||||
|
||||
/**
|
||||
* 修改收单详情
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOnlineOrderDetails(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails);
|
||||
|
||||
/**
|
||||
* 删除收单详情
|
||||
*
|
||||
* @param id 收单详情ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrderDetailsById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除收单详情
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrderDetailsByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,88 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrders;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrderDetails;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 收单列表Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface ScrcuOnlineOrdersMapper extends RuoYiBaseMapper<ScrcuOnlineOrders>
|
||||
{
|
||||
/**
|
||||
* 查询收单列表
|
||||
*
|
||||
* @param id 收单列表ID
|
||||
* @return 收单列表
|
||||
*/
|
||||
public ScrcuOnlineOrders selectScrcuOnlineOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询收单列表列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 收单列表集合
|
||||
*/
|
||||
public List<ScrcuOnlineOrders> selectScrcuOnlineOrdersList(ScrcuOnlineOrders scrcuOnlineOrders);
|
||||
|
||||
/**
|
||||
* 新增收单列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders);
|
||||
|
||||
/**
|
||||
* 修改收单列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders);
|
||||
|
||||
/**
|
||||
* 删除收单列表
|
||||
*
|
||||
* @param id 收单列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除收单列表
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrdersByIds(String[] ids);
|
||||
|
||||
/**
|
||||
* 批量删除收单详情
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrderDetailsByOrderNumbers(String[] ids);
|
||||
|
||||
/**
|
||||
* 批量新增收单详情
|
||||
*
|
||||
* @param scrcuOnlineOrderDetailsList 收单详情列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int batchScrcuOnlineOrderDetails(List<ScrcuOnlineOrderDetails> scrcuOnlineOrderDetailsList);
|
||||
|
||||
|
||||
/**
|
||||
* 通过收单列表ID删除收单详情信息
|
||||
*
|
||||
* @param id 收单列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrderDetailsByOrderNumber(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineRefundOrders;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 退款订单Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface ScrcuOnlineRefundOrdersMapper extends RuoYiBaseMapper<ScrcuOnlineRefundOrders>
|
||||
{
|
||||
/**
|
||||
* 查询退款订单
|
||||
*
|
||||
* @param id 退款订单ID
|
||||
* @return 退款订单
|
||||
*/
|
||||
public ScrcuOnlineRefundOrders selectScrcuOnlineRefundOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询退款订单列表
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 退款订单集合
|
||||
*/
|
||||
public List<ScrcuOnlineRefundOrders> selectScrcuOnlineRefundOrdersList(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders);
|
||||
|
||||
/**
|
||||
* 新增退款订单
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOnlineRefundOrders(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders);
|
||||
|
||||
/**
|
||||
* 修改退款订单
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOnlineRefundOrders(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders);
|
||||
|
||||
/**
|
||||
* 删除退款订单
|
||||
*
|
||||
* @param id 退款订单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineRefundOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除退款订单
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineRefundOrdersByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,62 @@
|
|||
package com.ruoyi.bend.mapper;
|
||||
|
||||
import com.ruoyi.common.mappers.RuoYiBaseMapper;
|
||||
import com.ruoyi.bend.domain.WechatMember;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 微信用户Mapper接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface WechatMemberMapper extends RuoYiBaseMapper<WechatMember>
|
||||
{
|
||||
/**
|
||||
* 查询微信用户
|
||||
*
|
||||
* @param id 微信用户ID
|
||||
* @return 微信用户
|
||||
*/
|
||||
public WechatMember selectWechatMemberById(Long id);
|
||||
|
||||
/**
|
||||
* 查询微信用户列表
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 微信用户集合
|
||||
*/
|
||||
public List<WechatMember> selectWechatMemberList(WechatMember wechatMember);
|
||||
|
||||
/**
|
||||
* 新增微信用户
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWechatMember(WechatMember wechatMember);
|
||||
|
||||
/**
|
||||
* 修改微信用户
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWechatMember(WechatMember wechatMember);
|
||||
|
||||
/**
|
||||
* 删除微信用户
|
||||
*
|
||||
* @param id 微信用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWechatMemberById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除微信用户
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWechatMemberByIds(String[] ids);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.Agreement;
|
||||
|
||||
/**
|
||||
* 协议管理Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface IAgreementService
|
||||
{
|
||||
/**
|
||||
* 查询协议管理
|
||||
*
|
||||
* @param id 协议管理ID
|
||||
* @return 协议管理
|
||||
*/
|
||||
public Agreement selectAgreementById(Long id);
|
||||
|
||||
/**
|
||||
* 查询协议管理列表
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 协议管理集合
|
||||
*/
|
||||
public List<Agreement> selectAgreementList(Agreement agreement);
|
||||
|
||||
/**
|
||||
* 新增协议管理
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertAgreement(Agreement agreement);
|
||||
|
||||
/**
|
||||
* 修改协议管理
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateAgreement(Agreement agreement);
|
||||
|
||||
/**
|
||||
* 批量删除协议管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAgreementByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除协议管理信息
|
||||
*
|
||||
* @param id 协议管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteAgreementById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.Article;
|
||||
|
||||
/**
|
||||
* 内容管理Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface IArticleService
|
||||
{
|
||||
/**
|
||||
* 查询内容管理
|
||||
*
|
||||
* @param id 内容管理ID
|
||||
* @return 内容管理
|
||||
*/
|
||||
public Article selectArticleById(Long id);
|
||||
|
||||
/**
|
||||
* 查询内容管理列表
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 内容管理集合
|
||||
*/
|
||||
public List<Article> selectArticleList(Article article);
|
||||
|
||||
/**
|
||||
* 新增内容管理
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertArticle(Article article);
|
||||
|
||||
/**
|
||||
* 修改内容管理
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateArticle(Article article);
|
||||
|
||||
/**
|
||||
* 批量删除内容管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteArticleByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除内容管理信息
|
||||
*
|
||||
* @param id 内容管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteArticleById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.Banner;
|
||||
|
||||
/**
|
||||
* 首页管理Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface IBannerService
|
||||
{
|
||||
/**
|
||||
* 查询首页管理
|
||||
*
|
||||
* @param id 首页管理ID
|
||||
* @return 首页管理
|
||||
*/
|
||||
public Banner selectBannerById(Long id);
|
||||
|
||||
/**
|
||||
* 查询首页管理列表
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 首页管理集合
|
||||
*/
|
||||
public List<Banner> selectBannerList(Banner banner);
|
||||
|
||||
/**
|
||||
* 新增首页管理
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBanner(Banner banner);
|
||||
|
||||
/**
|
||||
* 修改首页管理
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBanner(Banner banner);
|
||||
|
||||
/**
|
||||
* 批量删除首页管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBannerByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除首页管理信息
|
||||
*
|
||||
* @param id 首页管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBannerById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.Member;
|
||||
|
||||
/**
|
||||
* 会员列表Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface IMemberService
|
||||
{
|
||||
/**
|
||||
* 查询会员列表
|
||||
*
|
||||
* @param id 会员列表ID
|
||||
* @return 会员列表
|
||||
*/
|
||||
public Member selectMemberById(Long id);
|
||||
|
||||
/**
|
||||
* 查询会员列表列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 会员列表集合
|
||||
*/
|
||||
public List<Member> selectMemberList(Member member);
|
||||
|
||||
/**
|
||||
* 新增会员列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMember(Member member);
|
||||
|
||||
/**
|
||||
* 修改会员列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMember(Member member);
|
||||
|
||||
/**
|
||||
* 批量删除会员列表
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMemberByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除会员列表信息
|
||||
*
|
||||
* @param id 会员列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMemberById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.MessageCode;
|
||||
|
||||
/**
|
||||
* 短信管理Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface IMessageCodeService
|
||||
{
|
||||
/**
|
||||
* 查询短信管理
|
||||
*
|
||||
* @param id 短信管理ID
|
||||
* @return 短信管理
|
||||
*/
|
||||
public MessageCode selectMessageCodeById(Long id);
|
||||
|
||||
/**
|
||||
* 查询短信管理列表
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 短信管理集合
|
||||
*/
|
||||
public List<MessageCode> selectMessageCodeList(MessageCode messageCode);
|
||||
|
||||
/**
|
||||
* 新增短信管理
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMessageCode(MessageCode messageCode);
|
||||
|
||||
/**
|
||||
* 修改短信管理
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMessageCode(MessageCode messageCode);
|
||||
|
||||
/**
|
||||
* 批量删除短信管理
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMessageCodeByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除短信管理信息
|
||||
*
|
||||
* @param id 短信管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMessageCodeById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.PatientList;
|
||||
|
||||
/**
|
||||
* 就诊人列表Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface IPatientListService
|
||||
{
|
||||
/**
|
||||
* 查询就诊人列表
|
||||
*
|
||||
* @param id 就诊人列表ID
|
||||
* @return 就诊人列表
|
||||
*/
|
||||
public PatientList selectPatientListById(Long id);
|
||||
|
||||
/**
|
||||
* 查询就诊人列表列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 就诊人列表集合
|
||||
*/
|
||||
public List<PatientList> selectPatientListList(PatientList patientList);
|
||||
|
||||
/**
|
||||
* 新增就诊人列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPatientList(PatientList patientList);
|
||||
|
||||
/**
|
||||
* 修改就诊人列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int updatePatientList(PatientList patientList);
|
||||
|
||||
/**
|
||||
* 批量删除就诊人列表
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePatientListByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除就诊人列表信息
|
||||
*
|
||||
* @param id 就诊人列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePatientListById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineOrders;
|
||||
|
||||
/**
|
||||
* 线下订单Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface IScrcuOfflineOrdersService
|
||||
{
|
||||
/**
|
||||
* 查询线下订单
|
||||
*
|
||||
* @param id 线下订单ID
|
||||
* @return 线下订单
|
||||
*/
|
||||
public ScrcuOfflineOrders selectScrcuOfflineOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询线下订单列表
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 线下订单集合
|
||||
*/
|
||||
public List<ScrcuOfflineOrders> selectScrcuOfflineOrdersList(ScrcuOfflineOrders scrcuOfflineOrders);
|
||||
|
||||
/**
|
||||
* 新增线下订单
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOfflineOrders(ScrcuOfflineOrders scrcuOfflineOrders);
|
||||
|
||||
/**
|
||||
* 修改线下订单
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOfflineOrders(ScrcuOfflineOrders scrcuOfflineOrders);
|
||||
|
||||
/**
|
||||
* 批量删除线下订单
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineOrdersByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除线下订单信息
|
||||
*
|
||||
* @param id 线下订单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineOrdersById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineRefundOrders;
|
||||
|
||||
/**
|
||||
* 扫码退款Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface IScrcuOfflineRefundOrdersService
|
||||
{
|
||||
/**
|
||||
* 查询扫码退款
|
||||
*
|
||||
* @param id 扫码退款ID
|
||||
* @return 扫码退款
|
||||
*/
|
||||
public ScrcuOfflineRefundOrders selectScrcuOfflineRefundOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询扫码退款列表
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 扫码退款集合
|
||||
*/
|
||||
public List<ScrcuOfflineRefundOrders> selectScrcuOfflineRefundOrdersList(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders);
|
||||
|
||||
/**
|
||||
* 新增扫码退款
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOfflineRefundOrders(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders);
|
||||
|
||||
/**
|
||||
* 修改扫码退款
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOfflineRefundOrders(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders);
|
||||
|
||||
/**
|
||||
* 批量删除扫码退款
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineRefundOrdersByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除扫码退款信息
|
||||
*
|
||||
* @param id 扫码退款ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOfflineRefundOrdersById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrderDetails;
|
||||
|
||||
/**
|
||||
* 收单详情Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface IScrcuOnlineOrderDetailsService
|
||||
{
|
||||
/**
|
||||
* 查询收单详情
|
||||
*
|
||||
* @param id 收单详情ID
|
||||
* @return 收单详情
|
||||
*/
|
||||
public ScrcuOnlineOrderDetails selectScrcuOnlineOrderDetailsById(Long id);
|
||||
|
||||
/**
|
||||
* 查询收单详情列表
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 收单详情集合
|
||||
*/
|
||||
public List<ScrcuOnlineOrderDetails> selectScrcuOnlineOrderDetailsList(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails);
|
||||
|
||||
/**
|
||||
* 新增收单详情
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOnlineOrderDetails(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails);
|
||||
|
||||
/**
|
||||
* 修改收单详情
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOnlineOrderDetails(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails);
|
||||
|
||||
/**
|
||||
* 批量删除收单详情
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrderDetailsByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除收单详情信息
|
||||
*
|
||||
* @param id 收单详情ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrderDetailsById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,69 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrders;
|
||||
|
||||
/**
|
||||
* 收单列表Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface IScrcuOnlineOrdersService
|
||||
{
|
||||
/**
|
||||
* 查询收单列表
|
||||
*
|
||||
* @param id 收单列表ID
|
||||
* @return 收单列表
|
||||
*/
|
||||
public ScrcuOnlineOrders selectScrcuOnlineOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询收单列表列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 收单列表集合
|
||||
*/
|
||||
public List<ScrcuOnlineOrders> selectScrcuOnlineOrdersList(ScrcuOnlineOrders scrcuOnlineOrders);
|
||||
|
||||
/**
|
||||
* 新增收单列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders);
|
||||
|
||||
/**
|
||||
* 修改收单列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders);
|
||||
|
||||
/**
|
||||
* 批量删除收单列表
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrdersByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除收单列表信息
|
||||
*
|
||||
* @param id 收单列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询在线收单
|
||||
*
|
||||
* @param scrcuOnlineOrders 在线收单
|
||||
* @return 在线收单
|
||||
*/
|
||||
public ScrcuOnlineOrders selectScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineRefundOrders;
|
||||
|
||||
/**
|
||||
* 退款订单Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
public interface IScrcuOnlineRefundOrdersService
|
||||
{
|
||||
/**
|
||||
* 查询退款订单
|
||||
*
|
||||
* @param id 退款订单ID
|
||||
* @return 退款订单
|
||||
*/
|
||||
public ScrcuOnlineRefundOrders selectScrcuOnlineRefundOrdersById(Long id);
|
||||
|
||||
/**
|
||||
* 查询退款订单列表
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 退款订单集合
|
||||
*/
|
||||
public List<ScrcuOnlineRefundOrders> selectScrcuOnlineRefundOrdersList(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders);
|
||||
|
||||
/**
|
||||
* 新增退款订单
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertScrcuOnlineRefundOrders(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders);
|
||||
|
||||
/**
|
||||
* 修改退款订单
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateScrcuOnlineRefundOrders(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders);
|
||||
|
||||
/**
|
||||
* 批量删除退款订单
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineRefundOrdersByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除退款订单信息
|
||||
*
|
||||
* @param id 退款订单ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteScrcuOnlineRefundOrdersById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
package com.ruoyi.bend.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.bend.domain.WechatMember;
|
||||
|
||||
/**
|
||||
* 微信用户Service接口
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
public interface IWechatMemberService
|
||||
{
|
||||
/**
|
||||
* 查询微信用户
|
||||
*
|
||||
* @param id 微信用户ID
|
||||
* @return 微信用户
|
||||
*/
|
||||
public WechatMember selectWechatMemberById(Long id);
|
||||
|
||||
/**
|
||||
* 查询微信用户列表
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 微信用户集合
|
||||
*/
|
||||
public List<WechatMember> selectWechatMemberList(WechatMember wechatMember);
|
||||
|
||||
/**
|
||||
* 新增微信用户
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertWechatMember(WechatMember wechatMember);
|
||||
|
||||
/**
|
||||
* 修改微信用户
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateWechatMember(WechatMember wechatMember);
|
||||
|
||||
/**
|
||||
* 批量删除微信用户
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWechatMemberByIds(String ids);
|
||||
|
||||
/**
|
||||
* 删除微信用户信息
|
||||
*
|
||||
* @param id 微信用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteWechatMemberById(Long id);
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.AgreementMapper;
|
||||
import com.ruoyi.bend.domain.Agreement;
|
||||
import com.ruoyi.bend.service.IAgreementService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 协议管理Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Service
|
||||
public class AgreementServiceImpl implements IAgreementService
|
||||
{
|
||||
@Autowired
|
||||
private AgreementMapper agreementMapper;
|
||||
|
||||
/**
|
||||
* 查询协议管理
|
||||
*
|
||||
* @param id 协议管理ID
|
||||
* @return 协议管理
|
||||
*/
|
||||
@Override
|
||||
public Agreement selectAgreementById(Long id)
|
||||
{
|
||||
return agreementMapper.selectAgreementById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询协议管理列表
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 协议管理
|
||||
*/
|
||||
@Override
|
||||
public List<Agreement> selectAgreementList(Agreement agreement)
|
||||
{
|
||||
return agreementMapper.selectAgreementList(agreement);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增协议管理
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertAgreement(Agreement agreement)
|
||||
{
|
||||
agreement.setCreateTime(DateUtils.getNowDate());
|
||||
return agreementMapper.insertAgreement(agreement);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改协议管理
|
||||
*
|
||||
* @param agreement 协议管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateAgreement(Agreement agreement)
|
||||
{
|
||||
agreement.setUpdateTime(DateUtils.getNowDate());
|
||||
return agreementMapper.updateAgreement(agreement);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除协议管理对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteAgreementByIds(String ids)
|
||||
{
|
||||
return agreementMapper.deleteAgreementByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除协议管理信息
|
||||
*
|
||||
* @param id 协议管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteAgreementById(Long id)
|
||||
{
|
||||
return agreementMapper.deleteAgreementById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.ArticleMapper;
|
||||
import com.ruoyi.bend.domain.Article;
|
||||
import com.ruoyi.bend.service.IArticleService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 内容管理Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Service
|
||||
public class ArticleServiceImpl implements IArticleService
|
||||
{
|
||||
@Autowired
|
||||
private ArticleMapper articleMapper;
|
||||
|
||||
/**
|
||||
* 查询内容管理
|
||||
*
|
||||
* @param id 内容管理ID
|
||||
* @return 内容管理
|
||||
*/
|
||||
@Override
|
||||
public Article selectArticleById(Long id)
|
||||
{
|
||||
return articleMapper.selectArticleById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询内容管理列表
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 内容管理
|
||||
*/
|
||||
@Override
|
||||
public List<Article> selectArticleList(Article article)
|
||||
{
|
||||
return articleMapper.selectArticleList(article);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增内容管理
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertArticle(Article article)
|
||||
{
|
||||
article.setCreateTime(DateUtils.getNowDate());
|
||||
return articleMapper.insertArticle(article);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改内容管理
|
||||
*
|
||||
* @param article 内容管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateArticle(Article article)
|
||||
{
|
||||
article.setUpdateTime(DateUtils.getNowDate());
|
||||
return articleMapper.updateArticle(article);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除内容管理对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteArticleByIds(String ids)
|
||||
{
|
||||
return articleMapper.deleteArticleByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除内容管理信息
|
||||
*
|
||||
* @param id 内容管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteArticleById(Long id)
|
||||
{
|
||||
return articleMapper.deleteArticleById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.BannerMapper;
|
||||
import com.ruoyi.bend.domain.Banner;
|
||||
import com.ruoyi.bend.service.IBannerService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 首页管理Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Service
|
||||
public class BannerServiceImpl implements IBannerService
|
||||
{
|
||||
@Autowired
|
||||
private BannerMapper bannerMapper;
|
||||
|
||||
/**
|
||||
* 查询首页管理
|
||||
*
|
||||
* @param id 首页管理ID
|
||||
* @return 首页管理
|
||||
*/
|
||||
@Override
|
||||
public Banner selectBannerById(Long id)
|
||||
{
|
||||
return bannerMapper.selectBannerById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询首页管理列表
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 首页管理
|
||||
*/
|
||||
@Override
|
||||
public List<Banner> selectBannerList(Banner banner)
|
||||
{
|
||||
return bannerMapper.selectBannerList(banner);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增首页管理
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertBanner(Banner banner)
|
||||
{
|
||||
banner.setCreateTime(DateUtils.getNowDate());
|
||||
return bannerMapper.insertBanner(banner);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改首页管理
|
||||
*
|
||||
* @param banner 首页管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateBanner(Banner banner)
|
||||
{
|
||||
banner.setUpdateTime(DateUtils.getNowDate());
|
||||
return bannerMapper.updateBanner(banner);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除首页管理对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteBannerByIds(String ids)
|
||||
{
|
||||
return bannerMapper.deleteBannerByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除首页管理信息
|
||||
*
|
||||
* @param id 首页管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteBannerById(Long id)
|
||||
{
|
||||
return bannerMapper.deleteBannerById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.MemberMapper;
|
||||
import com.ruoyi.bend.domain.Member;
|
||||
import com.ruoyi.bend.service.IMemberService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 会员列表Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Service
|
||||
public class MemberServiceImpl implements IMemberService
|
||||
{
|
||||
@Autowired
|
||||
private MemberMapper memberMapper;
|
||||
|
||||
/**
|
||||
* 查询会员列表
|
||||
*
|
||||
* @param id 会员列表ID
|
||||
* @return 会员列表
|
||||
*/
|
||||
@Override
|
||||
public Member selectMemberById(Long id)
|
||||
{
|
||||
return memberMapper.selectMemberById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询会员列表列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 会员列表
|
||||
*/
|
||||
@Override
|
||||
public List<Member> selectMemberList(Member member)
|
||||
{
|
||||
return memberMapper.selectMemberList(member);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增会员列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertMember(Member member)
|
||||
{
|
||||
member.setCreateTime(DateUtils.getNowDate());
|
||||
return memberMapper.insertMember(member);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改会员列表
|
||||
*
|
||||
* @param member 会员列表
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateMember(Member member)
|
||||
{
|
||||
member.setUpdateTime(DateUtils.getNowDate());
|
||||
return memberMapper.updateMember(member);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除会员列表对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteMemberByIds(String ids)
|
||||
{
|
||||
return memberMapper.deleteMemberByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除会员列表信息
|
||||
*
|
||||
* @param id 会员列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteMemberById(Long id)
|
||||
{
|
||||
return memberMapper.deleteMemberById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.MessageCodeMapper;
|
||||
import com.ruoyi.bend.domain.MessageCode;
|
||||
import com.ruoyi.bend.service.IMessageCodeService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 短信管理Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Service
|
||||
public class MessageCodeServiceImpl implements IMessageCodeService
|
||||
{
|
||||
@Autowired
|
||||
private MessageCodeMapper messageCodeMapper;
|
||||
|
||||
/**
|
||||
* 查询短信管理
|
||||
*
|
||||
* @param id 短信管理ID
|
||||
* @return 短信管理
|
||||
*/
|
||||
@Override
|
||||
public MessageCode selectMessageCodeById(Long id)
|
||||
{
|
||||
return messageCodeMapper.selectMessageCodeById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询短信管理列表
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 短信管理
|
||||
*/
|
||||
@Override
|
||||
public List<MessageCode> selectMessageCodeList(MessageCode messageCode)
|
||||
{
|
||||
return messageCodeMapper.selectMessageCodeList(messageCode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增短信管理
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertMessageCode(MessageCode messageCode)
|
||||
{
|
||||
messageCode.setCreateTime(DateUtils.getNowDate());
|
||||
return messageCodeMapper.insertMessageCode(messageCode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改短信管理
|
||||
*
|
||||
* @param messageCode 短信管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateMessageCode(MessageCode messageCode)
|
||||
{
|
||||
messageCode.setUpdateTime(DateUtils.getNowDate());
|
||||
return messageCodeMapper.updateMessageCode(messageCode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除短信管理对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteMessageCodeByIds(String ids)
|
||||
{
|
||||
return messageCodeMapper.deleteMessageCodeByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除短信管理信息
|
||||
*
|
||||
* @param id 短信管理ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteMessageCodeById(Long id)
|
||||
{
|
||||
return messageCodeMapper.deleteMessageCodeById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.PatientListMapper;
|
||||
import com.ruoyi.bend.domain.PatientList;
|
||||
import com.ruoyi.bend.service.IPatientListService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 就诊人列表Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Service
|
||||
public class PatientListServiceImpl implements IPatientListService
|
||||
{
|
||||
@Autowired
|
||||
private PatientListMapper patientListMapper;
|
||||
|
||||
/**
|
||||
* 查询就诊人列表
|
||||
*
|
||||
* @param id 就诊人列表ID
|
||||
* @return 就诊人列表
|
||||
*/
|
||||
@Override
|
||||
public PatientList selectPatientListById(Long id)
|
||||
{
|
||||
return patientListMapper.selectPatientListById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询就诊人列表列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 就诊人列表
|
||||
*/
|
||||
@Override
|
||||
public List<PatientList> selectPatientListList(PatientList patientList)
|
||||
{
|
||||
return patientListMapper.selectPatientListList(patientList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增就诊人列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertPatientList(PatientList patientList)
|
||||
{
|
||||
patientList.setCreateTime(DateUtils.getNowDate());
|
||||
return patientListMapper.insertPatientList(patientList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改就诊人列表
|
||||
*
|
||||
* @param patientList 就诊人列表
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updatePatientList(PatientList patientList)
|
||||
{
|
||||
patientList.setUpdateTime(DateUtils.getNowDate());
|
||||
return patientListMapper.updatePatientList(patientList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除就诊人列表对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deletePatientListByIds(String ids)
|
||||
{
|
||||
return patientListMapper.deletePatientListByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除就诊人列表信息
|
||||
*
|
||||
* @param id 就诊人列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deletePatientListById(Long id)
|
||||
{
|
||||
return patientListMapper.deletePatientListById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.ScrcuOfflineOrdersMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOfflineOrdersService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 线下订单Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Service
|
||||
public class ScrcuOfflineOrdersServiceImpl implements IScrcuOfflineOrdersService
|
||||
{
|
||||
@Autowired
|
||||
private ScrcuOfflineOrdersMapper scrcuOfflineOrdersMapper;
|
||||
|
||||
/**
|
||||
* 查询线下订单
|
||||
*
|
||||
* @param id 线下订单ID
|
||||
* @return 线下订单
|
||||
*/
|
||||
@Override
|
||||
public ScrcuOfflineOrders selectScrcuOfflineOrdersById(Long id)
|
||||
{
|
||||
return scrcuOfflineOrdersMapper.selectScrcuOfflineOrdersById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询线下订单列表
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 线下订单
|
||||
*/
|
||||
@Override
|
||||
public List<ScrcuOfflineOrders> selectScrcuOfflineOrdersList(ScrcuOfflineOrders scrcuOfflineOrders)
|
||||
{
|
||||
return scrcuOfflineOrdersMapper.selectScrcuOfflineOrdersList(scrcuOfflineOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增线下订单
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertScrcuOfflineOrders(ScrcuOfflineOrders scrcuOfflineOrders)
|
||||
{
|
||||
scrcuOfflineOrders.setCreateTime(DateUtils.getNowDate());
|
||||
return scrcuOfflineOrdersMapper.insertScrcuOfflineOrders(scrcuOfflineOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改线下订单
|
||||
*
|
||||
* @param scrcuOfflineOrders 线下订单
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateScrcuOfflineOrders(ScrcuOfflineOrders scrcuOfflineOrders)
|
||||
{
|
||||
scrcuOfflineOrders.setUpdateTime(DateUtils.getNowDate());
|
||||
return scrcuOfflineOrdersMapper.updateScrcuOfflineOrders(scrcuOfflineOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除线下订单对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOfflineOrdersByIds(String ids)
|
||||
{
|
||||
return scrcuOfflineOrdersMapper.deleteScrcuOfflineOrdersByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除线下订单信息
|
||||
*
|
||||
* @param id 线下订单ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOfflineOrdersById(Long id)
|
||||
{
|
||||
return scrcuOfflineOrdersMapper.deleteScrcuOfflineOrdersById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,96 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.ScrcuOfflineRefundOrdersMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOfflineRefundOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOfflineRefundOrdersService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 扫码退款Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Service
|
||||
public class ScrcuOfflineRefundOrdersServiceImpl implements IScrcuOfflineRefundOrdersService
|
||||
{
|
||||
@Autowired
|
||||
private ScrcuOfflineRefundOrdersMapper scrcuOfflineRefundOrdersMapper;
|
||||
|
||||
/**
|
||||
* 查询扫码退款
|
||||
*
|
||||
* @param id 扫码退款ID
|
||||
* @return 扫码退款
|
||||
*/
|
||||
@Override
|
||||
public ScrcuOfflineRefundOrders selectScrcuOfflineRefundOrdersById(Long id)
|
||||
{
|
||||
return scrcuOfflineRefundOrdersMapper.selectScrcuOfflineRefundOrdersById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询扫码退款列表
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 扫码退款
|
||||
*/
|
||||
@Override
|
||||
public List<ScrcuOfflineRefundOrders> selectScrcuOfflineRefundOrdersList(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders)
|
||||
{
|
||||
return scrcuOfflineRefundOrdersMapper.selectScrcuOfflineRefundOrdersList(scrcuOfflineRefundOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增扫码退款
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertScrcuOfflineRefundOrders(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders)
|
||||
{
|
||||
scrcuOfflineRefundOrders.setCreateTime(DateUtils.getNowDate());
|
||||
return scrcuOfflineRefundOrdersMapper.insertScrcuOfflineRefundOrders(scrcuOfflineRefundOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改扫码退款
|
||||
*
|
||||
* @param scrcuOfflineRefundOrders 扫码退款
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateScrcuOfflineRefundOrders(ScrcuOfflineRefundOrders scrcuOfflineRefundOrders)
|
||||
{
|
||||
return scrcuOfflineRefundOrdersMapper.updateScrcuOfflineRefundOrders(scrcuOfflineRefundOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除扫码退款对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOfflineRefundOrdersByIds(String ids)
|
||||
{
|
||||
return scrcuOfflineRefundOrdersMapper.deleteScrcuOfflineRefundOrdersByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除扫码退款信息
|
||||
*
|
||||
* @param id 扫码退款ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOfflineRefundOrdersById(Long id)
|
||||
{
|
||||
return scrcuOfflineRefundOrdersMapper.deleteScrcuOfflineRefundOrdersById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,96 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.ScrcuOnlineOrderDetailsMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrderDetails;
|
||||
import com.ruoyi.bend.service.IScrcuOnlineOrderDetailsService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 收单详情Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Service
|
||||
public class ScrcuOnlineOrderDetailsServiceImpl implements IScrcuOnlineOrderDetailsService
|
||||
{
|
||||
@Autowired
|
||||
private ScrcuOnlineOrderDetailsMapper scrcuOnlineOrderDetailsMapper;
|
||||
|
||||
/**
|
||||
* 查询收单详情
|
||||
*
|
||||
* @param id 收单详情ID
|
||||
* @return 收单详情
|
||||
*/
|
||||
@Override
|
||||
public ScrcuOnlineOrderDetails selectScrcuOnlineOrderDetailsById(Long id)
|
||||
{
|
||||
return scrcuOnlineOrderDetailsMapper.selectScrcuOnlineOrderDetailsById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询收单详情列表
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 收单详情
|
||||
*/
|
||||
@Override
|
||||
public List<ScrcuOnlineOrderDetails> selectScrcuOnlineOrderDetailsList(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails)
|
||||
{
|
||||
return scrcuOnlineOrderDetailsMapper.selectScrcuOnlineOrderDetailsList(scrcuOnlineOrderDetails);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增收单详情
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertScrcuOnlineOrderDetails(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails)
|
||||
{
|
||||
scrcuOnlineOrderDetails.setCreateTime(DateUtils.getNowDate());
|
||||
return scrcuOnlineOrderDetailsMapper.insertScrcuOnlineOrderDetails(scrcuOnlineOrderDetails);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改收单详情
|
||||
*
|
||||
* @param scrcuOnlineOrderDetails 收单详情
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateScrcuOnlineOrderDetails(ScrcuOnlineOrderDetails scrcuOnlineOrderDetails)
|
||||
{
|
||||
return scrcuOnlineOrderDetailsMapper.updateScrcuOnlineOrderDetails(scrcuOnlineOrderDetails);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除收单详情对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOnlineOrderDetailsByIds(String ids)
|
||||
{
|
||||
return scrcuOnlineOrderDetailsMapper.deleteScrcuOnlineOrderDetailsByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除收单详情信息
|
||||
*
|
||||
* @param id 收单详情ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOnlineOrderDetailsById(Long id)
|
||||
{
|
||||
return scrcuOnlineOrderDetailsMapper.deleteScrcuOnlineOrderDetailsById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,146 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.ArrayList;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrderDetails;
|
||||
import com.ruoyi.bend.mapper.ScrcuOnlineOrdersMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOnlineOrdersService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 收单列表Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Service
|
||||
public class ScrcuOnlineOrdersServiceImpl implements IScrcuOnlineOrdersService
|
||||
{
|
||||
@Autowired
|
||||
private ScrcuOnlineOrdersMapper scrcuOnlineOrdersMapper;
|
||||
|
||||
/**
|
||||
* 查询收单列表
|
||||
*
|
||||
* @param id 收单列表ID
|
||||
* @return 收单列表
|
||||
*/
|
||||
@Override
|
||||
public ScrcuOnlineOrders selectScrcuOnlineOrdersById(Long id)
|
||||
{
|
||||
return scrcuOnlineOrdersMapper.selectScrcuOnlineOrdersById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询收单列表列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 收单列表
|
||||
*/
|
||||
@Override
|
||||
public List<ScrcuOnlineOrders> selectScrcuOnlineOrdersList(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
return scrcuOnlineOrdersMapper.selectScrcuOnlineOrdersList(scrcuOnlineOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增收单列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 结果
|
||||
*/
|
||||
@Transactional
|
||||
@Override
|
||||
public int insertScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
scrcuOnlineOrders.setCreateTime(DateUtils.getNowDate());
|
||||
int rows = scrcuOnlineOrdersMapper.insertScrcuOnlineOrders(scrcuOnlineOrders);
|
||||
insertScrcuOnlineOrderDetails(scrcuOnlineOrders);
|
||||
return rows;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改收单列表
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表
|
||||
* @return 结果
|
||||
*/
|
||||
@Transactional
|
||||
@Override
|
||||
public int updateScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
scrcuOnlineOrders.setUpdateTime(DateUtils.getNowDate());
|
||||
scrcuOnlineOrdersMapper.deleteScrcuOnlineOrderDetailsByOrderNumber(scrcuOnlineOrders.getId());
|
||||
insertScrcuOnlineOrderDetails(scrcuOnlineOrders);
|
||||
return scrcuOnlineOrdersMapper.updateScrcuOnlineOrders(scrcuOnlineOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除收单列表对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Transactional
|
||||
@Override
|
||||
public int deleteScrcuOnlineOrdersByIds(String ids)
|
||||
{
|
||||
scrcuOnlineOrdersMapper.deleteScrcuOnlineOrderDetailsByOrderNumbers(Convert.toStrArray(ids));
|
||||
return scrcuOnlineOrdersMapper.deleteScrcuOnlineOrdersByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除收单列表信息
|
||||
*
|
||||
* @param id 收单列表ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOnlineOrdersById(Long id)
|
||||
{
|
||||
scrcuOnlineOrdersMapper.deleteScrcuOnlineOrderDetailsByOrderNumber(id);
|
||||
return scrcuOnlineOrdersMapper.deleteScrcuOnlineOrdersById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增收单详情信息
|
||||
*
|
||||
* @param scrcuOnlineOrders 收单列表对象
|
||||
*/
|
||||
public void insertScrcuOnlineOrderDetails(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
List<ScrcuOnlineOrderDetails> scrcuOnlineOrderDetailsList = scrcuOnlineOrders.getScrcuOnlineOrderDetailsList();
|
||||
Long id = scrcuOnlineOrders.getId();
|
||||
if (StringUtils.isNotNull(scrcuOnlineOrderDetailsList))
|
||||
{
|
||||
List<ScrcuOnlineOrderDetails> list = new ArrayList<ScrcuOnlineOrderDetails>();
|
||||
for (ScrcuOnlineOrderDetails scrcuOnlineOrderDetails : scrcuOnlineOrderDetailsList)
|
||||
{
|
||||
scrcuOnlineOrderDetails.setId(id);
|
||||
list.add(scrcuOnlineOrderDetails);
|
||||
}
|
||||
if (list.size() > 0)
|
||||
{
|
||||
scrcuOnlineOrdersMapper.batchScrcuOnlineOrderDetails(list);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询在线收单
|
||||
*
|
||||
* @param scrcuOnlineOrders 在线收单ID
|
||||
* @return 在线收单
|
||||
*/
|
||||
@Override
|
||||
public ScrcuOnlineOrders selectScrcuOnlineOrders(ScrcuOnlineOrders scrcuOnlineOrders)
|
||||
{
|
||||
return scrcuOnlineOrdersMapper.selectOne(scrcuOnlineOrders);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,96 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.ScrcuOnlineRefundOrdersMapper;
|
||||
import com.ruoyi.bend.domain.ScrcuOnlineRefundOrders;
|
||||
import com.ruoyi.bend.service.IScrcuOnlineRefundOrdersService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 退款订单Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-09-01
|
||||
*/
|
||||
@Service
|
||||
public class ScrcuOnlineRefundOrdersServiceImpl implements IScrcuOnlineRefundOrdersService
|
||||
{
|
||||
@Autowired
|
||||
private ScrcuOnlineRefundOrdersMapper scrcuOnlineRefundOrdersMapper;
|
||||
|
||||
/**
|
||||
* 查询退款订单
|
||||
*
|
||||
* @param id 退款订单ID
|
||||
* @return 退款订单
|
||||
*/
|
||||
@Override
|
||||
public ScrcuOnlineRefundOrders selectScrcuOnlineRefundOrdersById(Long id)
|
||||
{
|
||||
return scrcuOnlineRefundOrdersMapper.selectScrcuOnlineRefundOrdersById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询退款订单列表
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 退款订单
|
||||
*/
|
||||
@Override
|
||||
public List<ScrcuOnlineRefundOrders> selectScrcuOnlineRefundOrdersList(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders)
|
||||
{
|
||||
return scrcuOnlineRefundOrdersMapper.selectScrcuOnlineRefundOrdersList(scrcuOnlineRefundOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增退款订单
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertScrcuOnlineRefundOrders(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders)
|
||||
{
|
||||
scrcuOnlineRefundOrders.setCreateTime(DateUtils.getNowDate());
|
||||
return scrcuOnlineRefundOrdersMapper.insertScrcuOnlineRefundOrders(scrcuOnlineRefundOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改退款订单
|
||||
*
|
||||
* @param scrcuOnlineRefundOrders 退款订单
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateScrcuOnlineRefundOrders(ScrcuOnlineRefundOrders scrcuOnlineRefundOrders)
|
||||
{
|
||||
return scrcuOnlineRefundOrdersMapper.updateScrcuOnlineRefundOrders(scrcuOnlineRefundOrders);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除退款订单对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOnlineRefundOrdersByIds(String ids)
|
||||
{
|
||||
return scrcuOnlineRefundOrdersMapper.deleteScrcuOnlineRefundOrdersByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除退款订单信息
|
||||
*
|
||||
* @param id 退款订单ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteScrcuOnlineRefundOrdersById(Long id)
|
||||
{
|
||||
return scrcuOnlineRefundOrdersMapper.deleteScrcuOnlineRefundOrdersById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,97 @@
|
|||
package com.ruoyi.bend.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.bend.mapper.WechatMemberMapper;
|
||||
import com.ruoyi.bend.domain.WechatMember;
|
||||
import com.ruoyi.bend.service.IWechatMemberService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
|
||||
/**
|
||||
* 微信用户Service业务层处理
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-08-30
|
||||
*/
|
||||
@Service
|
||||
public class WechatMemberServiceImpl implements IWechatMemberService
|
||||
{
|
||||
@Autowired
|
||||
private WechatMemberMapper wechatMemberMapper;
|
||||
|
||||
/**
|
||||
* 查询微信用户
|
||||
*
|
||||
* @param id 微信用户ID
|
||||
* @return 微信用户
|
||||
*/
|
||||
@Override
|
||||
public WechatMember selectWechatMemberById(Long id)
|
||||
{
|
||||
return wechatMemberMapper.selectWechatMemberById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询微信用户列表
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 微信用户
|
||||
*/
|
||||
@Override
|
||||
public List<WechatMember> selectWechatMemberList(WechatMember wechatMember)
|
||||
{
|
||||
return wechatMemberMapper.selectWechatMemberList(wechatMember);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增微信用户
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertWechatMember(WechatMember wechatMember)
|
||||
{
|
||||
wechatMember.setCreateTime(DateUtils.getNowDate());
|
||||
return wechatMemberMapper.insertWechatMember(wechatMember);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改微信用户
|
||||
*
|
||||
* @param wechatMember 微信用户
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateWechatMember(WechatMember wechatMember)
|
||||
{
|
||||
wechatMember.setUpdateTime(DateUtils.getNowDate());
|
||||
return wechatMemberMapper.updateWechatMember(wechatMember);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除微信用户对象
|
||||
*
|
||||
* @param ids 需要删除的数据ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWechatMemberByIds(String ids)
|
||||
{
|
||||
return wechatMemberMapper.deleteWechatMemberByIds(Convert.toStrArray(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除微信用户信息
|
||||
*
|
||||
* @param id 微信用户ID
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteWechatMemberById(Long id)
|
||||
{
|
||||
return wechatMemberMapper.deleteWechatMemberById(id);
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,409 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.TypeReference;
|
||||
import com.bending.core.his.bo.PayAccountBO;
|
||||
import com.bending.core.his.common.HISResult;
|
||||
import com.bending.core.his.constant.HisConstant;
|
||||
import com.bending.core.his.entity.*;
|
||||
import com.bending.core.his.vo.*;
|
||||
import com.bending.core.utils.HISClientUtil;
|
||||
import com.ruoyi.common.func.IConstant;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.func.Func;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.bean.BeanUtils;
|
||||
import com.ruoyi.his.domain.*;
|
||||
import com.ruoyi.his.service.*;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.annotations.ApiParam;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
import java.util.function.Function;
|
||||
import java.util.function.Predicate;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static java.util.stream.Collectors.toList;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("his/v1/sync")
|
||||
@Api(value = "HIS同步数据接口", tags = "HIS同步数据接口")
|
||||
public class HisController {
|
||||
@Resource
|
||||
private HISClientUtil hisClientUtil;
|
||||
@Resource
|
||||
private IHisHospitalInfoService iHisHospitalInfoService;
|
||||
@Resource
|
||||
private IHisDepartmentService iHisDepartmentService;
|
||||
@Resource
|
||||
private IHisDoctorDepartmentService iHisDoctorDepartmentService;
|
||||
@Resource
|
||||
private IHisDoctorService iHisDoctorService;
|
||||
@Resource
|
||||
private IHisRegistrationTemplateService iHisRegistrationTemplateService;
|
||||
@Resource
|
||||
private IHisPayAccountService iHisPayAccountService;
|
||||
@Resource
|
||||
private IHisFeeItemService hisFeeItemService;
|
||||
@Resource
|
||||
private IHisDoctorScheduleService iHisDoctorScheduleService;
|
||||
|
||||
@ApiOperation("获取挂号模板")
|
||||
@GetMapping("/template/list")
|
||||
public AjaxResult templateList(String orgCode) {
|
||||
HisHospitalInfo hisHospitalInfo = iHisHospitalInfoService.selectHisHospitalInfoByOrgCode(orgCode);
|
||||
if (null == hisHospitalInfo) {
|
||||
return AjaxResult.error("指定机构不存在!");
|
||||
}
|
||||
RegistrationTemplate registrationTemplate = new RegistrationTemplate();
|
||||
registrationTemplate.setOrgCode(orgCode);
|
||||
registrationTemplate.setTemplateId("");
|
||||
HISResult hisResult = hisClientUtil.getRegistrationTemplateList(registrationTemplate);
|
||||
if (HisConstant.RESULT_SUCCESS_CODE.equals(hisResult.getResult())) {
|
||||
TypeReference<List<RegistrationTemplateVO>> typeRef = new TypeReference<List<RegistrationTemplateVO>>() {
|
||||
};
|
||||
List<RegistrationTemplateVO> list = JSON.parseObject(hisResult.getMsg(), typeRef);
|
||||
//保存数据到本地数据库
|
||||
for (RegistrationTemplateVO vo : list) {
|
||||
//每次更新时,查询是否已经存在
|
||||
String s = vo.getTemplateName().replaceAll("\\s*", "");
|
||||
vo.setTemplateName(Func.cleanChars(s));
|
||||
HisRegistrationTemplate hisRegistrationTemplate = Func.copy(vo, HisRegistrationTemplate.class);
|
||||
hisRegistrationTemplate.setIsShow(0);
|
||||
hisRegistrationTemplate.setFee(vo.getRegistrationAmount());
|
||||
hisRegistrationTemplate.setOrgCode(orgCode);
|
||||
hisRegistrationTemplate.setOrgName(hisHospitalInfo.getOrgName());
|
||||
iHisRegistrationTemplateService.insertHisRegistrationTemplate(hisRegistrationTemplate);
|
||||
}
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
return AjaxResult.error(hisResult.getMsg());
|
||||
}
|
||||
|
||||
@ApiOperation("获取机构列表")
|
||||
@GetMapping("/hospital/list")
|
||||
public AjaxResult hospitalList(String orgName) {
|
||||
HospitalInfo hospitalInfo = new HospitalInfo();
|
||||
hospitalInfo.setOrgName(orgName);
|
||||
HISResult hisResult = hisClientUtil.getHospitalInfoByList(hospitalInfo);
|
||||
if (HisConstant.RESULT_SUCCESS_CODE.equals(hisResult.getResult())) {
|
||||
TypeReference<List<HospitalInfoVO>> typeRef = new TypeReference<List<HospitalInfoVO>>() {
|
||||
};
|
||||
List<HospitalInfoVO> list = JSON.parseObject(hisResult.getMsg(), typeRef);
|
||||
if (CollectionUtils.isNotEmpty(list)) {
|
||||
for (HospitalInfoVO hospitalInfoVO : list) {
|
||||
HisHospitalInfo hisHospitalInfo = iHisHospitalInfoService.selectHisHospitalInfoByOrgCode(hospitalInfoVO.getOrgCode());
|
||||
if (null == hisHospitalInfo) {
|
||||
hisHospitalInfo = new HisHospitalInfo();
|
||||
BeanUtils.copyProperties(hospitalInfoVO, hisHospitalInfo);
|
||||
iHisHospitalInfoService.insertHisHospitalInfo(hisHospitalInfo);
|
||||
} else {
|
||||
iHisHospitalInfoService.updateHisHospitalInfo(hisHospitalInfo);
|
||||
}
|
||||
}
|
||||
}
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
return AjaxResult.error(hisResult.getMsg());
|
||||
}
|
||||
|
||||
@ApiOperation("获取科室列表")
|
||||
@GetMapping("/dept/list")
|
||||
public AjaxResult deptList(String orgCode) {
|
||||
//查询本地数据库
|
||||
HisHospitalInfo hisHospitalInfo = iHisHospitalInfoService.selectHisHospitalInfoByOrgCode(orgCode);
|
||||
if (null == hisHospitalInfo) {
|
||||
return AjaxResult.error("指定机构不存在!");
|
||||
}
|
||||
//HIS医院综合目录
|
||||
ComprehensiveCatalogue comprehensiveCatalogue = new ComprehensiveCatalogue();
|
||||
comprehensiveCatalogue.setDirectoryType(HisConstant.CATALOG_TYPE_1);
|
||||
comprehensiveCatalogue.setOrgCode(orgCode);
|
||||
HISResult hisResult = hisClientUtil.getComprehensiveCatalogueList(comprehensiveCatalogue);
|
||||
if (HisConstant.RESULT_SUCCESS_CODE.equals(hisResult.getResult())) {
|
||||
TypeReference<List<ComprehensiveCatalogueVO>> typeRef = new TypeReference<List<ComprehensiveCatalogueVO>>() {
|
||||
};
|
||||
List<ComprehensiveCatalogueVO> list = JSON.parseObject(hisResult.getMsg(), typeRef);
|
||||
for (ComprehensiveCatalogueVO vo : list) {
|
||||
String deptId = vo.getDirectoryCode();
|
||||
HisDepartment hisDepartment = new HisDepartment();
|
||||
hisDepartment.setDeptId(deptId);
|
||||
hisDepartment.setDeptName(vo.getDirectoryName());
|
||||
hisDepartment.setOrgCode(orgCode);
|
||||
hisDepartment.setOrgName(hisHospitalInfo.getOrgName());
|
||||
hisDepartment.setIsShow(0);
|
||||
hisDepartment.setCreateTime(DateUtils.getNowDate());
|
||||
int res = iHisDepartmentService.insertHisDepartment(hisDepartment);
|
||||
//每次更新时,查询是否已经存在
|
||||
}
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
return AjaxResult.error(hisResult.getMsg());
|
||||
}
|
||||
|
||||
@ApiOperation("获取医生列表")
|
||||
@GetMapping("/doctor/list")
|
||||
public AjaxResult doctorList(String orgCode) {
|
||||
//查询本地数据库
|
||||
HisHospitalInfo hisHospitalInfo = iHisHospitalInfoService.selectHisHospitalInfoByOrgCode(orgCode);
|
||||
if (null == hisHospitalInfo) {
|
||||
return AjaxResult.error("指定机构不存在!");
|
||||
}
|
||||
//HIS医院综合目录
|
||||
ComprehensiveCatalogue comprehensiveCatalogue = new ComprehensiveCatalogue();
|
||||
comprehensiveCatalogue.setDirectoryType(HisConstant.CATALOG_TYPE_2);
|
||||
comprehensiveCatalogue.setOrgCode(orgCode);
|
||||
HISResult hisResult = hisClientUtil.getComprehensiveCatalogueList(comprehensiveCatalogue);
|
||||
if (HisConstant.RESULT_SUCCESS_CODE.equals(hisResult.getResult())) {
|
||||
TypeReference<List<ComprehensiveCatalogueVO>> typeRef = new TypeReference<List<ComprehensiveCatalogueVO>>() {
|
||||
};
|
||||
List<ComprehensiveCatalogueVO> list = JSON.parseObject(hisResult.getMsg(), typeRef);
|
||||
|
||||
//医生分组,但是数据没有去重。
|
||||
Map<String, List<ComprehensiveCatalogueVO>> map = list.stream().collect(Collectors.groupingBy(ComprehensiveCatalogueVO::getDirectoryCode));
|
||||
// 医生与科室对应关系
|
||||
// Map<doctorId,deptIds> --> Map<String,List<String>>
|
||||
Map<String, List<String>> doctorMapR = new HashMap<>();
|
||||
map.forEach((doctorId, voList) -> {
|
||||
//拿到科室ID,就是科室去重
|
||||
List<ComprehensiveCatalogueVO> tempList = voList.stream().filter(distinctByKey(ComprehensiveCatalogueVO::getRemark)).collect(Collectors.toList());
|
||||
List<String> deptIds = tempList.stream().map(ComprehensiveCatalogueVO::getRemark).collect(Collectors.toList());
|
||||
doctorMapR.put(doctorId, deptIds);
|
||||
});
|
||||
//保存医生与科室的对应关系
|
||||
doctorMapR.forEach((doctorId, deptIds) -> {
|
||||
deptIds.forEach(deptId -> {
|
||||
//每次更新时,查询是否已经存在对应关系
|
||||
HisDoctorDepartment doctorDepartment = new HisDoctorDepartment();
|
||||
//一个医生理论上对应一个科室,实际上是对应多个科室的.
|
||||
doctorDepartment.setDeptId(deptId);
|
||||
HisDepartment hisDepartment = iHisDepartmentService.selectHisDepartmentByDeptId(deptId);
|
||||
doctorDepartment.setDeptName(null != hisDepartment ? hisDepartment.getDeptName() : "");
|
||||
doctorDepartment.setDoctorId(doctorId);
|
||||
doctorDepartment.setOrgCode(orgCode);
|
||||
doctorDepartment.setIsShow(0);
|
||||
iHisDoctorDepartmentService.insertHisDoctorDepartment(doctorDepartment);
|
||||
});
|
||||
});
|
||||
|
||||
//根据医生ID去重
|
||||
List<ComprehensiveCatalogueVO> voList = list.stream().filter(distinctByKey(ComprehensiveCatalogueVO::getDirectoryCode)).collect(Collectors.toList());
|
||||
for (ComprehensiveCatalogueVO v : voList) {
|
||||
HisDoctor hisDoctor = new HisDoctor();
|
||||
hisDoctor.setDoctorId(v.getDirectoryCode());
|
||||
hisDoctor.setDoctorName(v.getDirectoryName());
|
||||
//备注[目录类型1: 返回医生所在科室的编码;目录类型3: 返回床位所在的病区编码.]
|
||||
hisDoctor.setDeptId(v.getRemark()); //随机设置一个默认科室
|
||||
HisDepartment hisDepartment = iHisDepartmentService.selectHisDepartmentByDeptId(v.getRemark());
|
||||
hisDoctor.setDeptName(null != hisDepartment ? hisDepartment.getDeptName() : "");
|
||||
hisDoctor.setOrgCode(orgCode);
|
||||
hisDoctor.setOrgName(hisHospitalInfo.getOrgName());
|
||||
hisDoctor.setIsShow(0);
|
||||
iHisDoctorService.insertHisDoctor(hisDoctor);
|
||||
}
|
||||
//每次更新时,查询是否已经存在
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
return AjaxResult.error(hisResult.getMsg());
|
||||
}
|
||||
|
||||
private static <T> Predicate<T> distinctByKey(Function<? super T, ?> keyExtractor) {
|
||||
Map<Object, Boolean> seen = new ConcurrentHashMap<>();
|
||||
return t -> seen.putIfAbsent(keyExtractor.apply(t), Boolean.TRUE) == null;
|
||||
}
|
||||
|
||||
|
||||
@GetMapping("/payment/list")
|
||||
@ApiOperation(value = "HIS同步数据接口:机构支付方式列表", notes = "传入查询参数")
|
||||
public AjaxResult queryHospitalPayment(@ApiParam(name = "orgCode", value = "机构ID", required = true) @RequestParam String orgCode) {
|
||||
HisHospitalInfo hisHospitalInfo = iHisHospitalInfoService.selectHisHospitalInfoByOrgCode(orgCode);
|
||||
if (null == hisHospitalInfo) {
|
||||
return AjaxResult.error("指定机构不存在!");
|
||||
}
|
||||
HospitalPayment hospitalPayment = new HospitalPayment();
|
||||
hospitalPayment.setOrgCode(orgCode);
|
||||
HISResult hisResult = hisClientUtil.getHospitalPaymentList(hospitalPayment);
|
||||
|
||||
List<HisPayAccount> hisPayAccountList = new ArrayList<>();
|
||||
|
||||
if (HisConstant.RESULT_SUCCESS_CODE.equals(hisResult.getResult())) {
|
||||
TypeReference<List<HospitalPaymentVO>> typeRef = new TypeReference<List<HospitalPaymentVO>>() {
|
||||
};
|
||||
List<HospitalPaymentVO> list = JSON.parseObject(hisResult.getMsg(), typeRef);
|
||||
//保存数据到本地数据库
|
||||
for (HospitalPaymentVO vo : list) {
|
||||
List<PayAccountBO> payAccountBOList = vo.getOrgAcc();
|
||||
payAccountBOList.forEach(bo -> {
|
||||
HisPayAccount payAccount = new HisPayAccount();
|
||||
Func.copy(bo, payAccount);
|
||||
payAccount.setAccId(bo.getId());
|
||||
hisPayAccountList.add(payAccount);
|
||||
});
|
||||
}
|
||||
if (Func.isNotEmpty(hisPayAccountList)) {
|
||||
iHisPayAccountService.insertHisPayAccountBatch(hisPayAccountList);
|
||||
}
|
||||
return AjaxResult.success(hisPayAccountList);
|
||||
}
|
||||
return AjaxResult.error(hisResult.getMsg());
|
||||
}
|
||||
|
||||
|
||||
@GetMapping("/fee/item/list")
|
||||
@ApiOperation(value = "HIS同步数据接口:挂号费用类型")
|
||||
public AjaxResult queryHisFeeItem() {
|
||||
List<HisFeeItem> hisFeeItemList = new ArrayList<>();
|
||||
RegistrationFeeType registrationFeeType = new RegistrationFeeType();
|
||||
HISResult hisResult = hisClientUtil.getFeeItemList(registrationFeeType);
|
||||
if (HisConstant.RESULT_SUCCESS_CODE.equals(hisResult.getResult())) {
|
||||
TypeReference<List<RegistrationFeeTypeVO>> typeRef = new TypeReference<List<RegistrationFeeTypeVO>>() {
|
||||
};
|
||||
List<RegistrationFeeTypeVO> list = JSON.parseObject(hisResult.getMsg(), typeRef);
|
||||
if (Func.isNotEmpty(list)) {
|
||||
for (RegistrationFeeTypeVO vo : list) {
|
||||
HisFeeItem hisFeeItem = new HisFeeItem();
|
||||
Func.copy(vo, hisFeeItem);
|
||||
hisFeeItem.setIsShow(IConstant.ZERO.getValue());
|
||||
hisFeeItem.setCreateTime(DateUtils.getNowDate());
|
||||
hisFeeItemList.add(hisFeeItem);
|
||||
}
|
||||
}
|
||||
if (Func.isNotEmpty(hisFeeItemList)) {
|
||||
hisFeeItemService.insertHisFeeItemBatch(hisFeeItemList);
|
||||
}
|
||||
return AjaxResult.success(hisFeeItemList);
|
||||
} else {
|
||||
return AjaxResult.error(hisResult.getMsg());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* /his/v1/sync/doctor/schedule
|
||||
* 同步医生排班信息
|
||||
*
|
||||
* @param orgCode 机构ID
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/doctor/schedule")
|
||||
@ApiOperation(value = "HIS同步数据接口:医生排班信息", notes = "传入查询参数")
|
||||
public AjaxResult queryDoctorSchedule(@ApiParam(name = "orgCode", value = "机构ID") @RequestParam(required = false) String orgCode) {
|
||||
Date nowDate = DateUtils.getNowDate();
|
||||
Date beginTime = Func.minusDays(nowDate, 1);//-days天
|
||||
Date endTime = Func.plusDays(nowDate, 1);//+days天
|
||||
if (Func.isNotEmpty(orgCode)) {
|
||||
HisHospitalInfo hospitalInfo = iHisHospitalInfoService.selectHisHospitalInfoByOrgCode(orgCode); //机构信息
|
||||
if (null == hospitalInfo) return AjaxResult.error("指定机构不存在!");
|
||||
syncDoctorSchedule(hospitalInfo, beginTime, endTime);
|
||||
} else {
|
||||
HisHospitalInfo hospitalInfoQuery = new HisHospitalInfo();
|
||||
hospitalInfoQuery.setIsShow(IConstant.ONE.getValue());
|
||||
List<HisHospitalInfo> hospitalInfoList = iHisHospitalInfoService.selectHisHospitalInfoList(hospitalInfoQuery);
|
||||
if (Func.isNotEmpty(hospitalInfoList)) {
|
||||
hospitalInfoList.forEach(hospitalInfo -> {
|
||||
syncDoctorSchedule(hospitalInfo, beginTime, endTime);
|
||||
});
|
||||
}
|
||||
}
|
||||
return AjaxResult.success("医生排班同步完成!");
|
||||
}
|
||||
|
||||
private void syncDoctorSchedule(HisHospitalInfo hospitalInfo, Date beginTime, Date endTime) {
|
||||
if (null == hospitalInfo) return;
|
||||
String orgName = Func.isNotEmpty(hospitalInfo) ? hospitalInfo.getOrgName() : "";
|
||||
String orgCode = hospitalInfo.getOrgCode();
|
||||
//班次判断是否存在
|
||||
HisDoctorSchedule doctorScheduleQuery = new HisDoctorSchedule();
|
||||
doctorScheduleQuery.setOrgCode(orgCode);
|
||||
Map<String, Object> paramsQuery = new HashMap<>();
|
||||
//删除过期排班老数据
|
||||
Date beginScheduleDate = Func.minusDays(beginTime, 7); //当前日期过去的days
|
||||
Date endScheduleDate = Func.minusDays(beginTime, 1); //昨天
|
||||
paramsQuery.put("beginScheduleDate", Func.formatDate(beginScheduleDate, DateUtils.YYYY_MM_DD));
|
||||
paramsQuery.put("endScheduleDate", Func.formatDate(endScheduleDate, DateUtils.YYYY_MM_DD));
|
||||
doctorScheduleQuery.setParams(paramsQuery);
|
||||
List<HisDoctorSchedule> oldScheduleList = iHisDoctorScheduleService.selectHisDoctorScheduleList(doctorScheduleQuery);
|
||||
if (Func.isNotEmpty(oldScheduleList)) {
|
||||
List<Long> idsList = oldScheduleList.stream().map(HisDoctorSchedule::getId).collect(toList());
|
||||
String ids = Func.join(idsList, ",");
|
||||
iHisDoctorScheduleService.deleteHisDoctorScheduleByIds(ids);
|
||||
}
|
||||
//医生列表(正常在线)
|
||||
HisDoctor hisDoctor = new HisDoctor();
|
||||
hisDoctor.setOrgCode(orgCode);
|
||||
hisDoctor.setIsShow(IConstant.ONE.getValue());
|
||||
List<HisDoctor> doctorList = iHisDoctorService.selectHisDoctorList(hisDoctor);
|
||||
if (Func.isNotEmpty(doctorList)) {
|
||||
// 新数据
|
||||
List<HisDoctorSchedule> newDoctorScheduleList = new ArrayList<>();
|
||||
List<HisDoctorSchedule> oldDoctorScheduleList = new ArrayList<>();
|
||||
|
||||
doctorList.forEach(doctor -> {
|
||||
DoctorSchedule doctorSchedule = new DoctorSchedule();
|
||||
doctorSchedule.setOrgCode(orgCode);
|
||||
doctorSchedule.setDoctorId(doctor.getDoctorId());
|
||||
//查询日期限制在7天内,yyyy-MM-dd
|
||||
doctorSchedule.setBeginTime(Func.formatDate(beginTime));
|
||||
doctorSchedule.setEndTime(Func.formatDate(endTime));
|
||||
HISResult hisResult = hisClientUtil.getDoctorScheduleList(doctorSchedule);
|
||||
if (HisConstant.RESULT_SUCCESS_CODE.equals(hisResult.getResult())) {
|
||||
TypeReference<List<DoctorScheduleVO>> typeRef = new TypeReference<List<DoctorScheduleVO>>() {
|
||||
};
|
||||
List<DoctorScheduleVO> list = JSON.parseObject(hisResult.getMsg(), typeRef);
|
||||
if (Func.isNotEmpty(list)) {
|
||||
for (DoctorScheduleVO vo : list) {
|
||||
String shift = Func.trimWhitespace(vo.getScheduleShift());
|
||||
Date scheduleDate = Func.parse(vo.getScheduleDate(), "yyyy-MM-dd");
|
||||
//班次判断是否存在 --老数据
|
||||
HisDoctorSchedule hisDoctorScheduleQuery = new HisDoctorSchedule();
|
||||
hisDoctorScheduleQuery.setOrgCode(orgCode);
|
||||
hisDoctorScheduleQuery.setDoctorId(vo.getDoctorId());
|
||||
hisDoctorScheduleQuery.setScheduleDate(scheduleDate);
|
||||
hisDoctorScheduleQuery.setScheduleShift(shift);
|
||||
HisDoctorSchedule hisDoctorSchedule = iHisDoctorScheduleService.selectHisDoctorSchedule(hisDoctorScheduleQuery);
|
||||
if (null == hisDoctorSchedule) {
|
||||
hisDoctorSchedule = new HisDoctorSchedule();
|
||||
hisDoctorSchedule.setScheduleDate(scheduleDate);
|
||||
hisDoctorSchedule.setOrgCode(orgCode);
|
||||
hisDoctorSchedule.setOrgName(orgName);
|
||||
hisDoctorSchedule.setCreateTime(DateUtils.getNowDate());
|
||||
hisDoctorSchedule.setIsShow(IConstant.ONE.getValue());
|
||||
Func.copy(vo, hisDoctorSchedule);
|
||||
if (HisConstant.MORNING.equals(shift)) {
|
||||
hisDoctorSchedule.setScheduleTag(IConstant.ONE.getValue());
|
||||
}
|
||||
if (HisConstant.AFTERNOON.equals(shift)) {
|
||||
hisDoctorSchedule.setScheduleTag(IConstant.TWO.getValue());
|
||||
}
|
||||
newDoctorScheduleList.add(hisDoctorSchedule);
|
||||
} else {
|
||||
Func.copy(vo, hisDoctorSchedule);
|
||||
if (HisConstant.MORNING.equals(shift)) {
|
||||
hisDoctorSchedule.setScheduleTag(IConstant.ONE.getValue());
|
||||
}
|
||||
if (HisConstant.AFTERNOON.equals(shift)) {
|
||||
hisDoctorSchedule.setScheduleTag(IConstant.TWO.getValue());
|
||||
}
|
||||
oldDoctorScheduleList.add(hisDoctorSchedule);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
if (Func.isNotEmpty(newDoctorScheduleList)) {
|
||||
iHisDoctorScheduleService.insertHisDoctorScheduleBatch(newDoctorScheduleList);
|
||||
}
|
||||
if (Func.isNotEmpty(oldDoctorScheduleList)) {
|
||||
iHisDoctorScheduleService.updateHisDoctorScheduleBatch(oldDoctorScheduleList);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,138 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.his.domain.HisDoctorDepartment;
|
||||
import com.ruoyi.his.service.IHisDoctorDepartmentService;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisDepartment;
|
||||
import com.ruoyi.his.service.IHisDepartmentService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 科室Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/department")
|
||||
public class HisDepartmentController extends BaseController
|
||||
{
|
||||
private String prefix = "his/department";
|
||||
|
||||
@Autowired
|
||||
private IHisDepartmentService hisDepartmentService;
|
||||
@Autowired
|
||||
private IHisDoctorDepartmentService iHisDoctorDepartmentService;
|
||||
|
||||
@RequiresPermissions("his:department:view")
|
||||
@GetMapping()
|
||||
public String department()
|
||||
{
|
||||
return prefix + "/department";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询科室列表
|
||||
*/
|
||||
@RequiresPermissions("his:department:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisDepartment hisDepartment)
|
||||
{
|
||||
startPage();
|
||||
List<HisDepartment> list = hisDepartmentService.selectHisDepartmentList(hisDepartment);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出科室列表
|
||||
*/
|
||||
@RequiresPermissions("his:department:export")
|
||||
@Log(title = "科室", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisDepartment hisDepartment)
|
||||
{
|
||||
List<HisDepartment> list = hisDepartmentService.selectHisDepartmentList(hisDepartment);
|
||||
ExcelUtil<HisDepartment> util = new ExcelUtil<HisDepartment>(HisDepartment.class);
|
||||
return util.exportExcel(list, "department");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增科室
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存科室
|
||||
*/
|
||||
@RequiresPermissions("his:department:add")
|
||||
@Log(title = "科室", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisDepartment hisDepartment)
|
||||
{
|
||||
return toAjax(hisDepartmentService.insertHisDepartment(hisDepartment));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改科室
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisDepartment hisDepartment = hisDepartmentService.selectHisDepartmentById(id);
|
||||
mmap.put("hisDepartment", hisDepartment);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存科室
|
||||
*/
|
||||
@RequiresPermissions("his:department:edit")
|
||||
@Log(title = "科室", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisDepartment hisDepartment)
|
||||
{
|
||||
//科室更新时 同步更新对应关系
|
||||
String deptId = hisDepartment.getDeptId();
|
||||
HisDoctorDepartment hisDoctorDepartment = new HisDoctorDepartment();
|
||||
hisDoctorDepartment.setDeptId(deptId);
|
||||
hisDoctorDepartment.setIsShow(hisDepartment.getIsShow());
|
||||
iHisDoctorDepartmentService.updateHisDoctorDepartmentByDeptId(hisDoctorDepartment);
|
||||
|
||||
return toAjax(hisDepartmentService.updateHisDepartment(hisDepartment));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除科室
|
||||
*/
|
||||
@RequiresPermissions("his:department:remove")
|
||||
@Log(title = "科室", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisDepartmentService.deleteHisDepartmentByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,172 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.func.Func;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.his.domain.HisDepartment;
|
||||
import com.ruoyi.his.domain.HisDoctor;
|
||||
import com.ruoyi.his.domain.HisDoctorDepartment;
|
||||
import com.ruoyi.his.domain.HisRegistrationTemplate;
|
||||
import com.ruoyi.his.service.IHisDepartmentService;
|
||||
import com.ruoyi.his.service.IHisDoctorDepartmentService;
|
||||
import com.ruoyi.his.service.IHisDoctorService;
|
||||
import com.ruoyi.his.service.IHisRegistrationTemplateService;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 医生Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/doctor")
|
||||
public class HisDoctorController extends BaseController
|
||||
{
|
||||
private String prefix = "his/doctor";
|
||||
|
||||
@Autowired
|
||||
private IHisDoctorService hisDoctorService;
|
||||
@Autowired
|
||||
private IHisRegistrationTemplateService iHisRegistrationTemplateService;
|
||||
@Autowired
|
||||
private IHisDoctorDepartmentService iHisDoctorDepartmentService;
|
||||
@Autowired
|
||||
private IHisDepartmentService iHisDepartmentService;
|
||||
|
||||
|
||||
@RequiresPermissions("his:doctor:view")
|
||||
@GetMapping()
|
||||
public String doctor()
|
||||
{
|
||||
return prefix + "/doctor";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询医生列表
|
||||
*/
|
||||
@RequiresPermissions("his:doctor:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisDoctor hisDoctor)
|
||||
{
|
||||
startPage();
|
||||
List<HisDoctor> list = hisDoctorService.selectHisDoctorList(hisDoctor);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出医生列表
|
||||
*/
|
||||
@RequiresPermissions("his:doctor:export")
|
||||
@Log(title = "医生", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisDoctor hisDoctor)
|
||||
{
|
||||
List<HisDoctor> list = hisDoctorService.selectHisDoctorList(hisDoctor);
|
||||
ExcelUtil<HisDoctor> util = new ExcelUtil<HisDoctor>(HisDoctor.class);
|
||||
return util.exportExcel(list, "doctor");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增医生
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存医生
|
||||
*/
|
||||
@RequiresPermissions("his:doctor:add")
|
||||
@Log(title = "医生", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisDoctor hisDoctor)
|
||||
{
|
||||
return toAjax(hisDoctorService.insertHisDoctor(hisDoctor));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改医生
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisDoctor hisDoctor = hisDoctorService.selectHisDoctorById(id);
|
||||
mmap.put("hisDoctor", hisDoctor);
|
||||
if(Func.isNotEmpty(hisDoctor)){
|
||||
//编辑时可设置挂号模板
|
||||
HisRegistrationTemplate template = new HisRegistrationTemplate();
|
||||
template.setOrgCode(hisDoctor.getOrgCode());
|
||||
template.setIsShow(1);
|
||||
List<HisRegistrationTemplate> hisRegistrationTemplateList = iHisRegistrationTemplateService.selectHisRegistrationTemplateList(template);
|
||||
if (Func.isNotEmpty(hisRegistrationTemplateList)){
|
||||
mmap.put("hisRegistrationTemplateList", hisRegistrationTemplateList);
|
||||
}
|
||||
//修改默认科室
|
||||
HisDoctorDepartment hisDoctorDepartment= new HisDoctorDepartment();
|
||||
hisDoctorDepartment.setDoctorId(hisDoctor.getDoctorId());
|
||||
List<HisDoctorDepartment> hisDoctorDepartmentList = iHisDoctorDepartmentService.selectHisDoctorDepartmentList(hisDoctorDepartment);
|
||||
if (Func.isNotEmpty(hisDoctorDepartmentList)){
|
||||
mmap.put("hisDoctorDepartmentList", hisDoctorDepartmentList);
|
||||
}
|
||||
}
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存医生
|
||||
*/
|
||||
@RequiresPermissions("his:doctor:edit")
|
||||
@Log(title = "医生", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisDoctor hisDoctor)
|
||||
{
|
||||
//根据挂号模板ID获取模板名称
|
||||
String templateId = hisDoctor.getTemplateId();
|
||||
if (Func.isNotEmpty(templateId)){
|
||||
HisRegistrationTemplate template = new HisRegistrationTemplate();
|
||||
template.setTemplateId(templateId);
|
||||
HisRegistrationTemplate hisRegistrationTemplate = iHisRegistrationTemplateService.selectHisRegistrationTemplate(template);
|
||||
if (Func.isNotEmpty(hisRegistrationTemplate)){
|
||||
hisDoctor.setTemplateName(hisRegistrationTemplate.getTemplateName());
|
||||
}
|
||||
}
|
||||
//设置默认科室
|
||||
String deptId = hisDoctor.getDeptId();
|
||||
if (Func.isNotEmpty(deptId)){
|
||||
HisDepartment hisDepartment = iHisDepartmentService.selectHisDepartmentByDeptId(deptId);
|
||||
if (Func.isNotEmpty(hisDepartment)){
|
||||
hisDoctor.setDeptName(hisDepartment.getDeptName());
|
||||
}
|
||||
}
|
||||
return toAjax(hisDoctorService.updateHisDoctor(hisDoctor));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除医生
|
||||
*/
|
||||
@RequiresPermissions("his:doctor:remove")
|
||||
@Log(title = "医生", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisDoctorService.deleteHisDoctorByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisDoctorDepartment;
|
||||
import com.ruoyi.his.service.IHisDoctorDepartmentService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 医生科室关系Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-01
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/doctorDepartment")
|
||||
public class HisDoctorDepartmentController extends BaseController
|
||||
{
|
||||
private String prefix = "his/doctorDepartment";
|
||||
|
||||
@Autowired
|
||||
private IHisDoctorDepartmentService hisDoctorDepartmentService;
|
||||
|
||||
@RequiresPermissions("his:doctorDepartment:view")
|
||||
@GetMapping()
|
||||
public String doctorDepartment()
|
||||
{
|
||||
return prefix + "/doctorDepartment";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询医生科室关系列表
|
||||
*/
|
||||
@RequiresPermissions("his:doctorDepartment:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisDoctorDepartment hisDoctorDepartment)
|
||||
{
|
||||
startPage();
|
||||
List<HisDoctorDepartment> list = hisDoctorDepartmentService.selectHisDoctorDepartmentList(hisDoctorDepartment);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出医生科室关系列表
|
||||
*/
|
||||
@RequiresPermissions("his:doctorDepartment:export")
|
||||
@Log(title = "医生科室关系", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisDoctorDepartment hisDoctorDepartment)
|
||||
{
|
||||
List<HisDoctorDepartment> list = hisDoctorDepartmentService.selectHisDoctorDepartmentList(hisDoctorDepartment);
|
||||
ExcelUtil<HisDoctorDepartment> util = new ExcelUtil<HisDoctorDepartment>(HisDoctorDepartment.class);
|
||||
return util.exportExcel(list, "doctorDepartment");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增医生科室关系
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存医生科室关系
|
||||
*/
|
||||
@RequiresPermissions("his:doctorDepartment:add")
|
||||
@Log(title = "医生科室关系", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisDoctorDepartment hisDoctorDepartment)
|
||||
{
|
||||
return toAjax(hisDoctorDepartmentService.insertHisDoctorDepartment(hisDoctorDepartment));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改医生科室关系
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisDoctorDepartment hisDoctorDepartment = hisDoctorDepartmentService.selectHisDoctorDepartmentById(id);
|
||||
mmap.put("hisDoctorDepartment", hisDoctorDepartment);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存医生科室关系
|
||||
*/
|
||||
@RequiresPermissions("his:doctorDepartment:edit")
|
||||
@Log(title = "医生科室关系", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisDoctorDepartment hisDoctorDepartment)
|
||||
{
|
||||
return toAjax(hisDoctorDepartmentService.updateHisDoctorDepartment(hisDoctorDepartment));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除医生科室关系
|
||||
*/
|
||||
@RequiresPermissions("his:doctorDepartment:remove")
|
||||
@Log(title = "医生科室关系", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisDoctorDepartmentService.deleteHisDoctorDepartmentByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisDoctorSchedule;
|
||||
import com.ruoyi.his.service.IHisDoctorScheduleService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 医生排班Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-03
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/doctorSchedule")
|
||||
public class HisDoctorScheduleController extends BaseController
|
||||
{
|
||||
private String prefix = "his/doctorSchedule";
|
||||
|
||||
@Autowired
|
||||
private IHisDoctorScheduleService hisDoctorScheduleService;
|
||||
|
||||
@RequiresPermissions("his:doctorSchedule:view")
|
||||
@GetMapping()
|
||||
public String doctorSchedule()
|
||||
{
|
||||
return prefix + "/doctorSchedule";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询医生排班列表
|
||||
*/
|
||||
@RequiresPermissions("his:doctorSchedule:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisDoctorSchedule hisDoctorSchedule)
|
||||
{
|
||||
startPage();
|
||||
List<HisDoctorSchedule> list = hisDoctorScheduleService.selectHisDoctorScheduleList(hisDoctorSchedule);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出医生排班列表
|
||||
*/
|
||||
@RequiresPermissions("his:doctorSchedule:export")
|
||||
@Log(title = "医生排班", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisDoctorSchedule hisDoctorSchedule)
|
||||
{
|
||||
List<HisDoctorSchedule> list = hisDoctorScheduleService.selectHisDoctorScheduleList(hisDoctorSchedule);
|
||||
ExcelUtil<HisDoctorSchedule> util = new ExcelUtil<HisDoctorSchedule>(HisDoctorSchedule.class);
|
||||
return util.exportExcel(list, "doctorSchedule");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增医生排班
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存医生排班
|
||||
*/
|
||||
@RequiresPermissions("his:doctorSchedule:add")
|
||||
@Log(title = "医生排班", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisDoctorSchedule hisDoctorSchedule)
|
||||
{
|
||||
return toAjax(hisDoctorScheduleService.insertHisDoctorSchedule(hisDoctorSchedule));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改医生排班
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisDoctorSchedule hisDoctorSchedule = hisDoctorScheduleService.selectHisDoctorScheduleById(id);
|
||||
mmap.put("hisDoctorSchedule", hisDoctorSchedule);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存医生排班
|
||||
*/
|
||||
@RequiresPermissions("his:doctorSchedule:edit")
|
||||
@Log(title = "医生排班", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisDoctorSchedule hisDoctorSchedule)
|
||||
{
|
||||
return toAjax(hisDoctorScheduleService.updateHisDoctorSchedule(hisDoctorSchedule));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除医生排班
|
||||
*/
|
||||
@RequiresPermissions("his:doctorSchedule:remove")
|
||||
@Log(title = "医生排班", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisDoctorScheduleService.deleteHisDoctorScheduleByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisEhealthClient;
|
||||
import com.ruoyi.his.service.IHisEhealthClientService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 健康卡Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-27
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/ehealthClient")
|
||||
public class HisEhealthClientController extends BaseController
|
||||
{
|
||||
private String prefix = "his/ehealthClient";
|
||||
|
||||
@Autowired
|
||||
private IHisEhealthClientService hisEhealthClientService;
|
||||
|
||||
@RequiresPermissions("his:ehealthClient:view")
|
||||
@GetMapping()
|
||||
public String ehealthClient()
|
||||
{
|
||||
return prefix + "/ehealthClient";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询健康卡列表
|
||||
*/
|
||||
@RequiresPermissions("his:ehealthClient:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisEhealthClient hisEhealthClient)
|
||||
{
|
||||
startPage();
|
||||
List<HisEhealthClient> list = hisEhealthClientService.selectHisEhealthClientList(hisEhealthClient);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出健康卡列表
|
||||
*/
|
||||
@RequiresPermissions("his:ehealthClient:export")
|
||||
@Log(title = "健康卡", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisEhealthClient hisEhealthClient)
|
||||
{
|
||||
List<HisEhealthClient> list = hisEhealthClientService.selectHisEhealthClientList(hisEhealthClient);
|
||||
ExcelUtil<HisEhealthClient> util = new ExcelUtil<HisEhealthClient>(HisEhealthClient.class);
|
||||
return util.exportExcel(list, "ehealthClient");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增健康卡
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存健康卡
|
||||
*/
|
||||
@RequiresPermissions("his:ehealthClient:add")
|
||||
@Log(title = "健康卡", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisEhealthClient hisEhealthClient)
|
||||
{
|
||||
return toAjax(hisEhealthClientService.insertHisEhealthClient(hisEhealthClient));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改健康卡
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisEhealthClient hisEhealthClient = hisEhealthClientService.selectHisEhealthClientById(id);
|
||||
mmap.put("hisEhealthClient", hisEhealthClient);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存健康卡
|
||||
*/
|
||||
@RequiresPermissions("his:ehealthClient:edit")
|
||||
@Log(title = "健康卡", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisEhealthClient hisEhealthClient)
|
||||
{
|
||||
return toAjax(hisEhealthClientService.updateHisEhealthClient(hisEhealthClient));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除健康卡
|
||||
*/
|
||||
@RequiresPermissions("his:ehealthClient:remove")
|
||||
@Log(title = "健康卡", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisEhealthClientService.deleteHisEhealthClientByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,140 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.his.domain.HisRegistrationTemplate;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisFeeItem;
|
||||
import com.ruoyi.his.service.IHisFeeItemService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 费用类型Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-14
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/feeItem")
|
||||
public class HisFeeItemController extends BaseController
|
||||
{
|
||||
private String prefix = "his/feeItem";
|
||||
|
||||
@Autowired
|
||||
private IHisFeeItemService hisFeeItemService;
|
||||
|
||||
@RequiresPermissions("his:feeItem:view")
|
||||
@GetMapping()
|
||||
public String feeItem()
|
||||
{
|
||||
return prefix + "/feeItem";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询费用类型列表
|
||||
*/
|
||||
@RequiresPermissions("his:feeItem:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisFeeItem hisFeeItem)
|
||||
{
|
||||
startPage();
|
||||
List<HisFeeItem> list = hisFeeItemService.selectHisFeeItemList(hisFeeItem);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出费用类型列表
|
||||
*/
|
||||
@RequiresPermissions("his:feeItem:export")
|
||||
@Log(title = "费用类型", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisFeeItem hisFeeItem)
|
||||
{
|
||||
List<HisFeeItem> list = hisFeeItemService.selectHisFeeItemList(hisFeeItem);
|
||||
ExcelUtil<HisFeeItem> util = new ExcelUtil<HisFeeItem>(HisFeeItem.class);
|
||||
return util.exportExcel(list, "feeItem");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增费用类型
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存费用类型
|
||||
*/
|
||||
@RequiresPermissions("his:feeItem:add")
|
||||
@Log(title = "费用类型", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisFeeItem hisFeeItem)
|
||||
{
|
||||
return toAjax(hisFeeItemService.insertHisFeeItem(hisFeeItem));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改费用类型
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisFeeItem hisFeeItem = hisFeeItemService.selectHisFeeItemById(id);
|
||||
mmap.put("hisFeeItem", hisFeeItem);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存费用类型
|
||||
*/
|
||||
@RequiresPermissions("his:feeItem:edit")
|
||||
@Log(title = "费用类型", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisFeeItem hisFeeItem)
|
||||
{
|
||||
return toAjax(hisFeeItemService.updateHisFeeItem(hisFeeItem));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除费用类型
|
||||
*/
|
||||
@RequiresPermissions("his:feeItem:remove")
|
||||
@Log(title = "费用类型", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisFeeItemService.deleteHisFeeItemByIds(ids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 状态修改
|
||||
*/
|
||||
@Log(title = "费用类型管理", businessType = BusinessType.UPDATE)
|
||||
@RequiresPermissions("his:feeItem:edit")
|
||||
@PostMapping("/changeStatus")
|
||||
@ResponseBody
|
||||
public AjaxResult changeStatus(HisFeeItem hisFeeItem)
|
||||
{
|
||||
return toAjax(hisFeeItemService.changeStatus(hisFeeItem));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,237 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.common.config.Global;
|
||||
import com.ruoyi.common.config.ServerConfig;
|
||||
import com.ruoyi.common.func.Func;
|
||||
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||
import com.ruoyi.his.domain.HisDepartment;
|
||||
import com.ruoyi.his.domain.HisDoctor;
|
||||
import com.ruoyi.his.service.IHisDepartmentService;
|
||||
import com.ruoyi.his.service.IHisDoctorService;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisHospitalInfo;
|
||||
import com.ruoyi.his.service.IHisHospitalInfoService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
/**
|
||||
* 医疗机构Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-06-28
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/hospital")
|
||||
public class HisHospitalInfoController extends BaseController
|
||||
{
|
||||
private String prefix = "his/hospital";
|
||||
|
||||
@Autowired
|
||||
private IHisHospitalInfoService hisHospitalInfoService;
|
||||
@Autowired
|
||||
private IHisDoctorService hisDoctorService;
|
||||
@Autowired
|
||||
private IHisDepartmentService iHisDepartmentService;
|
||||
|
||||
@RequiresPermissions("his:hospital:view")
|
||||
@GetMapping()
|
||||
public String hospital()
|
||||
{
|
||||
return prefix + "/hospital";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询医疗机构列表
|
||||
*/
|
||||
@RequiresPermissions("his:hospital:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisHospitalInfo hisHospitalInfo)
|
||||
{
|
||||
startPage();
|
||||
List<HisHospitalInfo> list = hisHospitalInfoService.selectHisHospitalInfoList(hisHospitalInfo);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出医疗机构列表
|
||||
*/
|
||||
@RequiresPermissions("his:hospital:export")
|
||||
@Log(title = "医疗机构", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisHospitalInfo hisHospitalInfo)
|
||||
{
|
||||
List<HisHospitalInfo> list = hisHospitalInfoService.selectHisHospitalInfoList(hisHospitalInfo);
|
||||
ExcelUtil<HisHospitalInfo> util = new ExcelUtil<HisHospitalInfo>(HisHospitalInfo.class);
|
||||
return util.exportExcel(list, "hospital");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增医疗机构
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存医疗机构
|
||||
*/
|
||||
@RequiresPermissions("his:hospital:add")
|
||||
@Log(title = "医疗机构", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisHospitalInfo hisHospitalInfo)
|
||||
{
|
||||
return toAjax(hisHospitalInfoService.insertHisHospitalInfo(hisHospitalInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改医疗机构
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisHospitalInfo hisHospitalInfo = hisHospitalInfoService.selectHisHospitalInfoById(id);
|
||||
mmap.put("hisHospitalInfo", hisHospitalInfo);
|
||||
if (Func.isNotEmpty(hisHospitalInfo)){
|
||||
HisDoctor hisDoctor = new HisDoctor();
|
||||
hisDoctor.setOrgCode(hisHospitalInfo.getOrgCode());
|
||||
hisDoctor.setIsShow(1);
|
||||
//选择优秀医生
|
||||
List<HisDoctor> hisDoctorList = hisDoctorService.selectHisDoctorList(hisDoctor);
|
||||
if (Func.isNotEmpty(hisDoctorList)){
|
||||
//已经选中的优秀医生
|
||||
String excellentDoctorIds = hisHospitalInfo.getExcellentDoctorIds();
|
||||
if (Func.isNotEmpty(excellentDoctorIds)){
|
||||
String[] doctorIds = Func.toStrArray(",", excellentDoctorIds);
|
||||
if (Func.isNotEmpty(doctorIds)){
|
||||
for (String doctorId : doctorIds) {
|
||||
for (HisDoctor doctor : hisDoctorList) {
|
||||
if (doctorId.equals(doctor.getDoctorId())) {
|
||||
doctor.setFlag(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
//设置选中标签
|
||||
mmap.put("hisDoctorList", hisDoctorList);
|
||||
}
|
||||
|
||||
//选择机构虚拟操作员列表
|
||||
HisDoctor vmDoctor = new HisDoctor();
|
||||
vmDoctor.setOrgCode(hisHospitalInfo.getOrgCode());
|
||||
vmDoctor.setIsVirtualAccount(1);
|
||||
List<HisDoctor> vmUserList = hisDoctorService.selectHisDoctorList(vmDoctor);
|
||||
if (Func.isNotEmpty(vmUserList)){
|
||||
String vmUserId = hisHospitalInfo.getVmUserId();
|
||||
//已经选中的虚拟操作员
|
||||
if (Func.isNotEmpty(vmUserId)){
|
||||
for (HisDoctor vm : vmUserList) {
|
||||
if (vmUserId.equals(vm.getDoctorId())) {
|
||||
vm.setFlag(true);//设置选中标签
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
mmap.put("vmUserList", vmUserList);
|
||||
}
|
||||
|
||||
//选择优秀科室
|
||||
HisDepartment hisDepartment = new HisDepartment();
|
||||
hisDepartment.setOrgCode(hisHospitalInfo.getOrgCode());
|
||||
hisDepartment.setIsShow(1);
|
||||
List<HisDepartment> hisDepartmentList = iHisDepartmentService.selectHisDepartmentList(hisDepartment);
|
||||
if (Func.isNotEmpty(hisDepartmentList)){
|
||||
//已经选中的优秀科室
|
||||
String excellentDeptIds = hisHospitalInfo.getExcellentDeptIds();
|
||||
if (Func.isNotEmpty(excellentDeptIds)){
|
||||
String[] deptIds= Func.toStrArray(",", excellentDeptIds);
|
||||
if (Func.isNotEmpty(deptIds)){
|
||||
for (String deptId : deptIds) {
|
||||
for (HisDepartment department : hisDepartmentList) {
|
||||
if (deptId.equals(department.getDeptId())) {
|
||||
department.setFlag(true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
//设置选中标签
|
||||
mmap.put("hisDepartmentList", hisDepartmentList);
|
||||
}
|
||||
}
|
||||
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存医疗机构
|
||||
*/
|
||||
@RequiresPermissions("his:hospital:edit")
|
||||
@Log(title = "医疗机构", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisHospitalInfo hisHospitalInfo)
|
||||
{
|
||||
return toAjax(hisHospitalInfoService.updateHisHospitalInfo(hisHospitalInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除医疗机构
|
||||
*/
|
||||
@RequiresPermissions("his:hospital:remove")
|
||||
@Log(title = "医疗机构", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisHospitalInfoService.deleteHisHospitalInfoByIds(ids));
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private ServerConfig serverConfig;
|
||||
|
||||
/**
|
||||
* 机构图标
|
||||
*/
|
||||
@Log(title = "上传机构图标", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/update/logo")
|
||||
@ResponseBody
|
||||
public AjaxResult updateLogo(@RequestParam("logoFile") MultipartFile file)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (!file.isEmpty())
|
||||
{
|
||||
String fileName = FileUploadUtils.upload(Global.getUploadPath(), file);
|
||||
String url = serverConfig.getUrl() + fileName;
|
||||
AjaxResult ajax = AjaxResult.success();
|
||||
ajax.put("data", fileName);
|
||||
ajax.put("url", url);
|
||||
return ajax;
|
||||
}
|
||||
return error();
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
return error(e.getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.web.controller.his;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisInpatient;
|
||||
import com.ruoyi.his.service.IHisInpatientService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 住院病人Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-08
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/inpatient")
|
||||
public class HisInpatientController extends BaseController
|
||||
{
|
||||
private String prefix = "his/inpatient";
|
||||
|
||||
@Autowired
|
||||
private IHisInpatientService hisInpatientService;
|
||||
|
||||
@RequiresPermissions("his:inpatient:view")
|
||||
@GetMapping()
|
||||
public String inpatient()
|
||||
{
|
||||
return prefix + "/inpatient";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询住院病人列表
|
||||
*/
|
||||
@RequiresPermissions("his:inpatient:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisInpatient hisInpatient)
|
||||
{
|
||||
startPage();
|
||||
List<HisInpatient> list = hisInpatientService.selectHisInpatientList(hisInpatient);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出住院病人列表
|
||||
*/
|
||||
@RequiresPermissions("his:inpatient:export")
|
||||
@Log(title = "住院病人", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisInpatient hisInpatient)
|
||||
{
|
||||
List<HisInpatient> list = hisInpatientService.selectHisInpatientList(hisInpatient);
|
||||
ExcelUtil<HisInpatient> util = new ExcelUtil<HisInpatient>(HisInpatient.class);
|
||||
return util.exportExcel(list, "inpatient");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增住院病人
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存住院病人
|
||||
*/
|
||||
@RequiresPermissions("his:inpatient:add")
|
||||
@Log(title = "住院病人", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisInpatient hisInpatient)
|
||||
{
|
||||
return toAjax(hisInpatientService.insertHisInpatient(hisInpatient));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改住院病人
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisInpatient hisInpatient = hisInpatientService.selectHisInpatientById(id);
|
||||
mmap.put("hisInpatient", hisInpatient);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存住院病人
|
||||
*/
|
||||
@RequiresPermissions("his:inpatient:edit")
|
||||
@Log(title = "住院病人", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisInpatient hisInpatient)
|
||||
{
|
||||
return toAjax(hisInpatientService.updateHisInpatient(hisInpatient));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除住院病人
|
||||
*/
|
||||
@RequiresPermissions("his:inpatient:remove")
|
||||
@Log(title = "住院病人", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisInpatientService.deleteHisInpatientByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisInpatientPrepayment;
|
||||
import com.ruoyi.his.service.IHisInpatientPrepaymentService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 住院预交Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-14
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/inpatientPrepayment")
|
||||
public class HisInpatientPrepaymentController extends BaseController
|
||||
{
|
||||
private String prefix = "his/inpatientPrepayment";
|
||||
|
||||
@Autowired
|
||||
private IHisInpatientPrepaymentService hisInpatientPrepaymentService;
|
||||
|
||||
@RequiresPermissions("his:inpatientPrepayment:view")
|
||||
@GetMapping()
|
||||
public String inpatientPrepayment()
|
||||
{
|
||||
return prefix + "/inpatientPrepayment";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询住院预交列表
|
||||
*/
|
||||
@RequiresPermissions("his:inpatientPrepayment:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisInpatientPrepayment hisInpatientPrepayment)
|
||||
{
|
||||
startPage();
|
||||
List<HisInpatientPrepayment> list = hisInpatientPrepaymentService.selectHisInpatientPrepaymentList(hisInpatientPrepayment);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出住院预交列表
|
||||
*/
|
||||
@RequiresPermissions("his:inpatientPrepayment:export")
|
||||
@Log(title = "住院预交", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisInpatientPrepayment hisInpatientPrepayment)
|
||||
{
|
||||
List<HisInpatientPrepayment> list = hisInpatientPrepaymentService.selectHisInpatientPrepaymentList(hisInpatientPrepayment);
|
||||
ExcelUtil<HisInpatientPrepayment> util = new ExcelUtil<HisInpatientPrepayment>(HisInpatientPrepayment.class);
|
||||
return util.exportExcel(list, "inpatientPrepayment");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增住院预交
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存住院预交
|
||||
*/
|
||||
@RequiresPermissions("his:inpatientPrepayment:add")
|
||||
@Log(title = "住院预交", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisInpatientPrepayment hisInpatientPrepayment)
|
||||
{
|
||||
return toAjax(hisInpatientPrepaymentService.insertHisInpatientPrepayment(hisInpatientPrepayment));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改住院预交
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisInpatientPrepayment hisInpatientPrepayment = hisInpatientPrepaymentService.selectHisInpatientPrepaymentById(id);
|
||||
mmap.put("hisInpatientPrepayment", hisInpatientPrepayment);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存住院预交
|
||||
*/
|
||||
@RequiresPermissions("his:inpatientPrepayment:edit")
|
||||
@Log(title = "住院预交", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisInpatientPrepayment hisInpatientPrepayment)
|
||||
{
|
||||
return toAjax(hisInpatientPrepaymentService.updateHisInpatientPrepayment(hisInpatientPrepayment));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除住院预交
|
||||
*/
|
||||
@RequiresPermissions("his:inpatientPrepayment:remove")
|
||||
@Log(title = "住院预交", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisInpatientPrepaymentService.deleteHisInpatientPrepaymentByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,126 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisInspectionApply;
|
||||
import com.ruoyi.his.service.IHisInspectionApplyService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 申请单Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-10
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/inspectionApply")
|
||||
public class HisInspectionApplyController extends BaseController
|
||||
{
|
||||
private String prefix = "his/inspectionApply";
|
||||
|
||||
@Autowired
|
||||
private IHisInspectionApplyService hisInspectionApplyService;
|
||||
|
||||
@RequiresPermissions("his:inspectionApply:view")
|
||||
@GetMapping()
|
||||
public String inspectionApply()
|
||||
{
|
||||
return prefix + "/inspectionApply";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询申请单列表
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionApply:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisInspectionApply hisInspectionApply)
|
||||
{
|
||||
startPage();
|
||||
List<HisInspectionApply> list = hisInspectionApplyService.selectHisInspectionApplyList(hisInspectionApply);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出申请单列表
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionApply:export")
|
||||
@Log(title = "申请单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisInspectionApply hisInspectionApply)
|
||||
{
|
||||
List<HisInspectionApply> list = hisInspectionApplyService.selectHisInspectionApplyList(hisInspectionApply);
|
||||
ExcelUtil<HisInspectionApply> util = new ExcelUtil<HisInspectionApply>(HisInspectionApply.class);
|
||||
return util.exportExcel(list, "inspectionApply");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增申请单
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存申请单
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionApply:add")
|
||||
@Log(title = "申请单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisInspectionApply hisInspectionApply)
|
||||
{
|
||||
return toAjax(hisInspectionApplyService.insertHisInspectionApply(hisInspectionApply));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改申请单
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisInspectionApply hisInspectionApply = hisInspectionApplyService.selectHisInspectionApplyById(id);
|
||||
mmap.put("hisInspectionApply", hisInspectionApply);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存申请单
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionApply:edit")
|
||||
@Log(title = "申请单", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisInspectionApply hisInspectionApply)
|
||||
{
|
||||
return toAjax(hisInspectionApplyService.updateHisInspectionApply(hisInspectionApply));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除申请单
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionApply:remove")
|
||||
@Log(title = "申请单", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisInspectionApplyService.deleteHisInspectionApplyByIds(ids));
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,149 @@
|
|||
package com.ruoyi.his.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.his.domain.HisInspectionReportItem;
|
||||
import com.ruoyi.his.domain.HisOutpatientExpensesBill;
|
||||
import com.ruoyi.his.domain.HisOutpatientExpensesBillDetail;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.his.domain.HisInspectionReport;
|
||||
import com.ruoyi.his.service.IHisInspectionReportService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 检查检验Controller
|
||||
*
|
||||
* @author bend
|
||||
* @date 2020-07-10
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/his/inspectionReport")
|
||||
public class HisInspectionReportController extends BaseController
|
||||
{
|
||||
private String prefix = "his/inspectionReport";
|
||||
|
||||
@Autowired
|
||||
private IHisInspectionReportService hisInspectionReportService;
|
||||
|
||||
@RequiresPermissions("his:inspectionReport:view")
|
||||
@GetMapping()
|
||||
public String inspectionReport()
|
||||
{
|
||||
return prefix + "/inspectionReport";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询检查检验列表
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionReport:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisInspectionReport hisInspectionReport)
|
||||
{
|
||||
startPage();
|
||||
List<HisInspectionReport> list = hisInspectionReportService.selectHisInspectionReportList(hisInspectionReport);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出检查检验列表
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionReport:export")
|
||||
@Log(title = "检查检验", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(HisInspectionReport hisInspectionReport)
|
||||
{
|
||||
List<HisInspectionReport> list = hisInspectionReportService.selectHisInspectionReportList(hisInspectionReport);
|
||||
ExcelUtil<HisInspectionReport> util = new ExcelUtil<HisInspectionReport>(HisInspectionReport.class);
|
||||
return util.exportExcel(list, "inspectionReport");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增检查检验
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存检查检验
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionReport:add")
|
||||
@Log(title = "检查检验", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(HisInspectionReport hisInspectionReport)
|
||||
{
|
||||
return toAjax(hisInspectionReportService.insertHisInspectionReport(hisInspectionReport));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改检查检验
|
||||
*/
|
||||
@GetMapping("/edit/{id}")
|
||||
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||
{
|
||||
HisInspectionReport hisInspectionReport = hisInspectionReportService.selectHisInspectionReportById(id);
|
||||
mmap.put("hisInspectionReport", hisInspectionReport);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存检查检验
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionReport:edit")
|
||||
@Log(title = "检查检验", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(HisInspectionReport hisInspectionReport)
|
||||
{
|
||||
return toAjax(hisInspectionReportService.updateHisInspectionReport(hisInspectionReport));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除检查检验
|
||||
*/
|
||||
@RequiresPermissions("his:inspectionReport:remove")
|
||||
@Log(title = "检查检验", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(hisInspectionReportService.deleteHisInspectionReportByIds(ids));
|
||||
}
|
||||
|
||||
@RequiresPermissions("his:inspectionReport:detail")
|
||||
@GetMapping("/detail")
|
||||
public String expensesBillDetail(@RequestParam(value = "id") Long id, ModelMap mmap)
|
||||
{
|
||||
if (StringUtils.isNotNull(id))
|
||||
{
|
||||
HisInspectionReport report = hisInspectionReportService.selectHisInspectionReportById(id);
|
||||
mmap.put("report", report);
|
||||
}
|
||||
return prefix + "/inspectionReportItem";
|
||||
}
|
||||
|
||||
@RequiresPermissions("his:inspectionReport:list")
|
||||
@PostMapping("/detail/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(HisInspectionReportItem item)
|
||||
{
|
||||
startPage();
|
||||
List<HisInspectionReportItem> list = hisInspectionReportService.selectHisInspectionReportItemList(item);
|
||||
return getDataTable(list);
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue