OSDN Git Service

DBFlute-0.9.3に更新
[ea2ddl/ea2ddl.git] / ea2ddl-gen / dbflute-0.9.3 / templates / doc / html / datamodel.vm
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">\r
2 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja">\r
3 <head>\r
4   <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />\r
5   <title>${database.projectName} schema</title>\r
6   <style type="text/css">\r
7         * {\r
8                 margin: 0;\r
9                 padding: 0;\r
10         }\r
11         body {\r
12                 font-family: sans-serif;\r
13                 font-size: 90%;\r
14                 margin: 10px 5px 5px 15px;\r
15         }\r
16         \r
17         /* header */\r
18         h1 {\r
19                 font-size: 1.5em;\r
20                 border-bottom: 2px solid #af0000;\r
21                 border-top: 2px solid #af0000;\r
22         }\r
23         h2 {\r
24                 margin: 30px 0 5px 0;\r
25                 font-size: 1.8em;\r
26                 border-bottom: 2px solid #af0000;\r
27                 border-left: 10px solid #af0000;\r
28                 text-indent: 10px;\r
29         }\r
30         .updatedate {\r
31                 text-align: right;\r
32         }\r
33         \r
34         /* table */\r
35         table {\r
36                 border-collapse:collapse;\r
37         }\r
38         table, th {\r
39                 border: 1px solid #555;\r
40         }\r
41         th {\r
42                 background-color: #cc9;\r
43                 font-size: 0.8em;\r
44         }\r
45         td {\r
46                 border-bottom: 1px dotted #aaa;\r
47                 border-left: 1px solid #555;\r
48                 padding:2px;\r
49         }\r
50         .aliascell {\r
51                 white-space: nowrap;\r
52         }\r
53         .flgcell {\r
54                 text-align: center;\r
55         }\r
56         .numcell {\r
57                 text-align: center;\r
58         }\r
59         .linkcell {\r
60                 font-size: 0.8em;\r
61         }\r
62         .commentcell {\r
63                 font-size: 0.7em;\r
64         }\r
65         .subcell {\r
66                 font-size: 0.8em;\r
67         }\r
68         .comcolcell {\r
69                 color: #666;\r
70         }\r
71         .optcell {\r
72                 font-style: italic;\r
73         }\r
74         .additionalpk {\r
75                 font-size: 0.7em;\r
76                 font-style: italic;\r
77         }\r
78         .additionalfk {\r
79                 font-size: 0.7em;\r
80                 font-style: italic;\r
81         }\r
82 \r
83         /* inner table */\r
84         table.child {\r
85                 margin: 3px;\r
86         }\r
87         table.child th {\r
88                 font-size: 0.7em;\r
89                 background-color: #fff;\r
90         }\r
91         table.child, table.child td, table.child th {\r
92                 border-top: none;\r
93                 border-left: none;\r
94                 border-bottom: 1px solid #aaa;\r
95                 border-right: 1px solid #aaa;\r
96         }\r
97   </style>\r
98 </head>\r
99 \r
100 <body>\r
101   <h1>${database.projectName} schema on ${database.databaseName}</h1>\r
102   <p class="updatedate">${database.timestampExpression}</p>\r
103   <h2>Table List</h2>\r
104   <table>\r
105     <thead>\r
106       <tr>\r
107 #if ($database.isAliasDelimiterInDbCommentValid())\r
108         <th>Alias</th>\r
109 #end\r
110         <th>Name</th>\r
111         <th>Type</th>\r
112         <th>ForeignTable</th>\r
113         <th>ReferrerTable</th>\r
114         <th>Comment</th>\r
115         <th>EntityName</th>\r
116       </tr>\r
117     </thead>\r
118     <tbody>\r
119 #foreach ($table in $database.tableDisplaySortedList)\r
120       <tr>\r
121 #if ($database.isAliasDelimiterInDbCommentValid())\r
122         <td class="aliascell">${table.alias}</td>\r
123 #end\r
124         <td><a href="#${table.name}">${table.name}</a></td>\r
125         <td>${table.type}</td>\r
126         <td class="subcell">${table.foreignTableNameCommaStringWithHtmlHref}</td>\r
127         <td class="subcell">${table.referrerTableNameCommaStringWithHtmlHref}</td>\r
128         <td class="commentcell">#if ($table.hasComment()) ${table.commentForSchemaHtml}#else &nbsp;#end</td>\r
129         <td class="subcell">${table.javaName}</td>\r
130       </tr>\r
131 #end\r
132     </tbody>\r
133   </table>\r
134 \r
135 #foreach ($table in $database.tableDisplaySortedList)\r
136 $generator.parse("doc/html/table.vm", null, "table", $table)\r
137 #end\r
138 \r
139 #if ($database.hasClassificationDefinitionMap())\r
140   <h2>Classification Definition</h2>\r
141   <table>\r
142       <thead>\r
143       <tr>\r
144         <th>Classification</th>\r
145         <th>Top Comment</th>\r
146         <th>Definition</th>\r
147       </tr>\r
148       </thead>\r
149     <tbody>\r
150 #foreach ($classificationName in $database.classificationNameList)\r
151 #set ($classificationMapList = $database.classificationDefinitionMap.get($classificationName))\r
152 #set ($existTop = false)\r
153 #if ($database.classificationTopDefinitionMap.containsKey($classificationName))\r
154   #set ($classificationTopMap = $database.classificationTopDefinitionMap.get($classificationName))\r
155   #set ($existTop = true)\r
156 #else\r
157   #set ($existTop = false)\r
158 #end\r
159       <tr>\r
160         <td><a name="${classificationName}"/>${classificationName}</td>\r
161         <td>#if ($existTop && $classificationTopMap.containsKey('topComment'))$classificationTopMap.get('topComment')#else &nbsp;#end</td>\r
162         <td>\r
163           <table class="child">\r
164             <tr>\r
165               <th>Code</th>\r
166               <th>Name</th>\r
167               <th>Comment</th>\r
168             </tr>\r
169 #foreach ($classificationMap in $classificationMapList)\r
170             <tr>\r
171               <td>$classificationMap.get('code')</td>\r
172               <td>${classificationMap.get('name')}</td>\r
173               <td>#if ($classificationMap.containsKey('comment'))${classificationMap.get('comment')}#else &nbsp;#end</td>\r
174             </tr>\r
175 #end\r
176           </table>\r
177         </td>\r
178       </tr>\r
179 #end\r
180     </tbody>\r
181   </table>\r
182 #end\r
183 </body>\r
184 </html>\r