Пример #1
0
 /// <summary>
 /// Loads the attributes locked.
 /// </summary>
 private void LoadAttributesLocked()
 {
     Store.AssociatedAttributeCollection associatedAttributeCollection = new Store.ProductController().FetchAssociatedAttributesByProductId(productId);
     dgAttributesLocked.DataSource            = associatedAttributeCollection;
     dgAttributesLocked.Columns[0].HeaderText = LocalizationUtility.GetText("hdrSortOrder");
     dgAttributesLocked.Columns[1].HeaderText = LocalizationUtility.GetText("hdrName");
     dgAttributesLocked.Columns[2].HeaderText = LocalizationUtility.GetText("hdrIsRequired");
     dgAttributesLocked.DataBind();
 }
Пример #2
0
 /// <summary>
 /// Loads the available attributes.
 /// </summary>
 private void LoadAvailableAttributes()
 {
     Store.AttributeCollection attributeCollection = new Store.ProductController().FetchAvailableAttributesByProductId(productId);
     dgAvailableAttributes.DataSource            = attributeCollection;
     dgAvailableAttributes.ItemDataBound        += new DataGridItemEventHandler(dgAvailableAttributes_ItemDataBound);
     dgAvailableAttributes.Columns[0].HeaderText = LocalizationUtility.GetText("hdrAdd");
     dgAvailableAttributes.Columns[1].HeaderText = LocalizationUtility.GetText("hdrName");
     dgAvailableAttributes.DataBind();
 }
Пример #3
0
 /// <summary>
 /// Loads the associated attributes.
 /// </summary>
 private void LoadAssociatedAttributes()
 {
     Store.AssociatedAttributeCollection associatedAttributeCollection = new Store.ProductController().FetchAssociatedAttributesByProductId(productId);
     dgAssociatedAttributes.DataSource            = associatedAttributeCollection;
     dgAssociatedAttributes.ItemDataBound        += new DataGridItemEventHandler(dgAssociatedAttributes_ItemDataBound);
     dgAssociatedAttributes.Columns[0].HeaderText = LocalizationUtility.GetText("hdrSortOrder");
     dgAssociatedAttributes.Columns[1].HeaderText = LocalizationUtility.GetText("hdrName");
     dgAssociatedAttributes.Columns[2].HeaderText = LocalizationUtility.GetText("hdrIsRequired");
     dgAssociatedAttributes.Columns[3].HeaderText = LocalizationUtility.GetText("hdrDelete");
     dgAssociatedAttributes.DataBind();
     if (associatedAttributeCollection.Count > 0)
     {
         ImageButton lbUp = dgAssociatedAttributes.Items[0].Cells[1].FindControl("lbUp") as ImageButton;
         if (lbUp != null)
         {
             lbUp.Visible = false;
         }
         ImageButton lbDown = dgAssociatedAttributes.Items[dgAssociatedAttributes.Items.Count - 1].Cells[1].FindControl("lbDown") as ImageButton;
         if (lbDown != null)
         {
             lbDown.Visible = false;
         }
     }
 }
Пример #4
0
 /// <summary>
 /// Loads the available attributes.
 /// </summary>
 private void LoadAvailableAttributes()
 {
     Store.AttributeCollection attributeCollection = new Store.ProductController().FetchAvailableAttributesByProductId(productId);
       dgAvailableAttributes.DataSource = attributeCollection;
       dgAvailableAttributes.ItemDataBound += new DataGridItemEventHandler(dgAvailableAttributes_ItemDataBound);
       dgAvailableAttributes.Columns[0].HeaderText = LocalizationUtility.GetText("hdrAdd");
       dgAvailableAttributes.Columns[1].HeaderText = LocalizationUtility.GetText("hdrName");
       dgAvailableAttributes.DataBind();
 }
Пример #5
0
 /// <summary>
 /// Loads the attributes locked.
 /// </summary>
 private void LoadAttributesLocked()
 {
     Store.AssociatedAttributeCollection associatedAttributeCollection = new Store.ProductController().FetchAssociatedAttributesByProductId(productId);
       dgAttributesLocked.DataSource = associatedAttributeCollection;
       dgAttributesLocked.Columns[0].HeaderText = LocalizationUtility.GetText("hdrSortOrder");
       dgAttributesLocked.Columns[1].HeaderText = LocalizationUtility.GetText("hdrName");
       dgAttributesLocked.Columns[2].HeaderText = LocalizationUtility.GetText("hdrIsRequired");
       dgAttributesLocked.DataBind();
 }
Пример #6
0
 /// <summary>
 /// Loads the associated attributes.
 /// </summary>
 private void LoadAssociatedAttributes()
 {
     Store.AssociatedAttributeCollection associatedAttributeCollection = new Store.ProductController().FetchAssociatedAttributesByProductId(productId);
       dgAssociatedAttributes.DataSource = associatedAttributeCollection;
       dgAssociatedAttributes.ItemDataBound += new DataGridItemEventHandler(dgAssociatedAttributes_ItemDataBound);
       dgAssociatedAttributes.Columns[0].HeaderText = LocalizationUtility.GetText("hdrSortOrder");
       dgAssociatedAttributes.Columns[1].HeaderText = LocalizationUtility.GetText("hdrName");
       dgAssociatedAttributes.Columns[2].HeaderText = LocalizationUtility.GetText("hdrIsRequired");
       dgAssociatedAttributes.Columns[3].HeaderText = LocalizationUtility.GetText("hdrDelete");
       dgAssociatedAttributes.DataBind();
       if(associatedAttributeCollection.Count > 0) {
     ImageButton lbUp = dgAssociatedAttributes.Items[0].Cells[1].FindControl("lbUp") as ImageButton;
     if(lbUp != null) {
       lbUp.Visible = false;
     }
     ImageButton lbDown = dgAssociatedAttributes.Items[dgAssociatedAttributes.Items.Count - 1].Cells[1].FindControl("lbDown") as ImageButton;
     if(lbDown != null) {
       lbDown.Visible = false;
     }
       }
 }