SlideShare uma empresa Scribd logo
1 de 52
Sahana Eden: Emergency Development Environment 30 September 2010, Grace Hopper Celebration Fran Boon [email_address]
Agenda ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Stack Overview ,[object Object],Client Browser Eclipse Firebug Sahana Eden (S3) Web2Py Python HTML JavaScript CSS
Installation: Virtual Machine ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Model-View-Controller ,[object Object],[object Object],[object Object],[object Object]
Model-View-Controller ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Model-View-Controller ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Modules ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Sahana Modules ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Branches LaunchPad Merge proposal Trunk Local Branch Your Branch bzr merge bzr push
Request processing ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Emergency ,[object Object]
Software Development Cycle
Incident Reporting System ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Define Data ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Forms for CRUD ,[object Object],[object Object],[object Object],[object Object]
We’re done! ,[object Object],[object Object],[object Object],[object Object],[object Object]
Views: Custom REST ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
SQL constraints / Validators ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Field Types ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Default Values ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Labels ,[object Object],[object Object]
Internationalisation ,[object Object],[object Object]
Comments ,[object Object],[object Object]
Requires ,[object Object],[object Object],[object Object]
Represent ,[object Object],[object Object]
Exploring: Web2Py shell ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
DAL ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
End
Enable Module ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Index page ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
View ,[object Object],[object Object],[object Object],[object Object],[object Object]
Controller: Menu ,[object Object],[object Object],[object Object]
Joined Resources ,[object Object],[object Object],[object Object],[object Object]
Joined Resources: Model ,[object Object],[object Object]
Joined Resources: Model ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Joined Resources: Model ,[object Object],[object Object],[object Object],[object Object],[object Object]
Joined Resources: Model ,[object Object],[object Object],[object Object],[object Object],[object Object]
Joined Resources: Controller ,[object Object],[object Object],[object Object],[object Object],[object Object]
Joined Resources: Model  ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Joined Resources: Model ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Represent ,[object Object]
DAL: Optimised SQL queries ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
JR: Represent ,[object Object],[object Object]
Components ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
RHeader ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
RHeader Tabs ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
RHeader Tabs
S3 is built on Web2Py REST CRUD SQLFORM FORM
Form submission ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Documentation ,[object Object],[object Object],[object Object],[object Object]
Use the Source, Luke! ,[object Object]

Mais conteúdo relacionado

Mais procurados

OpenERP Technical Memento
OpenERP Technical MementoOpenERP Technical Memento
OpenERP Technical MementoOdoo
 
Introduction to Zend Framework web services
Introduction to Zend Framework web servicesIntroduction to Zend Framework web services
Introduction to Zend Framework web servicesMichelangelo van Dam
 
Be RESTful (Symfony Camp 2008)
Be RESTful (Symfony Camp 2008)Be RESTful (Symfony Camp 2008)
Be RESTful (Symfony Camp 2008)Fabien Potencier
 
50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 Minutes50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 MinutesAzim Kurt
 
Laravel 로 배우는 서버사이드 #5
Laravel 로 배우는 서버사이드 #5Laravel 로 배우는 서버사이드 #5
Laravel 로 배우는 서버사이드 #5성일 한
 
Apostrophe (improved Paris edition)
Apostrophe (improved Paris edition)Apostrophe (improved Paris edition)
Apostrophe (improved Paris edition)tompunk
 
Aplicacoes dinamicas Rails com Backbone
Aplicacoes dinamicas Rails com BackboneAplicacoes dinamicas Rails com Backbone
Aplicacoes dinamicas Rails com BackboneRafael Felix da Silva
 
Alloy Tips & Tricks #TiLon
Alloy Tips & Tricks #TiLonAlloy Tips & Tricks #TiLon
Alloy Tips & Tricks #TiLonFokke Zandbergen
 
Tools for Making Machine Learning more Reactive
Tools for Making Machine Learning more ReactiveTools for Making Machine Learning more Reactive
Tools for Making Machine Learning more ReactiveJeff Smith
 
“iOS 11 в App in the Air”, Пронин Сергей, App in the Air
“iOS 11 в App in the Air”, Пронин Сергей, App in the Air“iOS 11 в App in the Air”, Пронин Сергей, App in the Air
“iOS 11 в App in the Air”, Пронин Сергей, App in the AirAvitoTech
 
Presentation of the new OpenERP API. Raphael Collet, OpenERP
Presentation of the new OpenERP API. Raphael Collet, OpenERPPresentation of the new OpenERP API. Raphael Collet, OpenERP
Presentation of the new OpenERP API. Raphael Collet, OpenERPOdoo
 
AngularJS vs. Ember.js vs. Backbone.js
AngularJS vs. Ember.js vs. Backbone.jsAngularJS vs. Ember.js vs. Backbone.js
AngularJS vs. Ember.js vs. Backbone.jsMark
 
Sahana Eden - Introduction to the Code
Sahana Eden - Introduction to the CodeSahana Eden - Introduction to the Code
Sahana Eden - Introduction to the CodeAidIQ
 
Rapid prototyping search applications with solr
Rapid prototyping search applications with solrRapid prototyping search applications with solr
Rapid prototyping search applications with solrLucidworks (Archived)
 
Silex meets SOAP & REST
Silex meets SOAP & RESTSilex meets SOAP & REST
Silex meets SOAP & RESTHugo Hamon
 

Mais procurados (19)

OpenERP Technical Memento
OpenERP Technical MementoOpenERP Technical Memento
OpenERP Technical Memento
 
Introduction to Zend Framework web services
Introduction to Zend Framework web servicesIntroduction to Zend Framework web services
Introduction to Zend Framework web services
 
Be RESTful (Symfony Camp 2008)
Be RESTful (Symfony Camp 2008)Be RESTful (Symfony Camp 2008)
Be RESTful (Symfony Camp 2008)
 
50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 Minutes50 Laravel Tricks in 50 Minutes
50 Laravel Tricks in 50 Minutes
 
Laravel 로 배우는 서버사이드 #5
Laravel 로 배우는 서버사이드 #5Laravel 로 배우는 서버사이드 #5
Laravel 로 배우는 서버사이드 #5
 
Apostrophe (improved Paris edition)
Apostrophe (improved Paris edition)Apostrophe (improved Paris edition)
Apostrophe (improved Paris edition)
 
Aplicacoes dinamicas Rails com Backbone
Aplicacoes dinamicas Rails com BackboneAplicacoes dinamicas Rails com Backbone
Aplicacoes dinamicas Rails com Backbone
 
Alloy Tips & Tricks #TiLon
Alloy Tips & Tricks #TiLonAlloy Tips & Tricks #TiLon
Alloy Tips & Tricks #TiLon
 
Tools for Making Machine Learning more Reactive
Tools for Making Machine Learning more ReactiveTools for Making Machine Learning more Reactive
Tools for Making Machine Learning more Reactive
 
“iOS 11 в App in the Air”, Пронин Сергей, App in the Air
“iOS 11 в App in the Air”, Пронин Сергей, App in the Air“iOS 11 в App in the Air”, Пронин Сергей, App in the Air
“iOS 11 в App in the Air”, Пронин Сергей, App in the Air
 
Presentation of the new OpenERP API. Raphael Collet, OpenERP
Presentation of the new OpenERP API. Raphael Collet, OpenERPPresentation of the new OpenERP API. Raphael Collet, OpenERP
Presentation of the new OpenERP API. Raphael Collet, OpenERP
 
Chainable datasource
Chainable datasourceChainable datasource
Chainable datasource
 
Pyramid REST
Pyramid RESTPyramid REST
Pyramid REST
 
Backbone - TDC 2011 Floripa
Backbone - TDC 2011 FloripaBackbone - TDC 2011 Floripa
Backbone - TDC 2011 Floripa
 
Ruby - Design patterns tdc2011
Ruby - Design patterns tdc2011Ruby - Design patterns tdc2011
Ruby - Design patterns tdc2011
 
AngularJS vs. Ember.js vs. Backbone.js
AngularJS vs. Ember.js vs. Backbone.jsAngularJS vs. Ember.js vs. Backbone.js
AngularJS vs. Ember.js vs. Backbone.js
 
Sahana Eden - Introduction to the Code
Sahana Eden - Introduction to the CodeSahana Eden - Introduction to the Code
Sahana Eden - Introduction to the Code
 
Rapid prototyping search applications with solr
Rapid prototyping search applications with solrRapid prototyping search applications with solr
Rapid prototyping search applications with solr
 
Silex meets SOAP & REST
Silex meets SOAP & RESTSilex meets SOAP & REST
Silex meets SOAP & REST
 

Destaque

Participatory Programming
Participatory ProgrammingParticipatory Programming
Participatory ProgrammingAidIQ
 
HFOSS and RAD
HFOSS and RADHFOSS and RAD
HFOSS and RADAidIQ
 
Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)
Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)
Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)AidIQ
 
Sahana sharing your work with others
Sahana   sharing your work with othersSahana   sharing your work with others
Sahana sharing your work with othersAidIQ
 
IT Systems for Disaster Management and Development
IT Systems for Disaster Management and DevelopmentIT Systems for Disaster Management and Development
IT Systems for Disaster Management and DevelopmentAidIQ
 
Sahana Eden : Deployment (SahanaCamp 1.2)
Sahana Eden : Deployment (SahanaCamp 1.2)Sahana Eden : Deployment (SahanaCamp 1.2)
Sahana Eden : Deployment (SahanaCamp 1.2)AidIQ
 
Open GeoSMS slayer chuang
Open GeoSMS   slayer chuangOpen GeoSMS   slayer chuang
Open GeoSMS slayer chuangAidIQ
 
Sahana community development process
Sahana   community development processSahana   community development process
Sahana community development processAidIQ
 
Sahana Overview
Sahana OverviewSahana Overview
Sahana OverviewAidIQ
 
Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)
Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)
Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)AidIQ
 
Sahana Reponse to Haiti Earthquake
Sahana Reponse to Haiti EarthquakeSahana Reponse to Haiti Earthquake
Sahana Reponse to Haiti EarthquakeAidIQ
 
Humanitarian Mapping - Sahana and OpenStreetMap
Humanitarian Mapping - Sahana and OpenStreetMapHumanitarian Mapping - Sahana and OpenStreetMap
Humanitarian Mapping - Sahana and OpenStreetMapAidIQ
 
OpenStreetMap louis liu
OpenStreetMap   louis liuOpenStreetMap   louis liu
OpenStreetMap louis liuAidIQ
 
Sahana Open Source Humanitarian Software Project - Pandemic Preparedness Forum
Sahana Open Source Humanitarian Software Project - Pandemic Preparedness ForumSahana Open Source Humanitarian Software Project - Pandemic Preparedness Forum
Sahana Open Source Humanitarian Software Project - Pandemic Preparedness ForumAidIQ
 
OpenStreetMap dongpo deng
OpenStreetMap   dongpo dengOpenStreetMap   dongpo deng
OpenStreetMap dongpo dengAidIQ
 
Bombeiros Workshop - Introduction to Sahana Eden
Bombeiros Workshop - Introduction to Sahana EdenBombeiros Workshop - Introduction to Sahana Eden
Bombeiros Workshop - Introduction to Sahana EdenAidIQ
 
Tech 2 - Introduction to the Code
Tech 2 - Introduction to the CodeTech 2 - Introduction to the Code
Tech 2 - Introduction to the CodeAidIQ
 
Sahana TW
Sahana TWSahana TW
Sahana TWAidIQ
 
Sahana Eden : Bug Reporting (SahanaCamp 1.2)
Sahana Eden : Bug Reporting (SahanaCamp 1.2)Sahana Eden : Bug Reporting (SahanaCamp 1.2)
Sahana Eden : Bug Reporting (SahanaCamp 1.2)AidIQ
 
Sahana : Case Studies (SahanaCamp 1.2)
Sahana : Case Studies (SahanaCamp 1.2)Sahana : Case Studies (SahanaCamp 1.2)
Sahana : Case Studies (SahanaCamp 1.2)AidIQ
 

Destaque (20)

Participatory Programming
Participatory ProgrammingParticipatory Programming
Participatory Programming
 
HFOSS and RAD
HFOSS and RADHFOSS and RAD
HFOSS and RAD
 
Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)
Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)
Sahana Eden : Introduction and Simulation A (SahanaCamp 1.2)
 
Sahana sharing your work with others
Sahana   sharing your work with othersSahana   sharing your work with others
Sahana sharing your work with others
 
IT Systems for Disaster Management and Development
IT Systems for Disaster Management and DevelopmentIT Systems for Disaster Management and Development
IT Systems for Disaster Management and Development
 
Sahana Eden : Deployment (SahanaCamp 1.2)
Sahana Eden : Deployment (SahanaCamp 1.2)Sahana Eden : Deployment (SahanaCamp 1.2)
Sahana Eden : Deployment (SahanaCamp 1.2)
 
Open GeoSMS slayer chuang
Open GeoSMS   slayer chuangOpen GeoSMS   slayer chuang
Open GeoSMS slayer chuang
 
Sahana community development process
Sahana   community development processSahana   community development process
Sahana community development process
 
Sahana Overview
Sahana OverviewSahana Overview
Sahana Overview
 
Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)
Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)
Sahana Eden : Developer Environment (VM) (SahanaCamp 1.2)
 
Sahana Reponse to Haiti Earthquake
Sahana Reponse to Haiti EarthquakeSahana Reponse to Haiti Earthquake
Sahana Reponse to Haiti Earthquake
 
Humanitarian Mapping - Sahana and OpenStreetMap
Humanitarian Mapping - Sahana and OpenStreetMapHumanitarian Mapping - Sahana and OpenStreetMap
Humanitarian Mapping - Sahana and OpenStreetMap
 
OpenStreetMap louis liu
OpenStreetMap   louis liuOpenStreetMap   louis liu
OpenStreetMap louis liu
 
Sahana Open Source Humanitarian Software Project - Pandemic Preparedness Forum
Sahana Open Source Humanitarian Software Project - Pandemic Preparedness ForumSahana Open Source Humanitarian Software Project - Pandemic Preparedness Forum
Sahana Open Source Humanitarian Software Project - Pandemic Preparedness Forum
 
OpenStreetMap dongpo deng
OpenStreetMap   dongpo dengOpenStreetMap   dongpo deng
OpenStreetMap dongpo deng
 
Bombeiros Workshop - Introduction to Sahana Eden
Bombeiros Workshop - Introduction to Sahana EdenBombeiros Workshop - Introduction to Sahana Eden
Bombeiros Workshop - Introduction to Sahana Eden
 
Tech 2 - Introduction to the Code
Tech 2 - Introduction to the CodeTech 2 - Introduction to the Code
Tech 2 - Introduction to the Code
 
Sahana TW
Sahana TWSahana TW
Sahana TW
 
Sahana Eden : Bug Reporting (SahanaCamp 1.2)
Sahana Eden : Bug Reporting (SahanaCamp 1.2)Sahana Eden : Bug Reporting (SahanaCamp 1.2)
Sahana Eden : Bug Reporting (SahanaCamp 1.2)
 
Sahana : Case Studies (SahanaCamp 1.2)
Sahana : Case Studies (SahanaCamp 1.2)Sahana : Case Studies (SahanaCamp 1.2)
Sahana : Case Studies (SahanaCamp 1.2)
 

Semelhante a GHC Participant Training

Sahana introduction to the code v2
Sahana   introduction to the code v2Sahana   introduction to the code v2
Sahana introduction to the code v2AidIQ
 
Implementation of GUI Framework part3
Implementation of GUI Framework part3Implementation of GUI Framework part3
Implementation of GUI Framework part3masahiroookubo
 
Rails 3 overview
Rails 3 overviewRails 3 overview
Rails 3 overviewYehuda Katz
 
Rails 3: Dashing to the Finish
Rails 3: Dashing to the FinishRails 3: Dashing to the Finish
Rails 3: Dashing to the FinishYehuda Katz
 
I Phone On Rails
I Phone On RailsI Phone On Rails
I Phone On RailsJohn Wilker
 
Already given code from 4 files- 1-app-ctrl-js code- -- include expres.pdf
Already given code from 4 files- 1-app-ctrl-js code- -- include expres.pdfAlready given code from 4 files- 1-app-ctrl-js code- -- include expres.pdf
Already given code from 4 files- 1-app-ctrl-js code- -- include expres.pdfas1mobiles
 
Rails GUI Development with Ext JS
Rails GUI Development with Ext JSRails GUI Development with Ext JS
Rails GUI Development with Ext JSMartin Rehfeld
 
Angular server side rendering - Strategies & Technics
Angular server side rendering - Strategies & Technics Angular server side rendering - Strategies & Technics
Angular server side rendering - Strategies & Technics Eliran Eliassy
 
Designing REST API automation tests in Kotlin
Designing REST API automation tests in KotlinDesigning REST API automation tests in Kotlin
Designing REST API automation tests in KotlinDmitriy Sobko
 
Boston Computing Review - Ruby on Rails
Boston Computing Review - Ruby on RailsBoston Computing Review - Ruby on Rails
Boston Computing Review - Ruby on RailsJohn Brunswick
 
Hack an ASP .NET website? Hard, but possible!
Hack an ASP .NET website? Hard, but possible! Hack an ASP .NET website? Hard, but possible!
Hack an ASP .NET website? Hard, but possible! Vladimir Kochetkov
 
Create an application with ember
Create an application with ember Create an application with ember
Create an application with ember Chandra Sekar
 
SproutCore and the Future of Web Apps
SproutCore and the Future of Web AppsSproutCore and the Future of Web Apps
SproutCore and the Future of Web AppsMike Subelsky
 
ADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael PizzoADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael PizzoHasnain Iqbal
 
Bag Of Tricks From Iusethis
Bag Of Tricks From IusethisBag Of Tricks From Iusethis
Bag Of Tricks From IusethisMarcus Ramberg
 
Protractor framework – how to make stable e2e tests for Angular applications
Protractor framework – how to make stable e2e tests for Angular applicationsProtractor framework – how to make stable e2e tests for Angular applications
Protractor framework – how to make stable e2e tests for Angular applicationsLudmila Nesvitiy
 

Semelhante a GHC Participant Training (20)

Sahana introduction to the code v2
Sahana   introduction to the code v2Sahana   introduction to the code v2
Sahana introduction to the code v2
 
Implementation of GUI Framework part3
Implementation of GUI Framework part3Implementation of GUI Framework part3
Implementation of GUI Framework part3
 
Rails 3 overview
Rails 3 overviewRails 3 overview
Rails 3 overview
 
JS-05-Handlebars.ppt
JS-05-Handlebars.pptJS-05-Handlebars.ppt
JS-05-Handlebars.ppt
 
Framework
FrameworkFramework
Framework
 
Rails 3: Dashing to the Finish
Rails 3: Dashing to the FinishRails 3: Dashing to the Finish
Rails 3: Dashing to the Finish
 
I Phone On Rails
I Phone On RailsI Phone On Rails
I Phone On Rails
 
前端概述
前端概述前端概述
前端概述
 
Already given code from 4 files- 1-app-ctrl-js code- -- include expres.pdf
Already given code from 4 files- 1-app-ctrl-js code- -- include expres.pdfAlready given code from 4 files- 1-app-ctrl-js code- -- include expres.pdf
Already given code from 4 files- 1-app-ctrl-js code- -- include expres.pdf
 
Rails GUI Development with Ext JS
Rails GUI Development with Ext JSRails GUI Development with Ext JS
Rails GUI Development with Ext JS
 
Angular server side rendering - Strategies & Technics
Angular server side rendering - Strategies & Technics Angular server side rendering - Strategies & Technics
Angular server side rendering - Strategies & Technics
 
Designing REST API automation tests in Kotlin
Designing REST API automation tests in KotlinDesigning REST API automation tests in Kotlin
Designing REST API automation tests in Kotlin
 
Boston Computing Review - Ruby on Rails
Boston Computing Review - Ruby on RailsBoston Computing Review - Ruby on Rails
Boston Computing Review - Ruby on Rails
 
Hack an ASP .NET website? Hard, but possible!
Hack an ASP .NET website? Hard, but possible! Hack an ASP .NET website? Hard, but possible!
Hack an ASP .NET website? Hard, but possible!
 
IOC + Javascript
IOC + JavascriptIOC + Javascript
IOC + Javascript
 
Create an application with ember
Create an application with ember Create an application with ember
Create an application with ember
 
SproutCore and the Future of Web Apps
SproutCore and the Future of Web AppsSproutCore and the Future of Web Apps
SproutCore and the Future of Web Apps
 
ADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael PizzoADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
 
Bag Of Tricks From Iusethis
Bag Of Tricks From IusethisBag Of Tricks From Iusethis
Bag Of Tricks From Iusethis
 
Protractor framework – how to make stable e2e tests for Angular applications
Protractor framework – how to make stable e2e tests for Angular applicationsProtractor framework – how to make stable e2e tests for Angular applications
Protractor framework – how to make stable e2e tests for Angular applications
 

Mais de AidIQ

Tech 1 - Deploying Sahana Eden
Tech 1  - Deploying Sahana EdenTech 1  - Deploying Sahana Eden
Tech 1 - Deploying Sahana EdenAidIQ
 
Introduction to Sahana Eden
Introduction to Sahana EdenIntroduction to Sahana Eden
Introduction to Sahana EdenAidIQ
 
Participatory programming
Participatory programmingParticipatory programming
Participatory programmingAidIQ
 
OpenStreetMap : Technical (SahanaCamp 1.2)
OpenStreetMap : Technical (SahanaCamp 1.2)OpenStreetMap : Technical (SahanaCamp 1.2)
OpenStreetMap : Technical (SahanaCamp 1.2)AidIQ
 
OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)
OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)
OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)AidIQ
 
Simulation: Instructions ((SahanaCamp 1.2)
Simulation: Instructions ((SahanaCamp 1.2)Simulation: Instructions ((SahanaCamp 1.2)
Simulation: Instructions ((SahanaCamp 1.2)AidIQ
 
Simulation: Incidents (SahanaCamp 1.2)
Simulation: Incidents (SahanaCamp 1.2)Simulation: Incidents (SahanaCamp 1.2)
Simulation: Incidents (SahanaCamp 1.2)AidIQ
 
Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)
Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)
Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)AidIQ
 
General Sessions Hand Outs (SahanaCamp 1.2)
General Sessions Hand Outs (SahanaCamp 1.2)General Sessions Hand Outs (SahanaCamp 1.2)
General Sessions Hand Outs (SahanaCamp 1.2)AidIQ
 
BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)
BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)
BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)AidIQ
 
Sahana Eden : Introduction to the Code (SahanaCamp 1.2)
Sahana Eden : Introduction to the Code (SahanaCamp 1.2)Sahana Eden : Introduction to the Code (SahanaCamp 1.2)
Sahana Eden : Introduction to the Code (SahanaCamp 1.2)AidIQ
 
Exercise24
Exercise24Exercise24
Exercise24AidIQ
 
Sahana camp simulation 1.1
Sahana camp simulation 1.1Sahana camp simulation 1.1
Sahana camp simulation 1.1AidIQ
 
Sahana camp incident reporting exercise v3
Sahana camp incident reporting exercise v3Sahana camp incident reporting exercise v3
Sahana camp incident reporting exercise v3AidIQ
 

Mais de AidIQ (14)

Tech 1 - Deploying Sahana Eden
Tech 1  - Deploying Sahana EdenTech 1  - Deploying Sahana Eden
Tech 1 - Deploying Sahana Eden
 
Introduction to Sahana Eden
Introduction to Sahana EdenIntroduction to Sahana Eden
Introduction to Sahana Eden
 
Participatory programming
Participatory programmingParticipatory programming
Participatory programming
 
OpenStreetMap : Technical (SahanaCamp 1.2)
OpenStreetMap : Technical (SahanaCamp 1.2)OpenStreetMap : Technical (SahanaCamp 1.2)
OpenStreetMap : Technical (SahanaCamp 1.2)
 
OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)
OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)
OpenStreetMap : Sahana Mapping Client (SahanaCamp 1.2)
 
Simulation: Instructions ((SahanaCamp 1.2)
Simulation: Instructions ((SahanaCamp 1.2)Simulation: Instructions ((SahanaCamp 1.2)
Simulation: Instructions ((SahanaCamp 1.2)
 
Simulation: Incidents (SahanaCamp 1.2)
Simulation: Incidents (SahanaCamp 1.2)Simulation: Incidents (SahanaCamp 1.2)
Simulation: Incidents (SahanaCamp 1.2)
 
Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)
Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)
Implementing IT Solutions for Disaster Management (SahanaCamp 1.2)
 
General Sessions Hand Outs (SahanaCamp 1.2)
General Sessions Hand Outs (SahanaCamp 1.2)General Sessions Hand Outs (SahanaCamp 1.2)
General Sessions Hand Outs (SahanaCamp 1.2)
 
BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)
BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)
BZR & LaunchPad : Sharing Your Work With Others (SahanaCamp 1.2)
 
Sahana Eden : Introduction to the Code (SahanaCamp 1.2)
Sahana Eden : Introduction to the Code (SahanaCamp 1.2)Sahana Eden : Introduction to the Code (SahanaCamp 1.2)
Sahana Eden : Introduction to the Code (SahanaCamp 1.2)
 
Exercise24
Exercise24Exercise24
Exercise24
 
Sahana camp simulation 1.1
Sahana camp simulation 1.1Sahana camp simulation 1.1
Sahana camp simulation 1.1
 
Sahana camp incident reporting exercise v3
Sahana camp incident reporting exercise v3Sahana camp incident reporting exercise v3
Sahana camp incident reporting exercise v3
 

GHC Participant Training

Notas do Editor

  1. S3 is a codename for Sahana Eden Server & Client can be on the same machine Each part needs to be debugged separately: Eclipse works well for the Server-side Python, whilst Firebug is excellent for the generated HTML/CSS/JavaScript JavaScript libraries we use include jQuery & ExtJS
  2. There are notes on the Wiki for installing a developer environment on Windows, Mac or Linux machines if you wish to run in other environments later.
  3. Look around the filesystem in web2py/applications/eden folder Similar layout structure to other MVC frameworks, such as Ruby-on-Rails & Django
  4. JavaScript which doesn’t require server-side parsing put into static Python Libraries available: System Python, Web2Py, Eden (S3*)
  5. The problems faced by both the victims of and responders to disasters are numerous. Beyond the trauma, this involves having to coordinate, manage and track things. In countries at risk of being affected by large scale sudden onset disasters, these problems can be massive and overwhelming.
  6. Normally you work in a local branch on your PC. You Merge changes in regularly from Trunk. You Push your changes to your branch on LaunchPad (You Pull from LaunchPad to update your server sites)
  7. Minimise the time taken to process Manage dependencies No need to import most of the libraries in ‘gluon/’
  8. Create a new file in the models folder called inc.py & type in the text above – be careful to use the correct case for Field!
  9. Create a new file in the controllers folder called inc.py & type in the text above – be careful to get the indentation correct!
  10. Note that you’ll need to Register yourself as a user on the system before you’re allowed to create a resource. The 1 st user to register gets the Administrator role by default.
  11. Create a new folder in the views folder called ‘ inc ’ & inside that put a new file ‘ incident_list_create.html’ . Type in the text above. Refresh the incident page to see the new text: http://127.0.0.1:8000/eden/inc/ incident No need to learn another macro language Defaults (non-REST) to views/controller/function.html Open the About page ( http://127.0.0.1:8000/eden/default/about ) & browse the variables We store our S3 variables in response.s3.*, session.s3.* so as not to pollute the Web2Py namespace
  12. unique=True is a SQL-level constraint. Open your inc.py from the models directory & add the extra code above. Validators are DAL-level constraints which produce nice error messages instead of tickets! Validators provide server-side validation & some also provide client-side rendering & validation Web2Py automatically adds a Validator when the SQL constraint is set.
  13. Fields default to type ‘string’. ‘ date’ is the SQL-level field type & also provides the class in the HTML which means we get a date widget Add the extra code above to your file & refresh the page, now enter a date.
  14. Add the extra code above to your file & refresh the page to see the default value
  15. Add this to your model (underneath the table definition) & try it out
  16. You can check out the languages file, if you wish: http://127.0.0.1:8000/admin/default/design/eden#languages Update all languages
  17. Add this to your model (underneath the table definition) & try it out Comment is rendered as ‘column3’ (although can be moved using ‘formstyle’) We also use the same space for Help buttons & ‘Add New Resource’ links. NB For optimal performance, we normally add such comments in the Controller instead & put them inside a ‘prep’ to tale effect just when ‘r.representation in shn_interactive_view_formats’
  18. Add this to your model (underneath the table definition) & try it out Comment is rendered as ‘column3’ (although can be moved using ‘formstyle’) We also use the same space for Help buttons & ‘Add New Resource’ links. NB For optimal performance, we normally add such comments in the Controller instead & put them inside a ‘prep’ to tale effect just when ‘r.representation in shn_interactive_view_formats’
  19. Add this to your model (underneath the table definition) & try it out Comment is rendered as ‘column3’ (although can be moved using ‘formstyle’) We also use the same space for Help buttons & ‘Add New Resource’ links. NB For optimal performance, we normally add such comments in the Controller instead & put them inside a ‘prep’ to tale effect just when ‘r.representation in shn_interactive_view_formats’
  20. This should be available as a script or an alias ‘w2p’ iPython needs to be installed for object exploring.
  21. Add this text to the file 000_config.py in the models folder. Navigate to the home page to see the module appear both there & on the menu. Try navigating to the module. Module Type 10 means appears in the ‘more’ section of the default modules menu. (Most deployments will create a fully-customised menu anyway)
  22. Add this text to your controller file & now open the module. “ Custom View” is a Doc String One should be added to all functions for automatic documentation generators & interactive browsing of docs You can try this out in the Interactive Shell: w2p execfile("applications/eden/controllers/vts.py", globals()) help(index)
  23. Create a file called ‘index.html’ inside the views/inc folder See plain HTML being interspersed with the server-side parsed Python Look at another module’s index.html What’s bad about this index?
  24. Add this text to your controller (outside the functions – e.g. at the top) & see what effect this has on your module.
  25. Copt this text into your model. Note the use of string substitution to define the tablename
  26. Tells SQL that these fields are ‘reference’ fields (i.e. Foreign Keys) - They store integers which are a pointer to the ID field in the other tables.
  27. Copy this text into your Model & refresh the presence page Reusable field defined in models/03_gis.py Includes additional useful configuration such as .requires & .represent
  28. Copt this text into your controller. Try it out. Note the automation of the resource name to minimise the editing after copy/paste of new functions
  29. Copy this text into your model & see what it does for the page IS_ONE_OF() will provide us a dropdown showing license plates, even though we actually store the ID. This is an S3 validator which extends Web2Py’s IS_IN_DB() to support the ‘deleted’ status & also allow the use of lambdas as formatting options.
  30. We can add additional fields into the link table.
  31. IS_ONE_OF provides the representation in the dropdown table.field.represent provides the representation in Display/List views A lambda is a Python feature for defining anonymous functions on the fly: http://diveintopython.org/power_of_introspection/lambda_functions.html
  32. Optimise the query – we know we only want a single record & a single field from that record
  33. Add the optimised query to your model.
  34. Add this to your model underneath the definition of the Presence table & try out the URL. No need for dedicated presence() controller
  35. Add this Resource Header definition to your Controller. Be careful to get the end brackets & commas right! ‘ r’ is the resource
  36. Then plug it into the Controller
  37. Take a look at the HTML structure of the page in Firebug.
  38. Web2Py source code very accessible – small enough to be able to grasp the whole thing after not too long FORM defined in gluon/html.py: Dumb HTML elements SQLFORM defined in gluon/sqlhtml.py: Self-processing forms which update the database CRUD defined in gluon/tools.py: Wrappers around SQLFORM - We actually change CRUD a lot & are looking to remove it completely – building straight on top of SQLFORM() REST defined in modules/s3xrc.py: RESTful interface & XML representations If you drop down a level, then need to do things more manually & need to take care of framework issues yourself.
  39. Whilst we spend a lot of time updating developer documentation, the actual codebase always moves faster, so the source is always the most authoritative source of information.