CoreFiles by mySites.guru
admin-actionlogs-default.es6.js35 lines, 1,011 bytes, from Joomla_4.0.0-beta1-Beta-Full_Package.zip
Raw History Compare with 3.9.0-beta4
md5
2e9ee28e91e8b1a9fe2047fde66f85bc
sha1
0e22dee517a46233e93ebf968275377da5c98d6f
sha256
4e48cda41ac24b78de8a91fb47f663cdc2be7567243135a23884453f2d210f99
/**
* PLEASE DO NOT MODIFY THIS FILE. WORK ON THE ES6 VERSION.
* OTHERWISE YOUR CHANGES WILL BE REPLACED ON THE NEXT BUILD.
**/

/**
 * @copyright   Copyright (C) 2005 - 2020 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
Joomla.submitbutton = task => {
  'use strict';

  if (task === 'actionlogs.exportLogs') {
    Joomla.submitform(task, document.getElementById('exportForm'));
    return;
  }

  if (task === 'actionlogs.exportSelectedLogs') {
    // Get id of selected action logs item and pass it to export form hidden input
    const cids = [];
    const elements = [].slice.call(document.querySelectorAll("input[name='cid[]']:checked"));

    if (elements.length) {
      elements.forEach(element => {
        cids.push(element.value);
      });
    }

    document.exportForm.cids.value = cids.join(',');
    Joomla.submitform(task, document.getElementById('exportForm'));
    return;
  }

  Joomla.submitform(task);
};

The same content is in 5 releases, Joomla 4.0.0-beta to 4.0.0-beta5. See them all, or every version of this file.