Пример #1
0
<?php

include_once '../models/transaksi.php';
include_once '../models/masterdata.php';
include_once '../inc/functions.php';
$param = array('id' => $_GET['id']);
$cek = check_penjualan_availability($param['id']);
$list_data = load_data_resep($param);
$master_resep = $list_data['data'];
$jasa = 0;
foreach ($master_resep as $key => $data) {
    $kemasan = kemasan_load_data($data->id_barang);
    $jasa = $jasa + $data->nominal;
    ?>
<tr class="tr_rows">
    <td align=center><?php 
    echo ++$key;
    ?>
</td>
    <td>&nbsp;<?php 
    echo $data->nama_barang;
    ?>
<input type=hidden name=id_barang[] value="<?php 
    echo $data->id_barang;
    ?>
" class=id_barang id=id_barang<?php 
    echo $key;
    ?>
 /></td>
    <td><input type=text name=jumlah[] id=jumlah<?php 
    echo $key;
Пример #2
0
<?php

include_once '../models/masterdata.php';
include_once '../inc/functions.php';
$barang_packing = kemasan_load_data($_GET['id']);
$kemasan = satuan_load_data();
foreach ($barang_packing as $key => $rows) {
    ?>
    <tr class="mother" id="mother<?php 
    echo $key;
    ?>
"><td width=15%><input type=radio name=default <?php 
    echo $rows->default_kemasan === '1' ? 'checked' : NULL;
    ?>
 value="<?php 
    echo $rows->id;
    ?>
" title="Kemasan jual default" /> Barcode:</td><td width=70%><?php 
    echo form_hidden('id_kemasan' . $key, $rows->id, 'id=id_kemasan' . $key);
    echo form_input('barcode' . $key, $rows->barcode, 'id=barcode' . $key . ' class=barcode size=10');
    ?>
 
    Kemasan: <select name=kemasan<?php 
    echo $key;
    ?>
 onchange="isi_satuan_terkecil(<?php 
    echo $key;
    ?>
);" id="kemasan<?php 
    echo $key;
    ?>