Exemplo n.º 1
0
        public static object GenerateTrnObject(string strTradeDate
                                               , string strBuySell
                                               , string strInstrument
                                               , string strCtpy
                                               , string strPortfolio
                                               , string strSettlementDate
                                               , string strYield
                                               , string strUnit
                                               , string strCleanPrice
                                               , string strGrossPrice
                                               , string strNotional
                                               , string strCCY
                                               , string strPceFlag
                                               , string strSettleFlag
                                               , string strYeildType
                                               , string strReportBy
                                               , string strPurpose
                                               , string strTerm
                                               , string strRate
                                               , string strTBMARemark
                                               , string strRemark
                                               , string strProductId
                                               , bool blnIsSubmit)
        {
            try
            {
                DA_TRN TrnInfo = DealUIP.GenerateFITransactionObject(SessionInfo
                                                                     , strTradeDate
                                                                     , strBuySell
                                                                     , strInstrument
                                                                     , strCtpy
                                                                     , strPortfolio
                                                                     , strSettlementDate
                                                                     , strYield
                                                                     , strUnit
                                                                     , strCleanPrice
                                                                     , strGrossPrice
                                                                     , strNotional
                                                                     , strCCY
                                                                     , strPceFlag
                                                                     , strSettleFlag
                                                                     , strYeildType
                                                                     , strReportBy
                                                                     , strPurpose
                                                                     , strTerm
                                                                     , strRate
                                                                     , strTBMARemark
                                                                     , strRemark
                                                                     , strProductId);


                object PCESCEObject;
                CheckFILimit(blnIsSubmit, TrnInfo, out PCESCEObject);
                return(new { Result = "OK",
                             record = JsonConvert.SerializeObject(TrnInfo, new IsoDateTimeConverter()),
                             pcesce = PCESCEObject,
                             Message = "" });
            }
            catch (Exception ex)
            {
                return(new { Result = "ERROR", Message = ex.Message });
            }
        }