Bug 970822 - Injects are not rendered in the doc preview.
Summary: Injects are not rendered in the doc preview.
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: PressGang CCMS
Classification: Community
Component: Web-UI
Version: 1.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 1.2
Assignee: Lee Newson
QA Contact:
URL:
Whiteboard:
: 971233 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-06-05 02:06 UTC by Jared MORGAN
Modified: 2015-08-10 01:23 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-11-08 02:05:19 UTC
Embargoed:


Attachments (Terms of Use)

Comment 1 Lee Newson 2013-06-05 04:23:18 UTC
Firstly your syntax is incorrect for the injection, it should be <!-- Inject: <ID> --> (note the missing colon), so if that was correct then it would appear on the Docbuilder. However it would not appear on the live preview so I'm gonna edit the title to match that (also made your comment private since it has internal links).

Comment 2 Lee Newson 2013-06-06 04:36:57 UTC
*** Bug 971233 has been marked as a duplicate of this bug. ***

Comment 3 Lee Newson 2013-09-17 07:33:48 UTC
I've implemented a first pass at this in Build 201309171700.

Currently the injections aren't resolved fully and will only display the topic ID instead of the topic title (and the links are useless). It is done this way as it would be too slow to have to fetch each topics information and provide the rendering in a reasonable time frame. To do a full rendering we'd have to asynchronously load and replace the content, in the same way that images are loaded.

As an example see topic 3676 on the test server.

Comment 5 Jared MORGAN 2013-09-17 22:35:56 UTC
Yep, I corrected the injects at the time (as per an IRC with you) and they then rendered in the published doc.

This extra level of functionality in the test topic is actually pretty good. This way, displaying the injects like this shows you that you have structured them correctly. 

Early on, I was making the mistake with injects you detected in Comment#1 because I wasn't getting any feedback from the system that the syntax was incorrect. If new users know that they should see an in-line render of the referenced topic, that is a great visual key for them to know they've "done it right".

For now, I think this solution is fine.

Comment 6 Lee Newson 2013-09-17 23:23:36 UTC
Really the XML validation that is done should also check for any incorrect injection references, however we have BZ#997681 open to fix that issue.

I've also made another minor change to the initial pass. The links that are injected will now link to the editor for the injected topic.

Comment 7 Lee Newson 2013-11-08 02:05:19 UTC
I'm going to mark this as complete since it was released as part of 1.2 and if we want the titles instead of just the ids then a new bug/RFE should be opened.


Note You need to log in before you can comment on or make changes to this bug.