cancel
Showing results for 
Search instead for 
Did you mean: 

header title aikau

_jan
Champ on-the-rise
Champ on-the-rise
Hello, I am trying to change title of new share page in header which I created by aikau.
my code is :

model.jsonModel = {
    widgets: [{
        id: "SET_PAGE_TITLE",
        name: "alfresco/header/SetTitle",
        config: {
            title: "Custom title"
        }
    }]
};


The problem is that it sometimes work and sometimes don't. There isn't any error in console or in alfresco logging. Sometimes I refresh page and it appear and sometimes it does not appear.
I don't know where to try to find a mistake.
3 REPLIES 3

_jan
Champ on-the-rise
Champ on-the-rise
I found that it is because at that moment when aikau publish
ALF_UPDATE_PAGE_TITLE
, component/dom element for title is undefined. Only sometimes it is loaded before SetTitle widget and it change title correctly.
Is in AIKAU some config parameter for widget or some function to wait with publishing for other widget ?

ddraper
World-Class Innovator
World-Class Innovator
What versions of Alfresco and Aikau are you using?

_jan
Champ on-the-rise
Champ on-the-rise
Hi, I am using Alfresco 4.2.f. I dont know how to check AIKAU version.
I made workaround. When title is ready it will publish some payload about it and custom SET_PAGE_TITLE is listening for this. After SET_PAGE_TITLE receive that title is ready it will process title change.