Sha256: 1737b38e7df734f91cfb6163a0437944634681ea7f4f77f9a4886bfb9a11eafa

Contents?: true

Size: 1.47 KB

Versions: 1

Compression:

Stored size: 1.47 KB

Contents

<% form_for(@database, :url => { :action => :update, :tablename => @tablename }, :html => { :method => :put }) do |f| %>

<%#= menu %>
<div id="contents">
<%#= submenu %>

<div id="main">

<%= message %>

<%= pagetitle :title => "database [" + @tablename + "]" %>

<div class="sheet">

<%= f.error_messages %>
<%= flash_tag %>

<% content_for :button do %>
<div class="commonBtnArea">
<div class="centerBox">
<%#= delete_button_tag(Class.new(ActiveRecord::Base).set_table_name(@tablename)) %>
<%# obj = Class.new(ActiveRecord::Base).set_table_name(@tablename) %>
<%= link_to image_tag('/images/btn_delete.png', :alt => '削除', :style => 'float: right;'), {:action => :destroy}, :confirm => '削除してもよろしいですか?', :method => :delete %>
<%= submit_button_tag(f, :value => '/images/btn_update.png') %>
<%= index_button_tag %>
</div>
<!--/ commonBtnArea--></div>
<% end %>

<%#= yield :button %>

<%= pagesubtitle %>
<%= required_notice_tag %>

<table class="commonSheet">
<% @columns.each do |column| %>
<tr>
<th><%= f.label column.name %><%#=hlabel @tablename.singularize, column.name %></th>
<td>
  <% if ["id","created_at","updated_at"].include?(column.name) -%>
  <% if column.type.to_s == "datetime" -%>
  <%=hdate @database[column.name] -%>
  <% else -%>
  <%=h @database[column.name] -%>
  <% end -%>
  <% else -%>
  <%= f.text_field column.name -%>
  <% end -%>
</td>
</tr>
<% end %>
</table>

</div>

<%= yield :button %>

<!--/ #main--></div>
<!--/ #contents--></div>

<% end %>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
ava_rails_generator-0.0.3 templates/databases_edit.html.erb