<?php include "../../root.class.php";
$html = new html();
$html->add_styles_page();
$barcode = new barcodeReader();



$item_code = new input();
$item_code->id("code");
$item_code->name("code");
$item_code->class("inputs");
$item_code->type("text");


$user_id = new input();
$user_id->id("user_id");
$user_id->name("user_id");
$user_id->class("inputs");
$user_id->value($_SESSION['user_id']);
$user_id->type("hidden");
?>

<div class="form_down">
    <h1>ADD STOCK CODE</h1>
    <label>TYPE</label>
    <select id="stock_type" name="stock_type" class="inputs">
        <option></option>
        <option value="0">STOCK</option>
        <option value="1">NON STOCK</option>
        <option value="2">UNITS</option>
        <option value="3">NOT COUNTABLE</option>
    </select>
    <label>XERO ITEM CODE</label>
    <?php $item_code->add(); ?>
    <?php $user_id->add(); ?>
    <?php echo $html->submit_btn("submit", 'ADD', 'stock()', 'select_button'); ?>

</div>

<?php
$html->html_form_ajax("stock", "INSERT", "item_code_alocation", '', false);
?>