CoreFiles by mySites.guru
admin-field-edit-modal.js23 lines, 803 bytes, from Joomla_4.0.0-beta7-Beta-Full_Package.zip
Raw History Compare with 4.0.0-beta6
md5
a4fd0198372e7c6120756d74b964c996
sha1
4d15ebfec84478db688a85b7ebbd2136a7025dfb
sha256
c6f535293b2fb7320a4d87d3d3ba504fe09521eb485064c4d2005e81a673341b
/**
* PLEASE DO NOT MODIFY THIS FILE. WORK ON THE ES6 VERSION.
* OTHERWISE YOUR CHANGES WILL BE REPLACED ON THE NEXT BUILD.
**/

/**
 * @copyright  (C) 2019 Open Source Matters, Inc. <https://www.joomla.org>
 * @license    GNU General Public License version 2 or later; see LICENSE.txt
 */
(function (Joomla) {
  'use strict';

  Joomla.submitbutton = function (task) {
    if (task === 'field.cancel' || document.formvalidator.isValid(document.getElementById('item-form'))) {
      if (window.opener && (task === 'field.save' || task === 'field.cancel')) {
        window.opener.document.closeEditWindow = window.self;
        window.opener.setTimeout('window.document.closeEditWindow.close()', 1000);
      }

      Joomla.submitform(task, document.getElementById('item-form'));
    }
  };
})(Joomla);

The same content is in 2 releases, Joomla 4.0.0-beta6 to 4.0.0-beta7. See them all, or every version of this file.