scaffold models

This commit is contained in:
Min Zeya Phyo
2017-04-20 17:01:14 +06:30
parent 0a97947259
commit 0af7d78c3c
145 changed files with 4127 additions and 2 deletions

View File

@@ -0,0 +1,16 @@
<%= simple_form_for(@settings_payment_method_setting) do |f| %>
<%= f.error_notification %>
<div class="form-inputs">
<%= f.input :payment_method %>
<%= f.input :is_active %>
<%= f.input :gateway_communication_type %>
<%= f.input :gateway_url %>
<%= f.input :auth_token %>
<%= f.association :merchant_account %>
</div>
<div class="form-actions">
<%= f.button :submit %>
</div>
<% end %>

View File

@@ -0,0 +1,2 @@
json.extract! settings_payment_method_setting, :id, :payment_method, :is_active, :gateway_communication_type, :gateway_url, :auth_token, :merchant_account_id, :created_at, :updated_at
json.url settings_payment_method_setting_url(settings_payment_method_setting, format: :json)

View File

@@ -0,0 +1,6 @@
<h1>Editing Settings Payment Method Setting</h1>
<%= render 'form', settings_payment_method_setting: @settings_payment_method_setting %>
<%= link_to 'Show', @settings_payment_method_setting %> |
<%= link_to 'Back', settings_payment_method_settings_path %>

View File

@@ -0,0 +1,37 @@
<p id="notice"><%= notice %></p>
<h1>Settings Payment Method Settings</h1>
<table>
<thead>
<tr>
<th>Payment method</th>
<th>Is active</th>
<th>Gateway communication type</th>
<th>Gateway url</th>
<th>Auth token</th>
<th>Merchant account</th>
<th colspan="3"></th>
</tr>
</thead>
<tbody>
<% @settings_payment_method_settings.each do |settings_payment_method_setting| %>
<tr>
<td><%= settings_payment_method_setting.payment_method %></td>
<td><%= settings_payment_method_setting.is_active %></td>
<td><%= settings_payment_method_setting.gateway_communication_type %></td>
<td><%= settings_payment_method_setting.gateway_url %></td>
<td><%= settings_payment_method_setting.auth_token %></td>
<td><%= settings_payment_method_setting.merchant_account %></td>
<td><%= link_to 'Show', settings_payment_method_setting %></td>
<td><%= link_to 'Edit', edit_settings_payment_method_setting_path(settings_payment_method_setting) %></td>
<td><%= link_to 'Destroy', settings_payment_method_setting, method: :delete, data: { confirm: 'Are you sure?' } %></td>
</tr>
<% end %>
</tbody>
</table>
<br>
<%= link_to 'New Settings Payment Method Setting', new_settings_payment_method_setting_path %>

View File

@@ -0,0 +1 @@
json.array! @settings_payment_method_settings, partial: 'settings_payment_method_settings/settings_payment_method_setting', as: :settings_payment_method_setting

View File

@@ -0,0 +1,5 @@
<h1>New Settings Payment Method Setting</h1>
<%= render 'form', settings_payment_method_setting: @settings_payment_method_setting %>
<%= link_to 'Back', settings_payment_method_settings_path %>

View File

@@ -0,0 +1,34 @@
<p id="notice"><%= notice %></p>
<p>
<strong>Payment method:</strong>
<%= @settings_payment_method_setting.payment_method %>
</p>
<p>
<strong>Is active:</strong>
<%= @settings_payment_method_setting.is_active %>
</p>
<p>
<strong>Gateway communication type:</strong>
<%= @settings_payment_method_setting.gateway_communication_type %>
</p>
<p>
<strong>Gateway url:</strong>
<%= @settings_payment_method_setting.gateway_url %>
</p>
<p>
<strong>Auth token:</strong>
<%= @settings_payment_method_setting.auth_token %>
</p>
<p>
<strong>Merchant account:</strong>
<%= @settings_payment_method_setting.merchant_account %>
</p>
<%= link_to 'Edit', edit_settings_payment_method_setting_path(@settings_payment_method_setting) %> |
<%= link_to 'Back', settings_payment_method_settings_path %>

View File

@@ -0,0 +1 @@
json.partial! "settings_payment_method_settings/settings_payment_method_setting", settings_payment_method_setting: @settings_payment_method_setting