ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pallav...@apache.org
Subject ambari git commit: AMBARI-20497. Hive View2.0: Upload table fails, if one column is deleted (pallavkul)
Date Mon, 20 Mar 2017 20:23:58 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.5 fcf9536b5 -> a0e90f250


AMBARI-20497. Hive View2.0: Upload table fails, if one column is deleted (pallavkul)


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

Branch: refs/heads/branch-2.5
Commit: a0e90f250dc45f0e45f4fcc1288db0e833b88361
Parents: fcf9536
Author: pallavkul <pallav.kul@gmail.com>
Authored: Tue Mar 21 01:51:42 2017 +0530
Committer: pallavkul <pallav.kul@gmail.com>
Committed: Tue Mar 21 01:53:26 2017 +0530

----------------------------------------------------------------------
 .../ui/app/routes/databases/database/tables/upload-table.js        | 1 +
 .../src/main/resources/ui/app/templates/components/column-item.hbs | 2 +-
 .../main/resources/ui/app/templates/components/create-table.hbs    | 2 +-
 .../main/resources/ui/app/templates/components/table-columns.hbs   | 1 +
 .../main/resources/ui/app/templates/components/upload-table.hbs    | 2 +-
 .../ui/app/templates/databases/database/tables/upload-table.hbs    | 2 +-
 6 files changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/a0e90f25/contrib/views/hive20/src/main/resources/ui/app/routes/databases/database/tables/upload-table.js
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/src/main/resources/ui/app/routes/databases/database/tables/upload-table.js
b/contrib/views/hive20/src/main/resources/ui/app/routes/databases/database/tables/upload-table.js
index e6b71fe..bfd603b 100644
--- a/contrib/views/hive20/src/main/resources/ui/app/routes/databases/database/tables/upload-table.js
+++ b/contrib/views/hive20/src/main/resources/ui/app/routes/databases/database/tables/upload-table.js
@@ -38,6 +38,7 @@ export default NewTable.extend(UILoggerMixin, {
   setupController(controller, model) {
     this._super(controller, model);
     this.controller.set("showUploadTableModal", false);
+    this.controller.set("options", { 'isDeleteColumnDisabled' : true});
   },
   getCharOptionByCharCode: function(charCode){
     return Helpers.getAllTerminationCharacters().findBy("id", charCode + "");

http://git-wip-us.apache.org/repos/asf/ambari/blob/a0e90f25/contrib/views/hive20/src/main/resources/ui/app/templates/components/column-item.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/src/main/resources/ui/app/templates/components/column-item.hbs
b/contrib/views/hive20/src/main/resources/ui/app/templates/components/column-item.hbs
index 762c77c..6874781 100644
--- a/contrib/views/hive20/src/main/resources/ui/app/templates/components/column-item.hbs
+++ b/contrib/views/hive20/src/main/resources/ui/app/templates/components/column-item.hbs
@@ -118,7 +118,7 @@
       {{#unless column.editing}}
         <button class="btn btn-success" {{action "edit"}}>{{fa-icon "check"}} Edit</button>
       {{/unless}}
-      <button class="btn btn-danger" {{action "delete"}}>{{fa-icon "times"}} Delete</button>
+      <button class="btn btn-danger" {{action "delete"}} disabled={{options.isDeleteColumnDisabled}}
>{{fa-icon "times"}} Delete</button>
     {{/if}}
 
   </div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/a0e90f25/contrib/views/hive20/src/main/resources/ui/app/templates/components/create-table.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/src/main/resources/ui/app/templates/components/create-table.hbs
b/contrib/views/hive20/src/main/resources/ui/app/templates/components/create-table.hbs
index f369783..2ffbd2a 100644
--- a/contrib/views/hive20/src/main/resources/ui/app/templates/components/create-table.hbs
+++ b/contrib/views/hive20/src/main/resources/ui/app/templates/components/create-table.hbs
@@ -44,7 +44,7 @@
               {{emptyColumnsErrorText}}
             </div>
           {{/if}}
-          {{table-columns columns=columns shouldAddBuckets=shouldAddBuckets}}
+          {{table-columns columns=columns shouldAddBuckets=shouldAddBuckets options=options}}
         {{/if}}
         {{#if (eq tab.link "create.table.properties")}}
           {{table-properties properties=properties}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/a0e90f25/contrib/views/hive20/src/main/resources/ui/app/templates/components/table-columns.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/src/main/resources/ui/app/templates/components/table-columns.hbs
b/contrib/views/hive20/src/main/resources/ui/app/templates/components/table-columns.hbs
index b942136..969308a 100644
--- a/contrib/views/hive20/src/main/resources/ui/app/templates/components/table-columns.hbs
+++ b/contrib/views/hive20/src/main/resources/ui/app/templates/components/table-columns.hbs
@@ -32,6 +32,7 @@
                   columnDeleted="columnDeleted"
                   columnUpdated="columnUpdated"
                   editMode=editMode
+                  options=options
     }}
   {{/each}}
   <tr class="new-settings text-center">

http://git-wip-us.apache.org/repos/asf/ambari/blob/a0e90f25/contrib/views/hive20/src/main/resources/ui/app/templates/components/upload-table.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/src/main/resources/ui/app/templates/components/upload-table.hbs
b/contrib/views/hive20/src/main/resources/ui/app/templates/components/upload-table.hbs
index 0ee6b81..7483d65 100644
--- a/contrib/views/hive20/src/main/resources/ui/app/templates/components/upload-table.hbs
+++ b/contrib/views/hive20/src/main/resources/ui/app/templates/components/upload-table.hbs
@@ -54,7 +54,7 @@
   <div class="table-body">
     {{create-table tabs=tabs
     cancel="cancel"
-    create="createAndUpload" columns=columns tableName=tableName }}
+    create="createAndUpload" columns=columns tableName=tableName options=options}}
   </div>
 </div>
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/a0e90f25/contrib/views/hive20/src/main/resources/ui/app/templates/databases/database/tables/upload-table.hbs
----------------------------------------------------------------------
diff --git a/contrib/views/hive20/src/main/resources/ui/app/templates/databases/database/tables/upload-table.hbs
b/contrib/views/hive20/src/main/resources/ui/app/templates/databases/database/tables/upload-table.hbs
index 0091ede..557d9c6 100644
--- a/contrib/views/hive20/src/main/resources/ui/app/templates/databases/database/tables/upload-table.hbs
+++ b/contrib/views/hive20/src/main/resources/ui/app/templates/databases/database/tables/upload-table.hbs
@@ -40,6 +40,6 @@ container-class="modal-dialog modal-sm"}}
 {{/if}}
 </div>
 
-{{upload-table tabs=tabs columns=columns rows=rows tableName=tableName tableMeta=tableMeta
cancel="cancel" createAndUpload="uploadTable" preview="preview"}}
+{{upload-table tabs=tabs columns=columns rows=rows tableName=tableName tableMeta=tableMeta
cancel="cancel" createAndUpload="uploadTable" preview="preview" options=options}}
 </div>
 {{yield}}


Mime
View raw message