Composite C1: translated pages lost after English page moved (cut+paste) - c1-cms

One page has been moved in the page tree structure. It was a second level child, now it is a third level child. The change has been made in the default language - English.
Before this change the page had already been translated to other languages.
After the change I noticed that the translated versions don't appear in the tree, neither in the old place nor in the new one.
In the database table Composite_Data_Types_IPageStructure seems to define child-parent relations, not depending on the language at all (all pages have the same Id in all languages, right?).
Tables Composite_Data_Types_IPage_Unpublished_<culture-code> still contain the translated pages.
However, for some reason only the default language tree shows all the pages.
How can I fix this?

That page that is the new parent of the moved page hadn't been translated yet. It seems that the CMS does not display a translated child under the not translated parent.
The steps that fixed the problem:
1. Translate the new parent page.
2. Click "Restart server".
The translated child appears in the tree after the server is reloaded (the cache is cleared).
Repeat these steps for every language.

Related

CouchCMS Blog index items to display inline (blog_list.html)

I've used Couch CMS to create a blog page with index of articles.
I've used Couch for blog systems before and the blog index item always displays underneath each other. However, this time they must display next to each other. I've tried so many things, but the index items remains under each other oppose to next to each other. The website is based on bootstrap, but the columns just keep on stacking on top of each other.
Can someone please help?
URL: https://legacyeb.co.za/news.php
Solved. Just make sure the couch page open and page close tags are in the correct place.
Everything in between the tags gets repeated with the blog index.

What is the idea of watgtail root[depth=0] page?

Please i need to understand the idea of wagtail root[depth=0] page. Because for me homepages must be on the root level but currently all homepages are on depth=1 level, why and what is the idea to have root level page.
I checked docs etc, but didnt find clear info of this idea.
Also why homepages[depth=1] related to site object and not root[depth=0]?
It's mostly an implementation detail to make Wagtail's internal logic simpler. For example, the Page model has copy and move methods, which take the new parent page as a parameter. Having a fixed, non-editable page at the root level means that there's always a meaningful value we can pass as the parent - if the root node wasn't there, we'd have to implement separate code paths for "move a page to a new parent" versus "move a page to the top level".
However, there's also one place where the root page is directly meaningful to the site admin: it's possible to assign permissions to that page (through the Settings -> Groups area). Since permissions propagate down the page tree, this means that the permission will apply to all pages across all sites. For example, if you want to give a (non-superuser) group the ability to create new homepages, you can do that by giving them 'add' permission on the root page.

Get content Id (nid) from path on views block

I just can't seem to wrap my head around Drupal relationships. I have been reading and watching tutorials, but as soon as I try to get my own project done - I fail. I think it's very basic, so I would love to understand it. Maybe someone here can help me understand how it works :)
On my drupal site, I want to keep track of some private game tournaments.
I have created a content type called contestant, which has fields like: Tournament date, Player name, Final Position. I can then create a view that list the information from one tournament. I used the help I got from this thread: drupal views dynamic filter
I would like to have the view described above as a block. And then place that block-view on a "tournament description" page. I could do this, by simply creating a new block each time, and then manually place it on the page it should be shown (structure-->Blocks-->configure), but that is not an elegant way to do it. I am pretty sure this is where Relationships should be used. But I fail to understand how to create this relationship, so that the specific block view, that matches the specific tournament description page will be displayed together.
Use a Content:Nid as a Contextual filter.
WHEN the Filter value is not in the URL >>
Provide default value
Content ID from URL

Weird navigation bug, with side menu, routing views won’t update

I am fairly new to ionic (using the 1.0.0 beta1) and Angular, and I am working on my first project, where I experience weird bugs, I cannot understand.
My app is based on the "Ionic Book" task app, described here: http://ionicframework.com/docs/guide/building.html.
Here's the link to my app: http://plnkr.co/edit/zp49fsbmOfMiQfXDopxt?p=preview1
In my version of the task-app, the tasks are called "instances" and each instance has several "categories" in it. Each category has a title and a status.
The user can enter instances in the side menu, via the '+' button. And each instance is created with some dummy categories.
The user can choose his instances and then choose a category to see its status.
To see what bugs occur, please visit my app http://plnkr.co/edit/zp49fsbmOfMiQfXDopxt?p=preview1 and add a few instances with dummy titles like a, b, c, d. The url form may remain empty, it is not yet needed. Don't click on a category yet. You will notice the switching from one category to another works as expected (though all instances have the same categories).
Now when you click on a category in an instance, say in instance b, the view shows the category status, with the right category title in the nav-bar. When you now click on the back button, the mess starts:
If you now click on any category, the view always displays the category, which you clicked at first! Not the one you want to see. Also, if I now change the instance (say to instance a) and try to switch back to instance b, the switch will not be performed (the title remains a)!
I really can't see where those bugs come from, as the localeStorage seems to be updated on clicks! (check the lastActiveInstance and lastActiveCat variables in localStorage!)
Do you guys see where my mistake is? By this time I think it must be some fundamental problem with the $stateProvider and the back button?
I'd really appreciate your help, since I am pretty desperate right now. Thank you
For what I've seen, it looks like you have only one MainCtrl for the whole application, is that right?
It looks like the variables of this controller are only updated once. So your activeInstance will receive it's value when you click for the first time to see the category, but then if you come back and click again on anything, the value of this variable is not being updated. You're calling selectCat function but I don't see it updating the values of activeInstance.
I hope it's only that!
It is now fixed with the new ionic 1.0 beta 5b.
View title updates as expected.
From the changelog:
- List item
- make it set navbar if title changes back to old value (919d4f8d, closes #1121)

Show custom object in related list under page layout

I have been trying this whole day but cant figure out... I have custom object called Dev which has many to many relationship with Accounts... I want this object Dev to show under related list of page layout of account... But it is not showing there how can i add that to related list?
Assuming you have a lookup relation from Account to Dev and also a lookup from Dev to Account (creating your many-to-many), then this will work fine.
Try re-creating your lookup relationship from Account to Dev. Then make sure that you add the related list and add to the page layouts in steps 5 & 6:
Step 5. Add reference field to Page Layouts (Yes to All)
Step 6. Add custom related lists (Yes)
That's all you need. If, however, your many-to-many relationship is unique or otherwise configured differently (with a junction table, for example) then the above may not work for you.
We always tend to use joining objects for these relationships, obviously you can show the list of joining objects as a related list, and you could display other fields from the dev object by use of formulae.
One thing we've tended to do is create an inline VF page which can then show all of the objects related to the current record.

Resources