zoukankan      html  css  js  c++  java
  • 提醒窗口

    脚本:

    <script language="javascript" type="text/javascript">
        function showMsg() {
            var msg = $.ajax({ url: "../AJAX/GetMsg.aspx?ran=" + Math.random(), async: false }).responseText;
            if ($(".panel").css("display") != "block") {
                if (msg != null && msg != "" && !isHidden) {
                    $.messager.show({
                        title: '提醒消息',
                        msg: msg.split('')[0] + '<center><input  style="border:none" id="cb_isshow" type="checkbox" onclick="changeShow()" value="不再提醒">不再提醒</input></center>',
                        showType: 'slide',
                         300,
                        height: msg.split('')[1],
                        showSpeed: 600,
                        timeout: 50000
                    });
                }
            }
            setTimeout(showMsg, 60000);
        }
    </script>

    后台:

    using System;
    using System.Collections;
    using System.Configuration;
    using System.Data;
    using System.Linq;
    using System.Web;
    using System.Web.Security;
    using System.Web.UI;
    using System.Web.UI.HtmlControls;
    using System.Web.UI.WebControls;
    using System.Web.UI.WebControls.WebParts;
    using System.Xml.Linq;
    using System.Web.Services;
    
    public partial class AJAX_GetMsg : System.Web.UI.Page
    {
        zab_HuiFang zhf = new zab_HuiFang();
        zab_SheJiYQ zsj = new zab_SheJiYQ();
    
        protected void Page_Load(object sender, EventArgs e)
        {
            DateTime now = new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day);
            //提示框高度
            int height = 100;
            //客户回访数量 提早一天提示
            int hfcount = 0;
            DataTable hfdt = zhf.GetHFTongji(" and hf_khTime >= '" + now.AddDays(1) + "' and hf_khTime < '" + now.AddDays(2) + "'");
            if (hfdt != null)
            {
                hfcount = hfdt.Rows.Count;
            }
            //设计图纸提交数量 提早一天提示
            int sjcount = 0;
            DataTable sjdt = zsj.GetSheJi(" and ((sj_timePm >= '" + now.AddDays(1) + "' and sj_timePm < '" + now.AddDays(2) + "' and sj_jiaoTuOneState = 1)"
                + " or (sj_timeXg >= '" + now.AddDays(1) + "' and sj_timeXg < '" + now.AddDays(2) + "' and sj_jiaoTuTwoState = 1)"
                + " or (sj_timeSg >= '" + now.AddDays(1) + "' and sj_timeSg < '" + now.AddDays(2) + "' and sj_jiaoTuThreeState = 1)"
                + " or (sj_timeQT >= '" + now.AddDays(1) + "' and sj_timeQT < '" + now.AddDays(2) + "' and sj_jiaoTuFourState = 1))");
            if (sjdt != null)
            {
                sjcount = sjdt.Rows.Count;
            }
            string msg = string.Empty;
    
            if (hfcount != 0)
            {
                msg += "<a target='iframe' href = '../TongJi/HuiFang_Tongji.aspx'>明天需要回访的客户有:" + hfcount + "个</a><br/><br/>";
                height += 30;
            }
            if (sjcount != 0)
            {
                msg += "<a target='iframe' href = '../TongJi/JiaoTu_Tongji.aspx'>明天需要提交的图纸有:" + sjcount + "个</a><br/><br/>";
                height += 30;
            }
            if (!string.IsNullOrEmpty(msg))
            {
                msg += "时间:" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss") + "<br/><br/>"
                    + "" + height;
            }
            Response.Write(msg);
        }
    }
  • 相关阅读:
    nmcli 命令的基本使用
    kvm虚拟机添加网卡
    Centos 7 系统详解
    Android 开发工具下载
    Android Studio升级3.6 Build窗口出现中文乱码问题解决方案
    Android 透明度alpha换算16进制
    python 安装: WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
    关于AndroidStudio 配置的默认路径的修改
    通过设置代理解决AndroidStudio无法下载gradle问题
    机器学习ROC图解读
  • 原文地址:https://www.cnblogs.com/tianrui/p/3393797.html
Copyright © 2011-2022 走看看