ruboss4ruby 1.0.5 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +2 -2
- data/Manifest.txt +86 -79
- data/README.rdoc +53 -0
- data/Rakefile +42 -5
- data/app_generators/ruboss_app/USAGE +22 -0
- data/app_generators/ruboss_app/ruboss_app_generator.rb +94 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/actionscript.properties +1 -1
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/actionscriptair.properties +0 -0
- data/app_generators/ruboss_app/templates/app.yaml.erb +12 -0
- data/app_generators/ruboss_app/templates/default_tasks.rake +51 -0
- data/app_generators/ruboss_app/templates/empty.txt +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/expressInstall.swf +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/flex.properties +0 -0
- data/app_generators/ruboss_app/templates/generate.rb +17 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/html-template/AC_OETags.js +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/html-template/history/history.css +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/html-template/history/history.js +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/html-template/history/historyFrame.html +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/html-template/index.template.html +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/html-template/playerProductInstall.swf +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/index.html.erb +2 -2
- data/app_generators/ruboss_app/templates/index.yaml +11 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/mainair-app.xml +3 -3
- data/app_generators/ruboss_app/templates/mainapp-config.xml +21 -0
- data/{merb_generators/templates/ruboss_flex_app → app_generators/ruboss_app/templates}/mainapp.mxml +6 -9
- data/app_generators/ruboss_app/templates/project-textmate.erb +52 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/project.properties +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/projectair.properties +0 -0
- data/{merb_generators/templates/ruboss_config → app_generators/ruboss_app/templates}/swfobject.js +0 -0
- data/bin/ruboss-gen +31 -0
- data/generators/ruboss_config/USAGE +5 -0
- data/generators/ruboss_config/ruboss_config_generator.rb +19 -0
- data/generators/ruboss_controller/USAGE +10 -0
- data/generators/ruboss_controller/ruboss_controller_generator.rb +38 -0
- data/generators/ruboss_controller/templates/assist.py +65 -0
- data/{merb_generators/templates/ruboss_controller → generators/ruboss_controller/templates}/controller.as.erb +7 -6
- data/generators/ruboss_controller/templates/restful.py +136 -0
- data/generators/ruboss_main_app/USAGE +8 -0
- data/generators/ruboss_main_app/ruboss_main_app_generator.rb +60 -0
- data/generators/ruboss_main_app/templates/main.py.erb +29 -0
- data/generators/ruboss_main_app/templates/mainapp.mxml +35 -0
- data/generators/ruboss_scaffold/USAGE +29 -0
- data/generators/ruboss_scaffold/ruboss_scaffold_generator.rb +148 -0
- data/generators/ruboss_scaffold/templates/component.mxml.erb +149 -0
- data/generators/ruboss_scaffold/templates/controller.py.erb +27 -0
- data/generators/ruboss_scaffold/templates/model.as.erb +42 -0
- data/generators/ruboss_scaffold/templates/model.py.erb +14 -0
- data/generators/ruboss_yaml_scaffold/USAGE +45 -0
- data/generators/ruboss_yaml_scaffold/ruboss_yaml_scaffold_generator.rb +47 -0
- data/lib/ruboss4ruby/active_foo.rb +109 -86
- data/lib/ruboss4ruby/active_record_default_methods.rb +66 -0
- data/lib/ruboss4ruby/active_record_tasks.rb +10 -4
- data/lib/ruboss4ruby/configuration.rb +48 -34
- data/lib/ruboss4ruby/datamapper_foo.rb +31 -0
- data/lib/ruboss4ruby/{recipes.rb → rails/recipes.rb} +7 -9
- data/lib/ruboss4ruby/{ruboss_helper.rb → rails/swf_helper.rb} +14 -8
- data/lib/ruboss4ruby/tasks.rb +9 -4
- data/lib/ruboss4ruby.rb +72 -27
- data/rails_generators/ruboss_config/ruboss_config_generator.rb +3 -15
- data/rails_generators/ruboss_config/templates/mainair-app.xml +2 -2
- data/rails_generators/ruboss_config/templates/mainapp-config.xml +1 -1
- data/rails_generators/ruboss_config/templates/ruboss.yml +2 -4
- data/rails_generators/ruboss_config/templates/ruboss_tasks.rake +5 -15
- data/rails_generators/ruboss_controller/USAGE +1 -2
- data/rails_generators/ruboss_controller/ruboss_controller_generator.rb +3 -14
- data/rails_generators/ruboss_controller/templates/controller.as.erb +11 -6
- data/rails_generators/ruboss_scaffold/ruboss_scaffold_generator.rb +67 -76
- data/rails_generators/ruboss_scaffold/templates/component.mxml.erb +69 -69
- data/rails_generators/ruboss_scaffold/templates/model.as.erb +2 -2
- data/rails_generators/ruboss_yaml_scaffold/USAGE +38 -1
- data/rcl-1.0.txt +0 -0
- data/rdoc/generators/template/html/jamis.rb +588 -0
- data/ruboss4ruby.gemspec +43 -0
- data/spec/ruboss4ruby_spec.rb +7 -0
- data/spec/spec_helper.rb +16 -0
- data/tasks/ann.rake +80 -0
- data/tasks/bones.rake +20 -0
- data/tasks/gem.rake +201 -0
- data/tasks/git.rake +40 -0
- data/tasks/manifest.rake +48 -0
- data/tasks/notes.rake +27 -0
- data/tasks/post_load.rake +39 -0
- data/tasks/rdoc.rake +50 -0
- data/tasks/rubyforge.rake +55 -0
- data/tasks/setup.rb +279 -0
- data/tasks/spec.rake +54 -0
- data/tasks/svn.rake +47 -0
- data/tasks/test.rake +40 -0
- data/test/{controllers → rails/controllers}/application.rb +0 -0
- data/test/{controllers → rails/controllers}/locations_controller.rb +0 -0
- data/test/{controllers → rails/controllers}/notes_controller.rb +0 -0
- data/test/{controllers → rails/controllers}/projects_controller.rb +0 -0
- data/test/{controllers → rails/controllers}/tasks_controller.rb +0 -0
- data/test/{controllers → rails/controllers}/users_controller.rb +0 -0
- data/test/{database.yml → rails/database.yml} +0 -0
- data/test/{fixtures → rails/fixtures}/locations.yml +0 -0
- data/test/{fixtures → rails/fixtures}/notes.yml +0 -0
- data/test/{fixtures → rails/fixtures}/projects.yml +0 -0
- data/test/rails/fixtures/simple_properties.yml +19 -0
- data/test/{fixtures → rails/fixtures}/tasks.yml +0 -0
- data/test/{fixtures → rails/fixtures}/users.yml +0 -0
- data/test/{helpers → rails/helpers}/functional_test_helper.rb +0 -11
- data/test/rails/helpers/test_helper.rb +61 -0
- data/test/rails/helpers/unit_test_helper.rb +30 -0
- data/test/{model.yml → rails/model.yml} +0 -0
- data/test/{models → rails/models}/location.rb +0 -0
- data/test/{models → rails/models}/note.rb +0 -0
- data/test/{models → rails/models}/project.rb +1 -3
- data/test/rails/models/simple_property.rb +2 -0
- data/test/{models → rails/models}/task.rb +1 -1
- data/test/{models → rails/models}/user.rb +1 -2
- data/test/{playing_around_in_a_console.txt → rails/playing_around_in_a_console.txt} +0 -0
- data/test/{schema.rb → rails/schema.rb} +14 -0
- data/test/{test.swf → rails/test.swf} +0 -0
- data/test/rails/test_active_foo.rb +81 -0
- data/test/{test_ruboss_rails_integration_functional.rb → rails/test_ruboss_rails_integration_functional.rb} +4 -9
- data/test/{to_fxml_test.rb → rails/test_to_fxml.rb} +35 -37
- data/test/rails/test_to_json.rb +23 -0
- data/test/{views → rails/views}/notes/empty_params_action.html.erb +0 -0
- data/test/{views → rails/views}/notes/index.html.erb +0 -0
- metadata +138 -103
- data/Generators +0 -5
- data/README.txt +0 -37
- data/config/hoe.rb +0 -72
- data/config/requirements.rb +0 -15
- data/lib/ruboss4ruby/generated_attribute.rb +0 -61
- data/lib/ruboss4ruby/ruboss_test_helpers.rb +0 -31
- data/lib/ruboss4ruby/version.rb +0 -11
- data/merb_generators/ruboss_config.rb +0 -105
- data/merb_generators/ruboss_controller.rb +0 -61
- data/merb_generators/ruboss_flex_app.rb +0 -69
- data/merb_generators/ruboss_resource_controller.rb +0 -4
- data/merb_generators/ruboss_scaffold.rb +0 -158
- data/merb_generators/templates/ruboss_config/ruboss.yml +0 -16
- data/merb_generators/templates/ruboss_resource_controller/controller.rb.erb +0 -49
- data/script/console +0 -10
- data/script/destroy +0 -14
- data/script/generate +0 -14
- data/script/txt2html +0 -82
- data/setup.rb +0 -1585
- data/tasks/deployment.rake +0 -34
- data/tasks/environment.rake +0 -7
- data/tasks/website.rake +0 -17
- data/test/helpers/controllers.log +0 -8
- data/test/helpers/models.log +0 -170
- data/test/helpers/test_helper.rb +0 -25
- data/test/helpers/unit_test_helper.rb +0 -23
- data/test/test.sqlite3 +0 -0
- data/test/test_active_foo.rb +0 -79
- data/test/test_swfobject_helper.rb +0 -63
- data/website/index.html +0 -63
- data/website/index.txt +0 -34
- data/website/javascripts/rounded_corners_lite.inc.js +0 -285
- data/website/stylesheets/screen.css +0 -138
- data/website/template.html.erb +0 -47
@@ -1,106 +1,106 @@
|
|
1
1
|
<?xml version="1.0" encoding="utf-8"?>
|
2
2
|
<mx:HBox xmlns:mx="http://www.adobe.com/2006/mxml" width="100%" label="<%= class_name %>"
|
3
3
|
xmlns:rcomponents="org.ruboss.components.*">
|
4
|
-
<mx:Script><![CDATA[
|
5
|
-
|
6
|
-
|
7
|
-
|
4
|
+
<mx:Script><![CDATA[
|
5
|
+
import org.ruboss.Ruboss;
|
6
|
+
import org.ruboss.utils.RubossUtils;
|
7
|
+
import <%= base_package %>.models.<%= class_name %>;
|
8
8
|
<% for model in belongs_tos -%>
|
9
|
-
|
9
|
+
import <%= base_package %>.models.<%= model.camelcase %>;
|
10
10
|
<% end -%>
|
11
11
|
|
12
|
-
|
13
|
-
|
12
|
+
[Bindable]
|
13
|
+
private var _<%= class_name.dcfirst %>:<%= class_name %> = new <%= class_name %>();
|
14
14
|
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
15
|
+
private function new<%= class_name %>():void {
|
16
|
+
_<%= class_name.dcfirst %> = new <%= class_name %>();
|
17
|
+
<%= class_name.dcfirst.pluralize %>List.selectedIndex = -1;
|
18
|
+
}
|
19
19
|
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
20
|
+
private function save<%= class_name %>():void {
|
21
|
+
if (_<%= class_name.dcfirst %>.id) {
|
22
|
+
update<%= class_name %>();
|
23
|
+
} else {
|
24
|
+
create<%= class_name %>();
|
25
|
+
}
|
25
26
|
}
|
26
|
-
}
|
27
27
|
|
28
|
-
|
29
|
-
|
28
|
+
private function create<%= class_name %>():void {
|
29
|
+
var <%= class_name.dcfirst %>:<%= class_name %> = new <%= class_name %>();
|
30
30
|
<% for attribute in attributes -%>
|
31
31
|
<% if attribute.type == :boolean -%>
|
32
|
-
|
32
|
+
<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>CheckBox.selected;
|
33
33
|
<% elsif attribute.type == :string -%>
|
34
|
-
|
34
|
+
<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>TextInput.text;
|
35
35
|
<% elsif attribute.type == :text -%>
|
36
|
-
|
36
|
+
<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>TextArea.text;
|
37
37
|
<% elsif attribute.type == :datetime || attribute.type == :time -%>
|
38
|
-
|
38
|
+
<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>DateTimeTextInput.date;
|
39
39
|
<% elsif attribute.type == :date -%>
|
40
|
-
|
40
|
+
<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>DateField.selectedDate;
|
41
41
|
<% else -%>
|
42
|
-
|
42
|
+
<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_type %>(<%= attribute.flex_name %>TextInput.text);
|
43
43
|
<% end -%>
|
44
44
|
<% end -%>
|
45
45
|
|
46
46
|
<% for model in belongs_tos -%>
|
47
|
-
|
47
|
+
<%= class_name.dcfirst %>.<%= model.camelcase(:lower) %> = <%= model.camelcase %>(<%= model.camelcase(:lower) %>ComboBox.selectedItem);
|
48
48
|
<% end -%>
|
49
|
-
|
50
|
-
|
49
|
+
<%= class_name.dcfirst %>.create({onSuccess: on<%= class_name %>Create});
|
50
|
+
}
|
51
51
|
|
52
|
-
|
52
|
+
private function update<%= class_name %>():void {
|
53
53
|
<% for attribute in attributes -%>
|
54
54
|
<% if attribute.type == :boolean -%>
|
55
|
-
|
55
|
+
_<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>CheckBox.selected;
|
56
56
|
<% elsif attribute.type == :string -%>
|
57
|
-
|
57
|
+
_<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>TextInput.text;
|
58
58
|
<% elsif attribute.type == :text -%>
|
59
|
-
|
59
|
+
_<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>TextArea.text;
|
60
60
|
<% elsif attribute.type == :datetime || attribute.type == :time -%>
|
61
|
-
|
61
|
+
_<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>DateTimeTextInput.date;
|
62
62
|
<% elsif attribute.type == :date -%>
|
63
|
-
|
63
|
+
_<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_name %>DateField.selectedDate;
|
64
64
|
<% else -%>
|
65
|
-
|
65
|
+
_<%= class_name.dcfirst %>.<%= attribute.flex_name %> = <%= attribute.flex_type %>(<%= attribute.flex_name %>TextInput.text);
|
66
66
|
<% end -%>
|
67
67
|
<% end -%>
|
68
68
|
|
69
69
|
<% for model in belongs_tos -%>
|
70
|
-
|
70
|
+
_<%= class_name.dcfirst %>.<%= model.camelcase(:lower) %> = <%= model.camelcase %>(<%= model.camelcase(:lower) %>ComboBox.selectedItem);
|
71
71
|
<% end -%>
|
72
|
-
|
73
|
-
|
72
|
+
_<%= class_name.dcfirst %>.update({onSuccess: on<%= class_name %>Update});
|
73
|
+
}
|
74
74
|
|
75
|
-
|
76
|
-
|
77
|
-
|
75
|
+
private function destroy<%= class_name %>():void {
|
76
|
+
_<%= class_name.dcfirst %>.destroy({onSuccess: on<%= class_name %>Destroy});
|
77
|
+
}
|
78
78
|
|
79
|
-
|
80
|
-
|
81
|
-
|
79
|
+
private function on<%= class_name %>Select():void {
|
80
|
+
_<%= class_name.dcfirst %> = RubossUtils.clone(<%= class_name.dcfirst.pluralize %>List.selectedItem) as <%= class_name %>;
|
81
|
+
}
|
82
82
|
|
83
|
-
|
84
|
-
|
85
|
-
|
83
|
+
private function on<%= class_name %>Create(<%= class_name.dcfirst %>:<%= class_name %>):void {
|
84
|
+
_<%= class_name.dcfirst %> = new <%= class_name %>;
|
85
|
+
}
|
86
86
|
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
87
|
+
private function on<%= class_name %>Update(<%= class_name.dcfirst %>:<%= class_name %>):void {
|
88
|
+
<%= class_name.dcfirst.pluralize %>List.selectedItem = <%= class_name.dcfirst %>;
|
89
|
+
_<%= class_name.dcfirst %> = RubossUtils.clone(<%= class_name.dcfirst %>) as <%= class_name %>;
|
90
|
+
}
|
91
91
|
|
92
|
-
|
93
|
-
|
94
|
-
|
92
|
+
private function on<%= class_name %>Destroy(<%= class_name.dcfirst %>:<%= class_name %>):void {
|
93
|
+
on<%= class_name %>Create(<%= class_name.dcfirst %>);
|
94
|
+
}
|
95
95
|
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
]]></mx:Script>
|
100
|
-
<mx:Panel id="<%= class_name.
|
96
|
+
private function canDelete<%= class_name %>(<%= class_name.dcfirst %>:<%= class_name %>):Boolean {
|
97
|
+
return <%= class_name.dcfirst %> != null && !RubossUtils.isEmpty(<%= class_name.dcfirst %>.id);
|
98
|
+
}
|
99
|
+
]]></mx:Script>
|
100
|
+
<mx:Panel id="<%= class_name.dcfirst.pluralize %>Panel"
|
101
101
|
title="<%= class_name.pluralize %>" cornerRadius="0" dropShadowEnabled="false" borderStyle="solid"
|
102
102
|
borderThickness="1" backgroundColor="#EEEEEE" width="25%" height="100%">
|
103
|
-
<mx:List id="<%= class_name.
|
103
|
+
<mx:List id="<%= class_name.dcfirst.pluralize %>List"
|
104
104
|
width="100%" height="100%"
|
105
105
|
dataProvider="{Ruboss.models.index(<%= class_name %>)}"
|
106
106
|
change="on<%= class_name %>Select()"/>
|
@@ -113,19 +113,19 @@
|
|
113
113
|
borderThickness="1" backgroundColor="#EEEEEE" width="75%" height="100%">
|
114
114
|
<mx:Form width="100%" height="100%">
|
115
115
|
<% for attribute in attributes -%>
|
116
|
-
<mx:FormItem label="<%= attribute.flex_name.
|
116
|
+
<mx:FormItem label="<%= attribute.flex_name.ucfirst %>" width="100%">
|
117
117
|
<% if attribute.type == :boolean -%>
|
118
|
-
<mx:CheckBox id="<%= attribute.flex_name %>CheckBox" selected="{_<%= class_name.
|
118
|
+
<mx:CheckBox id="<%= attribute.flex_name %>CheckBox" selected="{_<%= class_name.dcfirst %>.<%= attribute.flex_name %>}"/>
|
119
119
|
<% elsif attribute.type == :string -%>
|
120
|
-
<mx:TextInput id="<%= attribute.flex_name %>TextInput" width="100%" text="{_<%= class_name.
|
120
|
+
<mx:TextInput id="<%= attribute.flex_name %>TextInput" width="100%" text="{_<%= class_name.dcfirst %>.<%= attribute.flex_name %>}"/>
|
121
121
|
<% elsif attribute.type == :text -%>
|
122
|
-
<mx:TextArea id="<%= attribute.flex_name %>TextArea" width="100%" height="200" text="{_<%= class_name.
|
122
|
+
<mx:TextArea id="<%= attribute.flex_name %>TextArea" width="100%" height="200" text="{_<%= class_name.dcfirst %>.<%= attribute.flex_name %>}"/>
|
123
123
|
<% elsif attribute.type == :datetime || attribute.type == :time -%>
|
124
|
-
<rcomponents:DateTimeTextInput id="<%= attribute.flex_name %>DateTimeTextInput" width="200" date="{_<%= class_name.
|
124
|
+
<rcomponents:DateTimeTextInput id="<%= attribute.flex_name %>DateTimeTextInput" width="200" date="{_<%= class_name.dcfirst %>.<%= attribute.flex_name %>}"/>
|
125
125
|
<% elsif attribute.type == :date -%>
|
126
|
-
<mx:DateField id="<%= attribute.flex_name %>DateField" selectedDate="{_<%= class_name.
|
126
|
+
<mx:DateField id="<%= attribute.flex_name %>DateField" selectedDate="{_<%= class_name.dcfirst %>.<%= attribute.flex_name %>}"/>
|
127
127
|
<% else -%>
|
128
|
-
<mx:TextInput id="<%= attribute.flex_name %>TextInput" width="100%" text="{_<%= class_name.
|
128
|
+
<mx:TextInput id="<%= attribute.flex_name %>TextInput" width="100%" text="{_<%= class_name.dcfirst %>.<%= attribute.flex_name %>}"/>
|
129
129
|
<% end -%>
|
130
130
|
</mx:FormItem>
|
131
131
|
<% end -%>
|
@@ -134,7 +134,7 @@
|
|
134
134
|
<mx:ComboBox id="<%= model.camelcase(:lower) %>ComboBox" width="200"
|
135
135
|
labelField="{<%= model.camelcase %>.LABEL}"
|
136
136
|
dataProvider="{Ruboss.models.index(<%= model.camelcase %>)}" prompt="<%= model.camelcase %> ..."
|
137
|
-
selectedItem="{_<%= class_name.
|
137
|
+
selectedItem="{_<%= class_name.dcfirst %>.<%= model.camelcase(:lower) %>}" />
|
138
138
|
</mx:FormItem>
|
139
139
|
<% end -%>
|
140
140
|
</mx:Form>
|
@@ -142,7 +142,7 @@
|
|
142
142
|
<mx:Button label="Save <%= class_name %>" width="50%" height="30"
|
143
143
|
click="save<%= class_name %>()"/>
|
144
144
|
<mx:Button label="Delete <%= class_name %>" width="50%" height="30"
|
145
|
-
enabled="{canDelete<%= class_name %>(_<%= class_name.
|
145
|
+
enabled="{canDelete<%= class_name %>(_<%= class_name.dcfirst %>)}"
|
146
146
|
click="destroy<%= class_name %>()"/>
|
147
147
|
</mx:ControlBar>
|
148
148
|
</mx:Panel>
|
@@ -1,6 +1,6 @@
|
|
1
1
|
package <%= base_package %>.models {
|
2
2
|
<% if has_manies.length > 0 -%>
|
3
|
-
import org.ruboss.
|
3
|
+
import org.ruboss.collections.ModelsCollection;
|
4
4
|
<% end -%>
|
5
5
|
import org.ruboss.models.RubossModel;
|
6
6
|
|
@@ -17,7 +17,7 @@ package <%= base_package %>.models {
|
|
17
17
|
<% if attribute.type == :datetime || attribute.type == :time -%>
|
18
18
|
[DateTime]
|
19
19
|
<% end -%>
|
20
|
-
public var <%= attribute.flex_name %>:<%= attribute.flex_type %>;
|
20
|
+
public var <%= attribute.flex_name %>:<%= attribute.flex_type %> = <%= attribute.flex_default %>;
|
21
21
|
|
22
22
|
<% end -%>
|
23
23
|
<% for model in belongs_tos -%>
|
@@ -11,4 +11,41 @@ Description:
|
|
11
11
|
editing.
|
12
12
|
|
13
13
|
Examples:
|
14
|
-
`./script/generate ruboss_yaml_scaffold`
|
14
|
+
`./script/generate ruboss_yaml_scaffold`
|
15
|
+
|
16
|
+
Sample Model File:
|
17
|
+
project:
|
18
|
+
- name: string
|
19
|
+
- notes: text
|
20
|
+
- start_date: date
|
21
|
+
- end_date: date
|
22
|
+
- completed: boolean
|
23
|
+
- belongs_to: [user]
|
24
|
+
- has_many: [tasks]
|
25
|
+
|
26
|
+
location:
|
27
|
+
- name: string
|
28
|
+
- notes: text
|
29
|
+
- belongs_to: [user]
|
30
|
+
- has_many: [tasks]
|
31
|
+
|
32
|
+
task:
|
33
|
+
- name: string
|
34
|
+
- notes: text
|
35
|
+
- start_time: datetime
|
36
|
+
- end_time: datetime
|
37
|
+
- completed: boolean
|
38
|
+
- next_action: boolean
|
39
|
+
- belongs_to: [project, location, user]
|
40
|
+
|
41
|
+
note:
|
42
|
+
- content: text
|
43
|
+
- belongs_to: [user]
|
44
|
+
|
45
|
+
user:
|
46
|
+
- login: string
|
47
|
+
- first_name: string
|
48
|
+
- last_name: string
|
49
|
+
- email: string
|
50
|
+
- has_many: [tasks, projects, locations]
|
51
|
+
- has_one: [note]
|
data/rcl-1.0.txt
CHANGED
Binary file
|