mirror of
https://github.com/documize/community.git
synced 2025-08-05 05:25:27 +02:00
Tidy HTML, separate detailed single-board data
This commit is contained in:
parent
2d7647e790
commit
0345c93560
8 changed files with 155 additions and 134 deletions
|
@ -12,32 +12,31 @@
|
|||
package trello
|
||||
|
||||
const membersTemplate = `
|
||||
<h3>Member Stats</h3>
|
||||
<p>
|
||||
There are {{len .MemberBoardAssign}} members assigned to {{.CardAssignTotal}} cards of the total {{.CardTotal}} cards across {{len .Boards}} boards.
|
||||
</p>
|
||||
{{if gt (len .Boards) 0}}
|
||||
<div class="heading">Member Stats</div>
|
||||
<p>
|
||||
There are {{len .MemberBoardAssign}} members assigned to {{.CardAssignTotal}} cards of the total {{.CardTotal}} cards across {{len .Boards}} boards.
|
||||
</p>
|
||||
|
||||
<div class="section-trello-render">
|
||||
<table class="trello-table" class="width-100">
|
||||
<tbody>
|
||||
|
||||
{{range $m := .MemberBoardAssign}}
|
||||
<tr>
|
||||
<td>
|
||||
<img class="trello-avatar" src="https://trello-avatars.s3.amazonaws.com/{{$m.AvatarHash}}/50.png" height="50" alt="Member Avatar">
|
||||
</td>
|
||||
<td>
|
||||
<h6>{{$m.MemberName}}</h6>
|
||||
<p>
|
||||
{{range $ac := $m.AssignCounts}}
|
||||
{{$ac.BoardName}} ({{$ac.Count}}),
|
||||
{{end}}
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
{{end}}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="section-trello-render">
|
||||
<table class="trello-table" class="width-100">
|
||||
<tbody>
|
||||
|
||||
{{range $m := .MemberBoardAssign}}
|
||||
<tr>
|
||||
<td>
|
||||
<img class="trello-avatar" src="https://trello-avatars.s3.amazonaws.com/{{$m.AvatarHash}}/50.png" height="50" alt="Member Avatar">
|
||||
</td>
|
||||
<td>
|
||||
<h6>{{$m.MemberName}}</h6>
|
||||
<p>
|
||||
{{range $idx, $ac := $m.AssignCounts}}{{if gt $idx 0}}, {{end}}{{$ac.BoardName}} ({{$ac.Count}}){{end}}.
|
||||
</p>
|
||||
</td>
|
||||
</tr>
|
||||
{{end}}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{{end}}
|
||||
`
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue