Mercurial > gemma
diff client/src/components/systemconfiguration/PDFTemplates.vue @ 2874:b9a6abef9f1c
client: more unified table layout
Expandable/collapsible rows are now also handled by the component
author | Markus Kottlaender <markus@intevation.de> |
---|---|
date | Mon, 01 Apr 2019 11:51:03 +0200 |
parents | 9adbe0633bf9 |
children | 106e1d011a5d |
line wrap: on
line diff
--- a/client/src/components/systemconfiguration/PDFTemplates.vue Mon Apr 01 10:46:18 2019 +0200 +++ b/client/src/components/systemconfiguration/PDFTemplates.vue Mon Apr 01 11:51:03 2019 +0200 @@ -18,28 +18,30 @@ { id: 'country', title: `${countryLabel}`, class: 'col-2' } ]" /> - <UITableBody - :data="templates | sortTable(sortColumn, sortDirection)" - v-slot="{ item: template }" - > - <div class="py-1 col-4">{{ template.name }}</div> - <div class="py-1 col-4">{{ template.time }}</div> - <div class="py-1 col-2" v-if="template.country"> - {{ template.country }} - </div> - <div class="py-1 col-2" v-else><i>global</i></div> - <div class="col py-1 text-right"> - <button - class="btn btn-xs btn-info mr-1" - ref="downloadTemplate" - @click="downloadTemplate(template)" - > - <font-awesome-icon icon="download" fixed-width /> - </button> - <button class="btn btn-xs btn-dark" @click="deleteTemplate(template)"> - <font-awesome-icon icon="trash" fixed-width /> - </button> - </div> + <UITableBody :data="templates | sortTable(sortColumn, sortDirection)"> + <template v-slot:row="{ item: template }"> + <div class="py-1 col-4">{{ template.name }}</div> + <div class="py-1 col-4">{{ template.time }}</div> + <div class="py-1 col-2" v-if="template.country"> + {{ template.country }} + </div> + <div class="py-1 col-2" v-else><i>global</i></div> + <div class="col py-1 text-right"> + <button + class="btn btn-xs btn-info mr-1" + ref="downloadTemplate" + @click="downloadTemplate(template)" + > + <font-awesome-icon icon="download" fixed-width /> + </button> + <button + class="btn btn-xs btn-dark" + @click="deleteTemplate(template)" + > + <font-awesome-icon icon="trash" fixed-width /> + </button> + </div> + </template> </UITableBody> <button class="btn btn-info mt-2" @click="$refs.uploadTemplate.click()"> <font-awesome-icon