diff --git a/CHANGELOG.md b/CHANGELOG.md index 8ad9f379..7f00a8da 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,13 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [3.11.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.10.0...v3.11.0) (2023-10-02) + + +### Features + +* List number of free spots on programme list ([38529a8](https://github.com/MultinetInteractive/EduAdmin-WordPress/commit/38529a86da27169961bb53597a0f6069c4721d1c)) + ## [3.10.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.9.2...v3.10.0) (2023-09-29) diff --git a/PLUGIN-CHECKSUM b/PLUGIN-CHECKSUM index c9d440b7..afb0dee6 100644 --- a/PLUGIN-CHECKSUM +++ b/PLUGIN-CHECKSUM @@ -1 +1 @@ -14f81e2c8579a08c36c41a722bb72da7 +9bff8c7558e82bfecfc89796fa3d435d diff --git a/content/template/programme/list.php b/content/template/programme/list.php index db3aae7b..aeb59169 100644 --- a/content/template/programme/list.php +++ b/content/template/programme/list.php @@ -1,4 +1,7 @@ get_option( 'eduadmin-spotsLeft', 'exactNumbers' ); +$always_few_spots = EDU()->get_option( 'eduadmin-alwaysFewSpots', '3' ); +$spot_settings = EDU()->get_option( 'eduadmin-spotsSettings', "1-5\n5-10\n10+" ); if ( empty( $programmes['Errors'] ) ) { ?> diff --git a/content/template/programme/template/list-item.php b/content/template/programme/template/list-item.php index 346012dd..d0235620 100644 --- a/content/template/programme/template/list-item.php +++ b/content/template/programme/template/list-item.php @@ -28,10 +28,13 @@ '; - echo wp_kses_post( $next_start['ParticipantNumberLeft'] > 0 || intval( $next_start['MaxParticipantNumber'] ) == 0 ? '' . _x( 'Spots left', 'frontend', 'eduadmin-booking' ) . '' : '' . _x( 'No spots', 'frontend', 'eduadmin-booking' ) . '' ); + echo wp_kses_post("" . get_spots_left( $spots_left, intval( $next_start['MaxParticipantNumber'] ), $spot_left_option, $spot_settings, $always_few_spots ) . "\n"); } ?> diff --git a/eduadmin.php b/eduadmin.php index 39af2757..4cae99dd 100644 --- a/eduadmin.php +++ b/eduadmin.php @@ -9,7 +9,7 @@ * Plugin URI: https://www.eduadmin.se * Description: EduAdmin plugin to allow visitors to book courses at your website * Tags: booking, participants, courses, events, eduadmin, lega online - * Version: 3.10.0 + * Version: 3.11.0 * GitHub Plugin URI: multinetinteractive/eduadmin-wordpress * GitHub Plugin URI: https://github.com/multinetinteractive/eduadmin-wordpress * Requires at least: 5.8 diff --git a/package.json b/package.json index 3faeb49b..6429a194 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "eduadmin-wordpress-plugin", "private": true, - "version": "3.10.0", + "version": "3.11.0", "repository": "https://github.com/MultinetInteractive/EduAdmin-WordPress.git", "author": "Chris GĂ„rdenberg ", "license": "MIT", diff --git a/readme.md b/readme.md index ff1c3a8b..1d637769 100644 --- a/readme.md +++ b/readme.md @@ -1,7 +1,7 @@ # EduAdmin Booking - Requires at least: 5.8 - Tested up to: 6.4 -- Stable tag: 3.10.0 +- Stable tag: 3.11.0 - Requires PHP: 7.0 - License: GPL3 - License URI: https://www.gnu.org/licenses/gpl-3.0.en.html @@ -40,6 +40,13 @@ If you notice that your API key doesn't work any more, you have to contact us. The full changelog available on [GitHub](https://github.com/MultinetInteractive/EduAdmin-WordPress/blob/production/CHANGELOG.md) +### [3.11.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.10.0...v3.11.0) (2023-10-02) + + +#### Features + +* List number of free spots on programme list ([38529a8](https://github.com/MultinetInteractive/EduAdmin-WordPress/commit/38529a86da27169961bb53597a0f6069c4721d1c)) + ### [3.10.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.9.2...v3.10.0) (2023-09-29) @@ -61,12 +68,5 @@ The full changelog available on [GitHub](https://github.com/MultinetInteractive/ * **Programme:** Fixed an issue where programme views/shortcodes weren't included in the correct way. ([fd0ee12](https://github.com/MultinetInteractive/EduAdmin-WordPress/commit/fd0ee128dfc1e324732544f9071640b5aba76e0c)), closes [#494](https://github.com/MultinetInteractive/EduAdmin-WordPress/issues/494) -### [3.9.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.8.1...v3.9.0) (2023-09-15) - - -#### Features - -* New type of script, when you use the booking form in the API. ([92eabd8](https://github.com/MultinetInteractive/EduAdmin-WordPress/commit/92eabd85c6d6392e3ce68db769fd60f52258dc77)), closes [#412](https://github.com/MultinetInteractive/EduAdmin-WordPress/issues/412) - diff --git a/readme.txt b/readme.txt index 7e4be9ec..77b146e5 100644 --- a/readme.txt +++ b/readme.txt @@ -3,7 +3,7 @@ Contributors: mnchga Tags: booking, participants, courses, events, eduadmin, lega online Requires at least: 5.8 Tested up to: 6.4 -Stable tag: 3.10.0 +Stable tag: 3.11.0 Requires PHP: 7.0 License: GPL3 License URI: https://www.gnu.org/licenses/gpl-3.0.en.html @@ -45,6 +45,13 @@ If you notice that your API key doesn't work any more, you have to contact us. The full changelog available on [GitHub](https://github.com/MultinetInteractive/EduAdmin-WordPress/blob/production/CHANGELOG.md) +### [3.11.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.10.0...v3.11.0) (2023-10-02) + + +#### Features + +* List number of free spots on programme list ([38529a8](https://github.com/MultinetInteractive/EduAdmin-WordPress/commit/38529a86da27169961bb53597a0f6069c4721d1c)) + ### [3.10.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.9.2...v3.10.0) (2023-09-29) @@ -66,12 +73,5 @@ The full changelog available on [GitHub](https://github.com/MultinetInteractive/ * **Programme:** Fixed an issue where programme views/shortcodes weren't included in the correct way. ([fd0ee12](https://github.com/MultinetInteractive/EduAdmin-WordPress/commit/fd0ee128dfc1e324732544f9071640b5aba76e0c)), closes [#494](https://github.com/MultinetInteractive/EduAdmin-WordPress/issues/494) -### [3.9.0](https://github.com/MultinetInteractive/EduAdmin-WordPress/compare/v3.8.1...v3.9.0) (2023-09-15) - - -#### Features - -* New type of script, when you use the booking form in the API. ([92eabd8](https://github.com/MultinetInteractive/EduAdmin-WordPress/commit/92eabd85c6d6392e3ce68db769fd60f52258dc77)), closes [#412](https://github.com/MultinetInteractive/EduAdmin-WordPress/issues/412) -