|
@@ -23,7 +23,7 @@ var bootstrap = function ($, learun) { |
|
|
}); |
|
|
}); |
|
|
// 新增 |
|
|
// 新增 |
|
|
$('#lr_add').on('click', function () { |
|
|
$('#lr_add').on('click', function () { |
|
|
learun.layerForm({ |
|
|
|
|
|
|
|
|
learun.layerForm({ |
|
|
id: 'form', |
|
|
id: 'form', |
|
|
title: '新增', |
|
|
title: '新增', |
|
|
url: top.$.rootUrl + '/PersonnelManagement/PartyMember/Form', |
|
|
url: top.$.rootUrl + '/PersonnelManagement/PartyMember/Form', |
|
@@ -54,57 +54,102 @@ var bootstrap = function ($, learun) { |
|
|
$('#lr_delete').on('click', function () { |
|
|
$('#lr_delete').on('click', function () { |
|
|
var keyValue = $('#gridtable').jfGridValue('ID'); |
|
|
var keyValue = $('#gridtable').jfGridValue('ID'); |
|
|
if (learun.checkrow(keyValue)) { |
|
|
if (learun.checkrow(keyValue)) { |
|
|
learun.layerConfirm('是否确认删除该项!', function (res) { |
|
|
|
|
|
|
|
|
learun.layerConfirm('是否确认删除该项!', function (res) { |
|
|
if (res) { |
|
|
if (res) { |
|
|
learun.deleteForm(top.$.rootUrl + '/PersonnelManagement/PartyMember/DeleteForm', { keyValue: keyValue}, function () { |
|
|
|
|
|
|
|
|
learun.deleteForm(top.$.rootUrl + '/PersonnelManagement/PartyMember/DeleteForm', { keyValue: keyValue }, function () { |
|
|
refreshGirdData(); |
|
|
refreshGirdData(); |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
|
|
|
// 审核 |
|
|
|
|
|
$('#lr_check').on('click', function () { |
|
|
|
|
|
var keyValue = $('#gridtable').jfGridValue('ID'); |
|
|
|
|
|
if (learun.checkrow(keyValue)) { |
|
|
|
|
|
learun.layerConfirm('是否确认审核该项!', function (res) { |
|
|
|
|
|
if (res) { |
|
|
|
|
|
learun.postForm(top.$.rootUrl + '/PersonnelManagement/PartyMember/UpdateCheckStatus', { keyValue: keyValue, CheckStatus: 1 }, function () { |
|
|
|
|
|
refreshGirdData(); |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
// 去审 |
|
|
|
|
|
$('#lr_uncheck').on('click', function () { |
|
|
|
|
|
var keyValue = $('#gridtable').jfGridValue('ID'); |
|
|
|
|
|
if (learun.checkrow(keyValue)) { |
|
|
|
|
|
learun.layerConfirm('是否确认去审该项!', function (res) { |
|
|
|
|
|
if (res) { |
|
|
|
|
|
learun.postForm(top.$.rootUrl + '/PersonnelManagement/PartyMember/UpdateCheckStatus', { keyValue: keyValue, CheckStatus: 2 }, function () { |
|
|
|
|
|
refreshGirdData(); |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
// 初始化列表 |
|
|
// 初始化列表 |
|
|
initGird: function () { |
|
|
initGird: function () { |
|
|
$('#gridtable').lrAuthorizeJfGrid({ |
|
|
$('#gridtable').lrAuthorizeJfGrid({ |
|
|
url: top.$.rootUrl + '/PersonnelManagement/PartyMember/GetPageList', |
|
|
url: top.$.rootUrl + '/PersonnelManagement/PartyMember/GetPageList', |
|
|
headData: [ |
|
|
headData: [ |
|
|
{ label: "名字", name: "Name", width: 100, align: "left"}, |
|
|
|
|
|
{ label: "性别", name: "Gender", width: 100, align: "left", |
|
|
|
|
|
formatterAsync: function (callback, value, row, op,$cell) { |
|
|
|
|
|
learun.clientdata.getAsync('dataItem', { |
|
|
|
|
|
key: value, |
|
|
|
|
|
code: 'usersex', |
|
|
|
|
|
callback: function (_data) { |
|
|
|
|
|
callback(_data.text); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
}}, |
|
|
|
|
|
{ label: "职位", name: "Position", width: 100, align: "left"}, |
|
|
|
|
|
{ label: "部门", name: "Department", width: 100, align: "left", |
|
|
|
|
|
formatterAsync: function (callback, value, row, op,$cell) { |
|
|
|
|
|
learun.clientdata.getAsync('department', { |
|
|
|
|
|
key: value, |
|
|
|
|
|
callback: function (_data) { |
|
|
|
|
|
callback(_data.name); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
}}, |
|
|
|
|
|
{ label: "学历", name: "Education", width: 100, align: "left"}, |
|
|
|
|
|
{ label: "联系方式", name: "Mobile", width: 100, align: "left"}, |
|
|
|
|
|
{ label: "特长", name: "Speciality", width: 100, align: "left"}, |
|
|
|
|
|
{ label: "时间", name: "Time", width: 100, align: "left"}, |
|
|
|
|
|
|
|
|
{ label: "名字", name: "Name", width: 100, align: "left" }, |
|
|
|
|
|
{ |
|
|
|
|
|
label: "性别", name: "Gender", width: 100, align: "left", |
|
|
|
|
|
formatterAsync: function (callback, value, row, op, $cell) { |
|
|
|
|
|
learun.clientdata.getAsync('dataItem', { |
|
|
|
|
|
key: value, |
|
|
|
|
|
code: 'usersex', |
|
|
|
|
|
callback: function (_data) { |
|
|
|
|
|
callback(_data.text); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ label: "职位", name: "Position", width: 100, align: "left" }, |
|
|
|
|
|
{ |
|
|
|
|
|
label: "部门", name: "Department", width: 100, align: "left", |
|
|
|
|
|
formatterAsync: function (callback, value, row, op, $cell) { |
|
|
|
|
|
learun.clientdata.getAsync('department', { |
|
|
|
|
|
key: value, |
|
|
|
|
|
callback: function (_data) { |
|
|
|
|
|
callback(_data.name); |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
|
|
|
{ label: "学历", name: "Education", width: 100, align: "left" }, |
|
|
|
|
|
{ label: "联系方式", name: "Mobile", width: 100, align: "left" }, |
|
|
|
|
|
{ label: "特长", name: "Speciality", width: 100, align: "left" }, |
|
|
|
|
|
{ label: "时间", name: "Time", width: 100, align: "left" }, |
|
|
{ label: "备注", name: "Remark", width: 100, align: "left" }, |
|
|
{ label: "备注", name: "Remark", width: 100, align: "left" }, |
|
|
{ label: "审核状态", name: "CheckStatus", width: 100, align: "left" }, |
|
|
|
|
|
|
|
|
{ |
|
|
|
|
|
label: "审核状态", name: "CheckStatus", width: 100, align: "left", |
|
|
|
|
|
formatter: function (cellvalue, row) { |
|
|
|
|
|
if (cellvalue == 1) { |
|
|
|
|
|
return "<span class=\"label label-success\">审核通过</span>"; |
|
|
|
|
|
} else if (cellvalue == 2) { |
|
|
|
|
|
return "<span class=\"label label-danger\">未通过</span>"; |
|
|
|
|
|
} |
|
|
|
|
|
else { |
|
|
|
|
|
return "<span class=\"label label-default\">草稿</span>"; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
], |
|
|
], |
|
|
mainId:'ID', |
|
|
|
|
|
isPage: true |
|
|
|
|
|
|
|
|
mainId: 'ID', |
|
|
|
|
|
isPage: true, |
|
|
|
|
|
isMultiselect: true |
|
|
}); |
|
|
}); |
|
|
page.search(); |
|
|
page.search(); |
|
|
}, |
|
|
}, |
|
|
search: function (param) { |
|
|
search: function (param) { |
|
|
param = param || {}; |
|
|
param = param || {}; |
|
|
$('#gridtable').jfGridSet('reload',{ queryJson: JSON.stringify(param) }); |
|
|
|
|
|
|
|
|
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); |
|
|
} |
|
|
} |
|
|
}; |
|
|
}; |
|
|
refreshGirdData = function () { |
|
|
refreshGirdData = function () { |
|
|