gd-sprest-bs 9.5.5 → 9.5.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -766,31 +766,37 @@ exports.ListForm.renderEditForm = function (props) {
766
766
  appendControls: function (controls) {
767
767
  // Append the controls
768
768
  form.appendControls(controls);
769
- // Parse the new controls
770
- for (var i = 0; i < controls.length; i++) {
771
- var control = controls[i].name ? form.getControl(controls[i].name) : null;
772
- if (control) {
773
- // Append the control
774
- customControls.push(control);
769
+ // Wait for the controls to be loaded
770
+ setTimeout(function () {
771
+ // Parse the new controls
772
+ for (var i = 0; i < controls.length; i++) {
773
+ var control = controls[i].name ? form.getControl(controls[i].name) : null;
774
+ if (control) {
775
+ // Append the control
776
+ customControls.push(control);
777
+ }
775
778
  }
776
- }
779
+ }, 10);
777
780
  },
778
781
  appendRows: function (rows) {
779
782
  // Append the controls
780
783
  form.appendRows(rows);
781
- // Parse the rows
782
- for (var i = 0; i < rows.length; i++) {
783
- // Parse the columns
784
- var columns = rows[i].columns;
785
- for (var j = 0; j < columns.length; j++) {
786
- // Get the control
787
- var control = columns[j].control && columns[j].control.name ? form.getControl(columns[j].control.name) : null;
788
- if (control) {
789
- // Append the control
790
- customControls.push(control);
784
+ // Wait for the controls to be loaded
785
+ setTimeout(function () {
786
+ // Parse the rows
787
+ for (var i = 0; i < rows.length; i++) {
788
+ // Parse the columns
789
+ var columns = rows[i].columns;
790
+ for (var j = 0; j < columns.length; j++) {
791
+ // Get the control
792
+ var control = columns[j].control && columns[j].control.name ? form.getControl(columns[j].control.name) : null;
793
+ if (control) {
794
+ // Append the control
795
+ customControls.push(control);
796
+ }
791
797
  }
792
798
  }
793
- }
799
+ }, 10);
794
800
  },
795
801
  el: form.el,
796
802
  getControl: function (fieldName) {