diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Controllers/NWFProcessController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Controllers/NWFProcessController.cs
index d696cb98d..ed978b3d2 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Controllers/NWFProcessController.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Controllers/NWFProcessController.cs
@@ -64,6 +64,12 @@ namespace Learun.Application.Web.Areas.LR_NewWorkFlow.Controllers
return View();
}
+ [HttpGet]
+ public ActionResult ApplyForIndex()
+ {
+ return View();
+ }
+
///
/// 创建流程
///
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/Index.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/Index.cshtml
new file mode 100644
index 000000000..03657cc84
--- /dev/null
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/Index.cshtml
@@ -0,0 +1,58 @@
+@{
+ ViewBag.Title = "流程(我的任务)";
+ Layout = "~/Views/Shared/_Index.cshtml";
+}
+
+@Html.AppendJsFile("/Areas/LR_NewWorkFlow/Views/NWFProcess/Index.js")
+
+
+
+
+
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/Index.js
new file mode 100644
index 000000000..97f12ff6a
--- /dev/null
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/Index.js
@@ -0,0 +1,458 @@
+/*
+ * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
+ * Copyright (c) 2013-2018 上海力软信息技术有限公司
+ * 创建人:力软-前端开发组
+ * 日 期:2017.08.04
+ * 描 述:流程(我的任务)
+ */
+var refreshGirdData;
+var bootstrap = function ($, learun) {
+ "use strict";
+ var categoryId = '2';
+ var logbegin = '';
+ var logend = '';
+
+ refreshGirdData = function () {
+ $('#gridtable').jfGridSet('reload');
+ }
+
+ var page = {
+ init: function () {
+ page.initleft();
+ page.initGrid();
+ 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,
+ // 默认
+ selectfn: function (begin, end) {
+ logbegin = begin;
+ logend = end;
+
+ page.search();
+ }
+ });
+ // 查询
+ $('#btn_Search').on('click', function () {
+ var keyword = $('#txt_Keyword').val();
+ page.search({ keyword: keyword });
+ });
+ // 刷新
+ $('#lr_refresh').on('click', function () {
+ location.reload();
+ });
+ // 查看流程进度
+ $('#lr_eye').on('click', function () {
+ page.eye();
+ });
+
+ // 发起流程
+ $('#lr_release').on('click', function () {
+ learun.layerForm({
+ id: 'form',
+ title: '选择流程模板',
+ url: top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/ReleaseForm',
+ height: 600,
+ width: 825,
+ maxmin: true,
+ callBack: function (id) {
+ return top[id].acceptClick();
+ }
+ });
+ });
+
+ // 审核流程
+ $('#lr_verify').on('click', function () {
+ page.verify();
+ });
+ // 批量审核
+ $('#lr_batchAudit').on('click', function () {
+ learun.layerForm({
+ id: 'BatchAuditIndex',
+ title: '批量审核',
+ url: top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/BatchAuditIndex',
+ height: 700,
+ width: 900,
+ maxmin: true,
+ btn: null
+ });
+ });
+ },
+ initleft: function () {
+ $('#lr_left_list li').on('click', function () {
+ var $this = $(this);
+ var $parent = $this.parent();
+ $parent.find('.active').removeClass('active');
+ $this.addClass('active');
+
+ categoryId = $this.attr('data-value');
+
+ if (categoryId == '2') {
+ $('#lr_verify').show();
+ $('#lr_verify span').text("审核");
+ }
+ else {
+ $('#lr_verify').hide();
+ }
+
+ page.search();
+ });
+ },
+ initGrid: function () {
+ $('#gridtable').lrAuthorizeJfGrid({
+ url: top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/GetTaskPageList',
+ headData: [
+ {
+ label: "任务", name: "F_TaskName", width: 160, align: "left",
+ formatter: function (cellvalue, row, dfop, $cell) {
+ if (row.F_EnabledMark == 3) {
+ if (categoryId == '1') {
+ return '本人发起';
+ }
+ else {
+ cellvalue;
+ }
+ }
+
+ // 草稿
+ if (row.F_EnabledMark == 2) {
+ $cell.on('click', '.create', function () {// 创建
+ // 关闭草稿页
+ learun.frameTab.closeByParam('tabProcessId', row.F_Id);
+
+ learun.frameTab.open({ F_ModuleId: row.F_Id, F_Icon: 'fa magic', F_FullName: '创建流程-' + row.F_SchemeName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?processId=' + row.F_Id + '&tabIframeId=' + row.F_Id + '&type=draftCreate' });
+ return false;
+ });
+ $cell.on('click', '.delete', function () {// 删除
+ learun.layerConfirm('是否确认删除该草稿?', function (res) {
+ if (res) {
+ // 关闭草稿页
+
+ learun.frameTab.closeByParam('tabProcessId', row.F_Id);
+ learun.deleteForm(top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/DeleteDraft', { processId: row.F_Id }, function () {
+ refreshGirdData();
+ });
+ }
+ });
+ return false;
+ });
+ return '编辑创建删除草稿';
+ }
+
+
+
+ var isaAain = false;
+ if (categoryId == '1') {
+ //如果流程是合同审批 并且校长审批通过的话可以打印
+ if (row.LeaderIsAgree && row.F_SchemeCode == 'LC_Contract_') {
+ $cell.on('click', '.print', function () {
+
+ learun.layerForm({
+ id: 'print',
+ title: '合同打印',
+ url: top.$.rootUrl +
+ '/LR_NewWorkFlow/NWFProcess/htPrint?keyValue=' + row.F_Id,
+ width: 1100,
+ height: 800,
+ btn: null
+ });
+ return false;
+ });
+ var _btnHtml = '打印';
+ return _btnHtml;
+ }
+ if (row.F_IsAgain == 1) {
+ isaAain = true;
+ }
+ else if (row.F_IsFinished == 0) {
+ // 加入催办和撤销按钮
+ $cell.on('click', '.urge', function () {// 催办审核
+ learun.layerConfirm('是否确认催办审核?', function (res, _index) {
+ if (res) {
+ learun.loading(true, '催办审核...');
+ var postData = {
+ processId: row.F_Id,
+ };
+ learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/UrgeFlow', postData, function (data) {
+ learun.loading(false);
+ });
+ top.layer.close(_index);
+ }
+ });
+ return false;
+ });
+ $cell.on('click', '.revoke', function () {// 删除
+ learun.layerConfirm('是否确认撤销流程?', function (res, _index) {
+ if (res) {
+
+ learun.loading(true, '撤销流程...');
+ var postData = {
+ processId: row.F_Id,
+ };
+ learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/RevokeFlow', postData, function (data) {
+ learun.loading(false);
+ refreshGirdData();
+ });
+ top.layer.close(_index);
+ }
+ });
+ return false;
+ });
+
+
+ var _btnHtml = '催办审核';
+ if (row.F_IsStart == 0) {
+ _btnHtml += '撤销流程';
+ }
+ return _btnHtml;
+ }
+ else {
+ return '本人发起';
+ }
+ }
+ if (row.F_TaskType == 3) {
+ return "【加签】" + cellvalue;
+ }
+ else if (row.F_TaskType == 5 && categoryId == '2') {
+ isaAain = true;
+ }
+ else if (row.F_TaskType == 5) {
+ return '重新发起';
+ }
+
+ if (isaAain) {
+ $cell.on('click', '.AgainCreate', function () {
+ var title = "";
+ if (row.F_SchemeName != row.F_Title && row.F_Title) {
+ title = row.F_SchemeName + "(" + row.F_Title + ")";
+ }
+ else {
+ title = row.F_SchemeName;
+ }
+ learun.frameTab.open({ F_ModuleId: row.F_Id, F_Icon: 'fa magic', F_FullName: '重新发起-' + title, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?processId=' + row.F_Id + '&tabIframeId=' + row.F_Id + '&type=againCreate' });
+ return false;
+ });
+ return '重新发起';
+ }
+
+
+ if (categoryId == '3' && row.F_TaskType == 1 && row.F_IsFinished == 0 && !row.NextNodeIsAudited) {// 已完成任务,添加一个撤销按钮
+ cellvalue = '撤销审核' + cellvalue;
+
+ $cell.on('click', '.revoke2', function () {// 删除
+ learun.layerConfirm('是否确认撤销审核?', function (res, _index) {
+ if (res) {
+
+ learun.loading(true, '撤销审核...');
+ var postData = {
+ processId: row.F_Id,
+ taskId: row.F_TaskId,
+ };
+ learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/RevokeAudit', postData, function (data) {
+ learun.loading(false);
+ refreshGirdData();
+ });
+ top.layer.close(_index);
+ }
+ });
+ return false;
+ });
+ }
+
+ return cellvalue;
+ }
+ },
+ {
+ label: "标题", name: "F_Title", width: 300, align: "left", formatter: function (cellvalue, row) {
+ if (row.F_SchemeName != row.F_Title && row.F_Title) {
+ return row.F_SchemeName + "(" + row.F_Title + ")";
+ }
+ else {
+ return row.F_SchemeName;
+ }
+ }
+ },
+ //{
+ // label: "等级", name: "F_Level", width: 60, align: "center",
+ // formatter: function (cellvalue) {
+ // switch (cellvalue) {
+ // case 0:
+ // return '普通';
+ // break;
+ // case 1:
+ // return '重要';
+ // break;
+ // case 2:
+ // return '紧急';
+ // break;
+ // default:
+ // return '普通';
+ // break;
+ // }
+ // }
+ //},
+ {
+ label: "状态", name: "F_EnabledMark", width: 70, align: "center",
+ formatter: function (cellvalue, row) {
+ if (row.F_TaskType == 4) {
+ if (row.F_IsUrge == "1" && categoryId == '2') {
+ return "催办加急";
+ }
+ return "运行中";
+ }
+ if (row.F_IsFinished == 0) {
+ if (cellvalue == 1) {
+ if (row.F_IsUrge == "1" && categoryId == '2') {
+ return "催办加急";
+ }
+ return "运行中";
+ } else if (cellvalue == 2) {
+ return "草稿";
+ }
+ else {
+ return "作废";
+ }
+ }
+ else {
+ if (cellvalue == 4) {
+ return "终止";
+ } else {
+ return "结束";
+ }
+ }
+
+ }
+ },
+ { label: "发起者", name: "F_CreateUserName", width: 70, align: "center" },
+ {
+ label: "时间", name: "F_CreateDate", width: 150, align: "left",
+ formatter: function (cellvalue) {
+ return learun.formatDate(cellvalue, 'yyyy-MM-dd hh:mm:ss');
+ }
+ }
+ ],
+ mainId: 'F_Id',
+ isPage: true,
+ sidx: 'F_CreateDate DESC',
+ onSelectRow: function (row) {
+ if (categoryId == '2') {
+ if (row.F_TaskType == 5) {
+ $('#lr_verify span').text("重新发起");
+ }
+ else if (row.F_TaskType == 3) {
+ $('#lr_verify span').text("【加签】" + row.F_TaskName);
+ }
+ else {
+ $('#lr_verify span').text(row.F_TaskName);
+ }
+ }
+ },
+ dblclick: function () {
+ if (categoryId == '2') {
+ page.verify();
+ }
+ else {
+ page.eye();
+ }
+ }
+ });
+ page.search();
+ },
+ search: function (param) {
+ param = param || {};
+ param.StartTime = logbegin;
+ param.EndTime = logend;
+
+ $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param), categoryId: categoryId });
+ },
+
+ verify: function () {
+ var processId = $('#gridtable').jfGridValue('F_Id');
+ var taskId = $('#gridtable').jfGridValue('F_TaskId');
+ var title = $('#gridtable').jfGridValue('F_Title');
+ var schemeName = $('#gridtable').jfGridValue('F_SchemeName');
+ var taskName = $('#gridtable').jfGridValue('F_TaskName');
+ var taskType = $('#gridtable').jfGridValue('F_TaskType');
+
+ if (schemeName != title && title) {
+ title = schemeName + "(" + title + ")";
+ }
+ else {
+ title = schemeName;
+ }
+
+ //1审批2传阅3加签4子流程5重新创建
+ switch (taskType) {
+ case 1:// 审批
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '审批-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=audit' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 2:// 传阅
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '查阅-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=refer' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 3:// 加签
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '加签审核-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=signAudit' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 4:// 子流程
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '子流程-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=chlid' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 5:// 重新创建
+ learun.frameTab.open({ F_ModuleId: processId, F_Icon: 'fa magic', F_FullName: '重新发起-' + title, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?processId=' + processId + '&tabIframeId=' + processId + '&type=againCreate' });
+ break;
+ case 6:// 重新创建
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '子流程-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=againChild' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ }
+ },
+ eye: function () {
+ var processId = $('#gridtable').jfGridValue('F_Id') || '';
+ var taskId = $('#gridtable').jfGridValue('F_TaskId') || '';
+ var title = $('#gridtable').jfGridValue('F_Title');
+ var schemeName = $('#gridtable').jfGridValue('F_SchemeName');
+ var taskType = $('#gridtable').jfGridValue('F_TaskType');
+
+ if (schemeName != title && title) {
+ title = schemeName + "(" + title + ")";
+ }
+ else {
+ title = schemeName;
+ }
+
+ var enabledMark = $('#gridtable').jfGridValue('F_EnabledMark');
+ if (enabledMark == 2) {// 草稿不允许查看进度
+ learun.alert.warning("草稿不能查看进度");
+ return;
+ }
+
+ if (learun.checkrow(processId)) {
+ if (taskType == '4' || taskType == '6') {
+ learun.frameTab.open({ F_ModuleId: processId + taskId, F_Icon: 'fa magic', F_FullName: '查看流程进度【' + title + '】', F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + processId + taskId + '&type=childlook' + "&processId=" + processId + "&taskId=" + taskId });
+ }
+ else {
+ learun.frameTab.open({ F_ModuleId: processId + taskId, F_Icon: 'fa magic', F_FullName: '查看流程进度【' + title + '】', F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + processId + taskId + '&type=look' + "&processId=" + processId + "&taskId=" + taskId });
+ }
+ }
+ }
+
+ };
+
+ page.init();
+}
+
+
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/ApplyForIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/ApplyForIndex.cshtml
new file mode 100644
index 000000000..fa3f082b1
--- /dev/null
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/ApplyForIndex.cshtml
@@ -0,0 +1,53 @@
+@{
+ ViewBag.Title = "流程(我的任务)";
+ Layout = "~/Views/Shared/_Index.cshtml";
+}
+
+
+
+
+
+ - 已申请奖学金
+ - 已完成申请奖学金
+ - 奖学金流程查看
+
+
+
+
+
+
+@Html.AppendJsFile("/Areas/LR_NewWorkFlow/Views/NWFProcess/ApplyForIndex.js")
\ No newline at end of file
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/ApplyForIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/ApplyForIndex.js
new file mode 100644
index 000000000..48d47e78d
--- /dev/null
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_NewWorkFlow/Views/NWFProcess/ApplyForIndex.js
@@ -0,0 +1,459 @@
+/*
+ * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
+ * Copyright (c) 2013-2018 上海力软信息技术有限公司
+ * 创建人:力软-前端开发组
+ * 日 期:2017.08.04
+ * 描 述:流程(我的任务)
+ */
+var refreshGirdData;
+var bootstrap = function ($, learun) {
+ "use strict";
+ var categoryId = '2';
+ var logbegin = '';
+ var logend = '';
+
+ refreshGirdData = function () {
+ $('#gridtable').jfGridSet('reload');
+ }
+
+ var page = {
+ init: function () {
+ page.initleft();
+ page.initGrid();
+ 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,
+ // 默认
+ selectfn: function (begin, end) {
+ logbegin = begin;
+ logend = end;
+
+ page.search();
+ }
+ });
+ // 查询
+ $('#btn_Search').on('click', function () {
+ var keyword = $('#txt_Keyword').val();
+ page.search({ keyword: keyword });
+ });
+ // 刷新
+ $('#lr_refresh').on('click', function () {
+ location.reload();
+ });
+ // 查看流程进度
+ $('#lr_eye').on('click', function () {
+ page.eye();
+ });
+
+ // 发起流程
+ $('#lr_release').on('click', function () {
+ learun.layerForm({
+ id: 'form',
+ title: '选择流程模板',
+ url: top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/ReleaseForm',
+ height: 600,
+ width: 825,
+ maxmin: true,
+ callBack: function (id) {
+ return top[id].acceptClick();
+ }
+ });
+ });
+
+ // 审核流程
+ $('#lr_verify').on('click', function () {
+ page.verify();
+ });
+ // 批量审核
+ $('#lr_batchAudit').on('click', function () {
+ learun.layerForm({
+ id: 'BatchAuditIndex',
+ title: '批量审核',
+ url: top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/BatchAuditIndex',
+ height: 700,
+ width: 900,
+ maxmin: true,
+ btn: null
+ });
+ });
+ },
+ initleft: function () {
+ $('#lr_left_list li').on('click', function () {
+ var $this = $(this);
+ var $parent = $this.parent();
+ $parent.find('.active').removeClass('active');
+ $this.addClass('active');
+
+ categoryId = $this.attr('data-value');
+
+ if (categoryId == '2') {
+ $('#lr_verify').show();
+ $('#lr_verify span').text("审核");
+ }
+ else {
+ $('#lr_verify').hide();
+ }
+
+ page.search();
+ });
+ },
+ initGrid: function () {
+ $('#gridtable').lrAuthorizeJfGrid({
+ url: top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/GetTaskPageList',
+ headData: [
+ {
+ label: "任务", name: "F_TaskName", width: 160, align: "left",
+ formatter: function (cellvalue, row, dfop, $cell) {
+ if (row.F_EnabledMark == 3) {
+ if (categoryId == '1') {
+ return '本人发起';
+ }
+ else {
+ cellvalue;
+ }
+ }
+
+ // 草稿
+ if (row.F_EnabledMark == 2) {
+ $cell.on('click', '.create', function () {// 创建
+ // 关闭草稿页
+ learun.frameTab.closeByParam('tabProcessId', row.F_Id);
+
+ learun.frameTab.open({ F_ModuleId: row.F_Id, F_Icon: 'fa magic', F_FullName: '创建流程-' + row.F_SchemeName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?processId=' + row.F_Id + '&tabIframeId=' + row.F_Id + '&type=draftCreate' });
+ return false;
+ });
+ $cell.on('click', '.delete', function () {// 删除
+ learun.layerConfirm('是否确认删除该草稿?', function (res) {
+ if (res) {
+ // 关闭草稿页
+
+ learun.frameTab.closeByParam('tabProcessId', row.F_Id);
+ learun.deleteForm(top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/DeleteDraft', { processId: row.F_Id }, function () {
+ refreshGirdData();
+ });
+ }
+ });
+ return false;
+ });
+ return '编辑创建删除草稿';
+ }
+
+
+
+ var isaAain = false;
+ if (categoryId == '1') {
+ //如果流程是合同审批 并且校长审批通过的话可以打印
+ if (row.LeaderIsAgree && row.F_SchemeCode == 'LC_Contract_') {
+ $cell.on('click', '.print', function () {
+
+ learun.layerForm({
+ id: 'print',
+ title: '合同打印',
+ url: top.$.rootUrl +
+ '/LR_NewWorkFlow/NWFProcess/htPrint?keyValue=' + row.F_Id,
+ width: 1100,
+ height: 800,
+ btn: null
+ });
+ return false;
+ });
+ var _btnHtml = '打印';
+ return _btnHtml;
+ }
+ if (row.F_IsAgain == 1) {
+ isaAain = true;
+ }
+ else if (row.F_IsFinished == 0) {
+ // 加入催办和撤销按钮
+ $cell.on('click', '.urge', function () {// 催办审核
+ learun.layerConfirm('是否确认催办审核?', function (res, _index) {
+ if (res) {
+ learun.loading(true, '催办审核...');
+ var postData = {
+ processId: row.F_Id,
+ };
+ learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/UrgeFlow', postData, function (data) {
+ learun.loading(false);
+ });
+ top.layer.close(_index);
+ }
+ });
+ return false;
+ });
+ $cell.on('click', '.revoke', function () {// 删除
+ learun.layerConfirm('是否确认撤销流程?', function (res, _index) {
+ if (res) {
+
+ learun.loading(true, '撤销流程...');
+ var postData = {
+ processId: row.F_Id,
+ };
+ learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/RevokeFlow', postData, function (data) {
+ learun.loading(false);
+ refreshGirdData();
+ });
+ top.layer.close(_index);
+ }
+ });
+ return false;
+ });
+
+
+ var _btnHtml = '催办审核';
+ if (row.F_IsStart == 0) {
+ _btnHtml += '撤销流程';
+ }
+ return _btnHtml;
+ }
+ else {
+ return '本人发起';
+ }
+ }
+ if (row.F_TaskType == 3) {
+ return "【加签】" + cellvalue;
+ }
+ else if (row.F_TaskType == 5 && categoryId == '2') {
+ isaAain = true;
+ }
+ else if (row.F_TaskType == 5) {
+ return '重新发起';
+ }
+
+ if (isaAain) {
+ $cell.on('click', '.AgainCreate', function () {
+ var title = "";
+ if (row.F_SchemeName != row.F_Title && row.F_Title) {
+ title = row.F_SchemeName + "(" + row.F_Title + ")";
+ }
+ else {
+ title = row.F_SchemeName;
+ }
+ learun.frameTab.open({ F_ModuleId: row.F_Id, F_Icon: 'fa magic', F_FullName: '重新发起-' + title, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?processId=' + row.F_Id + '&tabIframeId=' + row.F_Id + '&type=againCreate' });
+ return false;
+ });
+ return '重新发起';
+ }
+
+
+ if (categoryId == '3' && row.F_TaskType == 1 && row.F_IsFinished == 0 && !row.NextNodeIsAudited) {// 已完成任务,添加一个撤销按钮
+ cellvalue = '撤销审核' + cellvalue;
+
+ $cell.on('click', '.revoke2', function () {// 删除
+ learun.layerConfirm('是否确认撤销审核?', function (res, _index) {
+ if (res) {
+
+ learun.loading(true, '撤销审核...');
+ var postData = {
+ processId: row.F_Id,
+ taskId: row.F_TaskId,
+ };
+ learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/RevokeAudit', postData, function (data) {
+ learun.loading(false);
+ refreshGirdData();
+ });
+ top.layer.close(_index);
+ }
+ });
+ return false;
+ });
+ }
+
+ return cellvalue;
+ }
+ },
+ {
+ label: "标题", name: "F_Title", width: 300, align: "left", formatter: function (cellvalue, row) {
+ if (row.F_SchemeName != row.F_Title && row.F_Title) {
+ return row.F_SchemeName + "(" + row.F_Title + ")";
+ }
+ else {
+ return row.F_SchemeName;
+ }
+ }
+ },
+ //{
+ // label: "等级", name: "F_Level", width: 60, align: "center",
+ // formatter: function (cellvalue) {
+ // switch (cellvalue) {
+ // case 0:
+ // return '普通';
+ // break;
+ // case 1:
+ // return '重要';
+ // break;
+ // case 2:
+ // return '紧急';
+ // break;
+ // default:
+ // return '普通';
+ // break;
+ // }
+ // }
+ //},
+ {
+ label: "状态", name: "F_EnabledMark", width: 70, align: "center",
+ formatter: function (cellvalue, row) {
+ if (row.F_TaskType == 4) {
+ if (row.F_IsUrge == "1" && categoryId == '2') {
+ return "催办加急";
+ }
+ return "运行中";
+ }
+ if (row.F_IsFinished == 0) {
+ if (cellvalue == 1) {
+ if (row.F_IsUrge == "1" && categoryId == '2') {
+ return "催办加急";
+ }
+ return "运行中";
+ } else if (cellvalue == 2) {
+ return "草稿";
+ }
+ else {
+ return "作废";
+ }
+ }
+ else {
+ if (cellvalue == 4) {
+ return "终止";
+ } else {
+ return "结束";
+ }
+ }
+
+ }
+ },
+ { label: "发起者", name: "F_CreateUserName", width: 70, align: "center" },
+ {
+ label: "时间", name: "F_CreateDate", width: 150, align: "left",
+ formatter: function (cellvalue) {
+ return learun.formatDate(cellvalue, 'yyyy-MM-dd hh:mm:ss');
+ }
+ }
+ ],
+ mainId: 'F_Id',
+ isPage: true,
+ sidx: 'F_CreateDate DESC',
+ onSelectRow: function (row) {
+ if (categoryId == '2') {
+ if (row.F_TaskType == 5) {
+ $('#lr_verify span').text("重新发起");
+ }
+ else if (row.F_TaskType == 3) {
+ $('#lr_verify span').text("【加签】" + row.F_TaskName);
+ }
+ else {
+ $('#lr_verify span').text(row.F_TaskName);
+ }
+ }
+ },
+ dblclick: function () {
+ if (categoryId == '2') {
+ page.verify();
+ }
+ else {
+ page.eye();
+ }
+ }
+ });
+ page.search();
+ },
+ search: function (param) {
+ param = param || {};
+ param.StartTime = logbegin;
+ param.EndTime = logend;
+ param.ProcessName = "Subsidy01Apply";
+
+ $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param), categoryId: categoryId });
+ },
+
+ verify: function () {
+ var processId = $('#gridtable').jfGridValue('F_Id');
+ var taskId = $('#gridtable').jfGridValue('F_TaskId');
+ var title = $('#gridtable').jfGridValue('F_Title');
+ var schemeName = $('#gridtable').jfGridValue('F_SchemeName');
+ var taskName = $('#gridtable').jfGridValue('F_TaskName');
+ var taskType = $('#gridtable').jfGridValue('F_TaskType');
+
+ if (schemeName != title && title) {
+ title = schemeName + "(" + title + ")";
+ }
+ else {
+ title = schemeName;
+ }
+
+ //1审批2传阅3加签4子流程5重新创建
+ switch (taskType) {
+ case 1:// 审批
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '审批-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=audit' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 2:// 传阅
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '查阅-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=refer' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 3:// 加签
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '加签审核-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=signAudit' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 4:// 子流程
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '子流程-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=chlid' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ case 5:// 重新创建
+ learun.frameTab.open({ F_ModuleId: processId, F_Icon: 'fa magic', F_FullName: '重新发起-' + title, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?processId=' + processId + '&tabIframeId=' + processId + '&type=againCreate' });
+ break;
+ case 6:// 重新创建
+ learun.frameTab.open({ F_ModuleId: taskId, F_Icon: 'fa magic', F_FullName: '子流程-' + title + '/' + taskName, F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + taskId + '&type=againChild' + "&processId=" + processId + "&taskId=" + taskId });
+ break;
+ }
+ },
+ eye: function () {
+ var processId = $('#gridtable').jfGridValue('F_Id') || '';
+ var taskId = $('#gridtable').jfGridValue('F_TaskId') || '';
+ var title = $('#gridtable').jfGridValue('F_Title');
+ var schemeName = $('#gridtable').jfGridValue('F_SchemeName');
+ var taskType = $('#gridtable').jfGridValue('F_TaskType');
+
+ if (schemeName != title && title) {
+ title = schemeName + "(" + title + ")";
+ }
+ else {
+ title = schemeName;
+ }
+
+ var enabledMark = $('#gridtable').jfGridValue('F_EnabledMark');
+ if (enabledMark == 2) {// 草稿不允许查看进度
+ learun.alert.warning("草稿不能查看进度");
+ return;
+ }
+
+ if (learun.checkrow(processId)) {
+ if (taskType == '4' || taskType == '6') {
+ learun.frameTab.open({ F_ModuleId: processId + taskId, F_Icon: 'fa magic', F_FullName: '查看流程进度【' + title + '】', F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + processId + taskId + '&type=childlook' + "&processId=" + processId + "&taskId=" + taskId });
+ }
+ else {
+ learun.frameTab.open({ F_ModuleId: processId + taskId, F_Icon: 'fa magic', F_FullName: '查看流程进度【' + title + '】', F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + processId + taskId + '&type=look' + "&processId=" + processId + "&taskId=" + taskId });
+ }
+ }
+ }
+
+ };
+
+ page.init();
+}
+
+
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/StudentWork/Views/SW_Ask_Main/ApplyForIndex.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/StudentWork/Views/SW_Ask_Main/ApplyForIndex.cshtml
new file mode 100644
index 000000000..99d48fa8c
--- /dev/null
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/StudentWork/Views/SW_Ask_Main/ApplyForIndex.cshtml
@@ -0,0 +1,46 @@
+@{
+ ViewBag.Title = "奖学金申请)";
+ Layout = "~/Views/Shared/_Index.cshtml";
+}
+
+
+
+
+
+ - 可申请奖学金
+ - 已申请奖学金
+ - 我的流程
+
+
+
+
+
+
+@Html.AppendJsFile("/Areas/StudentWork/Views/SW_Ask_Main/ApplyForIndex.js")
\ No newline at end of file
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/StudentWork/Views/SW_Ask_Main/ApplyForIndex.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/StudentWork/Views/SW_Ask_Main/ApplyForIndex.js
new file mode 100644
index 000000000..adedb6687
--- /dev/null
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/StudentWork/Views/SW_Ask_Main/ApplyForIndex.js
@@ -0,0 +1,188 @@
+/*
+ * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
+ * Copyright (c) 2013-2018 上海力软信息技术有限公司
+ * 创建人:力软-前端开发组
+ * 日 期:2017.08.04
+ * 描 述:流程(我的任务)
+ */
+var refreshGirdData;
+var bootstrap = function ($, learun) {
+ "use strict";
+ var categoryId = '2';
+ var logbegin = '';
+ var logend = '';
+
+ refreshGirdData = function () {
+ $('#gridtable').jfGridSet('reload');
+ }
+
+ var page = {
+ init: function () {
+ page.initleft();
+ page.initGrid();
+ 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,
+ // 默认
+ selectfn: function (begin, end) {
+ logbegin = begin;
+ logend = end;
+
+ page.search();
+ }
+ });
+ // 查询
+ $('#btn_Search').on('click', function () {
+ var keyword = $('#txt_Keyword').val();
+ page.search({ keyword: keyword });
+ });
+ // 刷新
+ $('#lr_refresh').on('click', function () {
+ location.reload();
+ });
+ // 查看流程进度
+ $('#lr_eye').on('click', function () {
+ page.eye();
+ });
+
+ //// 发起流程
+ //$('#lr_release').on('click', function () {
+ // learun.layerForm({
+ // id: 'form',
+ // title: '选择流程模板',
+ // url: top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/ReleaseForm',
+ // height: 600,
+ // width: 825,
+ // maxmin: true,
+ // callBack: function (id) {
+ // return top[id].acceptClick();
+ // }
+ // });
+ //});
+
+ //// 审核流程
+ //$('#lr_verify').on('click', function () {
+ // page.verify();
+ //});
+ },
+ initleft: function () {
+ $('#lr_left_list li').on('click', function () {
+ var $this = $(this);
+ var $parent = $this.parent();
+ $parent.find('.active').removeClass('active');
+ $this.addClass('active');
+
+ categoryId = $this.attr('data-value');
+
+ if (categoryId == '2') {
+ $('#lr_verify').show();
+ $('#lr_verify span').text("审核");
+ }
+ else {
+ $('#lr_verify').hide();
+ }
+
+ page.search();
+ });
+ },
+ initGrid: function () {
+ $('#gridtable').jfGrid({
+ url: top.$.rootUrl + '/StudentWork/SW_Ask_Main/GetPageList',
+ headData: [
+ { label: "问卷编号", name: "VSerial", width: 180, align: "left" },
+ { label: "标题", name: "VTitle", width: 200, align: "left" },
+ {
+ label: "类别", name: "TId", width: 100, align: "left",
+ formatterAsync: function (callback, value, row, op, $cell) {
+ learun.clientdata.getAsync('custmerData', {
+ url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'SW_Ask_Type',
+ key: value,
+ keyId: 'id',
+ callback: function (_data) {
+ callback(_data['tname']);
+ }
+ });
+ }
+ },
+ { label: "学年", name: "AcademicYearNo", width: 80, align: "left" },
+ { label: "学期", name: "Semester", width: 80, align: "left" },
+ { label: "排序", name: "VOrder", width: 80, align: "left" },
+ //{
+ // label: "是否提交", name: "IsSubmit", width: 100, align: "left", formatter: function (cellvalue) {
+ // return cellvalue == true ? "" : "";
+ // }
+ //},
+ //{
+ // label: "启用标志", name: "Status", width: 100, align: "left", formatter: function (cellvalue) {
+ // return cellvalue == true ? "" : "";
+ // }
+ //}
+ ],
+ mainId: 'VID',
+ isPage: true,
+ sidx: 'VOrder'
+ });
+ page.search();
+ },
+ search: function (param) {
+ param = param || {};
+ param.StartTime = logbegin;
+ param.EndTime = logend;
+
+ $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param), categoryId: categoryId });
+ },
+
+ eye: function () {
+ var processId = $('#gridtable').jfGridValue('F_Id') || '';
+ var taskId = $('#gridtable').jfGridValue('F_TaskId') || '';
+ var title = $('#gridtable').jfGridValue('F_Title');
+ var schemeName = $('#gridtable').jfGridValue('F_SchemeName');
+ var taskType = $('#gridtable').jfGridValue('F_TaskType');
+
+ if (schemeName != title && title) {
+ title = schemeName + "(" + title + ")";
+ }
+ else {
+ title = schemeName;
+ }
+
+ var enabledMark = $('#gridtable').jfGridValue('F_EnabledMark');
+ if (enabledMark == 2) {// 草稿不允许查看进度
+ learun.alert.warning("草稿不能查看进度");
+ return;
+ }
+
+ if (learun.checkrow(processId)) {
+ if (taskType == '4' || taskType == '6') {
+ learun.frameTab.open({ F_ModuleId: processId + taskId, F_Icon: 'fa magic', F_FullName: '查看流程进度【' + title + '】', F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + processId + taskId + '&type=childlook' + "&processId=" + processId + "&taskId=" + taskId });
+ }
+ else {
+ learun.frameTab.open({ F_ModuleId: processId + taskId, F_Icon: 'fa magic', F_FullName: '查看流程进度【' + title + '】', F_UrlAddress: '/LR_NewWorkFlow/NWFProcess/NWFContainerForm?tabIframeId=' + processId + taskId + '&type=look' + "&processId=" + processId + "&taskId=" + taskId });
+ }
+ }
+ }
+
+ };
+
+ page.init();
+}
+
+
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj
index e0293d3ca..24beacdc0 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj
@@ -1352,9 +1352,11 @@
+
+
@@ -7380,6 +7382,8 @@
+
+
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Process/NWFProcessSerivce.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Process/NWFProcessSerivce.cs
index ecbd008db..b44a3f0e1 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Process/NWFProcessSerivce.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/Process/NWFProcessSerivce.cs
@@ -232,6 +232,11 @@ namespace Learun.Application.WorkFlow
{
expression = expression.And(t => t.F_SchemeCode.Equals(schemeCode));
}
+ if (!queryParam["ProcessName"].IsEmpty())
+ {
+ string NewschemeCode = queryParam["ProcessName"].ToString();
+ expression = expression.And(t => t.F_SchemeCode.Contains(NewschemeCode));
+ }
expression = expression.And(t => t.F_IsChild == 0);
var aa = this.BaseRepository().FindList(expression, pagination);
foreach (var item in aa)
@@ -391,7 +396,11 @@ namespace Learun.Application.WorkFlow
keyword = "%" + queryParam["keyword"].ToString() + "%";
strSql.Append(" AND ( p.F_Title like @keyword OR p.F_SchemeName like @keyword ) ");
}
-
+ if (!queryParam["ProcessName"].IsEmpty())
+ {
+ //NewschemeCode = "%" + queryParam["schemeCode"].ToString() + "%";
+ strSql.Append(" AND p.F_SchemeCode like '@%" + queryParam["ProcessName"].ToString() + "%' ");
+ }
if (!string.IsNullOrEmpty(schemeCode))
{
strSql.Append(" AND p.F_SchemeCode = @schemeCode ");
@@ -577,6 +586,11 @@ namespace Learun.Application.WorkFlow
keyword = "%" + queryParam["keyword"].ToString() + "%";
strSql.Append(" AND ( p.F_ProcessName like @keyword OR p.F_SchemeName like @keyword ) ");
}
+ if (!queryParam["ProcessName"].IsEmpty())
+ {
+ //NewschemeCode = "%" + queryParam["schemeCode"].ToString() + "%";
+ strSql.Append(" AND p.F_SchemeCode like '%@" + queryParam["ProcessName"].ToString() + "%' ");
+ }
if (!string.IsNullOrEmpty(schemeCode))
{
strSql.Append(" AND p.F_SchemeCode = @schemeCode ");