wakame-vdc-webui 10.12.0 → 11.06.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (152) hide show
  1. data/INSTALL-API.txt +14 -0
  2. data/Rakefile +5 -1
  3. data/app/api/config/environment.rb +9 -0
  4. data/app/controllers/accounts_controller.rb +39 -1
  5. data/app/controllers/application_controller.rb +73 -1
  6. data/app/controllers/instance_specs_controller.rb +11 -0
  7. data/app/controllers/instances_controller.rb +7 -3
  8. data/app/controllers/{images_controller.rb → machine_images_controller.rb} +2 -3
  9. data/app/controllers/sessions_controller.rb +6 -3
  10. data/app/controllers/snapshots_controller.rb +17 -6
  11. data/app/controllers/volumes_controller.rb +6 -2
  12. data/app/helpers/application_helper.rb +9 -5
  13. data/app/helpers/machine_images_helper.rb +2 -0
  14. data/app/models/account.rb +22 -4
  15. data/app/models/base_new.rb +11 -2
  16. data/app/models/dcmgr_resource/base.rb +13 -0
  17. data/app/models/dcmgr_resource/instance_spec.rb +7 -0
  18. data/app/models/dcmgr_resource/volume_snapshot.rb +6 -0
  19. data/app/models/information.rb +1 -1
  20. data/app/models/oauth_consumer.rb +15 -0
  21. data/app/models/oauth_token.rb +10 -0
  22. data/app/models/user.rb +34 -1
  23. data/app/views/accounts/index.html.erb +42 -67
  24. data/app/views/accounts/password.html.erb +35 -0
  25. data/app/views/dialog/attach_volume.html.erb +2 -2
  26. data/app/views/dialog/create_and_edit_security_group.html.erb +61 -28
  27. data/app/views/dialog/create_snapshot.html.erb +11 -4
  28. data/app/views/dialog/create_ssh_keypair.html.erb +2 -2
  29. data/app/views/dialog/create_volume.html.erb +3 -4
  30. data/app/views/dialog/create_volume_from_snapshot.html.erb +1 -1
  31. data/app/views/dialog/delete_security_group.html.erb +1 -1
  32. data/app/views/dialog/delete_snapshot.html.erb +1 -1
  33. data/app/views/dialog/delete_ssh_keypair.html.erb +1 -1
  34. data/app/views/dialog/delete_volume.html.erb +1 -1
  35. data/app/views/dialog/detach_volume.html.erb +1 -1
  36. data/app/views/dialog/launch_instance.html.erb +10 -14
  37. data/app/views/dialog/reboot_instances.html.erb +1 -1
  38. data/app/views/dialog/terminate_instances.html.erb +1 -1
  39. data/app/views/home/index.html.erb +11 -11
  40. data/app/views/host_pools/index.html.erb +87 -92
  41. data/app/views/instances/index.html.erb +50 -52
  42. data/app/views/keypairs/index.html.erb +16 -16
  43. data/app/views/layouts/_header.html.erb +6 -6
  44. data/app/views/layouts/_informationarea.html.erb +5 -5
  45. data/app/views/layouts/_login_header.erb +1 -1
  46. data/app/views/layouts/_sidemenu.html.erb +30 -28
  47. data/app/views/layouts/application.html.erb +19 -3
  48. data/app/views/layouts/login.html.erb +4 -4
  49. data/app/views/{images → machine_images}/index.html.erb +20 -39
  50. data/app/views/security_groups/index.html.erb +20 -23
  51. data/app/views/sessions/new.html.erb +10 -5
  52. data/app/views/snapshots/index.html.erb +28 -26
  53. data/app/views/storage_pools/index.html.erb +17 -22
  54. data/app/views/volumes/index.html.erb +32 -34
  55. data/config/application-cli.rb +33 -0
  56. data/config/{application-api.rb → cli_token.rb} +0 -0
  57. data/config/environment-cli.rb +4 -0
  58. data/config/environments/development.rb +19 -0
  59. data/config/initializers/dcmgr_gui.rb +8 -3
  60. data/config/initializers/sequel.rb +4 -0
  61. data/config/initializers/site.rb +8 -0
  62. data/config/locales/en.yml +307 -1
  63. data/config/locales/ja-JP.yml +4 -0
  64. data/config/locales/ja.yml +309 -0
  65. data/config/routes.rb +16 -9
  66. data/lib/cli/account.rb +264 -0
  67. data/lib/cli/base.rb +74 -0
  68. data/lib/cli/errors.rb +59 -0
  69. data/lib/cli/user.rb +226 -0
  70. data/lib/tasks/dcmgr_api.rake +65 -12
  71. data/lib/tasks/dcmgr_gui.rake +96 -4
  72. data/lib/tasks/dcmgr_oauth.rake +39 -0
  73. data/public/i18n/Messages.properties +0 -0
  74. data/public/images/Chevron.gif +0 -0
  75. data/public/images/ChevronOverlay.png +0 -0
  76. data/public/images/IconHome.gif +0 -0
  77. data/public/images/bg-box-body.gif +0 -0
  78. data/public/images/bg-box-body.png +0 -0
  79. data/public/images/bg-box-bottom.gif +0 -0
  80. data/public/images/bg-box-bottom.png +0 -0
  81. data/public/images/bg-box-top.gif +0 -0
  82. data/public/images/bg-box-top.png +0 -0
  83. data/public/images/cluetip/arrowdown.gif +0 -0
  84. data/public/images/cluetip/arrowleft.gif +0 -0
  85. data/public/images/cluetip/arrowright.gif +0 -0
  86. data/public/images/cluetip/arrowup.gif +0 -0
  87. data/public/images/cluetip/bl.gif +0 -0
  88. data/public/images/cluetip/bl.png +0 -0
  89. data/public/images/cluetip/br.gif +0 -0
  90. data/public/images/cluetip/br.png +0 -0
  91. data/public/images/cluetip/darrowdown.gif +0 -0
  92. data/public/images/cluetip/darrowleft.gif +0 -0
  93. data/public/images/cluetip/darrowright.gif +0 -0
  94. data/public/images/cluetip/darrowup.gif +0 -0
  95. data/public/images/cluetip/itunes.png +0 -0
  96. data/public/images/cluetip/rarrowdown.gif +0 -0
  97. data/public/images/cluetip/rarrowleft.gif +0 -0
  98. data/public/images/cluetip/rarrowright.gif +0 -0
  99. data/public/images/cluetip/rarrowup.gif +0 -0
  100. data/public/images/cluetip/tl.gif +0 -0
  101. data/public/images/cluetip/tl.png +0 -0
  102. data/public/images/cluetip/tr.gif +0 -0
  103. data/public/images/cluetip/tr.png +0 -0
  104. data/public/images/cluetip/wait.gif +0 -0
  105. data/public/images/dialog-error.png +0 -0
  106. data/public/images/dialog-help.png +0 -0
  107. data/public/images/dialog-information.png +0 -0
  108. data/public/images/dialog-warning.png +0 -0
  109. data/public/images/ui-bg_flat_55_fcf0ba_40x100.png +0 -0
  110. data/public/images/ui-bg_glass_10_136d76_1x400.png +0 -0
  111. data/public/images/ui-bg_glass_10_458845_1x400.png +0 -0
  112. data/public/images/ui-bg_highlight-hard_100_f5f3e5_1x100.png +0 -0
  113. data/public/images/ui-bg_highlight-hard_100_fafaf4_1x100.png +0 -0
  114. data/public/images/ui-bg_highlight-soft_50_136d76_1x100.png +0 -0
  115. data/public/images/ui-bg_inset-soft_15_386b3d_1x100.png +0 -0
  116. data/public/images/ui-icons_4c9052_256x240.png +0 -0
  117. data/public/images/ui-icons_847e71_256x240.png +0 -0
  118. data/public/javascripts/dcmgr_gui/account_panel.js +6 -0
  119. data/public/javascripts/dcmgr_gui/application.js +78 -5
  120. data/public/javascripts/dcmgr_gui/core.js +409 -102
  121. data/public/javascripts/dcmgr_gui/dashboard_panel.js +12 -3
  122. data/public/javascripts/dcmgr_gui/host_pool_panel.js +1 -1
  123. data/public/javascripts/dcmgr_gui/image_panel.js +119 -65
  124. data/public/javascripts/dcmgr_gui/instance_panel.js +86 -44
  125. data/public/javascripts/dcmgr_gui/security_group_panel.js +135 -77
  126. data/public/javascripts/dcmgr_gui/snapshot_panel.js +119 -61
  127. data/public/javascripts/dcmgr_gui/sshkeypair_panel.js +71 -47
  128. data/public/javascripts/dcmgr_gui/storage_pool_panel.js +10 -10
  129. data/public/javascripts/dcmgr_gui/volume_panel.js +311 -155
  130. data/public/javascripts/jquery.cluetip.min.js +33 -0
  131. data/public/javascripts/jquery.easing.1.3.js +205 -0
  132. data/public/javascripts/jquery.hoverIntent.js +114 -0
  133. data/public/javascripts/jquery.i18n.properties-min.js +7 -0
  134. data/public/javascripts/jquery.jBreadCrumb.1.1.js +240 -0
  135. data/public/javascripts/sexyalertbox.v1.2.jquery.js +414 -0
  136. data/public/javascripts/ui.selectmenu.js +541 -0
  137. data/public/stylesheets/BreadCrumb.css +109 -0
  138. data/public/stylesheets/common.css +146 -86
  139. data/public/stylesheets/dialog.css +7 -7
  140. data/public/stylesheets/jquery-ui-1.8.4.custom.css +41 -40
  141. data/public/stylesheets/jquery.cluetip.css +179 -0
  142. data/public/stylesheets/sexyalertbox.css +67 -0
  143. data/public/stylesheets/ui.selectmenu.css +24 -0
  144. data/test/functional/{images_controller_test.rb → machine_images_controller_test.rb} +1 -1
  145. data/test/unit/helpers/machine_images_helper_test.rb +4 -0
  146. metadata +350 -221
  147. data/README +0 -256
  148. data/app/api/auth_server.rb +0 -28
  149. data/app/helpers/images_helper.rb +0 -2
  150. data/app/views/information/index.html.erb +0 -25
  151. data/app/views/layouts/_service_health.erb +0 -27
  152. data/test/unit/helpers/images_helper_test.rb +0 -4
@@ -14,12 +14,12 @@ jQuery(function($){
14
14
  </style>
15
15
  <% end %>
16
16
  <div id="mainarea_wide">
17
- <h3><img src="images/icon_resource.gif" />Key Pairs<a href="#" class="showhide"></a></h3>
17
+ <h3><img src="images/icon_resource.gif" /><%= t('keypairs.header') %><a href="#" class="showhide"></a></h3>
18
18
  <div id="list_load_mask" class="maincontent">
19
19
  <div class="controller clearfix">
20
- <a href="javascript:void(0);" class="create_ssh_keypair">Create Key Pair</a>
21
- <a href="javascript:void(0);" class="delete_ssh_keypair">Delete</a>
22
- <a href="javascript:void(0);" class="refresh">Refresh</a>
20
+ <a href="javascript:void(0);" class="create_ssh_keypair"><%= t('keypairs.button.create_keypair') %></a>
21
+ <a href="javascript:void(0);" class="delete_ssh_keypair"><%= t('keypairs.button.delete_keypair') %></a>
22
+ <a href="javascript:void(0);" class="refresh" style="margin-left:-9px"><%= t('button.refresh') %></a>
23
23
  </div>
24
24
  <div class="controller clearfix">
25
25
  <!-- <div class="l_float">
@@ -31,7 +31,7 @@ jQuery(function($){
31
31
  </div> -->
32
32
  <div id="pagenate" class="r_float">
33
33
  <a href="javascript:void(0);" class="prev"></a>
34
- <p id="viewPagenate">Items</p>
34
+ <p id="viewPagenate"></p>
35
35
  <a href="javascript:void(0);" class="next"></a>
36
36
  </div>
37
37
  </div>
@@ -41,8 +41,8 @@ jQuery(function($){
41
41
  <table class="ptn04" frame="void" cellpadding="0" cellspacing="0" border="0">
42
42
  <tr>
43
43
  <th class="icon"></th>
44
- <th>Access Key ID</th>
45
- <th class="show_key">Secret Access Key</th>
44
+ <th><%= t('keypairs.list.access_key_id') %></th>
45
+ <th class="header_show_key"><%= t('keypairs.list.secret_access_key') %></th>
46
46
  </tr>
47
47
  {{each(index,item) rows}}
48
48
  <tr>
@@ -55,9 +55,9 @@ jQuery(function($){
55
55
  <td>
56
56
  {{if item.uuid }}
57
57
  {{if item.private_key}}
58
- <a id="button_${item.uuid}" href="javascript:void(0);" class="show_key">Show Secret Access Key</a>
58
+ <a id="button_${item.uuid}" href="javascript:void(0);" class="show_key"><%= t('keypairs.button.show_secret_accesskey') %></a>
59
59
  {{else}}
60
- <a href="javascript:void(0);" class="show_key">Show Secret Access Key</a>
60
+ <a href="javascript:void(0);" class="show_key"><%= t('keypairs.button.show_secret_accesskey') %></a>
61
61
  {{/if}}
62
62
  {{/if}}
63
63
  </td>
@@ -69,7 +69,7 @@ jQuery(function($){
69
69
  </div>
70
70
  </div>
71
71
  <div id="btm_maincontent_wide"></div>
72
- <h3><img src="images/icon_ttl_detail.gif" />Detail<a href="javascript:void(0);" class="showhide"></a></h3>
72
+ <h3><img src="images/icon_ttl_detail.gif" /><%= t('keypairs.details.header') %><a href="javascript:void(0);" class="showhide"></a></h3>
73
73
  <div id="detail" class="maincontent">
74
74
  <% content_for :javascript_template do %>
75
75
  <script id="sshKeypairsDetailTemplate" type="text/x-jquery-tmpl">
@@ -77,22 +77,22 @@ jQuery(function($){
77
77
  <table class="ptn08" frame="void" cellpadding="0" cellspacing="0" border="0">
78
78
  <tr>
79
79
  <td class="padcell"></td>
80
- <td class="title">Name:</td>
80
+ <td class="title"><%= t('keypairs.details.name') %>:</td>
81
81
  <td colspan="7">${item.name}</td>
82
82
  </tr>
83
83
  <tr>
84
84
  <td class="padcell"></td>
85
- <td class="title">Fingerprint:</td>
86
- <td colspan="7"></td>
85
+ <td class="title"><%= t('keypairs.details.fingerprint') %>:</td>
86
+ <td colspan="7">${item.finger_print}</td>
87
87
  </tr>
88
88
  <tr>
89
89
  <td class="padcell"></td>
90
- <td class="title">Created:</td>
90
+ <td class="title"><%= t('keypairs.details.created_at') %>:</td>
91
91
  <td colspan="7">${item.created_at}</td>
92
92
  </tr>
93
93
  <tr>
94
94
  <td class="padcell"></td>
95
- <td class="title">Updated:</td>
95
+ <td class="title"><%= t('keypairs.details.updated_at') %>:</td>
96
96
  <td colspan="7">${item.updated_at}</td>
97
97
  </tr>
98
98
  </table>
@@ -101,4 +101,4 @@ jQuery(function($){
101
101
  <% end %>
102
102
  </div><!-- maincontent -->
103
103
  <div id="btm_maincontent_wide_last"></div>
104
- </div>
104
+ </div>
@@ -1,14 +1,14 @@
1
1
  <div id="header">
2
- <h1><a href="/">Wakame Inexhaustible Supply of Cloud Fuel.</a></h1>
2
+ <h1><a href="/"><%= @site[:logo] %></a></h1>
3
3
  <ul id="tab">
4
4
  <li class="infra-act"><h2><a href="#">Infrastructure</a></h2></li>
5
5
  <li class="plat-pas"><h2>Platform</h2></li>
6
6
  <li class="app-pas"><h2>Application</h2></li>
7
7
  </ul>
8
- <p><span class="greeting">Welcome,
9
- <%= @current_user.login_id %></span>|
10
- <!-- <a href="#">Help</a><span class="spacer">|</span> -->
11
- <!-- <a href="#">Settings</a><span class="spacer">|</span> -->
12
- <%= link_to 'Sign Out','/logout'%></p>
8
+ <p>
9
+ <span class="greeting"><%= t("header.welcome_message") %>
10
+ <%= @current_user.login_id %><%= t("header.login_name_suffix") %>&nbsp;|&nbsp;<%= link_to(t("header.settings"), '/accounts') %>&nbsp;|&nbsp;<%= link_to t("header.sign_out"),'/logout'%>
11
+ </span>
12
+ </p>
13
13
  </div>
14
14
  <div id="content_header"></div>
@@ -1,6 +1,6 @@
1
1
  <div id="informationarea">
2
2
  <div class="title clearfix">
3
- <h3>Information</h3>
3
+ <h3><%= t("information.header") %></h3>
4
4
  <%= link_to image_tag('icon_rss.gif',:width=> 20, :height => 20),:action => 'rss',:controller => 'information' %>
5
5
  </div>
6
6
  <ul>
@@ -8,11 +8,11 @@
8
8
  <li>
9
9
  <h4 class="date"><%= info.created_at.strftime("%Y-%m-%d")
10
10
  %></h4>
11
- <h2><%= info.title %></h2>
12
- <p>
13
- <%= nl2br(info.description) %>
11
+ <h2><%= link_to info.title, info.link, {'target' => '_blank'} %></h2>
12
+ <p style="margin-top:3px">
13
+ <%= nl2br(info.description) %>
14
14
  </p>
15
15
  </li>
16
16
  <% end %>
17
17
  </ul>
18
- </div>
18
+ </div>
@@ -1,4 +1,4 @@
1
1
  <div id="header">
2
- <h1><a href="#">Wakame Inexhaustible Supply of Cloud Fuel.</a></h1>
2
+ <h1><a href="#"><%= @site[:logo] %></a></h1>
3
3
  </div>
4
4
  <div id="content_header"></div>
@@ -1,58 +1,60 @@
1
1
  <div id="sidemenu">
2
2
  <div id="account" style="padding:5px">
3
3
  <%= form_for :accounts,:url => accounts_switch_path,:remote => true do |f| %>
4
- Change Account:&nbsp;<%= f.select "account_uuid",show_accounts,{:selected => primary_account_id} %>
4
+ <%= t('sidemenu.change_account') %>:&nbsp;<%= f.select "account_uuid",show_accounts,{:selected => primary_account_id} %>
5
5
  <% end %>
6
+ <div style="margin-top:10px">
7
+ <%= t('sidemenu.change_language') %>:&nbsp;
8
+ <%= form_for :select_language, :remote => false, :url => request.url, :html => {:id => :select_language, :method => :get,:style => "display: inline"} do |f| %>
9
+ <%= f.select(:locale, @locales, :selected => @locale) %>
10
+ <% end %>&nbsp;
11
+ </div>
12
+
6
13
  </div>
7
-
8
- <!-- <div id="regionselect"><img src="images/listicon_useast.gif" />US East</div>
9
- <ul id="regionmenu">
10
- <li><a href="#" id="list-useast"><img src="images/listicon_useast.gif" />US East</a></li>
11
- <li><a href="#" id="list-japan"><img src="images/listicon_useast.gif" />Japan</a></li>
12
- </ul> -->
14
+ <fieldset>
15
+ <select name="regionmenu" id="regionmenu">
16
+ <option value=""><%= t("selectmenu.select_region") %><%= t("selectmenu.select_region_first") %></option>
17
+ </select>
18
+ </fieldset>
13
19
  <div class="sidemenu_top"></div><ul class="classify_parent">
14
- <li class="parent"><h3><img src="images/icon_summary.gif" width="20" height="20" />SUMMARY</h3>
20
+ <li class="parent"><h3><img src="/images/icon_summary.gif" width="20" height="20" /><%= t("sidemenu.summary.header") %></h3>
15
21
  <ul>
16
- <%= li_link_to_current('Dashboard','home')%>
22
+ <%= li_link_to_current(t("sidemenu.summary.dashboard"), 'home', 'index')%>
17
23
  </ul>
18
24
  </li>
19
- <li class="parent"><h3><img src="images/icon_instances.gif" width="20" height="20" />INSTANCES</h3>
25
+ <li class="parent"><h3><img src="/images/icon_instances.gif" width="20" height="20" /><%= t("sidemenu.instances.header") %></h3>
20
26
  <ul>
21
- <%= li_link_to_current('Instances','instances')%>
27
+ <%= li_link_to_current(t("sidemenu.instances.instances"), 'instances', 'index')%>
22
28
  </ul>
23
29
  <ul>
24
- <%= li_link_to_current('Host Pools','host_pools')%>
30
+ <%= li_link_to_current(t("sidemenu.instances.host_pools"), 'host_pools', 'index')%>
25
31
  </ul>
26
32
  </li>
27
- <li class="parent"><h3><img src="images/icon_images.gif" width="20" height="20" />IMAGES</h3>
33
+ <li class="parent"><h3><img src="/images/icon_images.gif" width="20" height="20" /><%= t("sidemenu.images.header") %></h3>
28
34
  <ul>
29
- <%= li_link_to_current('Machine Images','images')%>
35
+ <%= li_link_to_current(t("sidemenu.images.machine_images"), 'machine_images', 'index')%>
30
36
  </ul>
31
37
  </li>
32
- <li class="parent"><h3><img src="images/icon_blockstore.gif" width="20" height="20" />BLOCK STORE</h3>
38
+ <li class="parent"><h3><img src="/images/icon_blockstore.gif" width="20" height="20" /><%= t("sidemenu.block_store.header") %></h3>
33
39
  <ul>
34
- <%= li_link_to_current('Volumes','volumes')%>
40
+ <%= li_link_to_current(t("sidemenu.block_store.volumes"), 'volumes', 'index')%>
35
41
  </ul>
36
42
  <ul>
37
- <%= li_link_to_current('Snapshots','snapshots')%>
43
+ <%= li_link_to_current(t("sidemenu.block_store.snapshots"), 'snapshots', 'index')%>
38
44
  </ul>
39
45
  <ul>
40
- <%= li_link_to_current('Storage Pools','storage_pools')%>
46
+ <%= li_link_to_current(t("sidemenu.block_store.storage_pools"), 'storage_pools', 'index')%>
41
47
  </ul>
42
48
  </li>
43
- <li class="parent"><h3><img src="images/icon_security.gif" width="20" height="20" />NETWORK & SECURITY</h3>
49
+ <li class="parent"><h3><img src="/images/icon_security.gif" width="20" height="20" /><%= t("sidemenu.network_security.header") %></h3>
44
50
  <ul>
45
- <%= li_link_to_current('Security Groups','security_groups')%>
51
+ <%= li_link_to_current(t("sidemenu.network_security.security_groups"), 'security_groups', 'index')%>
46
52
  </ul>
47
53
  <ul>
48
- <%= li_link_to_current('Key Pairs','keypairs')%>
54
+ <%= li_link_to_current(t("sidemenu.network_security.key_pairs"), 'keypairs', 'index')%>
49
55
  </ul>
50
56
  </li>
51
- <!-- <li class="parent"><h3><img src="images/icon_information.gif" width="20" height="20" />INFORMATION</h3>
52
- <ul>
53
- <%= li_link_to_current('Service Status','information')%>
54
- </ul>
55
- </li> -->
56
57
  </ul>
57
- <div class="sidemenu_bottom"></div>
58
- </div>
58
+ <div class="sidemenu_bottom">
59
+ </div>
60
+ </div>
@@ -4,17 +4,33 @@
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <meta http-equiv="Content-Style-Type" content="text/css" />
6
6
  <meta name="keywords" content="あくしゅ,axsh,wakame" />
7
- <meta name="description" content="Wakame UI">
8
- <title>Wakame UI</title>
7
+ <meta name="description" content="<%= @site[:meta][:description] %>">
8
+ <title><%= @site[:title] %></title>
9
9
  <%= stylesheet_link_tag :all %>
10
10
  <%= yield :stylesheet %>
11
11
  <%= javascript_include_tag 'jquery-1.4.2.min.js' %>
12
+ <%= javascript_include_tag 'jquery.i18n.properties-min.js' %>
12
13
  <%= javascript_include_tag 'jsdeferred.jquery.js' %>
13
14
  <%= javascript_include_tag 'jquery.tmpl.js' %>
14
15
  <%= javascript_include_tag 'jquery.loadmask.min.js' %>
15
16
  <%= javascript_include_tag 'jquery-ui-1.8.4.custom.min.js' %>
17
+ <%= javascript_include_tag 'jquery.easing.1.3.js' %>
18
+ <%= javascript_include_tag 'sexyalertbox.v1.2.jquery.js' %>
19
+ <%= javascript_include_tag 'ui.selectmenu.js' %>
16
20
  <%= javascript_include_tag 'dcmgr_gui/core.js' %>
17
21
  <%= javascript_include_tag 'dcmgr_gui/application.js' %>
22
+ <script type="text/javascript">
23
+ jQuery(function($){
24
+ $.i18n.properties({
25
+ name:'Messages',
26
+ path:'/i18n/',
27
+ mode:'both',
28
+ language: '<%= I18n.locale %>'
29
+ });
30
+ dcmgrGUI.setConfig('time_zone', '<%= @current_user.time_zone %>');
31
+ dcmgrGUI.setConfig('time_zone_utc_offset', <%= ActiveSupport::TimeZone[@current_user.time_zone].utc_offset %>);
32
+ });
33
+ </script>
18
34
  <%= yield :javascript %>
19
35
  <%= csrf_meta_tag %>
20
36
  <link rel="shortcut icon" href="favicon.ico" />
@@ -31,4 +47,4 @@
31
47
  </div>
32
48
  <%= yield :javascript_template %>
33
49
  </body>
34
- </html>
50
+ </html>
@@ -3,9 +3,9 @@
3
3
  <head>
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <meta http-equiv="Content-Style-Type" content="text/css" />
6
- <meta name="keywords" content="あくしゅ,axsh,wakame" />
7
- <meta name="description" content="Wakame UI">
8
- <title>Wakame UI</title>
6
+ <meta name="keywords" content="<%= @site[:meta][:keywords] %>" />
7
+ <meta name="description" content="<%= @site[:meta][:description] %>">
8
+ <title><%= @site[:title] %></title>
9
9
  <%= stylesheet_link_tag :all %>
10
10
  <%= csrf_meta_tag %>
11
11
  <%= yield :javascript %>
@@ -22,4 +22,4 @@
22
22
  <%= render :partial => 'layouts/footer'%>
23
23
  </div>
24
24
  </body>
25
- </html>
25
+ </html>
@@ -15,28 +15,16 @@ jQuery(function($){
15
15
  <% end %>
16
16
 
17
17
  <div id="mainarea_wide">
18
- <h3><img src="images/icon_resource.gif" />Machine Images<a href="javascript:void(0);" class="showhide"></a></h3>
18
+ <h3><img src="images/icon_resource.gif" /><%= t("machine_images.header") %><a href="javascript:void(0);" class="showhide"></a></h3>
19
19
  <div id="list_load_mask" class="maincontent">
20
20
  <div class="controller clearfix">
21
- <a href="javascript:void(0);" class="launch_instance">Launch Instance</a>
22
- <!-- <a href="javascript:void(0);" class="register_new_ami">Register New AMI</a> -->
23
- <!-- <a href="javascript:void(0);" class="de_register">De-register</a> -->
24
- <a href="javascript:void(0);" class="refresh" style="margin-left:470px">Refresh</a>
21
+ <a href="javascript:void(0);" class="launch_instance"><%= t("machine_images.button.launch_instance") %></a>
22
+ <a href="javascript:void(0);" class="refresh" style="margin-left:463px"><%= t("button.refresh") %></a>
25
23
  </div>
26
24
  <div class="controller clearfix">
27
- <!-- <div class="l_float">
28
- <span class="text">Viewing:</span>
29
- <select class="select">
30
- <option>Owned By Me</option>
31
- </select>
32
- <select class="type">
33
- <option>All Platforms</option>
34
- </select>
35
- <input type="text" class="search" />
36
- </div> -->
37
25
  <div id="pagenate" class="r_float">
38
26
  <a href="javascript:void(0);" class="prev"></a>
39
- <p id="viewPagenate">WMIs</p>
27
+ <p id="viewPagenate"></p>
40
28
  <a href="javascript:void(0);" class="next"></a>
41
29
  </div>
42
30
  </div>
@@ -46,10 +34,10 @@ jQuery(function($){
46
34
  <table class="ptn01" frame="void" cellpadding="0" cellspacing="0" border="0">
47
35
  <tr>
48
36
  <th></th>
49
- <th>WMI ID</th>
50
- <th>Source</th>
51
- <th>Owner</th>
52
- <th>State</th>
37
+ <th><%= t("machine_images.list.wmi_id") %></th>
38
+ <th><%= t("machine_images.list.description") %></th>
39
+ <th><%= t("machine_images.list.owner") %></th>
40
+ <th><%= t("machine_images.list.state") %></th>
53
41
  </tr>
54
42
  {{each(index,item) rows}}
55
43
  <tr>
@@ -59,10 +47,8 @@ jQuery(function($){
59
47
  <td class="listradiobutton"></td>
60
48
  {{/if}}
61
49
  <td class="vtip" title="title">${item.uuid}</td>
62
- <td class="vtip" title="source" style="width:300px">
63
- {{each(index,source) item.source}}
64
- ${source.uri}
65
- {{/each}}
50
+ <td class="vtip" title="description" style="width:300px">
51
+ ${item.description}
66
52
  </td>
67
53
  <td class="vtip" title="owner">${item.account_id}</td>
68
54
  <td class="vtip center" title="state">${item.state}</td>
@@ -74,47 +60,42 @@ jQuery(function($){
74
60
  </div>
75
61
  </div>
76
62
  <div id="btm_maincontent_wide"></div>
77
- <h3><img src="images/icon_ttl_detail.gif" />Details<a href="javascript:void(0);" class="showhide"></a></h3>
63
+ <h3><img src="images/icon_ttl_detail.gif" /><%= t("machine_images.details.header") %><a href="javascript:void(0);" class="showhide"></a></h3>
78
64
  <div id="detail" class="maincontent">
79
65
  <% content_for :javascript_template do %>
80
66
  <script id="imagesDetailTemplate" type="text/x-jquery-tmpl">
81
67
  <div id="${item.wmi_id}" class="display_area">
82
- <h4 class="ptn01">WMI ID:<span class="instansid">${item.uuid}</span></h4>
68
+ <h4 class="ptn01"><%= t("machine_images.details.wmi_id") %>:<span class="instansid">${item.uuid}</span></h4>
83
69
  <table class="ptn06" frame="void" cellpadding="0" cellspacing="0" border="0">
84
70
  <tr>
85
71
  <td class="padcell"></td>
86
- <td class="title">WMI ID:</td>
72
+ <td class="title"><%= t("machine_images.details.wmi_id") %>:</td>
87
73
  <td colspan="7">${item.uuid}</td>
88
74
  </tr>
89
75
  <tr>
90
76
  <td class="padcell"></td>
91
- <td class="title">Description:</td>
77
+ <td class="title"><%= t("machine_images.details.description") %>:</td>
92
78
  <td colspan="7">${item.description}</td>
93
79
  </tr>
94
80
  <tr>
95
81
  <td class="padcell"></td>
96
- <td class="title">Source:</td>
97
- <td colspan="7">${item.source.uri}</td>
98
- </tr>
99
- <tr>
100
- <td class="padcell"></td>
101
- <td class="title">Owner:</td>
82
+ <td class="title"><%= t("machine_images.details.owner") %>:</td>
102
83
  <td>${item.account_id}</td>
103
84
  <td class="padcell"></td>
104
- <td class="title">Arch:</td>
85
+ <td class="title"><%= t("machine_images.details.arch") %>:</td>
105
86
  <td>${item.arch}</td>
106
87
  <td class="padcell"></td>
107
- <td class="title">Status:</td>
88
+ <td class="title"><%= t("machine_images.details.status") %>:</td>
108
89
  <td>${item.state}</td>
109
90
  </tr>
110
91
  <tr>
111
92
  <td class="padcell"></td>
112
- <td class="title">Created At:</td>
93
+ <td class="title"><%= t("machine_images.details.created_at") %>:</td>
113
94
  <td colspan="7">${item.created_at}</td>
114
95
  </tr>
115
96
  <tr>
116
97
  <td class="padcell"></td>
117
- <td class="title">Updated At:</td>
98
+ <td class="title"><%= t("machine_images.details.updated_at") %>:</td>
118
99
  <td colspan="7">${item.updated_at}</td>
119
100
  </tr>
120
101
  </table>
@@ -123,4 +104,4 @@ jQuery(function($){
123
104
  <% end %>
124
105
  </div><!-- maincontent -->
125
106
  <div id="btm_maincontent_wide_last"></div>
126
- </div><!-- mainarea_wide -->
107
+ </div><!-- mainarea_wide -->
@@ -1,5 +1,8 @@
1
1
  <% content_for :javascript do %>
2
2
  <%= javascript_include_tag 'dcmgr_gui/security_group_panel.js' %>
3
+ <%= javascript_include_tag 'jquery.cluetip.min.js' %>
4
+ <%= javascript_include_tag 'jquery.hoverIntent.js' %>
5
+
3
6
  <script type="text/javascript">
4
7
  jQuery(function($){
5
8
  dcmgrGUI.securityGroupPanel();
@@ -9,6 +12,7 @@ jQuery(function($){
9
12
  <% end %>
10
13
 
11
14
  <% content_for :stylesheet do %>
15
+ <%= stylesheet_link_tag 'jquery.cluetip.css' %>
12
16
  <style type="text/css">
13
17
  .ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset { text-align:center; float: none;}
14
18
  .ui-dialog .ui-dialog-content {margin:5px;}
@@ -16,24 +20,17 @@ jQuery(function($){
16
20
  <% end %>
17
21
 
18
22
  <div id="mainarea_wide">
19
- <h3><img src="images/icon_resource.gif" />Security Groups<a href="javascript:void(0);" class="showhide"></a></h3>
23
+ <h3><img src="images/icon_resource.gif" /><%= t("security_groups.header") %><a href="javascript:void(0);" class="showhide"></a></h3>
20
24
  <div id="list_load_mask" class="maincontent">
21
25
  <div class="controller clearfix">
22
- <a href="javascript:void(0);" class="create_security_group">Create Security Group</a>
23
- <a href="javascript:void(0);" class="delete_security_group" >Delete</a>
24
- <a href="javascript:void(0);" class="refresh" style="margin-left:302px">Refresh</a>
26
+ <a href="javascript:void(0);" class="create_security_group"><%= t("security_groups.button.create_security_group") %></a>
27
+ <a href="javascript:void(0);" class="delete_security_group" ><%= t("security_groups.button.delete_security_group") %></a>
28
+ <a href="javascript:void(0);" class="refresh" style="margin-left:585px"><%= t("button.refresh") %></a>
25
29
  </div>
26
30
  <div class="controller clearfix">
27
- <!-- <div class="l_float">
28
- <span class="text">Viewing:</span>
29
- <select class="select" style="width:130px">
30
- <option>All Security Groups</option>
31
- </select>
32
- <input type="text" class="search" />
33
- </div> -->
34
31
  <div id="pagenate" class="r_float">
35
32
  <a href="javascript:void(0);" class="prev"></a>
36
- <p id="viewPagenate">Items</p>
33
+ <p id="viewPagenate"></p>
37
34
  <a href="javascript:void(0);" class="next"></a>
38
35
  </div>
39
36
  </div>
@@ -43,9 +40,9 @@ jQuery(function($){
43
40
  <table class="ptn01" frame="void" cellpadding="0" cellspacing="0" border="0">
44
41
  <tr>
45
42
  <th></th>
46
- <th>Name</th>
47
- <th>Description</th>
48
- <th>Action</th>
43
+ <th><%= t("security_groups.list.name") %></th>
44
+ <th><%= t("security_groups.list.descriptions") %></th>
45
+ <th><%= t("security_groups.list.action") %></th>
49
46
  </tr>
50
47
  {{each(index,item) rows}}
51
48
  <tr>
@@ -54,11 +51,11 @@ jQuery(function($){
54
51
  {{else}}
55
52
  <td class="listradiobutton"></td>
56
53
  {{/if}}
57
- <td class="vtip" title="name" style="width:100px">${item.name}</td>
54
+ <td class="vtip" title="name" style="width:130px">${item.name}</td>
58
55
  <td class="vtip" title="description" style="width:500px">${item.description}</td>
59
56
  {{if item.name }}
60
57
  <td class="vtip center" title="action">
61
- <a href="javascript:void(0);" class="edit_security_group" id="edit_${item.uuid}">Edit</a>
58
+ <a href="javascript:void(0);" class="edit_security_group" id="edit_${item.uuid}"><%= t("security_groups.button.edit_security_group") %></a>
62
59
  </td>
63
60
  {{else}}
64
61
  <td class="vtip center" title="action"></td>
@@ -72,7 +69,7 @@ jQuery(function($){
72
69
  </div>
73
70
  </div>
74
71
  <div id="btm_maincontent_wide"></div>
75
- <h3><img src="images/icon_ttl_detail.gif" />Detail<a href="javascript:void(0);" class="showhide"></a></h3>
72
+ <h3><img src="images/icon_ttl_detail.gif" /><%= t("security_groups.details.header") %><a href="javascript:void(0);" class="showhide"></a></h3>
76
73
  <div id="detail" class="maincontent">
77
74
  <% content_for :javascript_template do %>
78
75
  <script id="securityGroupsDetailTemplate" type="text/x-jquery-tmpl">
@@ -80,12 +77,12 @@ jQuery(function($){
80
77
  <table class="ptn07" frame="void" cellpadding="0" cellspacing="0" border="0">
81
78
  <tr>
82
79
  <td class="padcell"></td>
83
- <td class="title">Name:</td>
80
+ <td class="title"><%= t("security_groups.details.name") %>:</td>
84
81
  <td>${item.name}</td>
85
82
  </tr>
86
83
  <tr>
87
84
  <td class="padcell"></td>
88
- <td class="title">Description:</td>
85
+ <td class="title"><%= t("security_groups.details.description") %>:</td>
89
86
  <td>${item.description}</td>
90
87
  </tr>
91
88
  <tr>
@@ -96,12 +93,12 @@ jQuery(function($){
96
93
  </tr>
97
94
  <tr>
98
95
  <td class="padcell"></td>
99
- <td class="title">Created:</td>
96
+ <td class="title"><%= t("security_groups.details.created_at") %>:</td>
100
97
  <td colspan="7">${item.created_at}</td>
101
98
  </tr>
102
99
  <tr>
103
100
  <td class="padcell"></td>
104
- <td class="title">Updated:</td>
101
+ <td class="title"><%= t("security_groups.details.updated_at") %>:</td>
105
102
  <td colspan="7">${item.updated_at}</td>
106
103
  </tr>
107
104
  </table>
@@ -111,4 +108,4 @@ jQuery(function($){
111
108
  <% end %>
112
109
  </div><!-- maincontent -->
113
110
  <div id="btm_maincontent_wide_last"></div>
114
- </div><!-- mainarea_wide -->
111
+ </div><!-- mainarea_wide -->