Beispiel #1
0
 private void InitializeParams()
 {
     // Check if the page is loaded for first time
     if (ViewState["associationParams"] == null)
     {
         InitializeAssociationParams();
         ViewState["associationParams"] = this.associationParams;
         SPWorkflowAssociation existingAssociation = GetExistingAssociation();
         PopulateFormFields(existingAssociation);
     }
     else
     {
         this.associationParams = (AssociationParams)ViewState["associationParams"];
     }
 }
Beispiel #2
0
        private void InitializeAssociationParams()
        {
            this.associationParams = new AssociationParams();
            this.associationParams.AssociationName = Request.Params["WorkflowName"];
            this.associationParams.BaseTemplate    = Request.Params["WorkflowDefinition"];
            this.associationParams.AutoStartCreate = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AutoStartCreate"], "ON") == 0);
            this.associationParams.AutoStartChange = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AutoStartChange"], "ON") == 0);
            this.associationParams.AllowManual     = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AllowManual"], "ON") == 0);
            this.associationParams.RequireManagedListPermisions = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["ManualPermManageListRequired"], "ON") == 0);
            this.associationParams.SetDefaultApprovalWorkflow   = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["SetDefault"], "ON") == 0);
            this.associationParams.LockItem            = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AllowEdits"], "FALSE") == 0);
            this.associationParams.ContentTypePushDown = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["UpdateLists"], "TRUE") == 0);

            string associationGuid = Request.Params["GuidAssoc"];

            if (!String.IsNullOrEmpty(associationGuid))
            {
                this.associationParams.AssociationGuid = new Guid(associationGuid);
            }

            InitializeAssociationTypeParams();
            InitializeTaskListParams();
            InitializeHistoryListParams();
        }
        private void InitializeAssociationParams()
        {
            this.associationParams = new AssociationParams();
            this.associationParams.AssociationName = Request.Params["WorkflowName"];
            this.associationParams.BaseTemplate = Request.Params["WorkflowDefinition"];
            this.associationParams.AutoStartCreate = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AutoStartCreate"], "ON") == 0);
            this.associationParams.AutoStartChange = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AutoStartChange"], "ON") == 0);
            this.associationParams.AllowManual = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AllowManual"], "ON") == 0);
            this.associationParams.RequireManagedListPermisions = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["ManualPermManageListRequired"], "ON") == 0);
            this.associationParams.SetDefaultApprovalWorkflow = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["SetDefault"], "ON") == 0);
            this.associationParams.LockItem = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["AllowEdits"], "FALSE") == 0);
            this.associationParams.ContentTypePushDown = (StringComparer.OrdinalIgnoreCase.Compare(Request.Params["UpdateLists"], "TRUE") == 0);

            string associationGuid = Request.Params["GuidAssoc"];
            if (!String.IsNullOrEmpty(associationGuid))
            {
                this.associationParams.AssociationGuid = new Guid(associationGuid);
            }

            InitializeAssociationTypeParams();
            InitializeTaskListParams();
            InitializeHistoryListParams();
        }
        private void InitializeParams()
        {
            // Check if the page is loaded for first time
            if (ViewState["associationParams"] == null)
            {
                ApprovalUC.FirstLoad = true;
                InitializeAssociationParams();
                ViewState["associationParams"] = this.associationParams;
                SPWorkflowAssociation existingAssociation = GetExistingAssociation();
                PopulateFormFields(existingAssociation);
            }
            else
            {
                ApprovalUC.FirstLoad = false;
                this.associationParams = (AssociationParams)ViewState["associationParams"];
            }
            //ApprovalUC.WorkflowAssociation = this.associationParams;

            ApprovalUC.ListID = this.associationParams.TargetListGuid;
        }
 private void InitializeParams()
 {
     // Check if the page is loaded for first time
     if (ViewState["associationParams"] == null)
     {
         InitializeAssociationParams();
         ViewState["associationParams"] = this.associationParams;
         SPWorkflowAssociation existingAssociation = GetExistingAssociation();
         PopulateFormFields(existingAssociation);
     }
     else
     {
         this.associationParams = (AssociationParams)ViewState["associationParams"];
     }
 }