diff --git a/app/scripts/directives/fromFileDialog.js b/app/scripts/directives/fromFileDialog.js index 01c50ca035..c1b39a947b 100644 --- a/app/scripts/directives/fromFileDialog.js +++ b/app/scripts/directives/fromFileDialog.js @@ -21,6 +21,8 @@ function FromFileDialog($scope, $timeout, $routeParams, $filter, DataService) { var ctrl = this; + var annotation = $filter('annotation'); + var imageForIconClass = $filter('imageForIconClass'); ctrl.$onInit = function() { ctrl.alerts = {}; @@ -36,6 +38,11 @@ return (icon.indexOf('icon-') !== -1) ? 'font-icon ' + icon : icon; } + function getImage() { + var iconClass = _.get(ctrl, 'template.metadata.annotations.iconClass', 'fa fa-clone'); + return imageForIconClass(iconClass); + } + ctrl.importFile = function() { $scope.$broadcast('importFileFromYAMLOrJSON'); }; @@ -48,6 +55,10 @@ ctrl.selectedProject = message.project; ctrl.template = message.template; ctrl.iconClass = getIconClass(); + ctrl.image = getImage(); + ctrl.vendor = annotation(message.template, "template.openshift.io/provider-display-name"); + ctrl.docUrl = annotation(ctrl.template, "template.openshift.io/documentation-url"); + ctrl.supportUrl = annotation(ctrl.template, "template.openshift.io/support-url"); ctrl.name = "YAML / JSON"; // Need to let the current digest loop finish so the template config step becomes visible or the wizard will throw an error // from the change to currentStep diff --git a/app/scripts/directives/processTemplateDialog.js b/app/scripts/directives/processTemplateDialog.js index ceca60380c..6170a823be 100644 --- a/app/scripts/directives/processTemplateDialog.js +++ b/app/scripts/directives/processTemplateDialog.js @@ -130,6 +130,7 @@ ctrl.image = getImage(); ctrl.docUrl = annotation(ctrl.template, "template.openshift.io/documentation-url"); ctrl.supportUrl = annotation(ctrl.template, "template.openshift.io/support-url"); + ctrl.vendor = annotation(ctrl.template, "template.openshift.io/provider-display-name"); } } if (changes.useProjectTemplate) { @@ -179,6 +180,9 @@ ctrl.selectStep.valid = !!template; ctrl.iconClass = getIconClass(); ctrl.image = getImage(); + ctrl.docUrl = annotation(ctrl.template, "template.openshift.io/documentation-url"); + ctrl.supportUrl = annotation(ctrl.template, "template.openshift.io/support-url"); + ctrl.vendor = annotation(ctrl.template, "template.openshift.io/provider-display-name"); }; ctrl.templateProjectChange = function () { diff --git a/app/views/directives/from-file-dialog.html b/app/views/directives/from-file-dialog.html index de4ed3dc0d..36c28cebf4 100644 --- a/app/views/directives/from-file-dialog.html +++ b/app/views/directives/from-file-dialog.html @@ -38,19 +38,31 @@ next-enabled="!$ctrl.templateForm.$invalid">
-
+
- + +
{{$ctrl.template | displayName}}
+
+ {{$ctrl.vendor}} +
{{tag}}
+
diff --git a/app/views/directives/process-template-dialog/process-template-info.html b/app/views/directives/process-template-dialog/process-template-info.html index 4abbdc6ff5..0ef881d534 100644 --- a/app/views/directives/process-template-dialog/process-template-info.html +++ b/app/views/directives/process-template-dialog/process-template-info.html @@ -1,5 +1,5 @@
-
+
@@ -8,6 +8,9 @@
{{$ctrl.template | displayName}}
+
+ {{$ctrl.vendor}} +
{{tag}} diff --git a/bower.json b/bower.json index 292b23ec1a..ea36949684 100644 --- a/bower.json +++ b/bower.json @@ -47,7 +47,7 @@ "angular-utf8-base64": "0.0.5", "file-saver": "1.3.3", "origin-web-common": "0.0.66", - "origin-web-catalog": "0.0.54" + "origin-web-catalog": "0.0.55" }, "devDependencies": { "angular-mocks": "1.5.11", diff --git a/dist/scripts/scripts.js b/dist/scripts/scripts.js index fbef63ae4f..66b85f4830 100644 --- a/dist/scripts/scripts.js +++ b/dist/scripts/scripts.js @@ -13158,7 +13158,7 @@ appliedFilters: [], onFilterChange: g }, n.project || (b.showProjectName = !0); }, b.$onChanges = function(e) { -e.template && b.template && (d(), b.iconClass = l(), b.image = u(), b.docUrl = S(b.template, "template.openshift.io/documentation-url"), b.supportUrl = S(b.template, "template.openshift.io/support-url")), e.useProjectTemplate && d(); +e.template && b.template && (d(), b.iconClass = l(), b.image = u(), b.docUrl = S(b.template, "template.openshift.io/documentation-url"), b.supportUrl = S(b.template, "template.openshift.io/support-url"), b.vendor = S(b.template, "template.openshift.io/provider-display-name")), e.useProjectTemplate && d(); }, e.$on("templateInstantiated", function(e, t) { b.selectedProject = t.project, b.currentStep = b.resultsStep.label; }), b.$onDestroy = function() { @@ -13171,7 +13171,7 @@ _.isFunction(e) && e(); }, b.onProjectSelected = function(t) { b.selectedProject = t, b.configStep.valid = e.$ctrl.form.$valid && b.selectedProject; }, b.templateSelected = function(e) { -b.selectedTemplate = e, b.template = _.get(e, "resource"), b.selectStep.valid = !!e, b.iconClass = l(), b.image = u(); +b.selectedTemplate = e, b.template = _.get(e, "resource"), b.selectStep.valid = !!e, b.iconClass = l(), b.image = u(), b.docUrl = S(b.template, "template.openshift.io/documentation-url"), b.supportUrl = S(b.template, "template.openshift.io/support-url"), b.vendor = S(b.template, "template.openshift.io/provider-display-name"); }, b.templateProjectChange = function() { b.templateProjectName = _.get(b.templateProject, "metadata.name"), b.catalogItems = {}, b.templateSelected(), a.getProjectCatalogItems(b.templateProjectName, !1, !0).then(_.spread(function(e, t) { b.catalogItems = e, b.totalCount = b.catalogItems.length, g(), t && i.addNotification({ @@ -13225,30 +13225,34 @@ templateUrl: "views/directives/deploy-image-dialog.html" angular.module("openshiftConsole").component("fromFileDialog", { controller: [ "$scope", "$timeout", "$routeParams", "$filter", "DataService", function(e, t, n, a, r) { function o() { -var e = _.get(i, "template.metadata.annotations.iconClass", "fa fa-clone"); +var e = _.get(s, "template.metadata.annotations.iconClass", "fa fa-clone"); return -1 !== e.indexOf("icon-") ? "font-icon " + e : e; } -var i = this; -i.$onInit = function() { -i.alerts = {}, i.loginBaseUrl = r.openshiftAPIBaseUrl(), n.project || (i.showProjectName = !0); -}, i.importFile = function() { +function i() { +var e = _.get(s, "template.metadata.annotations.iconClass", "fa fa-clone"); +return l(e); +} +var s = this, c = a("annotation"), l = a("imageForIconClass"); +s.$onInit = function() { +s.alerts = {}, s.loginBaseUrl = r.openshiftAPIBaseUrl(), n.project || (s.showProjectName = !0); +}, s.importFile = function() { e.$broadcast("importFileFromYAMLOrJSON"); -}, i.instantiateTemplate = function() { +}, s.instantiateTemplate = function() { e.$broadcast("instantiateTemplate"); }, e.$on("fileImportedFromYAMLOrJSON", function(e, n) { -i.selectedProject = n.project, i.template = n.template, i.iconClass = o(), i.name = "YAML / JSON", t(function() { -i.currentStep = i.template ? "Template Configuration" : "Results"; +s.selectedProject = n.project, s.template = n.template, s.iconClass = o(), s.image = i(), s.vendor = c(n.template, "template.openshift.io/provider-display-name"), s.docUrl = c(s.template, "template.openshift.io/documentation-url"), s.supportUrl = c(s.template, "template.openshift.io/support-url"), s.name = "YAML / JSON", t(function() { +s.currentStep = s.template ? "Template Configuration" : "Results"; }, 0); }), e.$on("templateInstantiated", function(e, t) { -i.selectedProject = t.project, i.name = a("displayName")(i.template), i.currentStep = "Results"; -}), i.close = function() { -i.template = null; -var e = i.onDialogClosed(); -return _.isFunction(e) && e(), i.wizardDone = !1, !0; -}, i.stepChanged = function(e) { -"results" === e.stepId ? (i.nextButtonTitle = "Close", i.wizardDone = !0) : i.nextButtonTitle = "Create"; -}, i.currentStep = "YAML / JSON", i.nextCallback = function(e) { -return "file" === e.stepId ? (i.importFile(), !1) : "template" === e.stepId ? (i.instantiateTemplate(), !1) : "results" !== e.stepId || (i.close(), !1); +s.selectedProject = t.project, s.name = a("displayName")(s.template), s.currentStep = "Results"; +}), s.close = function() { +s.template = null; +var e = s.onDialogClosed(); +return _.isFunction(e) && e(), s.wizardDone = !1, !0; +}, s.stepChanged = function(e) { +"results" === e.stepId ? (s.nextButtonTitle = "Close", s.wizardDone = !0) : s.nextButtonTitle = "Create"; +}, s.currentStep = "YAML / JSON", s.nextCallback = function(e) { +return "file" === e.stepId ? (s.importFile(), !1) : "template" === e.stepId ? (s.instantiateTemplate(), !1) : "results" !== e.stepId || (s.close(), !1); }; } ], controllerAs: "$ctrl", diff --git a/dist/scripts/templates.js b/dist/scripts/templates.js index 601d73436c..a4ceac89d9 100644 --- a/dist/scripts/templates.js +++ b/dist/scripts/templates.js @@ -7018,19 +7018,31 @@ angular.module('openshiftConsoleTemplates', []).run(['$templateCache', function( "\n" + "
\n" + "
\n" + - "
\n" + + "
\n" + "
\n" + - "\n" + + "\"\"\n" + + "\n" + "
\n" + "
\n" + "
\n" + "{{$ctrl.template | displayName}}\n" + "
\n" + + "
\n" + + "{{$ctrl.vendor}}\n" + + "
\n" + "
\n" + "\n" + "{{tag}}\n" + "\n" + "
\n" + + "\n" + "
\n" + "
\n" + "
\n" + @@ -8846,7 +8858,7 @@ angular.module('openshiftConsoleTemplates', []).run(['$templateCache', function( $templateCache.put('views/directives/process-template-dialog/process-template-info.html', "
\n" + - "
\n" + + "
\n" + "
\n" + "\"\"\n" + "\n" + @@ -8855,6 +8867,9 @@ angular.module('openshiftConsoleTemplates', []).run(['$templateCache', function( "
\n" + "{{$ctrl.template | displayName}}\n" + "
\n" + + "
\n" + + "{{$ctrl.vendor}}\n" + + "
\n" + "
\n" + "\n" + "{{tag}}\n" + diff --git a/dist/scripts/vendor.js b/dist/scripts/vendor.js index 736b6a95ee..82cbb5822e 100644 --- a/dist/scripts/vendor.js +++ b/dist/scripts/vendor.js @@ -77303,7 +77303,7 @@ e.exports = '
\n \n \n \x3c!-- Wait until users leave the field to avoid flashing errors as they type. --\x3e\n
\n
\n \n Application name is required.\n \n
\n
\n \n Application name consists of lower-case letters, numbers, and dashes. It must start with a letter and can\'t end with a -.\n \n
\n
\n \n Application name must be at least 2 characters.\n \n
\n
\n \n Application name can\'t be more than 24 characters.\n \n
\n
\n
\n
\n\n
\n \n
\n \n \n
\n \n Git repository is required.\n \n
\n
\n \n This might not be a valid Git URL. Check that it is the correct URL to a remote Git repository.\n \n
\n
\n
\n\n \x3c!--\n Only show the link for existing projects. It will be broken for new\n projects. Use class `invisible` when the project list is still loading\n so the dialog doesn\'t resize.\n --\x3e\n
\n If you have a private Git repository or need to change application defaults, view\n advanced options.\n
\n \n
\n
\n'; }, function(e, t) { -e.exports = '
\n
\n
\n \n \n
\n
\n
\n {{$ctrl.imageStream.name}}\n {{$ctrl.istag.name}}\n
\n
\n \n {{tag}}\n \n
\n
\n
\n
\n

\n

\n Sample Repository:\n \x3c!-- TODO: Use Git link filter, needs to be added to origin-web-common --\x3e\n \n

\n
\n
\n'; +e.exports = '
\n
\n
\n \n \n
\n
\n
\n {{$ctrl.imageStream.name}}\n {{$ctrl.istag.name}}\n
\n
\n \n {{tag}}\n \n
\n
\n
\n
\n

\n

\n Sample Repository:\n \x3c!-- TODO: Use Git link filter, needs to be added to origin-web-common --\x3e\n \n

\n
\n
\n'; }, function(e, t) { e.exports = '
\n
\n
\n \n Pending\n
\n

\n {{$ctrl.name}} is being created in {{$ctrl.selectedProject | displayName}}.\n

\n
\n
\n
\n
\n
\n \n Success\n
\n

\n {{$ctrl.name}} has been created in {{$ctrl.selectedProject | displayName}} successfully.\n

\n
\n
\n
\n
\n \n \n
\n
\n

\n Continue to the project overview to check the status of your application as it builds and deploys.\n

\n
\n
\n
\n \n
\n

\n {{$ctrl.name}} failed to create in {{$ctrl.selectedProject | displayName}}.\n

\n
\n
\n
\n \n {{$ctrl.error.data.message | upperFirst}}\n \n \n An error occurred creating the application.\n \n
\n \x3c!-- TODO: Improve error message presentation --\x3e\n
    \n
  • \n {{failure.data.message}}\n
  • \n
\n
\n
\n'; }, function(e, t) { @@ -77313,7 +77313,7 @@ e.exports = '
\n \n \n Plan {{$ctrl.selectedPlan.spec.externalMetadata.displayName}}\n \n \n {{$ctrl.selectedPlan.spec.description}}\n

\n

\n

\n
\n
\n'; +e.exports = '
\n
\n
\n \n \n
\n
\n
\n {{$ctrl.serviceName}}\n
\n
\n {{$ctrl.serviceClass.vendor}}\n
\n
\n \n {{tag}}\n \n
\n \n
\n
\n
\n

\n \n Plan {{$ctrl.selectedPlan.spec.externalMetadata.displayName}}\n \n \n {{$ctrl.selectedPlan.spec.description}}\n

\n

No description provided.

\n

\n

\n
\n
\n'; }, function(e, t) { e.exports = '
\n
\n
\n

Select a Plan

\n
\n \n
\n
\n
\n
\n'; }, function(e, t) { @@ -78665,7 +78665,7 @@ status: "True" } return e.prototype.$onInit = function() { var e = this; -this.ctrl.iconClass = this.ctrl.serviceClass.iconClass || "fa fa-clone", this.ctrl.imageUrl = this.ctrl.serviceClass.imageUrl, this.ctrl.serviceName = this.ctrl.serviceClass.name, this.ctrl.description = this.ctrl.serviceClass.description, this.ctrl.longDescription = this.ctrl.serviceClass.longDescription, this.ctrl.applications = [], this.ctrl.parameterData = {}, this.ctrl.bindParameterData = {}, this.ctrl.forms = {}, this.ctrl.appToBind = null, this.ctrl.configStepValid = !0, this.infoStep = { +this.ctrl.iconClass = this.ctrl.serviceClass.iconClass || "fa fa-clone", this.ctrl.imageUrl = this.ctrl.serviceClass.imageUrl, this.ctrl.serviceName = this.ctrl.serviceClass.name, this.ctrl.description = this.ctrl.serviceClass.description, this.ctrl.longDescription = this.ctrl.serviceClass.longDescription, this.ctrl.docUrl = r.get(this.ctrl.serviceClass, "resource.spec.externalMetadata.documentationUrl"), this.ctrl.supportUrl = r.get(this.ctrl.serviceClass, "resource.spec.externalMetadata.supportUrl"), this.ctrl.applications = [], this.ctrl.parameterData = {}, this.ctrl.bindParameterData = {}, this.ctrl.forms = {}, this.ctrl.appToBind = null, this.ctrl.configStepValid = !0, this.infoStep = { id: "info", label: "Information", view: "order-service/order-service-info.html", diff --git a/dist/styles/main.css b/dist/styles/main.css index 633560139d..1cc63e8bee 100644 --- a/dist/styles/main.css +++ b/dist/styles/main.css @@ -4115,6 +4115,7 @@ div.hopscotch-bubble .hopscotch-nav-button.prev{color:#030303} @media (min-width:1600px){.landing-side-bar{width:475px} } .order-service-details .order-service-details-top{align-items:center;display:flex} +.order-service-details .order-service-details-top.order-service-details-top-icon-top{align-items:flex-start} .order-service-details .order-service-details-top .service-icon{margin-right:15px} .order-service-details .order-service-details-top .service-icon .icon{font-size:60px} .order-service-details .order-service-details-top .service-icon .image img{max-height:52px;max-width:52px} @@ -4127,11 +4128,12 @@ div.hopscotch-bubble .hopscotch-nav-button.prev{color:#030303} @media (min-width:450px){.order-service-details .order-service-details-top .service-title{font-size:22px} } .order-service-details .order-service-details-top .service-title-area{flex:1 1 0%;word-wrap:break-word;word-break:break-word;overflow-wrap:break-word;min-width:0} +.order-service-details .order-service-details-top .service-vendor{margin-top:5px} .order-service-details .order-service-details-top .sub-title{font-size:20px;font-weight:600;color:#72767b} .order-service-details .order-service-description-block{margin-top:15px} .order-service-details .order-service-description-block .learn-more-link{font-size:11px;white-space:nowrap} .order-service-details .order-service-documentation-url{margin-top:4px} -.order-service-details .order-service-tags{margin-top:5px} +.order-service-details .order-service-tags{color:#9c9c9c;margin-top:5px} .order-service-details .order-service-tags .tag{margin-right:5px;text-transform:uppercase} .order-service-config .config-top .adv-ops{height:30%} .order-service-config .config-top .adv-ops-href{cursor:pointer;font-size:14px}