当前位置: 首页>>代码示例>>C#>>正文


C# Util.IsAppSelectedForTest方法代码示例

本文整理汇总了C#中Util.IsAppSelectedForTest方法的典型用法代码示例。如果您正苦于以下问题:C# Util.IsAppSelectedForTest方法的具体用法?C# Util.IsAppSelectedForTest怎么用?C# Util.IsAppSelectedForTest使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Util的用法示例。


在下文中一共展示了Util.IsAppSelectedForTest方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: SetProvisionButtons

    protected void SetProvisionButtons(string app_name)
    {
        Util util = new Util();
        Hashtable State = (Hashtable)HttpRuntime.Cache[Session.SessionID];
        if (util.CheckSessionTimeout(State, Response, "Default.aspx")) return;

        if (State["SelectedApp"] == null)
        {
            util.ResetAppStateVariables(State);
            ProvisionApps.SelectedIndex = 0;
            ProvisionToStagingButton.Style.Value = "display:none";
            SeePublishingFormButton.Style.Value = "display:none"; ;

            return;
        }

        ClearMessages();

        if (!app_name.Contains("->"))
        {
            if (util.IsAppSelectedForTest(State))
            {
                ProvisionMessage.Text =  State["SelectedApp"].ToString() + " has been provisioned for testing";
                ProvisionToStagingButton.Style.Value = "display:none";
            }
            else
                ProvisionToStagingButton.Style.Value = "";

             SeePublishingFormButton.Style.Value = "";
             SetProvisionFormPopup();
        }
        else
        {
             State["SelectedApp"] = null;
             State["SelectedAppType"] = null;
            util.ResetAppStateVariables(State);
            ProvisionApps.SelectedIndex = 0;
            ProvisionToStagingButton.Style.Value = "display:none";
            SeePublishingFormButton.Style.Value = "display:none";;
        }
    }
开发者ID:dcolonvizi,项目名称:ViziAppsPortal,代码行数:41,代码来源:TabPublishOld.aspx.cs

示例2: InitCurrentApp

    public void InitCurrentApp(string app)
    {
        try
        {
            Hashtable State = (Hashtable)HttpRuntime.Cache[Session.SessionID];
            CurrentApp.SelectedValue = app;
            Util util = new Util();
            if (app.Contains("->"))
            {
                ResetAppStateVariables();
                StartMessage.Style.Value = "";
                State["SelectedDeviceType"] = Constants.IPHONE;
               // State["SelectedDeviceView"] = Constants.IPHONE;
                SetViewForDevice();
                AppSelectedForTest.Visible = false;
                HideAppControls();
                return;
            }
            State["SelectedApp"] = app;
            State["SelectedAppType"] = util.GetAppType(State);
            switch (State["SelectedAppType"].ToString())
            {
                case Constants.NATIVE_APP_TYPE:
                    break;
                case Constants.WEB_APP_TYPE:
                    Response.Redirect("TabDesignWeb.aspx", false);
                    break;
                case Constants.HYBRID_APP_TYPE:
                    Response.Redirect("TabDesignHybrid.aspx", false);
                    break;
            }

            if (util.IsAppSelectedForTest(State))
                AppSelectedForTest.Visible = true;
            else
                AppSelectedForTest.Visible = false;

            XmlUtil x_util = new XmlUtil();
            util.GetStagingAppXml(State, app);
           // State["SelectedDeviceView"] =
            State["SelectedDeviceType"] = x_util.GetAppDeviceType(State);
            if (State["SelectedDeviceType"] == null )
            {
                //State["SelectedDeviceView"] =
                State["SelectedDeviceType"] = Constants.IPHONE;
            }
            DeviceType.Text = State["SelectedDeviceType"].ToString();
            SetViewForDevice();
            InitAppPages();
            StartMessage.Style.Value = "display:none";

            string html = x_util.GetFirstAppPage(State);
            State["PageHtml"] = html;

            DefaultButtonImage.Text = util.GetDefaultButton(State);

            AppPages.SelectedValue = State["SelectedAppPage"].ToString();

            ShowAppControls();
        }
        catch (Exception ex)
        {
            Util util = new Util();
            Hashtable State = (Hashtable)HttpRuntime.Cache[Session.SessionID];
            util.LogError(State, ex);
            Message.Text = "Internal Error: " + ex.Message + ": " + ex.StackTrace;
        }
    }
开发者ID:dcolonvizi,项目名称:ViziAppsPortal,代码行数:68,代码来源:TabDesignNative.aspx.cs


注:本文中的Util.IsAppSelectedForTest方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。