/// <summary>
        /// Description  : To Get ECE Details by WOID.
        /// Created By   : Shiva  
        /// Created Date : 3rd Sep 2014
        /// Modified By  :
        /// Modified Date:
        /// </summary>
        /// <returns>ECE Details.</returns>
        public static WOExistingClientEngaging GetWOECEDetailsByWOID(int WOID)
        {
            var WOECEData = new WOExistingClientEngaging();

            System.Diagnostics.StackFrame stackFrame = new System.Diagnostics.StackFrame();
            System.Reflection.MethodBase methodBase = stackFrame.GetMethod();
            log.Debug("Start: " + methodBase.Name);
            try
            {
                SqlParameter[] sqlParams = new SqlParameter[1];
                sqlParams[0] = new SqlParameter("@WOID", WOID);
                var reader = SqlHelper.ExecuteReader(CSS2.Models.ConnectionUtility.GetConnectionString(), CommandType.StoredProcedure, "SPGetWOECEDetailsByWOID", sqlParams);
                var safe = new SafeDataReader(reader);
                while (reader.Read())
                {
                    WOECEData.FetchECEDetails(WOECEData, safe);
                }

                return WOECEData;
            }
            catch (Exception ex)
            {
                log.Error("Error: " + ex);
                return WOECEData;
            }
            finally
            {
                log.Debug("End: " + methodBase.Name);
            }
        }
        private WOExistingClientEngaging FetchECEDetails(WOExistingClientEngaging ECEData, SafeDataReader dr)
        {
            ECEData.Currency = dr.GetInt32("Currency");
            ECEData.ClassOfShare = dr.GetInt32("ClassOfShare");
            ECEData.NewAllottedShares = dr.GetString("NewAllottedShares");
            ECEData.EachShare = dr.GetString("ConsiderationOfEachShare");
            ECEData.AmountPaidToEachShare = dr.GetString("AmountPaidToEachShare");
            ECEData.TotalConsideration = dr.GetString("TotalConsideration");
            ECEData.NoOfIssuedShares = dr.GetString("ResultantNoOfIssuedShares");
            ECEData.IssuedCapital = dr.GetString("IssuedCapital");
            ECEData.MeetingNoticeSource = dr.GetString("MeetingNoticeSource");
            ECEData.MeetingNotice = dr.GetInt32("MeetingNotice");
            ECEData.MeetingMinutesSource = dr.GetString("MeetingMinutesSource");
            ECEData.MeetingMinutes = dr.GetInt32("MeetingMinutes");
            ECEData.OthersMeetingMinutes = dr.GetString("OthersMeetingMinutes");
            ECEData.Designation = dr.GetString("Designation");
            ECEData.NoticeResolutionSource = dr.GetString("NoticeResolutionSource");
            ECEData.NoticeResolution = dr.GetInt32("NoticeResolution");
            ECEData.F24F25Source = dr.GetString("F24F25Source");
            ECEData.F24F25ID = dr.GetInt32("F24F25ID");
            ECEData.ShareHoldingStructure = dr.GetInt32("ShareHoldingStructure");
            ECEData.ResultantPaidupCapital = dr.GetString("ResultantPaidupCapital");

            ECEData.IsROPlaceOfMeeting = dr.GetBoolean("IsROPlaceOfMeeting");
            ECEData.MAddressLine1 = dr.GetString("MeetingAddressLine1");
            ECEData.MAddressLine2 = dr.GetString("MeetingAddressLine2");
            ECEData.MAddressLine3 = dr.GetString("MeetingAddressLine3");
            ECEData.MAddressCountry = dr.GetInt32("MAddressCountry");
            ECEData.MAddressPostalCode = dr.GetString("MPostalCode");

            return ECEData;
        }
Ejemplo n.º 3
0
        public JsonResult SaveWOECEDetailsByWOID(WOExistingClientEngaging ECEData)
        {
            System.Diagnostics.StackFrame stackFrame = new System.Diagnostics.StackFrame();
            System.Reflection.MethodBase methodBase = stackFrame.GetMethod();
            log.Debug("Start: " + methodBase.Name);
            try
            {
                int checkSession = UserLogin.AuthenticateRequest();
                if (checkSession == 0)
                {
                    return Json(checkSession);
                }
                else
                {
                    var CompanyDetails = new WOExistingClientEngaging()
                    {
                        WOID = ECEData.WOID,
                        Currency = ECEData.Currency,
                        ClassOfShare = ECEData.ClassOfShare,
                        NewAllottedShares = ECEData.NewAllottedShares,
                        EachShare = ECEData.EachShare,
                        AmountPaidToEachShare = ECEData.AmountPaidToEachShare,
                        TotalConsideration = ECEData.TotalConsideration,
                        NoOfIssuedShares = ECEData.NoOfIssuedShares,
                        IssuedCapital = ECEData.IssuedCapital,
                        ResultantPaidupCapital = ECEData.ResultantPaidupCapital,
                        MeetingNoticeSource = ECEData.MeetingNoticeSource,
                        MeetingNotice = ECEData.MeetingNotice,
                        MeetingMinutesSource = ECEData.MeetingMinutesSource,
                        MeetingMinutes = ECEData.MeetingMinutes,
                        OthersMeetingMinutes = ECEData.OthersMeetingMinutes,
                        Designation = ECEData.Designation,
                        NoticeResolutionSource = ECEData.NoticeResolutionSource,
                        NoticeResolution = ECEData.NoticeResolution,
                        F24F25Source = ECEData.F24F25Source,
                        F24F25ID = ECEData.F24F25ID,
                        ShareHoldingStructure = ECEData.ShareHoldingStructure,

                        IsROPlaceOfMeeting = ECEData.IsROPlaceOfMeeting,
                        MAddressLine1 = ECEData.MAddressLine1,
                        MAddressLine2 = ECEData.MAddressLine2,
                        MAddressLine3 = ECEData.MAddressLine3,
                        MAddressCountry = ECEData.MAddressCountry,
                        MAddressPostalCode = ECEData.MAddressPostalCode,

                        SavedBy = checkSession
                    };
                    checkSession = CompanyDetails.SaveWOECEDetails();
                    return Json(checkSession);
                }
            }
            catch (Exception ex)
            {
                log.Error("Error: " + ex);
                return Json("");
            }
            finally
            {
                log.Debug("End: " + methodBase.Name);
            }
        }