Commit 6ec94374 by Shwetha GS

ATLAS-388 UI : On creating Tag, the page to be reset for creating new Tag (Anilg via shwethags)

parent 6c06fd0a
...@@ -375,4 +375,8 @@ Tags on Home Page design ...@@ -375,4 +375,8 @@ Tags on Home Page design
.graph{ .graph{
overflow: hidden!important; overflow: hidden!important;
}
.notifier{
margin-right: 15px;
margin-left: -15px;
} }
\ No newline at end of file
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
--> -->
<div class="container" data-ng-controller="NotificationController"> <div class="container" data-ng-controller="NotificationController">
<alert data-ng-repeat="notification in getNotifications()" data-type="{{notification.type}}" data-close="close(notification)"> <alert data-ng-repeat="notification in getNotifications()" data-type="{{notification.type}}" data-close="close(notification)" class="notifier">
{{notification.message}} {{notification.message}}
</alert> </alert>
</div> </div>
...@@ -27,9 +27,9 @@ angular.module('dgc.tags.definition').controller('DefinitionTagsController', ['$ ...@@ -27,9 +27,9 @@ angular.module('dgc.tags.definition').controller('DefinitionTagsController', ['$
attributeDefinitions: [] attributeDefinitions: []
}; };
$scope.typesList = NavigationResource.get(); $scope.typesList = NavigationResource.get();
$scope.newtagModel = angular.copy($scope.tagModel);
$scope.addAttribute = function AddAttribute() { $scope.addAttribute = function AddAttribute() {
$scope.tagModel.attributeDefinitions.push(AttributeDefinition.getModel()); $scope.tagModel.attributeDefinitions.push(AttributeDefinition.getModel());
}; };
$scope.removeAttribute = function(index) { $scope.removeAttribute = function(index) {
...@@ -40,6 +40,11 @@ angular.module('dgc.tags.definition').controller('DefinitionTagsController', ['$ ...@@ -40,6 +40,11 @@ angular.module('dgc.tags.definition').controller('DefinitionTagsController', ['$
$scope.categoryInst = Categories[$scope.category].clearTags(); $scope.categoryInst = Categories[$scope.category].clearTags();
}; };
$scope.reset = function(){
$scope.tagModel = angular.copy($scope.newtagModel);
$scope.selectedParent = undefined;
};
$scope.refreshTags = function(){ $scope.refreshTags = function(){
var httpDefaultCache = $cacheFactory.get('$http'); var httpDefaultCache = $cacheFactory.get('$http');
httpDefaultCache.remove('/api/atlas/types?type=TRAIT'); httpDefaultCache.remove('/api/atlas/types?type=TRAIT');
...@@ -61,6 +66,8 @@ angular.module('dgc.tags.definition').controller('DefinitionTagsController', ['$ ...@@ -61,6 +66,8 @@ angular.module('dgc.tags.definition').controller('DefinitionTagsController', ['$
NotificationService.info('"' + $scope.tagModel.typeName + '" has been created', false); NotificationService.info('"' + $scope.tagModel.typeName + '" has been created', false);
var httpDefaultCache = $cacheFactory.get('$http'); var httpDefaultCache = $cacheFactory.get('$http');
httpDefaultCache.remove('/api/atlas/types?type=TRAIT'); httpDefaultCache.remove('/api/atlas/types?type=TRAIT');
$scope.typesList = NavigationResource.get();
$scope.reset();
}).catch(function TagCreateFailed(error) { }).catch(function TagCreateFailed(error) {
NotificationService.error(error.data.error, false); NotificationService.error(error.data.error, false);
}).finally(function() { }).finally(function() {
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
</select> </select>
</div> </div>
</div> </div>
<div class="form-group" data-ng-class="{'has-error': tagForm.typeName.$invalid && tagForm.typeName.$dirty}"> <div class="form-group" >
<label for="typeName" class="col-sm-2 control-label">Tag Name</label> <label for="typeName" class="col-sm-2 control-label">Tag Name</label>
<div class="col-sm-10"> <div class="col-sm-10">
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
</div> </div>
</div> </div>
<ng-form name="attributeForm"> <ng-form name="attributeForm">
<div class="form-group" data-ng-class="{'has-error': attributeForm.name.$invalid && attributeForm.name.$dirty}" <div class="form-group"
data-ng-repeat-start="attribute in tagModel.attributeDefinitions"> data-ng-repeat-start="attribute in tagModel.attributeDefinitions">
<label for="attributeId_{{$index}}" class="col-sm-2 control-label">Attribute name</label> <label for="attributeId_{{$index}}" class="col-sm-2 control-label">Attribute name</label>
......
...@@ -7,6 +7,7 @@ ATLAS-409 Atlas will not import avro tables with schema read from a file (dosset ...@@ -7,6 +7,7 @@ ATLAS-409 Atlas will not import avro tables with schema read from a file (dosset
ATLAS-379 Create sqoop and falcon metadata addons (venkatnrangan,bvellanki,sowmyaramesh via shwethags) ATLAS-379 Create sqoop and falcon metadata addons (venkatnrangan,bvellanki,sowmyaramesh via shwethags)
ALL CHANGES: ALL CHANGES:
ATLAS-388 UI : On creating Tag, the page to be reset for creating new Tag (Anilg via shwethags)
ATLAS-199 webapp build fails (grunt + tests) (sanjayp via shwethags) ATLAS-199 webapp build fails (grunt + tests) (sanjayp via shwethags)
ATLAS-415 Hive import fails when importing a table that is already imported without StorageDescriptor information (yhemanth via shwethags) ATLAS-415 Hive import fails when importing a table that is already imported without StorageDescriptor information (yhemanth via shwethags)
ATLAS-450 quick_start fails on cygwin (dkantor via shwethags) ATLAS-450 quick_start fails on cygwin (dkantor via shwethags)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment