Skip to content

Commit

Permalink
[DB] H2 embedded database
Browse files Browse the repository at this point in the history
-H2 is now the default (embedded) db
-Removed HSQL files
-Installer folder now contains only the installation script, which is
obsolete. To be updated with H2 support
-Updated pom.xml. The build process copies a clean H2 db if it doesn't
already exists. Local DB path must be set here
-Fixed Birt report template with parametric DB credentials
  • Loading branch information
guido committed May 14, 2013
1 parent 58ecc7e commit 4f6391c
Show file tree
Hide file tree
Showing 32 changed files with 850 additions and 1,041 deletions.
35 changes: 35 additions & 0 deletions LEGGIMI.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
LOCANDA - versione 0.3

Grazie per aver provato Locanda. In questo file troverete alcune informazioni utili per configurarlo secondo le esigenze della vostra struttura e per cominciare ad utilizzarlo.

ACCESSO A LOCANDA
Dalla home page del sistema (raggiungibile all'indirizzo http://localhost:8080/locanda) si procede all'autenticazione con il bottone in alto a destra "Entra/Registrati", che porta alla pagina di Login.
Se non si � ancora in possesso di un account di accesso al sistema, cliccando sul pulsante "Registrati" si andr� ad un pagina dove poter inserire i propri dati. Al termine di tale procedura, verr� comunicata una password, da utilizzare assieme alla mail appena inserita negli appositi campi.
Inserendo questi dati nella pagina di Login si raggiunger� la pagina principale, dove si trova una schermata riassuntiva delle prenotazioni in corso e di quelle passate (se gi� inserite in precedenza), oltre naturalmente ai menu a tendina mediante i quali accedere a tutte le altre funzionalit� di Locanda.

DATI PRESENTI NEL SISTEMA
E' gi� presente una struttura con alcuni dati di esempio, liberamente modificabile con i dati della propria struttura. Tutte le altre entit� (camere, tipologie, stagioni, extra ecc) devono essere inserite dall'utente, tramite le varie sezioni accedibili dal menu.
Nel caso del listino dei prezzi (camere ed extra), devono essere presenti almeno una stagione ed una tipologia di camera. Il relativo listino verr� cos� creato con tutti i prezzi inizializzati a zero. Sar� quindi compito dell'utente inserire i prezzi desiderati per tutti i giorni della settimana e tutti gli extra, se presenti.
Alcuni elementi non potranno essere inseriti se non sono stati inseriti precendentemente degli altri. Non � possibile ad esempio creare delle camere se non vi si pu� associare una tipologia, cos� come inserire delle prenotazioni se mancano le camere o tutti gli elementi che determinano un listino (stagioni, tipologie, convenzioni). Per quanto riguarda le convenzioni, non � necessario che l'utente ne inserisca almeno una, poich� l'impostazione predefinita, che consente di creare i listini, � "Nessuna convenzione".

Per avere quindi tutti i dati necessari per utilizzare il sistema, consigliamo i seguenti step:
-creare una o pi� stagioni con i relativi periodi
-creare una o pi� tipologie di camere
-creare una o pi� camere
-creare eventuali extra con le relative unit� di misura (per es: per notte/per persona)
-configurare i listini dei prezzi delle camere
-configurare i listini dei prezzi degli extra
A questo punto si potranno creare dei booking direttamente dal tableau oppure dal pulsante "Nuova prenotazione".
Si potr� inoltre provare il componente html che permette di raccogliere le prenotazioni online andando nella sezione "Impostazioni->Widget Online" e cliccando su "Prova Widget Online".


FACILITIES
Con Locanda � possibile inserire le facilities della propria struttura e delle proprie camere, con le relative immagini. Ce ne sono gi� alcune presenti nel sistema, ma � possibile aggiungerne altre, con proprie immagini. Viene per� fornita una galleria di immagini descrittive delle facilities pi� comuni. Potete utilizzare quelle per creare le vostre nuove facilities. Le potete trovare nella cartella "facilities".

REPORTS
Dalla versione 0.2 � possibile creare la fattura in formato PDF della prenotazione. E' presente infatti nella pagina della prenotazione un pulsante "Scarica Fattura" che genera la fattura con i dati dell'ultimo salvataggio della prenotazione stessa.

RICERCA
Dalla versione 0.3, ogni risorsa del sistema � ricercabile con un campo di testo semplice e un form di ricerca avanzata, localizzato in alto a sinistra. Tale ricerca � implementata con il motore SOLR, la cui semplice configurazione � descritta nel file di istruzioni di installazione.

Buon divertimento con Locanda!
21 changes: 2 additions & 19 deletions installer/README → README.txt
Original file line number Diff line number Diff line change
@@ -1,23 +1,6 @@
LOCANDA
Thanks for trying Locanda. In this file you'll find some useful information to configure it according to the needs of your structure, and to start using it.

INSTALLATION on a Linux environment:
Prerequired software
- Java (version ??) or above
- Apache Tomcat server (version ??)
- MySQL (version ??) or HyperSQL (included in this pachage)
Note: locanda is able to use both MySQL and HSQL, you can chose your preferred platform.
- A web browser that support javascript

-Check the correct installation of the packages needed to execute Apache Tomcat and/or MySQL servers.
-If you want to use MySQL you need a administrator privileges in order to create a new locanda user and database.
-Check that Tomcat and/or MySQL servers are up and running.
-(not mandatory) before running the installation scripth make sure that you have ben exported your Tomcat var CATALINA_HOME.
-run the installation script.
-if you have chosed HSQL maybe you need to run the HSQL server and setup the database, please refer documentation
in HSQL directory.

LOCANDA - version 0.3

Thanks for trying Locanda. In this file you'll find some useful information to configure it according to the needs of your structure, and to start using it.

ACCESS TO LOCANDA
From the home page (http://localhost:8080/locanda), clicking on the "Login/Signup" button in the top-right part of the page will redirect you to the Login page
Expand Down
11 changes: 5 additions & 6 deletions build_instructions.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Locanda Build Guide (with Maven)
-In the project root, there are three .properties file to be customized:
-global.properties -> resources paths
-mysql.properties -> mySQL connection parameters
-hsql.properties -> HSQL connection parameters
-h2.properties -> H2 connection parameters

-To deploy the webapp, in the shell from the project directory type:
-mvn clean install to create the build in Locanda_Target folder
Expand All @@ -21,9 +21,8 @@ Locanda Build Guide (with Maven)
<password>tomcat</password>
</server>

-If you wish to use the HSQL db, you can deploy Locanda using the HSQL profile. Just run Maven with the command:
-mvn clean tomcat7:deploy -Phsql
and the config files will be set with the proper HSQL parameters of hsql.properties.
By activating this profile, the exec plugin will start and populate the HSQL database.
*BUG TO BE FIXED* The db start is commented due to the fact that it locks the shell, preventing the successful deployment completion
-If you wish to use the MySQL db, you can deploy Locanda using the MySQL profile. Just run Maven with the command:
-mvn clean tomcat7:deploy -Pmysql
and the config files will be set with the proper MySQL parameters of mysql.properties.
By activating this profile, the exec plugin will start and populate the MySQL database.

2 changes: 1 addition & 1 deletion global.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
resource.folder=${project.build.directory}/${project.name}_resources
solr.homeDir=${resource.folder}/${project.name}_solr
solr.homeDir=${resource.folder}/solr
solr.configFile=${solr.homeDir}/solr.xml
9 changes: 9 additions & 0 deletions h2.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
db.maxActive=100
db.maxIdle=30
db.maxWait=10000

db.name=locanda
db.username=locanda
db.password=locanda
db.driverClassName=org.h2.Driver
db.url=jdbc:h2:${db.folder}/${db.name}
Binary file added h2/locanda.h2.db
Binary file not shown.
11 changes: 0 additions & 11 deletions hsql.properties

This file was deleted.

42 changes: 0 additions & 42 deletions hsql/README

This file was deleted.

48 changes: 0 additions & 48 deletions hsql/dump.sh

This file was deleted.

Binary file removed hsql/lib/hsqldb.jar
Binary file not shown.
Binary file removed hsql/lib/sqltool.jar
Binary file not shown.
Loading

0 comments on commit 4f6391c

Please sign in to comment.