|
|
@ -67,7 +67,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
var ls = _repository.Where(p => p.InvGroupNum == p_billNum).ToList(); |
|
|
|
if (ls == null && ls.Count ==0) |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", string.Format("不存在编号为{0}",p_billNum)); |
|
|
|
throw new UserFriendlyException( string.Format("不存在编号为{0}",p_billNum)); |
|
|
|
} |
|
|
|
foreach (PUB_CAN_SA p_entiy in ls) |
|
|
|
{ |
|
|
@ -80,7 +80,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是【商务已审核】,无法设置成【财务已审核】状态"); |
|
|
|
throw new UserFriendlyException( "当前状态不是【商务已审核】,无法设置成【财务已审核】状态"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.商务已审核: |
|
|
@ -90,7 +90,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是【已开票】状态,无法设置成【商务已审核】"); |
|
|
|
throw new UserFriendlyException( "当前状态不是【已开票】状态,无法设置成【商务已审核】"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.已开票: |
|
|
@ -100,7 +100,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是【未结状态】状态,无法设置成【已开票】"); |
|
|
|
throw new UserFriendlyException( "当前状态不是【未结状态】状态,无法设置成【已开票】"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.已扣减: |
|
|
@ -110,7 +110,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是[客户收票],无法设置成【财务已审核】状态"); |
|
|
|
throw new UserFriendlyException( "当前状态不是[客户收票],无法设置成【财务已审核】状态"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.客户已收票: |
|
|
@ -120,7 +120,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是[财务已审核],无法设置成【客户已收票】状态"); |
|
|
|
throw new UserFriendlyException( "当前状态不是[财务已审核],无法设置成【客户已收票】状态"); |
|
|
|
} |
|
|
|
break; |
|
|
|
} |
|
|
@ -142,7 +142,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
var ls = _repository.Where(p => p.InvGroupNum == p_billNum).ToList(); |
|
|
|
if (ls == null && ls.Count == 0) |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", string.Format("不存在发票分组号为{0}的可结算单", p_billNum)); |
|
|
|
throw new UserFriendlyException( string.Format("不存在发票分组号为{0}的可结算单", p_billNum)); |
|
|
|
} |
|
|
|
foreach (PUB_CAN_SA p_entiy in ls) |
|
|
|
{ |
|
|
@ -156,7 +156,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是【财务已审核】,无法设置成【商务已审核】状态"); |
|
|
|
throw new UserFriendlyException( "当前状态不是【财务已审核】,无法设置成【商务已审核】状态"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.已开票: |
|
|
@ -166,7 +166,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是【商务已审核】状态,无法设置成【已开票】"); |
|
|
|
throw new UserFriendlyException( "当前状态不是【商务已审核】状态,无法设置成【已开票】"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.未结状态: |
|
|
@ -176,7 +176,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是【已开票】状态,无法设置成【未结状态】"); |
|
|
|
throw new UserFriendlyException( "当前状态不是【已开票】状态,无法设置成【未结状态】"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.客户已收票: |
|
|
@ -186,7 +186,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是[财务已审核],无法设置成【财务已审核客户收票】状态"); |
|
|
|
throw new UserFriendlyException( "当前状态不是[财务已审核],无法设置成【财务已审核客户收票】状态"); |
|
|
|
} |
|
|
|
break; |
|
|
|
case SettleBillState.财务已审核: |
|
|
@ -196,7 +196,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
throw new BusinessException("8989", "当前状态不是[客户已收票],无法设置成【财务已审核】状态"); |
|
|
|
throw new UserFriendlyException( "当前状态不是[客户已收票],无法设置成【财务已审核】状态"); |
|
|
|
} |
|
|
|
break; |
|
|
|
} |
|
|
|