photoviewer 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/LICENSE +842 -0
- data/README +33 -0
- data/Rakefile +38 -0
- data/app/controllers/application.rb +28 -0
- data/app/controllers/list_controller.rb +86 -0
- data/app/helpers/application_helper.rb +20 -0
- data/app/helpers/list_helper.rb +19 -0
- data/app/models/list.rb +19 -0
- data/app/views/list/banner.html.erb +148 -0
- data/app/views/list/images.xml +8 -0
- data/app/views/list/index.html.erb +46 -0
- data/app/views/list/promo.html.erb +89 -0
- data/app/views/list/response.xml +1 -0
- data/app/views/list/set_index.html.erb +77 -0
- data/app/views/list/view.html.erb +150 -0
- data/catalog.xml +4 -0
- data/config/boot.rb +109 -0
- data/config/database.yml +24 -0
- data/config/environment.rb +62 -0
- data/config/environments/development.rb +18 -0
- data/config/environments/production.rb +19 -0
- data/config/environments/test.rb +22 -0
- data/config/initializers/inflections.rb +10 -0
- data/config/initializers/mime_types.rb +5 -0
- data/config/rmobio.yml +10 -0
- data/config/routes.rb +37 -0
- data/coverage/app-controllers-application_rb.html +659 -0
- data/coverage/app-controllers-list_controller_rb.html +717 -0
- data/coverage/app-helpers-application_helper_rb.html +651 -0
- data/coverage/app-helpers-list_helper_rb.html +650 -0
- data/coverage/index.html +390 -0
- data/db/schema.rb +14 -0
- data/doc/README_FOR_APP +2 -0
- data/log/development.log +675 -0
- data/log/test.log +630 -0
- data/public/404.html +30 -0
- data/public/422.html +30 -0
- data/public/500.html +30 -0
- data/public/dispatch.cgi +10 -0
- data/public/dispatch.fcgi +24 -0
- data/public/dispatch.rb +10 -0
- data/public/favicon.ico +0 -0
- data/public/images/bn/afp.png +0 -0
- data/public/images/bn/airtel.png +0 -0
- data/public/images/bn/bpl.png +0 -0
- data/public/images/bn/imobizo.png +0 -0
- data/public/images/bn/toi.png +0 -0
- data/public/images/bn/trivia.png +0 -0
- data/public/images/cricket.png +0 -0
- data/public/images/default_state_icon.png +0 -0
- data/public/images/mobio_small.png +0 -0
- data/public/images/rails.png +0 -0
- data/public/images/time_small.png +0 -0
- data/public/images/title_icon.png +0 -0
- data/public/index.html +277 -0
- data/public/javascripts/application.js +2 -0
- data/public/javascripts/controls.js +963 -0
- data/public/javascripts/dragdrop.js +972 -0
- data/public/javascripts/effects.js +1120 -0
- data/public/javascripts/prototype.js +4225 -0
- data/public/robots.txt +5 -0
- data/public/stylesheets/scaffold.css +74 -0
- data/script/about +3 -0
- data/script/console +3 -0
- data/script/destroy +3 -0
- data/script/generate +3 -0
- data/script/performance/benchmarker +3 -0
- data/script/performance/profiler +3 -0
- data/script/performance/request +3 -0
- data/script/plugin +3 -0
- data/script/process/inspector +3 -0
- data/script/process/reaper +3 -0
- data/script/process/spawner +3 -0
- data/script/runner +3 -0
- data/script/server +3 -0
- data/test/functional/list_controller_test.rb +25 -0
- data/test/test_helper.rb +55 -0
- data/test/unit/list_test.rb +25 -0
- metadata +184 -0
@@ -0,0 +1,150 @@
|
|
1
|
+
<html id="root" xmlns="http://www.mobio.com/ext"
|
2
|
+
xmlns:xhtml="http://www.w3.org/1999/xhtml"
|
3
|
+
xmlns:xf="http://www.w3.org/2002/xforms"
|
4
|
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
5
|
+
xmlns:ext="http://www.mobio.com/ext"
|
6
|
+
xmlns:ev="http://www.w3.org/2001/xml-events">
|
7
|
+
<xhtml:head>
|
8
|
+
<xf:model>
|
9
|
+
<!-- image urls are loaded dynamically -->
|
10
|
+
<xf:instance id="pData" src="get_images"/>
|
11
|
+
|
12
|
+
<!-- banner -->
|
13
|
+
<xf:instance id="banner" src="<%=@ad_url%>"/>
|
14
|
+
</xf:model>
|
15
|
+
|
16
|
+
<style>
|
17
|
+
<class name="border">
|
18
|
+
<align value="center,image-center"/>
|
19
|
+
<border value="1"/>
|
20
|
+
<border-color value="#ff0000"/>
|
21
|
+
</class>
|
22
|
+
<class name="margin">
|
23
|
+
<border value="1"/>
|
24
|
+
<border-color value="#ff0000"/>
|
25
|
+
</class>
|
26
|
+
<class name="body">
|
27
|
+
<background-color value="#66CC00"/>
|
28
|
+
</class>
|
29
|
+
|
30
|
+
<class name="img">
|
31
|
+
<align value="center"/>
|
32
|
+
<margin value="2"/>
|
33
|
+
</class>
|
34
|
+
<class name="img:focused">
|
35
|
+
<border value="1"/>
|
36
|
+
<border-color value="#0000ff"/>
|
37
|
+
</class>
|
38
|
+
<class name="button">
|
39
|
+
<border value="1"/>
|
40
|
+
<font-color value="#ffffff" />
|
41
|
+
<font-weight value="bold" />
|
42
|
+
<background-color value="#008000"/>
|
43
|
+
<border-color value="#ffffff"/>
|
44
|
+
<margin value="0,0,0,1"/>
|
45
|
+
</class>
|
46
|
+
<class name="button:focused">
|
47
|
+
<font-color value="#000000" />
|
48
|
+
<background-color value="#ffff00"/>
|
49
|
+
<border-color value="#0000ff"/>
|
50
|
+
</class>
|
51
|
+
<class name="button:disabled">
|
52
|
+
<font-color value="#c0c0c0" />
|
53
|
+
<background-color value="#808080"/>
|
54
|
+
<border-color value="#0000ff"/>
|
55
|
+
</class>
|
56
|
+
|
57
|
+
<class name="cell">
|
58
|
+
<background-color value="transparent"/>
|
59
|
+
<margin value="5" />
|
60
|
+
</class>
|
61
|
+
|
62
|
+
<class name="cell:focused">
|
63
|
+
<border value="1" />
|
64
|
+
</class>
|
65
|
+
</style>
|
66
|
+
</xhtml:head>
|
67
|
+
|
68
|
+
<xhtml:body style="body">
|
69
|
+
<switch>
|
70
|
+
<case id="main">
|
71
|
+
<output height="1ex" value="index('mylist')"/>
|
72
|
+
<textoutput height="3ex">Center select an image to start slideshow from that image. Click SlideShow softkey starts slideshow from image 1.</textoutput>
|
73
|
+
<grid>
|
74
|
+
<rowset id="mylist" nodeset="instance('pData')/images/image" col="auto">
|
75
|
+
<item height="0" width="15em" style="cell">
|
76
|
+
<vstack height="0">
|
77
|
+
<image height="2ex" width="10em" ref="." style="img"/>
|
78
|
+
<output height="1ex" width="10em" ref="@label" style="img"/>
|
79
|
+
</vstack>
|
80
|
+
<xf:action ev:event="DOMActivate" >
|
81
|
+
<xf:setindex refid="imgview" index="index('mylist')"/>
|
82
|
+
<xf:setindex refid="imgbanner" index="'1'"/>
|
83
|
+
<xf:toggle case="view"/>
|
84
|
+
<xf:setfocus control="imgview"/>
|
85
|
+
</xf:action>
|
86
|
+
|
87
|
+
</item>
|
88
|
+
</rowset>
|
89
|
+
</grid>
|
90
|
+
<output height="1ex" ref="instance('pData')/images/image[index('mylist')]/@label"/>
|
91
|
+
<softkey position="3">
|
92
|
+
<label>SlideShow</label>
|
93
|
+
<xf:action ev:event="DOMActivate">
|
94
|
+
<xf:setindex refid="imgview" index="'1'"/>
|
95
|
+
<xf:setindex refid="imgbanner" index="'1'"/>
|
96
|
+
<xf:toggle case="view"/>
|
97
|
+
</xf:action>
|
98
|
+
</softkey>
|
99
|
+
</case>
|
100
|
+
<case id="view">
|
101
|
+
<output height="1ex" value="index('imgview')"/>
|
102
|
+
<textoutput height="3ex">Center select to start/stop slideshow. Banner image rotates when new image is dipalyed.</textoutput>
|
103
|
+
|
104
|
+
<image id="imgbanner" height="2ex"
|
105
|
+
nodeset="instance('banner')/ads/ad/image_url" style="img" >
|
106
|
+
<item>
|
107
|
+
<xf:action ev:event="DOMActivate">
|
108
|
+
<xf:load resource="promo"/>
|
109
|
+
</xf:action>
|
110
|
+
</item>
|
111
|
+
|
112
|
+
</image>
|
113
|
+
<image id="imgview"
|
114
|
+
nodeset="instance('pData')/images/image" style="img" delay="2">
|
115
|
+
<item>
|
116
|
+
|
117
|
+
<xf:action ev:event="DOMActivate">
|
118
|
+
<xf:setindex refid="imgbanner" index="index('imgbanner')+1" />
|
119
|
+
</xf:action>
|
120
|
+
<xf:action ev:event="DOMActivate" value="index('imgbanner') = count(instance('banner')/images/image)">
|
121
|
+
<xf:setindex refid="imgbanner" index="number('1')"/>
|
122
|
+
</xf:action>
|
123
|
+
<xf:action ev:event="image-loaded">
|
124
|
+
<xf:setindex refid="imgbanner" index="index('imgbanner')+1" />
|
125
|
+
</xf:action>
|
126
|
+
<xf:action ev:event="image-loaded" value="index('imgbanner') = count(instance('pData')/images/image)">
|
127
|
+
<xf:setindex refid="imgbanner" index="number('1')"/>
|
128
|
+
</xf:action>
|
129
|
+
|
130
|
+
</item>
|
131
|
+
</image>
|
132
|
+
<output height="1ex" ref="instance('pData')/images/image[index('imgview')]/@label"/>
|
133
|
+
|
134
|
+
|
135
|
+
<softkey position="1">
|
136
|
+
<label>Back</label>
|
137
|
+
<xf:toggle case="main" ev:event="DOMActivate"/>
|
138
|
+
</softkey>
|
139
|
+
|
140
|
+
</case>
|
141
|
+
|
142
|
+
</switch>
|
143
|
+
<footer>
|
144
|
+
<softkey position="1">
|
145
|
+
<label>Back</label>
|
146
|
+
<back ev:event="DOMActivate"/>
|
147
|
+
</softkey>
|
148
|
+
</footer>
|
149
|
+
</xhtml:body>
|
150
|
+
</html>
|
data/catalog.xml
ADDED
data/config/boot.rb
ADDED
@@ -0,0 +1,109 @@
|
|
1
|
+
# Don't change this file!
|
2
|
+
# Configure your app in config/environment.rb and config/environments/*.rb
|
3
|
+
|
4
|
+
RAILS_ROOT = "#{File.dirname(__FILE__)}/.." unless defined?(RAILS_ROOT)
|
5
|
+
|
6
|
+
module Rails
|
7
|
+
class << self
|
8
|
+
def boot!
|
9
|
+
unless booted?
|
10
|
+
preinitialize
|
11
|
+
pick_boot.run
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
def booted?
|
16
|
+
defined? Rails::Initializer
|
17
|
+
end
|
18
|
+
|
19
|
+
def pick_boot
|
20
|
+
(vendor_rails? ? VendorBoot : GemBoot).new
|
21
|
+
end
|
22
|
+
|
23
|
+
def vendor_rails?
|
24
|
+
File.exist?("#{RAILS_ROOT}/vendor/rails")
|
25
|
+
end
|
26
|
+
|
27
|
+
# FIXME : Ruby 1.9
|
28
|
+
def preinitialize
|
29
|
+
load(preinitializer_path) if File.exists?(preinitializer_path)
|
30
|
+
end
|
31
|
+
|
32
|
+
def preinitializer_path
|
33
|
+
"#{RAILS_ROOT}/config/preinitializer.rb"
|
34
|
+
end
|
35
|
+
end
|
36
|
+
|
37
|
+
class Boot
|
38
|
+
def run
|
39
|
+
load_initializer
|
40
|
+
Rails::Initializer.run(:set_load_path)
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
class VendorBoot < Boot
|
45
|
+
def load_initializer
|
46
|
+
require "#{RAILS_ROOT}/vendor/rails/railties/lib/initializer"
|
47
|
+
end
|
48
|
+
end
|
49
|
+
|
50
|
+
class GemBoot < Boot
|
51
|
+
def load_initializer
|
52
|
+
self.class.load_rubygems
|
53
|
+
load_rails_gem
|
54
|
+
require 'initializer'
|
55
|
+
end
|
56
|
+
|
57
|
+
def load_rails_gem
|
58
|
+
if version = self.class.gem_version
|
59
|
+
gem 'rails', version
|
60
|
+
else
|
61
|
+
gem 'rails'
|
62
|
+
end
|
63
|
+
rescue Gem::LoadError => load_error
|
64
|
+
$stderr.puts %(Missing the Rails #{version} gem. Please `gem install -v=#{version} rails`, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.)
|
65
|
+
exit 1
|
66
|
+
end
|
67
|
+
|
68
|
+
class << self
|
69
|
+
def rubygems_version
|
70
|
+
Gem::RubyGemsVersion if defined? Gem::RubyGemsVersion
|
71
|
+
end
|
72
|
+
|
73
|
+
def gem_version
|
74
|
+
if defined? RAILS_GEM_VERSION
|
75
|
+
RAILS_GEM_VERSION
|
76
|
+
elsif ENV.include?('RAILS_GEM_VERSION')
|
77
|
+
ENV['RAILS_GEM_VERSION']
|
78
|
+
else
|
79
|
+
parse_gem_version(read_environment_rb)
|
80
|
+
end
|
81
|
+
end
|
82
|
+
|
83
|
+
def load_rubygems
|
84
|
+
require 'rubygems'
|
85
|
+
|
86
|
+
unless rubygems_version >= '0.9.4'
|
87
|
+
$stderr.puts %(Rails requires RubyGems >= 0.9.4 (you have #{rubygems_version}). Please `gem update --system` and try again.)
|
88
|
+
exit 1
|
89
|
+
end
|
90
|
+
|
91
|
+
rescue LoadError
|
92
|
+
$stderr.puts %(Rails requires RubyGems >= 0.9.4. Please install RubyGems and try again: http://rubygems.rubyforge.org)
|
93
|
+
exit 1
|
94
|
+
end
|
95
|
+
|
96
|
+
def parse_gem_version(text)
|
97
|
+
$1 if text =~ /^[^#]*RAILS_GEM_VERSION\s*=\s*["']([!~<>=]*\s*[\d.]+)["']/
|
98
|
+
end
|
99
|
+
|
100
|
+
private
|
101
|
+
def read_environment_rb
|
102
|
+
File.read("#{RAILS_ROOT}/config/environment.rb")
|
103
|
+
end
|
104
|
+
end
|
105
|
+
end
|
106
|
+
end
|
107
|
+
|
108
|
+
# All that for this:
|
109
|
+
Rails.boot!
|
data/config/database.yml
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
|
2
|
+
development:
|
3
|
+
adapter: mysql
|
4
|
+
database: photoviewer_development
|
5
|
+
username: root
|
6
|
+
password:
|
7
|
+
host: localhost
|
8
|
+
|
9
|
+
# Warning: The database defined as 'test' will be erased and
|
10
|
+
# re-generated from your development database when you run 'rake'.
|
11
|
+
# Do not set this db to the same as development or production.
|
12
|
+
test:
|
13
|
+
adapter: mysql
|
14
|
+
database: photoviewer_test
|
15
|
+
username: root
|
16
|
+
password:
|
17
|
+
host: localhost
|
18
|
+
|
19
|
+
production:
|
20
|
+
adapter: mysql
|
21
|
+
database: photoviewer_production
|
22
|
+
username: root
|
23
|
+
password:
|
24
|
+
host: localhost
|
@@ -0,0 +1,62 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file
|
2
|
+
|
3
|
+
# Uncomment below to force Rails into production mode when
|
4
|
+
# you don't control web/app server and can't set it the proper way
|
5
|
+
# ENV['RAILS_ENV'] ||= 'production'
|
6
|
+
|
7
|
+
# Specifies gem version of Rails to use when vendor/rails is not present
|
8
|
+
RAILS_GEM_VERSION = '2.0.2' unless defined? RAILS_GEM_VERSION
|
9
|
+
|
10
|
+
# Bootstrap the Rails environment, frameworks, and default configuration
|
11
|
+
require File.join(File.dirname(__FILE__), 'boot')
|
12
|
+
|
13
|
+
Rails::Initializer.run do |config|
|
14
|
+
# Settings in config/environments/* take precedence over those specified here.
|
15
|
+
# Application configuration should go into files in config/initializers
|
16
|
+
# -- all .rb files in that directory are automatically loaded.
|
17
|
+
# See Rails::Configuration for more options.
|
18
|
+
|
19
|
+
# Skip frameworks you're not going to use (only works if using vendor/rails).
|
20
|
+
# To use Rails without a database, you must remove the Active Record framework
|
21
|
+
# config.frameworks -= [ :active_record, :active_resource, :action_mailer ]
|
22
|
+
|
23
|
+
# Only load the plugins named here, in the order given. By default, all plugins
|
24
|
+
# in vendor/plugins are loaded in alphabetical order.
|
25
|
+
# :all can be used as a placeholder for all plugins not explicitly named
|
26
|
+
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
|
27
|
+
|
28
|
+
# Add additional load paths for your own custom dirs
|
29
|
+
# config.load_paths += %W( #{RAILS_ROOT}/extras )
|
30
|
+
|
31
|
+
# Force all environments to use the same logger level
|
32
|
+
# (by default production uses :info, the others :debug)
|
33
|
+
# config.log_level = :debug
|
34
|
+
|
35
|
+
# Your secret key for verifying cookie session data integrity.
|
36
|
+
# If you change this key, all old sessions will become invalid!
|
37
|
+
# Make sure the secret is at least 30 characters and all random,
|
38
|
+
# no regular words or you'll be exposed to dictionary attacks.
|
39
|
+
config.action_controller.session = {
|
40
|
+
:session_key => '_photoviewer_session',
|
41
|
+
:secret => '9c6881cf49e9202ab207847db426d3a48ee723946ed270b8697de048cb511e365616f414ebb6cc8dc4f89d39aed9d861dbd5482670a26b616437801079ab78fe'
|
42
|
+
}
|
43
|
+
|
44
|
+
# Use the database for sessions instead of the cookie-based default,
|
45
|
+
# which shouldn't be used to store highly confidential information
|
46
|
+
# (create the session table with 'rake db:sessions:create')
|
47
|
+
# config.action_controller.session_store = :active_record_store
|
48
|
+
|
49
|
+
# Use SQL instead of Active Record's schema dumper when creating the test database.
|
50
|
+
# This is necessary if your schema can't be completely dumped by the schema dumper,
|
51
|
+
# like if you have constraints or database-specific column types
|
52
|
+
# config.active_record.schema_format = :sql
|
53
|
+
|
54
|
+
# Activate observers that should always be running
|
55
|
+
# config.active_record.observers = :cacher, :garbage_collector
|
56
|
+
|
57
|
+
# Make Active Record use UTC-base instead of local time
|
58
|
+
# config.active_record.default_timezone = :utc
|
59
|
+
end
|
60
|
+
require 'rmobio/client_info'
|
61
|
+
require 'rmobio/utils'
|
62
|
+
require 'rmobio/config_manager'
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# Settings specified here will take precedence over those in config/environment.rb
|
2
|
+
|
3
|
+
# In the development environment your application's code is reloaded on
|
4
|
+
# every request. This slows down response time but is perfect for development
|
5
|
+
# since you don't have to restart the webserver when you make code changes.
|
6
|
+
config.cache_classes = false
|
7
|
+
|
8
|
+
# Log error messages when you accidentally call methods on nil.
|
9
|
+
config.whiny_nils = true
|
10
|
+
|
11
|
+
# Show full error reports and disable caching
|
12
|
+
config.action_controller.consider_all_requests_local = true
|
13
|
+
config.action_view.debug_rjs = true
|
14
|
+
config.action_controller.perform_caching = false
|
15
|
+
config.action_view.cache_template_extensions = false
|
16
|
+
|
17
|
+
# Don't care if the mailer can't send
|
18
|
+
config.action_mailer.raise_delivery_errors = false
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# Settings specified here will take precedence over those in config/environment.rb
|
2
|
+
|
3
|
+
# The production environment is meant for finished, "live" apps.
|
4
|
+
# Code is not reloaded between requests
|
5
|
+
config.cache_classes = true
|
6
|
+
|
7
|
+
# Use a different logger for distributed setups
|
8
|
+
# config.logger = SyslogLogger.new
|
9
|
+
|
10
|
+
# Full error reports are disabled and caching is turned on
|
11
|
+
config.action_controller.consider_all_requests_local = false
|
12
|
+
config.action_controller.perform_caching = true
|
13
|
+
config.action_view.cache_template_loading = true
|
14
|
+
|
15
|
+
# Enable serving of images, stylesheets, and javascripts from an asset server
|
16
|
+
# config.action_controller.asset_host = "http://assets.example.com"
|
17
|
+
|
18
|
+
# Disable delivery errors, bad email addresses will be ignored
|
19
|
+
# config.action_mailer.raise_delivery_errors = false
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# Settings specified here will take precedence over those in config/environment.rb
|
2
|
+
|
3
|
+
# The test environment is used exclusively to run your application's
|
4
|
+
# test suite. You never need to work with it otherwise. Remember that
|
5
|
+
# your test database is "scratch space" for the test suite and is wiped
|
6
|
+
# and recreated between test runs. Don't rely on the data there!
|
7
|
+
config.cache_classes = true
|
8
|
+
|
9
|
+
# Log error messages when you accidentally call methods on nil.
|
10
|
+
config.whiny_nils = true
|
11
|
+
|
12
|
+
# Show full error reports and disable caching
|
13
|
+
config.action_controller.consider_all_requests_local = true
|
14
|
+
config.action_controller.perform_caching = false
|
15
|
+
|
16
|
+
# Disable request forgery protection in test environment
|
17
|
+
config.action_controller.allow_forgery_protection = false
|
18
|
+
|
19
|
+
# Tell ActionMailer not to deliver emails to the real world.
|
20
|
+
# The :test delivery method accumulates sent emails in the
|
21
|
+
# ActionMailer::Base.deliveries array.
|
22
|
+
config.action_mailer.delivery_method = :test
|
@@ -0,0 +1,10 @@
|
|
1
|
+
# Be sure to restart your server when you modify this file.
|
2
|
+
|
3
|
+
# Add new inflection rules using the following format
|
4
|
+
# (all these examples are active by default):
|
5
|
+
# Inflector.inflections do |inflect|
|
6
|
+
# inflect.plural /^(ox)$/i, '\1en'
|
7
|
+
# inflect.singular /^(ox)en/i, '\1'
|
8
|
+
# inflect.irregular 'person', 'people'
|
9
|
+
# inflect.uncountable %w( fish sheep )
|
10
|
+
# end
|
data/config/rmobio.yml
ADDED
@@ -0,0 +1,10 @@
|
|
1
|
+
|
2
|
+
development:
|
3
|
+
adserver_url: http://marge.mobiolabs.com/adserver/delivery/fetch_ad.xml
|
4
|
+
|
5
|
+
test:
|
6
|
+
adserver_url: http://marge.mobiolabs.com/adserver/delivery/fetch_ad.xml
|
7
|
+
|
8
|
+
production:
|
9
|
+
adserver_url: http://marge.mobiolabs.com/adserver/delivery/fetch_ad.xml
|
10
|
+
|
data/config/routes.rb
ADDED
@@ -0,0 +1,37 @@
|
|
1
|
+
ActionController::Routing::Routes.draw do |map|
|
2
|
+
map.resources :lists
|
3
|
+
|
4
|
+
# The priority is based upon order of creation: first created -> highest priority.
|
5
|
+
|
6
|
+
# Sample of regular route:
|
7
|
+
# map.connect 'products/:id', :controller => 'catalog', :action => 'view'
|
8
|
+
# Keep in mind you can assign values other than :controller and :action
|
9
|
+
|
10
|
+
# Sample of named route:
|
11
|
+
# map.purchase 'products/:id/purchase', :controller => 'catalog', :action => 'purchase'
|
12
|
+
# This route can be invoked with purchase_url(:id => product.id)
|
13
|
+
|
14
|
+
# Sample resource route (maps HTTP verbs to controller actions automatically):
|
15
|
+
# map.resources :products
|
16
|
+
|
17
|
+
# Sample resource route with options:
|
18
|
+
# map.resources :products, :member => { :short => :get, :toggle => :post }, :collection => { :sold => :get }
|
19
|
+
|
20
|
+
# Sample resource route with sub-resources:
|
21
|
+
# map.resources :products, :has_many => [ :comments, :sales ], :has_one => :seller
|
22
|
+
|
23
|
+
# Sample resource route within a namespace:
|
24
|
+
# map.namespace :admin do |admin|
|
25
|
+
# # Directs /admin/products/* to Admin::ProductsController (app/controllers/admin/products_controller.rb)
|
26
|
+
# admin.resources :products
|
27
|
+
# end
|
28
|
+
|
29
|
+
# You can have the root of your site routed with map.root -- just remember to delete public/index.html.
|
30
|
+
# map.root :controller => "welcome"
|
31
|
+
|
32
|
+
# See how all your routes lay out with "rake routes"
|
33
|
+
|
34
|
+
# Install the default routes as the lowest priority.
|
35
|
+
map.connect ':controller/:action/:id'
|
36
|
+
map.connect ':controller/:action/:id.:format'
|
37
|
+
end
|