Example #1
0
   <li><?php
    echo $f->l_val_field_d('buyer', 'hr_employee_v', 'employee_name', '', 'vf_select_document_owner employee_name');
    echo $f->hidden_field_withId('hr_employee_id', $$class->hr_employee_id);
    ?><i class="generic g_select_document_owner select_popup clickable fa fa-search" data-class_name="hr_employee_v"></i></li>
   <li><?php $f->l_text_field_d('buyer'); ?></li> 
   <li><?php $f->l_text_field_d('description'); ?></li> 
  </ul>
 </div>
 <div id="tabsHeader-2" class="tabContent">
  <div> 
   <ul class="column header_field">
    <li><?php $f->l_date_fieldFromToday('agreement_start_date', $$class->agreement_start_date) ?></li>
    <li><?php $f->l_date_fieldFromToday('agreement_end_date', $$class->agreement_start_date) ?></li>
    <li><?php $f->l_select_field_from_object('doc_currency', option_header::currencies(), 'option_line_code', 'option_line_code', $$class->doc_currency, 'doc_currency', '', 1, $readonly); ?></li>
    <li><?php $f->l_select_field_from_object('ledger_currency', option_header::currencies(), 'option_line_code', 'option_line_code', $$class->currency, 'currency', 'currency', 1, 1); ?></li>
    <li><?php $f->l_select_field_from_object('exchange_rate_type', gl_currency_conversion::currency_conversion_type(), 'option_line_code', 'option_line_code', $$class->exchange_rate_type, 'exchange_rate_type', '', 1, $readonly); ?></li>
    <li><?php $f->l_number_field('exchange_rate', $$class->exchange_rate, '', 'exchange_rate', '', 1, $readonly); ?> </li>
    <li><?php $f->l_select_field_from_object('price_list_header_id', mdm_price_list_header::find_all_purchasing_pl(), 'mdm_price_list_header_id', 'price_list', $$class->price_list_header_id); ?></li>
    <li><?php $f->l_number_field('header_amount', $$class->header_amount, '15', 'header_amount'); ?></li>
    <li><?php $f->l_number_field('tax_amount', $$class->tax_amount, '15', 'tax_amount'); ?></li>
    <li><?php $f->l_select_field_from_object('payment_term_id', payment_term::find_all(), 'payment_term_id', 'payment_term', $$class->payment_term_id, 'payment_term_id', '', 1, $readonly1); ?></li>
   </ul>
  </div>
 </div>
 <div id="tabsHeader-3" class="tabContent">
  <div class="shipto_address"><?php $f->address_field_d('ship_to_id'); ?></div>
  <div class="billto_address"><?php $f->address_field_d('bill_to_id'); ?></div>
 </div>
 <div id="tabsHeader-4" class="tabContent">
  <div id="comments">
   <div id="comment_list">
<?php

include_once "../../../includes/basics/basics.inc";
if (!empty($_GET['from_currency']) && !empty($_GET['to_currency']) && !empty($_GET['find_exchange_rate'])) {
    $from_currency = $_GET['from_currency'];
    $to_currency = $_GET['to_currency'];
    $rate_type = !empty($_GET['rate_type']) ? $_GET['rate_type'] : null;
    $result = gl_currency_conversion::find_rate($from_currency, $to_currency, $rate_type);
    if (count($result) == 0) {
        $data['rate'] = 0;
    } else {
        $data['rate'] = $result;
    }
    echo header('Content-Type: application/json');
    echo json_encode($data);
}
Example #3
0
$f->l_select_field_from_array('action', $action_a, ${$class}->action, 'action');
?>
</li>
     </ul>
    </div>
    <div id="tabsHeader-2" class="tabContent">
     <div class="vertical-align-top">
      <div class="panel panel-collapse panel-ino-classy large_box">
       <div class="panel-heading"><div class="panel-title font-medium"><?php 
echo gettext('Rate & Amounts');
?>
</div></div>
       <div class="panel-body">
        <ul class="column line_field">
         <li><?php 
$f->l_select_field_from_object('exchange_type', gl_currency_conversion::currency_conversion_type(), 'option_line_code', 'option_line_code', ${$class}->exchange_type, 'exchange_type', '', '', $readonly);
?>
</li>
         <li><?php 
$f->l_number_field('exchange_rate', ${$class}->exchange_rate, '', 'exchange_rate');
?>
 </li>
         <li><?php 
$f->l_number_field('running_total_dr', ${$class}->running_total_dr, '15', 'running_total_dr');
?>
</li>
         <li><?php 
$f->l_number_field('running_total_cr', ${$class}->running_total_cr, '15', 'running_total_cr');
?>
</li>
         <li><?php 
<div class="row small-left-padding">
 <form  method="post" id="gl_currency_conversion_line"  name="currency_conversion_line">
  <span class="heading"><?php 
echo __('Currency Conversions');
?>
</span>
  <div id="form_serach_header" class="tabContainer">
   <?php 
$f->l_select_field_from_object('currency_conversion_type', gl_currency_conversion::currency_conversion_type(), 'option_line_code', 'option_line_value', $currency_conversion_type_h, 'currency_conversion_type', '', 1);
?>
   <a name="show" href="form.php?class_name=gl_currency_conversion&<?php 
echo "mode={$mode}";
?>
" class="show document_id gl_currency_conversion_id">
    <i class="fa fa-refresh"></i></a> 
  </div> 
  <div id ="form_line" class="gl_currency_conversion"><span class="heading">
    <?php 
echo __('Conversion Details');
?>
</span>
   <div id="tabsLine">
    <ul class="tabMain">
     <li><a href="#tabsLine-1"><?php 
echo __('Rates');
?>
</a></li>
    </ul>
    <div class="tabContainer"> 
     <div id="tabsLine-1" class="tabContent">
      <table class="form_table">