Exemple #1
0
        public JsonResult GetProductsMaxCountConfig()
        {
            try
            {
                _objCurrentInfo  = new CurrentInfo();
                IConfig_Settings = new Config_Settings();
                string companyCode = _objCurrentInfo.GetCompanyCode();

                // Retrives the Max Products count value.
                string UserTypeMaxProductCount = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.INWARD,
                                                                                        CONFIG_KEY.INWARD_MAX_PRODUCT_COUNT_USERTYPEWISE);

                string UserMaxProductCount = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.INWARD,
                                                                                    CONFIG_KEY.INWARD_MAX_PRODUCT_COUNT_USERWISE);

                // Returns the Max Products Count
                Dictionary <string, string> dic = new Dictionary <string, string>();
                dic.Add("UserTypeMaxProductCount", UserTypeMaxProductCount);
                dic.Add("UserMaxProductCount", UserMaxProductCount);
                return(Json(dic));
            }
            catch
            {
                throw;
            }
        }
Exemple #2
0
        public string GetDashboardGaugeSettings()
        {
            CurrentInfo _objCurInfo = new CurrentInfo();

            IConfig_Settings = new Config_Settings();
            string companyCode = _objCurInfo.GetCompanyCode();

            // Retrives the DCR_ENTRY_TIME_GAP value.
            string gaugeRedColorFromTo = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.DASHBOARD,
                                                                                CONFIG_KEY.GAUGE_REDCOLOR_FROM_TO);
            string gaugeYellowColorFromTo = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.DASHBOARD,
                                                                                   CONFIG_KEY.GAUGE_YELLOWCOLOR_FROM_TO);
            string gaugeGreenColorFromTo = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.DASHBOARD,
                                                                                  CONFIG_KEY.GAUGE_GREENCOLOR_FROM_TO);

            return(gaugeRedColorFromTo + "_" + gaugeYellowColorFromTo + "_" + gaugeGreenColorFromTo);
        }
Exemple #3
0
        //
        // GET: /Inward/ExcelBulkUpload

        public ActionResult ExcelBulkUpload()
        {
            IConfig_Settings = new Config_Settings();
            string companyCode = _objCurrentInfo.GetCompanyCode();

            ViewBag.productTypeValue = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.INWARD,
                                                                              CONFIG_KEY.ALL_OPTION_FOR_INWARD);
            return(View());
        }
Exemple #4
0
 /// <summary>
 /// view page for Inward Adjustment
 /// </summary>
 /// <returns></returns>
 public ActionResult InwardAdjustment()
 {
     _objCurrentInfo      = new CurrentInfo();
     IConfig_Settings     = new Config_Settings();
     ViewBag.Cur_UserCode = _objCurrentInfo.GetUserCode();
     ViewBag.InwardAcknowledgementNeeded = IConfig_Settings.GetConfigDefaultValue(_objCurrentInfo.GetCompanyCode(), CONFIG_TYPE.INWARD, CONFIG_KEY.INWARD_ACKNOWLEDGEMENT_NEEDED);
     ViewBag.UserTypeName = _objCurrentInfo.GetUserTypeName();
     return(View());
 }
Exemple #5
0
        private string GetDCRDoctorVisitTimeEntryMode()
        {
            IConfig_Settings = new Config_Settings();
            string companyCode = _objcurrentInfo.GetCompanyCode();

            // Retrives the DCR_ENTRY_TIME_GAP value.
            string dcrDoctorVisitTimeEntryModeValue = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.DCR,
                                                                                             CONFIG_KEY.DCR_DOCTOR_VISIT_TIME_ENTRY_MODE);

            // Returns the dcrTimeGapValue.
            return(dcrDoctorVisitTimeEntryModeValue);
        }
Exemple #6
0
        private string GetDCREntryTimeGapValue()
        {
            IConfig_Settings = new Config_Settings();
            string companyCode = _objcurrentInfo.GetCompanyCode();

            // Retrives the DCR_ENTRY_TIME_GAP value.
            string dcrTimeGapValue = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.DCR,
                                                                            CONFIG_KEY.DCR_ENTRY_TIME_GAP);

            // Returns the dcrTimeGapValue.
            return(dcrTimeGapValue);
        }
Exemple #7
0
        public string GetDCRVersion()
        {
            IConfig_Settings = new Config_Settings();
            string companyCode = objCurr.GetCompanyCode();

            // Retrives the DCR_ENTRY_TIME_GAP value.
            string dcrTimeGapValue = IConfig_Settings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.DCR,
                                                                            CONFIG_KEY.DCR_VERSION);

            // Returns the dcrTimeGapValue.
            return(dcrTimeGapValue);
        }
Exemple #8
0
        /// <summary>
        /// Retrievs the KYD Displayed Columns.
        /// </summary>
        /// <param name="company_Code"></param>
        /// <returns></returns>
        public string GetKYDDisplayColumns(string company_Code, string key_Column, string mandatory_Columns)
        {
            _objIconfigsettings = new Config_Settings();

            //   string KeyColum = GetKYDDuplicateKeyColumnValue(company_Code);
            // string mandtoryColumns = GetKYDMandatoryColumns(company_Code, key_Column);

            string Display_Columns = _objIconfigsettings.GetConfigDefaultValue(company_Code, CONFIG_TYPE.KYD, CONFIG_KEY.KYD_DISPLAY_COLUMNS);

            string[] Display_ColumnsArr = Display_Columns.Split(',');

            //trim the unwanted spances
            if (Display_ColumnsArr.Length > 0)
            {
                for (int i = 0; i < Display_ColumnsArr.Length; i++)
                {
                    Display_ColumnsArr[i] = Display_ColumnsArr[i].Trim();
                }
            }
            // Merging Key and Mandatoty columns.
            // Key Column Exist.
            if (key_Column != null && key_Column.Length > 0)
            {
                if (Array.IndexOf(Display_ColumnsArr, key_Column) == -1)
                {
                    Display_Columns = Display_Columns + "," + key_Column;
                }
            }

            // Mandorty Columns exist.
            if (mandatory_Columns != null && mandatory_Columns.Length > 0)
            {
                string[] mandArray = mandatory_Columns.Split(',');

                for (int s = 0; s < mandArray.Length; s++)
                {
                    mandArray[s] = mandArray[s].Trim();
                }

                for (int i = 0; i < mandArray.Length; i++)
                {
                    if (Array.IndexOf(Display_ColumnsArr, mandArray[i]) == -1)
                    {
                        Display_Columns = Display_Columns + "," + mandArray[i];
                    }
                }
            }
            return(Display_Columns);
        }
Exemple #9
0
        public ActionResult InwardUploadExcelFile(HttpPostedFileBase fileUpload, string InwardDate)
        {
            DataControl.BLRegion    objBlRegion = new BLRegion();
            DataControl.CurrentInfo objCurInfo  = new CurrentInfo();
            IConfig_Settings = new Config_Settings();
            string subDomain          = objCurInfo.GetSubDomain();
            String Inward_ACK_Needeed = string.Empty;

            Inward_ACK_Needeed = IConfig_Settings.GetConfigDefaultValue(_objCurrentInfo.GetCompanyCode(), CONFIG_TYPE.INWARD, CONFIG_KEY.INWARD_ACKNOWLEDGEMENT_NEEDED);
            string result = string.Empty;

            result            = objBlRegion.InsertInwardExcelBulkUpload(objCurInfo.GetCompanyCode(), Guid.NewGuid().ToString(), fileUpload, objCurInfo.GetUserCode(), subDomain, System.Net.Dns.GetHostName().ToString(), Convert.ToDateTime(InwardDate), Inward_ACK_Needeed);
            ViewBag.ErrorCode = result;
            return(View("InwardUploadExcelFile"));
        }
Exemple #10
0
        /// <summary>
        /// Used to check KYD screen is Enabled for User Type or Not
        /// </summary>
        /// <param name="configEnable"></param>
        /// <param name="userTypeName"></param>
        /// <returns></returns>
        public string GetConfigValueforDesigantion(string companyCode, string userTypeName)
        {
            try
            {
                string configEnable = string.Empty;
                string configvaluefordesignation = string.Empty;

                //Retrive the config enable for Desigantion
                configEnable = _objIconfigsettings.GetConfigDefaultValue(companyCode, CONFIG_TYPE.KYD, CONFIG_KEY.IS_KYD_ENABLED_FOR_DESIGNATION); //Get config is enable or not

                if (!string.IsNullOrEmpty(configEnable))
                {
                    string[] configDesignation = configEnable.Split(',');
                    //trim unwanted spances
                    if (configDesignation.Length > 0)
                    {
                        for (int i = 0; i < configDesignation.Length; i++)
                        {
                            configDesignation[i] = configDesignation[i].Trim();
                        }
                    }

                    KYD_Config_Enabled _objconfigenable = new KYD_Config_Enabled();
                    if (Array.IndexOf(configDesignation, userTypeName) != -1)
                    {
                        configvaluefordesignation = "1";
                    }
                    else
                    {
                        configvaluefordesignation = "0";
                    }
                }
                else
                {
                    configvaluefordesignation = "0";
                }
                return(configvaluefordesignation);
            }
            catch
            {
                throw;
            }
        }
Exemple #11
0
        /// <summary>
        /// Retrievs the KYD Mandatory Columns.
        /// Default Value: Registration_No
        /// /// </summary>
        /// <param name="company_Code"></param>
        /// <returns></returns>
        public string GetKYDMandatoryColumns(string company_Code, string Key_Column)
        {
            _objIconfigsettings = new Config_Settings();
            string mandatory_Columns = _objIconfigsettings.GetConfigDefaultValue(company_Code, CONFIG_TYPE.KYD, CONFIG_KEY.KYD_MANDATORY_COLUMNS);

            string[] mandatory_ColumnsArr = mandatory_Columns.Trim().Split(',');
            //Trim spaces
            if (mandatory_ColumnsArr.Length > 0)
            {
                for (int i = 0; i < mandatory_ColumnsArr.Length; i++)
                {
                    mandatory_ColumnsArr[i] = mandatory_ColumnsArr[i].Trim();
                }
            }
            // Key Column Exist.
            if (Key_Column != null && Key_Column.Length > 0)
            {
                if (Array.IndexOf(mandatory_ColumnsArr, Key_Column) == -1)
                {
                    mandatory_Columns = mandatory_Columns + "," + Key_Column;
                }
            }
            return(mandatory_Columns);
        }
Exemple #12
0
 private string GetDoctorSufPreColumns(string company_Code)
 {
     IConfig_Settings = new Config_Settings();
     return(IConfig_Settings.GetConfigDefaultValue(company_Code, CONFIG_TYPE.DCR, CONFIG_KEY.DCR_DOCTOR_SUFIX_COLUMNS));
 }
Exemple #13
0
 /// <summary>
 /// Retrievs the  Duplicate Key Column value
 /// Default value is : Registration_No
 /// Possible Values: Registration_No, Mobile.
 /// </summary>
 /// <param name="company_Code"></param>
 /// <returns></returns>
 public string GetKYDDuplicateKeyColumnValue(string company_Code)
 {
     _objIconfigsettings = new Config_Settings();
     return(_objIconfigsettings.GetConfigDefaultValue(company_Code, CONFIG_TYPE.KYD, CONFIG_KEY.KYD_DOCTOR_DUPLICATE_KEY_CHECK_COLUMN));
 }