Skip to content

Commit

Permalink
Fix printForm declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
vanoudt committed Aug 9, 2016
1 parent 18289ba commit 6c414e9
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions db_objects/note_template.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ protected static function _getFields()
* @see DB_Object::printForm()
* @param string $prefix
*/
function printForm($prefix='')
function printForm($prefix='', $fields=NULL)
{
$this->fields['fields'] = Array();
parent::printForm();
Expand Down Expand Up @@ -97,7 +97,7 @@ private function _printFieldsConfiguration()
<small>When a note is added to a person using this template, the user will be prompted for the
following fields. Values that the user supplies for "independent" fields will be saved
only within the note. Values for "person" fields are will be saved within the note and will also
update the corresponding
update the corresponding
<a href="<?php build_url(Array('view' => 'admin__custom_fields')); ?>">custom field</a>
in the person record.</small>

Expand All @@ -116,10 +116,10 @@ private function _printFieldsConfiguration()
<?php
$i = 0;
$dummyField = new Note_Template_Field();

// Hack this field because we don't want 'empty' in the dropdown.
$dummyField->fields['customfieldid']['allow_empty'] = FALSE;

$fields += Array(0 => Array());
foreach ($fields as $id => $field) {
$prefix = 'fields_'.$i.'_';
Expand Down Expand Up @@ -404,6 +404,6 @@ public static function printTemplateChooserRow($selectedID)
</div>
<hr />
<?php
}
}
}
}
}

0 comments on commit 6c414e9

Please sign in to comment.