AttendDay2
This commit is contained in:
parent
f66182de94
commit
de6cfbc773
|
@ -103,14 +103,16 @@ func (s *StaffSalary) CalcSalary(salary *model.StaffSalary, month, expr string)
|
||||||
|
|
||||||
func (s *StaffSalary) calculate(corp *model.Corp, salary *model.StaffSalary, expression string) {
|
func (s *StaffSalary) calculate(corp *model.Corp, salary *model.StaffSalary, expression string) {
|
||||||
|
|
||||||
//获取基础数据
|
|
||||||
data := s.getCalcData(salary)
|
|
||||||
|
|
||||||
//获取业务数据
|
//获取业务数据
|
||||||
dataFactory := registry.NewSalaryCalculator(corp, s.user)
|
dataFactory := registry.NewSalaryCalculator(corp, s.user)
|
||||||
|
var biz interface{} = nil
|
||||||
if dataFactory != nil {
|
if dataFactory != nil {
|
||||||
data["biz"] = dataFactory.Calculate(salary)
|
biz = dataFactory.Calculate(salary)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
data := s.getCalcData(salary)
|
||||||
|
data["biz"] = biz
|
||||||
|
|
||||||
salary.Extra = goutil.EncodeJSONIndent(data)
|
salary.Extra = goutil.EncodeJSONIndent(data)
|
||||||
salary.SetExtra("calculate", goutil.GetNowTime())
|
salary.SetExtra("calculate", goutil.GetNowTime())
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue