代码拉取完成,页面将自动刷新
同步操作将从 Sunday/BoYuanCore 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
using System;
using System.Collections.Generic;
using System.Text;
namespace FineUICore
{
public partial class FineUICoreExtensions
{
/// <summary>
/// 显示信息并跳转到指定页面
/// </summary>
/// <param name="alert"></param>
/// <param name="message"></param>
/// <param name="url"></param>
/// <param name="js"></param>
/// <param name="title"></param>
public static void AlertInforAndRedirect(this FineUICore.Alert alert, string message, string url, string js = "", string title = "")
{
FineUICore.Alert.ShowInParent(message, title, MessageBoxIcon.Information, ActiveWindow.GetHidePostBackReference() + string.Format("self.location='{0}';{1} ", url, js));
}
/// <summary>
/// 提示信息(弹层用)
/// </summary>
/// <param name="alert"></param>
/// <param name="message">内容</param>
/// <param name="isPostBackReference">是否回发刷新页面</param>
/// <param name="js">显示消息后 执行的js</param>
/// <param name="title">标题</param>
public static void AlertInfor(this FineUICore.Alert alert, string message, bool isPostBackReference = true, string js = "", string title = "")
{
alert.AlertBase(message, isPostBackReference, js, MessageBoxIcon.Information, title);
//if (isPostBackReference)
//{
// //弹层页用,结合window的Onclose事件使用
// FineUICore.Alert.ShowInParent(message, "提示对话框", MessageBoxIcon.Information, ActiveWindow.GetHidePostBackReference());
// //弹层页用
// //Alert.ShowInParent(message, "提示对话框", MessageBoxIcon.Information, ActiveWindow.GetHideRefreshReference());
// //单页 并刷新当前页
// //Alert.ShowInParent(message, "提示对话框", MessageBoxIcon.Information, "window.location.reload()");
//}
//else
// FineUICore.Alert.ShowInParent(message, MessageBoxIcon.Information);
}
/// <summary>
/// 提示信息(单页用 并刷新当前页)
/// </summary>
/// <param name="alert"></param>
/// <param name="message">内容</param>
/// <param name="isPostBackReference">是否回发刷新页面</param>
/// <param name="js">显示消息后 执行的js</param>
/// <param name="title">标题</param>
public static void AlertInforBySingerPage(this FineUICore.Alert alert, string message, bool isPostBackReference = true, string js = "", string title = "")
{
if (isPostBackReference)
alert.AlertBase(message, isPostBackReference, "window.location.reload()", MessageBoxIcon.Information, title); //单页 并刷新当前页
else
alert.AlertBase(message, isPostBackReference, string.Empty, MessageBoxIcon.Information, title); //单页 并刷新当前页
}
/// <summary>
/// 报错信息
/// </summary>
/// <param name="alert"></param>
/// <param name="message">内容</param>
/// <param name="isPostBackReference">是否回发刷新页面</param>
/// <param name="js">显示消息后 执行的js</param>
/// <param name="title">标题</param>
public static void AlertError(this FineUICore.Alert alert, string message, bool isPostBackReference = true, string js = "", string title = "")
{
alert.AlertBase(message, isPostBackReference, js, MessageBoxIcon.Error, title);
}
/// <summary>
/// 成功信息
/// </summary>
/// <param name="alert"></param>
/// <param name="message">内容</param>
/// <param name="isPostBackReference">是否回发刷新页面</param>
/// <param name="js">显示消息后 执行的js</param>
/// <param name="title">标题</param>
public static void AlertSuccess(this FineUICore.Alert alert, string message, bool isPostBackReference = true, string js = "", string title = "")
{
alert.AlertBase(message, isPostBackReference, js, MessageBoxIcon.Success, title);
}
/// <summary>
/// 疑问信息
/// </summary>
/// <param name="alert"></param>
/// <param name="message">内容</param>
/// <param name="isPostBackReference">是否回发刷新页面</param>
/// <param name="js">显示消息后 执行的js</param>
/// <param name="title">标题</param>
public static void AlertQuestion(this FineUICore.Alert alert, string message, bool isPostBackReference = true, string js = "", string title = "")
{
alert.AlertBase(message, isPostBackReference, js, MessageBoxIcon.Question, title);
}
/// <summary>
/// 警告信息
/// </summary>
/// <param name="alert"></param>
/// <param name="message">内容</param>
/// <param name="isPostBackReference">是否回发刷新页面</param>
/// <param name="js">显示消息后 执行的js</param>
/// <param name="title">标题</param>
public static void AlertWarning(this FineUICore.Alert alert, string message, bool isPostBackReference = true, string js = "", string title = "")
{
alert.AlertBase(message, isPostBackReference, js, MessageBoxIcon.Warning, title);
}
private static void AlertBase(this FineUICore.Alert alert, string message, bool isPostBackReference = true, string js = "", MessageBoxIcon icon = MessageBoxIcon.Information, string title = "")
{
if (isPostBackReference)
FineUICore.Alert.ShowInParent(message, title, icon, ActiveWindow.GetHidePostBackReference() + js);
else
{
if (string.IsNullOrEmpty(js))
FineUICore.Alert.ShowInParent(message, title, icon);
else
FineUICore.Alert.ShowInParent(message, title, icon, js);
}
}
}
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。