Skip to content

Commit

Permalink
Bugfix(task_multi): 🐛 修复多任务定时随机值错误
Browse files Browse the repository at this point in the history
Fix #515
  • Loading branch information
a76yyyy committed Apr 6, 2024
1 parent 4bdf9e7 commit cac1aaa
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion web/handlers/task_multi.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ async def post(self, userid):
'cron_val': time_env['cron_val'],
}

if time_env['randtimezone1'] != '':
if time_env['randtimezone1']:
settime_env['randsw'] = True
# if time_env['cron_sec'] != '':
# settime_env['cron_sec'] = time_env['cron_sec']
Expand Down
6 changes: 3 additions & 3 deletions web/tpl/taskmulti.html
Original file line number Diff line number Diff line change
Expand Up @@ -139,8 +139,8 @@ <h4 class="modal-title" id="myModalLabel">多任务操作</h4>
'ontime_method' : $('#ontime_method')[0].value,
'ontime_run_date' : $('#ontime_run_date')[0].value,
'ontime_val' : $('#ontime_val')[0].value,
'randtimezone1' : $('#randtimezone1')[0].value,
'randtimezone2' : $('#randtimezone2')[0].value,
'randtimezone1' : parseInt($('#randtimezone1')[0].value),
'randtimezone2' : parseInt($('#randtimezone2')[0].value),
'cron_val' : $('#cron_val')[0].value,
// 'cron_sec' : $('#cron_sec')[0].value,
}
Expand Down Expand Up @@ -235,4 +235,4 @@ <h4 class="modal-title" id="myModalLabel">多任务操作</h4>
$('#ontime_val').val(now);
})
</script>
{% endif %}
{% endif %}

0 comments on commit cac1aaa

Please sign in to comment.