Ejemplo n.º 1
0
        public void GetEffluentTreatmentPlantDetails(int EffluentTreatmentPlantId)
        {
            DataSet DS = new DataSet();

            bftp = new BEffluentTreatmentPlant();
            DS   = bftp.GetEffluentTreatmentPlantDetailsById(EffluentTreatmentPlantId);
            if (!Comman.Comman.IsDataSetEmpty(DS))
            {
                string   DATE  = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["EffluentTreatmentPlantDate"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["EffluentTreatmentPlantDate"].ToString();
                DateTime date1 = Convert.ToDateTime(DATE, System.Globalization.CultureInfo.GetCultureInfo("ur-PK").DateTimeFormat);
                txtDate.Text = (Convert.ToDateTime(date1).ToString("yyyy-MM-dd"));
                dpShiftDetails.ClearSelection();
                if (dpShiftDetails.Items.FindByValue(Convert.ToInt32(DS.Tables[0].Rows[0]["EffluentTreatmentPlantShiftId"]).ToString()) != null)
                {
                    dpShiftDetails.Items.FindByValue(Convert.ToInt32(DS.Tables[0].Rows[0]["EffluentTreatmentPlantShiftId"]).ToString()).Selected = true;
                }
                txtOperatedBy.Text                           = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["OperatedBy"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["OperatedBy"].ToString();
                txtRemarks.Text                              = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["Remarks"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["Remarks"].ToString();
                txtAStartingTime.Text                        = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["CollectionPumpAStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["CollectionPumpAStartingTime"].ToString();
                txtAEndTime.Text                             = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["CollectionPumpAEndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["CollectionPumpAEndTime"].ToString();
                txtATotalHours.Text                          = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["CollectionPumpATotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["CollectionPumpATotalRunningHours"].ToString();
                txtBStartingTime.Text                        = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["CollectionPumpBStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["CollectionPumpBStartingTime"].ToString();
                txtBEndTime.Text                             = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["CollectionPumpBEndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["CollectionPumpBEndTime"].ToString();
                txtBTotalHours.Text                          = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["CollectionPumpBTotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["CollectionPumpBTotalRunningHours"].ToString();
                txtAERATORStartingTime.Text                  = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["AERATORStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["AERATORStartingTime"].ToString();
                txtAERATOREndTime.Text                       = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["AERATOREndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["AERATOREndTime"].ToString();
                txtAERATORTotalHours.Text                    = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["AERATORTotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["AERATORTotalRunningHours"].ToString();
                txtBLOWERAStartingTime.Text                  = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["BLOWERAStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["BLOWERAStartingTime"].ToString();
                txtBLOWERAEndTime.Text                       = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["BLOWERAEndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["BLOWERAEndTime"].ToString();
                txtBLOWERATotalHours.Text                    = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["BLOWERATotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["BLOWERATotalRunningHours"].ToString();
                txtBLOWERBStartingTime.Text                  = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["BLOWERBStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["BLOWERBStartingTime"].ToString();
                txtBLOWERBEndTime.Text                       = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["BLOWERBEndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["BLOWERBEndTime"].ToString();
                txtBLOWERBTotalHours.Text                    = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["BLOWERBTotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["BLOWERBTotalRunningHours"].ToString();
                txtClarifierMechanismStartingTime.Text       = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["ClarifierMechanismStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["ClarifierMechanismStartingTime"].ToString();
                txtClarifierMechanismEndTime.Text            = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["ClarifierMechanismEndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["ClarifierMechanismEndTime"].ToString();
                txtClarifierMechanismTotalHours.Text         = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["ClarifierMechanismTotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["ClarifierMechanismTotalRunningHours"].ToString();
                txtSludgeReCirculationpumpAStartingTime.Text = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["SludgeReCirculationPumpAStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["SludgeReCirculationPumpAStartingTime"].ToString();
                txtSludgeReCirculationpumpAEndTime.Text      = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["SludgeReCirculationPumpAEndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["SludgeReCirculationPumpAEndTime"].ToString();
                txtSludgeReCirculationpumpATotalHours.Text   = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["SludgeReCirculationPumpATotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["SludgeReCirculationPumpATotalRunningHours"].ToString();
                txtSludgeReCirculationpumpBStartingTime.Text = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["SludgeReCirculationPumpBStartingTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["SludgeReCirculationPumpBStartingTime"].ToString();
                txtSludgeReCirculationpumpBEndTime.Text      = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["SludgeReCirculationPumpBEndTime"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["SludgeReCirculationPumpBEndTime"].ToString();
                txtSludgeReCirculationpumpBTotalHours.Text   = string.IsNullOrEmpty(DS.Tables[0].Rows[0]["SludgeReCirculationPumpBTotalRunningHours"].ToString()) ? string.Empty : DS.Tables[0].Rows[0]["SludgeReCirculationPumpBTotalRunningHours"].ToString();
            }
        }