protected void GetProductRequisitionById(string productRequisitionId) { ProductRequisitionBLL productRequisition = new ProductRequisitionBLL(); try { DataTable dt = productRequisition.GetProductRequisitionById(productRequisitionId); if (dt.Rows.Count > 0) { requisitionDateLabel.Text = dt.Rows[0]["RequisitionDate"].ToString(); //salesCenterIdLabel.Text = dt.Rows[0]["SalesCenterId"].ToString(); //salesCenterNameLabel.Text = dt.Rows[0]["SalesCenterName"].ToString(); warehouseIdLabel.Text = dt.Rows[0]["WarehouseId"].ToString(); warehouseNameLabel.Text = dt.Rows[0]["WarehouseName"].ToString(); narrationLabel.Text = dt.Rows[0]["Narration"].ToString(); statusLabel.Text = dt.Rows[0]["Status"].ToString(); lblCreatedBy.Text = dt.Rows[0]["CreatedUser"].ToString(); reqTypelabel.Text = dt.Rows[0]["RequisitionType"].ToString(); //CreatedUser } else { msgbox.Visible = true; msgTitleLabel.Text = "Data Not Found!!!"; msgDetailLabel.Text = ""; } } catch (Exception ex) { msgbox.Visible = true; msgTitleLabel.Text = "Exception!!!"; msgDetailLabel.Text = ex.Message; } finally { productRequisition = null; } }
protected void GetProductRequisitionById(string productRequisitionId) { ProductRequisitionBLL productRequisition = new ProductRequisitionBLL(); //spanreqsc.Attributes.Remove("class"); spanreqwh.Attributes.Remove("class"); try { DataTable dt = productRequisition.GetProductRequisitionById(productRequisitionId); if (dt.Rows.Count > 0) { requisitionDateLabel.Text = dt.Rows[0]["RequisitionDate"].ToString(); //salesCenterIdLabel.Text = dt.Rows[0]["SalesCenterId"].ToString(); //salesCenterNameLabel.Text = dt.Rows[0]["SalesCenterName"].ToString(); warehouseIdLabel.Text = dt.Rows[0]["WarehouseId"].ToString(); warehouseNameLabel.Text = dt.Rows[0]["WarehouseName"].ToString(); narrationLabel.Text = dt.Rows[0]["Narration"].ToString(); statusLabel.Text = dt.Rows[0]["Status"].ToString(); lblCreatedBy.Text = dt.Rows[0]["CreatedUser"].ToString(); reqTypelabel.Text = dt.Rows[0]["RequisitionType"].ToString(); // if (reqTypelabel.Text == "WH-SC") // { // spanreqwh.Attributes.Add("class", "text-error icon icon-upload"); // spanreqsc.Attributes.Add("class", "text-success icon icon-download-alt"); // } // else if (reqTypelabel.Text == "SC-WH") // { // spanreqsc.Attributes.Add("class", "text-error icon icon-upload"); // spanreqwh.Attributes.Add("class", "text-success icon icon-download-alt"); // } // } // else // { // msgbox.Visible = true; msgTitleLabel.Text = "Data Not Found!!!"; msgDetailLabel.Text = ""; // } //} } } catch (Exception ex) { msgbox.Visible = true; msgTitleLabel.Text = "Exception!!!"; msgDetailLabel.Text = ex.Message; } finally { productRequisition = null; } }