15608 Commits

Author SHA1 Message Date
Jan Jakes
fbd27afedf Move step runner interface to the control namespace
[MAILPOET-4515]
2022-08-08 13:23:57 +02:00
Jan Jakes
ca308321fd Rename step runner to handler (free the name to step runner interface)
[MAILPOET-4515]
2022-08-08 13:23:57 +02:00
Jan Jakes
c9aa53df8b Extract workflow step updating to a separate controller
[MAILPOET-4515]
2022-08-08 13:23:57 +02:00
Jan Jakes
fc11b2f97e Fix automation editor body class
We use edit-site styles now so we need to set the correct class for the footer to disappear.

[MAILPOET-4515]
2022-08-08 13:23:57 +02:00
Jan Lysý
18501385dc Extend integration test for filters
[MAILPOET-4442]
2022-08-08 10:57:42 +02:00
Jan Lysý
c917505170 Add acceptance test with filtering by tag
[MAILPOET-4442]
2022-08-08 10:57:42 +02:00
Jan Lysý
0b14a03236 Disable margin left for second select in a row
[MAILPOET-4442]
2022-08-08 10:57:42 +02:00
Jan Lysý
2b5d089a79 Add tag filter into subscribers response
[MAILPOET-4442]
2022-08-08 10:57:42 +02:00
Jan Lysý
5445bf9305 Add tags statistics method
[MAILPOET-4442]
2022-08-08 10:57:42 +02:00
Jan Lysý
98d9952a44 Fix prefetching subscriber relations
[MAILPOET-4501]
2022-08-08 10:57:42 +02:00
Jan Lysý
f899eb1c16 Parse name from an email
When the settings table is empty and the current user uses an email in the name. We try to parse the name.
[MAILPOET-4501]
2022-08-08 10:42:25 +02:00
Rodrigo Primo
e93befc965 Rename popup message over list/segment badges to 'View subscribers'
[MAILPOET-4505]
2022-08-08 09:04:34 +02:00
Rostislav Wolny
c8278dde2a Use correct exception type when saving segment to DB fails
[MAILPOET-4294]
2022-08-04 13:31:53 +02:00
Rostislav Wolny
1d4ec47b25 Move tests for addList under the related service test
[MAILPOET-4294]
2022-08-04 13:31:53 +02:00
Rostislav Wolny
9c5dca0206 Refactor MailPoet\API\MP\v1\API::addList to doctrine
[MAILPOET-4294]
2022-08-04 13:31:53 +02:00
Rodrigo Primo
73f51523f3 Replace Paris models with Doctrine entities in SubscriberLinkTokens
[MAILPOET-4345]
2022-08-04 11:52:57 +02:00
Rodrigo Primo
d3abbddf73 Add a basic integration test to cover the happy path of SubscriberLinkTokens
[MAILPOET-4345]
2022-08-04 11:52:57 +02:00
Rodrigo Primo
56b90247b2 Add method to set the link_token to the Subscriber factory
[MAILPOET-4345]
2022-08-04 11:52:57 +02:00
Rodrigo Primo
4a8ac483f6 Use getServiceWithOverrides() instead of instantiating the tested class
This commit changes the way InactiveSubscribersTest
instantiates the tested class InactiveSubscribers. Instead of calling it
directly, it uses \MailPoetTest::getServiceWithOverrides(). This way, we
don't have to update all the tests when there is a change to the
signature of the constructor of the tested class.

[MAILPOET-4344]
2022-08-04 11:10:50 +02:00
Rodrigo Primo
af396021db Move the query to calculate the max subscriber ID to SubscribersRepository
[MAILPOET-4344]
2022-08-04 11:10:50 +02:00
Rodrigo Primo
0f7a3c3e00 Replace Paris models with Doctrine entities in SimpleWorkerTest
[MAILPOET-4344]
2022-08-04 11:10:50 +02:00
Rodrigo Primo
8a29519b31 Replace Paris models with Doctrine entities in InactiveSubscribers
[MAILPOET-4344]
2022-08-04 11:10:50 +02:00
Rodrigo Primo
261f2eaa25 Replace Paris models with Doctrine entities in Shortcodes
[MAILPOET-4364]
2022-08-04 10:55:03 +02:00
Rodrigo Primo
4a0ee78467 Replace Paris models with Doctrine entities in ShortcodesTest
[MAILPOET-4364]
2022-08-04 10:55:03 +02:00
Rodrigo Primo
de4e76b65d Use is_array() instead of !empty() for a safer check
Just in case the option is changed and is not an array anymore.

[MAILPOET-4491]
2022-08-04 10:18:44 +02:00
Rodrigo Primo
ffecdf8528 Use update_option() instead of add_option()
See https://github.com/mailpoet/mailpoet/pull/4277#discussion_r933531137

[MAILPOET-4491]
2022-08-04 10:18:44 +02:00
Rodrigo Primo
ef89cae94a Include in the Beacon info about if MP was installed via WC or not
[MAILPOET-4491]
2022-08-04 10:18:44 +02:00
Rodrigo Primo
6a5207a366 Add new property to pass to Mixpanel to track if MP was installed via WC
[MAILPOET-4491]
2022-08-04 10:18:44 +02:00
Rodrigo Primo
13e06fe0cb Add helper method to check if MailPoet was installed via WooCommerce
The method will return true if MailPoet was installed via the
WooCommerce onboarding wizard and false otherwise.

[MAILPOET-4491]
2022-08-04 10:18:44 +02:00
Sam Najian
57c02a2fd3 Inline form honey pot css style
Inline !important styling has more specificity that styling
added inside style tag, and is more likely to work on more
devices

[MAILPOET-4519]
2022-08-04 10:10:16 +02:00
Jan Lysý
ac473c412e Use WP functions from internal class
[MAILPOET-4516]
2022-08-03 16:52:02 +02:00
Jan Lysý
679d586d2b Fix settings action link order
[MAILPOET-4516]
2022-08-03 16:52:02 +02:00
Rodrigo Primo
85e7997197 Replace Paris models with Doctrine entities in AuthorizedEmailsController
[MAILPOET-4347]
2022-08-03 16:27:41 +02:00
Rodrigo Primo
d225f4e044 Replace Paris models with Doctrine entities in AuthorizedEmailsControllerTest
[MAILPOET-4347]
2022-08-03 16:27:41 +02:00
Rodrigo Primo
e7b32bdd4a Add method to set the status when creating a new Newsletter entity
This commit adds the method withStatus() to the newsletter factory
class so that it is possible to pass a variable with the status to the
factory. Before this change, it was necessary to class methods like
withActiveStatus() which make it impossible to create newsletters with
different status in the same call. This will be used in a subsequent
commit that is part of the same ticket to refactor
AuthorizedEmailsControllerTest.

[MAILPOET-4347]
2022-08-03 16:27:41 +02:00
Rostislav Wolny
b89a931e1a Improve CSS reset for fieldset and legend in form
These changes address issues found when testing with Storefront theme.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Rostislav Wolny
c170641d83 Fix form checkbox html
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Rostislav Wolny
35d9a6b2d3 Update form acceptance test check
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Rostislav Wolny
6777a9b560 Update unit tests to reflect form rendering changes
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Rostislav Wolny
bf5d27cc79 Unify error message for invalid email with other messages
Other error messages are also ended with period.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Rostislav Wolny
7f525068b3 Improve legend tag rendering in forms
The legend html was not escaped and was ignoring block settings coming
from the form editor.
This commit adds a new helper function for rendering legend that respects
applies block settings and also escapes the output.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Rostislav Wolny
243e1bdac8 Change form fieldset CSS reset to also affect manage subscription form
Previously the reset was applied to .mailpoet_form class but manage subscription form
which also uses these form blocks doesn't have the class.
This commit moves the reset to an internal class that wraps every input and is used
also in the manage subscription page.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Berkay Simsek
6671c573b8 Improve email error message in forms.
Added a 'type-message' for Parsley to display an error message when the input field is filled in incorrectly.
Also removed the global Parsley message to prevent it from overruling the 'required-message'.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Berkay Simsek
75fce3800c Add styling for the for fieldsets to avoid default.
Add styling for the fieldsets to avoid getting the default styling with the black border and unecessary padding and margin.
Applying default or theme styles would cause a BC break for existing forms.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Berkay Simsek
be220c4782 Add a fieldset and legend element to the radio buttons.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Berkay Simsek
b891ca4164 Add a fieldset and legend element to the checkboxes.
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Berkay Simsek
ba45281324 Add fieldset and legend to list selection
Made checkboxes in a form accessible according to the WCAG-standards by adding a fieldset around them and adding a legend describing the fieldset's purpose
(name).
[MAILPOET-4471]
2022-08-03 11:27:06 +02:00
Rostislav Wolny
45e1db5893 Make trigger run less frequent
Checking if there are task to execute every 2 minutes should be enough.
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
db254986ee Fix initial trigger scheduling
When scheduling using timestamp the action scheduler uses default UTC timezone
See 0a294e6df6/functions.php (L330-L339)
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00
Rostislav Wolny
8e9174442c Fix label for attribute in cron settings
[MAILPOET-4274]
2022-08-03 10:36:57 +02:00