%# Phone numbers as (401) 555-0101, left blank when the customer has none %> <% phone = ->(number) { digits = number.to_s.gsub(/\D/, ''); digits.present? ? number_to_phone(digits.to_i, area_code: true) : '' } %>
| <%= t(:label_name) %> | <%= customer.name %> |
|---|---|
| <%= t(:label_email) %> | <%= customer.email %> |
| <%= t(:label_primary_phone) %> | <%= phone.call(customer&.primary_phone) %> |
| <%= t(:label_mobile_phone) %> | <%= phone.call(customer&.mobile_phone) %> |
| <%= t(:label_billing_address) %> | <%= RedmineQboBilling::EstimateWriter.format_address(customer.billing_address) %> |
| <%= t(:label_shipping_address) %> | <%= RedmineQboBilling::EstimateWriter.format_address(customer.shipping_address) %> |
| <%= t(:label_account_balance) %> | <%= number_to_currency(customer.balance || 0) %> |
<%= t(:field_notes) %> |
|
|
<%= textilizable(customer, :notes) %>
|
|