Bug 1017511 - In articles 'Section:' is ignored unless nested in another section
Summary: In articles 'Section:' is ignored unless nested in another section
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: ---
: ---
Assignee: Lee Newson
QA Contact: mmurray
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-10-10 04:57 UTC by mmurray
Modified: 2013-10-10 06:14 UTC (History)
1 user (show)

Fixed In Version: 1.0.6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-10-10 06:14:55 UTC


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1013825 0 unspecified CLOSED Sprint 30 Sep - 18 Oct 2021-02-22 00:41:40 UTC

Internal Links: 1013825

Description mmurray 2013-10-10 04:57:46 UTC
Description of problem:
For articles 'Section:' is ignored unless nested in another section. So overall section numbering isn't as expected.

Example:
Would expect this content spec snippet [cs 12561, type=article]

Goal [12563]
Section: Documentation Plan
  Priority One Documentation Items [12852]
  Priority Two Documentation Items [12851]
Alpha and Beta Documentation [13164]
Section: Content Specification
  Content Specifications [12717]
  Section: JBoss BRMS 6
    BRMS Getting Started Guide [12574]
    BRMS Installation Guide [12571]

To come out something like
1. Goal
2. Documentation Plan
  2.1 Priority One
  2.2 Priority Two
3. Alpha and Beta Documentation
4. Content Specification
  4.1 Content Specifications
  4.2 JBoss BRMS 6
    4.2.1 BRMS Getting Started Guide
    4.2.2 BRMS Installation Guide 

But get
1. Goal
2. Priority One
3. Priority Two
4. Alpha and Beta Documentation
5. Content Specifications
6. JBoss BRMS 6
  6.1 BRMS Getting Started Guide
  6.2 BRMS Installation Guide

Version-Release number of selected component (if applicable):
Build 201309081012

How reproducible:
Also see cs 22485

Comment 1 Lee Newson 2013-10-10 05:09:04 UTC
Looking into this now. At a first glance it looks like it's not creating the root level section elements. ie

The XML is:

<section>
  <title>Goal</title>
  ...
</section>
<section>
  <title>Priority One</title>
  ...
</section>
...

When it should be:

<section>
  <title>Goal</title>
  ...
</section>
<section>
  <title>Documentation Plan</title>
  <section>
    <title>Priority One</title>
    ...
  </section>
</section>
...

Comment 2 Lee Newson 2013-10-10 05:42:28 UTC
Fixed in csprocessor 1.0.6

The problem was caused by the way the content was being added to the DOM Document, where the child elements were being added to the root element and as such it was producing incorrect XML.

Comment 4 mmurray 2013-10-10 06:08:51 UTC
Looks to be fixed in csprocessor 1.0.6:
* sections (eg, 1.) exist within document
* section topics (eg, 1.2) are correctly numbered
* sub-section topics (eg, 1.2.3) are correctly numbered

But noticed that sub-subsections are not included in table of contents. Perhaps not listing sub-subsections in table of contents is just how articles work? 

Example output:

So content spec
Alpha and Beta Documentation [13164]
Section: Content Specification
  Content Specifications [12717]
  Section: JBoss BRMS 6
    BRMS Getting Started Guide [12574]
    BRMS Installation Guide [12571]
    BRMS Administration and Configuration Guide [12575]
  Section: JBoss BPMS 6
    BPMS Getting Started Guide [12572]

results in
1. Alpha and Beta Documentation
2. Content Specification
  2.1 Content Specifications
  2.2 JBoss BRMS 6
  2.3 JBoss BPMS 6

Setting back to assigned for table of content behavior verification

Comment 5 Lee Newson 2013-10-10 06:14:55 UTC
Moving to CLOSED CURRENTRELEASE since that is a publican feature.

If you want more than a toc depth of 2 you need to add "toc_section_depth: <NUM>" to the publican.cfg, where <NUM> is the depth you want (2 is the default which is why subsections aren't displayed).


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