public List <ENT.MainDeviceMasterSUB> CheckDuplicate(List <Guid> ParentID, COM.MyEnumration.MasterType mstType, string DeviceName) { try { if (mstType == COM.MyEnumration.MasterType.MainDeviceMaster) { QueryDisctionery.SelectPart = "SELECT TOP 1 DeviceId"; QueryDisctionery.TablePart = @"FROM MainDeviceMaster "; QueryDisctionery.ParameterPart += " WHERE DeviceName ='" + DeviceName + "' "; } using (SqlDataReader dr = objDBHelper.ExecuteReaderQuery(QueryDisctionery, parFields, objEntity)) { lstEntity = COM.DBHelper.CopyDataReaderToEntity <ENT.MainDeviceMasterSUB>(dr); objDBHelper.Disposed(); } } catch { throw; } finally { parFields.Clear(); } return(lstEntity); }
public List <ENT.PlantMasterSUB> CheckDuplicateMOBILE(List <Guid> ParentID, COM.MyEnumration.MasterType mstType, string PlantName, string Person, string mobile, string EmailId) { try { if (mstType == COM.MyEnumration.MasterType.PlantMaster) { QueryDisctionery.SelectPart = "SELECT TOP 1 PlantId"; QueryDisctionery.TablePart = @"FROM PlantMaster "; QueryDisctionery.ParameterPart += " WHERE Mobile ='" + mobile + "'"; } using (SqlDataReader dr = objDBHelper.ExecuteReaderQuery(QueryDisctionery, parFields, objEntity)) { lstEntity = COM.DBHelper.CopyDataReaderToEntity <ENT.PlantMasterSUB>(dr); objDBHelper.Disposed(); } } catch (Exception ex) { } finally { parFields.Clear(); } return(lstEntity); }
public List <ENT.PlantMasterSUB> CheckDuplicateEmail(List <Guid> ParentID, COM.MyEnumration.MasterType mstType, string PlantName, string Person, string Mobile, string Email) { lstEntity = new List <ENT.PlantMasterSUB>(); lstEntity = clsDAL.CheckDuplicateEMAIL(ParentID, mstType, PlantName, Person, Mobile, Email); return(lstEntity); }
public List <ENT.MainDeviceMasterSUB> CheckDuplicateSerialNo(List <Guid> ParentID, COM.MyEnumration.MasterType mstType, string SerialNo) { lstEntity = new List <ENT.MainDeviceMasterSUB>(); lstEntity = clsDAL.CheckDuplicateSERIALNO(ParentID, mstType, SerialNo); return(lstEntity); }
public List <ENT.MainDeviceMasterSUB> CheckDuplicateCombination(List <Guid> ParentID, COM.MyEnumration.MasterType mstType, string DeviceName) { lstEntity = new List <ENT.MainDeviceMasterSUB>(); lstEntity = clsDAL.CheckDuplicate(ParentID, mstType, DeviceName); return(lstEntity); }