Commit Graph

670 Commits

Author SHA1 Message Date
fred
2bb7d95e37 Remove the "Start upgrade" button when the upgrade is completed
Add the "Upgrade completed" message
Add the "Go to MailPoet" button
2017-06-12 13:13:08 +02:00
fred
c64959dce0 Fixed: Segments number can be wrong 2017-06-12 13:13:08 +02:00
fred
ead0792b32 Rename getDataToMigrate() to getDataToMigrateAndResetProgressBar() 2017-06-12 13:13:07 +02:00
fred
7bd52d456c Make the Migration page accessible through admin.php?page=mailpoet-migration 2017-06-12 13:13:06 +02:00
fred
8517896660 Rename imported_data_mapping table to mapping_to_external_entities 2017-06-12 13:13:06 +02:00
fred
c78933f7c4 Numerous fixes following the code review:
H1 title should be "Welcome to MailPoet version 3!", as per wireframes
remove logo in top right of the page
remove the classes feature-section one-col to the parent
new styles for #logger
progress bar: ensure that the color and size for the font are the same as our current progress bar.
display the progress bar at 100% when the import of subscribers and lists is complete
move loadSQL() function in tests/_support/Helper/Database.php
remove CSS browser prefixes
use AMD module definition to embed the JavaScript
remove extra whitespace in JavaScript file
remove the redundant functions descriptions
rename objectPlugin to mailpoet_mp2_migrator
replace private $chunks_size by the constant CHUNK_SIZE
add the constant IMPORT_TIMEOUT_IN_SECONDS
replace Helpers::mysqlDate() by $datetime->formatTime(time(), \MailPoet\WP\DateTime::DEFAULT_DATE_TIME_FORMAT)
make the log messages translatable
fix PHPDoc
replace Env::$plugin_name by 'mailpoet' in the translation functions
use $snake_case for variable names, use lowercaseCamelCase for method names, use CamelCase for class names
define MP2 table names as constants
add spaces around ternary operators
use the models for MP3 entities, instead of counting via raw SQL queries
use \ORM::for_table('some_table')::count()
2017-06-12 13:13:05 +02:00
fred
acfb3aefba Use snake_case 2017-06-12 13:13:04 +02:00
fred
b7f7dc6728 Add unit tests for the MP2Migrator class
Add the method "invokeMethod" in the MailPoetTest class to be able to test private and protected methods
Move the "rowsCount" method in the Helpers class for reusability
Add the method "loadSQL" in the Helpers class
Store the mapping between MP2 user ID and MP3 subscriber ID
2017-06-12 13:13:02 +02:00
fred
ad1e8feb23 QA fixes 2017-06-12 13:13:01 +02:00
fred
472be3b071 Import the MP2 users lists
Import the MP2 users
Add the table "imported_data_mapping"
Add the function Helpers::mysql_date
2017-06-12 13:13:00 +02:00
fred
37a9fd9e1b Use Setting::getValue() and Setting::setValue() instead of get_option() and update_option() 2017-06-12 13:12:59 +02:00
fred
c984ac7a66 New: Display the number of data to migrate
Several fixes following the code review:
- For styles we use Stylus. (http://stylus-lang.com/)
  In Stylus styles curly brackets and terminating semicolons are unnecessary. Indentation is sufficient to denote blocks of styles
  You can also use variables to avoid duplication (e.g. mentioning the same color multiple times)
  Vendor prefixes are not necessary. We use the Nib mixin for Stylus to handle those (http://tj.github.io/nib/)
  => DONE

- `admin.js` bundle is included on all admin pages, so we need to ensure that migration fires only on the migration page and nowhere else.
  You can even create a separate bundle only for migration files, as they won't be necessary on other admin pages.
  => DONE

- MP2MigratorAPI => MP2Migrator endpoint would be just as fine
  => DONE

- For storing migration files, you can use the `Env::$temp_path` path
  => DONE

- `proposeMigration()` the method name disagrees with the comment.
  Comment suggests it tests if migration can be or should be performed
  Method name suggests that it proposes doing the migration (to the user?) - not very clear
  => DONE: the new name is isMigrationNeeded()

  And not only does it test, it may also update the `mailpoet_migration_complete` option, which is confusing and is an unexpected side-effect.
  => DONE

  The migration class itself `MP2Migrator` shouldn't even care about _GET, _REQUEST or _POST arguments. It should only work with what is passed to it.
  => DONE

- In views, please make sure all human-friendly texts use WP's gettext functions for translations (e.g. __('text'))
=> DONE
2017-06-12 13:12:58 +02:00
fred
a1ea56f505 Coding standard fixes 2017-06-12 13:12:58 +02:00
fred
dd7f959731 Migration from Mailpoet 2 to Mailpoet 3 : phase 0
Interface
2017-06-12 13:12:57 +02:00
mrcasual
35c25d3337 Updates length to support IPv4 mapped IPv6 addresses 2017-06-08 13:45:50 +01:00
mrcasual
ae25e95d51 Updates length of columns with IP addresses to 39 2017-06-08 13:45:50 +01:00
stoletniy
95072a9ac5 Restore empty license key warnings [MAILPOET-933] 2017-06-07 12:39:45 +03:00
stoletniy
580dd38b3a Rename methods for consistency and better readability [PREMIUM-9] 2017-06-07 12:39:44 +03:00
stoletniy
47d4e98aae Integrate installer with the Release API [PREMIUM-9] 2017-06-07 12:39:43 +03:00
stoletniy
7ebb7bac17 Add Premium installation/activation UI [PREMIUM-9] 2017-06-07 12:39:43 +03:00
stoletniy
e10fa065bd Add Premium page [MAILPOET-885] 2017-06-07 12:30:42 +03:00
stoletniy
58faf64a5c Add a Premium page link to bounced subscribers listing [MAILPOET-887] 2017-06-07 12:30:39 +03:00
stoletniy
f7efe44f09 Fix ServicesChecker behavior, make MSS check stricter [MAILPOET-890] 2017-06-07 12:30:38 +03:00
stoletniy
7aa0f21d11 Rework 'Send with...' tab UI, make a single license key field [MAILPOET-890] 2017-06-07 12:30:37 +03:00
Tautvidas Sipavičius
c56b56f4aa Apply charset and collation only if they are specified 2017-05-30 21:05:01 +03:00
Tautvidas Sipavičius
a071a14eec Update only those queries, for which conversion will yield correct char
lengths
2017-05-24 15:45:12 +03:00
stoletniy
5ae006b10f Update plugin version [MAILPOET-748] 2017-05-24 15:45:12 +03:00
Tautvidas Sipavičius
9d21ebd26e Fix a comment. UTF8MB4 is a superset of UTF8 2017-05-24 15:45:12 +03:00
Tautvidas Sipavičius
fcff6de3c3 Skip conversion for charset utf8 -> utf8mb4 2017-05-24 15:45:12 +03:00
Tautvidas Sipavičius
a6eb1b06da Add connection charset sync with WP and convert existing data to it 2017-05-24 15:45:12 +03:00
Vlad
8b13889c7a Adds one entry point for both JSON and MP APIs
Removes endpoints folder and moves versions to the root
JSON API folder
2017-05-16 20:56:55 -04:00
Vlad
398d7d3d80 Moves current API under JSON namespace 2017-05-16 20:56:54 -04:00
stoletniy
e71e23bbb5 Temporarily hide invalid key warnings when the license key isn't specified [MAILPOET-911] 2017-05-15 20:16:29 +03:00
Alexey Stoletniy
2eb98905b6 Encapsulate date formatting within the DateTime class [PREMIUM-4] 2017-05-09 08:54:12 +03:00
Alexey Stoletniy
4b1f216cd3 Use WP's date format instead of a hard-coded one [PREMIUM-4] 2017-05-05 18:57:15 +03:00
Alexey Stoletniy
3d5f13a2b8 Fix code style [PREMIUM-4] 2017-05-05 18:41:19 +03:00
Alexey Stoletniy
a7260cba3d Make the Premium key check stricter, split a unit test into more granular ones [PREMIUM-4] 2017-05-05 18:09:00 +03:00
Alexey Stoletniy
787e022382 Rename license key constants and vars, optimize error generation [PREMIUM-4] 2017-05-05 18:04:52 +03:00
Alexey Stoletniy
3cb08e3c09 Rename MSS check methods to better distinguish them from Premium ones [PREMIUM-4] 2017-05-04 09:36:38 +03:00
Alexey Stoletniy
0474985866 Add unit tests [PREMIUM-4] 2017-05-04 09:25:34 +03:00
Alexey Stoletniy
0fbc7fb7eb Add Premium key validation [PREMIUM-4] 2017-05-03 12:20:13 +03:00
Alexey Stoletniy
fbc0a3ad8d Add detailed stats page support in Free [PREMIUM-1] 2017-04-25 12:45:49 +03:00
Vlad
15ddc8454e Adds intval filter and fixes issue with number format applied on IDs
>=1000
2017-04-24 19:25:17 -04:00
Vlad
1dd6c91529 Updates missing requirements language 2017-04-16 23:54:10 -04:00
Vlad
c4f0426775 Adds checker for XML and ZIP extensions 2017-04-16 21:10:15 -04:00
Alexey Stoletniy
16dc81150d Execute mailpoet_initialized hook earlier after setup [PREMIUM-2]
This is done because Router can seize the request and prevent subsequent actions like Premium hooking from being run, so hooks didn't work in cron daemon.
2017-03-20 12:08:40 +03:00
Tautvidas Sipavičius
59f408846a Make all default newsletter templates read-only 2017-02-21 16:32:03 +02:00
Tautvidas Sipavičius
64606e69cf Fix Populator to update existing newsletter templates and remove duplicates 2017-02-21 15:46:28 +02:00
Tautvidas Sipavičius
953c124ef0 Move newsletter template assets to be shared through WP plugin repo 2017-02-21 15:46:28 +02:00
Tautvidas Sipavičius
b3abf46604 Update outdated newsletter template translation strings 2017-02-20 14:58:53 +02:00