Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
torque-sites
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ots
MediaWiki
torque-sites
Commits
8e78211f
Commit
8e78211f
authored
3 years ago
by
Frank Duncan
Browse files
Options
Downloads
Patches
Plain Diff
Add ability for Generic TOCs to omit wiki toc
parent
692fcdcd
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
etl/etl/toc.py
+9
-2
9 additions, 2 deletions
etl/etl/toc.py
with
9 additions
and
2 deletions
etl/etl/toc.py
+
9
−
2
View file @
8e78211f
...
...
@@ -260,8 +260,11 @@ class GenericToc(Toc):
self
.
data
[
grouping
][
"
all_proposal_ids
"
].
append
(
proposal
.
key
())
def
template_file
(
self
):
template
=
"
__TOC__
"
template
+=
""
template
=
""
if
self
.
include_wiki_toc
():
template
+=
"
__TOC__
"
template
+=
""
template
+=
"
{% for group in groups %}
\n
"
template
+=
"
{%- for proposal_id in group.all_proposal_ids %}
\n
"
template
+=
(
...
...
@@ -302,6 +305,10 @@ class GenericToc(Toc):
def
grouped_data
(
self
):
return
{
"
groups
"
:
list
(
self
.
data
.
values
())}
def
include_wiki_toc
(
self
):
"""
Add the wiki __TOC__ if this returns True
"""
return
True
class
GenericMultiLineToc
(
GenericToc
):
"""
A special case of GenericToc for columns that have multiple
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment