Wulin kungfu final

491 views

Published on

My topic on RubyConfChina2012, introduces wulin_master gem which is used for building enterprise application with ruby.

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
491
On SlideShare
0
From Embeds
0
Number of Embeds
4
Actions
Shares
0
Downloads
2
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Wulin kungfu final

  1. 1. Wulin Kungfu Fight for Ruby Enterprise problems
  2. 2. Background!   FIFA World Cup 2010 in South Africa!   BSS software managing the Broadcasting of the event !   TV and Radio orders !   Broadcasting instructions !   Temporal booking !   Spatial booking !   Finance
  3. 3. Problems! Extjs (everything is JavaScript)!   Code duplication !   Controllers setup for the JSON !   JavaScript setup of the grid and screens!   Heavy UI - Instability
  4. 4. We hope …!   Lighter!   Easier!   DSL!   Faster productivity
  5. 5. Birth of WulinMaster
  6. 6. WulinMaster!   A Ruby on Rails based framework!   For resolving enterprise problems!   Developer friendly!   Extensible
  7. 7. !   Application Interface
  8. 8. Tools and technologies!   Based on: !   Ruby on Rails ( >= 3.1 ) ! SlickGrid ( https://github.com/mleibman/SlickGrid ) ! jQuery plugins (jQuery UI, BBQ …)!   The Wulin plugins are Rails Engines.!   Use JSON as communication format.
  9. 9. Architecture Your Application WulinOAuthWulinScreenController WulinHomeControllerWulinScreen GridAction GridBehavior WulinPermit Other WulinWulinGrid GridColumn GridRelation WulinAudit PluginsWulinPanel GridStates WulinMaster WulinExcel Ruby on Rails SlickGrid jQuery Plugins
  10. 10. Create Your Guild
  11. 11. Wulin generator rails g wulin_master:install create app/controllers/homepage_controller.rb (menu configuration)create config/initializers/wulin_master.rbroute root :to => homepage#index’
  12. 12. Build the menu# app/controllers/homepage_controller.rb
  13. 13. Wulin Grid!   Fundamental component!   Remote data!   Auto cell types!   Association columns
  14. 14. Wulin Screen!   Fundamental container!   One/more grids/panels!   Specific configurations for grids in it
  15. 15. Rails MVC Wulin MVCModel View Model grid grid Screen both change Controller Controller Auto generated Browser Browser
  16. 16. Build a screen and a grid rails g wulin_master:screen_and_grid blogger name:string age:integer country:reference create db/migrate/20121115075159_create_bloggers.rb create app/controllers/bloggers_controller.rb create app/screens/blogger_screen.rb create app/grids/blogger_grid.rb create app/models/blogger.rb create app/views/bloggers route resources :bloggers
  17. 17. # app/grids/blogger_grid.rb# app/screens/blogger_screen.rb
  18. 18. Your first house!
  19. 19. Furnish it!   Grid Action!   Grid Behavior!   Grid Relation
  20. 20. Grid Action!   A toolbar button!   Active – respond to a user event!   Implemented in JavaScript!   Default actions are: Add, Edit, Delete!   Plugins might provide default actions such as Export Excel, Audit, etc.
  21. 21. Grid Behavior!   Passive Triggered by grid event!   Implemented by JavaScript!   Default behaviors
  22. 22. # app/assets/javascripts/actions/show_info.js
  23. 23. # app/assets/javascripts/behaviors/say_hello.js
  24. 24. Grid Relation!   One screen, multiple grids!   Interaction between grids!   Default relations
  25. 25. # app/screens/bloggers_posts_screen.rb
  26. 26. Level up!
  27. 27. Crafting your own weapon!   Rails Engine!   Write your own components!   Define your own actions / behaviors!   Equip it
  28. 28. Open source! http://github.com/ekohe/wulin_demo! http://github/com/ekohe/wulin_master!   http://wulin_demo.ekohe.com
  29. 29. Jimmy Huang (jimmy@ekohe.com) 黄腾 @pake007

×