From c0f41ae2f349a1edfb3d545da438c6345e224dbe Mon Sep 17 00:00:00 2001 From: Demian Adolfo Raschkovan Date: Sun, 12 Jul 2020 19:37:25 +0200 Subject: [PATCH] 1.0.59.0 - Rollup Function: Update to support Whole Number and Float (thanks to TarogStar) - New action: GetSharepointLocationURL: Added new step to get the sharepoint location absolute URL (thanks to annepessoa) - New Action: CreateTeam: added new step to creat a Team (owner or access) - New Action: GetOptionSetValue: addedd new step to get the value (number) of the selectet option of the optionset of a record --- .../.vs/msdyncrmWorkflowTools/v15/.suo | Bin 621056 -> 620032 bytes .../Class/AssociateEntity.cs | 3 + .../Class/CalculateRollupField.cs | 4 + .../msdyncrmWorkflowTools/Class/CreateTeam.cs | 93 ++++++++++++++++++ .../Class/GetOptionSetValue.cs | 84 ++++++++++++++++ .../Properties/AssemblyInfo.cs | 4 +- .../msdyncrmWorkflowTools.csproj | 2 + .../msdyncrmWorkflowTools_Class.cs | 13 +++ .../Program.cs | 10 +- 9 files changed, 206 insertions(+), 7 deletions(-) create mode 100644 msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CreateTeam.cs create mode 100644 msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/GetOptionSetValue.cs diff --git a/msdyncrmWorkflowTools/.vs/msdyncrmWorkflowTools/v15/.suo b/msdyncrmWorkflowTools/.vs/msdyncrmWorkflowTools/v15/.suo index 3e10b349e415932700b66ec7b5a1321b4e3725d4..228274afea69b68b866c891456af8b7cdf9ff802 100644 GIT binary patch delta 12412 zcmeHN3s_ZE+CFQaz4zG%5CIX7hQ<`diJ!|E_bun0dO`Gd2G+&)?>GS@*TR z^{sb*>sxD|(w3V_n{Fyk>Ob6IFlfM6t*xyH3=A*<89*5lI}qLn)BuBk6rgb5qCYYA zq~2TVl8r++3z!Pr0!#+7fIwgha5o?tXCk}D?m6C5CSen z2zd?qTS|!KSBR7W4*(H>sE~)yA&t91GL&>AgJ>=uA9Nwc70WN45p7+IRS^^sWr8AN zX}^skHk91}MM?}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U6mlUhc^f@qqH^oN;7{C)#wL0)9QST0~e$?NrT3Y>tVkbyLjaoXH3*|@}Gt79NcFt0) z+KJhU71BRX32#spK6Mi?55nzROUJ0x!aAc+l2$)QF*2y0zp9AI3otpDCg`3>pYE|1 z_CeNR+JS{i8{ZnPrM5Q=ko1L0um+KhWg28Sv59;@xOtQM(7;C_e|6(+n1^`GL!@8B zRXEX!$%^Qpx?=b+=M6tUdzLDZT-J~JMXL4{3yt>p7VpE_`C_G`z~{4m29{I?i23C5Mh0SP}tb9z3T6h0%yUPFVUFA6WHRW%+$ZxyIZ@Y+6`)}MuY!oiR zq`kbO<&iDsHe+p4dI>Rl^U&PtkKHU-1-2mW`GffHjECLqK6ri{T6Ct5Z@EuGHC_FjXjvU zy*`~vA5k_?T{sKHC3G~54qVjpZ>7mRS~ RecordURL { get; set; } + + + #endregion protected override void Execute(CodeActivityContext executionContext) diff --git a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CalculateRollupField.cs b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CalculateRollupField.cs index 12d506a..79938cb 100644 --- a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CalculateRollupField.cs +++ b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CalculateRollupField.cs @@ -42,13 +42,17 @@ protected override void Execute(CodeActivityContext executionContext) #region "Read Parameters" String _FieldName = this.FieldName.Get(executionContext); + objCommon.tracingService.Trace("_FieldName=" + _FieldName); String _ParentRecordURL = this.ParentRecordURL.Get(executionContext); + if (_ParentRecordURL == null || _ParentRecordURL == "") { return; } + objCommon.tracingService.Trace("_ParentRecordURL=" + _ParentRecordURL); string[] urlParts = _ParentRecordURL.Split("?".ToArray()); string[] urlParams=urlParts[1].Split("&".ToCharArray()); + string ParentObjectTypeCode=urlParams[0].Replace("etc=",""); string ParentId = urlParams[1].Replace("id=", ""); objCommon.tracingService.Trace("ParentObjectTypeCode=" + ParentObjectTypeCode + "--ParentId=" + ParentId); diff --git a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CreateTeam.cs b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CreateTeam.cs new file mode 100644 index 0000000..7d8e9d1 --- /dev/null +++ b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/CreateTeam.cs @@ -0,0 +1,93 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Activities; +using Microsoft.Xrm.Sdk; +using Microsoft.Xrm.Sdk.Workflow; +using Microsoft.Crm.Sdk.Messages; +using Microsoft.Xrm.Sdk.Metadata.Query; +using Microsoft.Xrm.Sdk.Query; +using Microsoft.Xrm.Sdk.Messages; +using Microsoft.Xrm.Sdk.Metadata; +using msdyncrmWorkflowTools; +using System.ServiceModel; + + +namespace msdyncrmWorkflowTools +{ + + public class CreateTeam : CodeActivity + { + [RequiredArgument] + [Input("Team Name")] + [Default("")] + public InArgument TeamName{ get; set; } + + + [RequiredArgument] + [Input("Team Type")] + public InArgument TeamType{ get; set; } + + [RequiredArgument] + [Input("Administrator")] + [ReferenceTarget("systemuser")] + public InArgument Administrator { get; set; } + + [RequiredArgument] + [Input("Business Unit")] + [ReferenceTarget("businessunit")] + public InArgument BusinessUnit { get; set; } + + + [Output("Team")] + [ReferenceTarget("team")] + public OutArgument createdTeam { get; set; } + + protected override void Execute(CodeActivityContext executionContext) + { + + #region "Load CRM Service from context" + + Common objCommon = new Common(executionContext); + objCommon.tracingService.Trace("Load CRM Service from context --- OK"); + #endregion + + #region "Read Parameters" + String _teamName = this.TeamName.Get(executionContext); + int _teamType = this.TeamType.Get(executionContext); + EntityReference _administrator= this.Administrator.Get(executionContext); + EntityReference _businessUnit= this.BusinessUnit.Get(executionContext); + + objCommon.tracingService.Trace("_teamName=" + _teamName ); + #endregion + + + #region "Associate Execution" + + try + { + msdyncrmWorkflowTools_Class commonClass = new msdyncrmWorkflowTools_Class(objCommon.service); + Guid createdTeamId= commonClass.CreateTeam(_teamName,_teamType, _administrator, _businessUnit); + this.createdTeam.Set(executionContext, new EntityReference("team", createdTeamId)); + + } + catch (FaultException ex) + { + objCommon.tracingService.Trace("Error : {0} - {1}", ex.Message, ex.StackTrace); + //throw ex; + // if (ex.Detail.ErrorCode != 2147220937)//ignore if the error is a duplicate insert + //{ + // throw ex; + //} + } + catch (System.Exception ex) + { + objCommon.tracingService.Trace("Error : {0} - {1}", ex.Message, ex.StackTrace); + //throw ex; + } + #endregion + + } + } +} diff --git a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/GetOptionSetValue.cs b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/GetOptionSetValue.cs new file mode 100644 index 0000000..6fdaf9f --- /dev/null +++ b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Class/GetOptionSetValue.cs @@ -0,0 +1,84 @@ +using Microsoft.Crm.Sdk.Messages; +using Microsoft.Xrm.Sdk; +using Microsoft.Xrm.Sdk.Query; +using Microsoft.Xrm.Sdk.Workflow; +using System; +using System.Activities; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Text.RegularExpressions; +using System.Threading.Tasks; + + +namespace msdyncrmWorkflowTools +{ + public class GetOptionSetValue : CodeActivity + { + [RequiredArgument] + [Input("Source Record URL")] + public InArgument SourceRecordUrl { get; set; } + + [RequiredArgument] + [Input("Attribute Name")] + public InArgument AttributeName { get; set; } + + [Output("Value")] + public OutArgument SelectedValue { get; set; } + + protected override void Execute(CodeActivityContext executionContext) + { + Common objCommon = new Common(executionContext); + objCommon.tracingService.Trace("Load CRM Service from context --- OK"); + + EntityReference sourceEntityReference = GetSourceEntityReference(objCommon.tracingService, executionContext, objCommon.service); + string attributeName = GetAttributeName(objCommon.tracingService, executionContext); + + int value= GetValue(sourceEntityReference, attributeName, objCommon.tracingService, objCommon.service); + + this.SelectedValue.Set(executionContext, value); + } + + private EntityReference GetSourceEntityReference(ITracingService tracingService, CodeActivityContext executionContext, IOrganizationService organizationService) + { + string sourceRecordUrl = SourceRecordUrl.Get(executionContext) ?? throw new ArgumentNullException("Source URL is empty"); + tracingService.Trace("Source Record URL:'{0}'", sourceRecordUrl); + return new DynamicUrlParser(sourceRecordUrl).ToEntityReference(organizationService); + } + + + private string GetAttributeName(ITracingService tracingService, CodeActivityContext executionContext) + { + string attributeName = AttributeName.Get(executionContext) ?? throw new ArgumentNullException("Attribute Name is empty"); + tracingService.Trace("Attribute name:'{0}'", attributeName); + return attributeName; + } + + + + private int GetValue(EntityReference sourceEntityReference, string attributeName, ITracingService tracingService, IOrganizationService organizationService) + { + if (sourceEntityReference == null || attributeName == null) + { + tracingService.Trace("Null parameters have been passed, so string will be empty"); + return 0; + } + + Entity sourceEntity = organizationService.Retrieve(sourceEntityReference.LogicalName, sourceEntityReference.Id, new ColumnSet(attributeName)); + tracingService.Trace("Source record has been retrieved correctly. Id:{0}", sourceEntity.Id); + + if (!sourceEntity.Contains(attributeName)) + { + tracingService.Trace("Attribues {0} was not found", attributeName); + return 0; + } + int value = 0; + if (sourceEntity.Attributes.Contains(attributeName)) + { + value = ((OptionSetValue)sourceEntity.Attributes[attributeName]).Value; + } + + return value; + } + } +} \ No newline at end of file diff --git a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Properties/AssemblyInfo.cs b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Properties/AssemblyInfo.cs index b17330c..857a45f 100644 --- a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Properties/AssemblyInfo.cs +++ b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/Properties/AssemblyInfo.cs @@ -33,5 +33,5 @@ // Puede especificar todos los valores o usar los valores predeterminados (número de compilación y de revisión) // usando el símbolo '*' como se muestra a continuación: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.58.0")] -[assembly: AssemblyFileVersion("1.0.58.0")] +[assembly: AssemblyVersion("1.0.59.0")] +[assembly: AssemblyFileVersion("1.0.59.0")] diff --git a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/msdyncrmWorkflowTools.csproj b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/msdyncrmWorkflowTools.csproj index 86a4963..c8104d6 100644 --- a/msdyncrmWorkflowTools/msdyncrmWorkflowTools/msdyncrmWorkflowTools.csproj +++ b/msdyncrmWorkflowTools/msdyncrmWorkflowTools/msdyncrmWorkflowTools.csproj @@ -96,10 +96,12 @@ + + diff --git a/msdyncrmWorkflowTools/msdyncrmWorkflowTools_Class/msdyncrmWorkflowTools_Class.cs b/msdyncrmWorkflowTools/msdyncrmWorkflowTools_Class/msdyncrmWorkflowTools_Class.cs index a21fc42..9106d45 100644 --- a/msdyncrmWorkflowTools/msdyncrmWorkflowTools_Class/msdyncrmWorkflowTools_Class.cs +++ b/msdyncrmWorkflowTools/msdyncrmWorkflowTools_Class/msdyncrmWorkflowTools_Class.cs @@ -671,6 +671,19 @@ public bool InsertOptionValue(bool globalOptionSet, string attributeName, string return true; } + + public Guid CreateTeam(string teamName, int teamType, EntityReference administrator, EntityReference businessUnit) + { + Entity team = new Entity("team"); + team.Attributes.Add("administratorid", administrator); + team.Attributes.Add("name", teamName); + team.Attributes.Add("teamtype", new OptionSetValue(teamType)); + team.Attributes.Add("businessunitid", businessUnit); + + Guid _teamId = service.Create(team); + + return _teamId; + } public void AssociateEntity(string PrimaryEntityName, Guid PrimaryEntityId, string _relationshipName, string _relationshipEntityName, string entityName, string ParentId) { try diff --git a/msdyncrmWorkflowTools/msdyncrmWorkflowTools_ConsoleTest/Program.cs b/msdyncrmWorkflowTools/msdyncrmWorkflowTools_ConsoleTest/Program.cs index 9672955..490039c 100644 --- a/msdyncrmWorkflowTools/msdyncrmWorkflowTools_ConsoleTest/Program.cs +++ b/msdyncrmWorkflowTools/msdyncrmWorkflowTools_ConsoleTest/Program.cs @@ -46,7 +46,7 @@ static void Main(string[] args) //bool regexSuccess = false; //classObj.StringFunctions(false, "Lead subject", "", false, 0, false, "", "", 50, 0, false, "", ref capitalizedText, ref paddedText, ref replacedText, ref subStringText, ref regexText, ref uppercaseText, ref lowercaseText, ref regexSuccess); - + Guid createdTeam=classObj.CreateTeam("PruebaTeam2", 1, new EntityReference("systemuser", new Guid("8fe5fd89-f447-4a38-90f1-1180617fcbc5")), new EntityReference("businessunit", new Guid("6025BC19-2E34-EA11-A812-000D3ABAAFE7"))); //string json = @"{""values"": [{""Author"": ""Lisa Simpson"",""Response Date"": ""2018-02-21T08:13:34.284Z""} ], ""SurveyId"": ""5114FA48-1DE6-E711-80E3-005056B37A5C""}"; //string jsonpath = "values[0].Author"; //string res = classObj.JsonParser(json, jsonpath); @@ -64,7 +64,7 @@ static void Main(string[] args) // classObj.SendEmailToUsersInRole(securityRoleLookup, new EntityReference("email",new Guid("B96825B7-CCB0-E711-810F-5065F38BF4A1"))); //classObj.InsertOptionValue(true, "purchaseprocess", "opportunity", "Tipo22", 22, 3082); - classObj.InsertOptionValue(false, "cre36_test", "account", "3", 3, 3082); + //classObj.InsertOptionValue(false, "cre36_test", "account", "3", 3, 3082); //classObj.DeleteOptionValue(true,"purchaseprocess", "opportunity", 22); //classObj.DeleteOptionValue(false, "cdi_test", "opportunity", 1); // classObj.AssociateEntity("new_test", new Guid("612F10EE-32DB-E711-8116-5065F38BF4A1"), "new_new_test_new_test", "new_test", "new_test", "F1F924DC-32DB-E711-8116-5065F38BF4A1"); @@ -80,9 +80,9 @@ static void Main(string[] args) public static IOrganizationService GetCrmService() { - const string crmServerUrl = "https://xxxx.crm4.dynamics.com"; - const string userName = "xxxx@xxxx.com"; - const string password = ""; + const string crmServerUrl = "https://XXX.crm4.dynamics.com"; + const string userName = "XXX@XXX.com"; + const string password = "XXX"; //SecureString theSecureString = new NetworkCredential("", password).SecurePassword;