]> git.donarmstrong.com Git - roundcube.git/blob - plugins/managesieve/skins/default/templates/filteredit.html
556d996215671a9e9d73fc74d36bf4fb3e6a41a1
[roundcube.git] / plugins / managesieve / skins / default / templates / filteredit.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <html xmlns="http://www.w3.org/1999/xhtml">
3 <head>
4 <title><roundcube:object name="pagetitle" /></title>
5 <roundcube:include file="/includes/links.html" />
6 <link rel="stylesheet" type="text/css" href="/this/managesieve.css" />
7 </head>
8 <body class="iframe">
9
10 <script type="text/javascript">
11
12 function header_select(id)
13 {
14     var obj = document.getElementById('header'+id);
15
16     if (obj.value == 'size')
17     {
18         document.getElementById('rule_size' + id).style.display = 'inline';
19         document.getElementById('rule_op' + id).style.display = 'none';
20         document.getElementById('rule_target' + id).style.display = 'none';
21         document.getElementById('custom_header' + id).style.display = 'none';
22     }
23     else
24     {
25         if (obj.value != '...')
26             document.getElementById('custom_header' + id).style.display = 'none';
27         else
28             document.getElementById('custom_header' + id).style.display = 'inline';
29     
30         document.getElementById('rule_size' + id).style.display = 'none';
31         document.getElementById('rule_op' + id).style.display = 'inline';
32         rule_op_select(id);
33     }
34 }
35
36 function rule_op_select(id)
37 {
38     var obj = document.getElementById('rule_op'+id);
39
40     if (obj.value == 'exists' || obj.value == 'notexists')
41     {
42         document.getElementById('rule_target' + id).style.display = 'none';
43     }
44     else
45     {
46         document.getElementById('rule_target' + id).style.display = 'inline';
47     }
48 }
49
50 function action_type_select(id)
51 {
52     var obj = document.getElementById('action_type'+id);
53
54     if (obj.value == 'fileinto' || obj.value == 'fileinto_copy')
55     {
56         document.getElementById('action_mailbox' + id).style.display = 'inline';
57         document.getElementById('action_target' + id).style.display = 'none';
58         document.getElementById('action_target_area' + id).style.display = 'none';
59         document.getElementById('action_vacation' + id).style.display = 'none';
60     }
61     else if (obj.value == 'redirect' || obj.value == 'redirect_copy')
62     {
63         document.getElementById('action_target' + id).style.display = 'inline';
64         document.getElementById('action_mailbox' + id).style.display = 'none';
65         document.getElementById('action_target_area' + id).style.display = 'none';
66         document.getElementById('action_vacation' + id).style.display = 'none';
67     }
68     else if (obj.value.match(/^reject|ereject$/))
69     {
70         document.getElementById('action_target_area' + id).style.display = 'inline';
71         document.getElementById('action_vacation' + id).style.display = 'none';
72         document.getElementById('action_target' + id).style.display = 'none';
73         document.getElementById('action_mailbox' + id).style.display = 'none';
74     }
75     else if (obj.value == 'vacation')
76     {
77         document.getElementById('action_vacation' + id).style.display = 'inline';
78         document.getElementById('action_target_area' + id).style.display = 'none';
79         document.getElementById('action_target' + id).style.display = 'none';
80         document.getElementById('action_mailbox' + id).style.display = 'none';
81     }
82     else // discard, keep, stop
83     {
84         document.getElementById('action_target_area' + id).style.display = 'none';
85         document.getElementById('action_vacation' + id).style.display = 'none';
86         document.getElementById('action_target' + id).style.display = 'none';
87         document.getElementById('action_mailbox' + id).style.display = 'none';
88     }
89 }
90
91 function rule_join_radio(value)
92 {
93     document.getElementById('rules').style.display = (value=='any' ? 'none' : 'block');
94 }
95 </script>
96
97 <div id="filter-title" class="boxtitle"><roundcube:label name="managesieve.filterdef" /></div>
98
99 <div id="filter-form" class="boxcontent">
100 <roundcube:object name="filterform" />
101
102 <div id="footer">
103 <div class="footerleft">
104 <roundcube:button command="plugin.managesieve-save" type="input" class="button mainaction" label="save" />
105 </div>
106 <div class="footerright">
107 <label for="disabled"><roundcube:label name="managesieve.filterdisabled" /></label>
108 <input type="checkbox" id="disabled" name="_disabled" value="1" />
109 </div>
110 </div>
111
112 </form>
113 </div>
114
115
116 </body>
117 </html>