mirror of
https://github.com/valitydev/redash.git
synced 2024-11-07 09:28:51 +00:00
This commit is contained in:
parent
927599cf00
commit
9647c37285
@ -13,8 +13,9 @@
|
||||
<label class="control-label">Visualization Type</label>
|
||||
|
||||
<select required ng-model="$ctrl.visualization.type"
|
||||
ng-options="type.type as type.name for type in $ctrl.visTypes" class="form-control"
|
||||
ng-change="$ctrl.typeChanged('{{$ctrl.visualization.type}}')"></select>
|
||||
ng-disabled="!$ctrl.canChangeType"
|
||||
ng-options="type.type as type.name for type in $ctrl.visTypes" class="form-control"
|
||||
ng-change="$ctrl.typeChanged('{{$ctrl.visualization.type}}')"></select>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
|
@ -19,6 +19,9 @@ const EditVisualizationDialog = {
|
||||
this.visualization = copy(this.originalVisualization);
|
||||
this.visTypes = Visualization.visualizationTypes;
|
||||
|
||||
// Don't allow to change type after creating visualization
|
||||
this.canChangeType = !(this.visualization && this.visualization.id);
|
||||
|
||||
this.newVisualization = () =>
|
||||
({
|
||||
type: Visualization.defaultVisualization.type,
|
||||
|
Loading…
Reference in New Issue
Block a user