AMBARI-20662.Need to auto populate the workflow parameters if its already 
defined in the global space.(M Madhan Mohan Reddy via padmapriyanitt)


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

Branch: refs/heads/branch-feature-AMBARI-12556
Commit: 4004ee89c989241ac5c6d439f02a06ee0dd61f03
Parents: 92e5b59
Author: padmapriyanitt <[email protected]>
Authored: Tue Apr 4 16:21:27 2017 +0530
Committer: padmapriyanitt <[email protected]>
Committed: Tue Apr 4 16:21:27 2017 +0530

----------------------------------------------------------------------
 .../wfmanager/src/main/resources/ui/app/components/job-config.js | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/4004ee89/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 e9c7c15..6aed9da 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
@@ -121,15 +121,17 @@ export default Ember.Component.extend(Validations, {
       if (value!== Constants.defaultNameNodeValue && 
value!==Constants.rmDefaultValue){
         var propName = value.trim().substring(2, value.length-1);
         var isRequired = true;
+        var val = null;
         if(jobParams && jobParams.configuration && 
jobParams.configuration.property){
           var param = jobParams.configuration.property.findBy('name', 
propName);
           if(param && param.value){
             isRequired = false;
+            val = param.value;
           }else {
             isRequired = true;
           }
         }
-        let val = null, tabData = self.get("tabInfo");
+        let tabData = self.get("tabInfo");
         if(tabData && tabData.isImportedFromDesigner && tabData.configuration 
&& tabData.configuration.settings && 
tabData.configuration.settings.configuration && 
tabData.configuration.settings.configuration.property) {
           let propVal = 
tabData.configuration.settings.configuration.property.findBy('name', propName);
           if(propVal) {

Reply via email to