Skip to content

📋 App using backbone.js and jQuery to make a simple database

Notifications You must be signed in to change notification settings

AndrewJBateman/backbone-employee-project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

⚡ Backbone Employee Project

  • Tutorial project using the Backbone.js library together with jQuery.
  • Note: to open web links in a new window use: ctrl+click on link

GitHub repo size GitHub pull requests GitHub Repo stars GitHub last commit

📄 Table of contents

📚 General info

  • Backbone.js gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.
  • BackboneJS architecture contains the following modules −
  1. HTTP Request
  2. Router
  3. View
  4. Events
  5. Model
  6. Collection
  7. Data Source
  • Some apps are too small to need building with an SPA framework such as Angular. The simplicity and interactivity of a jQuery-based application can be combined with the well-structured building blocks from Backbone.js to create interactive pages with code organization and structure.

📷 Screenshots

Example screenshot Example screenshot

📶 Technologies

💾 Setup

  • runs from index.html in browser.

💻 Code Examples

EmployeeManager.Views.Employee = Backbone.View.extend(
	{
		tagName: 'li',
		className: 'media col-md-6 col-lg-4',
		template: _.template($('#tpl-contact').html()),

		events: {
			'click .delete-employee': 'onClickDelete'
		},

		initialize: function() {
			this.listenTo(this.model, 'remove', this.remove);
		},

		render: function() {
			var html = this.template(this.model.toJSON());
			this.$el.append(html);
			return this;
		},

		onClickDelete: function(e) {
			e.preventDefault();
			this.model.collection.remove(this.model);
		}
	}
);

🆒 Features

  • employees can be added and edited

📋 Status & To-Do List

  • Status: Working. Delete function not working
  • To-Do: Fix delete function. Delete button commented out

👏 Inspiration

📁 License

  • This project is licensed under the terms of the MIT license.

✉️ Contact

About

📋 App using backbone.js and jQuery to make a simple database

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published