farmitry_hvac/app/views/modbus/schedule_edit.html.erb

24 lines
747 B
Plaintext

<%= form_with url: "/modbus/schedule_edit_update", method: :post, class: 'flex flex-col h-full divide-y divide-border-table-border' do %>
<div class="flex-1 overflow-y-auto p-4">
<table class="base-table">
<thead>
<tr>
<th>시간</th>
<th>온도</th>
</tr>
</thead>
<tbody>
<% @schedule.each do |s| %>
<tr>
<td><%= s.hour %>시</td>
<td><%= number_field_tag "schedule[#{s.id}][temperature]", s.temperature, step: "0.1", inputmode: "decimal", class: "border px-2 py-1 rounded" %> °C</td>
</tr>
<% end %>
</tbody>
</table>
</div>
<div class="flex p-4">
<%= submit_tag "업데이트", class: "btn bg-primary" %>
</div>
<% end %>