Why aren't my Content Items accepting their new Workflow? - sitecore

All of my Content Items in one node have a bad reference to a workflow. I am trying to create one to replace the missing Workflow. I did these steps:
Created a new workflow
Located the common inherited template that all content items in this node use.
In the standard values I chose my new workflow for the "Workflow" and "Default Workflow" fields (I think I just need default, but I am not sure.)
Saved and Smart Published.
The content items still show the GUID for the missing Workflow. I click the template name at the top of the content item, double check the standard values on the template and everything looks great.
How do I force Content Items to retrieve the correct workflow from their Templates?

It looks like your content items have broken from their standard values which is why your new standard value WF is not getting set. What version of Sitecore are you using? You can use the reset button on each content item to bring it back to the standard value just for the workflow.
Go to the View ribbon and enable Standard Fields
For each content item that has the wrong workflow, go to the Versions ribbon and click the Reset button on the left
In the pop-up scroll all the way down to the bottom Workflow section and check the boxes to reset specific fields
Repeat this process for all of the content items
Another idea is to write code to programatically reset fields or set them to a new WF

Related

Kentico - Editable WebPartZones on children pages?

I added a WebPartZone in the master page at the top pf the master page, this web part zone is a message bar that will display on all the pages but could be different on each page. Is it possible to have a web part zone in the template that is editable on each page? Or is a different way to do it?
Thanks
The short answer no. From the template engine prospective whatever editable in the master - is not editable in its children. All editable web parts/widgets editable on the master, are not editable in its children.
If you really want to have an editable text in the master and all its children, you probably need to clone and customize web part and form control it is based on. Or create you own web part.
P.S. You can have editable text in your page template so all page that use this template will have this editable text working.
If you can give more details on what kind thing you want to edit would be easier to provide an answer
P.P.S. You can have a work around but it will not be with editable text. You will have to edit message text at the form tab. Would that suits you?
You can add the webpart on your master, and use a macro to get the content, like {%CurrentDocument.GetValue("Message")%}, but you have to add a field to each page to store the message in.
Just throwing out one more option, if what you want to display changes from page type to page type, you can put a repeater on the master page, put a path of a period (current document), then use macros to set the page type to the current document class name and the transformation to currentdocument.classname+".mastermessage"
Using a macro, then add a transformation "mastermessage" to each page type it will encounter, then you can change the fields and format for each page type.

Sitecore Custom Multilist

In Sitecore, I built two custom multi-lists, where the second one depends on the first. The only issue is, that after selecting the first one, I have to save the item before the second multi-list filters the items.
My question somebody know how to create a two custom multi-list on Sitecore, where the second one filters automatically after selecting an item in the first (without save event), or which event can I override to do it?
It sounds like what you are looking for is some kind of front end event that you can use in the Sitecore backend to update a list based on another list selection without a save event. I don't think there is really anything out of the box for that..
Really what you should be doing (to do the 'sitecore' thing) would be to have your first selection (be it multi-list or whatever you like) simply point to a datasource item for another template item which is where your user can set the second option(s). I think you would benefit from taking a different approach like this rather than trying to customise Sitecore here.

Item to be bucketed according to a date field when created

I have created a content item at /sitecore/Home/FootballFever/Articles and have given insert option so that we can add only items of templates "Article".As of now,these article items are bucketable according to a field created date.
Now, i have insert option "Add Article" and "Insert from Template" buttons in the Home ribbon "Insert" block. When i create an item through "Insert from Template", the item automatically gets added in respective bucket with path as created date. for example if the item has created date is "7/21/2014" then path will be "/Articles/2014/7/21/ ".
But when i click on "Add Article", the item gets added in /Articles and i have to Sync everytime to get it to correct path.
How can I have the same behavior as that of "Insert from Template" but with path having Release date which is a field of template "Article"?
Please make sure that Article template has Bucketable field checked in its Standard values (for Article template).
If not, when you add a new item into buckets folder, newly added item itself is not bucketable, unlike the rest already existing items from the same bucket folder.
I have just made a proof of concept on my sandbox environment and can confirm that in case you add a new item with Bucketable checked by Standard values - it comes into a bucket straight away and you do not need to perform Sync.
Hope this helps.
UPDATE: I have written a blog post specially to cover your question,with comprehensive description.
http://blog.martinmiles.net/post/understanding-buckets-adding-new-items-to-buckets-correctly
By default, items will be structured in bucket folders, five levels deep based on the date and time the item was created. There are a couple of other built in rules you can use like using part of the Guid or part of the name. The thing to note here is that these are all things that are available on item creation. If you want to structure your articles based on a custom 'Release Date' then you will need to write a custom rule and you will also have to implement an OnItemSaved event handler. Here is a article on how to write the custom rule.
Generally you don't have to worry about how the items are structured in your bucket. Editors should be using the search tab to find the items they need.
Having said that, this SO post discusses how to structure your bucket items based on a custom field. Some things to note here is that this is generally a global change. There are ways around it that enables you to have different strategies for different buckets but you'll then have to do additional work to override the LinkProvider and potentially other things.

Sitecore Page Editor Add New Page Inline

In my content tree, I have "Folder" items that have no presentation, but have all the insert options on them. How would you be able to use the "Insert Page" button in the ribbon to insert a new content item in the right part of the tree?
For Example:
I have my home page Content(Folder)/Home.item
All of my insert options are on Content(Folder), how do I add a new Home.item type without nesting it under Home.item?
In order to be able to use the Insert Page button, the item you are inserting under must have Presentation defined. It doesn't need to have components added, and I've worked round this before by simply define a "blank" layout and setting it on those items. Maybe create yourself a new template (inheriting from Folder) and then set Layout on that. But, this is a workaround at best. You can only "Insert Page" below the current page you are on, so you would essentially have to navigate to a blank page in order to create the sibling.
From what you have stated, it sounds like you may want to re-think where your Insert Options have been set and your content structure, i.e. why would you want create another Home item? Creating so will require set-up of another <site> and related config. You probably also want to separate those sites out with other settings, there is some good example of multi-site structure in this blog post. If you go down this route look into using Branch Templates. But, difficult to know what you are doing without context...

Add Activities to Activity Dropdown in Task Work Item

Is there a way to modify the values that are currently in the Activity dropdown for a Task work item? Here's the current list:
Deployment
Design
Development
Documentation
Testing
Requirements
Sure, you have to edit the Process Template or the Work Item type of the existing Team Project you want to change.
This article gives you information about how to edit a Process Template.
If you want to edit the Work Item of an existing team project is almost the same process, only the start is different as you have to select this command:
Once your Task Work Item Type is selected, double-click on the Activity field in the Fields tab.
Then in the windows that opens, go to the "Rules" tab and double-clik on the "SUGGESTEDVALUE" line.
Then change the lines you want.
Finally save the Work Item type, if you're from the process template then follow the procedure told in the article, if you're from the Work Item in an existing Team Project, you just have to save for the change to be effective.
BUT, beware (for the existing Team Project case) that if some Work Items already exist in your Team Project that use a value you removed, these ones will generate an error the next time you'll edit them. You'll have to change the value of the Activity field to an existing one if you want the Work Item to be save-able.