public string GetDesignationCode(JGConstant.DesignationType objDesignationType)
 {
     try
     {
         SqlDatabase database = MSSQLDataBase.Instance.GetDefaultDatabase();
         {
             DbCommand command = database.GetStoredProcCommand("UDP_GetDesignationCode");
             database.AddInParameter(command, "@DesignationID", DbType.Int32, objDesignationType);
             command.CommandType = CommandType.StoredProcedure;
             string returnValue = string.Empty;
             returnValue = Convert.ToString(database.ExecuteScalar(command));
             return(returnValue);
         }
     }
     catch (Exception ex)
     {
         return(null);
     }
 }
Beispiel #2
0
        public static string GetDesignationCode(JGConstant.DesignationType objDesignationType)
        {
            string strCode = string.Empty;

            switch (objDesignationType)
            {
            case JGConstant.DesignationType.Admin:
                strCode = "ADM";
                break;

            case JGConstant.DesignationType.Jr_Sales:
                strCode = "JSL";
                break;

            case JGConstant.DesignationType.Jr_Project_Manager:
                strCode = "JPM";
                break;

            case JGConstant.DesignationType.Office_Manager:
                strCode = "OFM";
                break;

            case JGConstant.DesignationType.Recruiter:
                strCode = "REC";
                break;

            case JGConstant.DesignationType.Sales_Manager:
                strCode = "SLM";
                break;

            case JGConstant.DesignationType.Sr_Sales:
                strCode = "SSL";
                break;

            case JGConstant.DesignationType.IT_Network_Admin:
                strCode = "ITNA";
                break;

            case JGConstant.DesignationType.IT_Jr_Net_Developer:
                strCode = "ITJN";
                break;

            case JGConstant.DesignationType.IT_Sr_Net_Developer:
                strCode = "ITSN";
                break;

            case JGConstant.DesignationType.IT_Android_Developer:
                strCode = "ITAD";
                break;

            case JGConstant.DesignationType.IT_PHP_Developer:
                strCode = "ITPH";
                break;

            case JGConstant.DesignationType.IT_SEO_OR_BackLinking:
                strCode = "ITSB";
                break;

            case JGConstant.DesignationType.Installer_Helper:
                strCode = "INH";
                break;

            case JGConstant.DesignationType.Installer_Journeyman:
                strCode = "INJ";
                break;

            case JGConstant.DesignationType.Installer_Mechanic:
                strCode = "INM";
                break;

            case JGConstant.DesignationType.Installer_Lead_Mechanic:
                strCode = "INLM";
                break;

            case JGConstant.DesignationType.Installer_Foreman:
                strCode = "INF";
                break;

            case JGConstant.DesignationType.Commercial_Only:
                strCode = "COM";
                break;

            case JGConstant.DesignationType.SubContractor:
                strCode = "SBC";
                break;

            case JGConstant.DesignationType.IT_Lead:
                strCode = "ITL";
                break;

            case JGConstant.DesignationType.Admin_Sales:
                strCode = "ASL";
                break;

            case JGConstant.DesignationType.Admin_Recruiter:
                strCode = "AREC";
                break;

            default:
                strCode = "OUID";
                break;
            }

            return(strCode);
        }
 public string GetDesignationCode(JGConstant.DesignationType objDesignationType)
 {
     return(DesignationDAL.Instance.GetDesignationCode(objDesignationType));
 }