blob: 24d4c97f4940a626db62605765709410b5855a5e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
{{define "title"}}{{if .JobID}}Edit Job{{else}}Create Job{{end}}{{end}}
{{define "content"}}
{{if .Error}}
<div class="error">{{.Error}}</div>
{{end}}
{{if not .Fatal}}
{{if .Success}}
<div class="success">{{.Success}}</div>
{{end}}
<form action="/jobedit{{if .JobID}}/{{.JobID}}{{end}}" method="post" accept-charset="UTF-8">
<h2>Mail</h2>
<p>
<strong>Subject:</strong><br />
<input type="text" name="Subject" value="{{.Subject}}" />
</p>
<p>
<strong>Content:</strong><br />
<textarea name="Content" cols="80" rows="20">{{.Content}}</textarea>
</p>
<h2>Schedule</h2>
<table class="fullwidth schedules">
<thead>
<tr>
<th>Start<br /><span class="hint">(Format: YYYY-MM-DD HH:MM:SS)</span></th>
<th colspan="2">Repetition</th>
<th colspan="2">End<br /><span class="hint">(Format: YYYY-MM-DD HH:MM:SS)</span></th>
</tr>
</thead>
<tbody>
{{range .Schedules}}<tr>
<td><input type="text" name="Start" value="{{.Start}}" /></td>
<td>
<select name="RepetitionEnabled" size="0" class="enabler">
<option value="no"{{if not .RepetitionEnabled}} selected="selected"{{end}}>Off</option>
<option value="yes"{{if .RepetitionEnabled}} selected="selected"{{end}}>On</option>
</select>
</td>
<td>
<input type="text" name="Count" value="{{.Count}}" class="quant" />
<select name="Unit" size="0">
<option value="Minute"{{if .UnitIsMinute}} selected="selected"{{end}}>Minute(s)</option>
<option value="Hour"{{if .UnitIsHour}} selected="selected"{{end}}>Hour(s)</option>
<option value="Day"{{if .UnitIsDay}} selected="selected"{{end}}>Day(s)</option>
<option value="Week"{{if .UnitIsWeek}} selected="selected"{{end}}>Week(s)</option>
<option value="Month"{{if .UnitIsMonth}} selected="selected"{{end}}>Month(s)</option>
<option value="Year"{{if .UnitIsYear}} selected="selected"{{end}}>Year(s)</option>
</select>
</td>
<td>
<select name="EndEnabled" size="0" class="enabler">
<option value="no"{{if not .EndEnabled}} selected="selected"{{end}}>Off</option>
<option value="yes"{{if .EndEnabled}} selected="selected"{{end}}>On</option>
</select>
</td>
<td><input type="text" name="End" value="{{.End}}" /></td>
</tr>{{end}}
</tbody>
</table>
<h2>Save</h2>
<input type="submit" />
</form>
{{end}}
{{end}}
|