<table class="table tl" onclick="$('#infosave').fadeOut()">
        <tr>
        	<td class="h4" colspan="2">
            <?php if($_GET['info']==1){?>
			<b class="text text-success">Data Saved !</b>
			<?php }?>
            </td>
            <td class="h4 tr" colspan="2"><?php echo $act_desc?></td>
        </tr>
        <tr>
        	<td>Category</td>
            <td colspan="3">
            	<select class="input w-80" name="pc_autoid" id="pc_autoid">
                <option value="">Select Kategori</option>
                <?php
                $sqlsc = "select * from mst_parttype a, mst_partclass b  
						WHERE a.pt_autoid = b.pt_autoid  order by b.pc_name";
				$sc_con = $conn->query($sqlsc) or die($sqlsc);
				while($rsc = $sc_con->fetch_assoc()){
					if($rsx['pt_autoid']=="1"){$txt_class = 'color:#06F';}
					else{
						$txt_class = 'color:#666';
						}
				?>
                	<option style="<?php echo $txt_class?>" <?php if($pc_autoid==$rsc['pc_autoid']){echo "selected='selected'";}?> 
                    value="<?php echo $rsc['pc_autoid']?>"><?php echo $rsc['pc_name']?> | <?php echo $rsc['pt_code']?></option>
                <?php } ?>
                </select>
            </td>
        </tr>
    	<tr>
        	<td style="width:200px;">Nama Item</td>
            <td colspan="3">
            	<input type="text" id="pm_name" name="pm_name" class="input w-80" placeholder="Nama Item" value="<?php echo $row['pm_name']?>">
            </td>
        </tr>
      	<tr>
        	<td>Harga Beli</td>
            <td colspan="3">
            	<input type="text" id="pm_bprice" name="pm_bprice" class="input tr" placeholder="0" value="<?php echo $row['pm_bprice']?>">
            </td>
        </tr>    
      	<tr>
        	<td>Harga Jual</td>
            <td colspan="3">
            	<input type="text" id="pm_sprice" name="pm_sprice" class="input tr" placeholder="0" value="<?php echo $row['pm_sprice']?>">
            </td>
		</tr>
		<tr>
        	<td>Catatan / Keterangan</td>
            <td colspan="3">
            <textarea class="input" style="width:80%" name="pm_desc"><?php echo $row['pm_desc']?></textarea>
            </td>
        </tr>
    </table>
    
<table class="table tl">

        <tr>
        	<td style="width:200px;">Product Image 1</td>
            <td>
				<input type="file" name="img_file_1" id="img_file" class="input"/> 
                <i class="text text-danger">* W = 620px H =800px</i>
            </td>
            <td>
                <a href="../../<?php echo $img_1 ?>" target="_blank"><img src="../../<?php echo $img_1 ?>" style="height:50px;" /></a>
            </td>
        </tr>
        <!--
        <tr>
        	<td>Product Image 2</td>
            <td>
				<input type="file" name="img_file_2" id="img_file" class="input"/>
            </td>
            <td>
				<img src="../../../<?php echo $img_2 ?>" style="height:50px;" />
            </td>
        </tr>
        <tr>
        	<td>Product Image 3</td>
            <td>
				<input type="file" name="img_file_3" id="img_file" class="input"/>
            </td>
            <td>
                	<img src="../../../<?php echo $img_3?>" style="height:50px;" />
            </td>
        </tr>
        <tr>
        	<td>Product Image 4</td>
            <td>
				<input type="file" name="img_file_4" id="img_file" class="input"/>
            </td>
            <td>
                	<img src="../../../<?php echo $img_4 ?>" style="height:50px;" />
            </td>
        </tr>
        -->
</table>

<div class="px-2">
            <?php
            if($act=="add"){$save_label = "Save Product";}
            if($act=="edit"){$save_label = "Save Edit";}
			if($act=="delete"){$save_label = "Delete Product";}
			?>
            <input type="button" value="<?php echo $save_label?>" class="btn btn-success btn-sm mr-3" onclick="confirm_save('save')">
            <input type="button" value="Back To Index" class="btn btn-dark btn-sm" onclick="window.location.href='index'">
			<input type="hidden" id="act" name="act" value="<?php echo $act?>">
		 	<input type="hidden" id="autoid" name="autoid" value="<?php echo $autoid?>">

</div>
  
