Project

General

Profile

« Previous | Next » 

Revision 2d2f8479

Added by Tomer Brisker about 5 years ago

Refs #26198 - Replace foreman_url with tfm.tools.foremanURL

ac1fe0d moved the foreman_url js function to webpack and deprecated the
old version but there were still a couple of places calling it causing
warnings in the console. This replaces those use cases with the newer
function.

View differences:

webpack/assets/javascripts/foreman_dashboard.js
import $ from 'jquery';
import { doesDocumentHasFocus } from './react_app/common/document';
import { notify } from './foreman_toast_notifications';
import { activateTooltips } from './foreman_tools';
import { activateTooltips, foremanUrl } from './foreman_tools';
import { translate as __ } from './react_app/common/I18n';
$(document).on('ContentLoad', () => {
if (window.foreman_url('/') === window.location.pathname) {
if (foremanUrl('/') === window.location.pathname) {
startGridster();
autoRefresh();
}

Also available in: Unified diff