소스 검색

[core] Add the document copy action to the right click context menu in the left assist panel

This adds the "copy" action to the context menu for documents listed in the left assist panel.
Johan Åhlén 1 년 전
부모
커밋
d742b42c8f
1개의 변경된 파일5개의 추가작업 그리고 2개의 파일을 삭제
  1. 5 2
      desktop/core/src/desktop/js/ko/components/assist/ko.assistDocumentsPanel.js

+ 5 - 2
desktop/core/src/desktop/js/ko/components/assist/ko.assistDocumentsPanel.js

@@ -42,10 +42,13 @@ const TEMPLATE = `
       'Show details'
     )}</a></li>
     <li><a href="javascript: void(0);" data-bind="click: open"><i class="fa fa-fw fa-edit"></i> ${I18n(
-      'Open document'
+      'Open'
+    )}</a></li>
+    <li><a href="javascript: void(0);" data-bind="click: function() { $data.selected(true); $data.parent.copy() }"><i class="fa fa-fw fa-files-o"></i> ${I18n(
+  'Copy'
     )}</a></li>
     <li><a href="javascript: void(0);" data-bind="click: function() { $data.selected(true); huePubSub.publish('doc.show.delete.modal', $data.parent); }"><i class="fa fa-fw fa-trash-o"></i> ${I18n(
-      'Delete document'
+      'Delete'
     )}</a></li>
     <!-- /ko -->
     <!-- ko if: $containerContext.sharingEnabled -->