...
|
...
|
@@ -92,6 +92,7 @@ func (cmd *HistoryProductRecordQuery) Valid(validation *validation.Validation) { |
|
|
cmd.ProductBeginTime = t
|
|
|
cmd.ProductEndTime = t.AddDate(0, 0, 1)
|
|
|
}
|
|
|
if cmd.ProductRecordType == domain.RecordTypeReceiveMaterial && cmd.ProductRecordType == domain.RecordTypeReturnMaterial {
|
|
|
if cmd.Status == domain.ProductRecordNotApprove {
|
|
|
cmd.Status = domain.ProductRecordNotApprove
|
|
|
if xtime.IsZero(cmd.ProductBeginTime) || xtime.BeforeEqual(cmd.ProductBeginTime, xtime.BeginningOfDay()) {
|
...
|
...
|
@@ -106,6 +107,7 @@ func (cmd *HistoryProductRecordQuery) Valid(validation *validation.Validation) { |
|
|
cmd.Status = domain.ProductRecordLogged
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
func (cmd *HistoryProductRecordQuery) ValidateQuery() error {
|
...
|
...
|
|