Commit 25d05b5d authored by hongguangwu's avatar hongguangwu

优化时间等

parent 2209c6b3
...@@ -23,8 +23,10 @@ import com.baomidou.mybatisplus.annotation.TableField; ...@@ -23,8 +23,10 @@ import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute; import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.common.mybatis.base.BaseEntity;
import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data; import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length; import org.hibernate.validator.constraints.Length;
import javax.validation.constraints.NotBlank; import javax.validation.constraints.NotBlank;
...@@ -40,8 +42,9 @@ import java.util.List; ...@@ -40,8 +42,9 @@ import java.util.List;
*/ */
@Data @Data
@TableName("t_salary_account") @TableName("t_salary_account")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "工资报账主表(工资条)") @Schema(description = "工资报账主表(工资条)")
public class TSalaryAccount { public class TSalaryAccount extends BaseEntity {
/** /**
* 主键 * 主键
......
...@@ -67,6 +67,11 @@ ...@@ -67,6 +67,11 @@
<result property="salaryTaxUnit" column="SALARY_TAX_UNIT"/> <result property="salaryTaxUnit" column="SALARY_TAX_UNIT"/>
<result property="haveSalaryFlag" column="HAVE_SALARY_FLAG"/> <result property="haveSalaryFlag" column="HAVE_SALARY_FLAG"/>
<result property="haveSpecialFlag" column="HAVE_SPECIAL_FLAG"/> <result property="haveSpecialFlag" column="HAVE_SPECIAL_FLAG"/>
<result property="createBy" column="CREATE_BY"/>
<result property="createName" column="CREATE_NAME"/>
<result property="createTime" column="CREATE_TIME"/>
<result property="updateBy" column="UPDATE_BY"/>
<result property="updateTime" column="UPDATE_TIME"/>
</resultMap> </resultMap>
<sql id="Base_Column_List"> <sql id="Base_Column_List">
a.ID, a.ID,
...@@ -111,7 +116,12 @@ ...@@ -111,7 +116,12 @@
a.RELAY_SALARY_UNIT, a.RELAY_SALARY_UNIT,
a.SALARY_TAX_UNIT, a.SALARY_TAX_UNIT,
a.HAVE_SALARY_FLAG, a.HAVE_SALARY_FLAG,
a.HAVE_SPECIAL_FLAG a.HAVE_SPECIAL_FLAG,
a.CREATE_BY,
a.CREATE_NAME,
a.CREATE_TIME,
a.UPDATE_BY,
a.UPDATE_TIME
</sql> </sql>
<sql id="tSalaryAccount_where"> <sql id="tSalaryAccount_where">
<if test="tSalaryAccount != null"> <if test="tSalaryAccount != null">
...@@ -249,6 +259,7 @@ ...@@ -249,6 +259,7 @@
a.DELETE_FLAG = 0 a.DELETE_FLAG = 0
<include refid="tSalaryAccount_where"/> <include refid="tSalaryAccount_where"/>
</where> </where>
order by a.CREATE_TIME desc
</select> </select>
<!-- 获取校验的报账明细 ### 格式:身份证号_工资月份_报表类型_应发金额 --> <!-- 获取校验的报账明细 ### 格式:身份证号_工资月份_报表类型_应发金额 -->
......
...@@ -201,6 +201,7 @@ ...@@ -201,6 +201,7 @@
1=1 1=1
<include refid="tStatisticsCurrentReport_where"/> <include refid="tStatisticsCurrentReport_where"/>
</where> </where>
order by a.DECLARE_MONTH desc
</select> </select>
<!-- 本期申报 --> <!-- 本期申报 -->
...@@ -257,7 +258,8 @@ ...@@ -257,7 +258,8 @@
where m.declare_MONTH <![CDATA[<=]]> #{lastMonth} and m.declare_MONTH like '${nowYear}%' where m.declare_MONTH <![CDATA[<=]]> #{lastMonth} and m.declare_MONTH like '${nowYear}%'
GROUP BY m.EMP_IDCARD,m.INVOICE_TITLE GROUP BY m.EMP_IDCARD,m.INVOICE_TITLE
) m on m.EMP_IDCARD=s.EMP_IDCARD and m.INVOICE_TITLE = s.INVOICE_TITLE ) m on m.EMP_IDCARD=s.EMP_IDCARD and m.INVOICE_TITLE = s.INVOICE_TITLE
where s.DECLARE_MONTH = #{nowMonth} left join t_statistics_declarer d on d.EMP_IDCARD=s.EMP_IDCARD and d.DECLARE_MONTH=#{nowMonth}
where s.DECLARE_MONTH = #{nowMonth} and (d.id is null or d.IS_DECLARE = '0')
) )
</insert> </insert>
......
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