| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289 |
- <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
- <%@include file="/context/mytags.jsp"%>
- <t:base type="jquery,easyui,tools,DatePicker,autocomplete"></t:base>
- <style>
- .seachdiv{
- padding : 15px 30px;
- background-color: #ffffff;
- box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.05);
- border: solid 1px #dcdcdc;
- margin: 10px 10px 0px 10px;
- margin-bottom:1px;
- }
- </style>
- <div class="easyui-layout" fit="true">
- <div region="center" style="padding:0px;border:0px">
- <t:datagrid name="overtimepayStrategyList" pagination="true" fitColumns="true" title="加班费策略设定" actionUrl="overtimepayStrategyController.do?datagrid" idField="id" fit="true" pageSize="10" queryMode="group">
- <t:dgCol title="主键" field="id" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="创建人名称" field="createName" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="创建人登录名称" field="createBy" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="创建日期" field="createDate" formatter="yyyy-MM-dd hh:mm:ss" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="更新人名称" field="updateName" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="更新人登录名称" field="updateBy" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="更新日期" field="updateDate" formatter="yyyy-MM-dd hh:mm:ss" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="所属部门" field="sysOrgCode" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="所属公司" field="sysCompanyCode" hidden="true" queryMode="single" width="120"></t:dgCol>
- <t:dgCol title="加班费策略名称" field="strategyName" queryMode="single" width="120" showLen="35"></t:dgCol>
- <t:dgCol title="倍数" field="multiple" queryMode="single" width="20" style="text-align: right;"></t:dgCol>
- <t:dgCol title="备注" field="remark" queryMode="single" width="120" showLen="35"></t:dgCol>
- <t:dgCol title="逻辑删除标识" field="deleteFlag" hidden="true" queryMode="single" dictionary="del_flag" width="120"></t:dgCol>
- <t:dgCol title="状态" field="status" queryMode="single" dictionary="ableStatus" width="20" extendParams="align:'center',"></t:dgCol>
- <t:dgToolBar title="删除" icon="icon-remove" operationCode="remove" url="overtimepayStrategyController.do?doBatchLogicDel" funname="logicDel"></t:dgToolBar>
- <t:dgToolBar title="启用" icon="icon-enable" url="overtimepayStrategyController.do?doEnableObj" funname="enableObj"></t:dgToolBar>
- <t:dgToolBar title="停用" icon="icon-disable" url="overtimepayStrategyController.do?doDisableObj" funname="disableObj"></t:dgToolBar>
- </t:datagrid>
- </div>
- </div>
- <div id="pinjie1">
- <div name="pinjie2" style="padding:3px; height: auto" class="datagrid-toolbar">
- <div style="" class="seachdiv">
- <t:formvalid formid="formobj" dialog="false" layout="table" tipSweep="true" action="overtimepayStrategyController.do?saveRows" tiptype="1" callback="callback">
- <div style="display:none"><input type="submit" id ="btnsub" value=""/></div>
- <input name="id" id="id" type="hidden" value="" />
- <div style="position: relative;">
- <div align="right" style="float:left;margin-top:9px;">
- <label class="Validform_label">
- <span color="red" class="requiredIcon">*</span>加班费策略名称
- </label>
- </div>
- <div class="value" style="float:left;">
- <input id="strategyName" name="strategyName" type="text" style="width: 150px;" class="inputxt" datatype="*,*1-100" value="" placeholder="请输入加班费策略名称" errormsg="加班费策略名称最多填写100文字!">
- <span class="Validform_checktip"></span>
- <label class="Validform_label" style="display: none;">加班费策略名称</label>
- </div>
- <div align="right" style="float:left;margin-top:9px;">
- <label class="Validform_label">
- <span color="red" class="requiredIcon">*</span>倍数
- </label>
- </div>
- <div class="value" style="float:left;">
- <input id="multiple" name="multiple" type="text" style="width: 150px; " class="inputxt" datatype="*,/^\d{1,4}(\.\d{1})?$/" errormsg="倍数填写范围0~9999.9" value="" placeholder="请输入倍数">
- <span class="Validform_checktip"></span>
- <label class="Validform_label" style="display: none;">倍数</label>
- </div>
- <div align="right" style="float:left;margin-top:9px;">
- <label class="Validform_label">
- 备注
- </label>
- </div>
- <div class="value" style="float:left;">
- <input id="remark" name="remark" type="text" style="width: 350px;" class="inputxt" datatype="*0-100" errormsg="备注最多填写100文字!" value="" placeholder="请输入备注说明,最多100文字">
- </div>
- <div class="value" style="float:left;">
- <a href="#" class="easyui-linkbutton l-btn l-btn-plain" plain="true" icon="icon-save" id="btn_sub" onclick="saveData()">
- 保存
- </a>
- </div>
- <div class="value" >
- <a href="#" class="easyui-linkbutton l-btn l-btn-plain" plain="true" icon="icon-clean" onclick="clearData()">
- 清空
- </a>
- </div>
- </div>
- </t:formvalid>
- </div>
- </div>
- </div>
- <script src = "webpage/cn/com/lzt/overtimepaystrategy/overtimepayStrategyList.js"></script>
- <script type="text/javascript">
- function logicDel(){
- var ids = [];
- var rows = $("#overtimepayStrategyList").datagrid('getSelections');
- if (rows.length > 0) {
- $.messager.confirm("确认", "确定要删除这条数据?", function (r) {
- if (r) {
- for ( var i = 0; i < rows.length; i++) {
- ids.push(rows[i].id);
- }
- $.ajax({
- url : "overtimepayStrategyController.do?doBatchLogicDel",
- type : 'post',
- data : {
- ids : ids.join(',')
- },
- cache : false,
- success : function(data) {
- var d = data; // ------ $.parseJSON(data);
- if (d.success) {
- var msg = d.msg;
- tip(msg);
- $("#overtimepayStrategyList").datagrid('reload');
- clearData();
- ids='';
- }else{
- layer.alert(d.msg);
- }
- }
- });
- }
- });
- } else {
- layer.alert("请选择需要删除的数据");
- }
- }
-
- function enableObj(){
- var ids = [];
- var rows = $("#overtimepayStrategyList").datagrid('getSelections');
- if (rows.length > 0) {
- $.messager.confirm("确认", "确定要启用这条数据?", function (r) {
- if (r) {
- for ( var i = 0; i < rows.length; i++) {
- ids.push(rows[i].id);
- }
- $.ajax({
- url : "overtimepayStrategyController.do?doEnableObj",
- type : 'post',
- data : {
- ids : ids.join(',')
- },
- cache : false,
- success : function(data) {
- var d = data; // ------ $.parseJSON(data);
- if (d.success) {
- var msg = d.msg;
- tip(msg);
- $("#overtimepayStrategyList").datagrid('reload');
- clearData();
- ids='';
- } else {
- layer.alert(d.msg);
- }
- }
- });
- }
- });
- } else {
- layer.alert("请选择需要启用的数据");
- }
- }
-
- function disableObj(){
- var ids = [];
- var rows = $("#overtimepayStrategyList").datagrid('getSelections');
- if (rows.length > 0) {
- $.messager.confirm("确认", "确定要停用这条数据?", function (r) {
- if (r) {
- for ( var i = 0; i < rows.length; i++) {
- ids.push(rows[i].id);
- }
- $.ajax({
- url : "overtimepayStrategyController.do?doDisableObj",
- type : 'post',
- data : {
- ids : ids.join(',')
- },
- cache : false,
- success : function(data) {
- var d = data; // ------ $.parseJSON(data);
- if (d.success) {
- var msg = d.msg;
- tip(msg);
- $("#overtimepayStrategyList").datagrid('reload');
- clearData();
- ids='';
- } else {
- layer.alert(d.msg);
- }
- }
- });
- }
- });
- } else {
- layer.alert("请选择需要停用的数据");
- }
- }
-
- function fillData(rowData){
- //清空表单
- $("#formobj").form('clear');
- //填充数据
- for(var d in rowData){
- $("#"+d).val(rowData[d]);
- }
- }
-
- $(function(){
- $("#overtimepayStrategyList").datagrid({
- onClickRow: function(rowIndex, rowData){
- fillData(rowData);
- }
- });
- var datagrid = $("#overtimepayStrategyListtb");
- datagrid.prepend($("#pinjie1 div[name='pinjie2']").html());
- $("#pinjie1").html('');
- })
- //保存数据
- function saveData(){
- $("#btnsub").click();
- }
-
- function callback(data){
- if(data.success){
- clearData();
- $("#overtimepayStrategyList").datagrid('reload');
- top.tip(data.msg);
- }
- else{
- layer.alert(data.msg);
- }
- }
- function cancelEdit(){
- var rowData = $("#overtimepayStrategyList").datagrid("getSelected");
- if (rowData != null) {
- fillData(rowData);
- }else{
- clearData();
- }
- }
-
- function clearData(){
- var rowData = {};
- fillData(rowData);
- $("#overtimepayStrategyList").datagrid('clearChecked');
- $("#overtimepayStrategyList").datagrid('unselectAll');
- }
- /**
- //导入
- function ImportXls() {
- openuploadwin('Excel导入', 'overtimepayStrategyController.do?upload', "overtimepayStrategyList");
- }
- //导出
- function ExportXls() {
- JeecgExcelExport("overtimepayStrategyController.do?exportXls","overtimepayStrategyList");
- }
- //模板下载
- function ExportXlsByT() {
- JeecgExcelExport("overtimepayStrategyController.do?exportXlsByT","overtimepayStrategyList");
- }
- //新增
- function add(title,url,id){
- window.location.href=url
- }
- //修改
- function update(title,url, id){
- updateNotCreateWin("修改",url, "overtimepayStrategyList",false);
- }
- //查看
- function view(title,url, id){
- viewNotCreateWin("查看",url, "overtimepayStrategyList",false)
- }
- */
- </script>
|