2
0
Эх сурвалжийг харах

fixed spacing & indentation - changed var to const

Erik Turk 7 жил өмнө
parent
commit
ecd77c8704

+ 32 - 36
client/components/cards/cardDetails.js

@@ -312,43 +312,39 @@ Template.copyManyCardPopup.events({
     card.sort = Lists.findOne(this._id).cards().count();
 
     if (titleEntry) {
-      var titleList;
-      var titleList = JSON.parse(titleEntry);
-	
-      
+      const titleList = JSON.parse(titleEntry);
       for (var i = 0; i < titleList.length; i++){
-	      var obj = titleList[i];
-
-	      card.title = obj.title;
-	      card.description = obj.description;
-	      card.coverId = '';
-	      const _id = Cards.insert(card);
-// In case the filter is active we need to add the newly inserted card in
-      // the list of exceptions -- cards that are not filtered. Otherwise the
-      // card will disappear instantly.
-      // See https://github.com/wekan/wekan/issues/80
-	      Filter.addException(_id);
-
-      // copy checklists
-	      let cursor = Checklists.find({cardId: oldId});
-	      cursor.forEach(function() {
-		'use strict';
-		const checklist = arguments[0];
-		checklist.cardId = _id;
-		checklist._id = null;
-		Checklists.insert(checklist);
-	      });
-
-      // copy card comments
-	      cursor = CardComments.find({cardId: oldId});
-	      cursor.forEach(function () {
-		'use strict';
-		const comment = arguments[0];
-		comment.cardId = _id;
-		comment._id = null;
-		CardComments.insert(comment);
-	      });
-	}
+        let obj = titleList[i];
+        card.title = obj.title;
+	card.description = obj.description;
+	card.coverId = '';
+	const _id = Cards.insert(card);
+        // In case the filter is active we need to add the newly inserted card in
+        // the list of exceptions -- cards that are not filtered. Otherwise the
+        // card will disappear instantly.
+        // See https://github.com/wekan/wekan/issues/80
+	Filter.addException(_id);
+
+        // copy checklists
+	let cursor = Checklists.find({cardId: oldId});
+	cursor.forEach(function() {
+	  'use strict';
+	  const checklist = arguments[0];
+	  checklist.cardId = _id;
+	  checklist._id = null;
+	  Checklists.insert(checklist);
+	});
+
+        // copy card comments
+	cursor = CardComments.find({cardId: oldId});
+	cursor.forEach(function () {
+	  'use strict';
+	  const comment = arguments[0];
+	  comment.cardId = _id;
+	  comment._id = null;
+	  CardComments.insert(comment);
+	});
+      }
       Popup.close();
     }
   },

+ 0 - 435
i18n/en-GB.i18n.json

@@ -1,435 +0,0 @@
-{
-    "accept": "Accept",
-    "act-activity-notify": "[Wekan] Activity Notification",
-    "act-addAttachment": "attached _ attachment _ to _ card _",
-    "act-addChecklist": "added checklist __checklist__ to __card__",
-    "act-addChecklistItem": "added __checklistItem__ to checklist __checklist__ on __card__",
-    "act-addComment": "commented on __card__: __comment__",
-    "act-createBoard": "created __board__",
-    "act-createCard": "added __card__ to __list__",
-    "act-createList": "added __list__ to __board__",
-    "act-addBoardMember": "added __member__ to __board__",
-    "act-archivedBoard": "archived __board__",
-    "act-archivedCard": "archived __card__",
-    "act-archivedList": "archived __list__",
-    "act-archivedSwimlane": "archived __swimlane__",
-    "act-importBoard": "imported __board__",
-    "act-importCard": "imported __card__",
-    "act-importList": "imported __list__",
-    "act-joinMember": "added __member__ to __card__",
-    "act-moveCard": "moved __card__ from __oldList__ to __list__",
-    "act-removeBoardMember": "removed __member__ from __board__",
-    "act-restoredCard": "restored __card__ to __board__",
-    "act-unjoinMember": "removed __member__ from __card__",
-    "act-withBoardTitle": "[Wekan] __board__",
-    "act-withCardTitle": "[__board__] __card__",
-    "actions": "Actions",
-    "activities": "Activities",
-    "activity": "Activity",
-    "activity-added": "added %s to %s",
-    "activity-archived": "archived %s",
-    "activity-attached": "attached %s to %s",
-    "activity-created": "created %s",
-    "activity-excluded": "excluded %s from %s",
-    "activity-imported": "imported %s into %s from %s",
-    "activity-imported-board": "imported %s from %s",
-    "activity-joined": "joined %s",
-    "activity-moved": "moved %s from %s to %s",
-    "activity-on": "on %s",
-    "activity-removed": "removed %s from %s",
-    "activity-sent": "sent %s to %s",
-    "activity-unjoined": "unjoined %s",
-    "activity-checklist-added": "added checklist to %s",
-    "activity-checklist-item-added": "added checklist item to '%s' in %s",
-    "add": "Add",
-    "add-attachment": "Add Attachment",
-    "add-board": "Add Board",
-    "add-card": "Add Card",
-    "add-swimlane": "Add Swimlane",
-    "add-checklist": "Add Checklist",
-    "add-checklist-item": "Add an item to checklist",
-    "add-cover": "Add Cover",
-    "add-label": "Add Label",
-    "add-list": "Add List",
-    "add-members": "Add Members",
-    "added": "Added",
-    "addMemberPopup-title": "Members",
-    "admin": "Admin",
-    "admin-desc": "Can view and edit cards, remove members, and change settings for the board.",
-    "admin-announcement": "Announcement",
-    "admin-announcement-active": "Active System-Wide Announcement",
-    "admin-announcement-title": "Announcement from Administrator",
-    "all-boards": "All boards",
-    "and-n-other-card": "And __count__ other card",
-    "and-n-other-card_plural": "And __count__ other cards",
-    "apply": "Apply",
-    "app-is-offline": "Wekan is loading, please wait. Refreshing the page will cause data loss. If Wekan does not load, please check that Wekan server has not stopped.",
-    "archive": "Archive",
-    "archive-all": "Archive All",
-    "archive-board": "Archive Board",
-    "archive-card": "Archive Card",
-    "archive-list": "Archive List",
-    "archive-swimlane": "Archive Swimlane",
-    "archive-selection": "Archive selection",
-    "archiveBoardPopup-title": "Archive Board?",
-    "archived-items": "Archived Items",
-    "archived-boards": "Archived Boards",
-    "restore-board": "Restore Board",
-    "no-archived-boards": "No Archived Boards.",
-    "archives": "Archives",
-    "assign-member": "Assign member",
-    "attached": "attached",
-    "attachment": "Attachment",
-    "attachment-delete-pop": "Deleting an attachment is permanent. There is no undo.",
-    "attachmentDeletePopup-title": "Delete Attachment?",
-    "attachments": "Attachments",
-    "auto-watch": "Automatically watch boards when they are created",
-    "avatar-too-big": "The avatar is too large (70KB max)",
-    "back": "Back",
-    "board-change-color": "Change color",
-    "board-nb-stars": "%s stars",
-    "board-not-found": "Board not found",
-    "board-private-info": "This board will be <strong>private</strong>.",
-    "board-public-info": "This board will be <strong>public</strong>.",
-    "boardChangeColorPopup-title": "Change Board Background",
-    "boardChangeTitlePopup-title": "Rename Board",
-    "boardChangeVisibilityPopup-title": "Change Visibility",
-    "boardChangeWatchPopup-title": "Change Watch",
-    "boardMenuPopup-title": "Board Menu",
-    "boards": "Boards",
-    "board-view": "Board View",
-    "board-view-swimlanes": "Swimlanes",
-    "board-view-lists": "Lists",
-    "bucket-example": "Like “Bucket List” for example",
-    "cancel": "Cancel",
-    "card-archived": "This card is archived.",
-    "card-comments-title": "This card has %s comment.",
-    "card-delete-notice": "Deleting is permanent. You will lose all actions associated with this card.",
-    "card-delete-pop": "All actions will be removed from the activity feed and you won't be able to re-open the card. There is no undo.",
-    "card-delete-suggest-archive": "You can archive a card to remove it from the board and preserve the activity.",
-    "card-due": "Due",
-    "card-due-on": "Due on",
-    "card-spent": "Spent Time",
-    "card-edit-attachments": "Edit attachments",
-    "card-edit-labels": "Edit labels",
-    "card-edit-members": "Edit members",
-    "card-labels-title": "Change the labels for the card.",
-    "card-members-title": "Add or remove members of the board from the card.",
-    "card-start": "Start",
-    "card-start-on": "Starts on",
-    "cardAttachmentsPopup-title": "Attach From",
-    "cardDeletePopup-title": "Delete Card?",
-    "cardDetailsActionsPopup-title": "Card Actions",
-    "cardLabelsPopup-title": "Labels",
-    "cardMembersPopup-title": "Members",
-    "cardMorePopup-title": "More",
-    "cards": "Cards",
-    "change": "Change",
-    "change-avatar": "Change Avatar",
-    "change-password": "Change Password",
-    "change-permissions": "Change permissions",
-    "change-settings": "Change Settings",
-    "changeAvatarPopup-title": "Change Avatar",
-    "changeLanguagePopup-title": "Change Language",
-    "changePasswordPopup-title": "Change Password",
-    "changePermissionsPopup-title": "Change Permissions",
-    "changeSettingsPopup-title": "Change Settings",
-    "checklists": "Checklists",
-    "click-to-star": "Click to star this board.",
-    "click-to-unstar": "Click to unstar this board.",
-    "clipboard": "Clipboard or drag & drop",
-    "close": "Close",
-    "close-board": "Close Board",
-    "close-board-pop": "You will be able to restore the board by clicking the “Archives” button from the home header.",
-    "color-black": "black",
-    "color-blue": "blue",
-    "color-green": "green",
-    "color-lime": "lime",
-    "color-orange": "orange",
-    "color-pink": "pink",
-    "color-purple": "purple",
-    "color-red": "red",
-    "color-sky": "sky",
-    "color-yellow": "yellow",
-    "comment": "Comment",
-    "comment-placeholder": "Write Comment",
-    "comment-only": "Comment only",
-    "comment-only-desc": "Can comment on cards only.",
-    "computer": "Computer",
-    "confirm-checklist-delete-dialog": "Are you sure you want to delete checklist",
-    "copy-card-link-to-clipboard": "Copy card link to clipboard",
-    "copyCardPopup-title": "Copy Card",
-    "copyManyCardPopup-title": "Copy Multiple Cards",
-    "create": "Create",
-    "createBoardPopup-title": "Create Board",
-    "chooseBoardSourcePopup-title": "Import board",
-    "createLabelPopup-title": "Create Label",
-    "current": "current",
-    "date": "Date",
-    "decline": "Decline",
-    "default-avatar": "Default avatar",
-    "delete": "Delete",
-    "deleteLabelPopup-title": "Delete Label?",
-    "description": "Description",
-    "disambiguateMultiLabelPopup-title": "Disambiguate Label Action",
-    "disambiguateMultiMemberPopup-title": "Disambiguate Member Action",
-    "discard": "Discard",
-    "done": "Done",
-    "download": "Download",
-    "edit": "Edit",
-    "edit-avatar": "Change Avatar",
-    "edit-profile": "Edit Profile",
-    "edit-wip-limit": "Edit WIP Limit",
-    "soft-wip-limit": "Soft WIP Limit",
-    "editCardStartDatePopup-title": "Change start date",
-    "editCardDueDatePopup-title": "Change due date",
-    "editCardSpentTimePopup-title": "Change spent time",
-    "editLabelPopup-title": "Change Label",
-    "editNotificationPopup-title": "Edit Notification",
-    "editProfilePopup-title": "Edit Profile",
-    "email": "Email",
-    "email-enrollAccount-subject": "An account created for you on __siteName__",
-    "email-enrollAccount-text": "Hello __user__,\n\nTo start using the service, simply click the link below.\n\n__url__\n\nThanks.",
-    "email-fail": "Sending email failed",
-    "email-fail-text": "Error trying to send email",
-    "email-invalid": "Invalid email",
-    "email-invite": "Invite via email",
-    "email-invite-subject": "__inviter__ sent you an invitation",
-    "email-invite-text": "Dear __user__,\n\n__inviter__ invites you to join board \"__board__\" for collaboration.\n\nPlease follow the link below:\n\n__url__\n\nThanks.",
-    "email-resetPassword-subject": "Reset your password on __siteName__",
-    "email-resetPassword-text": "Hello __user__,\n\nTo reset your password, simply click the link below.\n\n__url__\n\nThanks.",
-    "email-sent": "Email sent",
-    "email-verifyEmail-subject": "Verify your email address on __siteName__",
-    "email-verifyEmail-text": "Hello __user__,\n\nTo verify your account email, simply click the link below.\n\n__url__\n\nThanks.",
-    "enable-wip-limit": "Enable WIP Limit",
-    "error-board-doesNotExist": "This board does not exist",
-    "error-board-notAdmin": "You need to be admin of this board to do that",
-    "error-board-notAMember": "You need to be a member of this board to do that",
-    "error-json-malformed": "Your text is not valid JSON",
-    "error-json-schema": "Your JSON data does not include the proper information in the correct format",
-    "error-list-doesNotExist": "This list does not exist",
-    "error-user-doesNotExist": "This user does not exist",
-    "error-user-notAllowSelf": "You can not invite yourself",
-    "error-user-notCreated": "This user is not created",
-    "error-username-taken": "This username is already taken",
-    "error-email-taken": "Email has already been taken",
-    "export-board": "Export board",
-    "filter": "Filter",
-    "filter-cards": "Filter Cards",
-    "filter-clear": "Clear filter",
-    "filter-no-label": "No label",
-    "filter-no-member": "No member",
-    "filter-on": "Filter is on",
-    "filter-on-desc": "You are filtering cards on this board. Click here to edit filter.",
-    "filter-to-selection": "Filter to selection",
-    "fullname": "Full Name",
-    "header-logo-title": "Go back to your boards page.",
-    "hide-system-messages": "Hide system messages",
-    "headerBarCreateBoardPopup-title": "Create Board",
-    "home": "Home",
-    "import": "Import",
-    "import-board": "import board",
-    "import-board-c": "Import board",
-    "import-board-title-trello": "Import board from Trello",
-    "import-board-title-wekan": "Import board from Wekan",
-    "import-sandstorm-warning": "Imported board will delete all existing data on board and replace it with imported board.",
-    "from-trello": "From Trello",
-    "from-wekan": "From Wekan",
-    "import-board-instruction-trello": "In your Trello board, go to 'Menu', then 'More', 'Print and Export', 'Export JSON', and copy the resulting text.",
-    "import-board-instruction-wekan": "In your Wekan board, go to 'Menu', then 'Export board', and copy the text in the downloaded file.",
-    "import-json-placeholder": "Paste your valid JSON data here",
-    "import-map-members": "Map members",
-    "import-members-map": "Your imported board has some members. Please map the members you want to import to Wekan users",
-    "import-show-user-mapping": "Review members mapping",
-    "import-user-select": "Pick the Wekan user you want to use as this member",
-    "importMapMembersAddPopup-title": "Select Wekan member",
-    "info": "Version",
-    "initials": "Initials",
-    "invalid-date": "Invalid date",
-    "invalid-time": "Invalid time",
-    "invalid-user": "Invalid user",
-    "joined": "joined",
-    "just-invited": "You are just invited to this board",
-    "keyboard-shortcuts": "Keyboard shortcuts",
-    "label-create": "Create Label",
-    "label-default": "%s label (default)",
-    "label-delete-pop": "There is no undo. This will remove this label from all cards and destroy its history.",
-    "labels": "Labels",
-    "language": "Language",
-    "last-admin-desc": "You can’t change roles because there must be at least one admin.",
-    "leave-board": "Leave Board",
-    "leave-board-pop": "Are you sure you want to leave __boardTitle__? You will be removed from all cards on this board.",
-    "leaveBoardPopup-title": "Leave Board ?",
-    "link-card": "Link to this card",
-    "list-archive-cards": "Archive all cards in this list",
-    "list-archive-cards-pop": "This will remove all the cards in this list from the board. To view archived cards and bring them back to the board, click “Menu” > “Archived Items”.",
-    "list-move-cards": "Move all cards in this list",
-    "list-select-cards": "Select all cards in this list",
-    "listActionPopup-title": "List Actions",
-    "swimlaneActionPopup-title": "Swimlane Actions",
-    "listImportCardPopup-title": "Import a Trello card",
-    "listMorePopup-title": "More",
-    "link-list": "Link to this list",
-    "list-delete-pop": "All actions will be removed from the activity feed and you won't be able to recover the list. There is no undo.",
-    "list-delete-suggest-archive": "You can archive a list to remove it from the board and preserve the activity.",
-    "lists": "Lists",
-    "swimlanes": "Swimlanes",
-    "log-out": "Log Out",
-    "log-in": "Log In",
-    "loginPopup-title": "Log In",
-    "memberMenuPopup-title": "Member Settings",
-    "members": "Members",
-    "menu": "Menu",
-    "move-selection": "Move selection",
-    "moveCardPopup-title": "Move Card",
-    "moveCardToBottom-title": "Move to Bottom",
-    "moveCardToTop-title": "Move to Top",
-    "moveSelectionPopup-title": "Move selection",
-    "multi-selection": "Multi-Selection",
-    "multi-selection-on": "Multi-Selection is on",
-    "muted": "Muted",
-    "muted-info": "You will never be notified of any changes in this board",
-    "my-boards": "My Boards",
-    "name": "Name",
-    "no-archived-cards": "No archived cards.",
-    "no-archived-lists": "No archived lists.",
-    "no-archived-swimlanes": "No archived swimlanes.",
-    "no-results": "No results",
-    "normal": "Normal",
-    "normal-desc": "Can view and edit cards. Can't change settings.",
-    "not-accepted-yet": "Invitation not accepted yet",
-    "notify-participate": "Receive updates to any cards you participate as creater or member",
-    "notify-watch": "Receive updates to any boards, lists, or cards you’re watching",
-    "optional": "optional",
-    "or": "or",
-    "page-maybe-private": "This page may be private. You may be able to view it by <a href='%s'>logging in</a>.",
-    "page-not-found": "Page not found.",
-    "password": "Password",
-    "paste-or-dragdrop": "to paste, or drag & drop image file to it (image only)",
-    "participating": "Participating",
-    "preview": "Preview",
-    "previewAttachedImagePopup-title": "Preview",
-    "previewClipboardImagePopup-title": "Preview",
-    "private": "Private",
-    "private-desc": "This board is private. Only people added to the board can view and edit it.",
-    "profile": "Profile",
-    "public": "Public",
-    "public-desc": "This board is public. It's visible to anyone with the link and will show up in search engines like Google. Only people added to the board can edit.",
-    "quick-access-description": "Star a board to add a shortcut in this bar.",
-    "remove-cover": "Remove Cover",
-    "remove-from-board": "Remove from Board",
-    "remove-label": "Remove Label",
-    "listDeletePopup-title": "Delete List ?",
-    "remove-member": "Remove Member",
-    "remove-member-from-card": "Remove from Card",
-    "remove-member-pop": "Remove __name__ (__username__) from __boardTitle__? The member will be removed from all cards on this board. They will receive a notification.",
-    "removeMemberPopup-title": "Remove Member?",
-    "rename": "Rename",
-    "rename-board": "Rename Board",
-    "restore": "Restore",
-    "save": "Save",
-    "search": "Search",
-    "select-color": "Select Color",
-    "set-wip-limit-value": "Set a limit for the maximum number of tasks in this list",
-    "setWipLimitPopup-title": "Set WIP Limit",
-    "shortcut-assign-self": "Assign yourself to current card",
-    "shortcut-autocomplete-emoji": "Autocomplete emoji",
-    "shortcut-autocomplete-members": "Autocomplete members",
-    "shortcut-clear-filters": "Clear all filters",
-    "shortcut-close-dialog": "Close Dialog",
-    "shortcut-filter-my-cards": "Filter my cards",
-    "shortcut-show-shortcuts": "Bring up this shortcuts list",
-    "shortcut-toggle-filterbar": "Toggle Filter Sidebar",
-    "shortcut-toggle-sidebar": "Toggle Board Sidebar",
-    "show-cards-minimum-count": "Show cards count if list contains more than",
-    "sidebar-open": "Open Sidebar",
-    "sidebar-close": "Close Sidebar",
-    "signupPopup-title": "Create an Account",
-    "star-board-title": "Click to star this board. It will show up at top of your boards list.",
-    "starred-boards": "Starred Boards",
-    "starred-boards-description": "Starred boards show up at the top of your boards list.",
-    "subscribe": "Subscribe",
-    "team": "Team",
-    "this-board": "this board",
-    "this-card": "this card",
-    "spent-time-hours": "Spent time (hours)",
-    "overtime-hours": "Overtime (hours)",
-    "overtime": "Overtime",
-    "has-overtime-cards": "Has overtime cards",
-    "has-spenttime-cards": "Has spent time cards",
-    "time": "Time",
-    "title": "Title",
-    "tracking": "Tracking",
-    "tracking-info": "You will be notified of any changes to those cards you are involved as creator or member.",
-    "unassign-member": "Unassign member",
-    "unsaved-description": "You have an unsaved description.",
-    "unwatch": "Unwatch",
-    "upload": "Upload",
-    "upload-avatar": "Upload an avatar",
-    "uploaded-avatar": "Uploaded an avatar",
-    "username": "Username",
-    "view-it": "View it",
-    "warn-list-archived": "warning: this card is in an archived list",
-    "watch": "Watch",
-    "watching": "Watching",
-    "watching-info": "You will be notified of any changes in this board",
-    "welcome-board": "Welcome Board",
-    "welcome-swimlane": "Milestone 1",
-    "welcome-list1": "Basics",
-    "welcome-list2": "Advanced",
-    "what-to-do": "What do you want to do?",
-    "wipLimitErrorPopup-title": "Invalid WIP Limit",
-    "wipLimitErrorPopup-dialog-pt1": "The number of tasks in this list is higher than the WIP limit you've defined.",
-    "wipLimitErrorPopup-dialog-pt2": "Please move some tasks out of this list, or set a higher WIP limit.",
-    "admin-panel": "Admin Panel",
-    "settings": "Settings",
-    "people": "People",
-    "registration": "Registration",
-    "disable-self-registration": "Disable Self-Registration",
-    "invite": "Invite",
-    "invite-people": "Invite People",
-    "to-boards": "To board(s)",
-    "email-addresses": "Email Addresses",
-    "smtp-host-description": "The address of the SMTP server that handles your emails.",
-    "smtp-port-description": "The port your SMTP server uses for outgoing emails.",
-    "smtp-tls-description": "Enable TLS support for SMTP server",
-    "smtp-host": "SMTP Host",
-    "smtp-port": "SMTP Port",
-    "smtp-username": "Username",
-    "smtp-password": "Password",
-    "smtp-tls": "TLS support",
-    "send-from": "From",
-    "send-smtp-test": "Send a test email to yourself",
-    "invitation-code": "Invitation Code",
-    "email-invite-register-subject": "__inviter__ sent you an invitation",
-    "email-invite-register-text": "Dear __user__,\n\n__inviter__ invites you to Wekan for collaboration.\n\nPlease follow the link below:\n__url__\n\nAnd your invitation code is: __icode__\n\nThanks.",
-    "email-smtp-test-subject": "SMTP Test Email From Wekan",
-    "email-smtp-test-text": "You have successfully sent an email",
-    "error-invitation-code-not-exist": "Invitation code doesn't exist",
-    "error-notAuthorized": "You are not authorised to view this page.",
-    "outgoing-webhooks": "Outgoing Webhooks",
-    "outgoingWebhooksPopup-title": "Outgoing Webhooks",
-    "new-outgoing-webhook": "New Outgoing Webhook",
-    "no-name": "(Unknown)",
-    "Wekan_version": "Wekan version",
-    "Node_version": "Node version",
-    "OS_Arch": "OS Arch",
-    "OS_Cpus": "OS CPU Count",
-    "OS_Freemem": "OS Free Memory",
-    "OS_Loadavg": "OS Load Average",
-    "OS_Platform": "OS Platform",
-    "OS_Release": "OS Release",
-    "OS_Totalmem": "OS Total Memory",
-    "OS_Type": "OS Type",
-    "OS_Uptime": "OS Uptime",
-    "hours": "hours",
-    "minutes": "minutes",
-    "seconds": "seconds",
-    "yes": "Yes",
-    "no": "No",
-    "accounts": "Accounts",
-    "accounts-allowEmailChange": "Allow Email Change",
-    "createdAt": "Created at",
-    "verified": "Verified",
-    "active": "Active"
-}