home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
61.19.244.139
/
61.19.244.139.zip
/
61.19.244.139
/
2015-02-19
/
views
/
comm-agent-setup.jsp
< prev
next >
Wrap
Text File
|
2015-02-19
|
12KB
|
391 lines
<%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles"%>
<tiles:insertDefinition name="defaultTemplate">
<tiles:putAttribute name="body">
<ul class="breadcrumb">
<li><a href="#">α╕½α╕Öα╣ëα╕▓α╕½α╕Ñα╕▒α╕ü</a><span class="divider">»</span></li>
<li class="active">กำหนดรายละเอียดกำเหน็จ</li>
</ul>
<div class="row-fluid">
<div class="span12 ">
<div class=" widget-block">
<div class="widget-head">
<h5>
<i class="black-icons documents"></i> ตัวแทนนายหน้า
</h5>
</div>
<div class="widget-content">
<div class="widget-searchbox">
<ul>
<li class="row-counts"><a class="btn btn-success" id="addBtn" href="#frm-box"> <i class="icon-plus icon-white"></i> เพิ่ม
</a> <a class="btn btn-primary" id="editBtn"> <i class="icon-pencil icon-white"></i> แก้ไข
</a> <a class="btn btn-danger" id="delBtn"> <i class="icon-trash icon-white"></i> ลบ
</a></li>
<li class="right">
<form>
<fieldset>
<div class="control-group">
<div class="controls">
<input class="input-small" type="text" id="agentIdStart" name="agentIdStart" placeholder="รหัส ตัวแทน"> - <input id="agentIdEnd" name="agentIdEnd" class="input-small"
type="text" placeholder="รหัส ตัวแทน"> <a class="btn btn-info" id="btSearch" > <i class="icon-search icon-white"></i> ค้นหา
</a>
</div>
</div>
</fieldset>
</form>
</li>
</ul>
</div>
<div class="widget-box">
<div align="center" id='jqgrid'>
<table id='grid'></table>
<div id='pager'></div>
</div>
</div>
</div>
</div>
</div>
</div>
<div id="frm-box" class="frm-popup span8">
<a href="#" class="close"><img src="img/close_pop.png" class="btn_close" title="Close Window" alt="Close" /></a>
<form class="form-horizontal well">
<div class="row-fluid">
<div class="span12">
<div class="nonboxy-widget">
<div class="widget-head">
<h5>กำหนดรายละเอียดตัวแทน</h5>
</div>
<div class="widget-content">
<div class="widget-box">
<fieldset>
<div class="box-tab">
<div class="tabbable">
<ul class="nav nav-tabs">
<li class="active"><a data-toggle="tab" href="#tab1"><i
class="black-icons blocks_images"></i> ราายละเอียดตัวแทน</a></li>
<li><a data-toggle="tab" href="#tab2"><i
class="black-icons blocks_images"></i> PACKAGES</a></li>
<li class=""><a data-toggle="tab" href="#tab3"><i
class="black-icons abacus"></i> รหัสรถยนต์</a></li>
</ul>
<div class="tab-content">
<!-- Tab1 -->
<div id="tab1" class="tab-pane active">
<div class=" row-fluid">
<div class="control-group">
<label class="control-label" for="input01">ตัวแทน</label>
<div class="controls">
<input class="input-small" type="text"
placeholder="รหัสตัวแทน"> <input
class="input-xlarge" type="text"
placeholder="ชื่อตัวแทน">
</div>
</div>
<div class="control-group">
<label class="control-label" for="input02">ประกันภัย</label>
<div class="controls multiline-input">
<select class="span2">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
</select>
</div>
</div>
<div class="control-group">
<label class="control-label" for="input02">อัตราค่านายหน้าที่ได้รับ</label>
<div class="controls">
<input class="input-small" type="text"
placeholder="ที่ได้รับ">
</div>
</div>
<div class="control-group">
<label class="control-label" for="input02">อัตราค่านายหน้าให้หัวหน้า</label>
<div class="controls">
<input class="input-small" type="text"
placeholder="ให้หนัวหน้าทีม">
</div>
</div>
</div>
</div>
<!-- end tab1 -->
<div id="tab2" class="tab-pane">
<div class=" row-fluid">
<div role="grid" class="dataTables_wrapper">
<div class="table_top clearfix"></div>
<div class="table_content">
<table
class="data-tbl-striped table table-striped table-bordered dataTable">
<thead>
<tr role="row">
<th class="sorting_disabled" role="columnheader"
rowspan="1" colspan="1" style="width: 100px;">
PACKAGE</th>
<th class=" " role="columnheader" rowspan="1"
colspan="1" style="width: 87px;">ขนาดรถยนต์</th>
<th class=" " role="columnheader" rowspan="1"
colspan="1" style="width: 87px;">
อัตราค่านายหน้า</th>
<th class=" " role="columnheader" rowspan="1"
colspan="1" style="width: 153px;">อัตราค่านายหน้าหัวหน้าทีม</th>
</tr>
</thead>
<tbody role="alert" aria-live="polite"
aria-relevant="all">
<tr class="odd">
<td class=" sorting_1"><input type="checkbox" /></td>
<td class=" ">PACKAGE 1</td>
<td class="center ">xxx</td>
<td class="center ">xxx</td>
</tr>
<tr class="odd">
<td class=" sorting_1"><input type="checkbox" /></td>
<td class=" ">PACKAGE 2</td>
<td class="center ">xxx</td>
<td class="center ">xxx</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
<!-- end Tab 2 -->
<div id="tab3" class="tab-pane">
<div class=" row-fluid">
<div role="grid" class="dataTables_wrapper">
<div class="table_top clearfix"></div>
<div class="table_content">
<table
class="data-tbl-striped table table-striped table-bordered dataTable">
<thead>
<tr role="row">
<th class="sorting_disabled" role="columnheader"
rowspan="1" colspan="1" style="width: 100px;">
เลือก</th>
<th class=" " role="columnheader" rowspan="1"
colspan="1" style="width: 87px;">รหัสรถยนต์</th>
<th class=" " role="columnheader" rowspan="1"
colspan="1" style="width: 87px;">ขนาดรถยนต์</th>
<th class=" " role="columnheader" rowspan="1"
colspan="1" style="width: 87px;">
อัตราค่านายหน้า</th>
<th class=" " role="columnheader" rowspan="1"
colspan="1" style="width: 153px;">อัตราค่านายหน้าหัวหน้าทีม</th>
</tr>
</thead>
<tbody role="alert" aria-live="polite"
aria-relevant="all">
<tr class="odd">
<td class=" sorting_1"><input type="checkbox" /></td>
<td class=" ">100</td>
<td class="center ">xxx</td>
<td class="center ">xxx</td>
<td class="center ">xxx</td>
</tr>
<tr class="odd">
<td class=" sorting_1"><input type="checkbox" /></td>
<td class=" ">101</td>
<td class="center ">xxx</td>
<td class="center ">xxx</td>
<td class="center ">xxx</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
<!-- end Tab 3 -->
</div>
</div>
</div>
<!-- Eng Tab box -->
<button class="btn btn-success">บันทึก</button>
<button class="btn">ยกเลิก</button>
</fieldset>
</div>
</div>
</div>
</div>
</div></form></div>
</tiles:putAttribute>
<tiles:putAttribute name="customScript">
<script>
$(function() {
$('#btSearch').click(function() {
// alert( $('#agentIdStart').val() +'-'+$('#agentIdEnd').val());
var f = {
groupOp : "AND",
rules : []
};
f.rules.push({
field : "agentIdStart",
op : "cn",
data : $('#agentIdStart').val()
});
f.rules.push({
field : "agentIdEnd",
op : "cn",
data : $('#agentIdEnd').val()
});
var grid = $('#grid');
grid[0].p.search = f.rules.length > 0;
$.extend(grid[0].p.postData, {
filters : JSON.stringify(f)
});
grid.trigger("reloadGrid", [ {
page : 1
} ]);
});
});
//box
$(document).ready(function() {
var enforceModalFocusFn = $.fn.modal.Constructor.prototype.enforceFocus;
$.fn.modal.Constructor.prototype.enforceFocus = function() {
};
$('#addBtn').click(function() {
//Getting the variable's value from a link
var frmBox = $(this).attr('href');
//Fade in the Popup
$(frmBox).fadeIn(300);
//Set the center alignment padding + border see css style
var popMargTop = ($(frmBox).height() + 5) / 2;
var popMargLeft = ($(frmBox).width() + 5) / 2;
$(frmBox).css({
'margin-top' : -popMargTop,
'margin-left' : -popMargLeft
});
// Add the mask to body
$('body').append('<div id="mask"></div>');
$('#mask').fadeIn(100);
return false;
});
$('#delBtn').click(function() {
var selr = $("#grid").jqGrid('getGridParam', 'selrow');
if (selr && confirm("ยืนยันการลบข้อมูล Package รหัส " + selr))
alert(selr);
});
// When clicking on the button close or the mask layer the popup closed
$('a.close, #mask').live('click', function() {
$('#mask , .frm-popup').fadeOut(300, function() {
$('#mask').remove();
});
$.fn.modal.Constructor.prototype.enforceFocus = enforceModalFocusFn;
return false;
});});
function codeFormat(cellvalue, options, rowObject) {
return '<span class="label label-success">' + cellvalue + '</span>';
}
</script>
</tiles:putAttribute>
</tiles:insertDefinition>