public void View(int companyID, string subStore) { //View store detail try { this.mStoreDS = new EnterpriseDS(); refreshView(); EnterpriseDS ds = new EnterpriseDS(); ds.Merge(EnterpriseFactory.GetStoreDetail(companyID, subStore)); if (ds.StoreTable.Rows.Count > 0) { this.mStoreDS = ds; } refreshView(); } catch (Exception ex) { reportError(new ControlException("Unexpected error while creating store detail view.", ex)); } }
private void showStoreDetail() { // this.mStoreDS = new EnterpriseDS(); this.txtStoreDetail.Clear(); if (this.cboCompany.SelectedValue != null && this.txtStore.Text.Length > 0) { EnterpriseDS ds = new EnterpriseDS(); switch (this.cboScope.SelectedItem.ToString()) { case SCOPE_STORES: ds.Merge(EnterpriseFactory.GetStoreDetail(Convert.ToInt32(this.cboCompany.SelectedValue), Convert.ToInt32(this.txtStore.Text))); break; case SCOPE_SUBSTORES: ds.Merge(EnterpriseFactory.GetStoreDetail(Convert.ToInt32(this.cboCompany.SelectedValue), this.txtStore.Text)); break; } if (ds.StoreTable.Rows.Count > 0) { this.mStoreDS = ds; this.txtStoreDetail.Text = getStoreDetailString(); } } }