コード例 #1
0
    protected void GetData()
    {
        string whereStr;
        string orderBy;

        whereStr                  = "";
        orderBy                   = "it.EmailFrom desc";
        BLL_ScheduleTasks         = new ScheduleTasksBLL();
        vBackupAndEmailSettingObj = BLL_ScheduleTasks.GetBackupAndEmailSetting(whereStr, orderBy);
        if (vBackupAndEmailSettingObj.Count() > 0)
        {
            foreach (var item in vBackupAndEmailSettingObj)
            {
                this.TempKeyId = item.BackupID.ToString();
            }
        }
    }
コード例 #2
0
    protected Boolean JudgeBackupAndEmailSetting()
    {
        string whereStr;
        string orderBy;

        whereStr                  = "";
        orderBy                   = "it.EmailFrom desc";
        BLL_ScheduleTasks         = new ScheduleTasksBLL();
        vBackupAndEmailSettingObj = BLL_ScheduleTasks.GetBackupAndEmailSetting(whereStr, orderBy);
        if (vBackupAndEmailSettingObj.Count() > 0)
        {
            foreach (var item in vBackupAndEmailSettingObj)
            {
                return(true);
            }
        }
        return(false);
    }
コード例 #3
0
    public void EncapsulationData()
    {
        //string selectDate;//选择的时间
        string whereStr;
        string orderBy;

        if (this.KeyId == string.Empty) //Tasks的billing相关信息,在billing页面完成
        {
            GetDataFromCookie();        //从cookies读取数据
        }
        else
        {
            SchedulerObj = new tblScheduler();
            //HttpCookie BuckupSettingData = Request.Cookies.Get("BuckupSetting");
            //if (BuckupSettingData != null)
            //{
            //    System.Guid KeyIdGuid = new Guid(BuckupSettingData.Values["BackupId"]);
            //    SchedulerObj.BackupID = KeyIdGuid;
            //}
        }

        whereStr                  = "";
        orderBy                   = "it.EmailFrom desc";
        BLL_ScheduleTasks         = new ScheduleTasksBLL();
        vBackupAndEmailSettingObj = BLL_ScheduleTasks.GetBackupAndEmailSetting(whereStr, orderBy);
        if (vBackupAndEmailSettingObj.Count() > 0)
        {
            foreach (var item in vBackupAndEmailSettingObj)
            {
                if (chkBDBB.Checked == true)
                {
                    SchedulerObj.BackupID = item.BackupID;
                }
                SchedulerObj.EmailID = item.EmailID;
            }
        }

        SchedulerObj.TaskName = rtxtTaskName.Text.Trim() + "-CreateSD";
        if (rcbScheduleType.SelectedItem != null)
        {
            SchedulerObj.ScheduleType = rcbScheduleType.SelectedItem.Value.Trim();
        }
        SchedulerObj.StartTime = rdStartTime.SelectedDate;

        //if (ckxlROOTD.Items.Count>0)
        //{
        //    selectDate = "#";
        //    for (int i = 0; i < ckxlROOTD.Items.Count; i++)
        //    {
        //        if (ckxlROOTD.Items[i].Selected == true)
        //        {
        //            selectDate += ckxlROOTD.Items[i].Value + "#";
        //        }
        //    }
        //    SchedulerObj.RunOnly = selectDate;
        //}
        SchedulerObj.RunOnlyStart = rdStartTime.SelectedDate; //运行开始时间
        SchedulerObj.RunOnlyEnd   = rdEndTime.SelectedDate;   //运行结束时间

        if (rcbAction.SelectedItem != null)
        {
            SchedulerObj.Action = rcbAction.SelectedItem.Value.Trim();
        }
        if (rcbPostAction.SelectedItem != null)
        {
            SchedulerObj.PostAction = rcbPostAction.SelectedItem.Value.Trim();
        }
    }