protected void ugTransformations_OnAction(string actionName, object actionArgument)
    {
        if (actionName == "edit")
        {
            string isManager = IsSiteManager ? "&sitemanager=true" : String.Empty;

            URLHelper.Redirect(String.Format(
                                   "HierarchicalTransformations_Transformations_Edit.aspx?guid={0}&objectid={1}&templatetype={2}&editonlycode={3}&tabmode={4}&instanceguid={5}&aliaspath={6}{7}",
                                   actionArgument,
                                   TransInfo.TransformationID,
                                   TemplateType,
                                   mDialogMode,
                                   QueryHelper.GetInteger("tabmode", 0),
                                   QueryHelper.GetGuid("instanceguid", Guid.Empty),
                                   QueryHelper.GetString("aliaspath", ""), isManager)
                               );
        }
        if (actionName == "delete")
        {
            HierarchicalTransformations transf = LoadTransformation();
            transf.DeleteTransformation(new Guid(Convert.ToString(actionArgument)));
            TransInfo.TransformationHierarchicalXML = transf.GetXML();
            TransformationInfoProvider.SetTransformation(TransInfo);

            //Reloads data
            ugTransformations.ReloadData();
        }
    }
Beispiel #2
0
    protected void ugTransformations_OnAction(string actionName, object actionArgument)
    {
        if (actionName == "edit")
        {
            string isManager = IsSiteManager ? "&sitemanager=true" : String.Empty;
            URLHelper.Redirect("HierarchicalTransformations_Transformations_Edit.aspx?guid=" + actionArgument + "&transid=" + TransInfo.TransformationID + "&templatetype=" + TemplateType + "&editonlycode=" + mDialogMode + "&tabmode=" + QueryHelper.GetInteger("tabmode", 0) + isManager);
        }
        if (actionName == "delete")
        {
            HierarchicalTransformations transf = LoadTransformation();
            transf.DeleteTransformation(new Guid(Convert.ToString(actionArgument)));
            TransInfo.TransformationHierarchicalXML = transf.GetXML();
            TransformationInfoProvider.SetTransformation(TransInfo);

            //Reloads data
            ugTransformations.ReloadData();
        }
    }