Expand my Community achievements bar.

SOLVED

Journal's comment resource type is set to social/journal/components/hbs/comment

Avatar

Level 3

Hi,

I have set the comment resource type to my custom comment component in journal component's design dialog. But on adding a comment to a blog,  the resourceType of comment is set to 'social/journal/components/hbs/comment' instead of the resource type set in design dialog.
Can any one suggest the solution for this.

Thanks

Rajeev

1 Accepted Solution

Avatar

Correct answer by
Level 2

Open the design dialog for extended Journal component. There you can specify the type for your Entry Topic. Set it to you custom entry topic component's path.

From now on the new posts created with this component will have the correct resourceType.

But you might see that the posts are not being listed on the list page.

View solution in original post

8 Replies

Avatar

Level 2

Did you get any solution  to this? Im still stuck. Basically the extended component doesnt work. The journal works but the entry_topic doesnt

Avatar

Level 3

I looked at the journal jar, there component resources type is hard coded. That's why it is being set to ootb component resource type.

Avatar

Level 2

So is your entry_topic working with custom changes?

Avatar

Level 3

If you want to change the resource type, you'll have to customize the backend code. But if your resource type is not changing, it should work with existing apis.

Avatar

Level 2

But extending will change the resource type right? Like overlay wont change the resource type... but extending will.

This sort of thing in the js

SCF.registerComponent('/apps/custom-blog/components/hbs/entry_topic', CustomBlogTopic, CustomBlogTopicView);

SCF.registerComponent('/apps/custom-blog/components/hbs/journal', CustomBlog, CustomBlogView);

Avatar

Level 3

Yes. Extending the components will change the resource type and you need to take care of that in js file. But when you check the stored content, you will find that the resource type stored content is ootb component resource type and not yours.

Avatar

Level 2

Then what file do we need to update so that we can update the resource type or entry resource type so that our extended entry_topic component is the one being referred to instead of the OOTB component?

Because apparently the below code doesn't work for entry_topic

SCF.registerComponent('/apps/custom-blog/components/hbs/entry_topic', CustomBlogTopic, CustomBlogTopicView);

Avatar

Correct answer by
Level 2

Open the design dialog for extended Journal component. There you can specify the type for your Entry Topic. Set it to you custom entry topic component's path.

From now on the new posts created with this component will have the correct resourceType.

But you might see that the posts are not being listed on the list page.