Commit 85cba2f2 authored by 黎聪聪's avatar 黎聪聪

咨询单管理

parent ac37690f
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
"http://java.sun.com/dtd/web-app_2_3.dtd" >
<web-app>
<display-name>Archetype Created Web Application</display-name>
</web-app>
<html>
<body>
<h2>Hello World!</h2>
</body>
</html>
package com.cftech.consultsheet.dao; package com.cftech.consultsheet.dao;
import com.alibaba.fastjson.JSONObject;
import com.cftech.consultsheet.model.ConsultSheet; import com.cftech.consultsheet.model.ConsultSheet;
import com.cftech.core.generic.GenericDao; import com.cftech.core.generic.GenericDao;
...@@ -11,5 +12,7 @@ import com.cftech.core.generic.GenericDao; ...@@ -11,5 +12,7 @@ import com.cftech.core.generic.GenericDao;
* @date: 2020-09-22 12:06 * @date: 2020-09-22 12:06
*/ */
public interface ConsultSheetMapper extends GenericDao<ConsultSheet> { public interface ConsultSheetMapper extends GenericDao<ConsultSheet> {
JSONObject updateDate(int consultId, String status, String description);
JSONObject updateStatus(ConsultSheet consultSheet);
} }
\ No newline at end of file
...@@ -23,6 +23,11 @@ ...@@ -23,6 +23,11 @@
<result column="description" property="description"/> <result column="description" property="description"/>
<result column="create_by" property="createBy"/> <result column="create_by" property="createBy"/>
<result column="update_by" property="updateBy"/> <result column="update_by" property="updateBy"/>
<result column="allergy" property="allergy"/>
<result column="symptom" property="symptom"/>
<result column="diagnosis" property="diagnosis"/>
<result column="doctor_name" property="doctorName"/>
<result column="customer_name" property="customerName"/>
</resultMap> </resultMap>
<sql id="sqlWhere"> <sql id="sqlWhere">
...@@ -53,6 +58,34 @@ ...@@ -53,6 +58,34 @@
</sql> </sql>
<sql id="sqlColumns"> <sql id="sqlColumns">
aidea.id,
aidea.consult_id,
aidea.user_name,
aidea.number_id,
aidea.benebit_id,
aidea.sex,
aidea.iphone,
aidea.past_records,
aidea.prescription,
aidea.doctor_id,
aidea.customer_id,
aidea.illness,
aidea.accounts_id,
aidea.del_flag,
aidea.status,
aidea.create_time,
aidea.update_time,
aidea.description,
aidea.create_by,
aidea.update_by,
aidea.allergy,
aidea.symptom,
aidea.diagnosis,
USER.doctor_name,
USER.customer_name
</sql>
<sql id="sqlColumn">
id, id,
consult_id, consult_id,
user_name, user_name,
...@@ -72,15 +105,18 @@ ...@@ -72,15 +105,18 @@
update_time, update_time,
description, description,
create_by, create_by,
update_by update_by,
</sql> allergy,
symptom,
diagnosis,
</sql>
<insert id="save" parameterType="com.cftech.consultsheet.model.ConsultSheet" useGeneratedKeys="true" <insert id="save" parameterType="com.cftech.consultsheet.model.ConsultSheet" useGeneratedKeys="true"
keyProperty="id"> keyProperty="id">
insert into t_aidea_consult_sheet insert into t_aidea_consult_sheet
( (
<include refid="sqlColumns"/> <include refid="sqlColumn"/>
) )
values values
( (
...@@ -104,19 +140,26 @@ ...@@ -104,19 +140,26 @@
now(), now(),
#{description, jdbcType=VARCHAR}, #{description, jdbcType=VARCHAR},
#{createBy, jdbcType=BIGINT}, #{createBy, jdbcType=BIGINT},
#{updateBy, jdbcType=BIGINT} #{updateBy, jdbcType=BIGINT},
#{allergy, jdbcType=VARCHAR},
#{updateBy, jdbcType=VARCHAR},
#{diagnosis,jdbcType=BIGINT}
#{doctorName, jdbcType=VARCHAR},
#{customerName,jdbcType=BIGINT}
) )
</insert> </insert>
<select id="fetchById" parameterType="java.lang.Long" resultMap="resultMap"> <select id="fetchById" parameterType="java.lang.Long" resultMap="resultMap">
SELECT SELECT
<include refid="sqlColumns"/> <include refid="sqlColumns"/>
FROM t_aidea_consult_sheet t FROM t_aidea_consult_sheet aidea LEFT JOIN t_qyuser USER ON aidea.doctor_id = USER.doctor_id AND
WHERE t.id=#{id} aidea.customer_id = USER.customer_id
WHERE aidea.id=#{id}
</select> </select>
<select id="count" parameterType="java.util.Map" resultType="java.lang.Integer"> <select id="count" parameterType="java.util.Map" resultType="java.lang.Integer">
SELECT COUNT(1) FROM t_aidea_consult_sheet SELECT COUNT(1) FROM t_aidea_consult_sheet aidea LEFT JOIN t_qyuser USER ON aidea.doctor_id = USER.doctor_id AND
aidea.customer_id = USER.customer_id
<include refid="sqlWhere"/> <include refid="sqlWhere"/>
</select> </select>
...@@ -124,7 +167,9 @@ ...@@ -124,7 +167,9 @@
<select id="fetchSearchByPage" parameterType="java.util.Map" resultMap="resultMap"> <select id="fetchSearchByPage" parameterType="java.util.Map" resultMap="resultMap">
SELECT SELECT
<include refid="sqlColumns"/> <include refid="sqlColumns"/>
FROM t_aidea_consult_sheet FROM t_aidea_consult_sheet aidea
LEFT JOIN t_qyuser USER ON aidea.doctor_id = USER.doctor_id AND
aidea.customer_id = USER.customer_id
<include refid="sqlWhere"/> <include refid="sqlWhere"/>
<if test="sort!=null">ORDER BY ${sort.param} ${sort.type}</if> <if test="sort!=null">ORDER BY ${sort.param} ${sort.type}</if>
<if test="limit>0">limit #{offset},#{limit}</if> <if test="limit>0">limit #{offset},#{limit}</if>
...@@ -153,7 +198,7 @@ ...@@ -153,7 +198,7 @@
sex = #{sex, jdbcType=BIGINT}, sex = #{sex, jdbcType=BIGINT},
</if> </if>
<if test="iPhone != null"> <if test="iPhone != null">
i_phone = #{iPhone, jdbcType=VARCHAR}, iphone = #{iPhone, jdbcType=VARCHAR},
</if> </if>
<if test="pastRecords != null"> <if test="pastRecords != null">
past_records = #{pastRecords, jdbcType=VARCHAR}, past_records = #{pastRecords, jdbcType=VARCHAR},
...@@ -191,6 +236,15 @@ ...@@ -191,6 +236,15 @@
<if test="updateBy != null"> <if test="updateBy != null">
update_by = #{updateBy, jdbcType=BIGINT}, update_by = #{updateBy, jdbcType=BIGINT},
</if> </if>
<if test="allergy != null">
allergy = #{allergy, jdbcType=VARCHAR},
</if>
<if test="symptom != null">
symptom = #{symptom, jdbcType=VARCHAR},
</if>
<if test="diagnosis != null">
diagnosis = #{diagnosis, jdbcType=BIGINT},
</if>
</set> </set>
where id=#{id,jdbcType=BIGINT} where id=#{id,jdbcType=BIGINT}
</update> </update>
...@@ -198,4 +252,6 @@ ...@@ -198,4 +252,6 @@
<update id="delete" parameterType="java.lang.Long"> <update id="delete" parameterType="java.lang.Long">
update t_aidea_consult_sheet set del_flag=1 where id=#{id,jdbcType=BIGINT} update t_aidea_consult_sheet set del_flag=1 where id=#{id,jdbcType=BIGINT}
</update> </update>
</mapper>
\ No newline at end of file
</mapper>
package com.cftech.consultsheet.model; package com.cftech.consultsheet.model;
import com.alibaba.fastjson.annotation.JSONField;
import com.cftech.core.poi.ExportConfig; import com.cftech.core.poi.ExportConfig;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import lombok.Data; import lombok.Data;
import org.codehaus.jackson.format.DataFormatMatcher;
import java.io.Serializable; import java.io.Serializable;
import java.util.Date; import java.util.Date;
...@@ -13,49 +17,59 @@ import java.util.Date; ...@@ -13,49 +17,59 @@ import java.util.Date;
* @date: 2020-09-22 12:06 * @date: 2020-09-22 12:06
*/ */
@Data @Data
public class ConsultSheet implements Serializable { public class ConsultSheet extends UserSheet implements Serializable {
/* 主键id */
/* 主键id */
private Long id; private Long id;
/* 咨询单编码 */ /* 咨询单编码 */
@ExportConfig(value = "咨询单编码", width = 100, showLevel = 1) @ExportConfig(value = "咨询单编码", width = 100, showLevel = 1)
private Long consultId; private Long consultId;
/* 用药人name */ /* 用药人name */
@ExportConfig(value = "用药人name", width = 100, showLevel = 1) @ExportConfig(value = "用药人姓名", width = 100, showLevel = 1)
private String userName; private String userName;
/* 身份证号 */ /* 身份证号 */
@ExportConfig(value = "身份证号", width = 100, showLevel = 1)
private String numberId; private String numberId;
/* 出生年月 */ /* 出生年月 */
@ExportConfig(value = "出生年月", width = 100, showLevel = 1)
private Date benebitId; @JSONField(format="yyyy-MM-dd")
private Date benebitId;
/* 性别 */ /* 性别 */
@ExportConfig(value = "性别", width = 100, showLevel = 1) @ExportConfig(value = "性别", width = 100, showLevel = 1)
private Long sex; private Long sex;
/* 手机号 */ /* 手机号 */
@ExportConfig(value = "手机号", width = 100, showLevel = 1) @ExportConfig(value = "联系电话", width = 100, showLevel = 1)
private String iPhone; private Long iPhone;
/* 疾病史 */ /* 疾病史 */
@ExportConfig(value = "疾病史", width = 100, showLevel = 1) @ExportConfig(value = "疾病史", width = 100, showLevel = 1)
private String pastRecords; private String pastRecords;
/* 处方单 */ /* 处方单 */
@ExportConfig(value = "处方单", width = 100, showLevel = 1) @ExportConfig(value = "处方单", width = 100, showLevel = 1)
private String Prescription; private String Prescription;
/* 药师id */ /* 药师id */
@ExportConfig(value = "药师id", width = 100, showLevel = 1)
private Long doctorId; private Long doctorId;
/* 客服id */ /* 客服id */
@ExportConfig(value = "客服id", width = 100, showLevel = 1)
private Long customerId; private Long customerId;
/* 病情描述 */ /* 病情描述 */
@ExportConfig(value = "病情描述", width = 100, showLevel = 1) @ExportConfig(value = "病情描述", width = 100, showLevel = 1)
private Long illness; private String illness;
/* 过敏史 */
@ExportConfig(value = "过敏史", width = 100, showLevel = 1)
private String allergy;
/* 本次确认症状 */
private String symptom;
/*是否已在医院确诊*/
private Long diagnosis;
/* 所属的账号 */ /* 所属的账号 */
private Long accountsId; private Long accountsId;
/* 删除标识 */ /* 删除标识 */
private boolean delFlag; private boolean delFlag;
/* 状态 */ /* 状态 */
@ExportConfig(value = "是否审核", width = 100, showLevel = 1)
private String status; private String status;
/* 创建时间 */ /* 创建时间 */
private Date createTime; private Date createTime;
...@@ -68,6 +82,8 @@ public class ConsultSheet implements Serializable { ...@@ -68,6 +82,8 @@ public class ConsultSheet implements Serializable {
/* 更新人 */ /* 更新人 */
private Long updateBy; private Long updateBy;
public ConsultSheet() { public ConsultSheet() {
this.delFlag = false; this.delFlag = false;
this.status = "0"; this.status = "0";
......
package com.cftech.consultsheet.model;
import com.cftech.core.poi.ExportConfig;
import lombok.Data;
import java.util.Date;
/**
* @author :licc
* @date :Created in 2020/9/23 20:56
* @description:
*/
@Data
public class ConsultSheetVO {
/* 咨询单编码 */
@ExportConfig(value = "咨询单编码", width = 100, showLevel = 1)
private Long consultId;
/* 用药人name */
@ExportConfig(value = "用药人姓名", width = 100, showLevel = 1)
private String userName;
/* 性别 */
@ExportConfig(value = "性别", width = 100, showLevel = 1)
private String sex;
/* 手机号 */
@ExportConfig(value = "联系电话", width = 100, showLevel = 1)
private Long phone;
/* 疾病史 */
@ExportConfig(value = "疾病史", width = 100, showLevel = 1)
private String pastRecords;
/* 病情描述 */
@ExportConfig(value = "病情描述", width = 100, showLevel = 1)
private String illness;
/* 过敏史 */
@ExportConfig(value = "过敏史", width = 100, showLevel = 1)
private String allergy;
/* 状态 */
@ExportConfig(value = "是否审核", width = 100, showLevel = 1)
private String status;
/* 药师姓名*/
@ExportConfig(value = "药师姓名", width = 100, showLevel = 1)
private String doctorName;
/* 客服姓名*/
@ExportConfig(value = "客服姓名", width = 100, showLevel = 1)
private String customerName;
}
package com.cftech.consultsheet.model;
import com.cftech.core.poi.ExportConfig;
import lombok.Data;
import org.omg.CORBA.PRIVATE_MEMBER;
/**
* @author :licc
* @date :Created in 2020/9/23 11:57
* @description:
*/
@Data
public class UserSheet {
/* 药师姓名*/
@ExportConfig(value = "药师姓名", width = 100, showLevel = 1)
private String doctorName;
/* 客服姓名*/
@ExportConfig(value = "客服姓名", width = 100, showLevel = 1)
private String customerName;
}
package com.cftech.consultsheet.service; package com.cftech.consultsheet.service;
import com.alibaba.fastjson.JSONObject;
import com.cftech.consultsheet.model.ConsultSheet; import com.cftech.consultsheet.model.ConsultSheet;
import com.cftech.core.generic.GenericService; import com.cftech.core.generic.GenericService;
import com.cftech.core.sql.Conds;
/** /**
* 咨询单Service * 咨询单Service
* *
...@@ -12,4 +15,6 @@ import com.cftech.core.generic.GenericService; ...@@ -12,4 +15,6 @@ import com.cftech.core.generic.GenericService;
public interface ConsultSheetService extends GenericService<ConsultSheet> { public interface ConsultSheetService extends GenericService<ConsultSheet> {
} }
package com.cftech.consultsheet.service.impl; package com.cftech.consultsheet.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.cftech.consultsheet.dao.ConsultSheetMapper; import com.cftech.consultsheet.dao.ConsultSheetMapper;
import com.cftech.consultsheet.model.ConsultSheet; import com.cftech.consultsheet.model.ConsultSheet;
import com.cftech.consultsheet.service.ConsultSheetService; import com.cftech.consultsheet.service.ConsultSheetService;
...@@ -28,4 +29,6 @@ public GenericDao<ConsultSheet> getGenericMapper() { ...@@ -28,4 +29,6 @@ public GenericDao<ConsultSheet> getGenericMapper() {
return consultSheetMapper; return consultSheetMapper;
} }
} }
\ No newline at end of file
/**
* Created by 16444 on 2020/9/22.
*/
public class TestJava {
}
...@@ -14,8 +14,6 @@ ...@@ -14,8 +14,6 @@
<modules> <modules>
<module>consult-module</module> <module>consult-module</module>
<module>consult-module-web</module> <module>consult-module-web</module>
<module>product-classify-module</module>
<module>product-classify-module-web</module>
</modules> </modules>
<dependencies> <dependencies>
......
<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/maven-v4_0_0.xsd">
<parent>
<artifactId>aidea-modules</artifactId>
<groupId>com.cftech</groupId>
<version>1.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>product-classify-module-web</artifactId>
<packaging>war</packaging>
<name>product-classify-module-web Maven Webapp</name>
<url>http://maven.apache.org</url>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.cftech</groupId>
<artifactId>product-classify-module</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
</dependencies>
<build>
<finalName>product-classify-module-web</finalName>
</build>
</project>
<?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>aidea-modules</artifactId>
<groupId>com.cftech</groupId>
<version>1.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>product-classify-module</artifactId>
<dependencies>
<dependency>
<groupId>com.cftech</groupId>
<artifactId>sys-module</artifactId>
<version>1.0-SNAPSHOT</version>
<scope>compile</scope>
</dependency>
</dependencies>
</project>
\ No newline at end of file
package com.cftech.productclassify.dao;
import com.cftech.productclassify.model.Productclassify;
import com.cftech.core.generic.GenericDao;
import java.util.List;
import java.util.Map;
/**
* 产品分类Mapper
*
* @author Buyj
* @date: 2020-09-22 18:06
*/
public interface ProductclassifyMapper extends GenericDao<Productclassify> {
/**
* 查产品分类
* @param params
* @return
*/
List<Productclassify> fetchTreeByPage(Map<String, Object> params);
}
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.cftech.productclassify.dao.ProductclassifyMapper">
<resultMap id="resultMap" type="com.cftech.productclassify.model.Productclassify">
<id column="id" property="id"/>
<result column="classify_name" property="classifyName"/>
<result column="classify_number" property="classifyNumber"/>
<result column="classify_img" property="classifyImg"/>
<result column="sort" property="sort"/>
<result column="whether_recommend" property="whetherRecommend"/>
<result column="parent_id" property="parentId"/>
<result column="parentName" property="parentName"/>
<result column="accounts_id" property="accountsId"/>
<result column="del_flag" property="delFlag"/>
<result column="status" property="status"/>
<result column="create_time" property="createTime"/>
<result column="update_time" property="updateTime"/>
<result column="description" property="description"/>
<result column="create_by" property="createBy"/>
<result column="update_by" property="updateBy"/>
</resultMap>
<sql id="sqlWhere">
<if test="conds!=null">
<trim prefix="WHERE" prefixOverrides="AND|OR">
<foreach collection="conds.conds" index="index" item="cond">
${cond.linkType}
<if test="cond.condType == 'EQUAL'">${cond.param} = #{cond.value}</if>
<if test="cond.condType == 'NOTEQUAL'">${cond.param} &lt;&gt; #{cond.value}</if>
<if test="cond.condType == 'GREATEQUAL'">${cond.param} &gt;= #{cond.value}</if>
<if test="cond.condType == 'GREATTHAN'">${cond.param} &gt; #{cond.value}</if>
<if test="cond.condType == 'LESSEQUAL'">${cond.param} &lt;= #{cond.value}</if>
<if test="cond.condType == 'LESSTHAN'">${cond.param} &lt; #{cond.value}</if>
<if test="cond.condType == 'BETWEEN'">${cond.param} BETWEEN #{cond.startValue} AND
#{cond.endValue}
</if>
<if test="cond.condType == 'ISNULL'">${cond.param} IS NULL</if>
<if test="cond.condType == 'NOTNULL'">${cond.param} IS NOT NULL</if>
<if test="cond.condType == 'LIKE'">${cond.param} LIKE #{cond.value}</if>
<if test="cond.condType == 'IN'">${cond.param} IN
<foreach item="item" index="index" collection="cond.value" open="(" separator="," close=")">
#{item}
</foreach>
</if>
</foreach>
</trim>
</if>
</sql>
<sql id="sqlColumns">
id,
classify_name,
classify_number,
classify_img,
sort,
whether_recommend,
parent_id,
accounts_id,
del_flag,
status,
create_time,
update_time,
description,
create_by,
update_by
</sql>
<insert id="save" parameterType="com.cftech.productclassify.model.Productclassify" useGeneratedKeys="true"
keyProperty="id">
insert into t_aidea_product_classify
(
<include refid="sqlColumns"/>
)
values
(
#{id, jdbcType=BIGINT},
#{classifyName, jdbcType=VARCHAR},
#{classifyNumber, jdbcType=VARCHAR},
#{classifyImg, jdbcType=VARCHAR},
#{sort, jdbcType=VARCHAR},
#{whetherRecommend, jdbcType=VARCHAR},
#{parentId, jdbcType=VARCHAR},
#{accountsId, jdbcType=BIGINT},
#{delFlag, jdbcType=TINYINT},
#{status, jdbcType=VARCHAR},
now(),
now(),
#{description, jdbcType=VARCHAR},
#{createBy, jdbcType=BIGINT},
#{updateBy, jdbcType=BIGINT}
)
</insert>
<select id="fetchTreeByPage" parameterType="java.util.Map" resultMap="resultMap">
SELECT
<include refid="sqlColumns"/>
FROM t_aidea_product_classify
<include refid="sqlWhere"/>
<if test="sort!=null">ORDER BY ${sort.param} ${sort.type}</if>
<if test="limit>0">limit #{offset},#{limit}</if>
</select>
<select id="fetchById" parameterType="java.lang.Long" resultMap="resultMap">
SELECT
<include refid="sqlColumns"/>
FROM t_aidea_product_classify t
WHERE t.id=#{id}
</select>
<select id="count" parameterType="java.util.Map" resultType="java.lang.Integer">
SELECT
COUNT(1)
FROM
t_aidea_product_classify a
LEFT JOIN t_aidea_product_classify b ON b.id = a.parent_id
AND b.del_flag = '0'
<include refid="sqlWhere"/>
</select>
<select id="fetchSearchByPage" parameterType="java.util.Map" resultMap="resultMap">
SELECT
a.id id,
a.classify_name classifyName,
a.classify_number classifyNumber,
a.classify_img classifyImg,
a.sort sort,
a.whether_recommend whetherRecommend,
a.parent_id parentId,
a.del_flag delFlag,
a.create_time createTime,
a.update_time updateTime,
a.description description,
a.create_by crateBy,
a.update_by updateBy,
b.classify_name parentName
FROM
t_aidea_product_classify a
LEFT JOIN t_aidea_product_classify b ON b.id = a.parent_id
AND b.del_flag = '0'
<include refid="sqlWhere"/>
<if test="sort!=null">ORDER BY ${sort.param} ${sort.type}</if>
<if test="limit>0">limit #{offset},#{limit}</if>
</select>
<update id="update" parameterType="com.cftech.productclassify.model.Productclassify">
update t_aidea_product_classify
<set>
<if test="id != null">
id = #{id, jdbcType=BIGINT},
</if>
<if test="classifyName != null">
classify_name = #{classifyName, jdbcType=VARCHAR},
</if>
<if test="classifyNumber != null">
classify_number = #{classifyNumber, jdbcType=VARCHAR},
</if>
<if test="classifyImg != null">
classify_img = #{classifyImg, jdbcType=VARCHAR},
</if>
<if test="sort != null">
sort = #{sort, jdbcType=VARCHAR},
</if>
<if test="whetherRecommend != null">
whether_recommend = #{whetherRecommend, jdbcType=VARCHAR},
</if>
<if test="parentId != null">
parent_id = #{parentId, jdbcType=VARCHAR},
</if>
<if test="accountsId != null">
accounts_id = #{accountsId, jdbcType=BIGINT},
</if>
<if test="delFlag != null">
del_flag = #{delFlag, jdbcType=TINYINT},
</if>
<if test="status != null">
status = #{status, jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime, jdbcType=TIMESTAMP},
</if>
<if test="description != null">
description = #{description, jdbcType=VARCHAR},
</if>
<if test="createBy != null">
create_by = #{createBy, jdbcType=BIGINT},
</if>
<if test="updateBy != null">
update_by = #{updateBy, jdbcType=BIGINT},
</if>
</set>
where id=#{id,jdbcType=BIGINT}
</update>
<update id="delete" parameterType="java.lang.Long">
update t_aidea_product_classify set del_flag=1 where id=#{id,jdbcType=BIGINT}
</update>
</mapper>
\ No newline at end of file
package com.cftech.productclassify.model;
import com.cftech.core.poi.ExportConfig;
import lombok.Data;
import org.apache.cxf.jaxws.handler.types.CString;
import java.io.Serializable;
import java.util.Date;
/**
* 产品分类
*
* @author Buyj
* @date: 2020-09-22 18:06
*/
@Data
public class Productclassify implements Serializable {
/* 主键id */
private Long id;
/* 分类名称 */
@ExportConfig(value = "分类名称", width = 100, showLevel = 2)
private String classifyName;
/* 分类编码 */
@ExportConfig(value = "分类编码", width = 100, showLevel = 2)
private String classifyNumber;
/* 分类banner图 */
@ExportConfig(value = "分类banner图", width = 100, showLevel = 1)
private String classifyImg;
/* 序号 */
@ExportConfig(value = "序号", width = 100, showLevel = 2)
private String sort;
/* 是否推荐 */
@ExportConfig(value = "是否推荐(是/否)", width = 200, showLevel = 2)
private String whetherRecommend;
/**
* 父级ID
*/
private String parentId;
/**
* 父级ID 对应的产品分类名称
*/
@ExportConfig(value = "父级编码(不填默认为第一级)", width = 300, showLevel = 2)
private String parentName;
/**
* 父级编码
*/
private String parentNumber;
/* 所属的账号 */
private Long accountsId;
/* 删除标识 */
private boolean delFlag;
/* 状态 */
private String status;
/* 创建时间 */
private Date createTime;
/* 更新时间 */
private Date updateTime;
/* 备注 */
private String description;
/* 创建人 */
private Long createBy;
/* 更新人 */
private Long updateBy;
public Productclassify() {
this.delFlag = false;
this.status = "0";
}
}
\ No newline at end of file
package com.cftech.productclassify.service;
import com.cftech.core.sql.Conds;
import com.cftech.core.sql.Sort;
import com.cftech.productclassify.model.Productclassify;
import com.cftech.core.generic.GenericService;
import java.util.List;
import java.util.Map;
/**
* 产品分类Service
*
* @author Buyj
* @date: 2020-09-22 18:06
*/
public interface ProductclassifyService extends GenericService<Productclassify> {
/**
* 查找产品分类
* @param conds
* @param sort
* @param pageNo
* @param pageSize
* @return
*/
List<Productclassify> fetchTreeByPage(Conds conds , Sort sort,int pageNo , int pageSize);
}
package com.cftech.productclassify.service.impl;
import com.cftech.core.sql.Sort;
import com.cftech.productclassify.model.Productclassify;
import com.cftech.productclassify.dao.ProductclassifyMapper;
import com.cftech.productclassify.service.ProductclassifyService;
import com.cftech.core.generic.GenericDao;
import com.cftech.core.generic.GenericServiceImpl;
import com.cftech.core.sql.Conds;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* 产品分类ServiceImpl
*
* @author Buyj
* @date: 2020-09-22 18:06
*/
@Service("productclassifyService")
public class ProductclassifyServiceImpl extends GenericServiceImpl<Productclassify> implements ProductclassifyService {
@Autowired
@Qualifier("productclassifyMapper")
private ProductclassifyMapper productclassifyMapper;
@Override
public GenericDao<Productclassify> getGenericMapper() {
return productclassifyMapper;
}
@Override
public List<Productclassify> fetchTreeByPage(Conds conds, Sort sort, int pageNo, int pageSize) {
Map<String, Object> params = new HashMap<>();
params.put("conds", conds);
params.put("offset", pageNo > 0 ? pageNo : 0);
params.put("limit", pageSize > 0 ? pageSize : 0);
params.put("sort", sort);
return productclassifyMapper.fetchTreeByPage(params);
}
}
\ No newline at end of file
...@@ -39,8 +39,8 @@ WOEK_TEMPLATE_MESSAGE=8m-_tt_EqoQO-wsE6_JLJdn3nO15_hgUp9mLTujz5RU ...@@ -39,8 +39,8 @@ WOEK_TEMPLATE_MESSAGE=8m-_tt_EqoQO-wsE6_JLJdn3nO15_hgUp9mLTujz5RU
userfiles.imgdir=E:\\fileResource userfiles.imgdir=E:\\fileResource
#\u56FE\u7247\u8BBF\u95EE\u5730\u5740 #\u56FE\u7247\u8BBF\u95EE\u5730\u5740
ROOT_ORG_NAME=\u827E\u8FEA\u836F\u4E1A IMAGEURL=/schaeffler/mobile/qybase/showPic?picFileName={PICFILENAME}
IMAGEURL=/aidea/mobile/qybase/showPic?picFileName={PICFILENAME} ROOT_ORG_NAME=\u4E1C\u660C\u96C6\u56E2
ROOT_PAPERCATEGORY_NAME=\u95EE\u5377\u7C7B\u578B ROOT_PAPERCATEGORY_NAME=\u95EE\u5377\u7C7B\u578B
ROOT_QUESTIONSCATEGORY_NAME=\u95EE\u9898\u7C7B\u522B ROOT_QUESTIONSCATEGORY_NAME=\u95EE\u9898\u7C7B\u522B
ROOT_MATERIALCATEGORY_NAME=\u7D20\u6750\u7C7B\u522B ROOT_MATERIALCATEGORY_NAME=\u7D20\u6750\u7C7B\u522B
...@@ -106,7 +106,6 @@ orderDeliverGoodsTemplateId=TH3I5prFYPC54M14zFJfgN4gvjx8SpJayctIHmzThwg ...@@ -106,7 +106,6 @@ orderDeliverGoodsTemplateId=TH3I5prFYPC54M14zFJfgN4gvjx8SpJayctIHmzThwg
#\u670D\u52A1\u5B8C\u6210\u901A\u77E5 #\u670D\u52A1\u5B8C\u6210\u901A\u77E5
serverEndTemplateId=7L1KIroXNxejxotFTzll-dVLdo1xbmqoiAo7UmDKWcc serverEndTemplateId=7L1KIroXNxejxotFTzll-dVLdo1xbmqoiAo7UmDKWcc
PRODUCT_CLASSIFY_FATHER_NAME=\uFFFD\uFFFD\u01B7\uFFFD\uFFFD\uFFFD\uFFFD
#\u54C1\u724C\u7533\u8BF7\u6D88\u606F\u6A21\u677F #\u54C1\u724C\u7533\u8BF7\u6D88\u606F\u6A21\u677F
brandApplyCommTemplateId=82ByH2tkWI1-jlYiWr_-CIihWsgjrvLdFvuO771FwBo brandApplyCommTemplateId=82ByH2tkWI1-jlYiWr_-CIihWsgjrvLdFvuO771FwBo
......
...@@ -14,7 +14,9 @@ log4j.appender.FILE.DatePattern='.'yyyy-MM-dd ...@@ -14,7 +14,9 @@ log4j.appender.FILE.DatePattern='.'yyyy-MM-dd
log4j.appender.FILE.layout=org.apache.log4j.PatternLayout log4j.appender.FILE.layout=org.apache.log4j.PatternLayout
#log4j.appender.FILE.layout=org.apache.log4j.HTMLLayout #log4j.appender.FILE.layout=org.apache.log4j.HTMLLayout
log4j.appender.FILE.layout.ConversionPattern=[%-5p] %d{yyyy-MM-dd HH\:mm\:ss} %C{8}@(%F\:%L)\:%m%n log4j.appender.FILE.layout.ConversionPattern=[%-5p] %d{yyyy-MM-dd HH\:mm\:ss} %C{8}@(%F\:%L)\:%m%n
log4j.appender.A1=org.apache.log4j.RollingFileAppender
log4j.appender.A1.Encoding=UTF-8
log4j.appender.A1.File=all.log
# mybatis log # mybatis log
log4j.logger.com=DEBUG log4j.logger.com=DEBUG
...@@ -21,7 +21,7 @@ ...@@ -21,7 +21,7 @@
*/ */
//var URL = base + '/ueditor-min-1.4.3/'; //var URL = base + '/ueditor-min-1.4.3/';
//var URL = 'plugins/ueditor-min-1.4.3/'; //var URL = 'plugins/ueditor-min-1.4.3/';
var URL = '/aidea/assets/adminlte/plugins/ueditor-min-1.4.3/'; var URL = '/schaeffler/assets/adminlte/plugins/ueditor-min-1.4.3/';
/** /**
* 配置项主体。注意,此处所有涉及到路径的配置别遗漏URL变量。 * 配置项主体。注意,此处所有涉及到路径的配置别遗漏URL变量。
......
...@@ -365,4 +365,6 @@ public class Conds { ...@@ -365,4 +365,6 @@ public class Conds {
public List<Cond> getConds() { public List<Cond> getConds() {
return conds; return conds;
} }
} }
...@@ -18,7 +18,7 @@ public class OKHttpUtils { ...@@ -18,7 +18,7 @@ public class OKHttpUtils {
static OkHttpClient client; static OkHttpClient client;
static { static {
OkHttpClient.Builder builder = new OkHttpClient.Builder(); OkHttpClient.Builder builder = new OkHttpClient.Builder();
Dispatcher dispatcher = new Dispatcher(); Dispatcher dispatcher = new Dispatcher();
dispatcher.setMaxRequests(100); dispatcher.setMaxRequests(100);
dispatcher.setMaxRequestsPerHost(50); dispatcher.setMaxRequestsPerHost(50);
......
...@@ -14,7 +14,7 @@ public class SystemConfig { ...@@ -14,7 +14,7 @@ public class SystemConfig {
try { try {
// inputStream = SystemConfig.class.newInstance().getClass() // inputStream = SystemConfig.class.newInstance().getClass()
// .getClassLoader().getResourceAsStream(""); // .getClassLoader().getResourceAsStream("");
p.load(new InputStreamReader(SystemConfig.class.getClassLoader().getResourceAsStream("/common-test.properties"), "GBK")); p.load(new InputStreamReader(SystemConfig.class.getClassLoader().getResourceAsStream("/common-test.properties"), "utf-8"));
inputStreamRedis = SystemConfig.class.newInstance().getClass() inputStreamRedis = SystemConfig.class.newInstance().getClass()
.getClassLoader().getResourceAsStream("/redis-config-test.properties"); .getClassLoader().getResourceAsStream("/redis-config-test.properties");
......
...@@ -242,9 +242,6 @@ ...@@ -242,9 +242,6 @@
#if($cosconfig.cosType == "qiniu") #if($cosconfig.cosType == "qiniu")
<option value="$cosconfig.id">七牛</option> <option value="$cosconfig.id">七牛</option>
#end #end
#if($cosconfig.cosType == "local")
<option value="$cosconfig.id">本地</option>
#end
#end #end
</select> </select>
</div> </div>
......
...@@ -69,7 +69,6 @@ ...@@ -69,7 +69,6 @@
</ol> </ol>
</section> </section>
<!-- Main content --> <!-- Main content -->
<section class="content"> <section class="content">
<div class="row"> <div class="row">
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<html> <html>
<head> <head>
<base href="#springUrl('/assets/adminlte/')"/> <base href="#springUrl('/assets/adminlte/')"/>
<meta charset="utf-8"> <meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>工作台</title> <title>工作台</title>
<!-- Tell the browser to be responsive to screen width --> <!-- Tell the browser to be responsive to screen width -->
......
package com.cftech.mp.fans.controller; package com.cftech.mp.fans.controller;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.cftech.accounts.service.MpAccountsService; import com.cftech.accounts.service.MpAccountsService;
import com.cftech.core.scope.OrderType; import com.cftech.core.scope.OrderType;
...@@ -82,7 +83,7 @@ public class FanssgroupController { ...@@ -82,7 +83,7 @@ public class FanssgroupController {
// 添加粉丝类型跳转页面 // 添加粉丝类型跳转页面
@RequestMapping(value = "/toadd",method = {RequestMethod.POST,RequestMethod.GET}) @RequestMapping(value = "/toadd",method = {RequestMethod.POST,RequestMethod.GET})
public String toadd(HttpServletRequest request, public String toadd(HttpServletRequest request,
HttpServletResponse response, Model model, Long id) { HttpServletResponse response, Model model, Long id) {
return "/fanssgroup/fanssgroupadd"; return "/fanssgroup/fanssgroupadd";
} }
// 修改粉丝类型跳转页面 // 修改粉丝类型跳转页面
......
...@@ -66,6 +66,7 @@ public class MpFanssController { ...@@ -66,6 +66,7 @@ public class MpFanssController {
model.addAttribute("startTime", startTime); model.addAttribute("startTime", startTime);
model.addAttribute("endTime", endTime); model.addAttribute("endTime", endTime);
model.addAttribute("mpFanssEntity", mpFanssEntity); model.addAttribute("mpFanssEntity", mpFanssEntity);
return "managefans/fansslist"; return "managefans/fansslist";
} }
......
...@@ -3,6 +3,7 @@ package com.cftech.mp.fans.model; ...@@ -3,6 +3,7 @@ package com.cftech.mp.fans.model;
import com.cftech.sys.model.BasicEntity; import com.cftech.sys.model.BasicEntity;
import com.fasterxml.jackson.databind.PropertyNamingStrategy; import com.fasterxml.jackson.databind.PropertyNamingStrategy;
import com.fasterxml.jackson.databind.annotation.JsonNaming; import com.fasterxml.jackson.databind.annotation.JsonNaming;
import lombok.Data;
import org.codehaus.jackson.map.annotate.JsonSerialize; import org.codehaus.jackson.map.annotate.JsonSerialize;
import java.util.Date; import java.util.Date;
...@@ -12,6 +13,7 @@ import java.util.Date; ...@@ -12,6 +13,7 @@ import java.util.Date;
* *
*/ */
@JsonSerialize @JsonSerialize
@Data
@JsonNaming(PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy.class) @JsonNaming(PropertyNamingStrategy.LowerCaseWithUnderscoresStrategy.class)
public class MpFanssEntity extends BasicEntity{ public class MpFanssEntity extends BasicEntity{
private static final long serialVersionUID = -2537256381609738771L; private static final long serialVersionUID = -2537256381609738771L;
......
...@@ -238,12 +238,6 @@ ...@@ -238,12 +238,6 @@
<version>1.0-SNAPSHOT</version> <version>1.0-SNAPSHOT</version>
<type>war</type> <type>war</type>
</dependency> </dependency>
<dependency>
<groupId>com.cftech</groupId>
<artifactId>product-classify-module-web</artifactId>
<version>1.0-SNAPSHOT</version>
<type>war</type>
</dependency>
<!--<dependency> <!--<dependency>
<groupId>com.cftech</groupId> <groupId>com.cftech</groupId>
<artifactId>fours-job-module</artifactId> <artifactId>fours-job-module</artifactId>
......
...@@ -112,19 +112,19 @@ ...@@ -112,19 +112,19 @@
maxlength="50" placeholder="组织名称" required="required" maxlength="50" placeholder="组织名称" required="required"
value="$!{data.orgName}"> value="$!{data.orgName}">
</div> </div>
<!--<div class="form-group form-md-line-input">--> <div class="form-group form-md-line-input">
<!--<label>组织分类</label>--> <label>组织分类</label>
<!--<div class="input-group">--> <div class="input-group">
<!--<input type="text" id="orgtypeId" name="orgtypeId" value="$!{data.orgtypeId}"--> <input type="text" id="orgtypeId" name="orgtypeId" value="$!{data.orgtypeId}"
<!--class="form-control" style="display: none">--> class="form-control" style="display: none">
<!--<input type="text" id="orgtypeName" name="orgtypeName" value="$!{orgtypeName}"--> <input type="text" id="orgtypeName" name="orgtypeName" value="$!{orgtypeName}"
<!--class="form-control" disabled>--> class="form-control" disabled>
<!--<span class="input-group-btn">--> <span class="input-group-btn">
<!--<button type="button" id="orgtypeSelect"--> <button type="button" id="orgtypeSelect"
<!--class="btn btn-info btn-flat">选择</button>--> class="btn btn-info btn-flat">选择</button>
<!--</span>--> </span>
<!--</div>--> </div>
<!--</div>--> </div>
<!--<div class="checkbox">--> <!--<div class="checkbox">-->
<!--<label>--> <!--<label>-->
<!--<input type="checkbox" id="isAdminUnit" name="isAdminUnit"--> <!--<input type="checkbox" id="isAdminUnit" name="isAdminUnit"-->
......
...@@ -105,7 +105,7 @@ public class OrgUnitController { ...@@ -105,7 +105,7 @@ public class OrgUnitController {
//提交编辑页面(新增、修改) //提交编辑页面(新增、修改)
@RequiresPermissions(value = PermissionSign.ORGUNIT_EDIT) @RequiresPermissions(value = PermissionSign.ORGUNIT_EDIT)
@RequestMapping(value = "/formData") @RequestMapping(value = "/formData",method = {RequestMethod.POST})
@ResponseBody @ResponseBody
public JSONObject formData(OrgUnit orgUnit, Model model, HttpServletRequest request) { public JSONObject formData(OrgUnit orgUnit, Model model, HttpServletRequest request) {
Long accountsId = UserUtils.getmpaccounts(request); Long accountsId = UserUtils.getmpaccounts(request);
...@@ -123,20 +123,20 @@ public class OrgUnitController { ...@@ -123,20 +123,20 @@ public class OrgUnitController {
orgUnit.setParentIds("0," + orgUnit.getId() + ","); orgUnit.setParentIds("0," + orgUnit.getId() + ",");
} }
//同步至企业号 // 2017-10-27 取消同步企业号,组织功能
if (StringUtils.isEmpty(orgUnit.getWxorgId())) { // if (StringUtils.isEmpty(orgUnit.getWxorgId())) {
int wxorgid = qyOrgUtil.create(orgUnit, parentOrgUnit); // int wxorgid = qyOrgUtil.create(orgUnit, parentOrgUnit);
if (wxorgid == -1) { // if (wxorgid == -1) {
log.error("同步微信端出错," + orgUnit.toString()); // log.error("同步微信端出错," + orgUnit.toString());
} else { // } else {
orgUnit.setWxorgId("" + wxorgid); // orgUnit.setWxorgId("" + wxorgid);
//
} // }
} else { // } else {
if (!qyOrgUtil.update(orgUnit)) { // if (!qyOrgUtil.update(orgUnit)) {
log.error("同步微信端出错," + orgUnit.toString()); // log.error("同步微信端出错," + orgUnit.toString());
} // }
} // }
orgUnitService.updateCache(orgUnit); orgUnitService.updateCache(orgUnit);
rtnJson.put("errorNo", 0); rtnJson.put("errorNo", 0);
...@@ -157,13 +157,14 @@ public class OrgUnitController { ...@@ -157,13 +157,14 @@ public class OrgUnitController {
orgUnit.setUpdateBy(UserUtils.getUser().getId()); orgUnit.setUpdateBy(UserUtils.getUser().getId());
orgUnitService.saveCache(orgUnit); orgUnitService.saveCache(orgUnit);
int wxorgid = qyOrgUtil.create(orgUnit, parentOrgUnit); // 2017-10-27 取消同步企业号,组织功能
if (wxorgid == -1 || wxorgid == 0) { // int wxorgid = qyOrgUtil.create(orgUnit, parentOrgUnit);
rtnJson.put("errorNo", 1); // if (wxorgid == -1 || wxorgid == 0) {
throw new Exception("同步微信端出错"); // rtnJson.put("errorNo", 1);
} else { // throw new Exception("同步微信端出错");
orgUnit.setWxorgId("" + wxorgid); // } else {
} // orgUnit.setWxorgId("" + wxorgid);
// }
orgUnit.setParentIds(orgUnit.getParentIds() + orgUnit.getId() + ","); orgUnit.setParentIds(orgUnit.getParentIds() + orgUnit.getId() + ",");
orgUnitService.updateCache(orgUnit); orgUnitService.updateCache(orgUnit);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment