Skip to content

rissawyss/ApartmentSite

Repository files navigation

ApartmentSite

Dynamic property management app

Web Development by Isometric Interactive

Bryan Castleman | Nicholas Nooch | Marissa Wyss

A template to sell apartment communities

  • Maps, photos, and floor plans
  • Contact forms to generate prospect leads
  • Application forms to capture new tenant info
  • Keep track of leasing
  • Maintain parking permits and parking spaces
  • Contractor vendor contact list
  • Track and manage work orders
  • History of work done

Technologies

  • Node and Express Web Server
  • MySQL Database with a Sequelize ORM
  • GET and POST routes for retrieving and adding new data
  • Materialize
  • Passport
  • Handlebars for Server-Side Templating
  • Authentication

Model View Controller (MVC) folder structure

2017-05-20 2

MODEL

Using the sequelize node module, models (tables) in the database were defined using sequelize.define('name', {attributes}, {options}) with appropriate DataTypes, Class Methods and Associations. Querying and accessing the database for CRUD (create, read, update, destroy) operations was executed via the Controller.

Tables Associations Add'l Associations/Methods
User Instance Valid Password
WorkOrder belongsTo(models.Tenant) belongsTo(models.Contractor)
Tenant hasMany(models.WorkOrder)
Contractor hasMany(models.WorkOrder)
Prospect
Applicant

VIEW

Handlebars were implemented to dynamically generate views routed through the Controller. Partials, along with built-In Helpers of each, if and unless allowed specific delivery of blocks of code depending on routes.

WorkOrder Maintenance Form Handlebars Sample

workorder-handlebars

CONTROLLER

The Controller determines the appropriate action method to handle requests from the server. A multitude of HTTP requests for the manager functionality alone were needed to create, view, edit and delete data:

  • GET Contractors get-contractors-manager

  • POST Prospects post-prospects-manager

  • PUT WorkOrders put-workorder-manager

AUTHENTICATION

A registration form is delivered at the /signup path which validates password by using regex. The Manager Login form is delivered via a modal, which authenticates user login by checking for existing username in the database (User model). login-signup

DESIGN

Dynamic view of property and floor plans

floorplans

Quick navigation to manager’s links

managerview

Table view of database models, and View/Edit/Delete icons

tableview

Form interface for contacting and applying

formview

Set up for Local Machine

'''npm install'''

''' npm run devstart '''

  • visit http://localhost:8080/

  • rs to restart server manually, but it should be restarting on file change locally

  • or npm start

  • debugging nodemon --inspect app.js

Copyright 2017 © Isometric Interactive

2017-04-20 2 - copy

About

Dynamic property management app

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •