3 # Display a form for exporting a batch file
5 require './user-lib.pl';
6 $access{'export'} || &error($text{'export_ecannot'});
7 &ui_print_header(undef, $text{'export_title'}, "", "export");
9 print "$text{'export_desc'}<p>\n";
10 print &ui_form_start("export_exec.cgi");
11 print &ui_table_start($text{'export_header'}, undef, 2);
14 if ($access{'export'} == 2) {
16 print &ui_table_row($text{'export_to'},
17 &ui_radio_table("to", 0,
18 [ [ 0, $text{'export_show'} ],
19 [ 1, $text{'export_file'},
20 &ui_filebox("file", undef, 30) ] ]));
24 print &ui_table_row($text{'export_to'}, $text{'export_show'});
28 $pft = &passfiles_type();
29 print &ui_table_row($text{'export_pft'},
30 &ui_select("pft", $pft,
31 [ map { [ $_, $text{'pft_'.$_} ] }
32 map { /^pft_(\d+)$/ ? ( $1 ) : ( ) }
33 sort { $a cmp $b } (keys %text) ]));
36 print &ui_table_row($text{'export_who'},
37 &ui_radio_table("mode", 0,
38 [ [ 0, $text{'export_who'} ],
39 [ 2, $text{'acl_uedit_only'},
40 &ui_textbox("can", undef, 40)." ".
41 &user_chooser_button("can", 1) ],
42 [ 3, $text{'acl_uedit_except'},
43 &ui_textbox("cannot", undef, 40)." ".
44 &user_chooser_button("cannot", 1) ],
45 [ 4, $text{'acl_uedit_uid'},
46 &ui_textbox("uid", undef, 6)." - ".
47 &ui_textbox("uid2", undef, 6) ],
48 [ 5, $text{'acl_uedit_group'},
49 &ui_textbox("group", undef, 40)." ".
50 &group_chooser_button("group", 1)."<br>".
51 &ui_checkbox("sec", 1, $text{'acl_uedit_sec'}, 0) ],
52 [ 8, $text{'acl_uedit_gid'},
53 &ui_textbox("gid", undef, 6)." - ".
54 &ui_textbox("gid2", undef, 6) ],
57 print &ui_table_end();
58 print &ui_form_end([ [ undef, $text{'export_ok'} ] ]);
60 &ui_print_footer("", $text{'index_return'});