menu alt name

This commit is contained in:
Nweni
2017-07-02 14:38:18 +06:30
16 changed files with 205 additions and 63 deletions

View File

@@ -47,11 +47,15 @@
<tbody>
<% @i = 0 %>
<% @crm_customers.each do |crm_customer| %>
<% if crm_customer.customer_id != "CUS-00001" && crm_customer.customer_id != "CUS-000000000" %>
<tr class="customer_tr" data-ref="<%= crm_customer.customer_id %>">
<td>
<input type="radio" style="width:20px;" name="checkbox" class="checkbox_check" ></td>
<td><%= @i += 1 %></td>
<td>
<% if crm_customer.customer_id != "CUS-000000000001" && crm_customer.customer_id != "CUS-000000000002" %>
<%= @i += 1 %>
<% end %>
</td>
<td><%= crm_customer.name %></td>
<td><%= crm_customer.card_no rescue '-' %></td>
<td><%= crm_customer.contact_no %></td>
@@ -59,7 +63,7 @@
<td><%= link_to 'Show', crm_customer_path(crm_customer) %></td>
</tr>
<% end %>
<% end %>
</tbody>

View File

@@ -32,6 +32,7 @@
<th>NRC/Passport No</th>
<th>Address</th>
<th>DOB</th>
<th>Membership Type</th>
</tr>
</thead>
@@ -45,8 +46,16 @@
<td><%= @customer.nrc_no %></td>
<td><%= @customer.address%></td>
<td><%= @customer.date_of_birth %></td>
<% if @customer.membership_type.to_f > 0%>
<td><%lookup= Lookup.find_by_value(@customer.membership_type) %>
<%= lookup.name %>
</td>
<%else%>
<td>-</td>
<%end%>
</tr>
<tr><th colspan="8"></th></tr>
<tr><th colspan="9"></th></tr>
</tbody>
</table>
@@ -55,21 +64,19 @@
<div class="table-responsive">
<table class="table table-striped">
<thead>
<%
if @response["data"].present? %>
<tr>
<th colspan="5">Membership Transactions</th>
<% if @response["status"] == true %>
<th>Current Balance : <%= @response["data"].last["balance"]%></th>
<% end %>
<th>Current Balance : <%= @balance%></th>
</tr>
<% end %>
<tr>
<th>Date</th>
<th>Redeem</th>
<th>Rebate</th>
<th>Balance</th>
<!-- <th>Account No</th> -->
<th>From Account</th>
<th>Status</th>
<th>Receipt No</th>
</tr>
@@ -82,7 +89,7 @@
<td><%= transaction["redeem"]%></td>
<td><%= transaction["rebate"] %></td>
<td><%= transaction["balance"] %></td>
<!-- <td><%= transaction["account_no"] %></td> -->
<td><%= transaction["account_status"] %></td>
<td><%= transaction["status"] %></td>
<td><%= transaction["receipt_no"] %></td>

View File

@@ -41,11 +41,15 @@
<% if @crm_customers.count > 0 %>
<% @i = 0 %>
<% @crm_customers.each do |crm_customer| %>
<% if crm_customer.customer_id != "CUS-00000" && crm_customer.customer_id != "CUS-00000000" %>
<tr class="customer_tr" data-ref="<%= crm_customer.customer_id %>">
<td>
<input type="radio" style="width:20px;" name="checkbox" class="checkbox_check" ></td>
<td><%= @i += 1 %></td>
<td>
<% if crm_customer.customer_id != "CUS-000000000001" && crm_customer.customer_id != "CUS-000000000002" %>
<%= @i += 1 %>
<% end %>
</td>
<td><%= crm_customer.name %></td>
<td><%= crm_customer.company rescue '-' %></td>
<td><%= crm_customer.contact_no %></td>
@@ -53,7 +57,6 @@
</tr>
<% end %>
<% end %>
<%else%>
<tr><td colspan="5"><p style="text-align:center"><strong>There are no record for your search</strong></p></td></tr>
@@ -155,10 +158,10 @@
<%= f.input :address, :class => "form-control col-md-6 address" %>
</div>
<!-- <div class="form-group">
<div class="form-group">
<label>Sr.No</label>
<input type="text" name="" value="<%=@count_customer%>" class="form-control" readonly="true">
</div> -->
</div>
<div class="form-group">
<label>Date Of Birth</label>
<%= f.text_field :date_of_birth,:value=>"01-01-1990",:class=>"form-control datepicker"%>

View File

@@ -39,6 +39,9 @@
<li class="nav-item">
<a class="nav-link" data-toggle="tab" href="#customer" role="tab">Customer Details</a>
</li>
<!-- <li class="nav-item">
<a class="nav-link" data-toggle="tab" href="#sale_audit" role="tab">Sale Audits</a>
</li> -->
</ul>
<!-- Nav tabs - End -->
@@ -235,23 +238,31 @@
</div>
</div>
<div class="tab-pane" id="sale_audit" role="tabpanel">
<br>
<div class="table-responsive">
<table class="table table-striped">
<thead>
<tr>
<th>Status</th>
<th>Action At</th>
<th>Approved By</th>
<th>Remark</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
</div>
</div>
</div>
<!-- <div class="col-lg-2 col-md-2 col-sm-2">
<a href="<%= transactions_sales_path%>" style="margin-top: 10px " class="btn btn-primary btn-lg">
<i class="fa fa-arrow-left fa-lg"></i> Back
</a>
<a href="<%= transactions_void_path(@sale)%>" style="margin-top: 10px " class="btn btn-danger btn-lg">
<i class="fa fa-trash fa-lg"></i> Void Sale
</a>
<a href="<%= transactions_manual_complete_sale_path(@sale)%>" style="margin-top: 10px " class="btn btn-success btn-lg">
<i class="fa fa-invoice fa-lg"></i> Complete Sale
</a>
</div> -->
</div>