Explorar el Código

AMBARI-10298 YARN service configs should look just like mockups. (ababiichuk)

aBabiichuk hace 10 años
padre
commit
9301f9b162

+ 1 - 1
ambari-web/app/mappers/configs/stack_config_properties_mapper.js

@@ -22,7 +22,7 @@ App.stackConfigPropertiesMapper = App.QuickDataMapper.create({
   config: {
     id: 'id',
     name: 'StackConfigurations.property_name',
-    display_name: 'StackConfigurations.property_name',
+    display_name: 'StackConfigurations.property_display_name',
     file_name: 'StackConfigurations.type',
     description: 'StackConfigurations.property_description',
     default_value: 'StackConfigurations.property_value',

+ 1 - 0
ambari-web/app/styles/common.less

@@ -40,6 +40,7 @@
 @space-l: 20px;
 @green: #69BE28;
 @blue: #0572ff;
+@gray-blue: #80A0B9;
 
 (~".@{health-status-red-icon}") {
   color: @health-status-red;

+ 5 - 0
ambari-web/app/styles/widgets.less

@@ -76,6 +76,11 @@
     box-shadow: none;
   }
 }
+.slider-disabled {
+  .slider-selection {
+    background-color: @gray-blue;
+  }
+}
 
 .spinner-input-widget {
 

+ 4 - 1
ambari-web/test/mappers/configs/stack_config_properties_mapper_test.js

@@ -45,6 +45,7 @@ describe('App.stackConfigPropertiesMapper', function () {
               "final" : "false",
               "property_description" : "desc1",
               "property_name" : "p1",
+              "property_display_name" : "P1",
               "property_type" : [ ],
               "property_value" : "v1",
               "service_name" : "s1",
@@ -95,6 +96,7 @@ describe('App.stackConfigPropertiesMapper', function () {
               "final" : "false",
               "property_description" : "desc3",
               "property_name" : "p2",
+              "property_display_name" : "P2",
               "property_type" : [ ],
               "property_value" : "v2",
               "service_name" : "s2",
@@ -108,6 +110,7 @@ describe('App.stackConfigPropertiesMapper', function () {
               "final" : "false",
               "property_description" : "desc3",
               "property_name" : "p3",
+              "property_display_name" : "P3",
               "property_type" : [ ],
               "property_value" : "v3",
               "service_name" : "s2",
@@ -139,7 +142,7 @@ describe('App.stackConfigPropertiesMapper', function () {
       expect(App.StackConfigProperty.find().mapProperty('id')).to.eql(['p1_site1','p2_site2','p3_site3']);
 
       expect(App.StackConfigProperty.find('p1_site1').get('name')).to.eql('p1');
-      expect(App.StackConfigProperty.find('p1_site1').get('displayName')).to.eql('p1');
+      expect(App.StackConfigProperty.find('p1_site1').get('displayName')).to.eql('P1');
       expect(App.StackConfigProperty.find('p1_site1').get('description')).to.eql('desc1');
       expect(App.StackConfigProperty.find('p1_site1').get('defaultValue')).to.eql('v1');
       expect(App.StackConfigProperty.find('p1_site1').get('defaultIsFinal')).to.be.false;