diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/Form.cshtml
index 949b5ee1e..4eecae013 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/Form.cshtml
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/Form.cshtml
@@ -21,11 +21,11 @@
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.cshtml
index baa5705a1..374909d61 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.cshtml
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.cshtml
@@ -40,11 +40,12 @@
提交
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.js
index 9be3e8340..566c29a2e 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.js
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyApply.js
@@ -137,9 +137,34 @@ var bootstrap = function ($, learun) {
});
}
});
- // 考勤
// 纪要
+ $('#lr_minutes').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ learun.layerForm({
+ id: 'MeetingMinutesIndex',
+ title: '会议纪要',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingMinutes/Index?MeetID=' + keyValue,
+ width: 1000,
+ height: 800,
+ btn: null
+ });
+ }
+ });
// 通知
+ $('#lr_notice').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ learun.layerForm({
+ id: 'MeetingNoticeIndex',
+ title: '会议通知',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingNotice/Index?MeetID=' + keyValue,
+ width: 1000,
+ height: 800,
+ btn: null
+ });
+ }
+ });
// 审核通过
$('#lr_checkyes').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('Id');
@@ -176,6 +201,20 @@ var bootstrap = function ($, learun) {
});
}
});
+ // 会议签到情况
+ $('#lr_case').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ learun.layerForm({
+ id: 'viewform',
+ title: '签到情况',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingSignInRecord/Index?MeetID=' + keyValue,
+ width: 1000,
+ height: 800,
+ btn: null
+ });
+ }
+ });
},
// 初始化列表
initGird: function () {
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.cshtml
index a7873c2ad..00e6f0a8d 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.cshtml
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.cshtml
@@ -1,7 +1,7 @@
@{
/**/
- ViewBag.Title = "我参加的会议";
+ ViewBag.Title = "会议管理";
Layout = "~/Views/Shared/_Index.cshtml";
}
@@ -34,8 +34,15 @@
+
-
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.js
index 36c36c606..ab540e8ed 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.js
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/MeetingManagement/IndexOfMyJoin.js
@@ -28,6 +28,79 @@ var bootstrap = function ($, learun) {
$('#lr_refresh').on('click', function () {
location.reload();
});
+ // 新增
+ $('#lr_add').on('click', function () {
+ learun.layerForm({
+ id: 'addform',
+ title: '新增',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingManagement/Form',
+ width: 1000,
+ height: 800,
+ callBack: function (id) {
+ var res = false;
+ // 验证数据
+ res = top[id].validForm();
+ // 保存数据
+ if (res) {
+ res = top[id].save('', function () {
+ page.search();
+ });
+ }
+ return res;
+ }
+ });
+ });
+ // 编辑
+ $('#lr_edit').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ var CheckStatus = $('#gridtable').jfGridValue('CheckStatus');
+ if (CheckStatus == "1") {
+ learun.alert.warning("当前项已审核通过!");
+ return false;
+ } else if (CheckStatus == "3") {
+ learun.alert.warning("当前项审核中!");
+ return false;
+ }
+ learun.layerForm({
+ id: 'editform',
+ title: '编辑',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingManagement/Form?keyValue=' + keyValue,
+ width: 1000,
+ height: 800,
+ callBack: function (id) {
+ var res = false;
+ // 验证数据
+ res = top[id].validForm();
+ // 保存数据
+ if (res) {
+ res = top[id].save('', function () {
+ page.search();
+ });
+ }
+ return res;
+ }
+ });
+ }
+ });
+ // 删除
+ $('#lr_delete').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ var CheckStatus = $('#gridtable').jfGridValue('CheckStatus');
+ if (CheckStatus != "0") {
+ learun.alert.warning("当前项已审核或审核中!");
+ return false;
+ }
+ learun.layerConfirm('是否确认删除该项!', function (res) {
+ if (res) {
+ learun.deleteForm(top.$.rootUrl + '/PersonnelManagement/MeetingManagement/DeleteForm', { keyValue: keyValue }, function () {
+ refreshGirdData();
+ });
+ }
+ });
+ }
+ });
// 查看
$('#lr_view').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('Id');
@@ -42,7 +115,106 @@ var bootstrap = function ($, learun) {
});
}
});
-
+ //提交
+ $('#lr_submit').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ var CheckStatus = $('#gridtable').jfGridValue('CheckStatus');
+ if (CheckStatus == "1") {
+ learun.alert.warning("当前项已审核通过!");
+ return false;
+ } else if (CheckStatus == "3") {
+ learun.alert.warning("当前项审核中!");
+ return false;
+ }
+ learun.layerConfirm('是否确认提交该项!', function (res) {
+ if (res) {
+ processId = learun.newGuid();
+ learun.postForm(top.$.rootUrl + '/PersonnelManagement/MeetingManagement/DoSubmit', { keyValue: keyValue, status: '3', processId: processId }, function (res) {
+ refreshGirdData(res, {});
+ });
+ }
+ });
+ }
+ });
+ // 纪要
+ $('#lr_minutes').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ learun.layerForm({
+ id: 'MeetingMinutesIndex',
+ title: '会议纪要',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingMinutes/Index?MeetID=' + keyValue,
+ width: 1000,
+ height: 800,
+ btn: null
+ });
+ }
+ });
+ // 通知
+ $('#lr_notice').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ learun.layerForm({
+ id: 'MeetingNoticeIndex',
+ title: '会议通知',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingNotice/Index?MeetID=' + keyValue,
+ width: 1000,
+ height: 800,
+ btn: null
+ });
+ }
+ });
+ // 审核通过
+ $('#lr_checkyes').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ var CheckStatus = $('#gridtable').jfGridValue('CheckStatus');
+ if (CheckStatus == '1') {
+ learun.alert.warning("该项已审核通过!");
+ return false;
+ }
+ learun.layerConfirm('是否确认审核通过该项!', function (res) {
+ if (res) {
+ learun.postForm(top.$.rootUrl + '/PersonnelManagement/MeetingManagement/DoCheck', { keyValue: keyValue, status: '1' }, function () {
+ refreshGirdData();
+ });
+ }
+ });
+ }
+ });
+ // 审核不通过
+ $('#lr_checkno').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ var CheckStatus = $('#gridtable').jfGridValue('CheckStatus');
+ if (CheckStatus == '2') {
+ learun.alert.warning("该项已审核不通过!");
+ return false;
+ }
+ learun.layerConfirm('是否确认审核不通过该项!', function (res) {
+ if (res) {
+ learun.postForm(top.$.rootUrl + '/PersonnelManagement/MeetingManagement/DoCheck', { keyValue: keyValue, status: '2' }, function () {
+ refreshGirdData();
+ });
+ }
+ });
+ }
+ });
+ // 会议签到情况
+ $('#lr_case').on('click', function () {
+ var keyValue = $('#gridtable').jfGridValue('Id');
+ if (learun.checkrow(keyValue)) {
+ learun.layerForm({
+ id: 'viewform',
+ title: '签到情况',
+ url: top.$.rootUrl + '/PersonnelManagement/MeetingSignInRecord/Index?MeetID=' + keyValue,
+ width: 1000,
+ height: 800,
+ btn: null
+ });
+ }
+ });
},
// 初始化列表
initGird: function () {
@@ -114,6 +286,17 @@ var bootstrap = function ($, learun) {
}
};
refreshGirdData = function (res, postData) {
+ if (res && res.code && res.code == 200) {
+ // 发起流程
+ var postData = {
+ schemeCode: 'MeetingManagementApply',// 填写流程对应模板编号
+ processId: processId,
+ level: '1',
+ };
+ learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) {
+ learun.loading(false);
+ });
+ }
page.search();
};
page.init();
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config b/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config
index f51265c4d..88ff6ac00 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/XmlConfig/ioc.config
@@ -38,6 +38,7 @@
+
@@ -87,6 +88,7 @@
+
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementBLL.cs
index c39cfa2a1..1691871cf 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementBLL.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementBLL.cs
@@ -138,7 +138,7 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
}
}
}
-
+
#endregion
#region 提交数据
@@ -262,6 +262,25 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
}
}
}
+ public void ReceivedList(string processId)
+ {
+ try
+ {
+ meetingManagementService.ReceivedList(processId);
+ }
+ catch (Exception ex)
+ {
+ if (ex is ExceptionEx)
+ {
+ throw;
+ }
+ else
+ {
+ throw ExceptionEx.ThrowBusinessException(ex);
+ }
+ }
+ }
+
#endregion
}
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementIBLL.cs
index 744cc0d95..f5b40cf1c 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementIBLL.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementIBLL.cs
@@ -82,6 +82,9 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
///
///
void ChangeStatusByProcessId(string processId, string status, string userId);
+
+ void ReceivedList(string processId);
+
#endregion
}
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementService.cs
index 23a1c40d0..01906403d 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementService.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/MeetingManagement/MeetingManagementService.cs
@@ -1,11 +1,19 @@
using Dapper;
using Learun.Application.Organization;
+using Learun.Application.TwoDevelopment.EducationalAdministration;
+using Learun.Application.TwoDevelopment.LR_Desktop;
using Learun.DataBase.Repository;
using Learun.Util;
+using Microsoft.AspNet.SignalR.Client;
+using Newtonsoft.Json;
using System;
using System.Collections.Generic;
+using System.Configuration;
using System.Data;
+using System.Linq;
using System.Text;
+using System.Threading.Tasks;
+using System.Web;
namespace Learun.Application.TwoDevelopment.PersonnelManagement
{
@@ -127,7 +135,12 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
{
try
{
- return this.BaseRepository("CollegeMIS").FindEntity(keyValue);
+ var data = this.BaseRepository("CollegeMIS").FindEntity(keyValue);
+ if (data != null)
+ {
+ data.ConferenceRoomName = this.BaseRepository("CollegeMIS").FindEntity(data.MeetingPlace).Name;
+ }
+ return data;
}
catch (Exception ex)
{
@@ -516,7 +529,112 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
}
}
+ public void ReceivedList(string processId)
+ {
+ var Received = GetMeetingManagementEntityByProcessId(processId);
+ List userInfos = new List();
+ foreach (var rid in Received.InternalParticipants.Split(','))
+ {
+ var user = this.BaseRepository().FindEntity(m => m.F_UserId == rid);
+ if (!userInfos.Contains(user))
+ {
+ userInfos.Add(user);
+ }
+ }
+ if (!string.IsNullOrEmpty(Received.RecordPerson))
+ {
+ foreach (var rid in Received.RecordPerson.Split(','))
+ {
+ var user = this.BaseRepository().FindEntity(m => m.F_UserId == rid);
+ if (!userInfos.Contains(user))
+ {
+ userInfos.Add(user);
+ }
+ }
+ }
+ //foreach (var uitem in userInfos)
+ //{
+ // SYS_ReceiveMessageEntity receiveMessageEntity = new SYS_ReceiveMessageEntity();
+ // receiveMessageEntity.Create();
+ // receiveMessageEntity.SENDERID = Received.SENDERID;
+ // receiveMessageEntity.SENDER = messageentity.SENDER;
+ // receiveMessageEntity.RECEIVERID = uitem.F_UserId;
+ // receiveMessageEntity.RECEIVER = uitem.F_RealName;
+ // receiveMessageEntity.TITLE = messageentity.TITLE;
+ // receiveMessageEntity.CONTENTS = messageentity.CONTENTS;
+ // receiveMessageEntity.URL = messageentity.URL;
+ // receiveMessageEntity.READFLAG = 0;
+ // receiveMessageEntity.SENDTIME = DateTime.Now;
+ // receiveMessageEntity.DelFlag = false;
+ // this.BaseRepository().Insert(receiveMessageEntity);
+ //}
+
+ //读取信息推送管理-会议申请推送(03)的配置
+ var informationPushEntity = this.BaseRepository().FindEntity(x => x.PushItem == "03");
+ if (informationPushEntity != null && informationPushEntity.Status == true)
+ {
+ //微信推送
+ try
+ {
+ PushWeixin(userInfos, Received.MeetingTitle);
+ }
+ catch (Exception e)
+ {
+ }
+ //飞星推送
+ Task.Run(async () =>
+ {
+ using (var hubConnection = new HubConnection(ConfigurationManager.AppSettings["CommunicationServeraddress"]))
+ {
+ var hubProxy = hubConnection.CreateHubProxy("SignalRHub");
+ await hubConnection.Start();
+ await hubProxy.Invoke("PushAnnouncement", Received.InternalParticipants, Received.MeetingTitle, Util.Str.ReplaceHtml(HttpUtility.HtmlDecode(Received.Content)).Length < 20 ? Util.Str.ReplaceHtml(HttpUtility.HtmlDecode(Received.Content)) : Util.Str.ReplaceHtml(HttpUtility.HtmlDecode(Received.Content)).Substring(0, 20), "mail", string.Join(",", userInfos.Select(m => m.F_UserId)), "");
+ }
+ });
+ }
+ }
+ public void PushWeixin(List needpostuserlist, string title)
+ {
+ var WeChatConfigentity = BaseRepository().FindEntity(m => m.IsEnable == true);
+ string appid = WeChatConfigentity.APPId;
+ string secret = WeChatConfigentity.secret;
+ var wechatemplete = BaseRepository()
+ .FindEntity(m => m.WeID == WeChatConfigentity.ID && m.TCode == "task");
+ string weixintaskurl = wechatemplete.TUrl;
+ string weixintasktempid = wechatemplete.TempId;
+ var responsejson = Util.HttpMethods.HttpGet("https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=" + appid + "&secret=" + secret);
+ foreach (UserEntity userinfo in needpostuserlist)
+ {
+ if (userinfo != null && !string.IsNullOrEmpty(userinfo.OpenIdForWeixin))
+ {
+ //执行推送任务
+ if (!string.IsNullOrEmpty(appid) && !string.IsNullOrEmpty(secret) && !string.IsNullOrEmpty(weixintaskurl) && !string.IsNullOrEmpty(weixintasktempid))
+ {
+ if (!string.IsNullOrEmpty(responsejson))
+ {
+ var weixintokenobj = JsonConvert.DeserializeObject(responsejson);
+ if (string.IsNullOrEmpty(weixintokenobj.errcode))
+ {
+ string access_token = weixintokenobj.access_token;
+ string jsondata = "{\"touser\":\"" + userinfo.OpenIdForWeixin + "\"," +
+ "\"template_id\":\"" + weixintasktempid + "\"," +
+ "\"url\":\"" + weixintaskurl + "\"," +
+ "\"data\":{" +
+ "\"first\": {\"value\":\"您有新的会议消息\",\"color\":\"#173177\"}," +
+ "\"keyword1\":{\"value\":\"未读邮件\",\"color\":\"#173177\"}," +
+ "\"keyword2\": {\"value\":\"" + title + "\",\"color\":\"#173177\"}," +
+ "\"keyword3\": {\"value\":\"待查看\",\"color\":\"#173177\"}," +
+ "\"keyword4\": {\"value\":\"您有新的未读会议【" + title + "】\",\"color\":\"#173177\"}" +
+ "}" +
+ "}";
+ string pushresult = Util.HttpMethods.HttpPost("https://api.weixin.qq.com/cgi-bin/message/template/send?access_token=" + access_token, jsondata);
+ }
+ }
+ }
+ }
+ }
+ }
#endregion
}
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/MeetingManagementApplyMethod.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/MeetingManagementApplyMethod.cs
index 55ee0ae70..c5b80c399 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/MeetingManagementApplyMethod.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.WorkFlow/NodeMethod/MeetingManagementApplyMethod.cs
@@ -17,6 +17,7 @@ namespace Learun.Application.WorkFlow
if (parameter.code == "agree")
{
meetingManagementIBLL.ChangeStatusByProcessId(parameter.processId, "1", parameter.userId);
+ meetingManagementIBLL.ReceivedList(parameter.processId);
}
else
{