mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-19 17:01:13 +00:00
Update to ADO c5a09dcbef2464ad2dbd6d8a5c70d4b8f105816c (#6)
This commit is contained in:
@@ -163,6 +163,8 @@ export class ThroughputInputViewModel extends WaitsForTemplateViewModel {
|
||||
public minAutoPilotThroughput: ko.Observable<number>;
|
||||
public overrideWithAutoPilotSettings: ko.Observable<boolean>;
|
||||
public overrideWithProvisionedThroughputSettings: ko.Observable<boolean>;
|
||||
public isManualThroughputInputFieldRequired: ko.Computed<boolean>;
|
||||
public isAutoscaleThroughputInputFieldRequired: ko.Computed<boolean>;
|
||||
|
||||
public constructor(options: ThroughputInputParams) {
|
||||
super();
|
||||
@@ -213,6 +215,10 @@ export class ThroughputInputViewModel extends WaitsForTemplateViewModel {
|
||||
});
|
||||
this.decreaseButtonAriaLabel = "Decrease throughput by " + this.step().toString();
|
||||
this.increaseButtonAriaLabel = "Increase throughput by " + this.step().toString();
|
||||
this.isManualThroughputInputFieldRequired = ko.pureComputed(() => this.isEnabled() && !this.isAutoPilotSelected());
|
||||
this.isAutoscaleThroughputInputFieldRequired = ko.pureComputed(
|
||||
() => this.isEnabled() && this.isAutoPilotSelected()
|
||||
);
|
||||
}
|
||||
|
||||
public decreaseThroughput() {
|
||||
|
||||
@@ -77,12 +77,21 @@
|
||||
<p>
|
||||
<span>Max RU/s</span>
|
||||
</p>
|
||||
<input
|
||||
type="number"
|
||||
data-bind="textInput: overrideWithProvisionedThroughputSettings() ? '' : maxAutoPilotThroughputSet, attr:{disabled: overrideWithProvisionedThroughputSettings(), step: step, 'class':'migration collid select-font-size', min: minAutoPilotThroughput, css: {
|
||||
<div data-bind="setTemplateReady: true">
|
||||
<input
|
||||
data-bind="textInput: overrideWithProvisionedThroughputSettings() ? '' : maxAutoPilotThroughputSet, attr:{
|
||||
disabled: overrideWithProvisionedThroughputSettings(),
|
||||
step: step,
|
||||
'class':'migration collid select-font-size',
|
||||
min: minAutoPilotThroughput,
|
||||
'aria-label': ariaLabel,
|
||||
type: isAutoscaleThroughputInputFieldRequired() ? 'number' : 'hidden',
|
||||
css: {
|
||||
dirty: maxAutoPilotThroughputSet.editableIsDirty
|
||||
}}"
|
||||
/>
|
||||
}
|
||||
}"
|
||||
/>
|
||||
</div>
|
||||
<p data-bind="visible: overrideWithProvisionedThroughputSettings && !overrideWithProvisionedThroughputSettings()">
|
||||
<span
|
||||
data-bind="
|
||||
@@ -114,27 +123,25 @@
|
||||
|
||||
<div data-bind="visible: !isAutoPilotSelected()">
|
||||
<div data-bind="setTemplateReady: true">
|
||||
<p class="addContainerThroughputInput">
|
||||
<input
|
||||
type="number"
|
||||
required
|
||||
data-bind="
|
||||
<input
|
||||
data-bind="
|
||||
textInput: overrideWithAutoPilotSettings() ? maxAutoPilotThroughputSet : value,
|
||||
css: {
|
||||
dirty: value.editableIsDirty
|
||||
},
|
||||
enable: isEnabled,
|
||||
attr:{
|
||||
type: isManualThroughputInputFieldRequired() ? 'number' : 'hidden',
|
||||
'data-test': testId,
|
||||
'class': cssClass,
|
||||
step: step,
|
||||
min: minimum,
|
||||
max: canExceedMaximumValue() ? null : maximum,
|
||||
'aria-label': ariaLabel,
|
||||
disabled: overrideWithAutoPilotSettings()
|
||||
disabled: overrideWithAutoPilotSettings(),
|
||||
required: isManualThroughputInputFieldRequired()
|
||||
}"
|
||||
/>
|
||||
</p>
|
||||
/>
|
||||
</div>
|
||||
|
||||
<p data-bind="visible: costsVisible">
|
||||
|
||||
Reference in New Issue
Block a user