1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
<?xml version="1.0" encoding="UTF-8"?>
<!--
~
~ Copyright (c) 2018-2025, lengleng All rights reserved.
~
~ Redistribution and use in source and binary forms, with or without
~ modification, are permitted provided that the following conditions are met:
~
~ Redistributions of source code must retain the above copyright notice,
~ this list of conditions and the following disclaimer.
~ Redistributions in binary form must reproduce the above copyright
~ notice, this list of conditions and the following disclaimer in the
~ documentation and/or other materials provided with the distribution.
~ Neither the name of the yifu4cloud.com developer nor the names of its
~ contributors may be used to endorse or promote products derived from
~ this software without specific prior written permission.
~ Author: lengleng (wangiegie@gmail.com)
~
-->
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yifu.cloud.plus.v1.yifu.salary.mapper.TStatisticsTaxDeclarerMapper">
<resultMap id="tStatisticsTaxDeclarerMap" type="com.yifu.cloud.plus.v1.yifu.salary.entity.TStatisticsTaxDeclarer">
<id property="id" column="id"/>
<result property="invoiceTitle" column="INVOICE_TITLE"/>
<result property="settleDepartId" column="SETTLE_DEPART_ID"/>
<result property="settleDepartNo" column="SETTLE_DEPART_NO"/>
<result property="settleDepartName" column="SETTLE_DEPART_NAME"/>
<result property="declareMonth" column="DECLARE_MONTH"/>
<result property="empId" column="EMP_ID"/>
<result property="empName" column="EMP_NAME"/>
<result property="empIdcard" column="EMP_IDCARD"/>
<result property="phone" column="PHONE"/>
<result property="userStatus" column="user_status"/>
<result property="userType" column="user_type"/>
<result property="taxMonth" column="tax_month"/>
<result property="unitId" column="UNIT_ID"/>
<result property="unitNo" column="UNIT_NO"/>
<result property="unitName" column="UNIT_NAME"/>
<result property="salaryTax" column="salary_tax"/>
<result property="specialDeduMoney" column="special_dedu_money"/>
</resultMap>
<sql id="Base_Column_List">
a.id,
a.INVOICE_TITLE,
a.SETTLE_DEPART_ID,
a.SETTLE_DEPART_NO,
a.SETTLE_DEPART_NAME,
a.DECLARE_MONTH,
a.EMP_ID,
a.EMP_NAME,
a.EMP_IDCARD,
a.PHONE,
a.user_status,
a.user_type,
a.tax_month,
a.UNIT_ID,
a.UNIT_NO,
a.UNIT_NAME,
a.salary_tax,
a.special_dedu_money
</sql>
<sql id="tStatisticsTaxDeclarer_where">
<if test="tStatisticsTaxDeclarer != null">
<if test="tStatisticsTaxDeclarer.id != null and tStatisticsTaxDeclarer.id.trim() != ''">
AND a.id = #{tStatisticsTaxDeclarer.id}
</if>
<if test="tStatisticsTaxDeclarer.invoiceTitle != null and tStatisticsTaxDeclarer.invoiceTitle.trim() != ''">
AND a.INVOICE_TITLE = #{tStatisticsTaxDeclarer.invoiceTitle}
</if>
<if test="tStatisticsTaxDeclarer.settleDepartId != null and tStatisticsTaxDeclarer.settleDepartId.trim() != ''">
AND a.SETTLE_DEPART_ID = #{tStatisticsTaxDeclarer.settleDepartId}
</if>
<if test="tStatisticsTaxDeclarer.settleDepartNo != null and tStatisticsTaxDeclarer.settleDepartNo.trim() != ''">
AND a.SETTLE_DEPART_NO = #{tStatisticsTaxDeclarer.settleDepartNo}
</if>
<if test="tStatisticsTaxDeclarer.settleDepartName != null and tStatisticsTaxDeclarer.settleDepartName.trim() != ''">
AND a.SETTLE_DEPART_NAME = #{tStatisticsTaxDeclarer.settleDepartName}
</if>
<if test="tStatisticsTaxDeclarer.declareMonth != null and tStatisticsTaxDeclarer.declareMonth.trim() != ''">
AND a.DECLARE_MONTH = #{tStatisticsTaxDeclarer.declareMonth}
</if>
<if test="tStatisticsTaxDeclarer.empId != null and tStatisticsTaxDeclarer.empId.trim() != ''">
AND a.EMP_ID = #{tStatisticsTaxDeclarer.empId}
</if>
<if test="tStatisticsTaxDeclarer.empName != null and tStatisticsTaxDeclarer.empName.trim() != ''">
AND a.EMP_NAME = #{tStatisticsTaxDeclarer.empName}
</if>
<if test="tStatisticsTaxDeclarer.empIdcard != null and tStatisticsTaxDeclarer.empIdcard.trim() != ''">
AND a.EMP_IDCARD = #{tStatisticsTaxDeclarer.empIdcard}
</if>
<if test="tStatisticsTaxDeclarer.phone != null and tStatisticsTaxDeclarer.phone.trim() != ''">
AND a.PHONE = #{tStatisticsTaxDeclarer.phone}
</if>
<if test="tStatisticsTaxDeclarer.userStatus != null and tStatisticsTaxDeclarer.userStatus.trim() != ''">
AND a.user_status = #{tStatisticsTaxDeclarer.userStatus}
</if>
<if test="tStatisticsTaxDeclarer.userType != null and tStatisticsTaxDeclarer.userType.trim() != ''">
AND a.user_type = #{tStatisticsTaxDeclarer.userType}
</if>
<if test="tStatisticsTaxDeclarer.taxMonth != null and tStatisticsTaxDeclarer.taxMonth.trim() != ''">
AND a.tax_month = #{tStatisticsTaxDeclarer.taxMonth}
</if>
<if test="tStatisticsTaxDeclarer.unitId != null and tStatisticsTaxDeclarer.unitId.trim() != ''">
AND a.UNIT_ID = #{tStatisticsTaxDeclarer.unitId}
</if>
<if test="tStatisticsTaxDeclarer.unitNo != null and tStatisticsTaxDeclarer.unitNo.trim() != ''">
AND a.UNIT_NO = #{tStatisticsTaxDeclarer.unitNo}
</if>
<if test="tStatisticsTaxDeclarer.unitName != null and tStatisticsTaxDeclarer.unitName.trim() != ''">
AND a.UNIT_NAME = #{tStatisticsTaxDeclarer.unitName}
</if>
<if test="tStatisticsTaxDeclarer.salaryTax != null">
AND a.salary_tax = #{tStatisticsTaxDeclarer.salaryTax}
</if>
<if test="tStatisticsTaxDeclarer.specialDeduMoney != null">
AND a.special_dedu_money = #{tStatisticsTaxDeclarer.specialDeduMoney}
</if>
</if>
</sql>
<!--tStatisticsTaxDeclarer简单分页查询-->
<select id="getTStatisticsTaxDeclarerPage" resultMap="tStatisticsTaxDeclarerMap">
SELECT
<include refid="Base_Column_List"/>
FROM t_statistics_tax_declarer a
<where>
1=1
<include refid="tStatisticsTaxDeclarer_where"/>
</where>
</select>
</mapper>