134 lines
3.7 KiB
PHP
134 lines
3.7 KiB
PHP
<?php include('techsyn_header.php'); ?>
|
|
<!-- Main Content Container for side bar and body-->
|
|
<div class="main-container ace-save-state" id="main-container">
|
|
<script type="text/javascript">
|
|
try{ace.settings.loadState('main-container')}catch(e){}
|
|
</script>
|
|
<?php include('techsyn_sidebar.php'); ?>
|
|
|
|
<!--breadcrumb-->
|
|
<div class="main-content">
|
|
<div class="main-content-inner">
|
|
<div class="breadcrumbs ace-save-state" id="breadcrumbs">
|
|
<ul class="breadcrumb">
|
|
|
|
<li class="#">Group item </li><li class="active">Add group items</li>
|
|
</ul>
|
|
</div>
|
|
<!-- End of breadcrumb -->
|
|
|
|
|
|
<div class="page-content">
|
|
|
|
<form name="group_item_form" method="post" action="" id="group_item_form">
|
|
|
|
<input type="hidden" name="group_item_id" id="group_item_id"/>
|
|
</form>
|
|
|
|
<div id="flex1" style="width:100%">
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
</div><!-- /.page-content -->
|
|
</div>
|
|
</div><!-- /.main-content -->
|
|
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
$(function () {
|
|
var w=screen.width*.90;
|
|
var h =0;
|
|
h =(window.innerHeight-($("#navbar").height()+$(".breadcrumbs").height()))*.75;
|
|
$("#flex1").flexigrid({
|
|
url: 'group_item_list_script.php',
|
|
dataType: 'json',
|
|
colModel: [
|
|
{display: 'Sr', name: 'count', width: w*.04, sortable: false, align: 'left'},
|
|
|
|
{display: 'Parent Item Name', name: 'item_id', width: w*.15, sortable: true, align: 'left'},
|
|
{display: 'Item Type', name: 'item_type', width: w*.15, sortable: true, align: 'left'},
|
|
{display: 'Child Item', name: 'item_id', width: w*.2, sortable: true, align: 'left'},
|
|
{display: 'Qty ', name: 'qty', width: w*.2, sortable: true, align: 'left'},
|
|
{display: 'Cost ', name: 'cost', width: w*.2, sortable: true, align: 'left'},
|
|
// {display: ' ', name: '', width: w*.2, sortable: true, align: 'left'},
|
|
|
|
|
|
|
|
],
|
|
buttons: [
|
|
|
|
{name: 'Add', bclass: 'add', onpress : add},
|
|
{separator: true},
|
|
/*{name: 'PDF', bclass: 'print', onpress : pdf},
|
|
{separator: true},
|
|
{name: 'Excel', bclass: 'print_excel', onpress : excel},
|
|
{separator: true},*/
|
|
|
|
],
|
|
searchitems: [
|
|
|
|
// {display: 'Parent ID', name: 'parent_id', isdefault: true},
|
|
|
|
{display: 'Item Type', name: 'item_type'},
|
|
{display: 'Qty', name: 'qty'},
|
|
|
|
// {display: 'qty ', name: 'qty'}
|
|
|
|
],
|
|
sortname: "group_item_id",
|
|
sortorder: "desc",
|
|
usepager: true, //pagination
|
|
|
|
useRp: true,
|
|
rp: 50, //records per page
|
|
showTableToggleBtn: false, //toggle button for the whole table
|
|
resizable: true,
|
|
//width: w,
|
|
height: h,
|
|
singleSelect: true
|
|
});
|
|
});
|
|
|
|
|
|
|
|
function open_group_items(group_id,action){
|
|
|
|
if(group_id!=null && group_id!=""){
|
|
if(action=='E'){
|
|
$("#group_item_id").val(group_id);
|
|
$("#group_item_form").attr('action', 'edit_group_items.php');
|
|
$("#group_item_form").submit();
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
function add(){
|
|
location.href="add_group_item.php";
|
|
}
|
|
|
|
function pdf(){
|
|
window.open('pdf_procurement.php');
|
|
}
|
|
function excel(){
|
|
window.location = 'excel_procurement.php';
|
|
}
|
|
function download_template(){
|
|
window.location = 'download_template.php';
|
|
}
|
|
function upload_excel(){
|
|
window.location = 'upload_excel_procurement.php';
|
|
}
|
|
|
|
|
|
</script>
|
|
|
|
<?php include('techsyn_footer.php'); ?>
|