Version Description
(2021-04-26) =
- Added delimiter and date format options in the "Import third party reviews" tool
- Fixed the missing "terms" database column in a fresh install of Site Reviews
Download this release
Release Info
Developer | geminilabs |
Plugin | Site Reviews |
Version | 5.10.0 |
Comparing to | |
See all releases |
Code changes from version 5.9.0 to 5.10.0
- languages/site-reviews-en_US.mo +0 -0
- languages/site-reviews-en_US.po +58 -15
- languages/site-reviews.pot +56 -11
- plugin/Commands/ImportReviews.php +57 -5
- plugin/Controllers/ToolsController.php +2 -2
- plugin/Database/SqlSchema.php +1 -0
- plugin/Helpers/Arr.php +19 -0
- plugin/Modules/Backtrace.php +4 -4
- plugin/Modules/Translation.php +1 -1
- plugin/Tinymce/TinymceGenerator.php +1 -1
- readme.txt +6 -1
- site-reviews.php +1 -1
- views/pages/tools/general/import-reviews.php +23 -2
- views/pages/welcome/upgrade/v500.php +2 -2
- views/pages/welcome/whatsnew.php +1 -0
- views/pages/welcome/whatsnew/v40.php +2 -2
- views/pages/welcome/whatsnew/v41.php +2 -2
- views/pages/welcome/whatsnew/v42.php +2 -2
- views/pages/welcome/whatsnew/v43.php +2 -2
- views/pages/welcome/whatsnew/v44.php +2 -2
- views/pages/welcome/whatsnew/v45.php +2 -2
- views/pages/welcome/whatsnew/v46.php +2 -2
- views/pages/welcome/whatsnew/v50.php +3 -3
- views/pages/welcome/whatsnew/v51.php +2 -2
- views/pages/welcome/whatsnew/v510.php +19 -0
- views/pages/welcome/whatsnew/v52.php +2 -2
- views/pages/welcome/whatsnew/v53.php +2 -2
- views/pages/welcome/whatsnew/v54.php +2 -2
- views/pages/welcome/whatsnew/v55.php +2 -2
- views/pages/welcome/whatsnew/v56.php +2 -2
- views/pages/welcome/whatsnew/v57.php +2 -2
- views/pages/welcome/whatsnew/v58.php +2 -2
- views/pages/welcome/whatsnew/v59.php +3 -3
languages/site-reviews-en_US.mo
CHANGED
Binary file
|
languages/site-reviews-en_US.po
CHANGED
@@ -700,7 +700,7 @@ msgstr ""
|
|
700 |
"href=\"https://api.slack.com/docs/attachments\">Message Attachments</a> "
|
701 |
"have been disabled."
|
702 |
|
703 |
-
#: config/settings.php:132
|
704 |
msgctxt "admin-text"
|
705 |
msgid "Date Format"
|
706 |
msgstr "Date Format"
|
@@ -1604,20 +1604,45 @@ msgctxt "admin-text"
|
|
1604 |
msgid "Pin Your Reviews"
|
1605 |
msgstr "Pin Your Reviews"
|
1606 |
|
1607 |
-
#: plugin/Commands/ImportReviews.php:
|
1608 |
msgctxt "admin-text"
|
1609 |
msgid "%s review was imported."
|
1610 |
msgid_plural "%s reviews were imported."
|
1611 |
msgstr[0] "%s review was imported."
|
1612 |
msgstr[1] "%s reviews were imported."
|
1613 |
|
1614 |
-
#: plugin/Commands/ImportReviews.php:
|
1615 |
msgctxt "admin-text"
|
1616 |
msgid "%s entry was skipped."
|
1617 |
msgid_plural "%s entries were skipped."
|
1618 |
msgstr[0] "%s entry was skipped."
|
1619 |
msgstr[1] "%s entries were skipped."
|
1620 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1621 |
#: plugin/Commands/ImportSettings.php:23
|
1622 |
msgctxt "admin-text"
|
1623 |
msgid "Settings imported."
|
@@ -1770,11 +1795,6 @@ msgctxt "admin-text"
|
|
1770 |
msgid "Sync Reviews"
|
1771 |
msgstr "Sync Reviews"
|
1772 |
|
1773 |
-
#: plugin/Controllers/MenuController.php:145
|
1774 |
-
msgctxt "admin-text"
|
1775 |
-
msgid "Console"
|
1776 |
-
msgstr "Console"
|
1777 |
-
|
1778 |
#: plugin/Controllers/MenuController.php:146
|
1779 |
msgctxt "admin-text"
|
1780 |
msgid "System Info"
|
@@ -3100,12 +3120,10 @@ msgstr ""
|
|
3100 |
msgctxt "admin-text"
|
3101 |
msgid ""
|
3102 |
"Here you can import third party reviews from a %s file. The CSV file should "
|
3103 |
-
"include a header row
|
3104 |
-
"following columns:"
|
3105 |
msgstr ""
|
3106 |
"Here you can import third party reviews from a %s file. The CSV file should "
|
3107 |
-
"include a header row
|
3108 |
-
"following columns:"
|
3109 |
|
3110 |
#: views/pages/tools/general/import-reviews.php:22
|
3111 |
msgctxt "admin-text"
|
@@ -3124,8 +3142,8 @@ msgstr "required"
|
|
3124 |
|
3125 |
#: views/pages/tools/general/import-reviews.php:24
|
3126 |
msgctxt "admin-text"
|
3127 |
-
msgid "The review date
|
3128 |
-
msgstr "The review date
|
3129 |
|
3130 |
#: views/pages/tools/general/import-reviews.php:25
|
3131 |
msgctxt "admin-text"
|
@@ -3169,10 +3187,35 @@ msgstr "Entries in the CSV file that do not contain required values will be skip
|
|
3169 |
|
3170 |
#: views/pages/tools/general/import-reviews.php:41
|
3171 |
msgctxt "admin-text"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3172 |
msgid "Importing reviews, please wait..."
|
3173 |
msgstr "Importing reviews, please wait..."
|
3174 |
|
3175 |
-
#: views/pages/tools/general/import-reviews.php:
|
3176 |
msgctxt "admin-text"
|
3177 |
msgid "Import Reviews"
|
3178 |
msgstr "Import Reviews"
|
700 |
"href=\"https://api.slack.com/docs/attachments\">Message Attachments</a> "
|
701 |
"have been disabled."
|
702 |
|
703 |
+
#: config/settings.php:132, views/pages/tools/general/import-reviews.php:49
|
704 |
msgctxt "admin-text"
|
705 |
msgid "Date Format"
|
706 |
msgstr "Date Format"
|
1604 |
msgid "Pin Your Reviews"
|
1605 |
msgstr "Pin Your Reviews"
|
1606 |
|
1607 |
+
#: plugin/Commands/ImportReviews.php:132
|
1608 |
msgctxt "admin-text"
|
1609 |
msgid "%s review was imported."
|
1610 |
msgid_plural "%s reviews were imported."
|
1611 |
msgstr[0] "%s review was imported."
|
1612 |
msgstr[1] "%s reviews were imported."
|
1613 |
|
1614 |
+
#: plugin/Commands/ImportReviews.php:140
|
1615 |
msgctxt "admin-text"
|
1616 |
msgid "%s entry was skipped."
|
1617 |
msgid_plural "%s entries were skipped."
|
1618 |
msgstr[0] "%s entry was skipped."
|
1619 |
msgstr[1] "%s entries were skipped."
|
1620 |
|
1621 |
+
#: plugin/Commands/ImportReviews.php:143
|
1622 |
+
msgctxt "admin-text"
|
1623 |
+
msgid "See the %s for more details."
|
1624 |
+
msgstr "See the %s for more details."
|
1625 |
+
|
1626 |
+
#: plugin/Commands/ImportReviews.php:146, plugin/Controllers/MenuController.php:145
|
1627 |
+
msgctxt "admin-text"
|
1628 |
+
msgid "Console"
|
1629 |
+
msgstr "Console"
|
1630 |
+
|
1631 |
+
#: plugin/Commands/ImportReviews.php:167
|
1632 |
+
msgctxt "admin-text"
|
1633 |
+
msgid "invalid date"
|
1634 |
+
msgstr "invalid date"
|
1635 |
+
|
1636 |
+
#: plugin/Commands/ImportReviews.php:168
|
1637 |
+
msgctxt "admin-text"
|
1638 |
+
msgid "invalid content"
|
1639 |
+
msgstr "invalid content"
|
1640 |
+
|
1641 |
+
#: plugin/Commands/ImportReviews.php:169
|
1642 |
+
msgctxt "admin-text"
|
1643 |
+
msgid "invalid rating"
|
1644 |
+
msgstr "invalid rating"
|
1645 |
+
|
1646 |
#: plugin/Commands/ImportSettings.php:23
|
1647 |
msgctxt "admin-text"
|
1648 |
msgid "Settings imported."
|
1795 |
msgid "Sync Reviews"
|
1796 |
msgstr "Sync Reviews"
|
1797 |
|
|
|
|
|
|
|
|
|
|
|
1798 |
#: plugin/Controllers/MenuController.php:146
|
1799 |
msgctxt "admin-text"
|
1800 |
msgid "System Info"
|
3120 |
msgctxt "admin-text"
|
3121 |
msgid ""
|
3122 |
"Here you can import third party reviews from a %s file. The CSV file should "
|
3123 |
+
"include a header row and may contain the following columns:"
|
|
|
3124 |
msgstr ""
|
3125 |
"Here you can import third party reviews from a %s file. The CSV file should "
|
3126 |
+
"include a header row and may contain the following columns:"
|
|
|
3127 |
|
3128 |
#: views/pages/tools/general/import-reviews.php:22
|
3129 |
msgctxt "admin-text"
|
3142 |
|
3143 |
#: views/pages/tools/general/import-reviews.php:24
|
3144 |
msgctxt "admin-text"
|
3145 |
+
msgid "The review date"
|
3146 |
+
msgstr "The review date"
|
3147 |
|
3148 |
#: views/pages/tools/general/import-reviews.php:25
|
3149 |
msgctxt "admin-text"
|
3187 |
|
3188 |
#: views/pages/tools/general/import-reviews.php:41
|
3189 |
msgctxt "admin-text"
|
3190 |
+
msgid "Delimiter"
|
3191 |
+
msgstr "Delimiter"
|
3192 |
+
|
3193 |
+
#: views/pages/tools/general/import-reviews.php:43
|
3194 |
+
msgctxt "admin-text"
|
3195 |
+
msgid "Select the delimiter used in the CSV file"
|
3196 |
+
msgstr "Select the delimiter used in the CSV file"
|
3197 |
+
|
3198 |
+
#: views/pages/tools/general/import-reviews.php:44
|
3199 |
+
msgctxt "admin-text"
|
3200 |
+
msgid "Commas (,)"
|
3201 |
+
msgstr "Commas (,)"
|
3202 |
+
|
3203 |
+
#: views/pages/tools/general/import-reviews.php:45
|
3204 |
+
msgctxt "admin-text"
|
3205 |
+
msgid "Semicolons (;)"
|
3206 |
+
msgstr "Semicolons (;)"
|
3207 |
+
|
3208 |
+
#: views/pages/tools/general/import-reviews.php:51
|
3209 |
+
msgctxt "admin-text"
|
3210 |
+
msgid "Select the date format used in the reviews"
|
3211 |
+
msgstr "Select the date format used in the reviews"
|
3212 |
+
|
3213 |
+
#: views/pages/tools/general/import-reviews.php:62
|
3214 |
+
msgctxt "admin-text"
|
3215 |
msgid "Importing reviews, please wait..."
|
3216 |
msgstr "Importing reviews, please wait..."
|
3217 |
|
3218 |
+
#: views/pages/tools/general/import-reviews.php:62
|
3219 |
msgctxt "admin-text"
|
3220 |
msgid "Import Reviews"
|
3221 |
msgstr "Import Reviews"
|
languages/site-reviews.pot
CHANGED
@@ -353,7 +353,7 @@ msgctxt "admin-text"
|
|
353 |
msgid "To restore the default text, save an empty template. If you are sending notifications to Slack then this template will only be used as a fallback in the event that <a href=\"https://api.slack.com/docs/attachments\">Message Attachments</a> have been disabled."
|
354 |
msgstr ""
|
355 |
|
356 |
-
#: config/settings.php:132
|
357 |
msgctxt "admin-text"
|
358 |
msgid "Date Format"
|
359 |
msgstr ""
|
@@ -1233,20 +1233,45 @@ msgctxt "admin-text"
|
|
1233 |
msgid "Pin Your Reviews"
|
1234 |
msgstr ""
|
1235 |
|
1236 |
-
#: plugin/Commands/ImportReviews.php:
|
1237 |
msgctxt "admin-text"
|
1238 |
msgid "%s review was imported."
|
1239 |
msgid_plural "%s reviews were imported."
|
1240 |
msgstr[0] ""
|
1241 |
msgstr[1] ""
|
1242 |
|
1243 |
-
#: plugin/Commands/ImportReviews.php:
|
1244 |
msgctxt "admin-text"
|
1245 |
msgid "%s entry was skipped."
|
1246 |
msgid_plural "%s entries were skipped."
|
1247 |
msgstr[0] ""
|
1248 |
msgstr[1] ""
|
1249 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1250 |
#: plugin/Commands/ImportSettings.php:23
|
1251 |
msgctxt "admin-text"
|
1252 |
msgid "Settings imported."
|
@@ -1409,11 +1434,6 @@ msgctxt "admin-text"
|
|
1409 |
msgid "Sync Reviews"
|
1410 |
msgstr ""
|
1411 |
|
1412 |
-
#: plugin/Controllers/MenuController.php:145
|
1413 |
-
msgctxt "admin-text"
|
1414 |
-
msgid "Console"
|
1415 |
-
msgstr ""
|
1416 |
-
|
1417 |
#: plugin/Controllers/MenuController.php:146
|
1418 |
msgctxt "admin-text"
|
1419 |
msgid "System Info"
|
@@ -2950,7 +2970,7 @@ msgstr ""
|
|
2950 |
|
2951 |
#: views/pages/tools/general/import-reviews.php:18
|
2952 |
msgctxt "admin-text"
|
2953 |
-
msgid "Here you can import third party reviews from a %s file. The CSV file should include a header row
|
2954 |
msgstr ""
|
2955 |
|
2956 |
#: views/pages/tools/general/import-reviews.php:22
|
@@ -2970,7 +2990,7 @@ msgstr ""
|
|
2970 |
|
2971 |
#: views/pages/tools/general/import-reviews.php:24
|
2972 |
msgctxt "admin-text"
|
2973 |
-
msgid "The review date
|
2974 |
msgstr ""
|
2975 |
|
2976 |
#: views/pages/tools/general/import-reviews.php:25
|
@@ -3015,10 +3035,35 @@ msgstr ""
|
|
3015 |
|
3016 |
#: views/pages/tools/general/import-reviews.php:41
|
3017 |
msgctxt "admin-text"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3018 |
msgid "Importing reviews, please wait..."
|
3019 |
msgstr ""
|
3020 |
|
3021 |
-
#: views/pages/tools/general/import-reviews.php:
|
3022 |
msgctxt "admin-text"
|
3023 |
msgid "Import Reviews"
|
3024 |
msgstr ""
|
353 |
msgid "To restore the default text, save an empty template. If you are sending notifications to Slack then this template will only be used as a fallback in the event that <a href=\"https://api.slack.com/docs/attachments\">Message Attachments</a> have been disabled."
|
354 |
msgstr ""
|
355 |
|
356 |
+
#: config/settings.php:132, views/pages/tools/general/import-reviews.php:49
|
357 |
msgctxt "admin-text"
|
358 |
msgid "Date Format"
|
359 |
msgstr ""
|
1233 |
msgid "Pin Your Reviews"
|
1234 |
msgstr ""
|
1235 |
|
1236 |
+
#: plugin/Commands/ImportReviews.php:132
|
1237 |
msgctxt "admin-text"
|
1238 |
msgid "%s review was imported."
|
1239 |
msgid_plural "%s reviews were imported."
|
1240 |
msgstr[0] ""
|
1241 |
msgstr[1] ""
|
1242 |
|
1243 |
+
#: plugin/Commands/ImportReviews.php:140
|
1244 |
msgctxt "admin-text"
|
1245 |
msgid "%s entry was skipped."
|
1246 |
msgid_plural "%s entries were skipped."
|
1247 |
msgstr[0] ""
|
1248 |
msgstr[1] ""
|
1249 |
|
1250 |
+
#: plugin/Commands/ImportReviews.php:143
|
1251 |
+
msgctxt "admin-text"
|
1252 |
+
msgid "See the %s for more details."
|
1253 |
+
msgstr ""
|
1254 |
+
|
1255 |
+
#: plugin/Commands/ImportReviews.php:146, plugin/Controllers/MenuController.php:145
|
1256 |
+
msgctxt "admin-text"
|
1257 |
+
msgid "Console"
|
1258 |
+
msgstr ""
|
1259 |
+
|
1260 |
+
#: plugin/Commands/ImportReviews.php:167
|
1261 |
+
msgctxt "admin-text"
|
1262 |
+
msgid "invalid date"
|
1263 |
+
msgstr ""
|
1264 |
+
|
1265 |
+
#: plugin/Commands/ImportReviews.php:168
|
1266 |
+
msgctxt "admin-text"
|
1267 |
+
msgid "invalid content"
|
1268 |
+
msgstr ""
|
1269 |
+
|
1270 |
+
#: plugin/Commands/ImportReviews.php:169
|
1271 |
+
msgctxt "admin-text"
|
1272 |
+
msgid "invalid rating"
|
1273 |
+
msgstr ""
|
1274 |
+
|
1275 |
#: plugin/Commands/ImportSettings.php:23
|
1276 |
msgctxt "admin-text"
|
1277 |
msgid "Settings imported."
|
1434 |
msgid "Sync Reviews"
|
1435 |
msgstr ""
|
1436 |
|
|
|
|
|
|
|
|
|
|
|
1437 |
#: plugin/Controllers/MenuController.php:146
|
1438 |
msgctxt "admin-text"
|
1439 |
msgid "System Info"
|
2970 |
|
2971 |
#: views/pages/tools/general/import-reviews.php:18
|
2972 |
msgctxt "admin-text"
|
2973 |
+
msgid "Here you can import third party reviews from a %s file. The CSV file should include a header row and may contain the following columns:"
|
2974 |
msgstr ""
|
2975 |
|
2976 |
#: views/pages/tools/general/import-reviews.php:22
|
2990 |
|
2991 |
#: views/pages/tools/general/import-reviews.php:24
|
2992 |
msgctxt "admin-text"
|
2993 |
+
msgid "The review date"
|
2994 |
msgstr ""
|
2995 |
|
2996 |
#: views/pages/tools/general/import-reviews.php:25
|
3035 |
|
3036 |
#: views/pages/tools/general/import-reviews.php:41
|
3037 |
msgctxt "admin-text"
|
3038 |
+
msgid "Delimiter"
|
3039 |
+
msgstr ""
|
3040 |
+
|
3041 |
+
#: views/pages/tools/general/import-reviews.php:43
|
3042 |
+
msgctxt "admin-text"
|
3043 |
+
msgid "Select the delimiter used in the CSV file"
|
3044 |
+
msgstr ""
|
3045 |
+
|
3046 |
+
#: views/pages/tools/general/import-reviews.php:44
|
3047 |
+
msgctxt "admin-text"
|
3048 |
+
msgid "Commas (,)"
|
3049 |
+
msgstr ""
|
3050 |
+
|
3051 |
+
#: views/pages/tools/general/import-reviews.php:45
|
3052 |
+
msgctxt "admin-text"
|
3053 |
+
msgid "Semicolons (;)"
|
3054 |
+
msgstr ""
|
3055 |
+
|
3056 |
+
#: views/pages/tools/general/import-reviews.php:51
|
3057 |
+
msgctxt "admin-text"
|
3058 |
+
msgid "Select the date format used in the reviews"
|
3059 |
+
msgstr ""
|
3060 |
+
|
3061 |
+
#: views/pages/tools/general/import-reviews.php:62
|
3062 |
+
msgctxt "admin-text"
|
3063 |
msgid "Importing reviews, please wait..."
|
3064 |
msgstr ""
|
3065 |
|
3066 |
+
#: views/pages/tools/general/import-reviews.php:62
|
3067 |
msgctxt "admin-text"
|
3068 |
msgid "Import Reviews"
|
3069 |
msgstr ""
|
plugin/Commands/ImportReviews.php
CHANGED
@@ -8,6 +8,7 @@ use GeminiLabs\League\Csv\Statement;
|
|
8 |
use GeminiLabs\SiteReviews\Contracts\CommandContract as Contract;
|
9 |
use GeminiLabs\SiteReviews\Database\ReviewManager;
|
10 |
use GeminiLabs\SiteReviews\Helpers\Arr;
|
|
|
11 |
use GeminiLabs\SiteReviews\Modules\Date;
|
12 |
use GeminiLabs\SiteReviews\Modules\Notice;
|
13 |
use GeminiLabs\SiteReviews\Modules\Rating;
|
@@ -16,15 +17,47 @@ use GeminiLabs\SiteReviews\Upload;
|
|
16 |
|
17 |
class ImportReviews extends Upload implements Contract
|
18 |
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
19 |
const REQUIRED_KEYS = [
|
20 |
'content', 'date', 'rating',
|
21 |
];
|
22 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
23 |
/**
|
24 |
* @var int
|
25 |
*/
|
26 |
protected $totalRecords = 0;
|
27 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
28 |
/**
|
29 |
* @return void
|
30 |
*/
|
@@ -55,10 +88,11 @@ class ImportReviews extends Upload implements Contract
|
|
55 |
try {
|
56 |
wp_raise_memory_limit('admin');
|
57 |
$reader = Reader::createFromPath($this->file()->tmp_name);
|
|
|
58 |
$reader->setHeaderOffset(0);
|
59 |
$header = array_map('trim', $reader->getHeader());
|
60 |
if (!empty(array_diff(static::REQUIRED_KEYS, $header))) {
|
61 |
-
throw new Exception('The CSV import header is missing required columns.');
|
62 |
}
|
63 |
$this->totalRecords = count($reader);
|
64 |
$records = Statement::create()
|
@@ -79,6 +113,8 @@ class ImportReviews extends Upload implements Contract
|
|
79 |
protected function importRecords($records)
|
80 |
{
|
81 |
foreach ($records as $offset => $record) {
|
|
|
|
|
82 |
$request = new Request($record);
|
83 |
$command = new CreateReview($request);
|
84 |
glsr(ReviewManager::class)->createRaw($command);
|
@@ -104,7 +140,14 @@ class ImportReviews extends Upload implements Contract
|
|
104 |
_nx('%s entry was skipped.', '%s entries were skipped.', $skippedRecords, 'admin-text', 'site-reviews'),
|
105 |
number_format_i18n($skippedRecords)
|
106 |
);
|
107 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
108 |
}
|
109 |
|
110 |
/**
|
@@ -112,12 +155,21 @@ class ImportReviews extends Upload implements Contract
|
|
112 |
*/
|
113 |
protected function validateRecord(array $record)
|
114 |
{
|
115 |
-
$date = Arr::get($record, 'date');
|
116 |
$required = [
|
117 |
-
'date' => glsr(Date::class)->isValid(
|
118 |
'content' => !empty($record['content']),
|
119 |
'rating' => glsr(Rating::class)->isValid(Arr::get($record, 'rating')),
|
120 |
];
|
121 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
122 |
}
|
123 |
}
|
8 |
use GeminiLabs\SiteReviews\Contracts\CommandContract as Contract;
|
9 |
use GeminiLabs\SiteReviews\Database\ReviewManager;
|
10 |
use GeminiLabs\SiteReviews\Helpers\Arr;
|
11 |
+
use GeminiLabs\SiteReviews\Helpers\Str;
|
12 |
use GeminiLabs\SiteReviews\Modules\Date;
|
13 |
use GeminiLabs\SiteReviews\Modules\Notice;
|
14 |
use GeminiLabs\SiteReviews\Modules\Rating;
|
17 |
|
18 |
class ImportReviews extends Upload implements Contract
|
19 |
{
|
20 |
+
const ALLOWED_DATE_FORMATS = [
|
21 |
+
'd-m-Y', 'd/m/Y',
|
22 |
+
'm-d-Y', 'm/d/Y',
|
23 |
+
'Y-m-d', 'Y-m-d H:i:s', 'Y/m/d',
|
24 |
+
];
|
25 |
+
|
26 |
+
const ALLOWED_DELIMITERS = [
|
27 |
+
',', ';',
|
28 |
+
];
|
29 |
+
|
30 |
const REQUIRED_KEYS = [
|
31 |
'content', 'date', 'rating',
|
32 |
];
|
33 |
|
34 |
+
/**
|
35 |
+
* @var string
|
36 |
+
*/
|
37 |
+
protected $date_format = 'Y-m-d';
|
38 |
+
|
39 |
+
/**
|
40 |
+
* @var string
|
41 |
+
*/
|
42 |
+
protected $delimiter = ',';
|
43 |
+
|
44 |
+
/**
|
45 |
+
* @var string[]
|
46 |
+
*/
|
47 |
+
protected $errors = [];
|
48 |
+
|
49 |
/**
|
50 |
* @var int
|
51 |
*/
|
52 |
protected $totalRecords = 0;
|
53 |
|
54 |
+
public function __construct(Request $request)
|
55 |
+
{
|
56 |
+
$this->date_format = Str::restrictTo(static::ALLOWED_DATE_FORMATS, $request->date_format, 'Y-m-d');
|
57 |
+
$this->delimiter = Str::restrictTo(static::ALLOWED_DELIMITERS, $request->delimiter, ',');
|
58 |
+
$this->errors = [];
|
59 |
+
}
|
60 |
+
|
61 |
/**
|
62 |
* @return void
|
63 |
*/
|
88 |
try {
|
89 |
wp_raise_memory_limit('admin');
|
90 |
$reader = Reader::createFromPath($this->file()->tmp_name);
|
91 |
+
$reader->setDelimiter($this->delimiter);
|
92 |
$reader->setHeaderOffset(0);
|
93 |
$header = array_map('trim', $reader->getHeader());
|
94 |
if (!empty(array_diff(static::REQUIRED_KEYS, $header))) {
|
95 |
+
throw new Exception('The CSV import header is missing the required columns (did you select the correct delimiter?).');
|
96 |
}
|
97 |
$this->totalRecords = count($reader);
|
98 |
$records = Statement::create()
|
113 |
protected function importRecords($records)
|
114 |
{
|
115 |
foreach ($records as $offset => $record) {
|
116 |
+
$date = \DateTime::createFromFormat($this->date_format, $record['date']);
|
117 |
+
$record['date'] = $date->format('Y-m-d H:i:s'); // format the provided date
|
118 |
$request = new Request($record);
|
119 |
$command = new CreateReview($request);
|
120 |
glsr(ReviewManager::class)->createRaw($command);
|
140 |
_nx('%s entry was skipped.', '%s entries were skipped.', $skippedRecords, 'admin-text', 'site-reviews'),
|
141 |
number_format_i18n($skippedRecords)
|
142 |
);
|
143 |
+
$consoleLink = sprintf(_x('See the %s for more details.', 'admin-text', 'site-reviews'),
|
144 |
+
sprintf('<a href="%s">%s</a>)',
|
145 |
+
admin_url('edit.php?post_type='.glsr()->post_type.'&page=tools#tab-console'),
|
146 |
+
_x('Console', 'admin-text', 'site-reviews')
|
147 |
+
)
|
148 |
+
);
|
149 |
+
glsr(Notice::class)->addWarning(sprintf('%s (%s)', sprintf('%s %s', $notice, $skipped), $consoleLink));
|
150 |
+
glsr_log()->warning(sprintf('One or more of the following errors were encountered during import: %s', Str::naturalJoin($this->errors)));
|
151 |
}
|
152 |
|
153 |
/**
|
155 |
*/
|
156 |
protected function validateRecord(array $record)
|
157 |
{
|
|
|
158 |
$required = [
|
159 |
+
'date' => glsr(Date::class)->isValid(Arr::get($record, 'date'), $this->date_format),
|
160 |
'content' => !empty($record['content']),
|
161 |
'rating' => glsr(Rating::class)->isValid(Arr::get($record, 'rating')),
|
162 |
];
|
163 |
+
if (count(array_filter($required)) === 3) {
|
164 |
+
return true;
|
165 |
+
}
|
166 |
+
$errorMessages = [
|
167 |
+
'date' => _x('invalid date', 'admin-text', 'site-reviews'),
|
168 |
+
'content' => _x('invalid content', 'admin-text', 'site-reviews'),
|
169 |
+
'rating' => _x('invalid rating', 'admin-text', 'site-reviews'),
|
170 |
+
];
|
171 |
+
$errors = array_intersect_key($errorMessages, array_diff_key($required, array_filter($required)));
|
172 |
+
$this->errors = array_merge($this->errors, $errors);
|
173 |
+
return false;
|
174 |
}
|
175 |
}
|
plugin/Controllers/ToolsController.php
CHANGED
@@ -166,9 +166,9 @@ class ToolsController extends Controller
|
|
166 |
* @return void
|
167 |
* @action site-reviews/route/admin/import-reviews
|
168 |
*/
|
169 |
-
public function importReviews()
|
170 |
{
|
171 |
-
$this->execute(new ImportReviews());
|
172 |
}
|
173 |
|
174 |
/**
|
166 |
* @return void
|
167 |
* @action site-reviews/route/admin/import-reviews
|
168 |
*/
|
169 |
+
public function importReviews(Request $request)
|
170 |
{
|
171 |
+
$this->execute(new ImportReviews($request));
|
172 |
}
|
173 |
|
174 |
/**
|
plugin/Database/SqlSchema.php
CHANGED
@@ -254,6 +254,7 @@ class SqlSchema
|
|
254 |
avatar varchar(200) DEFAULT NULL,
|
255 |
ip_address varchar(100) DEFAULT NULL,
|
256 |
url varchar(250) DEFAULT NULL,
|
|
|
257 |
PRIMARY KEY (ID),
|
258 |
UNIQUE KEY {$this->prefix('ratings_review_id_unique')} (review_id),
|
259 |
KEY {$this->prefix('ratings_rating_type_is_pinned_index')} (rating,type,is_pinned)
|
254 |
avatar varchar(200) DEFAULT NULL,
|
255 |
ip_address varchar(100) DEFAULT NULL,
|
256 |
url varchar(250) DEFAULT NULL,
|
257 |
+
terms tinyint(1) NOT NULL DEFAULT '1',
|
258 |
PRIMARY KEY (ID),
|
259 |
UNIQUE KEY {$this->prefix('ratings_review_id_unique')} (review_id),
|
260 |
KEY {$this->prefix('ratings_rating_type_is_pinned_index')} (rating,type,is_pinned)
|
plugin/Helpers/Arr.php
CHANGED
@@ -241,6 +241,25 @@ class Arr
|
|
241 |
return $result;
|
242 |
}
|
243 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
244 |
/**
|
245 |
* Set a value to an array of values using a dot-notation path as reference.
|
246 |
* @param mixed $data
|
241 |
return $result;
|
242 |
}
|
243 |
|
244 |
+
/**
|
245 |
+
* Search a multidimensional array by key value
|
246 |
+
* @param mixed $needle
|
247 |
+
* @param array $haystack
|
248 |
+
* @param int|string $key
|
249 |
+
* @return array|false
|
250 |
+
*/
|
251 |
+
public static function searchByKey($needle, $haystack, $key)
|
252 |
+
{
|
253 |
+
if (!is_array($haystack) || array_diff_key($haystack, array_filter($haystack, 'is_array'))) {
|
254 |
+
return false;
|
255 |
+
}
|
256 |
+
$index = array_search($needle, wp_list_pluck($haystack, $key));
|
257 |
+
if (false !== $index) {
|
258 |
+
return $haystack[$index];
|
259 |
+
}
|
260 |
+
return false;
|
261 |
+
}
|
262 |
+
|
263 |
/**
|
264 |
* Set a value to an array of values using a dot-notation path as reference.
|
265 |
* @param mixed $data
|
plugin/Modules/Backtrace.php
CHANGED
@@ -72,9 +72,9 @@ class Backtrace
|
|
72 |
{
|
73 |
$file = Arr::get($backtrace, '0.file');
|
74 |
$class = Arr::get($backtrace, '1.class');
|
75 |
-
$search =
|
76 |
if (false !== $search) {
|
77 |
-
$class = Arr::get($
|
78 |
} elseif (Str::endsWith('helpers.php', $file)) {
|
79 |
$file = Arr::get($backtrace, '1.file');
|
80 |
$class = Arr::get($backtrace, '2.class');
|
@@ -89,9 +89,9 @@ class Backtrace
|
|
89 |
*/
|
90 |
protected function getLineNumber(array $backtrace)
|
91 |
{
|
92 |
-
$search =
|
93 |
if (false !== $search) {
|
94 |
-
return Arr::get($
|
95 |
}
|
96 |
$file = Arr::get($backtrace, '0.file');
|
97 |
$line = Arr::get($backtrace, '0.line');
|
72 |
{
|
73 |
$file = Arr::get($backtrace, '0.file');
|
74 |
$class = Arr::get($backtrace, '1.class');
|
75 |
+
$search = Arr::searchByKey('glsr_log', $backtrace, 'function');
|
76 |
if (false !== $search) {
|
77 |
+
$class = Arr::get($search, 'class', Arr::get($search, 'file'));
|
78 |
} elseif (Str::endsWith('helpers.php', $file)) {
|
79 |
$file = Arr::get($backtrace, '1.file');
|
80 |
$class = Arr::get($backtrace, '2.class');
|
89 |
*/
|
90 |
protected function getLineNumber(array $backtrace)
|
91 |
{
|
92 |
+
$search = Arr::searchByKey('glsr_log', $backtrace, 'function');
|
93 |
if (false !== $search) {
|
94 |
+
return Arr::get($search, 'line');
|
95 |
}
|
96 |
$file = Arr::get($backtrace, '0.file');
|
97 |
$line = Arr::get($backtrace, '0.line');
|
plugin/Modules/Translation.php
CHANGED
@@ -116,7 +116,7 @@ class Translation
|
|
116 |
$entry
|
117 |
);
|
118 |
$data['data.class'] = $data['data.error'] = '';
|
119 |
-
if (false ===
|
120 |
$data['data.class'] = 'is-invalid';
|
121 |
$data['data.error'] = _x('This custom translation is no longer valid as the original text has been changed or removed.', 'admin-text', 'site-reviews');
|
122 |
}
|
116 |
$entry
|
117 |
);
|
118 |
$data['data.class'] = $data['data.error'] = '';
|
119 |
+
if (false === Arr::searchByKey($entry['s1'], $this->entries(), 'msgid')) { // @todo handle htmlentities i.e. →
|
120 |
$data['data.class'] = 'is-invalid';
|
121 |
$data['data.error'] = _x('This custom translation is no longer valid as the original text has been changed or removed.', 'admin-text', 'site-reviews');
|
122 |
}
|
plugin/Tinymce/TinymceGenerator.php
CHANGED
@@ -99,7 +99,7 @@ abstract class TinymceGenerator
|
|
99 |
if (!empty($this->errors)) {
|
100 |
$errors = [];
|
101 |
foreach ($this->required as $name => $alert) {
|
102 |
-
if (false ===
|
103 |
$errors[] = $this->errors[$name];
|
104 |
}
|
105 |
}
|
99 |
if (!empty($this->errors)) {
|
100 |
$errors = [];
|
101 |
foreach ($this->required as $name => $alert) {
|
102 |
+
if (false === Arr::searchByKey($name, $fields, 'name')) {
|
103 |
$errors[] = $this->errors[$name];
|
104 |
}
|
105 |
}
|
readme.txt
CHANGED
@@ -5,7 +5,7 @@ Tags: reviews, ratings, testimonials, woocommerce, product reviews
|
|
5 |
Tested up to: 5.7
|
6 |
Requires at least: 5.5
|
7 |
Requires PHP: 5.6
|
8 |
-
Stable tag: 5.
|
9 |
License: GPLv3
|
10 |
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
@@ -135,6 +135,11 @@ All documentation can be found in the "Help" page of the plugin. If your questio
|
|
135 |
|
136 |
## Changelog
|
137 |
|
|
|
|
|
|
|
|
|
|
|
138 |
= 5.9.0 (2021-04-24) =
|
139 |
|
140 |
- Added a "Compatibility Issues" section to the Help page to document incompatible plugins along with possible workarounds.
|
5 |
Tested up to: 5.7
|
6 |
Requires at least: 5.5
|
7 |
Requires PHP: 5.6
|
8 |
+
Stable tag: 5.10.0
|
9 |
License: GPLv3
|
10 |
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
135 |
|
136 |
## Changelog
|
137 |
|
138 |
+
= 5.10.0 (2021-04-26) =
|
139 |
+
|
140 |
+
- Added delimiter and date format options in the "Import third party reviews" tool
|
141 |
+
- Fixed the missing "terms" database column in a fresh install of Site Reviews
|
142 |
+
|
143 |
= 5.9.0 (2021-04-24) =
|
144 |
|
145 |
- Added a "Compatibility Issues" section to the Help page to document incompatible plugins along with possible workarounds.
|
site-reviews.php
CHANGED
@@ -7,7 +7,7 @@
|
|
7 |
* Plugin Name: Site Reviews
|
8 |
* Plugin URI: https://wordpress.org/plugins/site-reviews
|
9 |
* Description: Receive and display reviews on your website
|
10 |
-
* Version: 5.
|
11 |
* Author: Paul Ryley
|
12 |
* Author URI: https://geminilabs.io
|
13 |
* License: GPL2
|
7 |
* Plugin Name: Site Reviews
|
8 |
* Plugin URI: https://wordpress.org/plugins/site-reviews
|
9 |
* Description: Receive and display reviews on your website
|
10 |
+
* Version: 5.10.0
|
11 |
* Author: Paul Ryley
|
12 |
* Author URI: https://geminilabs.io
|
13 |
* License: GPL2
|
views/pages/tools/general/import-reviews.php
CHANGED
@@ -15,13 +15,13 @@
|
|
15 |
); ?></p>
|
16 |
</div>
|
17 |
<p><?= sprintf(
|
18 |
-
_x('Here you can import third party reviews from a %s file. The CSV file should include a header row
|
19 |
'<code>*.CSV</code>'
|
20 |
); ?></p>
|
21 |
<p>
|
22 |
<code>avatar</code> <?= _x('The avatar URL of the reviewer', 'admin-text', 'site-reviews'); ?><br>
|
23 |
<code>content</code> <?= sprintf('%s (<span class="required">%s</span>)', _x('The review', 'admin-text', 'site-reviews'), _x('required', 'admin-text', 'site-reviews')); ?><br>
|
24 |
-
<code>date</code> <?= sprintf('%s (<span class="required">%s</span>)',
|
25 |
<code>email</code> <?= _x('The reviewer\'s email', 'admin-text', 'site-reviews'); ?><br>
|
26 |
<code>ip_address</code> <?= _x('The IP address of the reviewer', 'admin-text', 'site-reviews'); ?><br>
|
27 |
<code>is_pinned</code> <?= _x('TRUE or FALSE', 'admin-text', 'site-reviews'); ?><br>
|
@@ -37,6 +37,27 @@
|
|
37 |
<p>
|
38 |
<input type="file" name="import-file" accept="text/csv">
|
39 |
</p>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
40 |
<button type="submit" class="glsr-button components-button is-secondary" id="import-reviews" data-expand="#tools-import-reviews">
|
41 |
<span data-loading="<?= esc_attr_x('Importing reviews, please wait...', 'admin-text', 'site-reviews'); ?>"><?= _x('Import Reviews', 'admin-text', 'site-reviews'); ?></span>
|
42 |
</button>
|
15 |
); ?></p>
|
16 |
</div>
|
17 |
<p><?= sprintf(
|
18 |
+
_x('Here you can import third party reviews from a %s file. The CSV file should include a header row and may contain the following columns:', 'admin-text', 'site-reviews'),
|
19 |
'<code>*.CSV</code>'
|
20 |
); ?></p>
|
21 |
<p>
|
22 |
<code>avatar</code> <?= _x('The avatar URL of the reviewer', 'admin-text', 'site-reviews'); ?><br>
|
23 |
<code>content</code> <?= sprintf('%s (<span class="required">%s</span>)', _x('The review', 'admin-text', 'site-reviews'), _x('required', 'admin-text', 'site-reviews')); ?><br>
|
24 |
+
<code>date</code> <?= sprintf('%s (<span class="required">%s</span>)', _x('The review date', 'admin-text', 'site-reviews'), _x('required', 'admin-text', 'site-reviews')); ?><br>
|
25 |
<code>email</code> <?= _x('The reviewer\'s email', 'admin-text', 'site-reviews'); ?><br>
|
26 |
<code>ip_address</code> <?= _x('The IP address of the reviewer', 'admin-text', 'site-reviews'); ?><br>
|
27 |
<code>is_pinned</code> <?= _x('TRUE or FALSE', 'admin-text', 'site-reviews'); ?><br>
|
37 |
<p>
|
38 |
<input type="file" name="import-file" accept="text/csv">
|
39 |
</p>
|
40 |
+
<p>
|
41 |
+
<label for="csv_delimiter"><strong><?= _x('Delimiter', 'admin-text', 'site-reviews'); ?></strong></label><br>
|
42 |
+
<select name="{{ id }}[delimiter]" id="csv_delimiter" required>
|
43 |
+
<option value=""><?= _x('Select the delimiter used in the CSV file', 'admin-text', 'site-reviews'); ?></option>
|
44 |
+
<option value=","><?= _x('Commas (,)', 'admin-text', 'site-reviews'); ?></option>
|
45 |
+
<option value=";"><?= _x('Semicolons (;)', 'admin-text', 'site-reviews'); ?></option>
|
46 |
+
</select>
|
47 |
+
</p>
|
48 |
+
<p>
|
49 |
+
<label for="csv_date_format"><strong><?= _x('Date Format', 'admin-text', 'site-reviews'); ?></strong></label><br>
|
50 |
+
<select name="{{ id }}[date_format]" id="csv_date_format" required>
|
51 |
+
<option value=""><?= _x('Select the date format used in the reviews', 'admin-text', 'site-reviews'); ?></option>
|
52 |
+
<option value="d-m-Y">d-m-Y (13-01-2021)</option>
|
53 |
+
<option value="d/m/Y">d/m/Y (13/01/2021)</option>
|
54 |
+
<option value="m-d-Y">m-d-Y (01-13-2021)</option>
|
55 |
+
<option value="m/d/Y">m/d/Y (01/13/2021)</option>
|
56 |
+
<option value="Y-m-d">Y-m-d (2021-01-13)</option>
|
57 |
+
<option value="Y-m-d H:i:s">Y-m-d H:i:s (2021-01-13 12:00:00)</option>
|
58 |
+
<option value="Y/m/d">Y/m/d (2021/01/13)</option>
|
59 |
+
</select>
|
60 |
+
</p>
|
61 |
<button type="submit" class="glsr-button components-button is-secondary" id="import-reviews" data-expand="#tools-import-reviews">
|
62 |
<span data-loading="<?= esc_attr_x('Importing reviews, please wait...', 'admin-text', 'site-reviews'); ?>"><?= _x('Import Reviews', 'admin-text', 'site-reviews'); ?></span>
|
63 |
</button>
|
views/pages/welcome/upgrade/v500.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth open">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="upgrade-
|
4 |
<span class="title">Version 5.0.0</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="upgrade-
|
9 |
<h2>Shortcode option changes</h2>
|
10 |
<p><em>Likelihood Of Impact: <span class="required">High</span></em></p>
|
11 |
<p>The changes to the shortcode options introduced in v5.0.0 are backwards compatible with version 4, meaning the old shortcode options will continue to work; however, if you are using these options then you should still update them as they may be removed in a future version.</p>
|
1 |
<div class="glsr-card postbox is-fullwidth open">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="upgrade-v5_0_0">
|
4 |
<span class="title">Version 5.0.0</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="upgrade-v5_0_0" class="inside">
|
9 |
<h2>Shortcode option changes</h2>
|
10 |
<p><em>Likelihood Of Impact: <span class="required">High</span></em></p>
|
11 |
<p>The changes to the shortcode options introduced in v5.0.0 are backwards compatible with version 4, meaning the old shortcode options will continue to work; however, if you are using these options then you should still update them as they may be removed in a future version.</p>
|
views/pages/welcome/whatsnew.php
CHANGED
@@ -4,6 +4,7 @@
|
|
4 |
<div class="is-fullwidth">
|
5 |
<div class="glsr-flex-row">
|
6 |
<div class="glsr-column">
|
|
|
7 |
<?php include trailingslashit(__DIR__).'whatsnew/v59.php'; ?>
|
8 |
<?php include trailingslashit(__DIR__).'whatsnew/v58.php'; ?>
|
9 |
<?php include trailingslashit(__DIR__).'whatsnew/v57.php'; ?>
|
4 |
<div class="is-fullwidth">
|
5 |
<div class="glsr-flex-row">
|
6 |
<div class="glsr-column">
|
7 |
+
<?php include trailingslashit(__DIR__).'whatsnew/v510.php'; ?>
|
8 |
<?php include trailingslashit(__DIR__).'whatsnew/v59.php'; ?>
|
9 |
<?php include trailingslashit(__DIR__).'whatsnew/v58.php'; ?>
|
10 |
<?php include trailingslashit(__DIR__).'whatsnew/v57.php'; ?>
|
views/pages/welcome/whatsnew/v40.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 4.0</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — October 6th, 2019</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v4_0_0">
|
4 |
<span class="title">Version 4.0</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v4_0_0" class="inside">
|
9 |
<p><em>Initial Release Date — October 6th, 2019</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v41.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 4.1</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — October 16th, 2019</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v4_1_0">
|
4 |
<span class="title">Version 4.1</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v4_1_0" class="inside">
|
9 |
<p><em>Initial Release Date — October 16th, 2019</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v42.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 4.2</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — October 29th, 2019</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v4_2_0">
|
4 |
<span class="title">Version 4.2</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v4_2_0" class="inside">
|
9 |
<p><em>Initial Release Date — October 29th, 2019</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v43.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 4.3</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — January 12th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v4_3_0">
|
4 |
<span class="title">Version 4.3</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v4_3_0" class="inside">
|
9 |
<p><em>Initial Release Date — January 12th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v44.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 4.4</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — February 12th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v4_4_0">
|
4 |
<span class="title">Version 4.4</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v4_4_0" class="inside">
|
9 |
<p><em>Initial Release Date — February 12th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v45.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 4.5</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — February 24th, 2020</em></p>
|
10 |
<h4>📢 Changes</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v4_5_0">
|
4 |
<span class="title">Version 4.5</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v4_5_0" class="inside">
|
9 |
<p><em>Initial Release Date — February 24th, 2020</em></p>
|
10 |
<h4>📢 Changes</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v46.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 4.6</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — April 22nd, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v4_6_0">
|
4 |
<span class="title">Version 4.6</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v4_6_0" class="inside">
|
9 |
<p><em>Initial Release Date — April 22nd, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v50.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.0</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — October 22nd, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
@@ -35,7 +35,7 @@
|
|
35 |
<li>Replaced the <code>assign_to</code> and <code>assigned_to</code> shortcode options with the <code>assigned_posts</code> option</li>
|
36 |
<li>Replaced the <code>category</code> shortcode option with <code>assigned_terms</code> option</li>
|
37 |
<li>Review limit validation now performs strict checking for assigned posts, categories and users (AND instead of OR).</li>
|
38 |
-
<li>The <code>site-reviews/rating/average</code> filter hook argument order has changed (see the <a data-expand="#upgrade-
|
39 |
<li>The Translations Settings search results are now restricted to public text that is actually shown on your website, if you would like to change plugin text shown in the WordPress admin, you should use the Loco Translate plugin instead.</li>
|
40 |
</ul>
|
41 |
<h4>🛠 Tweaks</h4>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_0_0">
|
4 |
<span class="title">Version 5.0</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_0_0" class="inside">
|
9 |
<p><em>Initial Release Date — October 22nd, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
35 |
<li>Replaced the <code>assign_to</code> and <code>assigned_to</code> shortcode options with the <code>assigned_posts</code> option</li>
|
36 |
<li>Replaced the <code>category</code> shortcode option with <code>assigned_terms</code> option</li>
|
37 |
<li>Review limit validation now performs strict checking for assigned posts, categories and users (AND instead of OR).</li>
|
38 |
+
<li>The <code>site-reviews/rating/average</code> filter hook argument order has changed (see the <a data-expand="#upgrade-v5_0_0" href="<?= admin_url('index.php?page='.glsr()->id.'-welcome#tab-upgrade-guide'); ?>">Upgrade Guide</a>).</li>
|
39 |
<li>The Translations Settings search results are now restricted to public text that is actually shown on your website, if you would like to change plugin text shown in the WordPress admin, you should use the Loco Translate plugin instead.</li>
|
40 |
</ul>
|
41 |
<h4>🛠 Tweaks</h4>
|
views/pages/welcome/whatsnew/v51.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.1</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — October 24th, 2020</em></p>
|
10 |
<h4>🛠 Tweaks</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_1_0">
|
4 |
<span class="title">Version 5.1</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_1_0" class="inside">
|
9 |
<p><em>Initial Release Date — October 24th, 2020</em></p>
|
10 |
<h4>🛠 Tweaks</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v510.php
ADDED
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<div class="glsr-card postbox is-fullwidth open">
|
2 |
+
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="true" aria-controls="welcome-v5_10_0">
|
4 |
+
<span class="title">Version 5.10</span>
|
5 |
+
<span class="icon"></span>
|
6 |
+
</button>
|
7 |
+
</h3>
|
8 |
+
<div id="welcome-v5_10_0" class="inside">
|
9 |
+
<p><em>Initial Release Date — April 26th, 2021</em></p>
|
10 |
+
<h4>✨ New Features</h4>
|
11 |
+
<ul>
|
12 |
+
<li>Added delimiter and date format options in the "Import third party reviews" tool</li>
|
13 |
+
</ul>
|
14 |
+
<h4>🐞 Bugs Fixed</h4>
|
15 |
+
<ul>
|
16 |
+
<li>Fixed the missing "terms" database column in a fresh install of Site Reviews</li>
|
17 |
+
</ul>
|
18 |
+
</div>
|
19 |
+
</div>
|
views/pages/welcome/whatsnew/v52.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.2</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — November 6th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_2_0">
|
4 |
<span class="title">Version 5.2</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_2_0" class="inside">
|
9 |
<p><em>Initial Release Date — November 6th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v53.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.3</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — December 13th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_3_0">
|
4 |
<span class="title">Version 5.3</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_3_0" class="inside">
|
9 |
<p><em>Initial Release Date — December 13th, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v54.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.4</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — December 22nd, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_4_0">
|
4 |
<span class="title">Version 5.4</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_4_0" class="inside">
|
9 |
<p><em>Initial Release Date — December 22nd, 2020</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v55.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.5</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — January 26th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_5_0">
|
4 |
<span class="title">Version 5.5</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_5_0" class="inside">
|
9 |
<p><em>Initial Release Date — January 26th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v56.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.6</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — February 4th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_6_0">
|
4 |
<span class="title">Version 5.6</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_6_0" class="inside">
|
9 |
<p><em>Initial Release Date — February 4th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v57.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.7</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — February 16th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_7_0">
|
4 |
<span class="title">Version 5.7</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_7_0" class="inside">
|
9 |
<p><em>Initial Release Date — February 16th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v58.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-
|
4 |
<span class="title">Version 5.8</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — March 20th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_8_0">
|
4 |
<span class="title">Version 5.8</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_8_0" class="inside">
|
9 |
<p><em>Initial Release Date — March 20th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
views/pages/welcome/whatsnew/v59.php
CHANGED
@@ -1,11 +1,11 @@
|
|
1 |
-
<div class="glsr-card postbox is-fullwidth
|
2 |
<h3 class="glsr-card-heading">
|
3 |
-
<button type="button" class="glsr-accordion-trigger" aria-expanded="
|
4 |
<span class="title">Version 5.9</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
-
<div id="welcome-
|
9 |
<p><em>Initial Release Date — April 24th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|
1 |
+
<div class="glsr-card postbox is-fullwidth">
|
2 |
<h3 class="glsr-card-heading">
|
3 |
+
<button type="button" class="glsr-accordion-trigger" aria-expanded="false" aria-controls="welcome-v5_9_0">
|
4 |
<span class="title">Version 5.9</span>
|
5 |
<span class="icon"></span>
|
6 |
</button>
|
7 |
</h3>
|
8 |
+
<div id="welcome-v5_9_0" class="inside">
|
9 |
<p><em>Initial Release Date — April 24th, 2021</em></p>
|
10 |
<h4>✨ New Features</h4>
|
11 |
<ul>
|