Giter VIP home page Giter VIP logo

grails-shell's Introduction

CRUD Project

Objective

Create a basic CRUD (create, read, update, delete) web application using the Grails framework. The application will track a customer's order history through multiple stores.

What's provided

As it stands, this is an empty shell of a Grails application that was created with Grails 2.5.0 via the grails create-app command. All plugins and dependencies are already self-contained. On the client side, this project provides the jQuery JavaScript library and Bootstrap framework.

Learning Curve

This project assumes no previous Grails experience and will require research skills and general resourcefulness when working in an unfamiliar environment.

You will have to research and learn the basics of Grails in order to demonstrate the ability to get an application up and running quickly. That being said, the Grails Getting Started guide is excellent and should accelerate your understanding of the framework. In addition, countless of other resources exist online. It's up to you to explore and investigate any questions that may arise during the development process.

Grails was designed for rapid development. You'll find that most features and concepts that are required in a web application are baked into the framework. There's no need to re-invent the wheel on most things, this is a project that is meant to demonstrate rapid development, not sheer programming prowess.

Development

This project requires Java 7 or above and Grails 2.5.0. Grails can be run from either GGTS (a fully-featured Grails IDE based on the Eclipse IDE) or the command line. Basic installation instructions are available via the Grails website.

Note that Grails 3 was recently released. Grails 3 is a major redesign of the Grails framework. We are using Grails 2.5.0 for this project. Keep that in mind in your research.

Requirements

Domain Model

Create a domain model which supports tracking a customer who can place orders with different stores. The customer has a name, address, city, state, zip, phone number, and date of birth. A store has a name, address, city, state, zip, phone number, and type of items sold (sporting goods, grocery, etc). An order has a date/time created, the store used, the customer the order is for, and the list of items purchased. An item has a catalog number, description, and price.

Where appropriate, these domain classes should constrain the values that they can contain. For example, if you have an email field, ensure that only a valid email address can be entered into the field.

Tip: Grails uses Hibernate to map Java objects to a relational database. By default it uses an in-memory database in development that can be viewed at http://localhost:8080/grails-shell/dbconsole. There is no password, so just click connect to view the database.

User Interface

Each domain class should have a corresponding CRUD interface: the ability to create, view, update, and delete objects from the UI. As mentioned before, Grails provides a great deal of functionality with minimal programmer effort. By default, Grails can easily provide a create, edit, show (detailed listing of a specific object), and listing page. Delete functionality is usually built in with the show/edit portion. There's no need to create any views in addition to these.

User Interface design should follow Bootstrap's design principles. It's up to you to decide how things should be laid out, but we've provided a structural framework to base your design on.

In addition to the views for each distinct domain class, modify the default view (index.gsp) to display a "dashboard" consisting of both the Customer and Order listings. It should have a "mini-view" of the list of the orders, and then the same for a list of the customers. This dashboard should be populated dynamically, that is, it should be empty when the page is initially rendered from the server, and populated via asynchronous JavaScript (AJAX). jQuery provides a number of handy methods for dealing with AJAX.

Hint: This shouldn't require any additional server side code than what you've created to support the normal CRUD views.

Extras

Tests are an important part of the Grails environment. Effective test-driven development ensures quality and stability while exposing bugs early and often. That being said, tests are out of the scope of this project. Add them if it's something you're used to doing and helps you work, but they're not required.

Delivery

Commit your changes to this repository, or send an email with your completed project as an attachment. We'd like for you to complete this project without any assistance, but if you do run into major problems (issues installing Grails or just getting this empty application to run) feel free to get in contact with us. Starting with a new framework and development tools can be difficult!

grails-shell's People

Contributors

dpcasady avatar

Watchers

James Cloos avatar Mash Syed avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.