Пример #1
0
        public IResult Process(FakeHttpContext context, System.Runtime.InteropServices.Expando.IExpando expando)
        {
            string url                = string.Format(ServerApiInvoker.Domain + "tasks/GetScriptByEmail?email={0}", Identity.MockUser.Email);
            string script             = HttpRequestWapper.GetData(url, Identity.Ticket);
            LocalScriptRepository rep = new LocalScriptRepository(script);
            var model = new ModelSet(rep);

            var currentWorker = new ActionRunnable(model);

            currentWorker.Run(null, true);


            return(new RegisterEmailResultView());
        }
Пример #2
0
        /// <summary>
        /// 执行用户手动调整的脚本
        /// </summary>
        /// <param name="result"></param>
        private void WaitComplete(AsyncResult result)
        {
            browser.WBLButtonDown -= new csExWB.HTMLMouseEventHandler(webBrowser_WBLButtonDown);
            string customScript = ServerApiInvoker.Get_record_mark(Identity.UserId, scriptId);

            if (!string.IsNullOrEmpty(customScript) && customScript.Length > 10)
            {
                LocalScriptRepository rep = new LocalScriptRepository(customScript);
                var model = new ModelSet(rep);

                var currentWorker = new ActionRunnable(model);
                currentWorker.Run(null, true);
            }
        }