- First sign up for a Developer Edition Org.
- Login to you new Developer Edition Org and go to Setup, under My Domain, register a My Domain.
- Install Development Tools
- Clone this repository:
git clone https://github.com/Shir10/Hotel-Reservations-Management-App.git cd Hotel-Reservations-Management-App
- Authorize your Developer Org and provide it with an alias (mydevorg in the command below):
sfdx force:auth:web:login -s -a mydevorg
- Run this command in a terminal to deploy the app.
sfdx force:source:deploy -p force-app
- Import some sample data:
- Install texei plugin:
sfdx plugins:install texei-sfdx-plugin
sfdx texei:data:import --inputdir ./data --targetusername YourOrgUserName
- Install texei plugin:
- If your org isn't already open, open it now:
sfdx force:org:open -u mydevorg
- In your Developer Org App Launcher, select the Hotel Reservations Management App.
This repository contains several files that are relevant if you want to integrate modern web development tooling to your Salesforce development processes, or to your continuous integration/continuous deployment processes.
Prettier is a code formatter used to ensure consistent formatting across your code base. To use Prettier with Visual Studio Code, install this extension from the Visual Studio Code Marketplace. The .prettierignore and .prettierrc files are provided as part of this repository to control the behavior of the Prettier formatter.
ESLint is a popular JavaScript linting tool used to identify stylistic errors and erroneous constructs. To use ESLint with Visual Studio Code, install this extension from the Visual Studio Code Marketplace. The .eslintignore file is provided as part of this repository to exclude specific files from the linting process in the context of Lightning Web Components development.
This repository also comes with a package.json file that makes it easy to set up a pre-commit hook that enforces code formatting and linting by running Prettier and ESLint every time you git commit
changes.
To set up the formatting and linting pre-commit hook:
- Install Node.js if you haven't already done so
- Run
npm install
in your project's root folder to install the ESLint and Prettier modules (Note: Mac users should verify that Xcode command line tools are installed before running this command.)
Prettier and ESLint will now run automatically every time you commit changes. The commit will fail if linting errors are detected. You can also run the formatting and linting from the command line using the following commands (check out package.json for the full list):
npm run lint:lwc
npm run prettier
Lightning Web Components:
- addHotel - Add a new Hotel with an address and image.
- addRoomType - Add a Room Type for the Hotel, with the amount of rooms available for that type.
- roomReservation - Book a reservation for a Hotel room to a Contact with a specific date.
- hotelsMap - See all the Hotels in a Google Map compoennt.
- searchHotel - Search for a Hotel and see the result in a grid view with the Hotel image and name.