This is a TE4 project by the group VALE. Original group members: Viggo Ström, Axel Thornberg, Eskil Tornberg. Former maintainers: Ivar Bjerling, Tim Kelso, David Cavalli-Björkman. Current maintainers: Jesper Cejie, Carl Eriksson Skogh, Joel Jansson, Viggo Ström och Axel Thornberg.
In order to compile the project, Node.js version 20.18.0 has to be installed and working. Afterwards install the required packages with:
npm install js-yaml handlebars dotenv cross-env
To compile the project, run the hbs-compiler.js script with:
node scripts/hbs-compiler.js
This will generate all the necessary html files from the index.hbs file.
To change the open hours that appear on the site, you have to change open_hours
and/or july_open_hours
in the kiruna.yml and/or lulea.yml file.
To change closed days change the text content of a table in the index.hbs file and change the closedDates object in the openHours.js file.
We use a customized version of the flag-icons project to integrate inline flag icons for the language selection dropdown in the website's nav-bar. In the flag-icons folder of our project there are two folders, css and flags. The css folder contains a minified CSS file which gets imported in index.hbs. The flags folder contains the flag icons used, which are imported through said CSS file. Beware that you have to add a new flag icon to the flags folder if you want to add more flag icons to the project. This can be done through downloading the flag-icons project and adding the desired flag icons.
To place an inline icon on the page add the language name and code to the languages
-variable in lulea.yml and kiruna.yml.
-
Phone numbers are changed in lulea.yml and kiruna.yml.
-
Changing which cars are available is done in lulea.yml and kiruna.yml.
-
To change the VAT tax, simply change the value of the "vat_on_cars" in lulea.yml and kiruna.yml.
-
To change which ZIP codes are delivered to and their price, change the value of the
zip_codes
-key in kiruna.yml or lulea.yml. -
To change the E-mail, change the
mail
-variable in kiruna.yml or lulea.yml. -
To change the address, change the
address
- andzip_code
-variables in kiruna.yml or lulea.yml. -
To change holidays where one or more stores are closed, change the value of the
closed_dates
-key in kiruna.yml and lulea.yml. Thedate
-key is in the following format:MMDD
where Janauary is month 0 and December is month 11. -
To change the hours which the store is open, change the value of the
open_hours
-key in kiruna.yml and lulea.yml. Theindex
-key is an integer for which day of the week the object refers to with Sunday as day 0 and Saturday as day 6. -
There is also an object
special_open_hours
which allows for differing hours during a specific month. It consists of two keys:month
which indicates which month this applies to (January is month 0 and December is month 11.) andopen_hours
which follows the same structure as mentioned previously.
When making changes to any of the above files also make sure to add that change to its correlating python testing file.