Repository: zeppelin Updated Branches: refs/heads/branch-0.7 20cb030fc -> 17fa705a0
[ZEPPELIN-2091] Disable add/remove operations in the window of Link this paragraph ### What is this PR for? When a paragraph is added or deleted from a note, the window which is created by `Link this paragraph` does unnecessary work. ### What type of PR is it? [Bug Fix] ### What is the Jira issue? * [ZEPPELIN-2091](https://issues.apache.org/jira/browse/ZEPPELIN-2091) ### How should this be tested? Here is the test way. 1. click "Link this paragraph" of a paragraph menu. 2. click `Insert New` or `remove`. 3. check the window made by "Link this paragraph". ### Screenshots (if appropriate) [ Before ] * When clicking `Insert New` in a paragraph menu, it appears new paragraph in the window of `Link this paragraph`.  * When click `remove` in a paragraph menu, the window of `Link this paragraph` appears empty screen.  [ After ] * It doesn't work in the window of 'Link this paragraph`  * _Note that text and title shape of the paragraph in window is covering https://github.com/apache/zeppelin/pull/1983._ ### Questions: * Does the licenses files need update? No * Is there breaking changes for older versions? No * Does this needs documentation? No Author: soralee <sora0...@zepl.com> Closes #2013 from soralee/ZEPPELIN-2091_fix_link_paragraph and squashes the following commits: 9e8ff41 [soralee] disable add/remove function in Link this paragraph window (cherry picked from commit 0548a796f554c54caac1e80fe424582267122c2b) Signed-off-by: Lee moon soo <m...@apache.org> Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/17fa705a Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/17fa705a Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/17fa705a Branch: refs/heads/branch-0.7 Commit: 17fa705a03af4b4db28392dd3db7e1f12ee45782 Parents: 20cb030 Author: soralee <sora0...@zepl.com> Authored: Mon Feb 13 16:17:44 2017 +0900 Committer: Lee moon soo <m...@apache.org> Committed: Tue Feb 21 09:24:32 2017 +0900 ---------------------------------------------------------------------- zeppelin-web/src/app/notebook/notebook.controller.js | 6 ++++++ 1 file changed, 6 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/zeppelin/blob/17fa705a/zeppelin-web/src/app/notebook/notebook.controller.js ---------------------------------------------------------------------- diff --git a/zeppelin-web/src/app/notebook/notebook.controller.js b/zeppelin-web/src/app/notebook/notebook.controller.js index ccf64b7..274ddd0 100644 --- a/zeppelin-web/src/app/notebook/notebook.controller.js +++ b/zeppelin-web/src/app/notebook/notebook.controller.js @@ -496,10 +496,16 @@ function NotebookCtrl($scope, $route, $routeParams, $location, $rootScope, }; $scope.$on('addParagraph', function(event, paragraph, index) { + if ($scope.paragraphUrl) { + return; + } addPara(paragraph, index); }); $scope.$on('removeParagraph', function(event, paragraphId) { + if ($scope.paragraphUrl) { + return; + } removePara(paragraphId); });