Ejemplo n.º 1
0
<?php

$locked = false;
echo '<div id="internal_info" class="' . get_tab_panel_class() . '">';
print_datetime_element(array('label' => 'Creation date', 'name' => 'creation_date', 'render_static' => $locked, 'show' => true, 'required' => true, 'static_value' => $maintenance_contract_data['creation_date'], 'static_displayvalue' => $maintenance_contract_data['creation_date']));
print_date_element(array('label' => 'Next maintenance date', 'name' => 'next_maintenance_date', 'render_static' => $locked || !has_capability('orders:editpreferredstartdate'), 'show' => true, 'required' => true, 'static_value' => $maintenance_contract_data['next_maintenance_date'], 'static_displayvalue' => $maintenance_contract_data['next_maintenance_date']));
print_dropdown_element(array('label' => 'Schedule type', 'name' => 'schedule_interval', 'required' => true, 'options' => array('3' => 'Quarterly', '6' => '6-monthly', '12' => 'Yearly')));
print_tabbed_form_navbuttons();
echo '</div>';
Ejemplo n.º 2
0
<div class="panel panel-primary">
<div class="panel-heading"><?php 
echo get_title($title_options);
?>
</div>
<?php 
echo form_open(base_url() . 'miniant/orders/assignments/process_edit/', array('id' => 'assignment_edit_form', 'class' => 'form-horizontal'));
echo '<div class="panel-body">';
echo form_hidden('assignment_id', $assignment_id);
echo form_hidden('unit_id', $assignment_data->unit_id);
echo form_hidden('order_id', $assignment_data->order_id);
echo form_hidden('senior_technician_id', $assignment_data->order_senior_technician_id);
print_form_container_open();
print_datetime_element(array('label' => 'Appointment date', 'name' => 'appointment_date', 'required' => true));
print_input_element(array('label' => 'Estimated duration (Mins)', 'name' => 'estimated_duration', 'required' => true));
print_multiselect_element(array('label' => 'Assigned technicians', 'name' => 'technician_id[]', 'required' => true, 'options' => $technicians, 'default_value' => $assigned_technicians));
print_dropdown_element(array('label' => 'Senior technician', 'name' => 'senior_technician_id', 'required' => true, 'default_value' => $senior_technician_id, 'options' => array()));
/*
print_dropdown_element(array(
    'label' => 'Priority level',
    'name' => 'priority_level_id',
    'required' => true,
    'options' => $priority_levels
));
*/
if (has_capability('assignments:editstatuses')) {
    print_multiselect_element(array('label' => 'Statuses', 'name' => 'status_id[]', 'required' => false, 'options' => $allstatuses, 'default_value' => $statuses, 'extra_html' => array('style' => "width: 500px; height: auto;")));
}
print_submit_container_open();
print_submit_button();
print_cancel_button(base_url() . 'miniant/orders/schedule');
Ejemplo n.º 3
0
<?php

echo '<div id="internal_info" class="' . get_tab_panel_class() . '">';
print_datetime_element(array('label' => 'Call date', 'name' => 'call_date', 'render_static' => $locked || !has_capability('orders:editcalldate'), 'show' => true, 'static_value' => $order_data['call_date'], 'static_displayvalue' => $order_data['call_date']));
print_dropdown_element(array('label' => 'Job type', 'name' => 'order_type_id', 'render_static' => $locked || !has_capability('orders:editordertype') || !empty($order_data['order_type_id']), 'show' => true, 'static_value' => @$order_data['order_type'], 'static_displayvalue' => $dropdowns['order_types'][$order_data['order_type_id']], 'options' => $dropdowns['order_types'], 'required' => true));
if (!empty($order_data['order_type_id'])) {
    print_hidden_element(array('name' => 'order_type_id', 'default_value' => $order_data['order_type_id']));
    if ($is_installation) {
        print_input_element(array('label' => 'Quotation number', 'name' => 'installation_quotation_number', 'render_static' => $locked, 'show' => true, 'static_value' => @$order_data['installation_quotation_number'], 'required' => true));
    }
} else {
    print_input_element(array('label' => 'Quotation number', 'name' => 'installation_quotation_number', 'render_static' => $locked, 'show' => true, 'static_value' => @$order_data['installation_quotation_number'], 'disabledunless' => array('order_type_id' => $this->order_model->get_type_id('Installation')), 'required' => true));
}
/*
    if (has_capability('orders:setappointmentdate') && !$locked) {
   print_datetime_element('Appointment date', array('name' => 'appointment_date'));
    } else if (!empty($order_id) || $locked) {
   print_static_form_element('Appointment date', '<span id="appointment_date">'.$order_data['appointment_date'].'</span>');
    }

    if (has_capability('orders:allocateorders') && !$locked) {
   print_dropdown_element('technician_id', 'Assigned technician', $dropdowns['technicians'], false);
    } else if (!empty($order_id) || $locked) {
   print_static_form_element('Assigned technician', '<span id="technician_name" data-id="'.$order_data['technician_id'].'">'.$order_data['technician_first_name'] . ' ' . $order_data['technician_last_name'].'</span>');
    }
*/
if ($is_maintenance || empty($order_id)) {
    $params = array('label' => 'Start date', 'name' => 'maintenance_preferred_start_date', 'render_static' => $locked || !has_capability('orders:editpreferredstartdate'), 'show' => true, 'static_value' => $order_data['preferred_start_date'], 'static_displayvalue' => $order_data['preferred_start_date'], 'required' => true);
    if (empty($order_id)) {
        // $params['disabledunless'] = array('order_type_id' => $this->order_model->get_type_id('Maintenance'));
    }