|
|
@@ -2,30 +2,30 @@
|
|
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
|
|
<mapper namespace="com.usoftchina.saas.money.mapper.OthreceiptsMapper" >
|
|
|
<resultMap id="BaseResultMap" type="com.usoftchina.saas.money.po.Othreceipts" >
|
|
|
- <id column="or_id" property="orId" jdbcType="INTEGER" />
|
|
|
- <result column="or_code" property="orCode" jdbcType="VARCHAR" />
|
|
|
- <result column="or_date" property="orDate" jdbcType="TIMESTAMP" />
|
|
|
- <result column="or_custid" property="orCustid" jdbcType="INTEGER" />
|
|
|
- <result column="or_custcode" property="orCustcode" jdbcType="VARCHAR" />
|
|
|
- <result column="or_custname" property="orCustname" jdbcType="VARCHAR" />
|
|
|
- <result column="or_bankcode" property="orBankcode" jdbcType="VARCHAR" />
|
|
|
- <result column="or_bankid" property="orBankid" jdbcType="INTEGER" />
|
|
|
- <result column="or_bankname" property="orBankname" jdbcType="VARCHAR" />
|
|
|
- <result column="or_amount" property="orAmount" jdbcType="DOUBLE" />
|
|
|
- <result column="or_recorderid" property="orRecorderid" jdbcType="INTEGER" />
|
|
|
- <result column="or_recorder" property="orRecorder" jdbcType="VARCHAR" />
|
|
|
- <result column="or_recorddate" property="orRecorddate" jdbcType="TIMESTAMP" />
|
|
|
- <result column="or_status" property="orStatus" jdbcType="VARCHAR" />
|
|
|
- <result column="or_statuscode" property="orStatuscode" jdbcType="VARCHAR" />
|
|
|
- <result column="or_remark" property="orRemark" jdbcType="VARCHAR" />
|
|
|
- <result column="companyId" property="companyid" jdbcType="INTEGER" />
|
|
|
- <result column="updaterId" property="updaterid" jdbcType="INTEGER" />
|
|
|
+ <id column="or_id" property="id" jdbcType="INTEGER" />
|
|
|
+ <result column="or_code" property="or_code" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_date" property="or_date" jdbcType="TIMESTAMP" />
|
|
|
+ <result column="or_custid" property="or_custid" jdbcType="INTEGER" />
|
|
|
+ <result column="or_custcode" property="or_custcode" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_custname" property="or_custname" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_bankcode" property="or_bankcode" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_bankid" property="or_bankid" jdbcType="INTEGER" />
|
|
|
+ <result column="or_bankname" property="or_bankname" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_amount" property="or_amount" jdbcType="DOUBLE" />
|
|
|
+ <result column="or_recorderid" property="or_recorderid" jdbcType="INTEGER" />
|
|
|
+ <result column="or_recorder" property="or_recorder" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_recorddate" property="or_recorddate" jdbcType="TIMESTAMP" />
|
|
|
+ <result column="or_status" property="or_status" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_statuscode" property="or_statuscode" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_remark" property="or_remark" jdbcType="VARCHAR" />
|
|
|
+ <result column="companyId" property="companyId" jdbcType="INTEGER" />
|
|
|
+ <result column="updaterId" property="updaterId" jdbcType="INTEGER" />
|
|
|
<result column="updatedate" property="updatedate" jdbcType="TIMESTAMP" />
|
|
|
- <result column="or_text1" property="orText1" jdbcType="VARCHAR" />
|
|
|
- <result column="or_text2" property="orText2" jdbcType="VARCHAR" />
|
|
|
- <result column="or_text3" property="orText3" jdbcType="VARCHAR" />
|
|
|
- <result column="or_text4" property="orText4" jdbcType="VARCHAR" />
|
|
|
- <result column="or_text5" property="orText5" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_text1" property="or_text1" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_text2" property="or_text2" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_text3" property="or_text3" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_text4" property="or_text4" jdbcType="VARCHAR" />
|
|
|
+ <result column="or_text5" property="or_text5" jdbcType="VARCHAR" />
|
|
|
</resultMap>
|
|
|
<sql id="Base_Column_List" >
|
|
|
or_id, or_code, or_date, or_custid, or_custcode, or_custname, or_bankcode, or_bankid,
|
|
|
@@ -37,7 +37,7 @@
|
|
|
select
|
|
|
<include refid="Base_Column_List" />
|
|
|
from othreceipts
|
|
|
- where or_id = #{orId,jdbcType=INTEGER}
|
|
|
+ where or_id = #{id,jdbcType=INTEGER}
|
|
|
</select>
|
|
|
|
|
|
<select id="selectList" resultMap="BaseResultMap">
|
|
|
@@ -48,7 +48,7 @@
|
|
|
|
|
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
|
|
|
delete from othreceipts
|
|
|
- where or_id = #{orId,jdbcType=INTEGER}
|
|
|
+ where or_id = #{id,jdbcType=INTEGER}
|
|
|
</delete>
|
|
|
<insert id="insert" parameterType="com.usoftchina.saas.money.po.Othreceipts" >
|
|
|
insert into othreceipts (or_id, or_code, or_date,
|
|
|
@@ -65,7 +65,7 @@
|
|
|
#{orBankcode,jdbcType=VARCHAR}, #{orBankid,jdbcType=INTEGER}, #{orBankname,jdbcType=VARCHAR},
|
|
|
#{orAmount,jdbcType=DOUBLE}, #{orRecorderid,jdbcType=INTEGER}, #{orRecorder,jdbcType=VARCHAR},
|
|
|
#{orRecorddate,jdbcType=TIMESTAMP}, #{orStatus,jdbcType=INTEGER}, #{orStatuscode,jdbcType=DECIMAL},
|
|
|
- #{orRemark,jdbcType=VARCHAR}, #{companyid,jdbcType=INTEGER}, #{updaterid,jdbcType=INTEGER},
|
|
|
+ #{orRemark,jdbcType=VARCHAR}, #{companyId,jdbcType=INTEGER}, #{updaterid,jdbcType=INTEGER},
|
|
|
#{updatedate,jdbcType=TIMESTAMP}, #{orText1,jdbcType=VARCHAR}, #{orText2,jdbcType=VARCHAR},
|
|
|
#{orText3,jdbcType=VARCHAR}, #{orText4,jdbcType=VARCHAR}, #{orText5,jdbcType=VARCHAR}
|
|
|
)
|
|
|
@@ -73,228 +73,225 @@
|
|
|
<insert id="insertSelective" parameterType="com.usoftchina.saas.money.po.Othreceipts" >
|
|
|
insert into othreceipts
|
|
|
<trim prefix="(" suffix=")" suffixOverrides="," >
|
|
|
- <if test="orId != null" >
|
|
|
- or_id,
|
|
|
- </if>
|
|
|
- <if test="orCode != null" >
|
|
|
+ <if test="or_code != null" >
|
|
|
or_code,
|
|
|
</if>
|
|
|
- <if test="orDate != null" >
|
|
|
+ <if test="or_date != null" >
|
|
|
or_date,
|
|
|
</if>
|
|
|
- <if test="orCustid != null" >
|
|
|
+ <if test="or_custid != null" >
|
|
|
or_custid,
|
|
|
</if>
|
|
|
- <if test="orCustcode != null" >
|
|
|
+ <if test="or_custcode != null" >
|
|
|
or_custcode,
|
|
|
</if>
|
|
|
- <if test="orCustname != null" >
|
|
|
+ <if test="or_custname != null" >
|
|
|
or_custname,
|
|
|
</if>
|
|
|
- <if test="orBankcode != null" >
|
|
|
+ <if test="or_bankcode != null" >
|
|
|
or_bankcode,
|
|
|
</if>
|
|
|
- <if test="orBankid != null" >
|
|
|
+ <if test="or_bankid != null" >
|
|
|
or_bankid,
|
|
|
</if>
|
|
|
- <if test="orBankname != null" >
|
|
|
+ <if test="or_bankname != null" >
|
|
|
or_bankname,
|
|
|
</if>
|
|
|
- <if test="orAmount != null" >
|
|
|
+ <if test="or_amount != null" >
|
|
|
or_amount,
|
|
|
</if>
|
|
|
- <if test="orRecorderid != null" >
|
|
|
+ <if test="or_recorderid != null" >
|
|
|
or_recorderid,
|
|
|
</if>
|
|
|
- <if test="orRecorder != null" >
|
|
|
+ <if test="or_recorder != null" >
|
|
|
or_recorder,
|
|
|
</if>
|
|
|
- <if test="orRecorddate != null" >
|
|
|
+ <if test="or_recorddate != null" >
|
|
|
or_recorddate,
|
|
|
</if>
|
|
|
- <if test="orStatus != null" >
|
|
|
+ <if test="or_status != null" >
|
|
|
or_status,
|
|
|
</if>
|
|
|
- <if test="orStatuscode != null" >
|
|
|
+ <if test="or_statuscode != null" >
|
|
|
or_statuscode,
|
|
|
</if>
|
|
|
- <if test="orRemark != null" >
|
|
|
+ <if test="or_remark != null" >
|
|
|
or_remark,
|
|
|
</if>
|
|
|
- <if test="companyid != null" >
|
|
|
+ <if test="companyId != null" >
|
|
|
companyId,
|
|
|
</if>
|
|
|
- <if test="updaterid != null" >
|
|
|
+ <if test="updaterId != null" >
|
|
|
updaterId,
|
|
|
</if>
|
|
|
<if test="updatedate != null" >
|
|
|
updatedate,
|
|
|
</if>
|
|
|
- <if test="orText1 != null" >
|
|
|
+ <if test="or_text1 != null" >
|
|
|
or_text1,
|
|
|
</if>
|
|
|
- <if test="orText2 != null" >
|
|
|
+ <if test="or_text2 != null" >
|
|
|
or_text2,
|
|
|
</if>
|
|
|
- <if test="orText3 != null" >
|
|
|
+ <if test="or_text3 != null" >
|
|
|
or_text3,
|
|
|
</if>
|
|
|
- <if test="orText4 != null" >
|
|
|
+ <if test="or_text4 != null" >
|
|
|
or_text4,
|
|
|
</if>
|
|
|
- <if test="orText5 != null" >
|
|
|
+ <if test="or_text5 != null" >
|
|
|
or_text5,
|
|
|
</if>
|
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides="," >
|
|
|
- <if test="orId != null" >
|
|
|
- #{orId,jdbcType=INTEGER},
|
|
|
+ <if test="or_code != null" >
|
|
|
+ #{or_code,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orCode != null" >
|
|
|
- #{orCode,jdbcType=VARCHAR},
|
|
|
+ <if test="or_date != null" >
|
|
|
+ #{or_date,jdbcType=TIMESTAMP},
|
|
|
</if>
|
|
|
- <if test="orDate != null" >
|
|
|
- #{orDate,jdbcType=TIMESTAMP},
|
|
|
+ <if test="or_custid != null" >
|
|
|
+ #{or_custid,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="orCustid != null" >
|
|
|
- #{orCustid,jdbcType=INTEGER},
|
|
|
+ <if test="or_custcode != null" >
|
|
|
+ #{or_custcode,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orCustcode != null" >
|
|
|
- #{orCustcode,jdbcType=VARCHAR},
|
|
|
+ <if test="or_custname != null" >
|
|
|
+ #{or_custname,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orCustname != null" >
|
|
|
- #{orCustname,jdbcType=VARCHAR},
|
|
|
+ <if test="or_bankcode != null" >
|
|
|
+ #{or_bankcode,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orBankcode != null" >
|
|
|
- #{orBankcode,jdbcType=VARCHAR},
|
|
|
+ <if test="or_bankid != null" >
|
|
|
+ #{or_bankid,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="orBankid != null" >
|
|
|
- #{orBankid,jdbcType=INTEGER},
|
|
|
+ <if test="or_bankname != null" >
|
|
|
+ #{or_bankname,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orBankname != null" >
|
|
|
- #{orBankname,jdbcType=VARCHAR},
|
|
|
+ <if test="or_amount != null" >
|
|
|
+ #{or_amount,jdbcType=DOUBLE},
|
|
|
</if>
|
|
|
- <if test="orAmount != null" >
|
|
|
- #{orAmount,jdbcType=DOUBLE},
|
|
|
+ <if test="or_recorderid != null" >
|
|
|
+ #{or_recorderid,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="orRecorderid != null" >
|
|
|
- #{orRecorderid,jdbcType=INTEGER},
|
|
|
+ <if test="or_recorder != null" >
|
|
|
+ #{or_recorder,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orRecorder != null" >
|
|
|
- #{orRecorder,jdbcType=VARCHAR},
|
|
|
+ <if test="or_recorddate != null" >
|
|
|
+ #{or_recorddate,jdbcType=TIMESTAMP},
|
|
|
</if>
|
|
|
- <if test="orRecorddate != null" >
|
|
|
- #{orRecorddate,jdbcType=TIMESTAMP},
|
|
|
+ <if test="or_status != null" >
|
|
|
+ #{or_status,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orStatus != null" >
|
|
|
- #{orStatus,jdbcType=INTEGER},
|
|
|
+ <if test="or_statuscode != null" >
|
|
|
+ #{or_statuscode,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orStatuscode != null" >
|
|
|
- #{orStatuscode,jdbcType=DECIMAL},
|
|
|
+ <if test="or_remark != null" >
|
|
|
+ #{or_remark,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orRemark != null" >
|
|
|
- #{orRemark,jdbcType=VARCHAR},
|
|
|
+ <if test="companyId != null" >
|
|
|
+ #{companyId,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="companyid != null" >
|
|
|
- #{companyid,jdbcType=INTEGER},
|
|
|
- </if>
|
|
|
- <if test="updaterid != null" >
|
|
|
- #{updaterid,jdbcType=INTEGER},
|
|
|
+ <if test="updaterId != null" >
|
|
|
+ #{updaterId,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
<if test="updatedate != null" >
|
|
|
#{updatedate,jdbcType=TIMESTAMP},
|
|
|
</if>
|
|
|
- <if test="orText1 != null" >
|
|
|
- #{orText1,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text1 != null" >
|
|
|
+ #{or_text1,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText2 != null" >
|
|
|
- #{orText2,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text2 != null" >
|
|
|
+ #{or_text2,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText3 != null" >
|
|
|
- #{orText3,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text3 != null" >
|
|
|
+ #{or_text3,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText4 != null" >
|
|
|
- #{orText4,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text4 != null" >
|
|
|
+ #{or_text4,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText5 != null" >
|
|
|
- #{orText5,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text5 != null" >
|
|
|
+ #{or_text5,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
</trim>
|
|
|
+ <selectKey resultType="Long" keyProperty="id" order="AFTER">
|
|
|
+ SELECT LAST_INSERT_ID()
|
|
|
+ </selectKey>
|
|
|
</insert>
|
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.usoftchina.saas.money.po.Othreceipts" >
|
|
|
update othreceipts
|
|
|
<set >
|
|
|
- <if test="orCode != null" >
|
|
|
- or_code = #{orCode,jdbcType=VARCHAR},
|
|
|
+ <if test="or_code != null" >
|
|
|
+ or_code = #{or_code,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orDate != null" >
|
|
|
- or_date = #{orDate,jdbcType=TIMESTAMP},
|
|
|
+ <if test="or_date != null" >
|
|
|
+ or_date = #{or_date,jdbcType=TIMESTAMP},
|
|
|
</if>
|
|
|
- <if test="orCustid != null" >
|
|
|
- or_custid = #{orCustid,jdbcType=INTEGER},
|
|
|
+ <if test="or_custid != null" >
|
|
|
+ or_custid = #{or_custid,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="orCustcode != null" >
|
|
|
- or_custcode = #{orCustcode,jdbcType=VARCHAR},
|
|
|
+ <if test="or_custcode != null" >
|
|
|
+ or_custcode = #{or_custcode,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orCustname != null" >
|
|
|
- or_custname = #{orCustname,jdbcType=VARCHAR},
|
|
|
+ <if test="or_custname != null" >
|
|
|
+ or_custname = #{or_custname,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orBankcode != null" >
|
|
|
- or_bankcode = #{orBankcode,jdbcType=VARCHAR},
|
|
|
+ <if test="or_bankcode != null" >
|
|
|
+ or_bankcode = #{or_bankcode,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orBankid != null" >
|
|
|
- or_bankid = #{orBankid,jdbcType=INTEGER},
|
|
|
+ <if test="or_bankid != null" >
|
|
|
+ or_bankid = #{or_bankid,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="orBankname != null" >
|
|
|
- or_bankname = #{orBankname,jdbcType=VARCHAR},
|
|
|
+ <if test="or_bankname != null" >
|
|
|
+ or_bankname = #{or_bankname,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orAmount != null" >
|
|
|
- or_amount = #{orAmount,jdbcType=DOUBLE},
|
|
|
+ <if test="or_amount != null" >
|
|
|
+ or_amount = #{or_amount,jdbcType=DOUBLE},
|
|
|
</if>
|
|
|
- <if test="orRecorderid != null" >
|
|
|
- or_recorderid = #{orRecorderid,jdbcType=INTEGER},
|
|
|
+ <if test="or_recorderid != null" >
|
|
|
+ or_recorderid = #{or_recorderid,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="orRecorder != null" >
|
|
|
- or_recorder = #{orRecorder,jdbcType=VARCHAR},
|
|
|
+ <if test="or_recorder != null" >
|
|
|
+ or_recorder = #{or_recorder,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orRecorddate != null" >
|
|
|
- or_recorddate = #{orRecorddate,jdbcType=TIMESTAMP},
|
|
|
+ <if test="or_recorddate != null" >
|
|
|
+ or_recorddate = #{or_recorddate,jdbcType=TIMESTAMP},
|
|
|
</if>
|
|
|
- <if test="orStatus != null" >
|
|
|
- or_status = #{orStatus,jdbcType=INTEGER},
|
|
|
+ <if test="or_status != null" >
|
|
|
+ or_status = #{or_status,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orStatuscode != null" >
|
|
|
- or_statuscode = #{orStatuscode,jdbcType=DECIMAL},
|
|
|
+ <if test="or_statuscode != null" >
|
|
|
+ or_statuscode = #{or_statuscode,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orRemark != null" >
|
|
|
- or_remark = #{orRemark,jdbcType=VARCHAR},
|
|
|
+ <if test="or_remark != null" >
|
|
|
+ or_remark = #{or_remark,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="companyid != null" >
|
|
|
- companyId = #{companyid,jdbcType=INTEGER},
|
|
|
+ <if test="companyId != null" >
|
|
|
+ companyId = #{companyId,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
- <if test="updaterid != null" >
|
|
|
- updaterId = #{updaterid,jdbcType=INTEGER},
|
|
|
+ <if test="updaterId != null" >
|
|
|
+ updaterId = #{updaterId,jdbcType=INTEGER},
|
|
|
</if>
|
|
|
<if test="updatedate != null" >
|
|
|
updatedate = #{updatedate,jdbcType=TIMESTAMP},
|
|
|
</if>
|
|
|
- <if test="orText1 != null" >
|
|
|
- or_text1 = #{orText1,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text1 != null" >
|
|
|
+ or_text1 = #{or_text1,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText2 != null" >
|
|
|
- or_text2 = #{orText2,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text2 != null" >
|
|
|
+ or_text2 = #{or_text2,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText3 != null" >
|
|
|
- or_text3 = #{orText3,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text3 != null" >
|
|
|
+ or_text3 = #{or_text3,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText4 != null" >
|
|
|
- or_text4 = #{orText4,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text4 != null" >
|
|
|
+ or_text4 = #{or_text4,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
- <if test="orText5 != null" >
|
|
|
- or_text5 = #{orText5,jdbcType=VARCHAR},
|
|
|
+ <if test="or_text5 != null" >
|
|
|
+ or_text5 = #{or_text5,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
</set>
|
|
|
- where or_id = #{orId,jdbcType=INTEGER}
|
|
|
+ where or_id = #{id,jdbcType=INTEGER}
|
|
|
</update>
|
|
|
<update id="updateByPrimaryKey" parameterType="com.usoftchina.saas.money.po.Othreceipts" >
|
|
|
update othreceipts
|
|
|
@@ -313,7 +310,7 @@
|
|
|
or_status = #{orStatus,jdbcType=INTEGER},
|
|
|
or_statuscode = #{orStatuscode,jdbcType=DECIMAL},
|
|
|
or_remark = #{orRemark,jdbcType=VARCHAR},
|
|
|
- companyId = #{companyid,jdbcType=INTEGER},
|
|
|
+ companyId = #{companyId,jdbcType=INTEGER},
|
|
|
updaterId = #{updaterid,jdbcType=INTEGER},
|
|
|
updatedate = #{updatedate,jdbcType=TIMESTAMP},
|
|
|
or_text1 = #{orText1,jdbcType=VARCHAR},
|
|
|
@@ -323,4 +320,40 @@
|
|
|
or_text5 = #{orText5,jdbcType=VARCHAR}
|
|
|
where or_id = #{orId,jdbcType=INTEGER}
|
|
|
</update>
|
|
|
+
|
|
|
+ <select id="validateCodeWhenInsert" resultType="int">
|
|
|
+ select count(1) from othreceipts where or_code = #{code} and companyId =#{companyId}
|
|
|
+ </select>
|
|
|
+ <select id="validateCodeWhenUpdate" resultType="int" >
|
|
|
+ select count(1) from othreceipts where or_code = #{code} and or_id != #{id} and companyId =#{companyId}
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="selectOthreceiptsBycondition" resultMap="BaseResultMap">
|
|
|
+ select
|
|
|
+ <include refid="Base_Column_List" />
|
|
|
+ from Othreceipts
|
|
|
+ <where>
|
|
|
+ <if test="con != null">
|
|
|
+ ${con}
|
|
|
+ </if>
|
|
|
+ <if test="companyId != null">
|
|
|
+ and othreceipts.companyId = #{companyId}
|
|
|
+ </if>
|
|
|
+ </where> order by or_id
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="selectOthreceiptsListByCondition" resultMap="BaseResultMap">
|
|
|
+ select
|
|
|
+ <include refid="Base_Column_List" />
|
|
|
+ from Othreceipts
|
|
|
+ left join othreceiptsdetail on or_id=ord_orid
|
|
|
+ <where>
|
|
|
+ <if test="con != null">
|
|
|
+ ${con}
|
|
|
+ </if>
|
|
|
+ <if test="companyId != null">
|
|
|
+ and othreceipts.companyId = #{companyId}
|
|
|
+ </if>
|
|
|
+ </where> order by or_id
|
|
|
+ </select>
|
|
|
</mapper>
|