|
|
@@ -84,7 +84,7 @@ var bootstrap = function ($, learun) { |
|
|
|
if (learun.checkrow(keyValue)) { |
|
|
|
learun.layerConfirm('是否确认删除该项!', function (res) { |
|
|
|
if (res) { |
|
|
|
learun.deleteForm(top.$.rootUrl + '/PersonnelManagement/VisitorInfo/DeleteForm', { keyValue: keyValue}, function () { |
|
|
|
learun.deleteForm(top.$.rootUrl + '/PersonnelManagement/VisitorInfo/DeleteForm', { keyValue: keyValue }, function () { |
|
|
|
refreshGirdData(); |
|
|
|
}); |
|
|
|
} |
|
|
@@ -98,19 +98,27 @@ var bootstrap = function ($, learun) { |
|
|
|
//审核 |
|
|
|
$('#lr_lock').on('click', function () { |
|
|
|
var keyValue = $('#gridtable').jfGridValue('VID'); |
|
|
|
if (keyValue.indexOf(',') > 0) { |
|
|
|
learun.alert.warning("只能选中一条记录审核!"); |
|
|
|
return; |
|
|
|
} |
|
|
|
if (learun.checkrow(keyValue)) { |
|
|
|
var VState = $('#gridtable').jfGridValue('VState'); |
|
|
|
if (VState.indexOf('1') != -1) { |
|
|
|
learun.alert.warning("选中记录中包含已审核项目!"); |
|
|
|
return; |
|
|
|
} |
|
|
|
learun.layerConfirm('是否确认审核该项?', function (res) { |
|
|
|
if (res) { |
|
|
|
learun.postForm(top.$.rootUrl + '/PersonnelManagement/VisitorInfo/Check', { keyValue: keyValue }, function () { |
|
|
|
refreshGirdData(); |
|
|
|
}); |
|
|
|
learun.layerForm({ |
|
|
|
id: 'form', |
|
|
|
title: '审核', |
|
|
|
url: top.$.rootUrl + '/PersonnelManagement/VisitorInfo/ExamineForm?keyValue=' + keyValue, |
|
|
|
width: 550, |
|
|
|
height: 330, |
|
|
|
callBack: function (id) { |
|
|
|
return top[id].acceptClick(refreshGirdData); |
|
|
|
} |
|
|
|
}); |
|
|
|
|
|
|
|
} |
|
|
|
}); |
|
|
|
//去审 |
|
|
@@ -119,7 +127,6 @@ var bootstrap = function ($, learun) { |
|
|
|
if (learun.checkrow(keyValue)) { |
|
|
|
var VState = $('#gridtable').jfGridValue('VState'); |
|
|
|
var VStateArr = VState.split(','); |
|
|
|
console.log("VStateArr", VStateArr); |
|
|
|
if ($.inArray('0', VStateArr) != -1 || $.inArray('', VStateArr) != -1) { |
|
|
|
learun.alert.warning("选中记录中包含未审核项目!"); |
|
|
|
return; |
|
|
@@ -159,20 +166,20 @@ var bootstrap = function ($, learun) { |
|
|
|
$('#gridtable').lrAuthorizeJfGrid({ |
|
|
|
url: top.$.rootUrl + '/PersonnelManagement/VisitorInfo/GetPageList', |
|
|
|
headData: [ |
|
|
|
{ label: "姓名", name: "VName", width: 100, align: "left"}, |
|
|
|
{ label: "手机号", name: "VPhone", width: 100, align: "left"}, |
|
|
|
{ label: "申请理由", name: "VReasons", width: 100, align: "left"}, |
|
|
|
{ label: "来访目的", name: "VObjective", width: 100, align: "left"}, |
|
|
|
{ label: "姓名", name: "VName", width: 100, align: "left" }, |
|
|
|
{ label: "手机号", name: "VPhone", width: 100, align: "left" }, |
|
|
|
{ label: "申请理由", name: "VReasons", width: 100, align: "left" }, |
|
|
|
{ label: "来访目的", name: "VObjective", width: 100, align: "left" }, |
|
|
|
{ label: "备注", name: "VRemarks", width: 100, align: "left" }, |
|
|
|
{ |
|
|
|
label: "审核标志", name: "VState", width: 80, align: "left", |
|
|
|
label: "状态", name: "VState", width: 80, align: "left", |
|
|
|
formatter: function (cellvalue) { |
|
|
|
return cellvalue == 1 ? "<span class=\"label label-success\">已审核</span>" : "<span class=\"label label-danger\">未审核</span>"; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
], |
|
|
|
mainId:'VID', |
|
|
|
mainId: 'VID', |
|
|
|
isPage: true, |
|
|
|
isMultiselect: true, |
|
|
|
}); |
|
|
@@ -181,7 +188,7 @@ var bootstrap = function ($, learun) { |
|
|
|
param = param || {}; |
|
|
|
param.StartTime = startTime; |
|
|
|
param.EndTime = endTime; |
|
|
|
$('#gridtable').jfGridSet('reload',{ queryJson: JSON.stringify(param) }); |
|
|
|
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); |
|
|
|
} |
|
|
|
}; |
|
|
|
refreshGirdData = function () { |
|
|
|