Skip to content
This repository has been archived by the owner on Apr 5, 2024. It is now read-only.

Commit

Permalink
Merge pull request #933 from City-of-Helsinki/release/0.3.0
Browse files Browse the repository at this point in the history
Release 0.3.0
  • Loading branch information
Chi Nguyen authored May 20, 2019
2 parents 3170c9b + 7132bee commit 153a8fb
Show file tree
Hide file tree
Showing 60 changed files with 1,073 additions and 261 deletions.
3 changes: 2 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
CLIENT_ID=
CLIENT_SECRET=
SESSION_SECRET=
TARGET_APP=
TARGET_APP=
CUSTOM_MUNICIPALITY_OPTIONS=[]
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ coverage
dist
node_modules
npm-debug.log
yarn-error.log
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,13 @@ install:

# We are running browser tests
before_script:
- export TZ=Europe/Helsinki
- export DISPLAY=:99.0
- sh -e /etc/init.d/xvfb start

script:
- yarn lint
- yarn test:ci

after_success:
- codecov < coverage/lcov.info
- codecov < coverage/lcov.info
122 changes: 74 additions & 48 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,95 +1,121 @@
* 0.1.2
** MAJOR CHANGES **
# 0.3.0
**MAJOR CHANGES**
```
- Add translation for date-picker, show date and month in currently selected language.
- Set varaamo timezone to flexible base on user local timezone.
- Add slotSize and minPeriod to reservation select, enable ability to reserve sauna slots with default amount of minPeriod. Time slot range equal with slotSize config from backend.
- Show access-code pending text if the access-code is generated 24h before reservation starts.
```

**CHANGELOG**

- [#920](https://github.com/City-of-Helsinki/varaamo/pull/920) Add translation for date-picker.
- [#921](https://github.com/City-of-Helsinki/varaamo/pull/921) Set varaamo timezone to flexible base on user local timezone.
- [#925](https://github.com/City-of-Helsinki/varaamo/pull/925) Add slotSize and minPeriod to reservation select, enable ability to reserve sauna with default amount of minPeriod.
- [#932](https://github.com/City-of-Helsinki/varaamo/pull/932) Show access-code pending text if the access-code is generated 24h before reservation starts.

- [#922](https://github.com/City-of-Helsinki/varaamo/pull/922) Add municipality options to env config.
- [#924](https://github.com/City-of-Helsinki/varaamo/pull/924) Add municipality to clear filter list.
- [#927](https://github.com/City-of-Helsinki/varaamo/pull/927) Translate SelectControl noOptionsMessage.
- [#928](https://github.com/City-of-Helsinki/varaamo/pull/928), [#930](https://github.com/City-of-Helsinki/varaamo/pull/930), [#931](https://github.com/City-of-Helsinki/varaamo/pull/931) Bugfix for [#925](https://github.com/City-of-Helsinki/varaamo/pull/925)

# 0.2.0
**MAJOR CHANGES**

- Add new selection field to sort filtered resources. Currently support to search by name, type, premise, people.
- Temporarily only show warning messages in 3 languages for IE11 user.
- Ability to favourite resources straight on search view instead going to resource detail page.

** CHANGELOG **
**CHANGELOG**

- [#895](https://github.com/City-of-Helsinki/varaamo/pull/895) Add sort to sort filtered resources.
- [#904](https://github.com/City-of-Helsinki/varaamo/pull/904) Favourite Resource on search view.
- [#909](https://github.com/City-of-Helsinki/varaamo/pull/909) Show warning message for IE11 users.
- [#895](https://github.com/City-of-Helsinki/varaamo/pull/895) Add sort to sort filtered resources.
- [#904](https://github.com/City-of-Helsinki/varaamo/pull/904) Favourite Resource on search view.
- [#909](https://github.com/City-of-Helsinki/varaamo/pull/909) Show warning message for IE11 users.

* 0.1.1
** HOTFIX **
# 0.1.1
**HOTFIX**

- [#913](https://github.com/City-of-Helsinki/varaamo/pull/913) Fix issue staff comment section is not working. Reason: React-bootstrap ref prop which is deprecated and replace with inputProps
* 0.1.0
** MAJOR CHANGES **
- [#913](https://github.com/City-of-Helsinki/varaamo/pull/913) Fix issue staff comment section is not working. Reason: React-bootstrap ref prop which is deprecated and replace with inputProps

# 0.1.0
**MAJOR CHANGES**

- Replacing Karma, Chai, Mocha with Jest.
- Upgrading React, Webpack, Babel and dependencies to latest.
- Dockerized development environment.
- Remove low locked node version 6, require v8 for Babel 7.

** CHANGELOG **
**CHANGELOG**

**UI changes:**
- [#863](https://github.com/City-of-Helsinki/varaamo/pull/863): Make homepage banner clickable.

UI changes:
- [#863](https://github.com/City-of-Helsinki/varaamo/pull/863): Make homepage banner clickable.
- [#865](https://github.com/City-of-Helsinki/varaamo/pull/865): Delayed reservation.

- [#865](https://github.com/City-of-Helsinki/varaamo/pull/865): Delayed reservation.
- [#867](https://github.com/City-of-Helsinki/varaamo/pull/867): Add config to fetch all unit that doesn't have empty resources.

- [#867](https://github.com/City-of-Helsinki/varaamo/pull/867): Add config to fetch all unit that doesn't have empty resources.
- [#868](https://github.com/City-of-Helsinki/varaamo/pull/868): Add municipality filters for filtering resources base on municiples.

- [#868](https://github.com/City-of-Helsinki/varaamo/pull/868): Add municipality filters for filtering resources base on municiples.
- [#873](https://github.com/City-of-Helsinki/varaamo/pull/873): Limit the selection of time slots to the ones within max period.

- [#873](https://github.com/City-of-Helsinki/varaamo/pull/873): Limit the selection of time slots to the ones within max period.
- [#875](https://github.com/City-of-Helsinki/varaamo/pull/875): Expand advanced search panel when filters are applied.

- [#875](https://github.com/City-of-Helsinki/varaamo/pull/875): Expand advanced search panel when filters are applied.
- [#876](https://github.com/City-of-Helsinki/varaamo/pull/876): Free-of-charge filter for resources.

- [#876](https://github.com/City-of-Helsinki/varaamo/pull/876): Free-of-charge filter for resources.
- [#878](https://github.com/City-of-Helsinki/varaamo/pull/878): Remove the link for old website from the footer.

- [#878](https://github.com/City-of-Helsinki/varaamo/pull/878): Remove the link for old website from the footer.
- [#883](https://github.com/City-of-Helsinki/varaamo/pull/883): Clear all filters after reset.

- [#883](https://github.com/City-of-Helsinki/varaamo/pull/883): Clear all filters after reset.
- [#889](https://github.com/City-of-Helsinki/varaamo/pull/889): Disable reservation time limit for admins.

- [#889](https://github.com/City-of-Helsinki/varaamo/pull/889): Disable reservation time limit for admins.
- [#899](https://github.com/City-of-Helsinki/varaamo/pull/899): Add unpublished tag to resource search list.

- [#899](https://github.com/City-of-Helsinki/varaamo/pull/899): Add unpublished tag to resource search list.
- [#901](https://github.com/City-of-Helsinki/varaamo/pull/901): Add navigation links to staff and higher permission user.

- [#901](https://github.com/City-of-Helsinki/varaamo/pull/901): Add navigation links to staff and higher permission user.

**Upgrading:**

Upgrading:
- [#854](https://github.com/City-of-Helsinki/varaamo/pull/854): Upgrade react-router to react-router v4.
- [#854](https://github.com/City-of-Helsinki/varaamo/pull/854): Upgrade react-router to react-router v4.

- [#856](https://github.com/City-of-Helsinki/varaamo/pull/856): Add dockerize config to dockerize development environment.
- [#856](https://github.com/City-of-Helsinki/varaamo/pull/856): Add dockerize config to dockerize development environment.

- [#857](https://github.com/City-of-Helsinki/varaamo/pull/857): Upgrade moment, moment-range, moment-timezome.
- [#857](https://github.com/City-of-Helsinki/varaamo/pull/857): Upgrade moment, moment-range, moment-timezome.

- [#860](https://github.com/City-of-Helsinki/varaamo/pull/860): Upgrade lodash.
- [#860](https://github.com/City-of-Helsinki/varaamo/pull/860): Upgrade lodash.

- [#862](https://github.com/City-of-Helsinki/varaamo/pull/862): Replace redux-logger with redux-devtools.
- [#862](https://github.com/City-of-Helsinki/varaamo/pull/862): Replace redux-logger with redux-devtools.

- [#868](https://github.com/City-of-Helsinki/varaamo/pull/868): Upgrade react-select.
- [#868](https://github.com/City-of-Helsinki/varaamo/pull/868): Upgrade react-select.

- [#874](https://github.com/City-of-Helsinki/varaamo/pull/874): Replace React internal prop-types with npm prop-types.
- [#874](https://github.com/City-of-Helsinki/varaamo/pull/874): Replace React internal prop-types with npm prop-types.

- [#879](https://github.com/City-of-Helsinki/varaamo/pull/879): Upgrade React to 15.6.2, Enzyme to v3+.
- [#879](https://github.com/City-of-Helsinki/varaamo/pull/879): Upgrade React to 15.6.2, Enzyme to v3+.

- [#882](https://github.com/City-of-Helsinki/varaamo/pull/882): Upgrade react-day-picker, remove react-date-picker.
- [#882](https://github.com/City-of-Helsinki/varaamo/pull/882): Upgrade react-day-picker, remove react-date-picker.

- [#884](https://github.com/City-of-Helsinki/varaamo/pull/884): Upgrade babel to v7, webpack v4, replace Karma/Mocha/Chai with Jest.
- [#884](https://github.com/City-of-Helsinki/varaamo/pull/884): Upgrade babel to v7, webpack v4, replace Karma/Mocha/Chai with Jest.

- [#890](https://github.com/City-of-Helsinki/varaamo/pull/890): Replace Chai with Jest's assertions.
- [#890](https://github.com/City-of-Helsinki/varaamo/pull/890): Replace Chai with Jest's assertions.

- [#892](https://github.com/City-of-Helsinki/varaamo/pull/892): Remove unnecessary outdated dependencies:
- [#892](https://github.com/City-of-Helsinki/varaamo/pull/892): Remove unnecessary outdated dependencies:

- Remove react-document-title, use react-helmet
- Remove react-body-classname, classname append can be handled by classnames
- Remove react-document-title, use react-helmet
- Remove react-body-classname, classname append can be handled by classnames

- [#893](https://github.com/City-of-Helsinki/varaamo/pull/893): Remove unnessary persisted state library, upgrade redux and dependencies:
- [#893](https://github.com/City-of-Helsinki/varaamo/pull/893): Remove unnessary persisted state library, upgrade redux and dependencies:

- Remove redux-localstorage and redux-localstorage-filter. Replaced with vanilla code.
- Remove redux-localstorage and redux-localstorage-filter. Replaced with vanilla code.

- Upgrade redux and dependencies.
- Upgrade redux and dependencies.

- [#894](https://github.com/City-of-Helsinki/varaamo/pull/894): Upgrade React to 16.8.x:
- [#894](https://github.com/City-of-Helsinki/varaamo/pull/894): Upgrade React to 16.8.x:

- Upgrade React to 16.8.x
- Upgrade React's dependencies to latest.
- Upgrade React to 16.8.x
- Upgrade React's dependencies to latest.

- [#900](https://github.com/City-of-Helsinki/varaamo/pull/900): Clean up obsolete/deprecated component.
- [#900](https://github.com/City-of-Helsinki/varaamo/pull/900): Clean up obsolete/deprecated component.

- Delete navbar, sidebar, side-navbar which was replaced by new component but not getting removed.
- Delete navbar, sidebar, side-navbar which was replaced by new component but not getting removed.
25 changes: 19 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,14 +62,27 @@ By default the running app can be found at `localhost:3000`.
```
OR prepare .env with default content:
```
CLIENT_ID
CLIENT_SECRET
SESSION_SECRET
TARGET_APP
API_URL
CUSTOM_MUNICIPALITY_OPTIONS
```
Environment's variable guideline:
- `API_URL`:
Custom config to replace global application's api URL. Expected value is valid URL string.
- `CUSTOM_MUNICIPALITY_OPTIONS`:
Config for custom municipalities. Expected value should be array of cities: `['Tampere','Jyväskylä','Oulu']`.
Without this config, default to use 3 central cities Helsinki, Espoo, Vantaa as options.
3. Then, start the development server:
```
Expand Down Expand Up @@ -144,7 +157,7 @@ OR enable `eslint --fix` onSave config in your code editor config.
```
$ docker-compose exec web sh
```
- Remove docker container if needed:
- Remove docker container if needed:
```
$ docker rm -f varaamo-frontend
```
Expand Down Expand Up @@ -185,17 +198,17 @@ Running Vscode debugger
All setting was included under .vscode directory.
- On Chrome:
[Guideline](https://code.visualstudio.com/blogs/2016/02/23/introducing-chrome-debugger-for-vs-code). Setting was under `Vscode debugger` name
[Guideline](https://code.visualstudio.com/blogs/2016/02/23/introducing-chrome-debugger-for-vs-code). Setting was under `Vscode debugger` name
- On Jest test:
[Guideline](https://jestjs.io/docs/en/troubleshooting#debugging-in-vs-code). Setting was under `Vscode Jest debugger` name.
- Put breakpoint in test file `(*.spec.js)`
- Run command:
```
$ yarn test:debug
```
```
License
-------
Expand Down
4 changes: 2 additions & 2 deletions app/constants/AppConstants.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,15 @@ export default {
},
},
SEARCH_PAGE_SIZE: 30,
SEARCH_MUNICIPALITY_OPTIONS: ['Helsinki', 'Espoo', 'Vantaa'],
DEFAULT_MUNICIPALITY_OPTIONS: ['Helsinki', 'Espoo', 'Vantaa'],
SHOW_TEST_SITE_MESSAGE: SETTINGS.SHOW_TEST_SITE_MESSAGE,
SUPPORTED_LANGUAGES: ['en', 'fi', 'sv'],
SUPPORTED_SEARCH_FILTERS: {
freeOfCharge: '',
date: '',
distance: '',
duration: 0,
municipality: '',
municipality: [],
end: '',
lat: '',
lon: '',
Expand Down
2 changes: 2 additions & 0 deletions app/constants/SlotConstants.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
export const slotSize = 30; // minutes
export const slotWidth = 30; // pixels
export const slotMargin = 0; // pixels

export const DEFAULT_SLOT_SIZE = '00:30:00';
3 changes: 2 additions & 1 deletion app/i18n/changeLocale.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ const messages = {
};

function changeLocale(language) {
savePersistLocale(language);
const locale = language === 'sv' ? 'se' : language;
savePersistLocale(locale);

moment.locale(`varaamo-${locale}`);
return updateIntl({
locale,
Expand Down
3 changes: 1 addition & 2 deletions app/i18n/initI18n.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'moment/locale/en-gb';
import 'moment/locale/fi';
import 'moment/locale/sv';
import 'moment-timezone';
import 'moment-timezone/builds/moment-timezone-with-data-10-year-range';

import constants from 'constants/AppConstants';

Expand All @@ -22,7 +22,6 @@ const messages = {
fi: fiMessages,
se: svMessages,
};
moment.tz.setDefault('Europe/Helsinki');

moment.defineLocale('varaamo-en', {
parentLocale: 'en-gb',
Expand Down
8 changes: 7 additions & 1 deletion app/i18n/messages/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@
"common.select": "Select",
"common.userNameLabel": "Account name",
"common.userEmailLabel": "Account email",
"SelectControl.noOptions": "No options",
"ConfirmReservationModal.beforeText": "Original reservation time:",
"ConfirmReservationModal.editTitle": "Changing reservation",
"ConfirmReservationModal.formInfo": "Please fill in the following data for your preliminary reservation. The fields marked with an asterisk (*) are mandatory.",
Expand Down Expand Up @@ -123,6 +124,7 @@
"Notifications.loginToReserve": "Log in to reserve these premises.",
"Notifications.reservationDeleteSuccessMessage": "Your reservation was successfully cancelled.",
"Notifications.reservationUpdateSuccessMessage": "Your reservation has been updated.",
"Notifications.selectTimeToReserve.warning": "The reservation overlaps with the existing reservation or is outside the opening hours.",
"Notifications.selectTimeToReserve": "Select the time for which you wish to make the reservation",
"Partners.kaupunginkirjatoImageAlt": "Helsinki City Library",
"Partners.nuorisoasiainkeskusImageAlt": "City of Helsinki – Youth Department",
Expand All @@ -145,6 +147,7 @@
"RecurringReservationControls.lastTimeLabel": "Ends on",
"RecurringReservationControls.numberOfOccurrencesLabel": "Repetitions",
"ReservationAccessCode.defaultText": "PIN code",
"ReservationAccessCode.pending": "PIN code is shown here. It will be generated 24h before the start of the reservation and will be sent to your email.",
"ReservationCalendarPickerLegend.booked": "Booked",
"ReservationCalendarPickerLegend.busy": "Partially booked",
"ReservationCalendarPickerLegend.free": "Free",
Expand All @@ -160,7 +163,7 @@
"ReservationConfirmation.reservationEditedTitle": "Reservation updated",
"ReservationConfirmation.resourceButton": "Back to premise",
"ReservationConfirmation.ownReservationButton": "Back to your reservations",
"ReservationConfirmation.confirmationText": "You will receive email (<a href='mailto:{email}'>{email}</a>) confirmation for your reservation.",
"ReservationConfirmation.confirmationText": "You will receive email (<a href='mailto:{email}'>{email}</a>) notification for your reservation.",
"ReservationConfirmation.reservationDetailsTitle": "Reservation details",
"ReservationControls.cancel": "Cancel",
"ReservationControls.confirm": "Approve",
Expand All @@ -183,6 +186,7 @@
"ReservationInfo.loginMessage": "You must <a href='/login?next={next}'>log in</a> to reserve these premises.",
"ReservationInfo.maxNumberOfReservations": "Maximum number of reservations per user:",
"ReservationInfo.reservationMaxLength": "Maximum duration of the reservation:",
"ReservationInfo.reservationMinLength": "Minimum duration of the reservation:",
"ReservationInfo.reservationEarliestDays": "Reservation at the earliest in {time}",
"ReservationInfoModal.cancelButton": "Cancel event",
"ReservationInfoModal.confirmButton": "Confirm reservation",
Expand Down Expand Up @@ -227,6 +231,8 @@
"ResourceHeader.backButton": "Back to search results",
"ResourceHeader.maxPeriodDays": "max {days} days",
"ResourceHeader.maxPeriodHours": "max {hours} h",
"ResourceHeader.minPeriodDays": "min {days} days",
"ResourceHeader.minPeriodHours": "min {hours} h",
"ResourceHeader.mapButton": "See position on map",
"ResourceHeader.resourceButton": "See resource info",
"ResourceHeader.favoriteAddButton": "Add favorite",
Expand Down
Loading

0 comments on commit 153a8fb

Please sign in to comment.