Skip to content
Permalink
Browse files

Tidying up

  • Loading branch information...
ikawhero
ikawhero committed Mar 27, 2006
1 parent 7592c74 commit 763e8d61f47f4e5b3b33c1b1035c8c57b0232f96
Showing with 8 additions and 15 deletions.
  1. +8 −15 mod/data/field.php
@@ -288,28 +288,20 @@
print_table($table);
}
echo '<div class="fieldadd" align="center">';
echo '<form name="fieldform" action="'.$CFG->wwwroot.'/mod/data/field.php" method="get">';
echo '<input type="hidden" name="d" value="'.$data->id.'" />';
echo '<input type="hidden" name="mode" value="new" />';
echo '<input type="hidden" name="sesskey" value="'.sesskey().'" />';
echo get_string('newfield','data').': ';
choose_from_menu($menufield, 'newtype');
echo '<input type="submit" value="'.get_string('create').'" />';
popup_form($CFG->wwwroot.'/mod/data/field.php?d='.$data->id.'&amp;mode=new&amp;sesskey='.
sesskey().'&amp;newtype=', $menufield, 'fieldform', '', 'choose');
helpbutton('fields', get_string('addafield','data'), 'data');
echo '</form>';
echo '</div>';
echo '<div class="sortdefault" align="center">';
echo '<form name="sortdefault" action="'.$CFG->wwwroot.'/mod/data/field.php" method="get">';
echo '<input type="hidden" name="d" value="'.$data->id.'" />';
echo '<input type="hidden" name="mode" value="sort" />';
echo '<input type="hidden" name="sesskey" value="'.sesskey().'" />';
echo '&nbsp;'.get_string('sortbydefault','data').':';
echo '&nbsp;'.get_string('defaultsortfield','data').':';
$fields = get_records('data_fields','dataid',$data->id);
echo '<select name="defaultsort"><option value="0">'.get_string('dateentered','data').'</option>';
foreach ($fields as $field) {
@@ -320,13 +312,14 @@
}
}
echo '</select>';
echo '&nbsp;';
$options = array(0 => get_string('ascending', 'data'),
1 => get_string('descending', 'data'));
choose_from_menu($options, 'defaultsortdir', $data->defaultsortdir, '');
echo '<input type="submit" value="'.get_string('setdefaultsort','data').'" />';
echo '<input type="submit" value="'.get_string('go').'" />';
echo '</form>';
echo '</div>';

0 comments on commit 763e8d6

Please sign in to comment.
You can’t perform that action at this time.