We are using Dynamic CRM 4 and the URL adressable views.
We are able to access a view from the url via this url using the etc attribute (entity code):
.../_root/homepage.aspx?etc=10014
From this link of MSDN, we could use the etn attribute (entity name) instead like this:
.../_root/homepage.aspx?etn=contracts
But it fall on an error page saying:
[InvalidOperationException: CRM Parameter Filter - Invalid parameter 'etn=contract' in Request.QueryString on page ...
Is there any configuration to do in CRM to allow the use of the entity name attribute in the URL?
I think there is some misunderstanding. You could specify the entity with etn instead of its type code etc for addressing forms.
This is IMHO not possible for addressing views. Therefore you receive this error
Related
I'm attempting to define some relationships between entity values, using metadata.
I've uploaded metadata to an entity value using the Watson API v1. When I list the entities through the same API I can see the metadata. I have not been able to access the metadata from Watson Assistant though.
As a test I changed the entity value and checked through Watson Assistant it was changed, so I know I'm working with the correct workspace. I've also checked the entity using the JSON editor to verify it was defined and tried assigning the entity to a context variable.
I've tried several methods including:
#Room.building, #Room.metadata.building, entities['Room']?metadata?.building, entities['Room']?.building (all within the < ? tags). Using #Room and entities['Room']?.value returns the entity value correctly. It's accessing the metadata where it fails.
The metadata for building should not be returning null, but I"m either receiving a null or, depending on how I'm attempting to retrieve the value, a SPEL exception - no property on undefined.
Unfortunately, it is not possible to access metadata defined on user entities in the WA runtime at this moment. The metadata are only returned when making the direct API call. You could use cloud functions call though to get the metadata in WA although that is not ideal either.
I'm using asp.net mvc
I have a url that have some parameters, one of them is a url
e.g
www.example.com?p1=v1&p2=v2&p3=url&p4=v4...
the url i want to add has few parameters. how can i add them to this url? becuase from the second parameter the first url take them
e.g
www.example.com?p1=v1&p2=v2&p3=www.example2.com?p21=v21&p22=v22&p23=v23&p4=v4...
p21,p22,p23 belongs to the second url (www.example2.com) but the first url (www.example.com) taking p22, p23 has it's own
p.s
i can't control the first url process
Thank you all for your help
You should url encode the value of the query string parameter before sending it in the url:
http://www.example.com?p1=v1&p2=v2&p3=www.example2.com%3Fp21%3Dv21%26p22%3Dv22%26p23%3Dv23%26p4%3Dv4..
So in this example the value of the p3 parameter is properly url encoded for transmission over the HTTP protocol and can be unambiguously decoded back to its original value of www.example2.com?p21=v21&p22=v22&p23=v23&p4=v4 at the receiving site.
There are built-in methods in .NET for achieving this. For example the EscapeDataString method:
string urlEncoded = Uri.EscapeDataString("www.example2.com?p21=v21&p22=v22&p23=v23&p4=v4");
// Will produce: www.example2.com%3Fp21%3Dv21%26p22%3Dv22%26p23%3Dv23%26p4%3Dv4
Of course if you are using the built-in helpers in ASP.NET MVC this url encoding will happen automatically.
If on the other hand you cannot control the building of this url then you will most definitely end up with an ambiguous and wrong url (like the one shown in your question) that no valid system will be able to understand. That's the reason why certain standards have been imposed.
I have a MVC model field that the user enters some html source code into. Currently, I am getting the following error:
A potentially dangerous Request.Form value was detected from the
client
I have had a look at the following resource: http://blogs.msdn.com/b/marcinon/archive/2010/11/09/mvc3-granular-request-validation-update.aspx
The resource says to add the AllowHtml attribute. I have added this attribute, and the error is now not occuring.
My question is this: Is there any other security features that I should add to my application, or is the AllowHtml attribute all that is required? Should I also use the following protection library: http://wpl.codeplex.com/
Thanks in advance
AllowHtml doesn't include any security to prevent malicious scripting. It's just allowing the property to skip this step in the validation process. You should still check that property to make sure it doesn't contain scripting and either sanitize or reject it if it does.
I work on REST service using Spring MVC 3.1. Names of some of the object fields are customized. Also I use JSR-303 validation. For example,
#Valid
#JsonProperty("env_vars")
private List<EnvironmentVariable> env;
Works great, but there is an issue here: error messages contains names of Java fields. I mean if user produces invalid value in field *env_vars*, he get an error message that env field contains an error and it can be confusing.
Is there a way to keep names customization without providing full messages for each field?
Not sure what you mean by "without providing full messages for each field"...
You need to specify the custom field name somewhere, so it may as well use the i18n mechanism for JSR303 - ValidationMessages.properties (see https://stackoverflow.com/a/5781678/249327).
I have a small application built using Seam 2.2, Richfaces 3.3, JBoss 5.1.
Most of the page navigation adds the request parameters to the target URL. I would like to hide parameters to be hidden to the customer who is using the application (e.g. I would expect the URL to be something like "http://localhost:8080/books/Book.seam". The parameters (userId, orderId and cmId) are currently mapped to the backend bean via Book.page.xml.
How do I prevent the request parameters from showing up in the browser URL, as it also allows the customer to manipulate the URL.
We did look at seam URL re-writing feature, it talked about manipulating say the primary key id in a REST format, not sure how to accomplish something more complex like the above use case in a elegant fashion.
PrettyFaces offers url-rewriting for JSF.
You can't, however, 'hide' the GET parameters. Unless you make them POST parameters. But all submissions are POST in JSF by default.