Browse Source

新增标准文件

anderx 1 year ago
parent
commit
9ab6139147

+ 25 - 0
src/main/java/com/goafanti/common/dao/StandardDocumentMapper.java

@@ -0,0 +1,25 @@
+package com.goafanti.common.dao;
+
+import com.goafanti.common.model.StandardDocument;
+
+/**
+* @author Administrator
+* @description 针对表【standard_document(标准文档列表)】的数据库操作Mapper
+* @createDate 2024-05-08 16:49:27
+* @Entity com.goafanti.common.model.StandardDocument
+*/
+public interface StandardDocumentMapper {
+
+    int deleteByPrimaryKey(Long id);
+
+    int insert(StandardDocument record);
+
+    int insertSelective(StandardDocument record);
+
+    StandardDocument selectByPrimaryKey(Long id);
+
+    int updateByPrimaryKeySelective(StandardDocument record);
+
+    int updateByPrimaryKey(StandardDocument record);
+
+}

+ 123 - 0
src/main/java/com/goafanti/common/mapper/StandardDocumentMapper.xml

@@ -0,0 +1,123 @@
+<?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.goafanti.common.dao.StandardDocumentMapper">
+
+    <resultMap id="BaseResultMap" type="com.goafanti.common.model.StandardDocument">
+            <id property="id" column="id" jdbcType="INTEGER"/>
+            <result property="url" column="url" jdbcType="VARCHAR"/>
+            <result property="serialNumber" column="serial_number" jdbcType="VARCHAR"/>
+            <result property="name" column="name" jdbcType="VARCHAR"/>
+            <result property="reference" column="reference" jdbcType="VARCHAR"/>
+            <result property="depId" column="dep_id" jdbcType="VARCHAR"/>
+            <result property="aid" column="aid" jdbcType="VARCHAR"/>
+            <result property="status" column="status" jdbcType="INTEGER"/>
+            <result property="createTime" column="create_time" jdbcType="TIMESTAMP"/>
+            <result property="updateTime" column="update_time" jdbcType="TIMESTAMP"/>
+    </resultMap>
+
+    <sql id="Base_Column_List">
+        id,url,serial_number,
+        name,reference,dep_id,
+        aid,status,create_time,
+        update_time
+    </sql>
+
+    <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
+        select
+        <include refid="Base_Column_List" />
+        from standard_document
+        where  id = #{id,jdbcType=INTEGER} 
+    </select>
+
+    <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
+        delete from standard_document
+        where  id = #{id,jdbcType=INTEGER} 
+    </delete>
+    <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.StandardDocument" useGeneratedKeys="true">
+        insert into standard_document
+        ( id,url,serial_number
+        ,name,reference,dep_id
+        ,aid,status,create_time
+        ,update_time)
+        values (#{id,jdbcType=INTEGER},#{url,jdbcType=VARCHAR},#{serialNumber,jdbcType=VARCHAR}
+        ,#{name,jdbcType=VARCHAR},#{reference,jdbcType=VARCHAR},#{depId,jdbcType=VARCHAR}
+        ,#{aid,jdbcType=VARCHAR},#{status,jdbcType=INTEGER},#{createTime,jdbcType=TIMESTAMP}
+        ,#{updateTime,jdbcType=TIMESTAMP})
+    </insert>
+    <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.StandardDocument" useGeneratedKeys="true">
+        insert into standard_document
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+                <if test="id != null">id,</if>
+                <if test="url != null">url,</if>
+                <if test="serialNumber != null">serial_number,</if>
+                <if test="name != null">name,</if>
+                <if test="reference != null">reference,</if>
+                <if test="depId != null">dep_id,</if>
+                <if test="aid != null">aid,</if>
+                <if test="status != null">status,</if>
+                <if test="createTime != null">create_time,</if>
+                <if test="updateTime != null">update_time,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+                <if test="id != null">#{id,jdbcType=INTEGER},</if>
+                <if test="url != null">#{url,jdbcType=VARCHAR},</if>
+                <if test="serialNumber != null">#{serialNumber,jdbcType=VARCHAR},</if>
+                <if test="name != null">#{name,jdbcType=VARCHAR},</if>
+                <if test="reference != null">#{reference,jdbcType=VARCHAR},</if>
+                <if test="depId != null">#{depId,jdbcType=VARCHAR},</if>
+                <if test="aid != null">#{aid,jdbcType=VARCHAR},</if>
+                <if test="status != null">#{status,jdbcType=INTEGER},</if>
+                <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if>
+                <if test="updateTime != null">#{updateTime,jdbcType=TIMESTAMP},</if>
+        </trim>
+    </insert>
+    <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.StandardDocument">
+        update standard_document
+        <set>
+                <if test="url != null">
+                    url = #{url,jdbcType=VARCHAR},
+                </if>
+                <if test="serialNumber != null">
+                    serial_number = #{serialNumber,jdbcType=VARCHAR},
+                </if>
+                <if test="name != null">
+                    name = #{name,jdbcType=VARCHAR},
+                </if>
+                <if test="reference != null">
+                    reference = #{reference,jdbcType=VARCHAR},
+                </if>
+                <if test="depId != null">
+                    dep_id = #{depId,jdbcType=VARCHAR},
+                </if>
+                <if test="aid != null">
+                    aid = #{aid,jdbcType=VARCHAR},
+                </if>
+                <if test="status != null">
+                    status = #{status,jdbcType=INTEGER},
+                </if>
+                <if test="createTime != null">
+                    create_time = #{createTime,jdbcType=TIMESTAMP},
+                </if>
+                <if test="updateTime != null">
+                    update_time = #{updateTime,jdbcType=TIMESTAMP},
+                </if>
+        </set>
+        where   id = #{id,jdbcType=INTEGER} 
+    </update>
+    <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.StandardDocument">
+        update standard_document
+        set 
+            url =  #{url,jdbcType=VARCHAR},
+            serial_number =  #{serialNumber,jdbcType=VARCHAR},
+            name =  #{name,jdbcType=VARCHAR},
+            reference =  #{reference,jdbcType=VARCHAR},
+            dep_id =  #{depId,jdbcType=VARCHAR},
+            aid =  #{aid,jdbcType=VARCHAR},
+            status =  #{status,jdbcType=INTEGER},
+            create_time =  #{createTime,jdbcType=TIMESTAMP},
+            update_time =  #{updateTime,jdbcType=TIMESTAMP}
+        where   id = #{id,jdbcType=INTEGER} 
+    </update>
+</mapper>

+ 202 - 0
src/main/java/com/goafanti/common/model/StandardDocument.java

@@ -0,0 +1,202 @@
+package com.goafanti.common.model;
+
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * 标准文档列表
+ * @TableName standard_document
+ */
+public class StandardDocument implements Serializable {
+    /**
+     * 
+     */
+    private Integer id;
+
+    /**
+     * 附件
+     */
+    private String url;
+
+    /**
+     * 标准编号
+     */
+    private String serialNumber;
+
+    /**
+     * 标准名称
+     */
+    private String name;
+
+    /**
+     * 参考
+     */
+    private String reference;
+
+    /**
+     * 订单部门
+     */
+    private String depId;
+
+    /**
+     * 负责人
+     */
+    private String aid;
+
+    /**
+     * 状态 0=关闭,1=开启
+     */
+    private Integer status;
+
+    /**
+     * 发起时间
+     */
+    private Date createTime;
+
+    /**
+     * 修改时间
+     */
+    private Date updateTime;
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 
+     */
+    public Integer getId() {
+        return id;
+    }
+
+    /**
+     * 
+     */
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    /**
+     * 附件
+     */
+    public String getUrl() {
+        return url;
+    }
+
+    /**
+     * 附件
+     */
+    public void setUrl(String url) {
+        this.url = url;
+    }
+
+    /**
+     * 标准编号
+     */
+    public String getSerialNumber() {
+        return serialNumber;
+    }
+
+    /**
+     * 标准编号
+     */
+    public void setSerialNumber(String serialNumber) {
+        this.serialNumber = serialNumber;
+    }
+
+    /**
+     * 标准名称
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * 标准名称
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    /**
+     * 参考
+     */
+    public String getReference() {
+        return reference;
+    }
+
+    /**
+     * 参考
+     */
+    public void setReference(String reference) {
+        this.reference = reference;
+    }
+
+    /**
+     * 订单部门
+     */
+    public String getDepId() {
+        return depId;
+    }
+
+    /**
+     * 订单部门
+     */
+    public void setDepId(String depId) {
+        this.depId = depId;
+    }
+
+    /**
+     * 负责人
+     */
+    public String getAid() {
+        return aid;
+    }
+
+    /**
+     * 负责人
+     */
+    public void setAid(String aid) {
+        this.aid = aid;
+    }
+
+    /**
+     * 状态 0=关闭,1=开启
+     */
+    public Integer getStatus() {
+        return status;
+    }
+
+    /**
+     * 状态 0=关闭,1=开启
+     */
+    public void setStatus(Integer status) {
+        this.status = status;
+    }
+
+    /**
+     * 发起时间
+     */
+    public Date getCreateTime() {
+        return createTime;
+    }
+
+    /**
+     * 发起时间
+     */
+    public void setCreateTime(Date createTime) {
+        this.createTime = createTime;
+    }
+
+    /**
+     * 修改时间
+     */
+    public Date getUpdateTime() {
+        return updateTime;
+    }
+
+    /**
+     * 修改时间
+     */
+    public void setUpdateTime(Date updateTime) {
+        this.updateTime = updateTime;
+    }
+}

+ 5 - 5
src/main/resources/props/config_local.properties

@@ -4,13 +4,13 @@ jdbc.driverClassName=com.mysql.jdbc.Driver
 static.host=//static.jishutao.com/1.3.14
 #static.host=//172.16.1.187/1.3.14
 
-jdbc.url=jdbc\:mysql://localhost:3306/aft20240430?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
+#jdbc.url=jdbc\:mysql://localhost:3306/aft20240430?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
 #jdbc.url=jdbc\:mysql://localhost:3306/aft?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
-jdbc.username=root
-jdbc.password=123456
-#jdbc.url=jdbc:mysql://101.37.32.31:3306/aft?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
 #jdbc.username=root
-#jdbc.password=aftdev
+#jdbc.password=123456
+jdbc.url=jdbc:mysql://101.37.32.31:3306/aft?useUnicode=true&characterEncoding=UTF-8&autoReconnect=true&useSSL=false
+jdbc.username=root
+jdbc.password=aftdev
 jdbc.validationQuery=SELECT 'x'
 jdbc.initialSize=3
 jdbc.maxActive=20