AW-6046 Angular improvement
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
This commit is contained in:
@@ -1,42 +1,29 @@
|
||||
import { Component, OnInit, OnDestroy, HostListener, ViewChild, AfterViewInit,NgZone,ElementRef } from '@angular/core';
|
||||
import { Location } from '@angular/common';
|
||||
import { Observable, Subject, Subscription, from,of ,EMPTY } from 'rxjs';
|
||||
import { withLatestFrom, switchMap,skip } from 'rxjs/operators';
|
||||
import { Router, ActivatedRoute, ParamMap } from '@angular/router';
|
||||
/* eslint-disable no-prototype-builtins */
|
||||
import { AfterViewInit, Component, ElementRef, HostListener, NgZone, OnDestroy, OnInit, ViewChild } from '@angular/core';
|
||||
import { ActivatedRoute, ParamMap, Router } from '@angular/router';
|
||||
import { DeviceService, GeolocatorService, IItem, IItemType, IQueryState, ItemTypeService, ResumableFileUploadService, StateSerializerService, commonActions, commonReducers } from '@farmmaps/common';
|
||||
import { Store } from '@ngrx/store';
|
||||
import { DeviceService } from '@farmmaps/common';
|
||||
import {getRenderPixel} from 'ol/render';
|
||||
|
||||
// Map
|
||||
import * as mapReducers from '../../reducers/map.reducer';
|
||||
import * as mapActions from '../../actions/map.actions';
|
||||
import { IMapState} from '../../models/map.state';
|
||||
import { IClickedFeature} from '../../models/clicked.feature';
|
||||
import { IQuery } from '../../reducers/map.reducer'
|
||||
import { ISelectedFeatures } from '../../models/selected.features';
|
||||
import { IItemLayer } from '../../models/item.layer';
|
||||
import { IListItem, IQueryState } from '@farmmaps/common';
|
||||
import { IPeriodState } from '../../models/period.state';
|
||||
import {IStyles} from '../../models/style.cache';
|
||||
import { IDroppedFile } from '../aol/file-drop-target/file-drop-target.component';
|
||||
import { StateSerializerService } from '@farmmaps/common';
|
||||
import { GeolocationService} from '../../services/geolocation.service';
|
||||
import { GeolocatorService } from '@farmmaps/common';
|
||||
import {DeviceOrientationService} from '../../services/device-orientation.service';
|
||||
|
||||
// AppCommon
|
||||
import { ResumableFileUploadService, ItemTypeService } from '@farmmaps/common';
|
||||
import { IItemType, IItem } from '@farmmaps/common';
|
||||
import {commonReducers} from '@farmmaps/common';
|
||||
import {commonActions} from '@farmmaps/common';
|
||||
|
||||
import {Feature} from 'ol';
|
||||
import {Geometry,Point,Circle} from 'ol/geom';
|
||||
import {Extent,createEmpty,extend } from 'ol/extent';
|
||||
import {transform} from 'ol/proj';
|
||||
import { tassign } from 'tassign';
|
||||
import { Feature } from 'ol';
|
||||
import { Extent, createEmpty, extend } from 'ol/extent';
|
||||
import { Circle, Geometry, Point } from 'ol/geom';
|
||||
import { transform } from 'ol/proj';
|
||||
import { getRenderPixel } from 'ol/render';
|
||||
import * as style from 'ol/style';
|
||||
|
||||
import { EMPTY, Observable, Subject, Subscription, from, of } from 'rxjs';
|
||||
import { skip, switchMap, withLatestFrom } from 'rxjs/operators';
|
||||
import { tassign } from 'tassign';
|
||||
import * as mapActions from '../../actions/map.actions';
|
||||
import { IClickedFeature } from '../../models/clicked.feature';
|
||||
import { IItemLayer } from '../../models/item.layer';
|
||||
import { IMapState } from '../../models/map.state';
|
||||
import { IPeriodState } from '../../models/period.state';
|
||||
import { ISelectedFeatures } from '../../models/selected.features';
|
||||
import { IStyles } from '../../models/style.cache';
|
||||
import * as mapReducers from '../../reducers/map.reducer';
|
||||
import { IQuery } from '../../reducers/map.reducer';
|
||||
import { DeviceOrientationService } from '../../services/device-orientation.service';
|
||||
import { GeolocationService } from '../../services/geolocation.service';
|
||||
import { IDroppedFile } from '../aol/file-drop-target/file-drop-target.component';
|
||||
|
||||
@Component({
|
||||
selector: 'fm-map-map',
|
||||
@@ -106,7 +93,6 @@ export class MapComponent implements OnInit, OnDestroy,AfterViewInit {
|
||||
private uploadService: ResumableFileUploadService,
|
||||
private serializeService: StateSerializerService,
|
||||
public itemTypeService: ItemTypeService,
|
||||
private location: Location,
|
||||
private geolocationService: GeolocationService,
|
||||
private geolocaterService: GeolocatorService,
|
||||
private zone: NgZone,
|
||||
@@ -389,15 +375,15 @@ export class MapComponent implements OnInit, OnDestroy,AfterViewInit {
|
||||
});
|
||||
}
|
||||
|
||||
handleSearchCollapse(event) {
|
||||
handleSearchCollapse() {
|
||||
this.store.dispatch(new mapActions.CollapseSearch());
|
||||
}
|
||||
|
||||
handleSearchExpand(event) {
|
||||
handleSearchExpand() {
|
||||
this.store.dispatch(new mapActions.ExpandSearch());
|
||||
}
|
||||
|
||||
handleToggleMenu(event) {
|
||||
handleToggleMenu() {
|
||||
this.store.dispatch(new commonActions.ToggleMenu());
|
||||
}
|
||||
|
||||
@@ -478,11 +464,11 @@ export class MapComponent implements OnInit, OnDestroy,AfterViewInit {
|
||||
});
|
||||
}
|
||||
|
||||
handleOnDownload(event) {
|
||||
handleOnDownload() {
|
||||
|
||||
}
|
||||
|
||||
handleClearSearch(event) {
|
||||
handleClearSearch() {
|
||||
this.store.dispatch(new mapActions.Clear());
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user