122 lines
		
	
	
		
			4.7 KiB
		
	
	
	
		
			Smarty
		
	
	
	
	
	
			
		
		
	
	
			122 lines
		
	
	
		
			4.7 KiB
		
	
	
	
		
			Smarty
		
	
	
	
	
	
| [%# comments_only.tpl 2018-11-05                        -%]
 | |
| [%# Textual comment summary for Community News.         -%]
 | |
| [%# This one partitions comments into past and current. -%]
 | |
| [%# It requires make_shownotes > V0.0.28                -%]
 | |
| [%- USE date -%]
 | |
| [%- USE wrap -%]
 | |
| [%- DEFAULT mark_comments = 0
 | |
|     aob = 0                   -%]
 | |
| [% TAGS outline -%]
 | |
| %% IF mark_comments == 1 && missed_comments.size > 0
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| 
 | |
| Missed comments last month
 | |
| --------------------------
 | |
| 
 | |
| Note to Volunteers: These are comments for shows last month that were not read
 | |
| in the last show because they arrived after the recording.
 | |
| 
 | |
| %% FOREACH comment IN missed_comments
 | |
| ================================================================================
 | |
| hpr[% comment.episode %] ([% comment.date %]) "[% comment.title %]" by [% comment.host %].
 | |
|   ------------------------------------------------------------------------------
 | |
|   From: [% comment.comment_author_name -%] on [% date.format(comment.comment_timestamp_ut,'%Y-%m-%d','UTC') -%]:
 | |
| [%- IF comment.comment_title.length > 0 -%]
 | |
|  "[% comment.comment_title %]"
 | |
| [%- ELSE -%]
 | |
|  "[no title]"
 | |
| [%- END %]
 | |
|   ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
 | |
| [% wrap(comment.comment_text, 80, '  ', '  ') FILTER decode_entities %]
 | |
| 
 | |
| %% END
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| %% END
 | |
| 
 | |
| Comments this month
 | |
| -------------------
 | |
| 
 | |
| %% IF comment_count > 0
 | |
| There [%- comment_count == 1 ? "is $comment_count comment" : "are $comment_count comments" -%] in total.
 | |
| 
 | |
| %% IF past_count > 0
 | |
| Past shows
 | |
| ----------
 | |
| 
 | |
| There [% past_count == 1 ? "is $past_count comment" : "are $past_count comments" %] on [% past.size %] previous [% past.size == 1 ? "show" : "shows" %]:
 | |
| %% FOREACH ep IN past.keys.sort
 | |
| %% arr = past.$ep
 | |
| 
 | |
| ================================================================================
 | |
| hpr[% arr.0.episode %] ([% arr.0.date %]) "[% arr.0.title %]" by [% arr.0.host %].
 | |
| %% FOREACH row IN arr
 | |
|   ------------------------------------------------------------------------------
 | |
|   Comment [% row.index %]: [% row.comment_author_name -%] on [% date.format(row.comment_timestamp_ut,'%Y-%m-%d','UTC') -%]:
 | |
| [%- IF row.comment_title.length > 0 -%]
 | |
|  "[% row.comment_title FILTER decode_entities %]"
 | |
| [%- ELSE -%]
 | |
|  "[no title]"
 | |
| [%- END %]
 | |
|   ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
 | |
| [% IF mark_comments == 1 && ((row.comment_timestamp_ut <= last_recording) && (arr.0.date.substr(0,7) == last_month)) -%]
 | |
| [% wrap(row.comment_text, 80, '| ', '| ') FILTER decode_entities %]
 | |
| [% ELSE -%]
 | |
| [% wrap(row.comment_text, 80, '  ', '  ') FILTER decode_entities %]
 | |
| [% END -%]
 | |
| %% END
 | |
| %% END
 | |
| 
 | |
| 
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| 
 | |
| %% END
 | |
| 
 | |
| %% cc = (comment_count - past_count)
 | |
| %% IF cc > 0
 | |
| This month's shows
 | |
| ------------------
 | |
| 
 | |
| There [% cc == 1 ? "is $cc comment" : "are $cc comments" %] on [% current.size %] of this month's shows:
 | |
| %% FOREACH ep IN current.keys.sort
 | |
| %% arr = current.$ep
 | |
| 
 | |
| ================================================================================
 | |
| hpr[% arr.0.episode %] ([% arr.0.date %]) "[% arr.0.title %]" by [% arr.0.host %].
 | |
| %% FOREACH row IN arr
 | |
|   ------------------------------------------------------------------------------
 | |
|   Comment [% row.index %]: [% row.comment_author_name -%] on [% date.format(row.comment_timestamp_ut,'%Y-%m-%d','UTC') -%]:
 | |
| [%- IF row.comment_title.length > 0 -%]
 | |
|  "[% row.comment_title FILTER decode_entities %]"
 | |
| [%- ELSE -%]
 | |
|  "[no title]"
 | |
| [%- END %]
 | |
|   ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
 | |
| [% wrap(row.comment_text, 80, '  ', '  ') FILTER decode_entities %]
 | |
| %% END
 | |
| %% END
 | |
| %% END
 | |
| 
 | |
| %% ELSE
 | |
| There were no comments this month.
 | |
| %% END
 | |
| 
 | |
| [%# Any other business? -%]
 | |
| [% IF aob == 1 -%]
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
 | |
| =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
 | |
| Any other business
 | |
| ------------------
 | |
| 
 | |
| [% INCLUDE $aobfile -%]
 | |
| [%- END %]
 | |
| [%#
 | |
|   # vim: syntax=tt2:ts=8:sw=4:ai:et:tw=78:fo=tcrqn21
 | |
| -%]
 |