-
-
+
diff --git a/src/app/topic/indicators.component.ts b/src/app/topic/indicators.component.ts
index 0677457..04ca1d4 100644
--- a/src/app/topic/indicators.component.ts
+++ b/src/app/topic/indicators.component.ts
@@ -75,13 +75,13 @@ export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterV
public indicator: Indicator;
public index: number = -1;
public editing: boolean = false;
+ public dragging: boolean = false;
/** Caches */
public safeUrls: Map
= new Map([]);
public numberResponses: Map = new Map();
public numberResults: Map = new Map();
/** Import / Export Indicators */
importLoading: boolean = false;
- exportLoading: boolean = false;
@ViewChild('editChartModal', {static: true}) editChartModal: AlertModal;
@ViewChild('editNumberModal', {static: true}) editNumberModal: AlertModal;
@ViewChild('deleteModal', {static: true}) deleteModal: AlertModal;
@@ -182,6 +182,12 @@ export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterV
this.reorderIndicators(list.current.id.toString().split('-')[1], type, reorder);
};
this.numbers.forEach((section) => {
+ this.subscriptions.push(UIkit.util.on(document, 'start', '#number-' + section._id, (): void => {
+ this.dragging = true;
+ }));
+ this.subscriptions.push(UIkit.util.on(document, 'stop', '#number-' + section._id, (): void => {
+ this.dragging = false;
+ }));
this.subscriptions.push(UIkit.util.on(document, 'moved', '#number-' + section._id, (list): void => {
callback(list, "number", 'moved');
}));
@@ -1281,7 +1287,6 @@ export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterV
public exportIndicators() {
this.editing = true;
- this.exportLoading = true;
let indicators = [];
let index: number = 0;
this.numbers.forEach(section => {
@@ -1329,7 +1334,6 @@ export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterV
a.remove(); // remove the element
this.editing = false;
- this.exportLoading = false;
}
fileChangeEvent(fileInput: any, index) {
@@ -1364,7 +1368,6 @@ export class IndicatorsComponent implements OnInit, OnDestroy, OnChanges, AfterV
return;
}
}
- // this.loading.open();
this.makeFileRequest(this.properties.utilsService + '/upload?type=json', [], this.filesToUpload).then(async (result: string) => {