Commit Graph

31 Commits

Author SHA1 Message Date
Nestor Soriano d3bfd33e98
Use 'esc_attr' instead of suppressing the PHPCS warning 2021-07-16 09:16:20 +02:00
Nestor Soriano 9017c953bd
Remove the metabox for regenerating attribute lookup data for single product
Instead, a product selector has been added to the "Regenerate
product attributes lookup table" entry in the tools page. If a product
is selected, the tool regenerates the data only for that product;
otherwise, it regenerates the entire table.

This has forced a change on how the tools page is rendered. Now,
instead of each tool being just a description and a trigger link,
a form with GET method is rendered for each tool. The forms are rendered
first and then the tools, since HTML doesn't allow to include forms
inside tables; each button is associated to its form with a "form"
attribute.

Additionally, now the tools array returned by the woocommerce_debug_tools`
hook can have a 'selector' array with the details needed to render a
selector, which will also be part of the form for the tool.
2021-07-14 12:01:42 +02:00
Nestor Soriano 10adec6b88
Improvements in the engine behind the debug tools page.
Two new optional keys have been added to the tool definition array:

- 'disabled': when true the tool button will appear disabled.
- 'needs_refresh': when running a tool, by default the tool definitions
  are retrieved first, then the selected tool is executed,
  then the definitions previously retrieved are rendered.
  When this key is true the tool definitions are retrieved again
  after execution, useful for cases where the tool description
  or button enable/disable state changes after the tool execution.

Also now if a tool execution throws an exception a notice will be
shown with the execption message, previously the exception
was unhandled.
2021-04-28 10:24:23 +02:00
Nestor Soriano bad3df3e23
Fix code sniffer errors 2021-04-28 09:36:10 +02:00
Mike Jolley fce69c3dad Fix status page padding 2017-08-30 15:39:54 +01:00
Mike Jolley a44a57b5d9 Improve tools page styling 2017-08-15 12:05:34 +01:00
Aristeides Stathopoulos d4e3faf014 PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket 2016-09-02 04:51:31 +03:00
Mike Jolley 0667c1cde1 Remove option based tools 2016-08-24 17:35:13 +01:00
Mike Jolley 931660038a Update debug mode wording
Closes #11258
2016-06-27 12:28:46 +01:00
Mike Jolley d3ac3f4073 Modals first pass 2016-03-24 17:26:40 +00:00
Shiva Poudel 162e6f874e Tweak some lines endings for views 2016-02-23 14:56:02 +05:45
Justin Shreve d28c4f4f39 Fix hierarchy in the system status pages. 2016-02-18 08:39:02 -08:00
Shiva Poudel 592c7aee02 Typo fix in tools for uninstall 2015-11-06 00:10:14 +05:45
Mike Jolley 5e62143767 Update tools text Closes #9512 2015-11-05 14:44:05 +00:00
Remi Corson 32a22b3337 replaced esc_attr by sanitize_html_class 2015-06-15 09:30:09 +02:00
Remi Corson 61d7b156f4 added esc_attr 2015-06-12 21:59:51 +02:00
Remi Corson 40a56e2f9e Add debug tools classes 2015-06-12 15:07:01 +02:00
Mike Jolley a6692c4722 Clarify delete message
Closes #7917
2015-04-09 12:05:07 +01:00
shivapoudel a56b93a143 Tweaks for System Status 2015-03-07 09:01:08 +05:45
Mike Jolley 2a472e64e8 Only run the uninstaller if the "Uninstall on Delete" option is checked in system status. 2015-02-12 11:09:13 +00:00
Tamara Zuk af442599b1 Code Standards: Finish up admin includes
* fixed indentation - swapped spaces for tabs at start of line, swapped
tabs for spaces min-line for alignment
* removed instances of `@return void` and `@access public`

@see http://make.wordpress.org/core/handbook/coding-standards/php/

@see part 1: #6157
2014-11-30 01:52:32 -05:00
Bryce 1ffa2dd867 Updated to employ WordPress coding standards 2014-07-28 22:16:35 +07:00
Bryce 16fad7469b Admin Views HTML Headers, Stop Direct Access
Also a couple small formatting improvements
2014-07-28 21:50:11 +07:00
claudiosmweb c34cea6523 added a new option in system status to force the translations upgrade 2014-06-04 14:25:49 -03:00
Mike Jolley 173d483ac0 Add tool for disabling shipping rate cache for debug 2014-05-01 14:40:31 +01:00
Mike Jolley c0c21c8364 Unify textdomains Closes #4814 2014-02-17 13:14:45 +00:00
Scott Basgaard c712e1414a Update tools wp_nonce_url() to correct page. 2013-11-11 13:20:03 -05:00
Mike Jolley 90ba359ef9 Uninstall option Closes #3968. Change option for #3992 2013-10-23 17:21:03 +01:00
Scott Basgaard 9c9bfe1f4c Add template debug mode option. First pass at #3941 2013-10-23 17:52:58 +02:00
Mike Jolley 05d9c0e045 Rename menus, removed woocommerce_ 2013-10-22 17:26:18 +01:00
Mike Jolley 8a6ff89bf1 Moved admin directory and moved some functions to classes (ongoing refactor) 2013-07-24 17:01:36 +01:00