lolita-report 0.0.2
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/.document +5 -0
- data/Gemfile +18 -0
- data/LICENSE.txt +20 -0
- data/README.rdoc +19 -0
- data/Rakefile +45 -0
- data/VERSION +1 -0
- data/app/controllers/lolita/reports_controller.rb +18 -0
- data/app/views/components/lolita/configuration/report/_display.html.erb +1 -0
- data/app/views/lolita/reports/show.html.erb +9 -0
- data/author +1 -0
- data/doc/ActiveSupport.html +167 -0
- data/doc/ActiveSupport/TestCase.html +168 -0
- data/doc/Comment.html +184 -0
- data/doc/Gemfile.html +157 -0
- data/doc/LICENSE.html +111 -0
- data/doc/Lolita.html +184 -0
- data/doc/Lolita/Configuration.html +178 -0
- data/doc/Lolita/Configuration/Report.html +837 -0
- data/doc/Lolita/Configuration/Reports.html +413 -0
- data/doc/LolitaReport.html +194 -0
- data/doc/LolitaReport/Configuration.html +250 -0
- data/doc/Post.html +183 -0
- data/doc/Rakefile.html +124 -0
- data/doc/author.html +111 -0
- data/doc/created.rid +15 -0
- data/doc/images/brick.png +0 -0
- data/doc/images/brick_link.png +0 -0
- data/doc/images/bug.png +0 -0
- data/doc/images/bullet_black.png +0 -0
- data/doc/images/bullet_toggle_minus.png +0 -0
- data/doc/images/bullet_toggle_plus.png +0 -0
- data/doc/images/date.png +0 -0
- data/doc/images/find.png +0 -0
- data/doc/images/loadingAnimation.gif +0 -0
- data/doc/images/macFFBgHack.png +0 -0
- data/doc/images/package.png +0 -0
- data/doc/images/page_green.png +0 -0
- data/doc/images/page_white_text.png +0 -0
- data/doc/images/page_white_width.png +0 -0
- data/doc/images/plugin.png +0 -0
- data/doc/images/ruby.png +0 -0
- data/doc/images/tag_green.png +0 -0
- data/doc/images/wrench.png +0 -0
- data/doc/images/wrench_orange.png +0 -0
- data/doc/images/zoom.png +0 -0
- data/doc/index.html +126 -0
- data/doc/js/darkfish.js +116 -0
- data/doc/js/jquery.js +32 -0
- data/doc/js/quicksearch.js +114 -0
- data/doc/js/thickbox-compressed.js +10 -0
- data/doc/lib/lolita-report/configuration/base_rb.html +61 -0
- data/doc/lib/lolita-report/configuration/report_rb.html +57 -0
- data/doc/lib/lolita-report/configuration/reports_rb.html +55 -0
- data/doc/lib/lolita-report/version_rb.html +52 -0
- data/doc/lib/lolita-report_rb.html +58 -0
- data/doc/rdoc.css +706 -0
- data/doc/spec/configuration/report_spec_rb.html +56 -0
- data/doc/spec/configuration/reports_spec_rb.html +56 -0
- data/doc/spec/factories/factories_rb.html +52 -0
- data/doc/spec/orm/mongoid_rb.html +56 -0
- data/doc/spec/spec_helper_rb.html +58 -0
- data/lib/lolita-report.rb +33 -0
- data/lib/lolita-report/configuration/base.rb +22 -0
- data/lib/lolita-report/configuration/report.rb +147 -0
- data/lib/lolita-report/configuration/reports.rb +42 -0
- data/lib/lolita-report/module.rb +1 -0
- data/lib/lolita-report/rails.rb +6 -0
- data/lib/lolita-report/routes.rb +15 -0
- data/lolita-report.gemspec +150 -0
- data/spec/configuration/report_spec.rb +87 -0
- data/spec/configuration/reports_spec.rb +40 -0
- data/spec/factories/factories.rb +7 -0
- data/spec/orm/mongoid.rb +27 -0
- data/spec/spec_helper.rb +38 -0
- metadata +259 -0
data/doc/Lolita.html
ADDED
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
|
3
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
4
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
5
|
+
<head>
|
|
6
|
+
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
|
|
7
|
+
|
|
8
|
+
<title>Module: Lolita</title>
|
|
9
|
+
|
|
10
|
+
<link rel="stylesheet" href="./rdoc.css" type="text/css" media="screen" />
|
|
11
|
+
|
|
12
|
+
<script src="./js/jquery.js" type="text/javascript"
|
|
13
|
+
charset="utf-8"></script>
|
|
14
|
+
<script src="./js/thickbox-compressed.js" type="text/javascript"
|
|
15
|
+
charset="utf-8"></script>
|
|
16
|
+
<script src="./js/quicksearch.js" type="text/javascript"
|
|
17
|
+
charset="utf-8"></script>
|
|
18
|
+
<script src="./js/darkfish.js" type="text/javascript"
|
|
19
|
+
charset="utf-8"></script>
|
|
20
|
+
|
|
21
|
+
</head>
|
|
22
|
+
<body class="module">
|
|
23
|
+
|
|
24
|
+
<div id="metadata">
|
|
25
|
+
<div id="home-metadata">
|
|
26
|
+
<div id="home-section" class="section">
|
|
27
|
+
<h3 class="section-header">
|
|
28
|
+
<a href="./index.html">Home</a>
|
|
29
|
+
<a href="./index.html#classes">Classes</a>
|
|
30
|
+
<a href="./index.html#methods">Methods</a>
|
|
31
|
+
</h3>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
|
|
35
|
+
<div id="file-metadata">
|
|
36
|
+
<div id="file-list-section" class="section">
|
|
37
|
+
<h3 class="section-header">In Files</h3>
|
|
38
|
+
<div class="section-body">
|
|
39
|
+
<ul>
|
|
40
|
+
|
|
41
|
+
<li><a href="./lib/lolita-report/configuration/report_rb.html?TB_iframe=true&height=550&width=785"
|
|
42
|
+
class="thickbox" title="lib/lolita-report/configuration/report.rb">lib/lolita-report/configuration/report.rb</a></li>
|
|
43
|
+
|
|
44
|
+
<li><a href="./lib/lolita-report/configuration/reports_rb.html?TB_iframe=true&height=550&width=785"
|
|
45
|
+
class="thickbox" title="lib/lolita-report/configuration/reports.rb">lib/lolita-report/configuration/reports.rb</a></li>
|
|
46
|
+
|
|
47
|
+
<li><a href="./lib/lolita-report_rb.html?TB_iframe=true&height=550&width=785"
|
|
48
|
+
class="thickbox" title="lib/lolita-report.rb">lib/lolita-report.rb</a></li>
|
|
49
|
+
|
|
50
|
+
</ul>
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<div id="class-metadata">
|
|
58
|
+
|
|
59
|
+
<!-- Parent Class -->
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
<!-- Namespace Contents -->
|
|
63
|
+
|
|
64
|
+
<div id="namespace-list-section" class="section">
|
|
65
|
+
<h3 class="section-header">Namespace</h3>
|
|
66
|
+
<ul class="link-list">
|
|
67
|
+
|
|
68
|
+
<li><span class="type">MODULE</span> <a href="Lolita/Configuration.html">Lolita::Configuration</a></li>
|
|
69
|
+
|
|
70
|
+
</ul>
|
|
71
|
+
</div>
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
<!-- Method Quickref -->
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
<!-- Included Modules -->
|
|
78
|
+
|
|
79
|
+
</div>
|
|
80
|
+
|
|
81
|
+
<div id="project-metadata">
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
<div id="fileindex-section" class="section project-section">
|
|
85
|
+
<h3 class="section-header">Files</h3>
|
|
86
|
+
<ul>
|
|
87
|
+
|
|
88
|
+
<li class="file"><a href="./Gemfile.html">Gemfile</a></li>
|
|
89
|
+
|
|
90
|
+
<li class="file"><a href="./LICENSE.html">LICENSE</a></li>
|
|
91
|
+
|
|
92
|
+
<li class="file"><a href="./Rakefile.html">Rakefile</a></li>
|
|
93
|
+
|
|
94
|
+
<li class="file"><a href="./author.html">author</a></li>
|
|
95
|
+
|
|
96
|
+
</ul>
|
|
97
|
+
</div>
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
<div id="classindex-section" class="section project-section">
|
|
101
|
+
<h3 class="section-header">Class Index
|
|
102
|
+
<span class="search-toggle"><img src="./images/find.png"
|
|
103
|
+
height="16" width="16" alt="[+]"
|
|
104
|
+
title="show/hide quicksearch" /></span></h3>
|
|
105
|
+
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
|
106
|
+
<fieldset>
|
|
107
|
+
<legend>Quicksearch</legend>
|
|
108
|
+
<input type="text" name="quicksearch" value=""
|
|
109
|
+
class="quicksearch-field" />
|
|
110
|
+
</fieldset>
|
|
111
|
+
</form>
|
|
112
|
+
|
|
113
|
+
<ul class="link-list">
|
|
114
|
+
|
|
115
|
+
<li><a href="./Lolita.html">Lolita</a></li>
|
|
116
|
+
|
|
117
|
+
<li><a href="./Lolita/Configuration.html">Lolita::Configuration</a></li>
|
|
118
|
+
|
|
119
|
+
<li><a href="./Lolita/Configuration/Report.html">Lolita::Configuration::Report</a></li>
|
|
120
|
+
|
|
121
|
+
<li><a href="./Lolita/Configuration/Reports.html">Lolita::Configuration::Reports</a></li>
|
|
122
|
+
|
|
123
|
+
<li><a href="./ActiveSupport.html">ActiveSupport</a></li>
|
|
124
|
+
|
|
125
|
+
<li><a href="./ActiveSupport/TestCase.html">ActiveSupport::TestCase</a></li>
|
|
126
|
+
|
|
127
|
+
<li><a href="./LolitaReport.html">LolitaReport</a></li>
|
|
128
|
+
|
|
129
|
+
<li><a href="./LolitaReport/Configuration.html">LolitaReport::Configuration</a></li>
|
|
130
|
+
|
|
131
|
+
<li><a href="./Comment.html">Comment</a></li>
|
|
132
|
+
|
|
133
|
+
<li><a href="./Post.html">Post</a></li>
|
|
134
|
+
|
|
135
|
+
</ul>
|
|
136
|
+
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
|
137
|
+
</div>
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
</div>
|
|
141
|
+
</div>
|
|
142
|
+
|
|
143
|
+
<div id="documentation">
|
|
144
|
+
<h1 class="module">Lolita</h1>
|
|
145
|
+
|
|
146
|
+
<div id="description">
|
|
147
|
+
<p>
|
|
148
|
+
<a
|
|
149
|
+
href="Lolita/Configuration/Report.html">Lolita::Configuration::Report</a>
|
|
150
|
+
class contain methods for generating report
|
|
151
|
+
</p>
|
|
152
|
+
<hr style="height: 1px"></hr><p>
|
|
153
|
+
Reports class object store Report class objects like an array
|
|
154
|
+
</p>
|
|
155
|
+
|
|
156
|
+
</div>
|
|
157
|
+
|
|
158
|
+
<!-- Constants -->
|
|
159
|
+
|
|
160
|
+
|
|
161
|
+
<!-- Attributes -->
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
<!-- Methods -->
|
|
165
|
+
|
|
166
|
+
|
|
167
|
+
</div>
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
<div id="rdoc-debugging-section-dump" class="debugging-section">
|
|
171
|
+
|
|
172
|
+
<p>Disabled; run with --debug to generate this.</p>
|
|
173
|
+
|
|
174
|
+
</div>
|
|
175
|
+
|
|
176
|
+
<div id="validator-badges">
|
|
177
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
|
178
|
+
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
|
179
|
+
Rdoc Generator</a> 1.1.6</small>.</p>
|
|
180
|
+
</div>
|
|
181
|
+
|
|
182
|
+
</body>
|
|
183
|
+
</html>
|
|
184
|
+
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
|
3
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
4
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
5
|
+
<head>
|
|
6
|
+
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
|
|
7
|
+
|
|
8
|
+
<title>Module: Lolita::Configuration</title>
|
|
9
|
+
|
|
10
|
+
<link rel="stylesheet" href="../rdoc.css" type="text/css" media="screen" />
|
|
11
|
+
|
|
12
|
+
<script src="../js/jquery.js" type="text/javascript"
|
|
13
|
+
charset="utf-8"></script>
|
|
14
|
+
<script src="../js/thickbox-compressed.js" type="text/javascript"
|
|
15
|
+
charset="utf-8"></script>
|
|
16
|
+
<script src="../js/quicksearch.js" type="text/javascript"
|
|
17
|
+
charset="utf-8"></script>
|
|
18
|
+
<script src="../js/darkfish.js" type="text/javascript"
|
|
19
|
+
charset="utf-8"></script>
|
|
20
|
+
|
|
21
|
+
</head>
|
|
22
|
+
<body class="module">
|
|
23
|
+
|
|
24
|
+
<div id="metadata">
|
|
25
|
+
<div id="home-metadata">
|
|
26
|
+
<div id="home-section" class="section">
|
|
27
|
+
<h3 class="section-header">
|
|
28
|
+
<a href="../index.html">Home</a>
|
|
29
|
+
<a href="../index.html#classes">Classes</a>
|
|
30
|
+
<a href="../index.html#methods">Methods</a>
|
|
31
|
+
</h3>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
|
|
35
|
+
<div id="file-metadata">
|
|
36
|
+
<div id="file-list-section" class="section">
|
|
37
|
+
<h3 class="section-header">In Files</h3>
|
|
38
|
+
<div class="section-body">
|
|
39
|
+
<ul>
|
|
40
|
+
|
|
41
|
+
<li><a href="../lib/lolita-report/configuration/report_rb.html?TB_iframe=true&height=550&width=785"
|
|
42
|
+
class="thickbox" title="lib/lolita-report/configuration/report.rb">lib/lolita-report/configuration/report.rb</a></li>
|
|
43
|
+
|
|
44
|
+
<li><a href="../lib/lolita-report/configuration/reports_rb.html?TB_iframe=true&height=550&width=785"
|
|
45
|
+
class="thickbox" title="lib/lolita-report/configuration/reports.rb">lib/lolita-report/configuration/reports.rb</a></li>
|
|
46
|
+
|
|
47
|
+
<li><a href="../lib/lolita-report_rb.html?TB_iframe=true&height=550&width=785"
|
|
48
|
+
class="thickbox" title="lib/lolita-report.rb">lib/lolita-report.rb</a></li>
|
|
49
|
+
|
|
50
|
+
</ul>
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
</div>
|
|
56
|
+
|
|
57
|
+
<div id="class-metadata">
|
|
58
|
+
|
|
59
|
+
<!-- Parent Class -->
|
|
60
|
+
|
|
61
|
+
|
|
62
|
+
<!-- Namespace Contents -->
|
|
63
|
+
|
|
64
|
+
<div id="namespace-list-section" class="section">
|
|
65
|
+
<h3 class="section-header">Namespace</h3>
|
|
66
|
+
<ul class="link-list">
|
|
67
|
+
|
|
68
|
+
<li><span class="type">CLASS</span> <a href="Configuration/Report.html">Lolita::Configuration::Report</a></li>
|
|
69
|
+
|
|
70
|
+
<li><span class="type">CLASS</span> <a href="Configuration/Reports.html">Lolita::Configuration::Reports</a></li>
|
|
71
|
+
|
|
72
|
+
</ul>
|
|
73
|
+
</div>
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
<!-- Method Quickref -->
|
|
77
|
+
|
|
78
|
+
|
|
79
|
+
<!-- Included Modules -->
|
|
80
|
+
|
|
81
|
+
</div>
|
|
82
|
+
|
|
83
|
+
<div id="project-metadata">
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
<div id="fileindex-section" class="section project-section">
|
|
87
|
+
<h3 class="section-header">Files</h3>
|
|
88
|
+
<ul>
|
|
89
|
+
|
|
90
|
+
<li class="file"><a href="../Gemfile.html">Gemfile</a></li>
|
|
91
|
+
|
|
92
|
+
<li class="file"><a href="../LICENSE.html">LICENSE</a></li>
|
|
93
|
+
|
|
94
|
+
<li class="file"><a href="../Rakefile.html">Rakefile</a></li>
|
|
95
|
+
|
|
96
|
+
<li class="file"><a href="../author.html">author</a></li>
|
|
97
|
+
|
|
98
|
+
</ul>
|
|
99
|
+
</div>
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
<div id="classindex-section" class="section project-section">
|
|
103
|
+
<h3 class="section-header">Class Index
|
|
104
|
+
<span class="search-toggle"><img src="../images/find.png"
|
|
105
|
+
height="16" width="16" alt="[+]"
|
|
106
|
+
title="show/hide quicksearch" /></span></h3>
|
|
107
|
+
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
|
108
|
+
<fieldset>
|
|
109
|
+
<legend>Quicksearch</legend>
|
|
110
|
+
<input type="text" name="quicksearch" value=""
|
|
111
|
+
class="quicksearch-field" />
|
|
112
|
+
</fieldset>
|
|
113
|
+
</form>
|
|
114
|
+
|
|
115
|
+
<ul class="link-list">
|
|
116
|
+
|
|
117
|
+
<li><a href="../Lolita.html">Lolita</a></li>
|
|
118
|
+
|
|
119
|
+
<li><a href="../Lolita/Configuration.html">Lolita::Configuration</a></li>
|
|
120
|
+
|
|
121
|
+
<li><a href="../Lolita/Configuration/Report.html">Lolita::Configuration::Report</a></li>
|
|
122
|
+
|
|
123
|
+
<li><a href="../Lolita/Configuration/Reports.html">Lolita::Configuration::Reports</a></li>
|
|
124
|
+
|
|
125
|
+
<li><a href="../ActiveSupport.html">ActiveSupport</a></li>
|
|
126
|
+
|
|
127
|
+
<li><a href="../ActiveSupport/TestCase.html">ActiveSupport::TestCase</a></li>
|
|
128
|
+
|
|
129
|
+
<li><a href="../LolitaReport.html">LolitaReport</a></li>
|
|
130
|
+
|
|
131
|
+
<li><a href="../LolitaReport/Configuration.html">LolitaReport::Configuration</a></li>
|
|
132
|
+
|
|
133
|
+
<li><a href="../Comment.html">Comment</a></li>
|
|
134
|
+
|
|
135
|
+
<li><a href="../Post.html">Post</a></li>
|
|
136
|
+
|
|
137
|
+
</ul>
|
|
138
|
+
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
|
139
|
+
</div>
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
</div>
|
|
143
|
+
</div>
|
|
144
|
+
|
|
145
|
+
<div id="documentation">
|
|
146
|
+
<h1 class="module">Lolita::Configuration</h1>
|
|
147
|
+
|
|
148
|
+
<div id="description">
|
|
149
|
+
|
|
150
|
+
</div>
|
|
151
|
+
|
|
152
|
+
<!-- Constants -->
|
|
153
|
+
|
|
154
|
+
|
|
155
|
+
<!-- Attributes -->
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
<!-- Methods -->
|
|
159
|
+
|
|
160
|
+
|
|
161
|
+
</div>
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
<div id="rdoc-debugging-section-dump" class="debugging-section">
|
|
165
|
+
|
|
166
|
+
<p>Disabled; run with --debug to generate this.</p>
|
|
167
|
+
|
|
168
|
+
</div>
|
|
169
|
+
|
|
170
|
+
<div id="validator-badges">
|
|
171
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
|
172
|
+
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
|
173
|
+
Rdoc Generator</a> 1.1.6</small>.</p>
|
|
174
|
+
</div>
|
|
175
|
+
|
|
176
|
+
</body>
|
|
177
|
+
</html>
|
|
178
|
+
|
|
@@ -0,0 +1,837 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="utf-8"?>
|
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
|
3
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
4
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
|
5
|
+
<head>
|
|
6
|
+
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
|
|
7
|
+
|
|
8
|
+
<title>Class: Lolita::Configuration::Report</title>
|
|
9
|
+
|
|
10
|
+
<link rel="stylesheet" href="../../rdoc.css" type="text/css" media="screen" />
|
|
11
|
+
|
|
12
|
+
<script src="../../js/jquery.js" type="text/javascript"
|
|
13
|
+
charset="utf-8"></script>
|
|
14
|
+
<script src="../../js/thickbox-compressed.js" type="text/javascript"
|
|
15
|
+
charset="utf-8"></script>
|
|
16
|
+
<script src="../../js/quicksearch.js" type="text/javascript"
|
|
17
|
+
charset="utf-8"></script>
|
|
18
|
+
<script src="../../js/darkfish.js" type="text/javascript"
|
|
19
|
+
charset="utf-8"></script>
|
|
20
|
+
|
|
21
|
+
</head>
|
|
22
|
+
<body class="class">
|
|
23
|
+
|
|
24
|
+
<div id="metadata">
|
|
25
|
+
<div id="home-metadata">
|
|
26
|
+
<div id="home-section" class="section">
|
|
27
|
+
<h3 class="section-header">
|
|
28
|
+
<a href="../../index.html">Home</a>
|
|
29
|
+
<a href="../../index.html#classes">Classes</a>
|
|
30
|
+
<a href="../../index.html#methods">Methods</a>
|
|
31
|
+
</h3>
|
|
32
|
+
</div>
|
|
33
|
+
</div>
|
|
34
|
+
|
|
35
|
+
<div id="file-metadata">
|
|
36
|
+
<div id="file-list-section" class="section">
|
|
37
|
+
<h3 class="section-header">In Files</h3>
|
|
38
|
+
<div class="section-body">
|
|
39
|
+
<ul>
|
|
40
|
+
|
|
41
|
+
<li><a href="../../lib/lolita-report/configuration/report_rb.html?TB_iframe=true&height=550&width=785"
|
|
42
|
+
class="thickbox" title="lib/lolita-report/configuration/report.rb">lib/lolita-report/configuration/report.rb</a></li>
|
|
43
|
+
|
|
44
|
+
</ul>
|
|
45
|
+
</div>
|
|
46
|
+
</div>
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
</div>
|
|
50
|
+
|
|
51
|
+
<div id="class-metadata">
|
|
52
|
+
|
|
53
|
+
<!-- Parent Class -->
|
|
54
|
+
|
|
55
|
+
<div id="parent-class-section" class="section">
|
|
56
|
+
<h3 class="section-header">Parent</h3>
|
|
57
|
+
|
|
58
|
+
<p class="link">Object</p>
|
|
59
|
+
|
|
60
|
+
</div>
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
<!-- Namespace Contents -->
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
<!-- Method Quickref -->
|
|
67
|
+
|
|
68
|
+
<div id="method-list-section" class="section">
|
|
69
|
+
<h3 class="section-header">Methods</h3>
|
|
70
|
+
<ul class="link-list">
|
|
71
|
+
|
|
72
|
+
<li><a href="#method-c-new">::new</a></li>
|
|
73
|
+
|
|
74
|
+
<li><a href="#method-i-add_collumns_for_counting">#add_collumns_for_counting</a></li>
|
|
75
|
+
|
|
76
|
+
<li><a href="#method-i-collumns_for_counting_defined%3F">#collumns_for_counting_defined?</a></li>
|
|
77
|
+
|
|
78
|
+
<li><a href="#method-i-create_table_for_report">#create_table_for_report</a></li>
|
|
79
|
+
|
|
80
|
+
<li><a href="#method-i-custom_fields">#custom_fields</a></li>
|
|
81
|
+
|
|
82
|
+
<li><a href="#method-i-export_excel">#export_excel</a></li>
|
|
83
|
+
|
|
84
|
+
<li><a href="#method-i-fields">#fields</a></li>
|
|
85
|
+
|
|
86
|
+
<li><a href="#method-i-fields_defined%3F">#fields_defined?</a></li>
|
|
87
|
+
|
|
88
|
+
<li><a href="#method-i-generate_table_for_report">#generate_table_for_report</a></li>
|
|
89
|
+
|
|
90
|
+
<li><a href="#method-i-name">#name</a></li>
|
|
91
|
+
|
|
92
|
+
<li><a href="#method-i-set_columns_width_for">#set_columns_width_for</a></li>
|
|
93
|
+
|
|
94
|
+
<li><a href="#method-i-set_data_in_counting_columns">#set_data_in_counting_columns</a></li>
|
|
95
|
+
|
|
96
|
+
<li><a href="#method-i-set_data_into_table_for_report">#set_data_into_table_for_report</a></li>
|
|
97
|
+
|
|
98
|
+
<li><a href="#method-i-table_header_format_for">#table_header_format_for</a></li>
|
|
99
|
+
|
|
100
|
+
<li><a href="#method-i-total">#total</a></li>
|
|
101
|
+
|
|
102
|
+
<li><a href="#method-i-total_columns">#total_columns</a></li>
|
|
103
|
+
|
|
104
|
+
</ul>
|
|
105
|
+
</div>
|
|
106
|
+
|
|
107
|
+
|
|
108
|
+
<!-- Included Modules -->
|
|
109
|
+
|
|
110
|
+
</div>
|
|
111
|
+
|
|
112
|
+
<div id="project-metadata">
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
<div id="fileindex-section" class="section project-section">
|
|
116
|
+
<h3 class="section-header">Files</h3>
|
|
117
|
+
<ul>
|
|
118
|
+
|
|
119
|
+
<li class="file"><a href="../../Gemfile.html">Gemfile</a></li>
|
|
120
|
+
|
|
121
|
+
<li class="file"><a href="../../LICENSE.html">LICENSE</a></li>
|
|
122
|
+
|
|
123
|
+
<li class="file"><a href="../../Rakefile.html">Rakefile</a></li>
|
|
124
|
+
|
|
125
|
+
<li class="file"><a href="../../author.html">author</a></li>
|
|
126
|
+
|
|
127
|
+
</ul>
|
|
128
|
+
</div>
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
<div id="classindex-section" class="section project-section">
|
|
132
|
+
<h3 class="section-header">Class Index
|
|
133
|
+
<span class="search-toggle"><img src="../../images/find.png"
|
|
134
|
+
height="16" width="16" alt="[+]"
|
|
135
|
+
title="show/hide quicksearch" /></span></h3>
|
|
136
|
+
<form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
|
|
137
|
+
<fieldset>
|
|
138
|
+
<legend>Quicksearch</legend>
|
|
139
|
+
<input type="text" name="quicksearch" value=""
|
|
140
|
+
class="quicksearch-field" />
|
|
141
|
+
</fieldset>
|
|
142
|
+
</form>
|
|
143
|
+
|
|
144
|
+
<ul class="link-list">
|
|
145
|
+
|
|
146
|
+
<li><a href="../../Lolita.html">Lolita</a></li>
|
|
147
|
+
|
|
148
|
+
<li><a href="../../Lolita/Configuration.html">Lolita::Configuration</a></li>
|
|
149
|
+
|
|
150
|
+
<li><a href="../../Lolita/Configuration/Report.html">Lolita::Configuration::Report</a></li>
|
|
151
|
+
|
|
152
|
+
<li><a href="../../Lolita/Configuration/Reports.html">Lolita::Configuration::Reports</a></li>
|
|
153
|
+
|
|
154
|
+
<li><a href="../../ActiveSupport.html">ActiveSupport</a></li>
|
|
155
|
+
|
|
156
|
+
<li><a href="../../ActiveSupport/TestCase.html">ActiveSupport::TestCase</a></li>
|
|
157
|
+
|
|
158
|
+
<li><a href="../../LolitaReport.html">LolitaReport</a></li>
|
|
159
|
+
|
|
160
|
+
<li><a href="../../LolitaReport/Configuration.html">LolitaReport::Configuration</a></li>
|
|
161
|
+
|
|
162
|
+
<li><a href="../../Comment.html">Comment</a></li>
|
|
163
|
+
|
|
164
|
+
<li><a href="../../Post.html">Post</a></li>
|
|
165
|
+
|
|
166
|
+
</ul>
|
|
167
|
+
<div id="no-class-search-results" style="display: none;">No matching classes.</div>
|
|
168
|
+
</div>
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
</div>
|
|
172
|
+
</div>
|
|
173
|
+
|
|
174
|
+
<div id="documentation">
|
|
175
|
+
<h1 class="class">Lolita::Configuration::Report</h1>
|
|
176
|
+
|
|
177
|
+
<div id="description">
|
|
178
|
+
|
|
179
|
+
</div>
|
|
180
|
+
|
|
181
|
+
<!-- Constants -->
|
|
182
|
+
|
|
183
|
+
|
|
184
|
+
<!-- Attributes -->
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
<!-- Methods -->
|
|
188
|
+
|
|
189
|
+
<div id="public-class-method-details" class="method-section section">
|
|
190
|
+
<h3 class="section-header">Public Class Methods</h3>
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
<div id="new-method" class="method-detail ">
|
|
194
|
+
<a name="method-c-new"></a>
|
|
195
|
+
|
|
196
|
+
<div class="method-heading">
|
|
197
|
+
|
|
198
|
+
<span class="method-name">new</span><span
|
|
199
|
+
class="method-args">(dbi,title=nil, &block)</span>
|
|
200
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
201
|
+
|
|
202
|
+
</div>
|
|
203
|
+
|
|
204
|
+
<div class="method-description">
|
|
205
|
+
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
|
|
209
|
+
|
|
210
|
+
<div class="method-source-code"
|
|
211
|
+
id="new-source">
|
|
212
|
+
<pre>
|
|
213
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 9</span>
|
|
214
|
+
9: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">dbi</span>,<span class="ruby-identifier">title</span>=<span class="ruby-keyword kw">nil</span>, &<span class="ruby-identifier">block</span>)
|
|
215
|
+
10: <span class="ruby-ivar">@dbi</span>=<span class="ruby-identifier">dbi</span>
|
|
216
|
+
11: <span class="ruby-ivar">@fields</span>=[]
|
|
217
|
+
12: <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">title</span>=<span class="ruby-identifier">title</span>
|
|
218
|
+
13: <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">instance_eval</span>(&<span class="ruby-identifier">block</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">block_given?</span>
|
|
219
|
+
14: <span class="ruby-keyword kw">end</span></pre>
|
|
220
|
+
</div>
|
|
221
|
+
|
|
222
|
+
</div>
|
|
223
|
+
|
|
224
|
+
|
|
225
|
+
|
|
226
|
+
|
|
227
|
+
</div>
|
|
228
|
+
|
|
229
|
+
|
|
230
|
+
</div>
|
|
231
|
+
|
|
232
|
+
<div id="public-instance-method-details" class="method-section section">
|
|
233
|
+
<h3 class="section-header">Public Instance Methods</h3>
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
<div id="custom-fields-method" class="method-detail ">
|
|
237
|
+
<a name="method-i-custom_fields"></a>
|
|
238
|
+
|
|
239
|
+
<div class="method-heading">
|
|
240
|
+
|
|
241
|
+
<span class="method-name">custom_fields</span><span
|
|
242
|
+
class="method-args">()</span>
|
|
243
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
244
|
+
|
|
245
|
+
</div>
|
|
246
|
+
|
|
247
|
+
<div class="method-description">
|
|
248
|
+
|
|
249
|
+
<p>
|
|
250
|
+
Return fields for displaying in report.
|
|
251
|
+
</p>
|
|
252
|
+
|
|
253
|
+
|
|
254
|
+
|
|
255
|
+
<div class="method-source-code"
|
|
256
|
+
id="custom-fields-source">
|
|
257
|
+
<pre>
|
|
258
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 42</span>
|
|
259
|
+
42: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">custom_fields</span>
|
|
260
|
+
43: <span class="ruby-ivar">@fields</span> <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@fields</span>
|
|
261
|
+
44: <span class="ruby-keyword kw">end</span></pre>
|
|
262
|
+
</div>
|
|
263
|
+
|
|
264
|
+
</div>
|
|
265
|
+
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
|
|
269
|
+
</div>
|
|
270
|
+
|
|
271
|
+
|
|
272
|
+
<div id="export-excel-method" class="method-detail ">
|
|
273
|
+
<a name="method-i-export_excel"></a>
|
|
274
|
+
|
|
275
|
+
<div class="method-heading">
|
|
276
|
+
|
|
277
|
+
<span class="method-name">export_excel</span><span
|
|
278
|
+
class="method-args">()</span>
|
|
279
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
280
|
+
|
|
281
|
+
</div>
|
|
282
|
+
|
|
283
|
+
<div class="method-description">
|
|
284
|
+
|
|
285
|
+
<p>
|
|
286
|
+
generate excel file with necessary data and formating
|
|
287
|
+
</p>
|
|
288
|
+
|
|
289
|
+
|
|
290
|
+
|
|
291
|
+
<div class="method-source-code"
|
|
292
|
+
id="export-excel-source">
|
|
293
|
+
<pre>
|
|
294
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 54</span>
|
|
295
|
+
54: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">export_excel</span>
|
|
296
|
+
55: <span class="ruby-identifier">book</span> = <span class="ruby-constant">Spreadsheet</span><span class="ruby-operator">::</span><span class="ruby-constant">Workbook</span>.<span class="ruby-identifier">new</span>
|
|
297
|
+
56: <span class="ruby-identifier">sheet1</span>=<span class="ruby-identifier">book</span>.<span class="ruby-identifier">create_worksheet</span>
|
|
298
|
+
57: <span class="ruby-identifier">sheet1</span>.<span class="ruby-identifier">name</span>=<span class="ruby-ivar">@title_for_report</span> <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@title_for_report</span>
|
|
299
|
+
58: <span class="ruby-identifier">sheet1</span>.<span class="ruby-identifier">row</span>(<span class="ruby-value">0</span>).<span class="ruby-identifier">replace</span>(<span class="ruby-ivar">@table</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">attributes</span>.<span class="ruby-identifier">map</span>(&<span class="ruby-value">:to_s</span>))
|
|
300
|
+
59: <span class="ruby-value">1</span>.<span class="ruby-identifier">upto</span>(<span class="ruby-ivar">@table</span>.<span class="ruby-identifier">size</span>){<span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
|
|
301
|
+
60: <span class="ruby-identifier">sheet1</span>.<span class="ruby-identifier">row</span>(<span class="ruby-identifier">i</span>).<span class="ruby-identifier">replace</span>(<span class="ruby-ivar">@table</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">attributes</span>.<span class="ruby-identifier">collect</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span> <span class="ruby-ivar">@table</span>[<span class="ruby-identifier">i</span><span class="ruby-operator">-</span><span class="ruby-value">1</span>].<span class="ruby-identifier">data</span>[<span class="ruby-identifier">f</span>]})
|
|
302
|
+
61: }
|
|
303
|
+
62: <span class="ruby-identifier">table_header_format_for</span> <span class="ruby-identifier">sheet1</span>
|
|
304
|
+
63: <span class="ruby-identifier">set_columns_width_for</span> <span class="ruby-identifier">sheet1</span>
|
|
305
|
+
64: <span class="ruby-comment cmt"># book.write "#{Time.now.to_i}.xls"</span>
|
|
306
|
+
65: <span class="ruby-identifier">book</span>.<span class="ruby-identifier">write</span> <span class="ruby-value str">"test.xls"</span>
|
|
307
|
+
66: <span class="ruby-keyword kw">end</span></pre>
|
|
308
|
+
</div>
|
|
309
|
+
|
|
310
|
+
</div>
|
|
311
|
+
|
|
312
|
+
|
|
313
|
+
|
|
314
|
+
|
|
315
|
+
</div>
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
<div id="fields-method" class="method-detail ">
|
|
319
|
+
<a name="method-i-fields"></a>
|
|
320
|
+
|
|
321
|
+
<div class="method-heading">
|
|
322
|
+
|
|
323
|
+
<span class="method-name">fields</span><span
|
|
324
|
+
class="method-args">(*args)</span>
|
|
325
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
326
|
+
|
|
327
|
+
</div>
|
|
328
|
+
|
|
329
|
+
<div class="method-description">
|
|
330
|
+
|
|
331
|
+
<p>
|
|
332
|
+
Set fields for displaying in report.
|
|
333
|
+
</p>
|
|
334
|
+
|
|
335
|
+
|
|
336
|
+
|
|
337
|
+
<div class="method-source-code"
|
|
338
|
+
id="fields-source">
|
|
339
|
+
<pre>
|
|
340
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 36</span>
|
|
341
|
+
36: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">fields</span>(*<span class="ruby-identifier">args</span>)
|
|
342
|
+
37: <span class="ruby-ivar">@fields</span>=<span class="ruby-identifier">args</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">args</span>
|
|
343
|
+
38: <span class="ruby-ivar">@fields</span>
|
|
344
|
+
39: <span class="ruby-keyword kw">end</span></pre>
|
|
345
|
+
</div>
|
|
346
|
+
|
|
347
|
+
</div>
|
|
348
|
+
|
|
349
|
+
|
|
350
|
+
|
|
351
|
+
|
|
352
|
+
</div>
|
|
353
|
+
|
|
354
|
+
|
|
355
|
+
<div id="generate-table-for-report-method" class="method-detail ">
|
|
356
|
+
<a name="method-i-generate_table_for_report"></a>
|
|
357
|
+
|
|
358
|
+
<div class="method-heading">
|
|
359
|
+
|
|
360
|
+
<span class="method-name">generate_table_for_report</span><span
|
|
361
|
+
class="method-args">()</span>
|
|
362
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
363
|
+
|
|
364
|
+
</div>
|
|
365
|
+
|
|
366
|
+
<div class="method-description">
|
|
367
|
+
|
|
368
|
+
<p>
|
|
369
|
+
Generate table for report, which contain all necessary data
|
|
370
|
+
</p>
|
|
371
|
+
|
|
372
|
+
|
|
373
|
+
|
|
374
|
+
<div class="method-source-code"
|
|
375
|
+
id="generate-table-for-report-source">
|
|
376
|
+
<pre>
|
|
377
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 47</span>
|
|
378
|
+
47: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">generate_table_for_report</span>
|
|
379
|
+
48: <span class="ruby-identifier">create_table_for_report</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">fields_defined?</span>
|
|
380
|
+
49: <span class="ruby-identifier">add_collumns_for_counting</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">collumns_for_counting_defined?</span>
|
|
381
|
+
50: <span class="ruby-identifier">set_data_into_table_for_report</span>
|
|
382
|
+
51: <span class="ruby-ivar">@table</span>
|
|
383
|
+
52: <span class="ruby-keyword kw">end</span></pre>
|
|
384
|
+
</div>
|
|
385
|
+
|
|
386
|
+
</div>
|
|
387
|
+
|
|
388
|
+
|
|
389
|
+
|
|
390
|
+
|
|
391
|
+
</div>
|
|
392
|
+
|
|
393
|
+
|
|
394
|
+
<div id="name-method" class="method-detail ">
|
|
395
|
+
<a name="method-i-name"></a>
|
|
396
|
+
|
|
397
|
+
<div class="method-heading">
|
|
398
|
+
|
|
399
|
+
<span class="method-name">name</span><span
|
|
400
|
+
class="method-args">(title)</span>
|
|
401
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
402
|
+
|
|
403
|
+
</div>
|
|
404
|
+
|
|
405
|
+
<div class="method-description">
|
|
406
|
+
|
|
407
|
+
<p>
|
|
408
|
+
Set a title for report.
|
|
409
|
+
</p>
|
|
410
|
+
|
|
411
|
+
|
|
412
|
+
|
|
413
|
+
<div class="method-source-code"
|
|
414
|
+
id="name-source">
|
|
415
|
+
<pre>
|
|
416
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 27</span>
|
|
417
|
+
27: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">name</span> <span class="ruby-identifier">title</span>
|
|
418
|
+
28: <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">title</span>
|
|
419
|
+
29: <span class="ruby-ivar">@title_for_report</span>=<span class="ruby-identifier">title</span>
|
|
420
|
+
30: <span class="ruby-keyword kw">else</span>
|
|
421
|
+
31: <span class="ruby-ivar">@title_for_report</span>=<span class="ruby-value str">""</span>
|
|
422
|
+
32: <span class="ruby-keyword kw">end</span>
|
|
423
|
+
33: <span class="ruby-keyword kw">end</span></pre>
|
|
424
|
+
</div>
|
|
425
|
+
|
|
426
|
+
</div>
|
|
427
|
+
|
|
428
|
+
|
|
429
|
+
|
|
430
|
+
|
|
431
|
+
</div>
|
|
432
|
+
|
|
433
|
+
|
|
434
|
+
<div id="total-method" class="method-detail ">
|
|
435
|
+
<a name="method-i-total"></a>
|
|
436
|
+
|
|
437
|
+
<div class="method-heading">
|
|
438
|
+
|
|
439
|
+
<span class="method-name">total</span><span
|
|
440
|
+
class="method-args">(*args)</span>
|
|
441
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
442
|
+
|
|
443
|
+
</div>
|
|
444
|
+
|
|
445
|
+
<div class="method-description">
|
|
446
|
+
|
|
447
|
+
<p>
|
|
448
|
+
Set data for counting.
|
|
449
|
+
</p>
|
|
450
|
+
|
|
451
|
+
|
|
452
|
+
|
|
453
|
+
<div class="method-source-code"
|
|
454
|
+
id="total-source">
|
|
455
|
+
<pre>
|
|
456
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 17</span>
|
|
457
|
+
17: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">total</span>(*<span class="ruby-identifier">args</span>)
|
|
458
|
+
18: <span class="ruby-ivar">@collumns_for_counting</span>=<span class="ruby-identifier">args</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">args</span>
|
|
459
|
+
19: <span class="ruby-ivar">@collumns_for_counting</span>
|
|
460
|
+
20: <span class="ruby-keyword kw">end</span></pre>
|
|
461
|
+
</div>
|
|
462
|
+
|
|
463
|
+
</div>
|
|
464
|
+
|
|
465
|
+
|
|
466
|
+
|
|
467
|
+
|
|
468
|
+
</div>
|
|
469
|
+
|
|
470
|
+
|
|
471
|
+
<div id="total-columns-method" class="method-detail ">
|
|
472
|
+
<a name="method-i-total_columns"></a>
|
|
473
|
+
|
|
474
|
+
<div class="method-heading">
|
|
475
|
+
|
|
476
|
+
<span class="method-name">total_columns</span><span
|
|
477
|
+
class="method-args">()</span>
|
|
478
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
479
|
+
|
|
480
|
+
</div>
|
|
481
|
+
|
|
482
|
+
<div class="method-description">
|
|
483
|
+
|
|
484
|
+
<p>
|
|
485
|
+
Return columns in array, which are needed counted.
|
|
486
|
+
</p>
|
|
487
|
+
|
|
488
|
+
|
|
489
|
+
|
|
490
|
+
<div class="method-source-code"
|
|
491
|
+
id="total-columns-source">
|
|
492
|
+
<pre>
|
|
493
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 22</span>
|
|
494
|
+
22: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">total_columns</span>
|
|
495
|
+
23: <span class="ruby-ivar">@collumns_for_counting</span>
|
|
496
|
+
24: <span class="ruby-keyword kw">end</span></pre>
|
|
497
|
+
</div>
|
|
498
|
+
|
|
499
|
+
</div>
|
|
500
|
+
|
|
501
|
+
|
|
502
|
+
|
|
503
|
+
|
|
504
|
+
</div>
|
|
505
|
+
|
|
506
|
+
|
|
507
|
+
</div>
|
|
508
|
+
|
|
509
|
+
<div id="private-instance-method-details" class="method-section section">
|
|
510
|
+
<h3 class="section-header">Private Instance Methods</h3>
|
|
511
|
+
|
|
512
|
+
|
|
513
|
+
<div id="add-collumns-for-counting-method" class="method-detail ">
|
|
514
|
+
<a name="method-i-add_collumns_for_counting"></a>
|
|
515
|
+
|
|
516
|
+
<div class="method-heading">
|
|
517
|
+
|
|
518
|
+
<span class="method-name">add_collumns_for_counting</span><span
|
|
519
|
+
class="method-args">()</span>
|
|
520
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
521
|
+
|
|
522
|
+
</div>
|
|
523
|
+
|
|
524
|
+
<div class="method-description">
|
|
525
|
+
|
|
526
|
+
<p>
|
|
527
|
+
For setting data for cuonting, necessary to add this collumns to table.
|
|
528
|
+
</p>
|
|
529
|
+
|
|
530
|
+
|
|
531
|
+
|
|
532
|
+
<div class="method-source-code"
|
|
533
|
+
id="add-collumns-for-counting-source">
|
|
534
|
+
<pre>
|
|
535
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 112</span>
|
|
536
|
+
112: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">add_collumns_for_counting</span>
|
|
537
|
+
113: <span class="ruby-ivar">@collumns_for_counting</span>.<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">method</span><span class="ruby-operator">|</span>
|
|
538
|
+
114: <span class="ruby-ivar">@table</span>.<span class="ruby-identifier">add_column</span>(<span class="ruby-node">"#{method.to_s}_total"</span>,<span class="ruby-value">:default=</span><span class="ruby-operator">></span><span class="ruby-value">0</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@table</span>
|
|
539
|
+
115: }
|
|
540
|
+
116: <span class="ruby-keyword kw">end</span></pre>
|
|
541
|
+
</div>
|
|
542
|
+
|
|
543
|
+
</div>
|
|
544
|
+
|
|
545
|
+
|
|
546
|
+
|
|
547
|
+
|
|
548
|
+
</div>
|
|
549
|
+
|
|
550
|
+
|
|
551
|
+
<div id="collumns-for-counting-defined--method" class="method-detail ">
|
|
552
|
+
<a name="method-i-collumns_for_counting_defined%3F"></a>
|
|
553
|
+
|
|
554
|
+
<div class="method-heading">
|
|
555
|
+
|
|
556
|
+
<span class="method-name">collumns_for_counting_defined?</span><span
|
|
557
|
+
class="method-args">()</span>
|
|
558
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
559
|
+
|
|
560
|
+
</div>
|
|
561
|
+
|
|
562
|
+
<div class="method-description">
|
|
563
|
+
|
|
564
|
+
<p>
|
|
565
|
+
Check if fields for counting are defined for report.
|
|
566
|
+
</p>
|
|
567
|
+
|
|
568
|
+
|
|
569
|
+
|
|
570
|
+
<div class="method-source-code"
|
|
571
|
+
id="collumns-for-counting-defined--source">
|
|
572
|
+
<pre>
|
|
573
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 108</span>
|
|
574
|
+
108: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">collumns_for_counting_defined?</span>
|
|
575
|
+
109: <span class="ruby-ivar">@collumns_for_counting</span>.<span class="ruby-identifier">size</span><span class="ruby-operator">></span><span class="ruby-value">0</span> <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@collumns_for_counting</span>
|
|
576
|
+
110: <span class="ruby-keyword kw">end</span></pre>
|
|
577
|
+
</div>
|
|
578
|
+
|
|
579
|
+
</div>
|
|
580
|
+
|
|
581
|
+
|
|
582
|
+
|
|
583
|
+
|
|
584
|
+
</div>
|
|
585
|
+
|
|
586
|
+
|
|
587
|
+
<div id="create-table-for-report-method" class="method-detail ">
|
|
588
|
+
<a name="method-i-create_table_for_report"></a>
|
|
589
|
+
|
|
590
|
+
<div class="method-heading">
|
|
591
|
+
|
|
592
|
+
<span class="method-name">create_table_for_report</span><span
|
|
593
|
+
class="method-args">()</span>
|
|
594
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
595
|
+
|
|
596
|
+
</div>
|
|
597
|
+
|
|
598
|
+
<div class="method-description">
|
|
599
|
+
|
|
600
|
+
<p>
|
|
601
|
+
Make table,which contain all necessary data for report.
|
|
602
|
+
</p>
|
|
603
|
+
|
|
604
|
+
|
|
605
|
+
|
|
606
|
+
<div class="method-source-code"
|
|
607
|
+
id="create-table-for-report-source">
|
|
608
|
+
<pre>
|
|
609
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 83</span>
|
|
610
|
+
83: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">create_table_for_report</span>
|
|
611
|
+
84: <span class="ruby-ivar">@table</span> = <span class="ruby-constant">Table</span> <span class="ruby-ivar">@fields</span>
|
|
612
|
+
85: <span class="ruby-keyword kw">end</span></pre>
|
|
613
|
+
</div>
|
|
614
|
+
|
|
615
|
+
</div>
|
|
616
|
+
|
|
617
|
+
|
|
618
|
+
|
|
619
|
+
|
|
620
|
+
</div>
|
|
621
|
+
|
|
622
|
+
|
|
623
|
+
<div id="fields-defined--method" class="method-detail ">
|
|
624
|
+
<a name="method-i-fields_defined%3F"></a>
|
|
625
|
+
|
|
626
|
+
<div class="method-heading">
|
|
627
|
+
|
|
628
|
+
<span class="method-name">fields_defined?</span><span
|
|
629
|
+
class="method-args">()</span>
|
|
630
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
631
|
+
|
|
632
|
+
</div>
|
|
633
|
+
|
|
634
|
+
<div class="method-description">
|
|
635
|
+
|
|
636
|
+
<p>
|
|
637
|
+
Check if fields are defined for report.
|
|
638
|
+
</p>
|
|
639
|
+
|
|
640
|
+
|
|
641
|
+
|
|
642
|
+
<div class="method-source-code"
|
|
643
|
+
id="fields-defined--source">
|
|
644
|
+
<pre>
|
|
645
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 104</span>
|
|
646
|
+
104: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">fields_defined?</span>
|
|
647
|
+
105: <span class="ruby-ivar">@fields</span>.<span class="ruby-identifier">size</span><span class="ruby-operator">></span><span class="ruby-value">0</span> <span class="ruby-keyword kw">if</span> <span class="ruby-ivar">@fields</span>
|
|
648
|
+
106: <span class="ruby-keyword kw">end</span></pre>
|
|
649
|
+
</div>
|
|
650
|
+
|
|
651
|
+
</div>
|
|
652
|
+
|
|
653
|
+
|
|
654
|
+
|
|
655
|
+
|
|
656
|
+
</div>
|
|
657
|
+
|
|
658
|
+
|
|
659
|
+
<div id="set-columns-width-for-method" class="method-detail ">
|
|
660
|
+
<a name="method-i-set_columns_width_for"></a>
|
|
661
|
+
|
|
662
|
+
<div class="method-heading">
|
|
663
|
+
|
|
664
|
+
<span class="method-name">set_columns_width_for</span><span
|
|
665
|
+
class="method-args">(sheet)</span>
|
|
666
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
667
|
+
|
|
668
|
+
</div>
|
|
669
|
+
|
|
670
|
+
<div class="method-description">
|
|
671
|
+
|
|
672
|
+
<p>
|
|
673
|
+
set excel collumns width for sheet
|
|
674
|
+
</p>
|
|
675
|
+
|
|
676
|
+
|
|
677
|
+
|
|
678
|
+
<div class="method-source-code"
|
|
679
|
+
id="set-columns-width-for-source">
|
|
680
|
+
<pre>
|
|
681
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 70</span>
|
|
682
|
+
70: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">set_columns_width_for</span> <span class="ruby-identifier">sheet</span>
|
|
683
|
+
71: <span class="ruby-value">0</span>.<span class="ruby-identifier">upto</span>(<span class="ruby-ivar">@table</span>[<span class="ruby-value">0</span>].<span class="ruby-identifier">attributes</span>.<span class="ruby-identifier">size</span><span class="ruby-operator">-</span><span class="ruby-value">1</span>){<span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
|
|
684
|
+
72: <span class="ruby-identifier">sheet</span>.<span class="ruby-identifier">column</span>(<span class="ruby-identifier">i</span>).<span class="ruby-identifier">width</span>=<span class="ruby-value">20</span>
|
|
685
|
+
73: }
|
|
686
|
+
74: <span class="ruby-keyword kw">end</span></pre>
|
|
687
|
+
</div>
|
|
688
|
+
|
|
689
|
+
</div>
|
|
690
|
+
|
|
691
|
+
|
|
692
|
+
|
|
693
|
+
|
|
694
|
+
</div>
|
|
695
|
+
|
|
696
|
+
|
|
697
|
+
<div id="set-data-in-counting-columns-method" class="method-detail ">
|
|
698
|
+
<a name="method-i-set_data_in_counting_columns"></a>
|
|
699
|
+
|
|
700
|
+
<div class="method-heading">
|
|
701
|
+
|
|
702
|
+
<span class="method-name">set_data_in_counting_columns</span><span
|
|
703
|
+
class="method-args">(object)</span>
|
|
704
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
705
|
+
|
|
706
|
+
</div>
|
|
707
|
+
|
|
708
|
+
<div class="method-description">
|
|
709
|
+
|
|
710
|
+
<p>
|
|
711
|
+
Set necessary data in columns, where will bi counting something.
|
|
712
|
+
</p>
|
|
713
|
+
|
|
714
|
+
|
|
715
|
+
|
|
716
|
+
<div class="method-source-code"
|
|
717
|
+
id="set-data-in-counting-columns-source">
|
|
718
|
+
<pre>
|
|
719
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 98</span>
|
|
720
|
+
98: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">set_data_in_counting_columns</span> <span class="ruby-identifier">object</span>
|
|
721
|
+
99: <span class="ruby-ivar">@collumns_for_counting</span>.<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">method</span><span class="ruby-operator">|</span>
|
|
722
|
+
100: <span class="ruby-ivar">@hsh</span>[<span class="ruby-node">"#{method.to_s}_total"</span>]=<span class="ruby-identifier">object</span>.<span class="ruby-identifier">send</span>(<span class="ruby-identifier">method</span>).<span class="ruby-identifier">size</span>
|
|
723
|
+
101: }
|
|
724
|
+
102: <span class="ruby-keyword kw">end</span></pre>
|
|
725
|
+
</div>
|
|
726
|
+
|
|
727
|
+
</div>
|
|
728
|
+
|
|
729
|
+
|
|
730
|
+
|
|
731
|
+
|
|
732
|
+
</div>
|
|
733
|
+
|
|
734
|
+
|
|
735
|
+
<div id="set-data-into-table-for-report-method" class="method-detail ">
|
|
736
|
+
<a name="method-i-set_data_into_table_for_report"></a>
|
|
737
|
+
|
|
738
|
+
<div class="method-heading">
|
|
739
|
+
|
|
740
|
+
<span class="method-name">set_data_into_table_for_report</span><span
|
|
741
|
+
class="method-args">()</span>
|
|
742
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
743
|
+
|
|
744
|
+
</div>
|
|
745
|
+
|
|
746
|
+
<div class="method-description">
|
|
747
|
+
|
|
748
|
+
<p>
|
|
749
|
+
Set all necessary data into table.
|
|
750
|
+
</p>
|
|
751
|
+
|
|
752
|
+
|
|
753
|
+
|
|
754
|
+
<div class="method-source-code"
|
|
755
|
+
id="set-data-into-table-for-report-source">
|
|
756
|
+
<pre>
|
|
757
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 87</span>
|
|
758
|
+
87: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">set_data_into_table_for_report</span>
|
|
759
|
+
88: <span class="ruby-ivar">@dbi</span>.<span class="ruby-identifier">find</span>(<span class="ruby-value">:all</span>).<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">object</span><span class="ruby-operator">|</span>
|
|
760
|
+
89: <span class="ruby-ivar">@hsh</span>={}
|
|
761
|
+
90: <span class="ruby-ivar">@fields</span>.<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">f</span><span class="ruby-operator">|</span>
|
|
762
|
+
91: <span class="ruby-ivar">@hsh</span>[<span class="ruby-identifier">f</span>]=<span class="ruby-identifier">object</span>.<span class="ruby-identifier">send</span>(<span class="ruby-identifier">f</span>)
|
|
763
|
+
92: <span class="ruby-identifier">set_data_in_counting_columns</span>(<span class="ruby-identifier">object</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">collumns_for_counting_defined?</span>
|
|
764
|
+
93: }
|
|
765
|
+
94: <span class="ruby-ivar">@table</span><span class="ruby-operator"><<</span><span class="ruby-ivar">@hsh</span>
|
|
766
|
+
95: }
|
|
767
|
+
96: <span class="ruby-keyword kw">end</span></pre>
|
|
768
|
+
</div>
|
|
769
|
+
|
|
770
|
+
</div>
|
|
771
|
+
|
|
772
|
+
|
|
773
|
+
|
|
774
|
+
|
|
775
|
+
</div>
|
|
776
|
+
|
|
777
|
+
|
|
778
|
+
<div id="table-header-format-for-method" class="method-detail ">
|
|
779
|
+
<a name="method-i-table_header_format_for"></a>
|
|
780
|
+
|
|
781
|
+
<div class="method-heading">
|
|
782
|
+
|
|
783
|
+
<span class="method-name">table_header_format_for</span><span
|
|
784
|
+
class="method-args">(sheet)</span>
|
|
785
|
+
<span class="method-click-advice">click to toggle source</span>
|
|
786
|
+
|
|
787
|
+
</div>
|
|
788
|
+
|
|
789
|
+
<div class="method-description">
|
|
790
|
+
|
|
791
|
+
<p>
|
|
792
|
+
make format for excel table header
|
|
793
|
+
</p>
|
|
794
|
+
|
|
795
|
+
|
|
796
|
+
|
|
797
|
+
<div class="method-source-code"
|
|
798
|
+
id="table-header-format-for-source">
|
|
799
|
+
<pre>
|
|
800
|
+
<span class="ruby-comment cmt"># File lib/lolita-report/configuration/report.rb, line 76</span>
|
|
801
|
+
76: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">table_header_format_for</span> <span class="ruby-identifier">sheet</span>
|
|
802
|
+
77: <span class="ruby-identifier">title_format</span> = <span class="ruby-constant">Spreadsheet</span><span class="ruby-operator">::</span><span class="ruby-constant">Format</span>.<span class="ruby-identifier">new</span> <span class="ruby-value">:pattern_bg_color=</span><span class="ruby-operator">></span><span class="ruby-value">:grey</span>,
|
|
803
|
+
78: <span class="ruby-value">:weight</span> =<span class="ruby-operator">></span> <span class="ruby-value">:bold</span>,
|
|
804
|
+
79: <span class="ruby-value">:size</span> =<span class="ruby-operator">></span> <span class="ruby-value">12</span>
|
|
805
|
+
80: <span class="ruby-identifier">sheet</span>.<span class="ruby-identifier">row</span>(<span class="ruby-value">0</span>).<span class="ruby-identifier">default_format</span> =<span class="ruby-identifier">title_format</span>
|
|
806
|
+
81: <span class="ruby-keyword kw">end</span></pre>
|
|
807
|
+
</div>
|
|
808
|
+
|
|
809
|
+
</div>
|
|
810
|
+
|
|
811
|
+
|
|
812
|
+
|
|
813
|
+
|
|
814
|
+
</div>
|
|
815
|
+
|
|
816
|
+
|
|
817
|
+
</div>
|
|
818
|
+
|
|
819
|
+
|
|
820
|
+
</div>
|
|
821
|
+
|
|
822
|
+
|
|
823
|
+
<div id="rdoc-debugging-section-dump" class="debugging-section">
|
|
824
|
+
|
|
825
|
+
<p>Disabled; run with --debug to generate this.</p>
|
|
826
|
+
|
|
827
|
+
</div>
|
|
828
|
+
|
|
829
|
+
<div id="validator-badges">
|
|
830
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
|
831
|
+
<p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
|
|
832
|
+
Rdoc Generator</a> 1.1.6</small>.</p>
|
|
833
|
+
</div>
|
|
834
|
+
|
|
835
|
+
</body>
|
|
836
|
+
</html>
|
|
837
|
+
|