AMBARI-20314. Revert AMBARI-20227 as it is causing wokflow id to be not shown 
after submission (Venkat Ranganathan via smohanty)


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

Branch: refs/heads/branch-dev-logsearch
Commit: 0bbd5455aa61eadd5f9ec7dbfee3a6ae79ed2953
Parents: df3b028
Author: Sumit Mohanty <[email protected]>
Authored: Sun Mar 5 13:38:24 2017 -0800
Committer: Sumit Mohanty <[email protected]>
Committed: Sun Mar 5 13:38:24 2017 -0800

----------------------------------------------------------------------
 .../resources/ui/app/components/bundle-config.js   | 17 -----------------
 .../resources/ui/app/components/coord-config.js    | 17 -----------------
 .../resources/ui/app/components/flow-designer.js   | 13 -------------
 .../main/resources/ui/app/components/job-config.js |  2 --
 .../main/resources/ui/app/components/save-wf.js    |  2 --
 .../ui/app/templates/components/bundle-config.hbs  | 11 ++---------
 .../ui/app/templates/components/coord-config.hbs   | 11 ++---------
 .../ui/app/templates/components/flow-designer.hbs  | 15 ++++-----------
 8 files changed, 8 insertions(+), 80 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/components/bundle-config.js
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/bundle-config.js 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/bundle-config.js
index 59ffbb8..e94d51a 100644
--- 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/bundle-config.js
+++ 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/bundle-config.js
@@ -146,7 +146,6 @@ export default Ember.Component.extend(Ember.Evented, 
Validations, {
   importBundle (filePath){
     this.set("bundleFilePath", filePath);
     this.set("isImporting", true);
-    this.hideSuccessMsg();
     filePath = this.appendFileName(filePath, 'bundle');
     var deferred = this.getBundleFromHdfs(filePath);
     deferred.promise.then(function(response){
@@ -250,22 +249,7 @@ export default Ember.Component.extend(Ember.Evented, 
Validations, {
       return filePath;
     }
   },
-  hideSuccessMsg(){
-    this.set('successMessage', '');
-    this.set('isWFSaveSuccess', false);
-  },
   actions : {
-    showSuccessMessage(msg, isHideSuccessMsg) {
-      if(isHideSuccessMsg){
-        this.set("isWFSaveSuccess", false);
-      } else {
-        this.set("isWFSaveSuccess", true);
-      }
-      Ember.run.later(()=>{
-      this.$('#successMsg').fadeOut();
-      }, 3000);
-      this.set("successMessage", msg);
-    },
     closeFileBrowser(){
       this.set("showingFileBrowser", false);
       this.get('fileBrowser').getContext().trigger('fileSelected', 
this.get('filePath'));
@@ -324,7 +308,6 @@ export default Ember.Component.extend(Ember.Evented, 
Validations, {
       this.set('showingResetConfirmation', true);
     },
     resetBundle(){
-      this.hideSuccessMsg();
       this.get('errors').clear();
       this.set('showingResetConfirmation', false);
       if(this.get('bundleFilePath')){

http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/components/coord-config.js
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/coord-config.js 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/coord-config.js
index 2d0a23c..c87ea99 100644
--- 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/coord-config.js
+++ 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/coord-config.js
@@ -262,7 +262,6 @@ export default Ember.Component.extend(Validations, 
Ember.Evented, {
     return deferred;
   },
   importCoordinator (filePath){
-    this.hideSuccessMsg();
     filePath = this.appendFileName(filePath, 'coord');
     this.set("coordinatorFilePath", filePath);
     this.set("isImporting", false);
@@ -368,22 +367,7 @@ export default Ember.Component.extend(Validations, 
Ember.Evented, {
     }.bind(this));
     return isChildComponentsValid;
   },
-  hideSuccessMsg(){
-    this.set('successMessage', '');
-    this.set('isWFSaveSuccess', false);
-  },
   actions : {
-    showSuccessMessage(msg, isHideSuccessMsg) {
-      if(isHideSuccessMsg){
-        this.set("isWFSaveSuccess", false);
-      } else {
-        this.set("isWFSaveSuccess", true);
-      }
-      Ember.run.later(()=>{
-      this.$('#successMsg').fadeOut();
-      }, 3000);
-      this.set("successMessage", msg);
-    },
     registerChild(key, context){
       this.get('childComponents').set(key, context);
     },
@@ -587,7 +571,6 @@ export default Ember.Component.extend(Validations, 
Ember.Evented, {
     },
     resetCoordinator(){
       this.get("errors").clear();
-      this.hideSuccessMsg();
       this.set('showingResetConfirmation', false);
       if(this.get('coordinatorFilePath')){
         this.importCoordinator(this.get('coordinatorFilePath'));

http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/components/flow-designer.js
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/flow-designer.js 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/flow-designer.js
index 6af82ba..01f8fe6 100644
--- 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/flow-designer.js
+++ 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/flow-designer.js
@@ -484,8 +484,6 @@ export default Ember.Component.extend(FindNodeMixin, 
Validations, {
     this.set('counterMap', {});
     this.set("undoAvailable", false);
     this.set("showingConfirmationNewWorkflow", false);
-    this.set("successMessage", "");
-    this.set("isWFSaveSuccess", false);
     if(this.get('workflow.parameters') !== null){
       this.set('workflow.parameters', {});
     }
@@ -752,17 +750,6 @@ export default Ember.Component.extend(FindNodeMixin, 
Validations, {
     }
   },
   actions:{
-    showSuccessMessage(msg, isHideSuccessMsg) {
-      if(isHideSuccessMsg){
-        this.set("isWFSaveSuccess", false);
-      } else {
-        this.set("isWFSaveSuccess", true);
-      }
-      Ember.run.later(()=>{
-      this.$('#successMsg').fadeOut();
-      }, 3000);
-      this.set("successMessage", msg);
-    },
     importWorkflowStream(dataStr){
       this.importWorkflowFromFile(dataStr);
     },

http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/components/job-config.js
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/job-config.js 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/job-config.js
index fe6f34c..15c1fbf 100644
--- a/contrib/views/wfmanager/src/main/resources/ui/app/components/job-config.js
+++ b/contrib/views/wfmanager/src/main/resources/ui/app/components/job-config.js
@@ -227,8 +227,6 @@ export default Ember.Component.extend(Validations, {
           });
         }
         this.set("savingInProgress",false);
-        this.$("#configureJob").modal("hide");
-        this.sendAction("showSuccessMessage", this.get("displayName")+" have 
been submitted successfully.");
       }.bind(this),
       error: function(response) {
         console.error(response);

http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/components/save-wf.js
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/components/save-wf.js 
b/contrib/views/wfmanager/src/main/resources/ui/app/components/save-wf.js
index cd9424a..017bc61 100644
--- a/contrib/views/wfmanager/src/main/resources/ui/app/components/save-wf.js
+++ b/contrib/views/wfmanager/src/main/resources/ui/app/components/save-wf.js
@@ -101,8 +101,6 @@ export default Ember.Component.extend(Validations, {
         });
         self.set("savingInProgress",false);
         this.set('jobFilePath', this.get('filePath'));
-        self.$("#configureJob").modal("hide");
-        self.sendAction("showSuccessMessage", this.get("displayName")+" have 
been saved successfully.");
     }.bind(this)).catch(function(response){
         self.set("savingInProgress",false);
         self.showNotification({

http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/bundle-config.hbs
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/bundle-config.hbs
 
b/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/bundle-config.hbs
index d17a857..2d374a5 100644
--- 
a/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/bundle-config.hbs
+++ 
b/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/bundle-config.hbs
@@ -72,13 +72,6 @@
     <div id='loading'>
       {{spin-spinner lines=13 length=20 width=10}}
     </div>
-    {{#if isWFSaveSuccess}}
-      <div id="successMsg">
-          <div id="alert" class="alert alert-info alert-dismissible 
workflow-error" role="alert">
-            {{successMessage}}
-          </div>
-      </div>
-    {{/if}}
     {{designer-errors errors=errors validationErrors=validationErrors 
errorMsg=errorMsg data=data}}
     <form class="form-horizontal">
       <div class="col-sm-12 paddingtop10">
@@ -131,7 +124,7 @@
   {{hdfs-browser closeFileBrowser="closeFileBrowser" 
selectFileCallback=selectFileCallback filePath=filePath}}
 {{/if}}
 {{#if showingJobConfig}}
-  {{job-config type='bundle' closeJobConfigs="closeBundleSubmitConfig" 
showSuccessMessage="showSuccessMessage" jobFilePath=bundleFilePath 
openFileBrowser="openFileBrowser" closeFileBrowser="closeFileBrowser" 
jobConfigs=bundleConfigs}}
+  {{job-config type='bundle' closeJobConfigs="closeBundleSubmitConfig" 
jobFilePath=bundleFilePath openFileBrowser="openFileBrowser" 
closeFileBrowser="closeFileBrowser" jobConfigs=bundleConfigs 
containsParameteriedPaths=containsParameteriedPaths}}
 {{/if}}
 {{#if showingResetConfirmation}}
   {{#confirmation-dialog title="Confirm Bundle Reset"
@@ -145,5 +138,5 @@
   {{bundle-version-settings bundle=bundle 
showVersionSettings="showVersionSettings" }}
 {{/if}}
 {{#if showingSaveWorkflow}}
-  {{save-wf type='bundle' close="closeSave" 
showSuccessMessage="showSuccessMessage" jobFilePath=bundleFilePath 
openFileBrowser="openFileBrowser" closeFileBrowser="closeFileBrowser" 
jobConfigs=configForSave}}
+  {{save-wf type='bundle' close="closeSave" jobFilePath=bundleFilePath 
openFileBrowser="openFileBrowser" closeFileBrowser="closeFileBrowser" 
jobConfigs=configForSave}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/coord-config.hbs
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/coord-config.hbs
 
b/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/coord-config.hbs
index 71d0080..0e35d0e 100644
--- 
a/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/coord-config.hbs
+++ 
b/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/coord-config.hbs
@@ -92,13 +92,6 @@
 <div id='loading'>
   {{spin-spinner lines=13 length=20 width=10}}
 </div>
-{{#if isWFSaveSuccess}}
-  <div id="successMsg">
-      <div id="alert" class="alert alert-info alert-dismissible 
workflow-error" role="alert">
-        {{successMessage}}
-      </div>
-  </div>
-{{/if}}
 <div class="container-fluid">
   {{designer-errors errors=errors validationErrors=validationErrors 
errorMsg=errorMsg data=data}}
   <form class="form-horizontal">
@@ -346,7 +339,7 @@
     parameterizedWorkflowPath=parameterizedWorkflowPath
     extractProperties="extractProperties" 
containsParameteriedPaths=containsParameteriedPaths
     jobFilePath=coordinatorFilePath openFileBrowser="openFileBrowser"
-    closeFileBrowser="closeFileBrowser" jobConfigs=coordinatorConfigs 
showSuccessMessage="showSuccessMessage" isDryrun=dryrun}}
+    closeFileBrowser="closeFileBrowser" jobConfigs=coordinatorConfigs 
isDryrun=dryrun}}
 {{/if}}
 {{#if showingResetConfirmation}}
 {{#confirmation-dialog title="Confirm Coordinator Reset"
@@ -388,5 +381,5 @@ okBtnText="Continue" cancelBtnText="Cancel" 
onOk="resetCoordinator"}}{{/confirma
 </div>
 {{/if}}
 {{#if showingSaveWorkflow}}
-  {{save-wf type='coord' close="closeSave" 
showSuccessMessage="showSuccessMessage" jobFilePath=coordinatorFilePath 
openFileBrowser="openFileBrowser" closeFileBrowser="closeFileBrowser" 
jobConfigs=configForSave}}
+  {{save-wf type='coord' close="closeSave" jobFilePath=coordinatorFilePath 
openFileBrowser="openFileBrowser" closeFileBrowser="closeFileBrowser" 
jobConfigs=configForSave}}
 {{/if}}

http://git-wip-us.apache.org/repos/asf/ambari/blob/0bbd5455/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/flow-designer.hbs
----------------------------------------------------------------------
diff --git 
a/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/flow-designer.hbs
 
b/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/flow-designer.hbs
index 2c85985..b5c3807 100644
--- 
a/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/flow-designer.hbs
+++ 
b/contrib/views/wfmanager/src/main/resources/ui/app/templates/components/flow-designer.hbs
@@ -159,25 +159,18 @@
       {{/if}}
       {{#if isAssetPublishing}}
         <div id="loader">
-            <div id="alert" class="alert alert-info alert-dismissible 
workflow-error" role="alert">
+            <div id="alert"class="alert alert-info alert-dismissible 
workflow-error" role="alert">
               Publishing asset. Please wait...
             </div>
         </div>
       {{/if}}
       {{#if isAssetImporting}}
         <div id="loader">
-            <div id="alert" class="alert alert-info alert-dismissible 
workflow-error" role="alert">
+            <div id="alert"class="alert alert-info alert-dismissible 
workflow-error" role="alert">
               Importing asset. Please wait...
             </div>
         </div>
       {{/if}}
-      {{#if isWFSaveSuccess}}
-        <div id="successMsg">
-            <div id="alert" class="alert alert-info alert-dismissible 
workflow-error" role="alert">
-              {{successMessage}}
-            </div>
-        </div>
-      {{/if}}
       <div id="flow-designer">
         {{#each flattenedNodes as |node|}}
         <div class="node-wrapper">
@@ -272,10 +265,10 @@
   {{workflow-action-editor actionType=currentAction 
closeActionEditor="closeActionEditor" setNodeTransitions="setNodeTransitions" 
actionModel=currentNode.domain nodeType=currentNode.type 
currentNode=currentNode killNodes=workflow.killNodes 
credentials=workflow.credentials validateWorkflow="validateWorkflow"}}
 {{/if}}
 {{#if showingSaveWorkflow}}
-  {{save-wf type='wf' close="closeSaveWorkflow" 
showSuccessMessage="showSuccessMessage" jobFilePath=workflowFilePath 
openFileBrowser="openFileBrowser" closeFileBrowser="closeFileBrowser" 
jobConfigs=configForSave}}
+  {{save-wf type='wf' close="closeSaveWorkflow" jobFilePath=workflowFilePath 
openFileBrowser="openFileBrowser" closeFileBrowser="closeFileBrowser" 
jobConfigs=configForSave}}
 {{/if}}
 {{#if showingWorkflowConfigProps}}
-  {{job-config type='wf' closeJobConfigs="closeWorkflowSubmitConfigs" 
showSuccessMessage="showSuccessMessage" jobFilePath=workflowFilePath 
tabInfo=tabInfo openFileBrowser="openFileBrowser" 
closeFileBrowser="closeFileBrowser" jobConfigs=workflowSubmitConfigs 
isDryrun=dryrun}}
+  {{job-config type='wf' closeJobConfigs="closeWorkflowSubmitConfigs" 
jobFilePath=workflowFilePath tabInfo=tabInfo openFileBrowser="openFileBrowser" 
closeFileBrowser="closeFileBrowser" jobConfigs=workflowSubmitConfigs 
isDryrun=dryrun}}
 {{/if}}
 {{#if showGlobalConfig}}
   {{#global-config closeGlobalConfig="closeWorkflowGlobalProps" 
saveGlobalConfig="saveGlobalConfig" actionModel=globalConfig}}{{/global-config}}

Reply via email to