Skip to content

Commit

Permalink
Merge branch 'release/3.4.1'
Browse files Browse the repository at this point in the history
* release/3.4.1:
  Finish up 3.4.1
  Fixed some re-flow issues with collapsed blocks
  Fixed a couple of bad references to the `uid` field on a Solspace Calendar model
  Require php >= 7.1
  • Loading branch information
joshangell committed Dec 4, 2019
2 parents 54695af + 6a38b26 commit f5b9fb7
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 4 deletions.
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,17 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p

## Unreleased


## 3.4.1 - 2019-12-04

### Changed
- Bumped the PHP requirement to >= 7.1 ([#72](https://github.com/angell-co/Spoon/issues/72))

### Fixed
- Fixed a couple of bad references to the `uid` field on a Solspace Calendar model ([#73](https://github.com/angell-co/Spoon/issues/73))
- Fixed the collapsed / expanded reflow issues ([#58](https://github.com/angell-co/Spoon/issues/58) & [#67](https://github.com/angell-co/Spoon/issues/67)) - hat tip to [@jsunsawyer](https://github.com/jsunsawyer) for pinpointing the specific circumstances that cause this to pop up


## 3.4.0 - 2019-11-22

### Added
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
}
],
"require": {
"php": ">=7.1.0",
"craftcms/cms": "^3.1.0"
},
"autoload": {
Expand Down
2 changes: 1 addition & 1 deletion src/assetbundles/dist/css/main.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/assetbundles/src/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ body.rtl .buttons-spooned > .btn, body.rtl .buttons-spooned > .btngroup { margin
-webkit-opacity: 0 !important;
-moz-opacity: 0 !important;
opacity: 0 !important;
overflow: hidden;
}

/* tabs */
Expand Down
9 changes: 6 additions & 3 deletions src/services/Loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,8 @@ public function run(): void
if ($calendarService) {
$calendar = $calendarService->getCalendarByHandle(end($segments));
if ($calendar) {
$this->configurator('#fieldlayoutform', 'calendar:'.$calendar->uid);
$uid = Db::uidById(\Solspace\Calendar\Records\CalendarRecord::TABLE, $calendar->id);
$this->configurator('#fieldlayoutform', 'calendar:'.$uid);
}
}
}
Expand Down Expand Up @@ -212,14 +213,16 @@ public function run(): void
$calendarService = new \Solspace\Calendar\Services\CalendarsService();
$calendar = $calendarService->getCalendarByHandle($segments[3]);
if ($calendar) {
$context = 'calendar:'.$calendar->uid;
$uid = Db::uidById(\Solspace\Calendar\Records\CalendarRecord::TABLE, $calendar->id);
$context = 'calendar:'.$uid;
}
} else {
$calendarEventsService = new \Solspace\Calendar\Services\EventsService();
if ($calendarEventsService) {
$event = $calendarEventsService->getEventById($segments[2]);
if ($event) {
$context = 'calendar:'.$event->getCalendar()->uid;
$uid = Db::uidById(\Solspace\Calendar\Records\CalendarRecord::TABLE, $event->getCalendar()->id);
$context = 'calendar:'.$uid;
}
}
}
Expand Down

0 comments on commit f5b9fb7

Please sign in to comment.