48 lines
1.3 KiB
HTML
48 lines
1.3 KiB
HTML
{% extends 'dashboard.html' %}
|
|
|
|
{% block page %}
|
|
|
|
{{ render_partial('dashboard/http_functions/header.html',
|
|
user_id=user_id,
|
|
show_name=False,
|
|
show_refresh=False,
|
|
show_logs=False,
|
|
show_client=False,
|
|
show_link=False,
|
|
cancel_url=url_for('timer.overview'),
|
|
title='New Timer Function')
|
|
}}
|
|
|
|
<div id="app" class="">
|
|
<!-- The Editor component will be mounted here -->
|
|
</div>
|
|
|
|
<script>
|
|
// Mount the component
|
|
m.mount(document.getElementById("app"), {
|
|
view: () => m(Editor, {
|
|
name: '{{ name }}',
|
|
jsValue: {{ script | tojson | safe }},
|
|
jsonValue: {{ environment_info | tojson | safe }},
|
|
isEdit: false,
|
|
isAdd: true,
|
|
showHeader: true,
|
|
executeUrl: "{{ url_for('execute_code', playground='true') }}",
|
|
saveUrl: "{{ url_for('timer.new') }}",
|
|
showDeleteButton: false,
|
|
dashboardUrl: "{{ url_for('timer.overview') }}",
|
|
generateUrl: "{{ url_for('llm.generate_script') }}",
|
|
isTimer: true,
|
|
showTimerSettings: true,
|
|
triggerType: 'interval',
|
|
frequencyMinutes: 60,
|
|
cronExpression: '',
|
|
runtime: 'node',
|
|
showPublicToggle: false,
|
|
showLogRequestToggle: false,
|
|
showLogResponseToggle: false
|
|
})
|
|
})
|
|
</script>
|
|
|
|
{% endblock %} |