protected override void CreateChildControls()
        {
            if (HttpContext.Current == null) { return; }

            litModuleTitle = new Literal();
            //this.Controls.Add(litModuleTitle);
            lnkModuleSettings = new HyperLink();
            lnkModuleSettings.CssClass = "modulesettingslink";
            //this.Controls.Add(lnkModuleSettings);

            lnkModuleEdit = new HyperLink();
            //this.Controls.Add(lnkModuleEdit);
            lnkModuleEdit.CssClass = "ModuleEditLink";
            lnkModuleEdit.SkinID = "plain";

            ibPostDraftContentForApproval = new ImageButton();
            ibPostDraftContentForApproval.ID = "lbPostDraftContentForApproval";
            ibPostDraftContentForApproval.CssClass = "jqtt ModulePostDraftForApprovalLink";
            ibPostDraftContentForApproval.SkinID = "plain";
            ibPostDraftContentForApproval.Visible = false;
            ibPostDraftContentForApproval.Click += new ImageClickEventHandler(ibPostDraftContentForApproval_Click);
            this.Controls.Add(ibPostDraftContentForApproval);

            ibApproveContent = new ImageButton();
            ibApproveContent.ID = "ibApproveContent";
            ibApproveContent.CssClass = "jqtt ModuleApproveContentLink";
            ibApproveContent.SkinID = "plain";
            ibApproveContent.Visible = false;
            ibApproveContent.Click += new ImageClickEventHandler(ibApproveContent_Click);
            this.Controls.Add(ibApproveContent);

            if (WebConfigSettings.Use3LevelContentWorkflow)
            {
                //joe davis
                ibPublishContent = new ImageButton();
                ibPublishContent.ID = "ibPublishContent";
                ibPublishContent.CssClass = "jqtt ModulePublishContentLink";
                ibPublishContent.SkinID = "plain";
                ibPublishContent.Visible = false;
                ibPublishContent.Click += new ImageClickEventHandler(ibApproveContent_Click); //approve and publish are the same at this point so we have only one method
                this.Controls.Add(ibPublishContent);
            }

            lnkRejectContent = new HyperLink();
            lnkRejectContent.ID = "ibRejectContent";
            lnkRejectContent.CssClass = "jqtt ModuleRejectContentLink";
            lnkRejectContent.SkinID = "plain";
            lnkRejectContent.Visible = false;

            ibCancelChanges = new ImageButton();
            ibCancelChanges.ID = "ibCancelChanges";
            ibCancelChanges.CssClass = "jqtt ModuleCancelChangesLink";
            ibCancelChanges.SkinID = "plain";
            ibCancelChanges.Visible = false;
            UIHelper.AddConfirmationDialog(ibCancelChanges, Resource.CancelContentChangesButtonWarning);
            ibCancelChanges.Click += new ImageClickEventHandler(ibCancelChanges_Click);
            this.Controls.Add(ibCancelChanges);

            statusIcon = new WorkflowStatusIcon();
            //statusLink = new ClueTipHelpLink();
            //if (!HttpContext.Current.Request.IsAuthenticated)
            //{
            //    statusLink.AssumeScriptIsLoaded = true; //we only show the cluetip if the user is in an edit role, so leave out the script when it isn't needed
            //}
            //statusLink.Visible = false;

            //this.Controls.Add(statusLink);
            this.Controls.Add(statusIcon);
        }
Exemple #2
0
        protected override void CreateChildControls()
        {
            if (HttpContext.Current == null)
            {
                return;
            }

            litModuleTitle = new Literal();
            //this.Controls.Add(litModuleTitle);
            lnkModuleSettings          = new HyperLink();
            lnkModuleSettings.CssClass = "modulesettingslink";
            //this.Controls.Add(lnkModuleSettings);

            lnkModuleEdit = new HyperLink();
            //this.Controls.Add(lnkModuleEdit);
            lnkModuleEdit.CssClass = "ModuleEditLink";
            lnkModuleEdit.SkinID   = "plain";



            ibPostDraftContentForApproval          = new ImageButton();
            ibPostDraftContentForApproval.ID       = "lbPostDraftContentForApproval";
            ibPostDraftContentForApproval.CssClass = "jqtt ModulePostDraftForApprovalLink";
            ibPostDraftContentForApproval.SkinID   = "plain";
            ibPostDraftContentForApproval.Visible  = false;
            ibPostDraftContentForApproval.Click   += new ImageClickEventHandler(ibPostDraftContentForApproval_Click);
            this.Controls.Add(ibPostDraftContentForApproval);

            ibApproveContent          = new ImageButton();
            ibApproveContent.ID       = "ibApproveContent";
            ibApproveContent.CssClass = "jqtt ModuleApproveContentLink";
            ibApproveContent.SkinID   = "plain";
            ibApproveContent.Visible  = false;
            ibApproveContent.Click   += new ImageClickEventHandler(ibApproveContent_Click);
            this.Controls.Add(ibApproveContent);

            if (WebConfigSettings.Use3LevelContentWorkflow)
            {
                //joe davis
                ibPublishContent          = new ImageButton();
                ibPublishContent.ID       = "ibPublishContent";
                ibPublishContent.CssClass = "jqtt ModulePublishContentLink";
                ibPublishContent.SkinID   = "plain";
                ibPublishContent.Visible  = false;
                ibPublishContent.Click   += new ImageClickEventHandler(ibApproveContent_Click); //approve and publish are the same at this point so we have only one method
                this.Controls.Add(ibPublishContent);
            }

            lnkRejectContent          = new HyperLink();
            lnkRejectContent.ID       = "ibRejectContent";
            lnkRejectContent.CssClass = "jqtt ModuleRejectContentLink";
            lnkRejectContent.SkinID   = "plain";
            lnkRejectContent.Visible  = false;

            ibCancelChanges          = new ImageButton();
            ibCancelChanges.ID       = "ibCancelChanges";
            ibCancelChanges.CssClass = "jqtt ModuleCancelChangesLink";
            ibCancelChanges.SkinID   = "plain";
            ibCancelChanges.Visible  = false;
            UIHelper.AddConfirmationDialog(ibCancelChanges, Resource.CancelContentChangesButtonWarning);
            ibCancelChanges.Click += new ImageClickEventHandler(ibCancelChanges_Click);
            this.Controls.Add(ibCancelChanges);

            statusIcon = new WorkflowStatusIcon();
            //statusLink = new ClueTipHelpLink();
            //if (!HttpContext.Current.Request.IsAuthenticated)
            //{
            //    statusLink.AssumeScriptIsLoaded = true; //we only show the cluetip if the user is in an edit role, so leave out the script when it isn't needed
            //}
            //statusLink.Visible = false;

            //this.Controls.Add(statusLink);
            this.Controls.Add(statusIcon);
        }