Inheritance: System.MarshalByRefObject, ICollection
コード例 #1
0
ファイル: FormElement.cs プロジェクト: rmsphd/HPattern
        public IBaseCollection<IHPatternInstanceElement> Fields(string tabBC)
        {
            BaseCollection<IHPatternInstanceElement> ret = new BaseCollection<IHPatternInstanceElement>();
            foreach (IHPatternInstanceElement i in this.Items)
            {
                if (i is RowElement)
                {
                    RowElement row = (RowElement)i;
                    ApplyFieldsRow(ret, row);
                }
                if (i is TabFormElement)
                {
                    TabFormElement tab = (TabFormElement)i;
                    if (tabBC == String.Empty || tab.Name == tabBC)
                    {
                        foreach (RowElement row in tab.Rows)
                        {
                            ApplyFieldsRow(ret, row);
                        }
                    }

                }
            }
            return ret;
        }
コード例 #2
0
ファイル: Template.cs プロジェクト: rmsphd/HPattern
 private static IBaseCollection<RowElement> GetRowsPP(WebObject trn, string tab, bool GridFreeStyle, bool GridStandard, WebObject trni)
 {
     // GetRows++ a revolta dos Rows :)
     IBaseCollection<RowElement> rows = new BaseCollection<RowElement>();
     if (String.IsNullOrEmpty(tab))
     {
         foreach (IHPatternInstanceElement i in trn.Form.Items)
         {
             if (i is RowElement)
             {
                 RowElement row = (RowElement)i;
                 GetRowsAllTabsPP(rows, row, GridFreeStyle, GridStandard, trni);
             }
             if (i is TabFormElement)
             {
                 TabFormElement tabe = (TabFormElement)i;
                 foreach (RowElement row in tabe.Rows)
                 {
                     GetRowsAllTabsPP(rows, row, GridFreeStyle, GridStandard, trni);
                 }
             }
         }
     }
     else
     {
         foreach (TabFormElement tabe in trn.Form.Tabs)
         {
             if (tabe.Name == tab)
             {
                 foreach (RowElement row in tabe.Rows)
                 {
                     GetRowsAllTabsPP(rows, row, GridFreeStyle, GridStandard, trni);
                 }
             }
         }
         if (rows.Count == 0)
         {
             if (trn.Form.Rows == null)
             {
                 foreach (TabFormElement tabe in trn.Form.Tabs)
                 {
                     foreach (RowElement row in tabe.Rows)
                     {
                         GetRowsAllTabsPP(rows, row, GridFreeStyle, GridStandard, trni);
                     }
                 }
             }
             else
             {
                 if (trn.Form.Rows.Count > 0)
                 {
                     foreach (RowElement row in trn.Form.Rows)
                     {
                         GetRowsAllTabsPP(rows, row, GridFreeStyle, GridStandard, trni);
                     }
                 }
                 else
                 {
                     foreach (TabFormElement tabe in trn.Form.Tabs)
                     {
                         foreach (RowElement row in tabe.Rows)
                         {
                             GetRowsAllTabsPP(rows, row, GridFreeStyle, GridStandard, trni);
                         }
                     }
                 }
             }
         }
     }
     return rows;
 }
コード例 #3
0
ファイル: Template.cs プロジェクト: rmsphd/HPattern
 private static IBaseCollection<RowElement> GetRowsAllTabs(IBaseCollection<TabFormElement> tabs, TransactionElement trni)
 {
     IBaseCollection<RowElement> rows = new BaseCollection<RowElement>();
     if (tabs != null)
     {
         foreach (TabFormElement tabe in tabs)
         {
             foreach (RowElement row in tabe.Rows)
                 rows.Add(row);
         }
     }
     return rows;
 }