Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
dj
/
rpc-staff
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 4f968fc5
authored
Jan 17, 2026
by
叶立庆
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
查询工资明细逻辑
1 parent
de9d369a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
20 changed files
with
664 additions
and
37 deletions
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/SalaryMonthBusinessDataDTO.java
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/SalaryStaffInfoDTO.java
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/StaffSalaryDetailDTO.java
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/StaffSalaryDetailRequestDTO.java
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/model/StaffMonthSalaryBaseInfo.java
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/model/StaffMonthSalarySlip.java
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/remote/salary/StaffMonthSalarySlipRemote.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/config/dubbo/SmartCarLifeDubboConfig.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/mapper/StaffMonthBusinessDataMapper.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/mapper/StaffMonthSalaryBaseInfoMapper.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/mapper/StaffMonthSalarySlipMapper.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/remote/salary/StaffMonthSalarySlipRemoteImpl.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/salary/StaffMonthBusinessDataService.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/salary/StaffMonthSalarySlipService.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/staffPerformance/PerformanceConfigService.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/staffPerformance/StaffPerformanceCalService.java
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/util/HttpRequestUtils.java
rpc-dj-staff/src/main/resources/META-INF/orm/StaffMonthSalaryBaseInfoMapper.xml
rpc-dj-staff/src/main/resources/META-INF/orm/StaffMonthSalarySlipMapper.xml
rpc-dj-staff/src/test/java/cn/com/glsx/dj/staff/service/StaffMonthSalaryServiceTest.java
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/SalaryMonthBusinessDataDTO.java
0 → 100644
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
dto
.
salary
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.List
;
/**
* 入职日期、离职日期、岗位、1.1总产值、1.1提成、2.1总产值、2.1提成、2.3总产值、2.3提成 查询类
*/
@Data
public
class
SalaryMonthBusinessDataDTO
implements
Serializable
{
// 手机号
@ApiModelProperty
(
name
=
"staffPhone"
,
notes
=
"员工手机号"
,
dataType
=
"String"
)
private
String
staffPhone
;
// 姓名
@ApiModelProperty
(
name
=
"staffName"
,
notes
=
"员工姓名"
,
dataType
=
"String"
)
private
String
staffName
;
@ApiModelProperty
(
name
=
"salaryMonth"
,
notes
=
"薪资月份(2025-12)"
,
dataType
=
"String"
)
private
String
salaryMonth
;
@ApiModelProperty
(
notes
=
"1.1总产值"
)
private
BigDecimal
orderTotalPrice1
;
@ApiModelProperty
(
notes
=
"1.1提成"
)
private
BigDecimal
commissionPrice1
;
@ApiModelProperty
(
notes
=
"2.1总产值"
)
private
BigDecimal
orderTotalPrice2
;
@ApiModelProperty
(
notes
=
"2.1提成"
)
private
BigDecimal
commissionPrice2
;
@ApiModelProperty
(
notes
=
"2.3总产值"
)
private
BigDecimal
orderTotalPrice3
;
@ApiModelProperty
(
notes
=
"2.3提成"
)
private
BigDecimal
commissionPrice3
;
}
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/SalaryStaffInfoDTO.java
0 → 100644
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
dto
.
salary
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.List
;
@Data
public
class
SalaryStaffInfoDTO
implements
Serializable
{
// 手机号
private
String
staffPhone
;
// 姓名
private
String
staffName
;
@ApiModelProperty
(
name
=
"salaryMonth"
,
notes
=
"薪资月份(2025-12)"
,
dataType
=
"String"
)
private
String
salaryMonth
;
// 门店号列表
@ApiModelProperty
(
name
=
"merchantIds"
,
notes
=
"商户id列表(查询时使用)"
,
dataType
=
"int"
)
private
List
<
Integer
>
merchantIds
;
// 手机号列表
@ApiModelProperty
(
name
=
"staffPhones"
,
notes
=
"手机号列表(查询时使用)"
,
dataType
=
"String"
)
private
List
<
String
>
staffPhones
;
}
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/StaffSalaryDetailDTO.java
0 → 100644
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
dto
.
salary
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.AllArgsConstructor
;
import
lombok.Builder
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
/**
* 工资明细导出导入类
*/
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
public
class
StaffSalaryDetailDTO
implements
Serializable
{
private
static
final
long
serialVersionUID
=
323172987093707L
;
@ApiModelProperty
(
notes
=
"id"
)
private
Integer
id
;
// 获取该员工产生提成订单,识别业务场景和4s店,取4s店在店面配置中所配置的区域经理字段,多个展示多个用“/”区隔,无则为空
@ApiModelProperty
(
notes
=
"区域运营"
)
private
String
areaOperation
;
//该4s店在店面配置中,所属省份字段,多个展示多个用“/”区隔,无则为空
@ApiModelProperty
(
notes
=
"区域(省)"
)
private
String
area
;
@ApiModelProperty
(
notes
=
"姓名"
)
private
String
staffName
;
@ApiModelProperty
(
notes
=
"手机号"
)
private
String
staffPhone
;
// 取当前员工入职日期 北森
@ApiModelProperty
(
notes
=
"入职日期"
)
private
String
entryDate
;
//取当前员工离职日期 北森
@ApiModelProperty
(
notes
=
"离职日期"
)
private
String
leaveDate
;
//取当前员工入职岗位字段 北森
@ApiModelProperty
(
notes
=
"岗位"
)
private
String
post
;
//取当前员工对应开单的4s店名称,多个时用/区隔
@ApiModelProperty
(
notes
=
"在岗门店"
)
private
String
merchantName
;
@ApiModelProperty
(
notes
=
"月份"
)
private
String
salaryMonth
;
@ApiModelProperty
(
notes
=
"业务类型(0:轻改,1:权益;2:延保)多个逗号分隔"
)
private
String
businessTypes
;
@ApiModelProperty
(
notes
=
"是否最终数据(Y:是,N:否)"
)
private
String
finalDataFlag
;
@ApiModelProperty
(
notes
=
"月应出勤天数"
)
private
BigDecimal
shouldWorkDay
;
@ApiModelProperty
(
notes
=
"计薪天数"
)
private
BigDecimal
actualWorkDay
;
@ApiModelProperty
(
notes
=
"薪资标准"
)
private
BigDecimal
salaryStandard
;
// 底薪
@ApiModelProperty
(
notes
=
"基本底薪"
)
private
BigDecimal
minimumSalary
;
@ApiModelProperty
(
notes
=
"绩效工资"
)
private
BigDecimal
performanceSalary
;
//绩效等级(1.S,2.A,3.B,4.B+,5.B-,6.C,7.D)
@ApiModelProperty
(
notes
=
"绩效等级(1.S,2.A,3.B,4.B+,5.B-,6.C,7.D)"
)
private
Byte
performanceLevel
;
//
@ApiModelProperty
(
notes
=
"基本薪资合计"
)
private
BigDecimal
basicSalary
;
@ApiModelProperty
(
notes
=
"1.1总产值"
)
private
BigDecimal
orderTotalPrice1
;
@ApiModelProperty
(
notes
=
"1.1提成"
)
private
BigDecimal
commissionPrice1
;
@ApiModelProperty
(
notes
=
"2.1总产值"
)
private
BigDecimal
orderTotalPrice2
;
@ApiModelProperty
(
notes
=
"2.1提成"
)
private
BigDecimal
commissionPrice2
;
@ApiModelProperty
(
notes
=
"2.3总产值"
)
private
BigDecimal
orderTotalPrice3
;
@ApiModelProperty
(
notes
=
"2.3提成"
)
private
BigDecimal
commissionPrice3
;
@ApiModelProperty
(
notes
=
"总产值"
)
private
BigDecimal
orderTotalPrice
;
@ApiModelProperty
(
notes
=
"总提成"
)
private
BigDecimal
commissionPrice
;
@ApiModelProperty
(
notes
=
"递延金扣减"
)
private
BigDecimal
deferExpenses
;
@ApiModelProperty
(
notes
=
"递延金发放"
)
private
BigDecimal
deferIncome
;
@ApiModelProperty
(
notes
=
"平板扣款"
)
private
BigDecimal
padDeductMoney
;
@ApiModelProperty
(
notes
=
"平板扣款次数"
)
private
Integer
padDeductCount
;
@ApiModelProperty
(
notes
=
"日报扣款次数"
)
private
Integer
dailyDeductCount
;
@ApiModelProperty
(
notes
=
"日报扣款"
)
private
BigDecimal
dailyDeductMoney
;
@ApiModelProperty
(
notes
=
"其它扣除"
)
private
BigDecimal
otherDeduction
;
@ApiModelProperty
(
notes
=
"其它扣除"
)
private
String
otherDeductionDetail
;
@ApiModelProperty
(
notes
=
"其它奖励"
)
private
BigDecimal
otherRewards
;
@ApiModelProperty
(
notes
=
"其他应发"
)
private
String
otherRewardsDetail
;
@ApiModelProperty
(
notes
=
"合计应发工资"
)
private
BigDecimal
salary
;
@ApiModelProperty
(
notes
=
"纠正后工资"
)
private
BigDecimal
correctSalary
;
}
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/dto/salary/StaffSalaryDetailRequestDTO.java
0 → 100644
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
dto
.
salary
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.List
;
@Data
public
class
StaffSalaryDetailRequestDTO
implements
Serializable
{
// 手机号
private
String
staffPhone
;
// 姓名
private
String
staffName
;
@ApiModelProperty
(
name
=
"salaryMonth"
,
notes
=
"薪资月份(2025-12)"
,
dataType
=
"String"
)
private
String
salaryMonth
;
// 门店号列表
@ApiModelProperty
(
name
=
"merchantIds"
,
notes
=
"商户id列表(查询时使用)"
,
dataType
=
"int"
)
private
List
<
Integer
>
merchantIds
;
// 手机号列表
@ApiModelProperty
(
name
=
"staffPhones"
,
notes
=
"手机号列表(查询时使用)"
,
dataType
=
"String"
)
private
List
<
String
>
staffPhones
;
}
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/model/StaffMonthSalaryBaseInfo.java
0 → 100644
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
model
;
import
lombok.AllArgsConstructor
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
lombok.ToString
;
import
lombok.experimental.SuperBuilder
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
javax.persistence.*
;
@AllArgsConstructor
@NoArgsConstructor
@SuperBuilder
@Data
@ToString
@Table
(
name
=
"dj_car_life_staff_month_salary_base_info"
)
public
class
StaffMonthSalaryBaseInfo
implements
Serializable
{
/**
* 主键ID
*/
@Id
@GeneratedValue
(
strategy
=
GenerationType
.
IDENTITY
)
private
Integer
id
;
/**
* 驻店员工手机号
*/
@Column
(
name
=
"staff_phone"
)
private
String
staffPhone
;
/**
* 工资月份
*/
@Column
(
name
=
"salary_month"
)
private
String
salaryMonth
;
/**
* 区域运营
*/
@Column
(
name
=
"area_operation"
)
private
String
areaOperation
;
/**
* 区域(省)
*/
private
String
area
;
/**
* 入职日期(北森)
*/
@Column
(
name
=
"entry_date"
)
private
String
entryDate
;
/**
* 离职日期(北森)
*/
@Column
(
name
=
"leave_date"
)
private
String
leaveDate
;
/**
* 岗位(北森)
*/
private
String
post
;
/**
* 在岗门店(取当前员工对应开单的4s店名称,多个时用/区隔)
*/
@Column
(
name
=
"merchant_name"
)
private
String
merchantName
;
/**
* 1.1总产值
*/
@Column
(
name
=
"order_total_price1"
)
private
BigDecimal
orderTotalPrice1
;
/**
* 1.1提成
*/
@Column
(
name
=
"commission_price1"
)
private
BigDecimal
commissionPrice1
;
/**
* 2.1总产值
*/
@Column
(
name
=
"order_total_price2"
)
private
BigDecimal
orderTotalPrice2
;
/**
* 2.1提成
*/
@Column
(
name
=
"commission_price2"
)
private
BigDecimal
commissionPrice2
;
/**
* 2.3总产值
*/
@Column
(
name
=
"order_total_price3"
)
private
BigDecimal
orderTotalPrice3
;
/**
* 2.3提成
*/
@Column
(
name
=
"commission_price3"
)
private
BigDecimal
commissionPrice3
;
/**
* 创建人
*/
@Column
(
name
=
"created_by"
)
private
String
createdBy
;
/**
* 创建时间
*/
@Column
(
name
=
"created_date"
)
private
Date
createdDate
;
/**
* 修改人
*/
@Column
(
name
=
"updated_by"
)
private
String
updatedBy
;
/**
* 修改时间
*/
@Column
(
name
=
"updated_date"
)
private
Date
updatedDate
;
/**
* 删除标识(D:已删除;N:未删除)
*/
@Column
(
name
=
"deleted_flag"
)
private
String
deletedFlag
;
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/model/StaffMonthSalarySlip.java
View file @
4f968fc
...
@@ -97,7 +97,7 @@ public class StaffMonthSalarySlip implements Serializable{
...
@@ -97,7 +97,7 @@ public class StaffMonthSalarySlip implements Serializable{
private
BigDecimal
performanceSalary
;
private
BigDecimal
performanceSalary
;
/**
/**
* 基本工资
* 基本工资
(当前月份实发底薪+实发绩效合)
*/
*/
@Column
(
name
=
"basic_salary"
)
@Column
(
name
=
"basic_salary"
)
private
BigDecimal
basicSalary
;
private
BigDecimal
basicSalary
;
...
...
rpc-dj-staff-api/src/main/java/cn/com/glsx/dj/staff/remote/salary/StaffMonthSalarySlipRemote.java
View file @
4f968fc
...
@@ -3,7 +3,7 @@ package cn.com.glsx.dj.staff.remote.salary;
...
@@ -3,7 +3,7 @@ package cn.com.glsx.dj.staff.remote.salary;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotNull
;
import
javax.validation.constraints.NotNull
;
import
cn.com.glsx.dj.staff.dto.salary.
StaffMonthSalarySlipDTO
;
import
cn.com.glsx.dj.staff.dto.salary.
*
;
import
cn.com.glsx.dj.staff.model.StaffMonthSalarySlip
;
import
cn.com.glsx.dj.staff.model.StaffMonthSalarySlip
;
import
cn.com.glsx.framework.core.annotation.ApiMethod
;
import
cn.com.glsx.framework.core.annotation.ApiMethod
;
import
cn.com.glsx.framework.core.annotation.ApiParam
;
import
cn.com.glsx.framework.core.annotation.ApiParam
;
...
@@ -33,4 +33,21 @@ public interface StaffMonthSalarySlipRemote {
...
@@ -33,4 +33,21 @@ public interface StaffMonthSalarySlipRemote {
})
})
@ApiResponse
(
"员工月度工资"
)
@ApiResponse
(
"员工月度工资"
)
RpcResponse
<
StaffMonthSalarySlip
>
getStaffSalary
(
@NotBlank
String
staffPhone
,
@NotBlank
String
salaryMonth
);
RpcResponse
<
StaffMonthSalarySlip
>
getStaffSalary
(
@NotBlank
String
staffPhone
,
@NotBlank
String
salaryMonth
);
@ApiMethod
(
"查询有过工资条的员工"
)
RpcResponse
<
RpcPagination
<
SalaryStaffInfoDTO
>>
getSalaryStaffList
(
@NotNull
RpcPagination
<
SalaryStaffInfoDTO
>
pagination
);
@ApiMethod
(
"查询员工月度工资业务提成数据"
)
@ApiParam
(
name
=
"salaryMonthBusinessDataDTO"
,
notes
=
"查询条件"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)
@ApiResponse
(
"员工月度工资业务提成数据"
)
RpcResponse
<
SalaryMonthBusinessDataDTO
>
getSalaryStaffMonthBusinessData
(
@NotNull
SalaryMonthBusinessDataDTO
salaryMonthBusinessDataDTO
);
@ApiMethod
(
"查询员工月度工资详情数据"
)
@ApiParam
(
name
=
"requestDTO"
,
notes
=
"查询条件"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)
@ApiResponse
(
"员工月度工资详情数据"
)
RpcResponse
<
RpcPagination
<
StaffSalaryDetailDTO
>>
getStaffMonthSalaryDetailData
(
@NotNull
RpcPagination
<
StaffSalaryDetailRequestDTO
>
pagination
);
}
}
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/config/dubbo/SmartCarLifeDubboConfig.java
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
config
.
dubbo
;
package
cn
.
com
.
glsx
.
dj
.
staff
.
config
.
dubbo
;
import
cn.com.glsx.dj.smartcarlife.remote.*
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.context.annotation.Configuration
;
import
cn.com.glsx.dj.smartcarlife.remote.GoodsOrderRemote
;
import
cn.com.glsx.dj.smartcarlife.remote.MerchantDailyReportHuaweiRemote
;
import
cn.com.glsx.dj.smartcarlife.remote.StaffBaseInfoRemote
;
import
cn.com.glsx.dj.smartcarlife.remote.StaffBehaviorDeductMoneyRecordRemote
;
import
cn.com.glsx.dj.smartcarlife.remote.StaffInfoRemote
;
import
cn.com.glsx.dj.staff.config.DubboConfig
;
import
cn.com.glsx.dj.staff.config.DubboConfig
;
@Configuration
@Configuration
...
@@ -37,5 +33,10 @@ public class SmartCarLifeDubboConfig extends DubboConfig {
...
@@ -37,5 +33,10 @@ public class SmartCarLifeDubboConfig extends DubboConfig {
public
StaffBehaviorDeductMoneyRecordRemote
staffBehaviorDeductMoneyRecordRemote
()
{
public
StaffBehaviorDeductMoneyRecordRemote
staffBehaviorDeductMoneyRecordRemote
()
{
return
factory
.
builder
(
StaffBehaviorDeductMoneyRecordRemote
.
class
).
check
(
check
).
timeout
(
timeout
).
version
(
"1.0.0"
).
build
();
return
factory
.
builder
(
StaffBehaviorDeductMoneyRecordRemote
.
class
).
check
(
check
).
timeout
(
timeout
).
version
(
"1.0.0"
).
build
();
}
}
@Bean
public
ShopMerchantDirectorConfigRemote
shopMerchantDirectorConfigRemote
(){
return
factory
.
builder
(
ShopMerchantDirectorConfigRemote
.
class
).
protocol
(
"dubbo"
).
check
(
check
).
version
(
"1.0.0"
).
timeout
(
timeout
).
build
();
}
}
}
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/mapper/StaffMonthBusinessDataMapper.java
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
mapper
;
package
cn
.
com
.
glsx
.
dj
.
staff
.
mapper
;
import
cn.com.glsx.dj.staff.model.StaffMonthBusinessData
;
import
cn.com.glsx.dj.staff.model.StaffMonthBusinessData
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
@Mapper
@Mapper
public
interface
StaffMonthBusinessDataMapper
extends
OreMapper
<
StaffMonthBusinessData
>
{
public
interface
StaffMonthBusinessDataMapper
extends
OreMapper
<
StaffMonthBusinessData
>
{
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/mapper/StaffMonthSalaryBaseInfoMapper.java
0 → 100644
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
mapper
;
import
cn.com.glsx.dj.staff.model.StaffMonthSalaryBaseInfo
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
@Mapper
public
interface
StaffMonthSalaryBaseInfoMapper
extends
OreMapper
<
StaffMonthSalaryBaseInfo
>
{
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/mapper/StaffMonthSalarySlipMapper.java
View file @
4f968fc
...
@@ -2,6 +2,9 @@ package cn.com.glsx.dj.staff.mapper;
...
@@ -2,6 +2,9 @@ package cn.com.glsx.dj.staff.mapper;
import
java.util.List
;
import
java.util.List
;
import
cn.com.glsx.dj.staff.dto.salary.SalaryStaffInfoDTO
;
import
cn.com.glsx.dj.staff.dto.salary.StaffSalaryDetailDTO
;
import
cn.com.glsx.dj.staff.dto.salary.StaffSalaryDetailRequestDTO
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
...
@@ -13,4 +16,8 @@ public interface StaffMonthSalarySlipMapper extends OreMapper<StaffMonthSalarySl
...
@@ -13,4 +16,8 @@ public interface StaffMonthSalarySlipMapper extends OreMapper<StaffMonthSalarySl
List
<
StaffMonthSalarySlipDTO
>
list
(
StaffMonthSalarySlipDTO
condition
);
List
<
StaffMonthSalarySlipDTO
>
list
(
StaffMonthSalarySlipDTO
condition
);
StaffMonthSalarySlipDTO
statStaffMonthSalary
(
StaffMonthSalarySlipDTO
dto
);
StaffMonthSalarySlipDTO
statStaffMonthSalary
(
StaffMonthSalarySlipDTO
dto
);
List
<
SalaryStaffInfoDTO
>
getSalaryStaffList
(
SalaryStaffInfoDTO
condition
);
List
<
StaffSalaryDetailDTO
>
getStaffMonthSalaryDetailData
(
StaffSalaryDetailRequestDTO
condition
);
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/remote/salary/StaffMonthSalarySlipRemoteImpl.java
View file @
4f968fc
...
@@ -3,10 +3,13 @@ package cn.com.glsx.dj.staff.remote.salary;
...
@@ -3,10 +3,13 @@ package cn.com.glsx.dj.staff.remote.salary;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotBlank
;
import
javax.validation.constraints.NotNull
;
import
javax.validation.constraints.NotNull
;
import
cn.com.glsx.dj.staff.dto.salary.*
;
import
cn.com.glsx.dj.staff.service.salary.StaffMonthBusinessDataService
;
import
cn.com.glsx.framework.core.enums.DefaultErrorEnum
;
import
cn.com.glsx.framework.core.util.RpcAssert
;
import
org.apache.dubbo.config.annotation.DubboService
;
import
org.apache.dubbo.config.annotation.DubboService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
cn.com.glsx.dj.staff.dto.salary.StaffMonthSalarySlipDTO
;
import
cn.com.glsx.dj.staff.model.StaffMonthSalarySlip
;
import
cn.com.glsx.dj.staff.model.StaffMonthSalarySlip
;
import
cn.com.glsx.dj.staff.service.salary.StaffMonthSalarySlipService
;
import
cn.com.glsx.dj.staff.service.salary.StaffMonthSalarySlipService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
...
@@ -17,6 +20,8 @@ import lombok.extern.slf4j.Slf4j;
...
@@ -17,6 +20,8 @@ import lombok.extern.slf4j.Slf4j;
public
class
StaffMonthSalarySlipRemoteImpl
implements
StaffMonthSalarySlipRemote
{
public
class
StaffMonthSalarySlipRemoteImpl
implements
StaffMonthSalarySlipRemote
{
@Autowired
@Autowired
private
StaffMonthSalarySlipService
staffMonthSalarySlipService
;
private
StaffMonthSalarySlipService
staffMonthSalarySlipService
;
@Autowired
private
StaffMonthBusinessDataService
staffMonthBusinessDataService
;
@Override
@Override
public
RpcResponse
<
RpcPagination
<
StaffMonthSalarySlipDTO
>>
pageStaffMonthSalary
(
public
RpcResponse
<
RpcPagination
<
StaffMonthSalarySlipDTO
>>
pageStaffMonthSalary
(
...
@@ -50,4 +55,42 @@ public class StaffMonthSalarySlipRemoteImpl implements StaffMonthSalarySlipRemot
...
@@ -50,4 +55,42 @@ public class StaffMonthSalarySlipRemoteImpl implements StaffMonthSalarySlipRemot
}
}
}
}
@Override
public
RpcResponse
<
RpcPagination
<
SalaryStaffInfoDTO
>>
getSalaryStaffList
(
RpcPagination
<
SalaryStaffInfoDTO
>
pagination
)
{
try
{
return
RpcResponse
.
success
(
RpcPagination
.
copyPage
(
staffMonthSalarySlipService
.
getSalaryStaffList
(
pagination
)));
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
return
RpcResponse
.
error
(
e
);
}
}
@Override
public
RpcResponse
<
SalaryMonthBusinessDataDTO
>
getSalaryStaffMonthBusinessData
(
SalaryMonthBusinessDataDTO
salaryMonthBusinessDataDTO
)
{
try
{
//参数非空校验
RpcAssert
.
assertNotNull
(
salaryMonthBusinessDataDTO
,
DefaultErrorEnum
.
PARAMETER_NULL
,
"员工月度工资业务提成数据查询参数不能为空"
);
RpcAssert
.
assertNotNull
(
salaryMonthBusinessDataDTO
.
getStaffPhone
(),
DefaultErrorEnum
.
PARAMETER_NULL
,
"手机号查询参数不能为空"
);
RpcAssert
.
assertNotNull
(
salaryMonthBusinessDataDTO
.
getSalaryMonth
(),
DefaultErrorEnum
.
PARAMETER_NULL
,
"薪资月份查询参数不能为空"
);
return
RpcResponse
.
success
(
staffMonthBusinessDataService
.
getSalaryStaffMonthBusinessData
(
salaryMonthBusinessDataDTO
));
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
return
RpcResponse
.
error
(
e
);
}
}
@Override
public
RpcResponse
<
RpcPagination
<
StaffSalaryDetailDTO
>>
getStaffMonthSalaryDetailData
(
RpcPagination
<
StaffSalaryDetailRequestDTO
>
pagination
)
{
try
{
//参数非空校验
RpcAssert
.
assertNotNull
(
pagination
,
DefaultErrorEnum
.
PARAMETER_NULL
,
"查询参数不能为空"
);
RpcAssert
.
assertNotNull
(
pagination
.
getCondition
(),
DefaultErrorEnum
.
PARAMETER_NULL
,
"查询参数不能为空"
);
RpcAssert
.
assertNotNull
(
pagination
.
getCondition
().
getSalaryMonth
(),
DefaultErrorEnum
.
PARAMETER_NULL
,
"薪资月份查询参数不能为空"
);
return
RpcResponse
.
success
(
RpcPagination
.
copyPage
(
staffMonthSalarySlipService
.
getStaffMonthSalaryDetailData
(
pagination
)));
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
return
RpcResponse
.
error
(
e
);
}
}
}
}
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/salary/StaffMonthBusinessDataService.java
View file @
4f968fc
This diff is collapsed.
Click to expand it.
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/salary/StaffMonthSalarySlipService.java
View file @
4f968fc
This diff is collapsed.
Click to expand it.
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/staffPerformance/PerformanceConfigService.java
View file @
4f968fc
...
@@ -41,11 +41,11 @@ public class PerformanceConfigService {
...
@@ -41,11 +41,11 @@ public class PerformanceConfigService {
// 2.
// 2.
// 调用PerformanceParamConfigService的方法,根据performanceConfigId,调用对应的mapper查询List<PerformanceParamConfigDTO>
// 调用PerformanceParamConfigService的方法,根据performanceConfigId,调用对应的mapper查询List<PerformanceParamConfigDTO>
List
<
PerformanceParamConfigDTO
>
performanceParamConfigs
=
performanceParamConfigService
//
List<PerformanceParamConfigDTO> performanceParamConfigs = performanceParamConfigService
.
listByConfigId
(
result
.
getId
());
//
.listByConfigId(result.getId());
//
// 设置到result
//
// 设置到result
result
.
setPerformanceParamConfigs
(
performanceParamConfigs
);
//
result.setPerformanceParamConfigs(performanceParamConfigs);
// 3. 返回PerformanceConfigDTO
// 3. 返回PerformanceConfigDTO
return
result
;
return
result
;
...
...
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/service/staffPerformance/StaffPerformanceCalService.java
View file @
4f968fc
...
@@ -127,7 +127,7 @@ public class StaffPerformanceCalService {
...
@@ -127,7 +127,7 @@ public class StaffPerformanceCalService {
PerformanceParamConfigDTO
firstConfig
=
paramConfigs
.
get
(
0
);
PerformanceParamConfigDTO
firstConfig
=
paramConfigs
.
get
(
0
);
String
assessmentFactor
=
firstConfig
.
getAssessmentFactor
();
String
assessmentFactor
=
firstConfig
.
getAssessmentFactor
();
BigDecimal
actualValue
=
getActualValue
(
assessmentFactor
,
dependencyData
,
BigDecimal
actualValue
=
getActualValue
(
assessmentFactor
,
dependencyData
,
firstConfig
.
getGoodsConfigType
(),
firstConfig
.
getGoodsConfigType
()
.
byteValue
()
,
firstConfig
.
getGoodsType
(),
firstConfig
.
getSecondaryGoodsType
(),
firstConfig
.
getGoodsType
(),
firstConfig
.
getSecondaryGoodsType
(),
firstConfig
.
getThirdLevelGoodsType
(),
firstConfig
.
getThirdLevelGoodsType
(),
firstConfig
.
getProductDefineId
());
firstConfig
.
getProductDefineId
());
...
@@ -322,7 +322,7 @@ public class StaffPerformanceCalService {
...
@@ -322,7 +322,7 @@ public class StaffPerformanceCalService {
.
staffName
(
context
.
getStaffName
())
.
staffName
(
context
.
getStaffName
())
.
month
(
context
.
getPerformanceMonth
())
.
month
(
context
.
getPerformanceMonth
())
.
merchantId
(
merchantId
)
.
merchantId
(
merchantId
)
.
businessType
(
businessType
)
.
businessType
(
businessType
.
intValue
()
)
.
brandId
(
brandId
)
.
brandId
(
brandId
)
.
childBrandId
(
childBrandId
)
.
childBrandId
(
childBrandId
)
.
goodsConfigType
(
config
.
getGoodsConfigType
())
.
goodsConfigType
(
config
.
getGoodsConfigType
())
...
...
rpc-dj-staff/src/main/java/cn/com/glsx/dj/staff/util/HttpRequestUtils.java
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
util
;
package
cn
.
com
.
glsx
.
dj
.
staff
.
util
;
import
cn.com.glsx.dj.peanalysis.dto.DataBusinessDTO
;
//
import cn.com.glsx.dj.peanalysis.dto.DataBusinessDTO;
import
cn.com.glsx.dj.peanalysis.utils.response.DataResp
;
//
import cn.com.glsx.dj.peanalysis.utils.response.DataResp;
import
cn.hutool.core.lang.TypeReference
;
import
cn.hutool.core.lang.TypeReference
;
import
cn.hutool.json.JSONUtil
;
import
cn.hutool.json.JSONUtil
;
...
@@ -142,23 +142,23 @@ public class HttpRequestUtils {
...
@@ -142,23 +142,23 @@ public class HttpRequestUtils {
try
{
try
{
// 带自定义请求头的 JSON 请求
// 带自定义请求头的 JSON 请求
Map
<
String
,
String
>
headers
=
new
HashMap
<>();
Map
<
String
,
String
>
headers
=
new
HashMap
<>();
//
String
jsonResponse
=
postJson
(
//
String jsonResponse = postJson(
"http://192.168.3.211:8021/data"
,
//
"http://192.168.3.211:8021/data",
"{\n"
+
//
"{\n" +
" \"bizs\": 1,\n"
+
//
" \"bizs\": 1,\n" +
" \"brandIds\": \"-1,-3\",\n"
+
//
" \"brandIds\": \"-1,-3\",\n" +
" \"dateType\": 2,\n"
+
//
" \"dateType\": 2,\n" +
" \"endDate\": \"2025-12-31\",\n"
+
//
" \"endDate\": \"2025-12-31\",\n" +
" \"exts\": \"merchantIds\",\n"
+
//
" \"exts\": \"merchantIds\",\n" +
" \"merchantIds\":\"44218026\",\n"
+
//
" \"merchantIds\":\"44218026\",\n" +
" \"itemCodes\": \"A036\",\n"
+
//
" \"itemCodes\": \"A036\",\n" +
" \"startDate\": \"2025-01-01\"\n"
+
//
" \"startDate\": \"2025-01-01\"\n" +
"}"
,
//
"}",
headers
//
headers
);
//
);
DataResp
<
List
<
DataBusinessDTO
>>
dataResp
=
JSONUtil
.
toBean
(
jsonResponse
,
new
TypeReference
<
DataResp
<
List
<
DataBusinessDTO
>>>()
{
//
DataResp<List<DataBusinessDTO>> dataResp = JSONUtil.toBean(jsonResponse, new TypeReference<DataResp<List<DataBusinessDTO>>>() {
},
true
);
//
}, true);
// DataResp<List<DataBusinessDTO>> dataResp = JSON.parseObject(jsonResponse, new TypeReference<DataResp<List<DataBusinessDTO>>>() {});
// DataResp<List<DataBusinessDTO>> dataResp = JSON.parseObject(jsonResponse, new TypeReference<DataResp<List<DataBusinessDTO>>>() {});
// System.out.println("JSON Response: " + DateUtil.format(DateUtil.offsetMonth(DateUtil.parse(String.valueOf(2024), "yyyy"), -0), "yyyy-MM"));
// System.out.println("JSON Response: " + DateUtil.format(DateUtil.offsetMonth(DateUtil.parse(String.valueOf(2024), "yyyy"), -0), "yyyy-MM"));
// 获取指定年份的12个月
// 获取指定年份的12个月
...
...
rpc-dj-staff/src/main/resources/META-INF/orm/StaffMonthSalaryBaseInfoMapper.xml
0 → 100644
View file @
4f968fc
<?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=
"cn.com.glsx.dj.staff.mapper.StaffMonthSalaryBaseInfoMapper"
>
<resultMap
id=
"BaseResultMap"
type=
"cn.com.glsx.dj.staff.model.StaffMonthSalaryBaseInfo"
>
<!--
WARNING - @mbg.generated
-->
<id
column=
"id"
property=
"id"
jdbcType=
"INTEGER"
/>
<result
column=
"staff_phone"
property=
"staffPhone"
jdbcType=
"VARCHAR"
/>
<result
column=
"salary_month"
property=
"salaryMonth"
jdbcType=
"CHAR"
/>
<result
column=
"area_operation"
property=
"areaOperation"
jdbcType=
"VARCHAR"
/>
<result
column=
"area"
property=
"area"
jdbcType=
"VARCHAR"
/>
<result
column=
"entry_date"
property=
"entryDate"
jdbcType=
"VARCHAR"
/>
<result
column=
"leave_date"
property=
"leaveDate"
jdbcType=
"VARCHAR"
/>
<result
column=
"post"
property=
"post"
jdbcType=
"VARCHAR"
/>
<result
column=
"merchant_name"
property=
"merchantName"
jdbcType=
"VARCHAR"
/>
<result
column=
"order_total_price1"
property=
"orderTotalPrice1"
jdbcType=
"DECIMAL"
/>
<result
column=
"commission_price1"
property=
"commissionPrice1"
jdbcType=
"DECIMAL"
/>
<result
column=
"order_total_price2"
property=
"orderTotalPrice2"
jdbcType=
"DECIMAL"
/>
<result
column=
"commission_price2"
property=
"commissionPrice2"
jdbcType=
"DECIMAL"
/>
<result
column=
"order_total_price3"
property=
"orderTotalPrice3"
jdbcType=
"DECIMAL"
/>
<result
column=
"commission_price3"
property=
"commissionPrice3"
jdbcType=
"DECIMAL"
/>
<result
column=
"created_by"
property=
"createdBy"
jdbcType=
"VARCHAR"
/>
<result
column=
"created_date"
property=
"createdDate"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"updated_by"
property=
"updatedBy"
jdbcType=
"VARCHAR"
/>
<result
column=
"updated_date"
property=
"updatedDate"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"deleted_flag"
property=
"deletedFlag"
jdbcType=
"CHAR"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
<!--
WARNING - @mbg.generated
-->
id, staff_phone, salary_month, area_operation, area, entry_date, leave_date, post,
merchant_name, order_total_price1, commission_price1, order_total_price2, commission_price2,
order_total_price3, commission_price3, created_by, created_date, updated_by, updated_date,
deleted_flag
</sql>
</mapper>
\ No newline at end of file
\ No newline at end of file
rpc-dj-staff/src/main/resources/META-INF/orm/StaffMonthSalarySlipMapper.xml
View file @
4f968fc
...
@@ -44,6 +44,47 @@
...
@@ -44,6 +44,47 @@
<resultMap
id=
"DTOResultMap"
type=
"cn.com.glsx.dj.staff.dto.salary.StaffMonthSalarySlipDTO"
extends=
"BaseResultMap"
>
<resultMap
id=
"DTOResultMap"
type=
"cn.com.glsx.dj.staff.dto.salary.StaffMonthSalarySlipDTO"
extends=
"BaseResultMap"
>
<result
column=
"totalActualSalary"
property=
"totalActualSalary"
/>
<result
column=
"totalActualSalary"
property=
"totalActualSalary"
/>
</resultMap>
</resultMap>
<resultMap
id=
"detailResultMap"
type=
"cn.com.glsx.dj.staff.dto.salary.StaffSalaryDetailDTO"
>
<id
column=
"id"
property=
"id"
jdbcType=
"INTEGER"
/>
<result
column=
"area_operation"
property=
"areaOperation"
/>
<result
column=
"area"
property=
"area"
/>
<result
column=
"entry_date"
property=
"entryDate"
/>
<result
column=
"leave_date"
property=
"leaveDate"
/>
<result
column=
"post"
property=
"post"
/>
<result
column=
"merchant_name"
property=
"merchantName"
/>
<result
column=
"order_total_price1"
property=
"orderTotalPrice1"
/>
<result
column=
"commission_price1"
property=
"commissionPrice1"
/>
<result
column=
"order_total_price2"
property=
"orderTotalPrice2"
/>
<result
column=
"commission_price2"
property=
"commissionPrice2"
/>
<result
column=
"order_total_price3"
property=
"orderTotalPrice3"
/>
<result
column=
"commission_price3"
property=
"commissionPrice3"
/>
<result
column=
"staff_name"
property=
"staffName"
jdbcType=
"VARCHAR"
/>
<result
column=
"staff_phone"
property=
"staffPhone"
jdbcType=
"VARCHAR"
/>
<result
column=
"business_types"
property=
"businessTypes"
jdbcType=
"VARCHAR"
/>
<result
column=
"salary_month"
property=
"salaryMonth"
jdbcType=
"CHAR"
/>
<result
column=
"final_data_flag"
property=
"finalDataFlag"
jdbcType=
"VARCHAR"
/>
<result
column=
"should_work_day"
property=
"shouldWorkDay"
jdbcType=
"DECIMAL"
/>
<result
column=
"actual_work_day"
property=
"actualWorkDay"
jdbcType=
"DECIMAL"
/>
<result
column=
"salary_standard"
property=
"salaryStandard"
jdbcType=
"DECIMAL"
/>
<result
column=
"minimum_salary"
property=
"minimumSalary"
jdbcType=
"DECIMAL"
/>
<result
column=
"performance_level"
property=
"performanceLevel"
jdbcType=
"TINYINT"
/>
<result
column=
"performance_salary"
property=
"performanceSalary"
jdbcType=
"DECIMAL"
/>
<result
column=
"basic_salary"
property=
"basicSalary"
jdbcType=
"DECIMAL"
/>
<result
column=
"order_total_price"
property=
"orderTotalPrice"
jdbcType=
"DECIMAL"
/>
<result
column=
"commission_price"
property=
"commissionPrice"
jdbcType=
"DECIMAL"
/>
<result
column=
"daily_deduct_count"
property=
"dailyDeductCount"
/>
<result
column=
"daily_deduct_money"
property=
"dailyDeductMoney"
jdbcType=
"DECIMAL"
/>
<result
column=
"pad_deduct_count"
property=
"padDeductCount"
/>
<result
column=
"pad_deduct_money"
property=
"padDeductMoney"
jdbcType=
"DECIMAL"
/>
<result
column=
"defer_expenses"
property=
"deferExpenses"
jdbcType=
"DECIMAL"
/>
<result
column=
"defer_income"
property=
"deferIncome"
jdbcType=
"DECIMAL"
/>
<result
column=
"other_deduction"
property=
"otherDeduction"
jdbcType=
"DECIMAL"
/>
<result
column=
"other_deduction_detail"
property=
"otherDeductionDetail"
/>
<result
column=
"other_rewards"
property=
"otherRewards"
jdbcType=
"DECIMAL"
/>
<result
column=
"other_rewards_detail"
property=
"otherRewardsDetail"
/>
<result
column=
"salary"
property=
"salary"
jdbcType=
"DECIMAL"
/>
<result
column=
"correct_salary"
property=
"correctSalary"
jdbcType=
"DECIMAL"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
<sql
id=
"Base_Column_List"
>
<!--
<!--
WARNING - @mbg.generated
WARNING - @mbg.generated
...
@@ -68,8 +109,61 @@
...
@@ -68,8 +109,61 @@
from dj_car_life_staff_month_salary_slip
from dj_car_life_staff_month_salary_slip
<include
refid=
"list_condition"
/>
<include
refid=
"list_condition"
/>
</select>
</select>
<select
id=
"getSalaryStaffList"
resultType=
"cn.com.glsx.dj.staff.dto.salary.SalaryStaffInfoDTO"
>
<sql
id=
"list_condition"
>
SELECT
dsi.phone_number staffPhone,
dsi.staff_name staffName
FROM `dj_car_life_staff_info` dsi
INNER JOIN (
SELECT
phone_number,
MAX(updated_date) AS latest_time
FROM `dj_car_life_staff_info`
WHERE deleted_flag = 'N'
GROUP BY phone_number
) latest ON dsi.phone_number = latest.phone_number AND dsi.updated_date = latest.latest_time
WHERE EXISTS (
SELECT 1
FROM dj_car_life_scene_merchant_ref dsmr
WHERE dsmr.deleted_flag = 'N'
AND dsmr.sub_merchant_type IN (6, 8)
AND dsmr.main_merchant_type = 2
AND dsmr.sub_merchant_id = dsi.merchant_id
)
AND EXISTS (
SELECT 1
FROM `dj_car_life_staff_month_salary_slip` dss
WHERE dss.deleted_flag = 'N'
<if
test=
"salaryMonth != null and salaryMonth != ''"
>
AND dss.salary_month=#{salaryMonth}
</if>
AND dss.staff_phone = dsi.phone_number
)
AND dsi.deleted_flag = 'N'
</select>
<select
id=
"getStaffMonthSalaryDetailData"
resultMap=
"detailResultMap"
>
SELECT ss.*,sbi.area_operation,sbi.area,sbi.entry_date,sbi.leave_date,sbi.post,sbi.
merchant_name,sbi.order_total_price1,sbi.commission_price1,sbi.order_total_price2,sbi.commission_price2,sbi.
order_total_price3,sbi.commission_price3 FROM `dj_car_life_staff_month_salary_slip` ss
INNER JOIN `dj_car_life_staff_month_salary_base_info` sbi ON sbi.staff_phone=ss.staff_phone AND sbi.salary_month=ss.salary_month
WHERE ss.deleted_flag='N' AND sbi.deleted_flag='N'
AND ss.salary_month=#{salaryMonth}
<if
test=
"staffPhone != null and staffPhone != ''"
>
AND ss.staff_phone = #{staffPhone}
</if>
<if
test=
"staffName != null and staffName != ''"
>
AND ss.staff_name = #{staffName}
</if>
<if
test=
"staffPhones != null and staffPhones.size()>0"
>
AND ss.staff_phone in
<foreach
collection=
"staffPhones"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</if>
GROUP BY ss.staff_phone,ss.salary_month
</select>
<sql
id=
"list_condition"
>
<where>
<where>
deleted_flag = 'N'
deleted_flag = 'N'
<if
test=
"staffPhone != null and staffPhone != ''"
>
<if
test=
"staffPhone != null and staffPhone != ''"
>
...
...
rpc-dj-staff/src/test/java/cn/com/glsx/dj/staff/service/StaffMonthSalaryServiceTest.java
0 → 100644
View file @
4f968fc
package
cn
.
com
.
glsx
.
dj
.
staff
.
service
;
import
cn.com.glsx.dj.sale.service.BaseServiceTest
;
import
cn.com.glsx.dj.staff.dto.salary.StaffSalaryDetailDTO
;
import
cn.com.glsx.dj.staff.dto.salary.StaffSalaryDetailRequestDTO
;
import
cn.com.glsx.dj.staff.service.salary.StaffMonthSalarySlipService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
com.github.pagehelper.Page
;
import
org.junit.Test
;
import
org.springframework.beans.factory.annotation.Autowired
;
public
class
StaffMonthSalaryServiceTest
extends
BaseServiceTest
{
@Autowired
private
StaffMonthSalarySlipService
staffMonthSalarySlipService
;
@Test
public
void
testStatStaffMonthSalaryBaseInfo
()
{
RpcPagination
<
StaffSalaryDetailRequestDTO
>
pagination
=
new
RpcPagination
<>();
String
staffPhone
=
"15699990000"
;
String
salaryMonth
=
"2025-12"
;
StaffSalaryDetailRequestDTO
dto
=
new
StaffSalaryDetailRequestDTO
();
dto
.
setStaffPhone
(
staffPhone
);
dto
.
setSalaryMonth
(
salaryMonth
);
pagination
.
setCondition
(
dto
);
pagination
.
setPageSize
(
10
);
pagination
.
setPageNum
(
1
);
Page
<
StaffSalaryDetailDTO
>
page
=
staffMonthSalarySlipService
.
getStaffMonthSalaryDetailData
(
pagination
);
System
.
out
.
println
(
page
);
}
}
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment