Commit Graph

130 Commits

Author SHA1 Message Date
wxa
872ff71f17 Fix first and last name sync on WooCommerce checkout
[MAILPOET-3499]
2021-03-24 09:58:25 +01:00
Pavel Dohnal
ce48153b12 Fix code using the combined segments
[MAILPOET-3212]
2021-03-23 15:58:34 +01:00
Pavel Dohnal
5b45bdac1e Enable joining segments using and/or
[MAILPOET-3212]
2021-03-23 15:58:34 +01:00
Pavel Dohnal
ceae8e17aa Make parameters unique
[MAILPOET-3212]

We need to be able to connect the same segments:
users who are editor or administrator
2021-03-23 15:58:34 +01:00
Pavel Dohnal
7a98abdead Connect dynamic segments filters using UNION select
[MAILPOET-3212]
2021-03-23 15:58:34 +01:00
Rostislav Wolny
9fdebdb4d7 Refactor api for creating/updating dynamic segments
[MAILPOET-3177]
2021-03-10 15:20:32 +01:00
Rostislav Wolny
40c9f047be Refactor segment filter data to embedded object
[MAILPOET-3177]
2021-03-10 15:20:32 +01:00
Rodrigo Primo
844ea3f6d8 Truncate first and last names before adding to wp_mailpoet_subscribers
MailPoet syncs users from wp_users to wp_mailpoet_subscribers. The
problem is that WP stores first and last names in a longtext field and
MP uses a varchar(255) field. This was causing a fatal error when
synchronizing names over 255 characters. This commit fixes this problem
by using SUBSTRING() to make sure that the 255 characters limit is
enforced when adding values to the columns first_name and last_name of
the wp_mailpoet_subscribers table. This should get rid of the fatal
error and it shouldn't be a problem to most users as it is unlikely that
a real user has a first or last name that is longer than 255 characters.

[MAILPOET-3246]
2021-03-02 16:09:47 +01:00
Jan Lysý
f5987359c7 Add integration test on SegmentSaveController
[MAILPOET-3170]
2021-01-26 17:03:48 +01:00
Jan Lysý
180a238b40 Use timestamp for DateTime compare in Segments WPTest
[MAILPOET-3367]
2021-01-25 11:52:25 +01:00
Rostislav Wolny
8456581695 Refactor segment lists fetching methods to separate repository
[MAILPOET-3164]
2021-01-25 09:17:17 +01:00
Pavel Dohnal
4e3dda9872 Fix flakey integration test
[MAILPOET-3336]
2021-01-25 09:04:20 +01:00
Jan Lysý
922c52f7df Remove phpstan errors from the rest of the tests
[MAILPOET-3235]
2021-01-18 14:39:42 +01:00
Pavel Dohnal
b64525ecc5 Migrate tests
[MAILPOET-3168]
2021-01-08 10:37:50 +01:00
Jan Lysý
83cb272555 Use method createOrUpdate from SegmentRepository in tests
[MAILPOET-3167]
2020-12-07 14:48:58 +01:00
Rostislav Wolny
9473579766 Fix type issues in tests
[MAILPOET-3296]
2020-12-07 11:36:01 +01:00
Rostislav Wolny
48ba20602e Handle batch sync of new users for disabled WP users segment
[MAILPOET-3141]
2020-11-09 12:56:17 +01:00
Rostislav Wolny
3dcb939432 Handle adding new WP users to disabled WP segment
[MAILPOET-3141]
2020-11-09 12:56:17 +01:00
Rostislav Wolny
645f888186 Refactor WP Users segment controller to injectable service
[MAILPOET-3141]
2020-11-09 12:56:17 +01:00
Jan Lysý
da15182979 Deny deleting WooCommerce subscribers
[MAILPOET-3138]
2020-10-20 17:22:06 +02:00
Jan Lysý
d5abc80346 Disable restore trashed WP subscribers
[MAILPOET-3138]
2020-10-20 17:22:06 +02:00
Rostislav Wolny
95af49e43f Refactor creating/deleting WordPress users in integration tests
[MAILPOET-3077]
2020-09-29 08:24:11 +02:00
Rostislav Wolny
2f270575f3 Make segment description mandatory
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
c78922c12e Remove unused FinderMock dummy service
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
cd295c7aec Allow fetching count of subscribers with status
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
694d1fae10 Refactor SubscribersFinder to be always injected by container
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
b91687cbc1 Add integration test for SegmentSubscribersRepository
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
c952ef9542 Use only Listing repository in subscribers listing API
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
0437236cf1 Refactor subscriber finder to use new repository
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
ed059670fb Refactor email action filter test to Doctrine
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
00db901d94 Implement email actions filter in Doctrine
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
cf76480ab3 Implement userRole filter using Doctrine
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
bf053edbfb Refactor mailpoet_subscribers_in_segment_apply_bulk_action_handlers to direct calls
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
1a56b2534e Refactor mailpoet_get_subscribers_listings_in_segment_handlers to direct calls
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Rostislav Wolny
dd7390ec73 Refactor mailpoet_get_subscribers_in_segment_finders hook to direct calls
[MAILPOET-3077]
2020-09-28 14:26:53 +02:00
Lysy Jan
ba4fd9eb1b Fix subscriber status resetting on WP user creation
Fixes:#2960
[MAILPOET-3016]
2020-08-04 13:41:48 +02:00
Pavel Dohnal
d166e4b51f Synchronise guest woocommerce users as unconfirmed
[MAILPOET-2799]
2020-04-02 14:24:38 +02:00
Jan Jakeš
81531116e7 Fix signup confirmation email for WP users trigger
[MAILPOET-2700]
2020-02-24 18:59:05 +00:00
Jan Jakeš
c7de47b822 Fix class/interface/trait opening brace on the same line
[MAILPOET-2715]
2020-02-19 19:12:53 +00:00
Jan Jakeš
b39dac75d6 Autofix number of newlines between methods
[MAILPOET-2715]
2020-02-19 19:12:53 +00:00
Jan Jakeš
0dcdf6e9f1 Autofix line endings
[MAILPOET-2715]
2020-02-19 19:12:53 +00:00
Jan Jakeš
835d8bc0af Fix PHPUnit 6 & Codeception\Verify incompatibilities
[MAILPOET-2582]
2020-01-28 20:18:39 +00:00
Pavel Dohnal
4c5155132a Send a confirmation email when a user is added to a website
[MAILPOET-2567]
2020-01-27 09:26:15 +00:00
Jan Jakeš
685b4885c0 Exclude WordPress and WooCommerce variables from camel case conversion
[MAILPOET-1796]
2020-01-14 15:22:42 +01:00
Jan Jakeš
8c848cfa28 Convert property names to camel case
[MAILPOET-1796]
2020-01-14 15:22:42 +01:00
Jan Jakeš
54549ff037 Convert variable names to camel case
[MAILPOET-1796]
2020-01-14 15:22:42 +01:00
wxa
17b578a09f Fix undefined classes and functions [MAILPOET-2488] 2019-12-30 14:51:22 +01:00
wxa
bd1a84c5c3 Fix types by casting [MAILPOET-2488] 2019-12-30 14:51:22 +01:00
wxa
176aba69fe Specify types for mocks [MAILPOET-2488] 2019-12-30 14:51:22 +01:00
wxa
1d757e1374 Fix undefined properties in tests [MAILPOET-2488] 2019-12-30 14:51:22 +01:00