haproxy-wi/app/static/js/variables.js

30 lines
1.2 KiB
JavaScript
Raw Normal View History

// Translate
const translate_div = $('#translate');
const cancel_word = translate_div.attr('data-cancel');
let add_word = translate_div.attr('data-add');
const close_word = translate_div.attr('data-close');
const service_word = translate_div.attr('data-service');
const save_word = translate_div.attr('data-save');
const just_save_word = translate_div.attr('data-just_save');
const upload_and_reload = translate_div.attr('data-upload_and_reload');
const upload_and_restart = translate_div.attr('data-upload_and_restart');
const edit_word = translate_div.attr('data-edit');
const delete_word = translate_div.attr('data-delete');
const back_word = translate_div.attr('data-back');
const nice_service_name = {'keepalived': 'HA Custer', 'haproxy': 'HAProxy', 'nginx': 'NGINX', 'apache': 'Apache'};
// JS scripts URL
2024-08-02 09:50:02 +00:00
const scriptPath = "/static/js"
const script = `${scriptPath}/script.js`;
const overview = `${scriptPath}/overview.js`;
const configShow = `${scriptPath}/configshow.js`;
const awesome = `${scriptPath}/fontawesome.min.js`;
const ha = `${scriptPath}/ha.js`;
2024-08-02 09:50:02 +00:00
const waf = `${scriptPath}/waf.js`
// csrf_token
const csrf_token = Cookies.get('csrf_access_token');
// API prefix
const api_prefix = '/api'