OK, here's the process I took...
create a new template "Mail Message"
create a "__Standard Values" item for the template
edit the "Subject" field in the standard values item: "Monthly email newsletter"
create a branch for the template
do NOT set the Subject field in the branch item
create an item from the branch
I would expect the subject would be the one from the standard values item, however it seems the branch field value is blank, and in turn the created item also has a blank subject field.
Should the Branch field value be that of the standard value. Or does the very act of creating a branch item eliminate any standard values you set.
Does the field versioing have any effect (e.g. Shared, Unversioned)?
I haven't been a big user of Branches, so I am surprised at the behaviour, but if it is normal, all good. Just want to confirm.
Alternatively, if the template or standard values were locked when the branch or item was created, the standard values might not have carried through.
Either way, you need to reset the value of the sitecore item. On the item, click the 'Reset' button, which is under the Versions tab and check the checkbox next to 'Subject'. Now, the field will show as 'Subject [standard value]'.
Hope that helps!
Creating the branch for the item template should copy the standard values and allow you to update the default values from the template.
So for example if you had "Monthly email newsletter" in the "Subject" field of the template it would be the same in the branch and all items created from that item.
Changing that field in the Standard Values should then update it in the branches and items.
If you have changed the field on the item however the link would be broken and you would no longer manage it from the standard values with out resetting the values.
Not sure on the shared/unversioned factor but dont think it effects the standard values.
When you change the value in branch template, you've broken the link already. So after that if you change the standard value, the value in branch template will not effect
Related
Insert option is not coming, can anyone help on this how I can programmatically insert option with item when we do not have insert option in _standardValue of template
When you create/edit the item from code, you can at the same time write to the Insert Options field, aka __Masters as field name, aka Branches as code constant, just as any other field. The field contains a pipe-separated list of template ID's. For example, like this:
item[Sitecore.FieldIDs.Branches] = "{TemplateId1}|{TemplateId2}|{...}";
// above is equivalent to item["__Masters"] = "...";
As you say, this will write a local value on the item being edited, and will therefore break any inheritance of the insert options that may be defined in __Standard Values. But in some scenarios this is actually better than having it on __Standard Values.
I have an item that is displayed conditionally - based on another item selection. I want to make that item non-required when hidden. What is the best way to do that?
As you have probably found, you cannot just set the dependent item's Required attribute, as this makes it required even when hidden. Instead you can create a Validation of type "Item is NOT NULL" on the dependent item, but with a server-side condition based on the value of the other item.
For example, suppose the first item is P12_JOB and the second is P12_COMMISSION, and P12_COMMISSION is only shown when P12_JOB = 'SALESMAN'. Then this Validation will do it:
As you can see there are various settings available there that you should check are appropriate for you e.g. Always Execute, Display Location.
I'm using the page below a POS sales list. Here the user can use the barcode pistol and pass the article and the code is translated into the item no.
The problem is when they use the pistol and end to pick a item and want to pass to next one the line go automatically to the first column (Item type) and my goal was to force to go into the second column (Item no), because the Item type is by default the type "product".
Only change the order of columns of Item no to Item product is not enough in this case.
Since ACTIVATE is not supported for controls in RTC.
Not many good options here.
Try using QuickEntry Property. Set it to false for all controls on subpage except No..
Create custom page with as less fields as possible, use it as buffer to scan all items and create sales lines upon closing of this new page. You can implement desired behavior on this page and keep original page almost unmodified
Create add-in that will intercept scanner output somehow.
When updating the standard values of a data template and saving the change, the updated value isn't being reflected in the instance(s) of the data template, until the cache is cleared.
This is happening across all data templates, and isn't due to the standard value being overwritten within the instance(s).
For example, in a base page template that is inherited by the content page template, there is a field that contains an email address.
After creating a new content page instance within the content tree, the email field is correctly set to the standard value (and has [standard value] next to the field name label).
After going back to the base page template, updating the email address and saving the item, the value in the content page instance is not updated, however it still has the [standard value] label next to the field.
The value of the field is not updated to reflect the base template until the cache is cleared (currently using the http://localhost/sitecore/admin/cache.aspx) page and using the 'Clear all' button.
Why is the standard value being cached within the content editor, and how can we prevent that from happening?
UPDATE
When attempting to reset the content item's field value to the standard value (using the ribbon command Versions -> Reset), the value of the field in the standard value box is also showing the cached standard value, and not the value that has been updated/saved in the data templates standard values.
In the content editor choose the data item, from the ribbon select the version tab and click the reset button (make sure standard fields are visible).
Select the layouts field and reset it to standard values.
This will show if you have values setup on the standard values correctly.
I am trying to display field titles above the appropriate columns in a name value list in Sitecore.
e.g. So instead of this
The name value list would look like this
Is there an easy method of achieving this apart from writing a custom control?
There is no out of the box support for applying a label to the values in a name value list, as #jammykam mentioned.
Since what you are storing would not typically be handled as key/value data, the name value list type might not be the best fit for what you are doing - think what you would have to do if you needed to add extra information e.g. title. I would suggest creating a simple template for 'person details' and then add 'people' items as sub-items of your existing item.
Seems like you want to give the authors a hint regarding the input fields and the best way to do that is using the "Short Description" field in "Help" section of the template under Standard Values. You can possibly enter something like as a hint.
A less optimal option would be to set up standard values for that field so the authors always have a value that suggests the type of input value for key and value.