Skip to content
Kyle Purdon edited this page May 28, 2014 · 20 revisions

Get the source code

git clone https://github.com/CReSIS/OPS-GEOPORTAL.git [yourLocalDirectory]

Directory Structure

These are the basic pieces (there are more but these are the key ones).

OPS-GEOPORTAL/
   app/
      controller/
      model/
      store/
      view/
      Application.js
      Global.js
   build/
   ext/
   geoext/
   ol/
   ol-custom/
   app.js
   opsBuildPortal.py

app/ this directory contains the actual source code of the application you are creating. Most all of the development you do occurs in this directory.

app/controller/ this directory contains all of the controllers. Controllers contain the logic of the views. For example a view defines where a button is rendered and what it looks like and a controller defines what happens when the button gets clicked.

app/model this directory contains all of the models. Models define the data structure of a store. A store is the actual place where data is contained and defines how/where the data comes from. What structure of data the store will contain is defined in the model.

app/store/ this directory contains all of the stores. Stores are where data is contained, accessed, manipulated, and saved throughout the application. Stores can use AJAX to get data, contain hard-coded fixed data, or use other means of retrieving data via the web.

app/view this directory contains all of the views. Views deifne how the application is visually laid out. In some cases (for example the arctic/antarctic maptab views) the logic is contained in the view itself. Having logic in a view is not following MVC exactly but GeoExt + Ext makes this difficult to do sometimes.

ext/ geoext/ ol/ are the library source directories. They contain the raw source code for the libraries downloaded directly from the web. No modifications are generally made in these directories.

ol-custom/ is the OPS custom built ol (OpenLayers) library which essentially is a subset of the complete ol source code, but only the pieces the OPS GeoPortal needs/uses. This allows it to load fast. (More Information Here)[http://docs.openlayers.org/library/deploying.html]