mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 15:30:13 +01:00
Export to Excel XLSX. Does work, but does not export all fields yet correctly. In Progress.
Thanks to gameendman, alfredgu and xet7 ! Related #3173
This commit is contained in:
parent
815b32c9b6
commit
855151a8d1
8 changed files with 1009 additions and 12 deletions
|
|
@ -324,6 +324,10 @@ template(name="exportBoard")
|
|||
a.download-json-link(href="{{exportUrl}}", download="{{exportJsonFilename}}")
|
||||
i.fa.fa-share-alt
|
||||
| {{_ 'export-board-json'}}
|
||||
li
|
||||
a(href="{{exportUrlExcel}}", download="{{exportFilenameExcel}}")
|
||||
i.fa.fa-share-alt
|
||||
| {{_ 'export-board-excel'}}
|
||||
li
|
||||
a(href="{{exportCsvUrl}}", download="{{exportCsvFilename}}")
|
||||
i.fa.fa-share-alt
|
||||
|
|
|
|||
|
|
@ -435,6 +435,23 @@ BlazeComponent.extendComponent({
|
|||
};
|
||||
return FlowRouter.path('/api/boards/:boardId/export', params, queryParams);
|
||||
},
|
||||
exportUrlExcel() {
|
||||
const params = {
|
||||
boardId: Session.get('currentBoard'),
|
||||
};
|
||||
const queryParams = {
|
||||
authToken: Accounts._storedLoginToken(),
|
||||
};
|
||||
return FlowRouter.path(
|
||||
'/api/boards/:boardId/exportExcel',
|
||||
params,
|
||||
queryParams,
|
||||
);
|
||||
},
|
||||
exportFilenameExcel() {
|
||||
const boardId = Session.get('currentBoard');
|
||||
return `export-board-excel-${boardId}.xlsx`;
|
||||
},
|
||||
exportCsvUrl() {
|
||||
const params = {
|
||||
boardId: Session.get('currentBoard'),
|
||||
|
|
|
|||
|
|
@ -166,7 +166,7 @@ Template.disambiguateMultiMemberPopup.events({
|
|||
});
|
||||
|
||||
Template.moveSelectionPopup.events({
|
||||
'click .js-select-list'(event) {
|
||||
'click .js-select-list'() {
|
||||
// Move the minicard to the end of the target list
|
||||
mutateSelectedCards('moveToEndOfList', { listId: this._id });
|
||||
EscapeActions.executeUpTo('multiselection');
|
||||
|
|
|
|||
|
|
@ -85,14 +85,14 @@ function initSortable(boardComponent, $listsDom) {
|
|||
},
|
||||
});
|
||||
|
||||
function userIsMember() {
|
||||
return (
|
||||
Meteor.user() &&
|
||||
Meteor.user().isBoardMember() &&
|
||||
!Meteor.user().isCommentOnly() &&
|
||||
!Meteor.user().isWorker()
|
||||
);
|
||||
}
|
||||
//function userIsMember() {
|
||||
// return (
|
||||
// Meteor.user() &&
|
||||
// Meteor.user().isBoardMember() &&
|
||||
// !Meteor.user().isCommentOnly() &&
|
||||
// !Meteor.user().isWorker()
|
||||
// );
|
||||
//}
|
||||
|
||||
boardComponent.autorun(() => {
|
||||
let showDesktopDragHandles = false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue