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 
 
 
 
 
 
 
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
{% extends "layout.html" %}
{% block content %}
<div class="main-content">

	<div class="container-fluid" style="padding-bottom:54px">
		<div class="pos-box bgw mtb15">
			<div class="tab-list" id="cronMode">
				<div class="tabs-item" data-type="crontab">{{data['lan']['H2']}}</div>
				<div class="tabs-item" data-type="trigger">任务编排</div>
				<div class="tabs-item" data-type="script">脚本库</div>
			</div>
		</div>
		<div class="info-title-tips task-orchestration-title" style="display: none">
			<p><span class="glyphicon glyphicon-alert" style="color: #f39c12; margin-right: 10px;"></span>【使用提醒】此功能为企业版专享功能</p>
		</div>
		<div class="site_table_view bgw mtb15 pd15 tab-view-box">
			<div class="tab-con" style="padding: 0;overflow: inherit;">
				<div class="tab-con-block">
					<div class="setbox radius4">
						<div class="title c6 plr15">
							<div class="flex" >
								<h3 class="f16">{{data['lan']['H3']}}</h3>
								<div class="ml15">
									<span class="bt-desired" style="background-size:contain;">
										<a href="javascript:;" class="btlink ml5 npsFeedback">需求反馈</a>
									</span>
								</div>
							</div>
						</div>
						<div class="setting-con ptb20" id="crontabForm" style="min-height:350px"></div>
					</div>
					<div class="setbox radius4">
						<div class="title c6 plr15 flex justify-between" style="align-items: center;">
							<h3 class="f16">{{data['lan']['H4']}}</h3>
							<div class="order_search">
								<input type="text" class="search_input" placeholder="支持任务名称、关键字模糊搜索" />
								<span class="glyphicon glyphicon-search" aria-hidden="true"></span>
							</div>
						</div>
						<div id="crontabTabel" class="pd15 setting-con"></div>
					</div>
				</div>
				<div class="tab-con-block task-orchestration" style="display: none">
					<div id="crontabTrigger"></div>
					<div class="thumbnail-introduce-new" style="padding: 34px 20% 0 20%;">
						<div class="thumbnail-introduce-title-new" style="width:100%;">
							<div class="thumbnail-title-left-new">
								<div class="thumbnail-title-text-new">
									<p>任务编排-功能介绍</p>
									<p>脚本库含有:服务管理、进程监控、告警通知、负载监控、网站监控等常用脚本任务,可以实现自动化的脚本定时执行、服务器状态监控和任务追踪功能。</p>
								</div>
							</div>
							<div class="thumbnail-title-button-new daily-product-buy">
								<a title="立即购买" href="javascript:;" class="btn btn-success va0 ml15"
									onclick="product_recommend.pay_product_sign('ltd',160,'ltd')">立即购买</a>
							</div>
						</div>
						<div class="thumbnail-introduce-hr" style="width: 100%;"></div>
						<div class="thumbnail-introduce-ul-new" style="width:100%;">
							<ul style="justify-content:space-evenly">
								<li><span class="li-icon"></span>脚本定时执行</li>
								<li><span class="li-icon"></span>监控服务器状态</li>
								<li><span class="li-icon"></span>任务追踪</li>
							</ul>
						</div>
						<img class="product_view_img"
							src="https://www.bt.cn/Public/new/plugin/introduce/crontab/crontab_trigger.png"
							style="width: 100%;box-shadow: 0px 6px 10px rgba(145, 145, 145, 0.25);margin-top:30px" />
					</div>
				</div>
				<div class="tab-con-block">
					<div id="crontabScriptBox"></div>
				</div>
			</div>
		</div>
	</div>
</div>
<style>
   	/* tools.js */
	.bt-form .line label.cursor-pointer i.form-checkbox {
		display: inline-block;
		width: 16px;
		height: 16px;
		border: 1px solid #ccc;
		background-color: #fff;
		vertical-align: top;
		position: relative;
		border-radius: 2px;
		vertical-align: middle;
	}
	.bt-form .line label.cursor-pointer i.form-checkbox.active {
		background-color: #20a53a;
		border-color: #20a53a;
	}
	.bt-form .line label.cursor-pointer i.form-checkbox.active::after {
		content: '';
		position: absolute;
		display: block;
		left: 50%;
		top: 50%;
		margin-left: -2.5px;
		margin-top: -6px;
		width: 5px;
		height: 10px;
		border: solid #fff;
		border-width: 0 2px 2px 0;
		transform: rotate(45deg);
	}
	/* tools.js end */
	.layer-create-content .layui-layer-content {
		overflow: inherit;
	}

	.crontab_form {
		padding: 15px 45px;
	}

	.crontab_form .inlineBlock {
		vertical-align: middle;
	}

	.crontab_form .tname {
		font-size: 13px;
	}

	.crontab_form .line .tname {
		height: 35px;
		line-height: 35px;
	}

	.crontab_form .line .info-r {
		margin-bottom: 15px;
	}

	.crontab_form .bt_select_updown {
		height: 35px;
		line-height: 35px;
	}

	.crontab_form .bt-input-text {
		height: 35px;
		line-height: 35px;
		padding-left: 10px;
		font-size: 13px;
	}


	.crontab_form .bt_select_updown .bt_select_list {
		max-height: 240px;
	}

	.crontab_form .inlineBlock.group span {
		height: 35px;
		line-height: 33px
	}

	.crontab_form .bt_select_updown .bt_select_value {
		height: 33px;
		line-height: 33px;
	}

	.crontab_form .bt_select_updown .bt_select_content {
		font-size: 13px;
	}

	.crontab_form .bt_select_updown .bt_select_list {
		top: 35px;
	}

	.crontab_form .bt_select_updown .bt_select_list .item {
		height: 30px;
		line-height: 30px;
	}

	.crontab_form .inlineBlock {
		margin-right: 10px;
	}

	.crontab_form .btn {
		font-size: 13px;
		padding: 7px 30px;
	}
	#crontabTabel .divtable thead {
		position: relative;
		z-index: 999;
	}
	#crontabTabel .divtable {
		border: 1px solid #ddd;
	}
	#crontabTabel table {
		border: none;
	}
	.layer-alarm-channel .bt-w-main {
		height: 430px
	}

	/* 消息通道 */
	.channel_config_view a.layui-layer-btn2 {
		background-color: #fff;
		border: 1px solid #ccc !important;
		color: #555;
		font-weight: initial;
		float: left;
	}
	.channel_config_view a.layui-layer-btn2:hover {
		color: #fff;
		background-color: #10952a;
		border-color: #398439;
	}

	.email_alarm thead {
		position: relative;
		z-index: 11;
	}
	/* 消息通道 end*/
	/* 触发器 */
	#trigger_form_box .inlineBlock.group span {
		height: 32px;
		line-height: 30px
	}

	#trigger_form_box .inlineBlock.group {
		margin-right: 10px;
	}

	/* 触发器 end*/
	#crontabScriptBox .tab-con {
		padding: 0;
	}

	/* tools二级下拉 */
	.bt_seconday_menu .bt_select_list {
		overflow: inherit;
	}

	.bt_select_list .item-parent span {
		position: absolute;
		right: 5px;
		top: 8px;
	}

	.bt_select_list li.item-parent {
		height: 28px;
		line-height: 28px;
		position: relative;
		display: flex;
		flex-direction: row;
		justify-content: space-between;
		align-items: center;
	}

	.bt_select_list li.item-parent.down {
		color: rgb(32, 165, 58);
	}

	.bt_select_list li.item-parent:hover,
	.bt_select_list li.item-parent.down,
	.bt_select_list .item-menu-body-list .item-child:hover {
		background-color: rgb(245, 247, 250);
	}

	.bt_select_list .item-menu-body-list {
		display: none;
		position: absolute;
		transition: all 500ms;
		top: 0;
		right: -204px;
		box-shadow: 0px 3px 16px rgba(153, 153, 153, 0.42);
		border-radius: 1px;
		width: 208px;
		z-index: 999;
		background-color: #fff;
		max-height: 168px;
		overflow: auto;
	}

	.bt_select_list .item-menu-body-list .item-child {
		height: 28px;
		line-height: 28px;
		color: rgb(102, 102, 102)
	}

	.bt_select_list .item-menu-body-list .item-child.active {
		color: rgb(32, 165, 58);
	}

	.item-menu-title.active {
		color: rgb(32, 165, 58);
	}

	.bt_select_list .item-menu-title {
		padding-left: 10px;
		width: max-content;
	}

	/* tools二级下拉 end*/
	.bt_seconday_menu .bt_select_list {
		overflow: inherit;
	}

	.bt_select_list .item-parent span {
		position: absolute;
		right: 5px;
		top: 8px;
	}

	.bt_select_list li.item-parent {
		height: 28px;
		line-height: 28px;
		position: relative;
		display: flex;
		flex-direction: row;
		justify-content: space-between;
		align-items: center;
	}

	.bt_select_list li.item-parent.down {
		color: rgb(32, 165, 58);
	}

	.bt_select_list li.item-parent:hover,
	.bt_select_list li.item-parent.down,
	.bt_select_list .item-menu-body-list .item-child:hover {
		background-color: rgb(245, 247, 250);
	}

	.bt_select_list .item-menu-body-list {
		display: none;
		position: absolute;
		transition: all 500ms;
		top: 0;
		right: -204px;
		box-shadow: 0px 3px 16px rgba(153, 153, 153, 0.42);
		border-radius: 1px;
		width: 208px;
		z-index: 999;
		background-color: #fff;
		max-height: 168px;
		overflow: auto;
	}

	.bt_select_list .item-menu-body-list .item-child {
		height: 28px;
		line-height: 28px;
		color: rgb(102, 102, 102)
	}

	.bt_select_list .item-menu-body-list .item-child.active {
		color: rgb(32, 165, 58);
	}

	.item-menu-title.active {
		color: rgb(32, 165, 58);
	}

	.bt_select_list .item-menu-title {
		padding-left: 10px;
		width: max-content;
	}


	.messageCard {
		overflow-y: scroll;
	}

	.messageCard::-webkit-scrollbar {
		width: 10px;
		height: 10px;
	}

	.messageCard::-webkit-scrollbar-thumb {
		border-radius: 10px;
		background: rgba(0, 0, 0, 0.2);
	}

	.messageCard::-webkit-scrollbar-track {
		border-radius: 0;
		background: rgba(0, 0, 0, 0.1);
	}

	.green {
		color: #20A53A;
	}
	.orange {
		color: #F0AD4E;
	}
	.red {
		color: #EF0808;
	}
	/* 计划任务列表置顶*/
	.crontab-topping {
		width: 20px;
		height: 20px;
		cursor: pointer;
	}

	.crontab-gray {
		filter: grayscale(80%)
	}

	.bt_multiple_select_updown .bt_select_content span:first-child {
		max-width: 120px;
		overflow: hidden;
		display: inline-block;
		text-overflow: ellipsis;
		white-space: nowrap;
	}
	/* 计划任务列表置顶 end*/
	/* 计划任务测试本地url提示样式*/
	.localManu {
		display: none;
		width: 98%;
		max-height: 300px;
		overflow: auto;
		position: absolute;
		top: 36px;
		left: 0px;
		padding: 5px 0;
		background-color: #fff;
		border-radius: 4px;
		border: 1px solid rgb(228, 231, 237);
		box-shadow: 0px 3px 16px rgba(153, 153, 153, 0.42);
		z-index: 99999;
	}

	.localManu .domain-li {
		width: 100%;
		padding: 0 10px;
		overflow: hidden;
		white-space: nowrap;
		text-overflow: ellipsis;
		line-height: 30px;
		cursor: pointer;
	}

	.localManu .domain-li:hover {
		background-color: #F5F7FA;
	}

	.localManu .active {
		color: #20A53A;
	}
	/* 计划任务测试本地url提示样式 end*/
	/* 任务列表搜索框样式*/
	.order_search {
		display: inline-block;
		height: 30px;
		line-height: 30px;
		position: relative;
	}
	.order_search .search_input {
		height: 30px;
		line-height: 30px;
		border-radius: 2px;
		border: 1px solid #DCDFE6;
		outline: none;
		padding-left: 8px;
		vertical-align: top;
		width: 230px;
	}
	.order_search .search_input:focus {
		border-color: #20a53a;
	}
	.order_search .glyphicon-search {
		height: 28px;
		line-height: 28px;
		padding: 0 10px;
		color: #888;
		position: absolute;
		right: 0;
		font-size: 14px;
		cursor: pointer;
	}
	.order_search .search_input:focus+span.glyphicon-search {
		color: #20a53a;
	}
	#time_choose {
		border: #ddd 1px solid;
		height: 30px;
		padding: 0 10px;
		width: 180px;
		background-image:
			url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAHBAMAAADOnLEXAAAAA3NCSVQICAjb4U/gAAAAElBMVEX////v7++oqKiSkpJgYGAzMzNVUvUKAAAABnRSTlMA//////96eeD+AAAACXBIWXMAAA7DAAAOwwHHb6hkAAAAFnRFWHRDcmVhdGlvbiBUaW1lADA3LzEzLzE442/mwwAAABx0RVh0U29mdHdhcmUAQWRvYmUgRmlyZXdvcmtzIENTNui8sowAAAApSURBVAiZYxBiAAJFBhEDBgZmRwbmYAYGUwMQBrGAXBAHyAVxgFwgBwBYpgOoNMjLNgAAAABJRU5ErkJggg==);
		background-repeat: no-repeat;
		background-position: 160px center;
		outline: none;
	}
	/* 任务列表搜索框样式end*/
</style>
{% endblock %}
{% block scripts %}
  {{ super() }}
	<script type="text/javascript" src="{{g.cdn_url}}/laydate/laydate.js"></script>
  <script src="{{g.cdn_url}}/js/crontab.js?version={{g['version']}}&repair={{data['js_random']}}"></script>
	<script type="text/javascript" src="{{g.cdn_url}}/editor/ace.js" defer></script>
	<script type="text/javascript">
      // crontab.init()
      setCookie('serverType',"{{session['webserver']}}");
	  bt.newDotTips([
		{el: '#cronMode .tabs-item:eq(1)',name: 'task',style: 'top: 18px;margin-left: 6px;'},
		{el: '#cronMode .tabs-item:eq(2)',name: 'shell',style: 'top: 18px;margin-left: 6px;'}
		])
			// 计划任务nps入口
			$('.npsFeedback').on('click',function(){
				bt_tools.nps({name:'计划任务', type: 6 })
			})


  </script>
{% endblock %}