public CheckUnitExistSelect(Units _Units) { this.Units = _Units; Command = @"SELECT deviceID FROM tblUnits WHERE comID = :comID AND" + @" (deviceID = coalesce(:unitID,0) OR unitName = :unitName) AND" + @" coalesce(isDelete,'0') != '1';"; }
public static void fillListBox(System.Web.UI.WebControls.ListBox _lst, int _comID) { try { Units _unit=new Units(); UnitInfoSelect _unitSelect = new UnitInfoSelect(); _unitSelect.ComID = _comID; _unitSelect.UnitListBoxItems(_unit._ListItems); _lst.DataSource = _unit._ListItems; _lst.DataTextField = "Name"; _lst.DataValueField = "Value"; _lst.DataBind(); } catch (Exception ex) { throw ex; } finally { _lst = null; } }
public UnitNameSelect(Units _unit, string userID) { this._units = _unit; Command = "SELECT unitID,unitName FROM tblUnits WHERE comID = :comID" + " AND coalesce(isDelete,'0') != '1' AND unitID = (SELECT DISTINCT" + " unitID FROM tblUnitUserWise WHERE uID = " + userID + " AND tblUnitUserWise.unitID" + " = tblUnits.unitID) ORDER BY unitName ASC;"; }
public TreeColor2(Units _unit) { this.Units = _unit; Command = @"SELECT coalescerulesID, '0') AS rulesID FROM tblUnitWiseRules WHERE unitID = :unitID AND isActive='1';" + @"SELECT coalesce(geofenceID, '0') AS geofenceID FROM tblUnitWiseRules" + @" WHERE unitID = :unitID and isGeofenceActive = '1';"; }
public TreeColor1(Units _unit) { this.Units = _unit; Command = @"SELECT DISTINCT CAST(velocity*0.621 as int) AS velocity,recTimeRevised,recTime,lat,long FROM tblGPRS" + @" WHERE recTime = (SELECT MAX(recTime) FROM tblGPRS" + @" WHERE deviceID = (SELECTdeviceID FROM tblUnits" + @" WHERE unitID = :unitID)) AND deviceID = (SELECT deviceID FROM tblUnits WHERE unitID = :unitID);"; }
/// <summary> /// load dropdownlist /// </summary> /// <param name="ddl">System.Web.UI.WebControls.DropDownList ddl</param> public static void fillDropDownItems(System.Web.UI.WebControls.DropDownList ddl, string comID, string type) { try { RulesData _r = new RulesData(); Geofence _g = new Geofence(); Units _u = new Units(); if (type == "rules") { new RulesDataSelect().RulesDropDownList(_r._dropDownList, comID); ddl.DataSource = _r._dropDownList; ddl.DataTextField = "Name"; ddl.DataValueField = "Value"; ddl.DataBind(); } else if ( type == "geo") { new RulesDataSelect("geo").GeoDropDownList(_g._dropDownList, comID); ddl.DataSource = _g._dropDownList; ddl.DataTextField = "Name"; ddl.DataValueField = "Value"; ddl.DataBind(); } else if (type == "units") { new RulesDataSelect("units").UnitsDropDownList(_u._dropDownList, comID); ddl.DataSource = _u._dropDownList; ddl.DataTextField = "Name"; ddl.DataValueField = "Value"; ddl.DataBind(); } } catch (Exception ex) { throw ex; } finally { ddl = null; } }
public static void fillDropDownItemsDeviceID(System.Web.UI.WebControls.DropDownList ddl, Units _Units) { try { Units _Unit = new Units(); _Unit = _Units; new DeviceIDSelect(_Unit).DeviceNameDropDownList(_Unit._dropDownList); ddl.DataSource = _Unit._dropDownList; ddl.DataTextField = "Name"; ddl.DataValueField = "Value"; ddl.DataBind(); } catch (Exception ex) { throw ex; } finally { ddl = null; } }
public void deleteUnitUserInfo() { UnitUserInfoDelete _DeleteData = new UnitUserInfoDelete(); try { _DeleteData.Units = this._Units; _DeleteData.deleteUserUnits(); } catch (Exception ex) { throw new Exception(" UpdateData :: UpdateUnit " + ex.Message); } finally { _DeleteData = null; _Units = null; } }
public DeviceIDSelect(Units _unit) { this.Units = _unit; Command = @"SELECT unitID,unitName FROM tblUnits a INNER JOINtblUnitType t" + @" ON t.typeID = a.typeID WHERE t.comID = :comID;"; }
public UnitInfoSelect(Units _Units) { this.Units = _Units; Command = "SELECT * FROM tblUnits WHERE unitID = :unitID AND coalesce(isDelete,'0') != '1'" + " ORDER BY unitName;"; }
public UnitNameSelect(Units _unit) { this._units = _unit; Command = "SELECT unitID,unitName FROM tblUnits WHERE comID = :comID" + " AND coalesce(isDelete,'0') != '1' ORDER BY unitName ASC;"; }
public UnitInfoDelete(Units _Units) { this.Units = _Units; Command = StoredProcedure.Name.SP_DELETE_UNIT_INFO.ToString(); }
public makeInsertParamforUnitData(Units _Unit) { this._Unit = _Unit; build(); }
public void LoadNotListedUnits(System.Web.UI.WebControls.ListBox LstBox) { NotListedUnitsSelect _notListedUnits = new NotListedUnitsSelect(); Units _unit = new Units(); try { _notListedUnits.PatternID = this._PatternID; _notListedUnits.ComID = this._comID; _notListedUnits.LoadNotListedUnitsForSupply(_unit._ListItems); LstBox.DataSource = _unit._ListItems; LstBox.DataTextField = "Name"; LstBox.DataValueField = "Value"; LstBox.DataBind(); } catch (Exception ex) { ex.Message.ToString(); } }
public static void fillDropDownItemsUserUnits(System.Web.UI.WebControls.DropDownList ddl, Units _Units, string userID) { try { Units _Unit = new Units(); _Unit = _Units; new UnitNameSelect(_Unit, userID).UnitNameDropDownList(_Unit._dropDownList); ddl.DataSource = _Unit._dropDownList; ddl.DataTextField = "Name"; ddl.DataValueField = "Value"; ddl.DataBind(); } catch (Exception ex) { throw ex; } finally { ddl = null; } }
public void addUnitUserInfo() { UnitsUserInfoInsert _insData = new UnitsUserInfoInsert(); try { _insData.Units = this._Units; _insData.addUnitUserInfo(); } catch (Exception ex) { throw new Exception(" UnitsUserInfoInsert :: addUnitUserInfo " + ex.Message); } finally { _insData = null; _Units = null; } }
public ProcessUnitManagementQueries(Units _units) { this.Units = _units; }
public makeUpdateParamforUnitData(Units _Unit) { this._Unit = _Unit; build(); }
public void updateUnitUserInfo() { UnitUserInfoUpdate _UpData = new UnitUserInfoUpdate(); try { _UpData.Units = this._Units; _UpData.updateUnitUserInfo(); } catch (Exception ex) { throw new Exception(" UnitsUserInfoUpdate :: updateUnitUserInfo " + ex.Message); } finally { _UpData = null; _Units = null; } }
public LoadImageSelect(Units _iconSetUp) { this.Units = _iconSetUp; Command = @"SELECT iconName FROM tblUnits WHERE unitID = :unitID AND comID = :comID;"; }
private void addUnitInfo() { UnitsInfoInsert _insData = new UnitsInfoInsert(); try { _insData.Units = this._Units; _insData.addUnitInfo(); } catch (Exception ex) { throw new Exception(" ProcessUser :: addUser " + ex.Message); } finally { _insData = null; _Units = null; } }
public makeParamforUnitUserData(Units _Unit) { this._Unit = _Unit; build(); }
private void updateUnitInfo() { UnitsInfoUpdate _UpdateData = new UnitsInfoUpdate(); try { _UpdateData.Units = this._Units; _UpdateData.UpdateUnitInfo(); } catch (Exception ex) { throw new Exception(" UpdateData :: UpdateUnit " + ex.Message); } finally { _UpdateData = null; _Units = null; } }
public CheckUnitExistSelect(Units _Units, string up) { this.Units = _Units; Command = StoredProcedure.Name.SP_CHECK_INFO_FOR_UPDATE.ToString(); }
public UnitUpdate(Units _unit) { this.Unit = _unit; Command = StoredProcedure.Name.SP_UPDATE_UNIT.ToString(); }