Skip to content

Angular 7, Firebase - A Mobile GPS, Picture Attendance App for storing Employee, Asset Picture Attendance with GPS Locations.

License

Notifications You must be signed in to change notification settings

AmitXShukla/Mobile-Picture-GPS-Tracking-Attendance-APP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

- If you like this project, please consider giving it a star (*) and follow me at GitHub & YouTube.

Mobile Picture, GPS Tracking Attendance App

A Mobile GPS, Picture Attendance App for storing Employee, Asset Picture Attendance with GPS Locations.

Objective

Store all Employee and/or Assets attendance records electronically.
1. Paperless Records for Attendance Regiter
2. Save Pictures and Live GPS Locations
3. Online and/or Offline (delayed capture) App
4. One App for multiple platforms (iOS, Android, Desktop, Cloud etc.)
5. Unlimited Storage (only limited to server/database hosting).
6. Store and Access millions of records instantly.
7. Paperless and Mobile on-premise App.
8. Instant access to ALL historical records at anytime.
9. No Thumb expressions, Picture identification or card punching or GPS devices to carry except smart phone.
10. Auto Face Recognition (Pro version only).

send an email to info@elishconsulting.com for Pro version enquiries.

Tools: 

front-end: Angular 7
back-end: Google Firebase
Pro Version: AI, Machine Learning Algorthim with Face Recognition

Let's get started :-



Before we start, Please make sure you have latest version of node js installed.
Let's head out to https://nodejs.org/en/ and grab latest nodejs.
Once you have nodejs installed, open command prompt/terminal window.
$ node -v // make sure, this command comes back with a node version
$ npm -v // make sure, this command comes back with a npm version

How to Install NodeJS on ChromeOS

# First run
$ sudo apt-get update
# and then if needed
$ sudo apt-get install curl gnupg -y
# or nodejs version 11
$ curl -sL https://deb.nodesource.com/setup_11.x | sudo -E bash -
$ sudo apt-get install -y nodejs

Install Angular CLI

$ npm install -g @angular/cli
$ mkdir app
$ cd app
$ mkdir client
$ ng new GPS-Pic-Attendance
$ cd GPS-Pic-Attendance
$ ng serve


$ ng g c shared/aboutus --spec=false --flat=true
$ ng g c shared/header --spec=false --flat=true
$ ng g c shared/footer --spec=false --flat=true
$ ng g c shared/login --spec=false --flat=true
$ ng g c shared/signup --spec=false --flat=true
$ ng g c product/attendance --spec=false --flat=true

Firebase Database Rules

service cloud.firestore {
match /databases/{database}/documents {

match /attendance/{document} {
allow write: if isSignedIn();
allow read, update: if isDocOwner() || isAdmin();
}

match /attendanceusers/{document} {
allow read: if isSignedIn();
}
}

// helper functions
function isDocOwner(){
// assuming document has a field author which is uid
// Only the authenticated user who authored the document can read or write
return request.auth.uid == resource.data.author;
// This above read query will fail
// The query fails even if the current user actually is the author of every story document.
// The reason for this behavior is that when Cloud Firestore applies your security rules,
// it evaluates the query against its potential result set,
// not against the actual properties of documents in your database.
// If a query could potentially include documents that violate your security rules,
// the query will fail.
// on your client app, make sure to include following
// .where("author", "==", this.afAuth.auth.currentUser.uid)
}
function isSignedIn() {
// check if user is signed in
return request.auth.uid != null;
}
function isAdmin() {
return get(/databases/$(database)/documents/attendanceusers/
$(request.auth.uid)).data.isAdmin == true;
}

videos !!
Setup Angular environment
Setup Angular Materials
Setup Firebase
Setup Angular Routes and AuthGuard
AngularFire and Firebase
Social Auth
Angular with Google Maps
GPS Location
Angular Firebase fileupload FireStorage
Angualar Materal Data table tutorials
Firebase persistence
Using Google Maps with Angular 7
Firebase query
Firebase database rules