Beispiel #1
0
        private void AddInputToContainer(BSFormControl control)
        {
            //Reinicia a lista
            InputControls.Add(control);

            if (InputControls.Count == this.InputsByColumn)
            {
                InputContainerControls.Add(InputControls);
                InputControls = new List <BSFormControl>();
            }
        }
Beispiel #2
0
        public string GetHTML()
        {
            var html = new StringBuilder();

            html.AppendFormat("<form id = '{0}' {1} action='{2}'>", this.Id, configClass(), FormAction).AppendLine();

            InputContainerControls.Add(InputControls);
            ButtonContainerControls.Add(ButtonControls);

            //Cria uma Row para os Inputs
            html.AppendFormat("<div id='{0}' class='row'>", "Row_Inputs_Form_" + this.Id).AppendLine();
            html.Append(GetHtmlContainer(InputContainerControls)).AppendLine();
            html.AppendFormat("</div> <!-- End Row Tag ({0}) -->", "Row_Inputs_Form_" + this.Id).AppendLine();

            //Cria uma Row para os Buttons, caso tenha
            html.AppendFormat("<div id='{0}' class='row'>", "Row_Button_Form_" + this.Id).AppendLine();
            html.Append(GetHtmlContainer(ButtonContainerControls)).AppendLine();
            html.AppendFormat("</div> <!-- {0} -->", "Row_Button_Form_" + this.Id).AppendLine();

            html.AppendFormat("</form>").AppendLine();
            return(html.ToString());
        }