You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@zeppelin.apache.org by pr...@apache.org on 2017/03/07 07:52:20 UTC

zeppelin git commit: [ZEPPELIN-2148] On creation of Bar graph zeppelin UI shows it as minigraph - 2

Repository: zeppelin
Updated Branches:
  refs/heads/master ebd5e1e9b -> 89386342f


[ZEPPELIN-2148] On creation of Bar graph zeppelin UI shows it as minigraph - 2

### What is this PR for?
This is based on https://github.com/apache/zeppelin/pull/2074#issuecomment-283843330.

In this I've reverted #47a106a and applied, that.

### What type of PR is it?
[Bug Fix]

### What is the Jira issue?
* Open an issue on Jira https://issues.apache.org/jira/browse/ZEPPELIN/
* Put link here, and add [ZEPPELIN-*Jira number*] in PR title, eg. [ZEPPELIN-533]

### What is the Jira issue?
* [ZEPPELIN-2148](https://issues.apache.org/jira/browse/ZEPPELIN-2148)

### How should this be tested?
Check screen shot.

### Screenshots (if appropriate)
Before:
![zeppelin-2148-before](https://cloud.githubusercontent.com/assets/674497/23291765/b1469780-fa80-11e6-9a13-3ecb6ca275ba.gif)

After:
![zeppelin-2148-after](https://cloud.githubusercontent.com/assets/674497/23291751/9aa39122-fa80-11e6-962e-482e12c4bca5.gif)

### Questions:
* Does the licenses files need update?
* Is there breaking changes for older versions?
* Does this needs documentation?

Author: Prabhjyot Singh <pr...@gmail.com>

Closes #2092 from prabhjyotsingh/ZEPPELIN-2148-2 and squashes the following commits:

bdd0b26 [Prabhjyot Singh] apply https://github.com/apache/zeppelin/pull/2074
5062c0b [Prabhjyot Singh] ZEPPELIN-2148: On creation of Bar graph zeppelin UI shows it as mini graph


Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo
Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/89386342
Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/89386342
Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/89386342

Branch: refs/heads/master
Commit: 89386342fdf0c94fc5f12da1a6320b97e89610af
Parents: ebd5e1e
Author: Prabhjyot Singh <pr...@gmail.com>
Authored: Fri Mar 3 11:36:44 2017 +0530
Committer: Prabhjyot Singh <pr...@gmail.com>
Committed: Tue Mar 7 13:22:15 2017 +0530

----------------------------------------------------------------------
 .../src/app/notebook/paragraph/result/result.controller.js     | 4 +---
 zeppelin-web/src/app/notebook/paragraph/result/result.html     | 6 +++---
 2 files changed, 4 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zeppelin/blob/89386342/zeppelin-web/src/app/notebook/paragraph/result/result.controller.js
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/app/notebook/paragraph/result/result.controller.js b/zeppelin-web/src/app/notebook/paragraph/result/result.controller.js
index 374f0d8..d3a81d4 100644
--- a/zeppelin-web/src/app/notebook/paragraph/result/result.controller.js
+++ b/zeppelin-web/src/app/notebook/paragraph/result/result.controller.js
@@ -267,9 +267,7 @@ function ResultCtrl($scope, $rootScope, $route, $window, $routeParams, $location
 
   $scope.renderDefaultDisplay = function(targetElemId, type, data, refresh) {
     if (type === DefaultDisplayType.TABLE) {
-      $timeout(function() {
-        $scope.renderGraph(targetElemId, $scope.graphMode, refresh);
-      }, 10);
+      $scope.renderGraph(targetElemId, $scope.graphMode, refresh);
     } else if (type === DefaultDisplayType.HTML) {
       renderHtml(targetElemId, data);
     } else if (type === DefaultDisplayType.ANGULAR) {

http://git-wip-us.apache.org/repos/asf/zeppelin/blob/89386342/zeppelin-web/src/app/notebook/paragraph/result/result.html
----------------------------------------------------------------------
diff --git a/zeppelin-web/src/app/notebook/paragraph/result/result.html b/zeppelin-web/src/app/notebook/paragraph/result/result.html
index 5b251e5..5a05eb7 100644
--- a/zeppelin-web/src/app/notebook/paragraph/result/result.html
+++ b/zeppelin-web/src/app/notebook/paragraph/result/result.html
@@ -28,10 +28,10 @@ limitations under the License.
                     && config.graph.optionOpen && !asIframe && !viewOnly">
         <div ng-repeat="viz in builtInTableDataVisualizationList track by $index"
              id="trsetting{{id}}_{{viz.id}}"
-             ng-show="graphMode == viz.id"></div>
+             ng-if="graphMode == viz.id"></div>
         <div ng-repeat="viz in builtInTableDataVisualizationList track by $index"
              id="vizsetting{{id}}_{{viz.id}}"
-             ng-show="graphMode == viz.id"></div>
+             ng-if="graphMode == viz.id"></div>
       </div>
 
       <!-- graph -->
@@ -40,7 +40,7 @@ limitations under the License.
            ng-class="{'noOverflow': graphMode=='table'}">
         <div ng-repeat="viz in builtInTableDataVisualizationList track by $index"
              id="p{{id}}_{{viz.id}}"
-             ng-show="graphMode == viz.id">
+             ng-if="graphMode == viz.id">
         </div>
       </div>