Commit | Line | Data |
---|---|---|
ec28d06c | 1 | <?php |
de77377e | 2 | switch($SUBPATH[0]) { |
ec28d06c | 3 | default: case 1: |
35916247 TM |
4 | echo $this->html->form("$URL/2", 'GET', array( |
5 | array('serial','','text',false,'autofocus','item_serial:'), | |
6 | array(false,'DISPOSE','submit') | |
7 | )); | |
ec28d06c TM |
8 | break; |
9 | case 2: | |
10 | $item_id = $this->db->map_unique('item_serial', $_GET['serial'], 'item_id', 'item'); | |
11 | $columns = $this->db->get_columns('item'); | |
12 | $selectbox = $this->db->columns_get_selectbox($columns, 'item'); | |
13 | ||
14 | $current = $this->db->get_listing('item', $item_id, 1); | |
15 | $current[$item_id]['status_id'] = 2; | |
b895e8ea | 16 | $current[$item_id]['item_customer'] = 0; |
ec28d06c TM |
17 | |
18 | $action = $_SERVER['SCRIPT_NAME']."/item/$item_id/edit"; | |
19 | echo $this->html->render_insert_form('item', $columns, $selectbox, $current, false, $action); | |
20 | break; | |
21 | } |