forked from openware/barong
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Move all logic from profile show to accounts show (close openware#449)
- Loading branch information
1 parent
033bea0
commit 592a5d4
Showing
10 changed files
with
93 additions
and
78 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<%= form_with(model: [:admin, @account, @label], local: true) do |form| %> | ||
<% if label.errors.any? %> | ||
<div class="alert alert-danger"> | ||
<h2><%= pluralize(@label.errors.count, "error") %> prohibited this label from being saved:</h2> | ||
<ul> | ||
<% @label.errors.full_messages.each do |message| %> | ||
<li><%= message %></li> | ||
<% end %> | ||
</ul> | ||
</div> | ||
<% end %> | ||
<%= form.label :key, class: 'control-label'%> | ||
<%= form.text_field :key, class: 'form-control col-sm-10'%> | ||
<br> | ||
|
||
<%= form.label :value, class: 'control-label'%> | ||
<%= form.text_field :value, class: 'form-control col-sm-10'%> | ||
<br> | ||
|
||
<%= form.label :scope, class: 'control-label'%> | ||
<%= form.select :scope, Label::SCOPES , class: 'form-control col-sm-10'%> | ||
<br> | ||
|
||
<%= form.submit 'Submit', class: 'btn btn-primary' %> | ||
|
||
<br> | ||
<br> | ||
|
||
<% end %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<div class="container"> | ||
<h1>Editing label</h1> | ||
<%= render 'form', label: @label %> | ||
<br> | ||
</div> |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters