@ -391,12 +391,14 @@ namespace DSWeb.MvcShipping.DAL.MsRptZjTotalDAL
foreach ( var head in headList )
foreach ( var head in headList )
{
{
head . ETDSTLDATE = Convert . ToDateTime ( head . ETD ) . AddDays ( days ) . ToString ( "yyyy-MM-dd" ) ;
var amountfee = 0 M ;
var amountfee = 0 M ;
if ( string . IsNullOrWhiteSpace ( head . ETD ) )
if ( string . IsNullOrWhiteSpace ( head . ETD ) )
{
{
continue ;
continue ;
}
}
var 需 计 算 资 金 成 本 的 费 用 List = feeList . Where ( x = > head . BSNO = = x . BSNO & & ( x . SETTLETIME = = null | | x . SETTLETIME > Convert . ToDateTime ( head . STLDATE) . AddDays ( days - 1 ) ) ) . ToList ( ) ;
var 需 计 算 资 金 成 本 的 费 用 List = feeList . Where ( x = > head . BSNO = = x . BSNO & & ( x . SETTLETIME = = null | | x . SETTLETIME > Convert . ToDateTime ( head . ETD STLDATE) ) ) . ToList ( ) ;
if ( 需 计 算 资 金 成 本 的 费 用 List ! = null & & 需 计 算 资 金 成 本 的 费 用 List . Count > 0 )
if ( 需 计 算 资 金 成 本 的 费 用 List ! = null & & 需 计 算 资 金 成 本 的 费 用 List . Count > 0 )
{
{
@ -410,7 +412,7 @@ namespace DSWeb.MvcShipping.DAL.MsRptZjTotalDAL
//feedays = (DateTime.Now - Convert.ToDateTime(head.STLDATE)).Days ;
//feedays = (DateTime.Now - Convert.ToDateTime(head.STLDATE)).Days ;
amountfee + = feedays * Convert . ToDecimal ( item . EXCHANGERATE * item . AMOUNT * 0.12 M / 365 ) ;
amountfee + = feedays * Convert . ToDecimal ( item . EXCHANGERATE * item . AMOUNT * 0.12 M / 365 ) ;
head . STLDATE = Convert . ToDateTime ( head . ETD ) . AddDays ( days ) . ToString ( "yyyy-MM-dd" ) ;
//head.STLDATE = Convert.ToDateTime(head.ETD).AddDays(days).ToString("yyyy-MM-dd") ;
head . ExceedDays = feedays ;
head . ExceedDays = feedays ;
}
}
else
else
@ -421,7 +423,7 @@ namespace DSWeb.MvcShipping.DAL.MsRptZjTotalDAL
//feedays = ((DateTime)item.SETTLETIME - Convert.ToDateTime(head.STLDATE)).Days;
//feedays = ((DateTime)item.SETTLETIME - Convert.ToDateTime(head.STLDATE)).Days;
amountfee + = feedays * Convert . ToDecimal ( ( item . SETTLEAMOUNT ) * 0.12 M / 365 ) ;
amountfee + = feedays * Convert . ToDecimal ( ( item . SETTLEAMOUNT ) * 0.12 M / 365 ) ;
head . STLDATE = Convert . ToDateTime ( head . ETD ) . AddDays ( days ) . ToString ( "yyyy-MM-dd" ) ;
//head.STLDATE = Convert.ToDateTime(head.ETD).AddDays(days).ToString("yyyy-MM-dd") ;
head . ExceedDays = feedays ;
head . ExceedDays = feedays ;
}
}
else
else
@ -430,7 +432,7 @@ namespace DSWeb.MvcShipping.DAL.MsRptZjTotalDAL
//feedays = ((DateTime)item.SETTLETIME - Convert.ToDateTime(head.STLDATE)).Days;
//feedays = ((DateTime)item.SETTLETIME - Convert.ToDateTime(head.STLDATE)).Days;
amountfee + = feedays * Convert . ToDecimal ( ( item . SETTLEAMOUNT ) * 0.12 M / 365 ) ;
amountfee + = feedays * Convert . ToDecimal ( ( item . SETTLEAMOUNT ) * 0.12 M / 365 ) ;
head . STLDATE = Convert . ToDateTime ( head . ETD ) . AddDays ( days ) . ToString ( "yyyy-MM-dd" ) ;
//head.STLDATE = Convert.ToDateTime(head.ETD).AddDays(days).ToString("yyyy-MM-dd") ;
feedays = ( DateTime . Now - Convert . ToDateTime ( head . ETD ) ) . Days - days ;
feedays = ( DateTime . Now - Convert . ToDateTime ( head . ETD ) ) . Days - days ;
//feedays = (DateTime.Now - Convert.ToDateTime(head.STLDATE)).Days;
//feedays = (DateTime.Now - Convert.ToDateTime(head.STLDATE)).Days;