...
|
...
|
@@ -169,7 +169,8 @@ func (dividendsOrderService *DividendsOrderService) CreateDividendsOrder(createD |
|
|
// 校验产品关联合约的激励规则是否匹配订单时间
|
|
|
if cooperationContractsMap[orderGood.CooperationContractNumber] != nil {
|
|
|
for _, incentivesRule := range cooperationContractsMap[orderGood.CooperationContractNumber].DividendsIncentivesRules {
|
|
|
if (orderTime.After(incentivesRule.DividendsIncentivesStageStart) || orderTime.Equal(incentivesRule.DividendsIncentivesStageStart)) && (orderTime.Before(incentivesRule.DividendsIncentivesStageEnd) || orderTime.Equal(incentivesRule.DividendsIncentivesStageEnd)) {
|
|
|
if !((orderTime.After(incentivesRule.DividendsIncentivesStageStart) || orderTime.Equal(incentivesRule.DividendsIncentivesStageStart)) &&
|
|
|
(orderTime.Before(incentivesRule.DividendsIncentivesStageEnd) || orderTime.Equal(incentivesRule.DividendsIncentivesStageEnd))) {
|
|
|
ruleMatchedFlag = true
|
|
|
break
|
|
|
}
|
...
|
...
|
@@ -754,7 +755,8 @@ func (dividendsOrderService *DividendsOrderService) ImportDividendsOrder(importD |
|
|
// 校验产品关联合约的激励规则是否匹配订单时间
|
|
|
if cooperationContractsMap[orderGood.CooperationContractNumber] != nil {
|
|
|
for _, incentivesRule := range cooperationContractsMap[orderGood.CooperationContractNumber].DividendsIncentivesRules {
|
|
|
if (orderTime.After(incentivesRule.DividendsIncentivesStageStart) || orderTime.Equal(incentivesRule.DividendsIncentivesStageStart)) && (orderTime.Before(incentivesRule.DividendsIncentivesStageEnd) || orderTime.Equal(incentivesRule.DividendsIncentivesStageEnd)) {
|
|
|
if !((orderTime.After(incentivesRule.DividendsIncentivesStageStart) || orderTime.Equal(incentivesRule.DividendsIncentivesStageStart)) &&
|
|
|
(orderTime.Before(incentivesRule.DividendsIncentivesStageEnd) || orderTime.Equal(incentivesRule.DividendsIncentivesStageEnd))) {
|
|
|
ruleMatchedFlag = true
|
|
|
break
|
|
|
}
|
...
|
...
|
@@ -1205,7 +1207,8 @@ func (dividendsOrderService *DividendsOrderService) UpdateDividendsOrder(updateD |
|
|
// 校验产品关联合约的激励规则是否匹配订单时间
|
|
|
if cooperationContractsMap[orderGood.CooperationContractNumber] != nil {
|
|
|
for _, incentivesRule := range cooperationContractsMap[orderGood.CooperationContractNumber].DividendsIncentivesRules {
|
|
|
if (orderTime.After(incentivesRule.DividendsIncentivesStageStart) || orderTime.Equal(incentivesRule.DividendsIncentivesStageStart)) && (orderTime.Before(incentivesRule.DividendsIncentivesStageEnd) || orderTime.Equal(incentivesRule.DividendsIncentivesStageEnd)) {
|
|
|
if !((orderTime.After(incentivesRule.DividendsIncentivesStageStart) || orderTime.Equal(incentivesRule.DividendsIncentivesStageStart)) &&
|
|
|
(orderTime.Before(incentivesRule.DividendsIncentivesStageEnd) || orderTime.Equal(incentivesRule.DividendsIncentivesStageEnd))) {
|
|
|
ruleMatchedFlag = true
|
|
|
break
|
|
|
}
|
...
|
...
|
|