mirror of https://github.com/ouqiang/gocron
新增界面截图
parent
98c1a1c3f9
commit
58776a1b30
|
@ -14,6 +14,10 @@
|
||||||
* 查看任务执行日志
|
* 查看任务执行日志
|
||||||
* 任务执行结果通知, 支持邮件、Slack
|
* 任务执行结果通知, 支持邮件、Slack
|
||||||
|
|
||||||
|
### 截图
|
||||||
|

|
||||||
|

|
||||||
|
|
||||||
### 支持平台
|
### 支持平台
|
||||||
> Windows、Linux、OSX
|
> Windows、Linux、OSX
|
||||||
|
|
||||||
|
|
|
@ -62,6 +62,7 @@ func request(req *http.Request, timeout int) ResponseWrapper {
|
||||||
}
|
}
|
||||||
|
|
||||||
func setRequestHeader(req *http.Request) {
|
func setRequestHeader(req *http.Request) {
|
||||||
|
req.Header.Set("Connection", "keep-alive")
|
||||||
req.Header.Set("Accept-Language", "zh-CN,zh;q=0.8,en;q=0.6")
|
req.Header.Set("Accept-Language", "zh-CN,zh;q=0.8,en;q=0.6")
|
||||||
req.Header.Set("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36 golang/gocron")
|
req.Header.Set("User-Agent", "Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36 golang/gocron")
|
||||||
}
|
}
|
||||||
|
|
Binary file not shown.
After Width: | Height: | Size: 221 KiB |
Binary file not shown.
After Width: | Height: | Size: 132 KiB |
|
@ -33,7 +33,7 @@
|
||||||
<div class="field">
|
<div class="field">
|
||||||
<select name="protocol" id="protocol">
|
<select name="protocol" id="protocol">
|
||||||
<option value="0">选择协议</option>
|
<option value="0">选择协议</option>
|
||||||
<option value="3" {{{if eq .Params.Protocol 3}}}selected{{{end}}}>本地命令</option>
|
<option value="3" {{{if eq .Params.Protocol 3}}}selected{{{end}}}>系统命令</option>
|
||||||
<option value="2" {{{if eq .Params.Protocol 2}}}selected{{{end}}} data-match="host_id" data-validate-type="selectProtocol">SSH</option>
|
<option value="2" {{{if eq .Params.Protocol 2}}}selected{{{end}}} data-match="host_id" data-validate-type="selectProtocol">SSH</option>
|
||||||
<option value="1" {{{if eq .Params.Protocol 1}}}selected{{{end}}}>HTTP</option>
|
<option value="1" {{{if eq .Params.Protocol 1}}}selected{{{end}}}>HTTP</option>
|
||||||
</select>
|
</select>
|
||||||
|
|
|
@ -181,7 +181,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{else}}
|
{{else}}
|
||||||
<a class="ui blue button" href="/setting/mail/edit">邮箱配置</a><br><br>
|
<a class="ui blue button" href="/manage/mail/edit">邮箱配置</a><br><br>
|
||||||
{{/each}}
|
{{/each}}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -194,7 +194,7 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{else}}
|
{{else}}
|
||||||
<a class="ui blue button" href="/setting/slack/edit">Slack配置</a>
|
<a class="ui blue button" href="/manage/slack/edit">Slack配置</a>
|
||||||
{{/each}}
|
{{/each}}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
@ -248,13 +248,13 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
function showMail(notifyReceiverIds) {
|
function showMail(notifyReceiverIds) {
|
||||||
util.get("/setting/mail", function(code, message, data) {
|
util.get("/manage/mail", function(code, message, data) {
|
||||||
renderReceiver(notifyReceiverIds, $('#mail-template'), data, 'MailUsers');
|
renderReceiver(notifyReceiverIds, $('#mail-template'), data, 'MailUsers');
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
function showSlack(notifyReceiverIds) {
|
function showSlack(notifyReceiverIds) {
|
||||||
util.get("/setting/slack", function(code, message, data) {
|
util.get("/manage/slack", function(code, message, data) {
|
||||||
renderReceiver(notifyReceiverIds, $('#slack-template'), data, 'Channels');
|
renderReceiver(notifyReceiverIds, $('#slack-template'), data, 'Channels');
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue