Skip to content

123mpozzi/brianzapp-web

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BrianzApp - Admin dashboard

Functionality

Promptly send public utility news addressed to the citizens of the agreed municipalities

Screenshots

Functionality
Homepage

Functionality
Filter the sent notifications displayed

Functionality
Send a new notification

Functionality
Mobile ready

Architecture

Functionality

Setup

The project has been built with PHP 7.
To access the WebApp, type the path to the public folder in the browser

Composer

Install Composer

Install project dependencies: composer install

Database

Create the database by connecting to MySQL and running createdb.sql

create database dbname;
use dbname;
source createdb.sql;

Add an account into the database

insert into utente (user, password) values ('user@email.it', SHA2('password', 256));

Configuration

Configure host, database connection, mail server inside the file private/config.ini.php
Create it if not already present:

;<?php  // This file is to be left as it is, it is both a valid php and ini file, so if the private folder is somehow accessed, there is still another security layer because the php part will stop the execution and no data will be displayed in the HTML source of the page.  
;die(); // For further security  
;/*

[mysql]
user = usernameMySQL
password = passwordMySQL
host = localhost
dbname = dbname

[email]
username = usernameEmail
password = passwordEmail

;*/

;?>

Mail server settings

Change PHPMailer settings in sendmail.php

Push notifications service

OneSignal is used to send push notifications to devices.
To use a different service, modify the implementation of sendMessage() in new_notification.php

Project Structure

project
│   README.md               This file
│   createdb.sql            SQL script to create the database
│   composer.*              Composer dependencies
│
└───private             Sensitive data to which access 
│   │                   must be restricted
│   │   logs
│   │   config.ini.php
│
└───public              Publicly accessible pages
│   │   .                 General PHP code
│   │   index.php         Start page
│   │   css               Styles
│   │   js                Scripts
│   │   res               Image assets
│   │   admin             PHP code related to admin dashboard
│   │   user              PHP code related to user: provides
│                         JSON data to the android app
│   
└───root                Files to be placed in the root directory
    │  ...              (such as htdocs) of the website that 
                        provides hosting, hence outside the 
                        WebApp folder

About

Admin dashboard of BrianzApp

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published