@@ -93805,7 +93805,7 @@ a.exports = '<div ng-if="!$ctrl.success && !$ctrl.error">\n <div ng-if="!$ctrl.
93805
93805
}, function(a, b) {
93806
93806
a.exports = '<bind-service-form service-class="$ctrl.serviceClass.resource"\n service-class-name="$ctrl.serviceClass.name"\n applications="$ctrl.applications"\n form-name="$ctrl.forms.bindForm"\n allow-no-binding="true"\n project-name="$ctrl.projectDisplayName"\n bind-type="$ctrl.bindType"\n app-to-bind="$ctrl.appToBind">\n</bind-service-form>\n';
93807
93807
}, function(a, b) {
93808
- a.exports = '<div class="config-top">\n <form name="$ctrl.forms.orderConfigureForm" class="config-form">\n <select-project selected-project="$ctrl.selectedProject" name-taken="$ctrl.nameTaken"></select-project>\n <catalog-parameters\n ng-if="$ctrl.parameterSchema"\n model="$ctrl.parameterData"\n parameter-schema="$ctrl.parameterSchema">\n </catalog-parameters>\n </form>\n <div ng-if="$ctrl.error" class="has-error">\n <span class="help-block">{{$ctrl.error}}</span>\n </div>\n</div>\n';
93808
+ a.exports = '<div class="config-top">\n <form name="$ctrl.forms.orderConfigureForm" class="config-form">\n <select-project selected-project="$ctrl.selectedProject" name-taken="$ctrl.nameTaken"></select-project>\n <catalog-parameters\n ng-if="$ctrl.parameterSchema.properties "\n model="$ctrl.parameterData"\n parameter-schema="$ctrl.parameterSchema">\n </catalog-parameters>\n </form>\n <div ng-if="$ctrl.error" class="has-error">\n <span class="help-block">{{$ctrl.error}}</span>\n </div>\n</div>\n';
93809
93809
}, function(a, b) {
93810
93810
a.exports = '<div class="config-top">\n <div class="select-plans">\n <h3>Select a Plan</h3>\n <div ng-repeat="plan in $ctrl.serviceClass.resource.plans" class="radio">\n <label>\n <input\n type="radio"\n ng-model="$ctrl.planIndex"\n ng-change="$ctrl.selectPlan(plan)"\n value="{{$index}}">\n <span class="plan-name">{{plan.externalMetadata.displayName || plan.name}}</span>\n <!-- TODO: truncate long text -->\n <div ng-if="plan.description">{{plan.description}}</div>\n <!-- TODO: show plan bullets -->\n </label>\n </div>\n </div>\n</div>\n';
93811
93811
}, function(a, b) {
@@ -94492,18 +94492,18 @@ function a(a, b) {
94492
94492
this.resource = a, this.catalogSrv = b, this.imageUrl = this.getImage(), this.iconClass = this.getIcon(), this.name = this.getName(), this.description = this.getDescription(), this.longDescription = this.getLongDescription(), this.tags = this.getTags();
94493
94493
}
94494
94494
return a.prototype.getImage = function() {
94495
- return e.get(this.resource, "externalMetadata.imageUrl", "") ;
94495
+ return e.get(this.resource, "externalMetadata.imageUrl") || "" ;
94496
94496
}, a.prototype.getIcon = function() {
94497
- var a = e.get(this.resource, [ "externalMetadata", "console.openshift.io/iconClass" ], "fa fa-clone") ;
94497
+ var a = e.get(this.resource, [ "externalMetadata", "console.openshift.io/iconClass" ]) || "fa fa-clone";
94498
94498
return a = -1 !== a.indexOf("icon-") ? "font-icon " + a :a;
94499
94499
}, a.prototype.getName = function() {
94500
- return e.get(this.resource, "externalMetadata.displayName", this.resource.metadata.name) ;
94500
+ return e.get(this.resource, "externalMetadata.displayName") || this.resource.metadata.name;
94501
94501
}, a.prototype.getDescription = function() {
94502
- return e.get(this.resource, "description", "") ;
94502
+ return e.get(this.resource, "description") || "" ;
94503
94503
}, a.prototype.getLongDescription = function() {
94504
- return e.get(this.resource, "externalMetadata.longDescription", "") ;
94504
+ return e.get(this.resource, "externalMetadata.longDescription") || "" ;
94505
94505
}, a.prototype.getTags = function() {
94506
- return e.get(this.resource, "alphaTags", []) ;
94506
+ return e.get(this.resource, "alphaTags") || [] ;
94507
94507
}, a;
94508
94508
}();
94509
94509
b.ServiceItem = g;
@@ -94672,15 +94672,18 @@ m.clearValidityWatcher(), m.ctrl.nextTitle = "Create", m.reviewStep.allowed = !0
94672
94672
}, this.showResults = function() {
94673
94673
m.clearValidityWatcher(), m.ctrl.nextTitle = "Close", m.ctrl.wizardDone = !0, m.createApp();
94674
94674
}, this.onProjectUpdate = function() {
94675
- m.isNewProject() ? (m.ctrl.serviceInstances = [], m.updateBindability()) :(m.ctrl.updating = !0, m.ProjectsService.get(m.ctrl.selectedProject.metadata.name).then(e.spread(function(a, b) {
94676
- var c = {
94675
+ !m.instancesSupported || m.isNewProject() ? (m.ctrl.serviceInstances = [], m.updateBindability()) :(m.ctrl.updating = !0, m.DataService.list({
94677
94676
group:"servicecatalog.k8s.io",
94678
94677
resource:"instances"
94679
- };
94680
- m.watches.push(m.DataService.watch(c, b, function(a) {
94678
+ }, {
94679
+ namespace:m.ctrl.selectedProject.metadata.name
94680
+ }, null, {
94681
+ errorNotification:!1
94682
+ }).then(function(a) {
94681
94683
m.ctrl.serviceInstances = e.filter(e.toArray(a.by("metadata.name")), m.isServiceBindable), m.sortServiceInstances(), m.ctrl.updating = !1, m.updateBindability();
94684
+ }, function(a) {
94685
+ m.Logger.warn("Failed to list instances in namespace " + m.ctrl.selectedProject.metadata.name, a), m.ctrl.updating = !1, m.ctrl.serviceInstances = [], m.updateBindability();
94682
94686
}));
94683
- })));
94684
94687
}, this.isServiceBindable = function(a) {
94685
94688
return m.BindingService.isServiceBindable(a, m.ctrl.serviceClasses);
94686
94689
}, this.$scope = a, this.$filter = b, this.$location = c, this.$q = d, this.BuilderAppService = f, this.ProjectsService = g, this.DataService = h, this.APIService = i, this.BindingService = j, this.Logger = k, this.ctrl.serviceToBind = null, this.ctrl.showPodPresets = e.get(l, [ "ENABLE_TECH_PREVIEW_FEATURE", "pod_presets" ], !1);
@@ -94714,7 +94717,10 @@ prevEnabled:!1,
94714
94717
onShow:this.showResults
94715
94718
}, this.ctrl.steps = [ this.configStep, this.bindStep, this.reviewStep ], this.ctrl.versions = this.getVersions(), this.ctrl.istag = e.first(this.ctrl.versions), this.ctrl.nameMaxLength = 24, this.ctrl.namePattern = /^[a-z]([-a-z0-9]*[a-z0-9])?$/, this.ctrl.repositoryPattern = /^[a-z][a-z0-9+.-@]*:(\/\/)?[0-9a-z_-]+/, this.ctrl.wizardDone = !1, this.ctrl.serviceToBind = null, this.ctrl.updating = !1, this.ctrl.serviceInstances = [], this.selectedProjectWatch = this.$scope.$watch(function() {
94716
94719
return a.ctrl.selectedProject;
94717
- }, this.onProjectUpdate), this.getServiceClasses();
94720
+ }, this.onProjectUpdate), this.getServiceClasses(), this.instancesSupported = !!this.APIService.apiInfo({
94721
+ group:"servicecatalog.k8s.io",
94722
+ resource:"instances"
94723
+ });
94718
94724
}, a.prototype.closePanel = function() {
94719
94725
d.isFunction(this.ctrl.handleClose) && this.ctrl.handleClose();
94720
94726
}, a.prototype.$onDestroy = function() {
@@ -95248,7 +95254,7 @@ return a.resizeExpansion(!1);
95248
95254
maxWait:250
95249
95255
}), d.element(window).bind("resize", this.debounceResize), f(window).on("resize.services", this.debounceResize), this.removeFilterListener = this.$rootScope.$on("filter-catalog-items", function(b, c) {
95250
95256
var e = d.copy(a.keywordFilterField);
95251
- e.value = c.searchText, a.ctrl.currentFilter = a.ctrl.currentSubFilter = "all", a.filterChange([ e ]);
95257
+ e.value = c.searchText, a.ctrl.currentFilter = a.ctrl.currentSubFilter = "all", a.ctrl.mobileView = "subcategories", a. filterChange([ e ]);
95252
95258
}), this.ctrl.filterConfig = {
95253
95259
fields:[ this.keywordFilterField ],
95254
95260
resultsCount:0,
0 commit comments