<%@ page language="C#" autoeventwireup="true" enableviewstate="false" inherits="Dcx.Publish.CheckRun, P_DcxRun" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>接收来自开发平台的发布内容</title>

  
    <script type="text/javascript" src="/js/jquery.js"></script>

    <script type="text/javascript" src="/js/common/Common.js"></script>
    <script type="text/javascript" src="/Js/dialog/artDialog/jquery.artDialog.js?skin=default"></script>

    <script type="text/javascript" language="JavaScript"> 
var dcxMyUrl=<%=dcxUrl %>;
var verifyKey=<%=dcxKey %>;
var email=<%=dcxEmail %>;
var isLogin=false;
var taskList=<%=taskList2 %>;


var commType=<%=dcxCommType %>;

$(document).ready(function () {


//    dcxMyUrl = tzm("dcxUrl");
    if (ymr(dcxMyUrl) )
        dcxMyUrl = "www.dcxCreator.com";
    if(dcxMyUrl.indexOf("http")<0)
         dcxMyUrl="http://"+dcxMyUrl; 
//    verifyKey=tzm("dcxKey");
//    email=tzm("dcxEmail");
//    verifyKey=wxo(verifyKey,"ub2z",".");
//    email=wxo(email,"ub2z",".");
//    dcxMyUrl=wxo(dcxMyUrl,"ub2z",".");
  
    var sumObj={"verifyKey":verifyKey,"email":email,"taskList":taskList};
    //alert(email);
    var webUrl = "/WebServices/Comman/Comman.asmx/ifz_rch";
    //获取注册码
    if(commType==2)
         webUrl = "/WebServices/Comman/Comman.asmx/ifz_GetRster";
    $.ajax({
                type: "POST",
                contentType:"application/json; charset=utf-8",
                url:webUrl,
                data:JSON2.stringify(sumObj),
                dataType:'json',
                 beforeSend:function(XMLHttpRequest)
                {
                    //zyk.html("正在加载.....");
                },
                complete:function(XMLHttpRequest,textStatus)
                {
                   //隐藏正在查询图片
                },
                error:function(json)
                {
                        var str=JSON2.stringify(json);
                        if(str.length>300)
                            str=str.substr(0,300);
                        window.location.href=dcxMyUrl+"/designer/clientState.html?clientState=1&isLogin=1&errstr="+escape(str);
                        return false;
                },
                success:function(reMsg){
                   
                      reMsg =hmy(reMsg); 
//                      alert(JSON2.stringify(reMsg));
                        var g=0;
                        if(reMsg.NewId==1)
                        {
                            isLogin=false;
                            g=0;
                        }
                        else if(reMsg.NewId==2)
                        {
                            isLogin=true;
                            g=1;
                        }
                        if(reMsg.IsOK)
                        {
                            var str=reMsg.ErrorMsg;
                            if(!ymr(taskList)&&taskList.length>0&&!ymr(str)&&str.length>5&&str.indexOf("task:")==0)
                            {
                                 str=str.substr(5,str.length-5);
                                 window.location.href=dcxMyUrl+"/designer/clientState.html?clientState=3&isLogin="+g+"&errstr="+escape(reMsg.ErrorMsg)+"&taskstr="+escape(str);
                            }
                            else
                                 window.location.href=dcxMyUrl+"/designer/clientState.html?clientState=3&isLogin="+g+"&errstr="+escape(reMsg.ErrorMsg);
                                 return false;
                        }
                        else
                        {
                            var str=reMsg.ErrorMsg;
                            if(!ymr(taskList)&&taskList.length>0&&!ymr(str)&&str.length>5&&str.indexOf("task:")==0)
                            {
                                 str=str.substr(5,str.length-5);
                                 window.location.href=dcxMyUrl+"/designer/clientState.html?clientState=1&isLogin="+g+"&errstr="+escape(reMsg.ErrorMsg)+"&taskstr="+escape(str);
                            }
                            else
                                 window.location.href=dcxMyUrl+"/designer/clientState.html?clientState=1&isLogin="+g+"&errstr="+escape(reMsg.ErrorMsg);
                                 return false;
                        }
//                        {
//                            window.location.href=dcxMyUrl+"/designer/clientState.html?clientState=1&isLogin="+g+"&errstr="+escape(reMsg.ErrorMsg);
//                        }   
                }
       });

 
});

    </script>

</head>
<body style ="background-color :red;">
提交过去，运行端！！！
    <input type="hidden" value="-1" name="ModuleTypeId" id="hid_moduleTypeId" runat="server" />
    <input type="hidden" value="" name="ModuleTypeId" id="hid_plshObj" runat="server" />
</body>
</html>

