Photo Field in Customer,Employee and Commissionor

This commit is contained in:
San Wai Lwin
2018-03-07 17:50:23 +06:30
parent 9f29bbef5a
commit 9ec8c4d18c
19 changed files with 360 additions and 9 deletions

View File

@@ -12,6 +12,22 @@
<%= f.input :password %>
</div>
<div class="form-inputs p-l-15">
<label>Employee Image</label>
<div class="panel padding-10">
<div class="form-group">
<div class="menu-item-img">
<% if f.object.image_path? %>
<p><%= f.object.name %></p>
<%= image_tag f.object.image_path.url, :class => "img-thumbnail" %>
<% else %>
<%= image_tag "/image/menu_images/default.png", :class => "img-thumbnail" %>
<% end %>
</div>
<%= f.file_field :image_path, :class => "img-thumbnail" %>
</div>
</div>
</div>
<div class="form-actions p-l-15">
<%= f.submit t('views.btn.submit'),:class => 'btn btn-primary btn-lg waves-effect' %>