Browse Source

微信模块进行检测,避免误安装

master
yashen 8 years ago
parent
commit
41af089fb7
1 changed files with 7 additions and 0 deletions
  1. +7
    -0
      B3WeChat.Web/PluginClass.cs

+ 7
- 0
B3WeChat.Web/PluginClass.cs View File

@ -8,6 +8,7 @@ using Forks.Utils;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using TSingSoft.WebPluginFramework; using TSingSoft.WebPluginFramework;
using System.Linq;
namespace BWP.Web namespace BWP.Web
{ {
@ -41,6 +42,12 @@ namespace BWP.Web
public void OnInit() public void OnInit()
{ {
if (PluginManager.Current.Plugins.Any((p) => p.Name == "B3UnitedInfos"))
{
throw new Exception("业务系统中不应该安装微信模块");
}
CustomLogin.Register("WeChatReceive.aspx"); CustomLogin.Register("WeChatReceive.aspx");
CustomLogin.Register("WeChatLogin.aspx"); CustomLogin.Register("WeChatLogin.aspx");
var roleSchemas = Wpf.Settings.RoleSchemas; var roleSchemas = Wpf.Settings.RoleSchemas;


Loading…
Cancel
Save