Beispiel #1
0
        public string UpdateAssetDetail(string assetDetailId, string payout, string price)
        {
            string strResult = string.Empty;

            try
            {
                ForexBO objForexBO = new ForexBO();
                objForexBO.AssetDetailId = Convert.ToInt32(assetDetailId);
                objForexBO.Payout        = Convert.ToInt32(payout);
                objForexBO.Price         = Convert.ToDouble(price);
                //double upper_Limit = 0.0;
                //if (upperLimit != "")
                //    objForexBO.UpperLimit = float.Parse(upperLimit);
                //else
                //    objForexBO.UpperLimit = (float)upper_Limit;

                // 1 for success
                strResult = new ForexBL().UpdateAssetDetail(objForexBO);
            }
            catch (Exception ex)
            {
                strResult = "5"; // Exception
            }
            return(strResult);
        }
Beispiel #2
0
        public string ActiveInactiveAsset(string assetId)
        {
            string strResult = string.Empty;

            try
            {
                var myGuid = new Guid();
                if (Guid.TryParse(assetId, out myGuid))
                {
                    // Parsed OK
                }

                // 1 for success
                strResult = new ForexBL().ActiveInactiveAsset(myGuid);
                if (strResult == "1")
                {
                    strResult = "Update";
                }
                else
                {
                    strResult = "NoUpdate";
                }
            }
            catch (Exception ex)
            {
                strResult = "5"; // Exception
            }
            return(strResult);
        }
Beispiel #3
0
        public List <ForexBO> GetGridDataByTradingType(string assetTypeId, string tradingTypeId, string pageNumber, string pageSize, string sort, string searchText)
        {
            try
            {
                if (string.IsNullOrEmpty(pageNumber))
                {
                    pageNumber = "0";
                }

                if (string.IsNullOrEmpty(pageSize))
                {
                    pageSize = "0";
                }

                List <ForexBO> lstForexBO = new ForexBL().GetGridDataByTradingType(Convert.ToInt32(assetTypeId), Convert.ToInt32(tradingTypeId), Convert.ToInt32(pageNumber), Convert.ToInt32(pageSize), sort, searchText);
                return(lstForexBO);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }