|
- /* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn)
- * Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
- * 创建人:超级管理员
- * 日 期:2023-03-16 17:18
- * 描 述:家庭经济信息(学工部)
- */
- var selectedRow;
- var refreshGirdData;
- var bootstrap = function ($, learun) {
- "use strict";
- var startTime;
- var endTime;
- var page = {
- init: function () {
- page.initGird();
- page.bind();
- },
- bind: function () {
- // 时间搜索框
- $('#datesearch').lrdate({
- dfdata: [
- { name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
- { name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
- { name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
- { name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }
- ],
- // 月
- mShow: false,
- premShow: false,
- // 季度
- jShow: false,
- prejShow: false,
- // 年
- ysShow: false,
- yxShow: false,
- preyShow: false,
- yShow: false,
- // 默认
- dfvalue: '1',
- selectfn: function (begin, end) {
- startTime = begin;
- endTime = end;
- page.search();
- }
- });
- $('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
- page.search(queryJson);
- }, 450, 600);
- $('#ClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' });
- $('#F_SchoolId').lrDataSourceSelect({ code: 'company', value: 'f_companyid', text: 'f_fullname' });
- $('#IsLowIncome').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsOrphan').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsSingleFamilyChildren').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsDisabledChildren').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsDisabled').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsParentsLoseWork').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsSeriouslyIllPatientInHome').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsOvercomePovertyFamilyStudent').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsUnstablePovertyFamilyStudent').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsEdgePovertyFamilyStudent').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsEdgeAcuteDifficultyStudent').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsLowIncomeFamily').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsMartyrChildren').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#FamilyIsSufferNaturalDisaster').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#FamilyIsSufferUnexpectEvent').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#IsSpecialPovertySupport').lrDataItemSelect({ code: 'YesOrNoBit' });
- $('#FamilyIsSufferEpidemic').lrDataItemSelect({ code: 'YesOrNoBit' });
- // 刷新
- $('#lr_refresh').on('click', function () {
- location.reload();
- });
- // 归档
- $('#lr_submit').on('click', function () {
- var keyValue = $('#gridtable').jfGridValue('Id');
- if (learun.checkrow(keyValue)) {
- var Status = $('#gridtable').jfGridValue('Status');
- if (Status != "2") {
- learun.alert.warning("当前项不属于学工部审核状态,无法提交归档!");
- return false;
- }
- learun.layerConfirm('是否确认归档该项!', function (res) {
- if (res) {
- learun.postForm(top.$.rootUrl + '/StudentWork/FamilyEconomy/DoSubmit', { keyValue: keyValue, status: '3', step: '3' }, function () {
- refreshGirdData();
- });
- }
- });
- }
- });
- // 退回辅导员
- $('#lr_back').on('click', function () {
- var keyValue = $('#gridtable').jfGridValue('Id');
- if (learun.checkrow(keyValue)) {
- var Status = $('#gridtable').jfGridValue('Status');
- if (Status != "2") {
- learun.alert.warning("当前项不属于学工部审核状态,无法退回辅导员!");
- return false;
- }
- learun.layerConfirm('是否确认退回该项!', function (res) {
- if (res) {
- learun.postForm(top.$.rootUrl + '/StudentWork/FamilyEconomy/DoBack', { keyValue: keyValue, status: '0', step: '3' }, function () {
- refreshGirdData();
- });
- }
- });
- }
- });
- // 退回二级学院
- $('#lr_backTwo').on('click', function () {
- var keyValue = $('#gridtable').jfGridValue('Id');
- if (learun.checkrow(keyValue)) {
- var Status = $('#gridtable').jfGridValue('Status');
- if (Status != "2") {
- learun.alert.warning("当前项不属于学工部审核状态,无法退回二级学院!");
- return false;
- }
- learun.layerConfirm('是否确认退回该项!', function (res) {
- if (res) {
- learun.postForm(top.$.rootUrl + '/StudentWork/FamilyEconomy/DoBack', { keyValue: keyValue, status: '1', step: '3' }, function () {
- refreshGirdData();
- });
- }
- });
- }
- });
- },
- initGird: function () {
- $('#gridtable').jfGrid({
- url: top.$.rootUrl + '/StudentWork/FamilyEconomy/GetPageList',
- headData: [
- { label: '学号', name: 'StuNo', width: 100, align: "left" },
- { label: '姓名', name: 'StuName', width: 150, align: "left" },
- {
- label: '院校', name: 'F_SchoolId', width: 120, align: "left",
- formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('custmerData', {
- url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'company',
- key: value,
- keyId: 'f_companyid',
- callback: function (_data) {
- callback(_data['f_fullname']);
- }
- });
- }
- },
- {
- label: '班级', name: 'ClassNo', width: 100, align: "left",
- formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('custmerData', {
- url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj',
- key: value,
- keyId: 'classno',
- callback: function (_data) {
- callback(_data['classname']);
- }
- });
- }
- },
- {
- label: '身份证件类型', name: 'IdCardType', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('dataItem', {
- key: value,
- code: 'IdCardType',
- callback: function (_data) {
- callback(_data.text);
- }
- });
- }
- },
- { label: '身份证件号', name: 'IdentityCardNo', width: 150, align: "left" },
- {
- label: '申请时间', name: 'ApplyTime', width: 100, align: "left", formatter: function (cellvalue) {
- return cellvalue.substring(0, 11);
- }
- },
- {
- label: '是否低保', name: 'IsLowIncome', width: 100, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否孤儿', name: 'IsOrphan', width: 100, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否单亲家庭子女', name: 'IsSingleFamilyChildren', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否残疾人子女', name: 'IsDisabledChildren', width: 100, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '本人是否残疾', name: 'IsDisabled', width: 100, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '残疾类别', name: 'DisabledCategory', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('dataItem', {
- key: value,
- code: 'DisabledCategory',
- callback: function (_data) {
- callback(_data.text);
- }
- });
- }
- },
- {
- label: '是否父母丧失劳动能力', name: 'IsParentsLoseWork', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否家中有大病患者', name: 'IsSeriouslyIllPatientInHome', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否脱贫家庭学生', name: 'IsOvercomePovertyFamilyStudent', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否脱贫不稳定家庭学生', name: 'IsUnstablePovertyFamilyStudent', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否边缘易致贫家庭学生', name: 'IsEdgePovertyFamilyStudent', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否边突发严重困难学生', name: 'IsEdgeAcuteDifficultyStudent', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '是否低收入家庭', name: 'IsLowIncomeFamily', width: 100, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- {
- label: '烈士子女', name: 'IsMartyrChildren', width: 100, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- { label: '家庭人均年收入', name: 'FamilyAverageIncome', width: 100, align: "left" },
- {
- label: '家庭主要收入来源类型', name: 'FamilyIncomeSourceCategory', width: 150, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('dataItem', {
- key: value,
- code: 'FamilyIncomeSourceCategory',
- callback: function (_data) {
- callback(_data.text);
- }
- });
- }
- },
- {
- label: '家庭是否遭受自然灾害', name: 'FamilyIsSufferNaturalDisaster', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- { label: '自然灾害具体情况描述', name: 'SufferNaturalDisasterDescription', width: 150, align: "left" },
- {
- label: '家庭是否遭受突发意外事件', name: 'FamilyIsSufferUnexpectEvent', width: 200, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- { label: '突发意外事件具体描述', name: 'SufferUnexpectEventDescription', width: 150, align: "left" },
- { label: '家庭欠债金额', name: 'FamilyOwesAmount', width: 100, align: "left" },
- { label: '家庭欠债原因', name: 'FamilyOwesReason', width: 100, align: "left" },
- { label: '家庭人口数', name: 'FamilyNumber', width: 100, align: "left" },
- { label: '劳动力人口数', name: 'LaborNumber', width: 100, align: "left" },
- { label: '家庭成员失业人数', name: 'FamilyUnemployNumber', width: 150, align: "left" },
- { label: '赡养人口数', name: 'SupportNumber', width: 100, align: "left" },
- { label: '其他信息', name: 'OtherInformation', width: 100, align: "left" },
- {
- label: '是否特困供养', name: 'IsSpecialPovertySupport', width: 100, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- { label: '其他', name: 'Others', width: 100, align: "left" },
- {
- label: '家庭是否遭受疫情', name: 'FamilyIsSufferEpidemic', width: 150, align: "left",
- formatter: function (cellvalue) {
- return cellvalue == true ? "是" : "否";
- }
- },
- { label: '家庭遭受疫情具体情况描述', name: 'SufferEpidemicDescription', width: 200, align: "left" },
- {
- label: '认定困难级别名称', name: 'IdentifyDifficultyLevel', width: 150, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('dataItem', {
- key: value,
- code: 'DifficultyLevel',
- callback: function (_data) {
- callback(_data.text);
- }
- });
- }
- },
- {
- label: '认定时间', name: 'IdentifyTime', width: 100, align: "left", formatter: function (cellvalue) {
- if (cellvalue != null && cellvalue != undefined && cellvalue != "") {
- return cellvalue.substring(0, 11);
- }
- }
- },
- { label: '认定原因', name: 'IdentifyReason', width: 100, align: "left" },
- { label: '班级认定意见', name: 'ClassIdentifyOpinion', width: 100, align: "left" },
- { label: '年级认定意见', name: 'GradeIdentifyOpinion', width: 100, align: "left" },
- {
- label: '审核状态', name: 'Status', width: 100, align: "left", formatter: function (cellvalue) {
- return cellvalue == "0" ? "<span class=\"label label-default\">草稿</span>" : cellvalue == "1" ? "<span class=\"label label-success\">学院审核中</span>" : cellvalue == "2" ? "<span class=\"label label-success\">学工部审核中</span>" : cellvalue == "3" ? "<span class=\"label label-success\">已归档</span>" : "<span class=\"label label-default\">草稿</span>";
- }
- },
- {
- label: '创建人', name: 'CreateUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('custmerData', {
- url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser',
- key: value,
- keyId: 'f_userid',
- callback: function (_data) {
- callback(_data['f_realname']);
- }
- });
- }
- },
- { label: '创建时间', name: 'CreateTime', width: 130, align: "left" },
- { label: '提交时间', name: 'SubmitTime', width: 130, align: "left" },
- {
- label: '提交人', name: 'SubmitUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('custmerData', {
- url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser',
- key: value,
- keyId: 'f_userid',
- callback: function (_data) {
- callback(_data['f_realname']);
- }
- });
- }
- },
- {
- label: '学院审核人', name: 'FirstCheckUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('custmerData', {
- url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser',
- key: value,
- keyId: 'f_userid',
- callback: function (_data) {
- callback(_data['f_realname']);
- }
- });
- }
- },
- { label: '学院审核时间', name: 'FirstCheckTime', width: 130, align: "left" },
- {
- label: '学工部审核人', name: 'SecondCheckUserId', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) {
- learun.clientdata.getAsync('custmerData', {
- url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'BaseUser',
- key: value,
- keyId: 'f_userid',
- callback: function (_data) {
- callback(_data['f_realname']);
- }
- });
- }
- },
- { label: '学工部审核时间', name: 'SecondCheckTime', width: 130, align: "left" },
- ],
- mainId: 'Id',
- isPage: true,
- sidx: 'FirstCheckTime desc'
- });
- },
- search: function (param) {
- param = param || {};
- param.StartTime = startTime;
- param.EndTime = endTime;
- param.Step = "3";//第三步:学工部审核
- $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
- }
- };
- refreshGirdData = function () {
- page.search();
- };
- page.init();
- }
|