Skip to content

Commit

Permalink
[UPDATE]v1.1重构首页 完善功能 修复BUG
Browse files Browse the repository at this point in the history
  • Loading branch information
Exrick committed Apr 19, 2018
1 parent 00bcf93 commit 504ffc9
Show file tree
Hide file tree
Showing 29 changed files with 8,883 additions and 201 deletions.
312 changes: 111 additions & 201 deletions .idea/workspace.xml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
package cn.exrick.manager.mapper;

import cn.exrick.manager.pojo.TbPanelContent;
import cn.exrick.manager.pojo.TbPanelContentExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface TbPanelContentMapper {
long countByExample(TbPanelContentExample example);

int deleteByExample(TbPanelContentExample example);

int deleteByPrimaryKey(Integer id);

int insert(TbPanelContent record);

int insertSelective(TbPanelContent record);

List<TbPanelContent> selectByExample(TbPanelContentExample example);

TbPanelContent selectByPrimaryKey(Integer id);

int updateByExampleSelective(@Param("record") TbPanelContent record, @Param("example") TbPanelContentExample example);

int updateByExample(@Param("record") TbPanelContent record, @Param("example") TbPanelContentExample example);

int updateByPrimaryKeySelective(TbPanelContent record);

int updateByPrimaryKey(TbPanelContent record);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,306 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "https://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.exrick.manager.mapper.TbPanelContentMapper">
<resultMap id="BaseResultMap" type="cn.exrick.manager.pojo.TbPanelContent">
<id column="id" jdbcType="INTEGER" property="id" />
<result column="panel_id" jdbcType="INTEGER" property="panelId" />
<result column="type" jdbcType="INTEGER" property="type" />
<result column="product_id" jdbcType="BIGINT" property="productId" />
<result column="sort_order" jdbcType="INTEGER" property="sortOrder" />
<result column="full_url" jdbcType="VARCHAR" property="fullUrl" />
<result column="pic_url" jdbcType="VARCHAR" property="picUrl" />
<result column="pic_url2" jdbcType="VARCHAR" property="picUrl2" />
<result column="pic_url3" jdbcType="VARCHAR" property="picUrl3" />
<result column="created" jdbcType="TIMESTAMP" property="created" />
<result column="updated" jdbcType="TIMESTAMP" property="updated" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, panel_id, type, product_id, sort_order, full_url, pic_url, pic_url2, pic_url3,
created, updated
</sql>
<select id="selectByExample" parameterType="cn.exrick.manager.pojo.TbPanelContentExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from tb_panel_content
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_panel_content
where id = #{id,jdbcType=INTEGER}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
delete from tb_panel_content
where id = #{id,jdbcType=INTEGER}
</delete>
<delete id="deleteByExample" parameterType="cn.exrick.manager.pojo.TbPanelContentExample">
delete from tb_panel_content
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="cn.exrick.manager.pojo.TbPanelContent">
insert into tb_panel_content (id, panel_id, type,
product_id, sort_order, full_url,
pic_url, pic_url2, pic_url3,
created, updated)
values (#{id,jdbcType=INTEGER}, #{panelId,jdbcType=INTEGER}, #{type,jdbcType=INTEGER},
#{productId,jdbcType=BIGINT}, #{sortOrder,jdbcType=INTEGER}, #{fullUrl,jdbcType=VARCHAR},
#{picUrl,jdbcType=VARCHAR}, #{picUrl2,jdbcType=VARCHAR}, #{picUrl3,jdbcType=VARCHAR},
#{created,jdbcType=TIMESTAMP}, #{updated,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="cn.exrick.manager.pojo.TbPanelContent">
insert into tb_panel_content
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="panelId != null">
panel_id,
</if>
<if test="type != null">
type,
</if>
<if test="productId != null">
product_id,
</if>
<if test="sortOrder != null">
sort_order,
</if>
<if test="fullUrl != null">
full_url,
</if>
<if test="picUrl != null">
pic_url,
</if>
<if test="picUrl2 != null">
pic_url2,
</if>
<if test="picUrl3 != null">
pic_url3,
</if>
<if test="created != null">
created,
</if>
<if test="updated != null">
updated,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=INTEGER},
</if>
<if test="panelId != null">
#{panelId,jdbcType=INTEGER},
</if>
<if test="type != null">
#{type,jdbcType=INTEGER},
</if>
<if test="productId != null">
#{productId,jdbcType=BIGINT},
</if>
<if test="sortOrder != null">
#{sortOrder,jdbcType=INTEGER},
</if>
<if test="fullUrl != null">
#{fullUrl,jdbcType=VARCHAR},
</if>
<if test="picUrl != null">
#{picUrl,jdbcType=VARCHAR},
</if>
<if test="picUrl2 != null">
#{picUrl2,jdbcType=VARCHAR},
</if>
<if test="picUrl3 != null">
#{picUrl3,jdbcType=VARCHAR},
</if>
<if test="created != null">
#{created,jdbcType=TIMESTAMP},
</if>
<if test="updated != null">
#{updated,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="cn.exrick.manager.pojo.TbPanelContentExample" resultType="java.lang.Long">
select count(*) from tb_panel_content
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update tb_panel_content
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=INTEGER},
</if>
<if test="record.panelId != null">
panel_id = #{record.panelId,jdbcType=INTEGER},
</if>
<if test="record.type != null">
type = #{record.type,jdbcType=INTEGER},
</if>
<if test="record.productId != null">
product_id = #{record.productId,jdbcType=BIGINT},
</if>
<if test="record.sortOrder != null">
sort_order = #{record.sortOrder,jdbcType=INTEGER},
</if>
<if test="record.fullUrl != null">
full_url = #{record.fullUrl,jdbcType=VARCHAR},
</if>
<if test="record.picUrl != null">
pic_url = #{record.picUrl,jdbcType=VARCHAR},
</if>
<if test="record.picUrl2 != null">
pic_url2 = #{record.picUrl2,jdbcType=VARCHAR},
</if>
<if test="record.picUrl3 != null">
pic_url3 = #{record.picUrl3,jdbcType=VARCHAR},
</if>
<if test="record.created != null">
created = #{record.created,jdbcType=TIMESTAMP},
</if>
<if test="record.updated != null">
updated = #{record.updated,jdbcType=TIMESTAMP},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update tb_panel_content
set id = #{record.id,jdbcType=INTEGER},
panel_id = #{record.panelId,jdbcType=INTEGER},
type = #{record.type,jdbcType=INTEGER},
product_id = #{record.productId,jdbcType=BIGINT},
sort_order = #{record.sortOrder,jdbcType=INTEGER},
full_url = #{record.fullUrl,jdbcType=VARCHAR},
pic_url = #{record.picUrl,jdbcType=VARCHAR},
pic_url2 = #{record.picUrl2,jdbcType=VARCHAR},
pic_url3 = #{record.picUrl3,jdbcType=VARCHAR},
created = #{record.created,jdbcType=TIMESTAMP},
updated = #{record.updated,jdbcType=TIMESTAMP}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="cn.exrick.manager.pojo.TbPanelContent">
update tb_panel_content
<set>
<if test="panelId != null">
panel_id = #{panelId,jdbcType=INTEGER},
</if>
<if test="type != null">
type = #{type,jdbcType=INTEGER},
</if>
<if test="productId != null">
product_id = #{productId,jdbcType=BIGINT},
</if>
<if test="sortOrder != null">
sort_order = #{sortOrder,jdbcType=INTEGER},
</if>
<if test="fullUrl != null">
full_url = #{fullUrl,jdbcType=VARCHAR},
</if>
<if test="picUrl != null">
pic_url = #{picUrl,jdbcType=VARCHAR},
</if>
<if test="picUrl2 != null">
pic_url2 = #{picUrl2,jdbcType=VARCHAR},
</if>
<if test="picUrl3 != null">
pic_url3 = #{picUrl3,jdbcType=VARCHAR},
</if>
<if test="created != null">
created = #{created,jdbcType=TIMESTAMP},
</if>
<if test="updated != null">
updated = #{updated,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=INTEGER}
</update>
<update id="updateByPrimaryKey" parameterType="cn.exrick.manager.pojo.TbPanelContent">
update tb_panel_content
set panel_id = #{panelId,jdbcType=INTEGER},
type = #{type,jdbcType=INTEGER},
product_id = #{productId,jdbcType=BIGINT},
sort_order = #{sortOrder,jdbcType=INTEGER},
full_url = #{fullUrl,jdbcType=VARCHAR},
pic_url = #{picUrl,jdbcType=VARCHAR},
pic_url2 = #{picUrl2,jdbcType=VARCHAR},
pic_url3 = #{picUrl3,jdbcType=VARCHAR},
created = #{created,jdbcType=TIMESTAMP},
updated = #{updated,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=INTEGER}
</update>
</mapper>
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
package cn.exrick.manager.mapper;

import cn.exrick.manager.pojo.TbPanel;
import cn.exrick.manager.pojo.TbPanelExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface TbPanelMapper {
long countByExample(TbPanelExample example);

int deleteByExample(TbPanelExample example);

int deleteByPrimaryKey(Integer id);

int insert(TbPanel record);

int insertSelective(TbPanel record);

List<TbPanel> selectByExample(TbPanelExample example);

TbPanel selectByPrimaryKey(Integer id);

int updateByExampleSelective(@Param("record") TbPanel record, @Param("example") TbPanelExample example);

int updateByExample(@Param("record") TbPanel record, @Param("example") TbPanelExample example);

int updateByPrimaryKeySelective(TbPanel record);

int updateByPrimaryKey(TbPanel record);
}
Loading

0 comments on commit 504ffc9

Please sign in to comment.