Compare commits
2 Commits
9e4a538a07
...
ea26cdd628
Author | SHA1 | Date | |
---|---|---|---|
|
ea26cdd628 | ||
|
26e28bdda8 |
17
package-lock.json
generated
17
package-lock.json
generated
@ -2692,14 +2692,14 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@farmmaps/common": {
|
"@farmmaps/common": {
|
||||||
"version": "0.0.1-prerelease.349",
|
"version": "0.0.1-prerelease.398",
|
||||||
"resolved": "https://repository.akkerweb.nl/repository/npm-group/@farmmaps/common/-/common-0.0.1-prerelease.349.tgz",
|
"resolved": "https://repository.akkerweb.nl/repository/npm-group/@farmmaps/common/-/common-0.0.1-prerelease.398.tgz",
|
||||||
"integrity": "sha512-CLANnjefX8vpIIOHX/eutPG9H/7PD/rgG5HH/VhmXjTwSjU97W4xf+iLow4SvukVFfikQ1EDnWECx/6uKKRIUg=="
|
"integrity": "sha512-lAOHGwYFUSE4lTqiSIbANbP6KJoAW0uEgor8ag2ridTRHE8X5skj3wYZIkzYOhUA8njPEju+U6wwW8e4wshlCw=="
|
||||||
},
|
},
|
||||||
"@farmmaps/common-map": {
|
"@farmmaps/common-map": {
|
||||||
"version": "0.0.1-prerelease.360",
|
"version": "0.0.1-prerelease.398",
|
||||||
"resolved": "https://repository.akkerweb.nl/repository/npm-group/@farmmaps/common-map/-/common-map-0.0.1-prerelease.360.tgz",
|
"resolved": "https://repository.akkerweb.nl/repository/npm-group/@farmmaps/common-map/-/common-map-0.0.1-prerelease.398.tgz",
|
||||||
"integrity": "sha512-V7cWPiTHS1gIahwCpt32Qcv+wHxdOWg/+LzmP2x/6X9cJnC0L6XDR5rJFvS8zpGeRJiunq7cSFCm/22MOpnRTQ=="
|
"integrity": "sha512-XZt8q55r5oQUdUwLDxFeAkzliyMRXC6qHm87ok/hIZvQkq90RlTRBAZ1+xoLS8Gi3Ix28fQMDwjYD68n2PJ5Vg=="
|
||||||
},
|
},
|
||||||
"@istanbuljs/schema": {
|
"@istanbuljs/schema": {
|
||||||
"version": "0.1.2",
|
"version": "0.1.2",
|
||||||
@ -9443,6 +9443,11 @@
|
|||||||
"minimist": "^1.2.5"
|
"minimist": "^1.2.5"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"moment": {
|
||||||
|
"version": "2.28.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/moment/-/moment-2.28.0.tgz",
|
||||||
|
"integrity": "sha512-Z5KOjYmnHyd/ukynmFd/WwyXHd7L4J9vTI/nn5Ap9AVUgaAE15VvQ9MOGmJJygEUklupqIrFnor/tjTwRU+tQw=="
|
||||||
|
},
|
||||||
"move-concurrently": {
|
"move-concurrently": {
|
||||||
"version": "1.0.1",
|
"version": "1.0.1",
|
||||||
"resolved": "https://registry.npmjs.org/move-concurrently/-/move-concurrently-1.0.1.tgz",
|
"resolved": "https://registry.npmjs.org/move-concurrently/-/move-concurrently-1.0.1.tgz",
|
||||||
|
@ -19,8 +19,8 @@
|
|||||||
"@angular/platform-browser": "~9.1.0",
|
"@angular/platform-browser": "~9.1.0",
|
||||||
"@angular/platform-browser-dynamic": "~9.1.0",
|
"@angular/platform-browser-dynamic": "~9.1.0",
|
||||||
"@angular/router": "~9.1.0",
|
"@angular/router": "~9.1.0",
|
||||||
"@farmmaps/common": ">=0.0.1-prerelease.349 <0.0.1",
|
"@farmmaps/common": ">=0.0.1-prerelease.398 <0.0.1",
|
||||||
"@farmmaps/common-map": ">=0.0.1-prerelease.349 <0.0.1",
|
"@farmmaps/common-map": ">=0.0.1-prerelease.398 <0.0.1",
|
||||||
"@microsoft/signalr": "^3.1.3",
|
"@microsoft/signalr": "^3.1.3",
|
||||||
"@ng-bootstrap/ng-bootstrap": "^6.0",
|
"@ng-bootstrap/ng-bootstrap": "^6.0",
|
||||||
"@ngrx/effects": "^9.0",
|
"@ngrx/effects": "^9.0",
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Component, Input, Injectable, OnInit, ComponentFactoryResolver, Inject, ComponentFactory } from '@angular/core';
|
import { Component, Input, Injectable, OnInit } from '@angular/core';
|
||||||
import { Location } from '@angular/common';
|
import { Location } from '@angular/common';
|
||||||
import { Feature } from 'ol';
|
import { Feature } from 'ol';
|
||||||
import { Store } from '@ngrx/store';
|
import { Store } from '@ngrx/store';
|
||||||
@ -11,7 +11,6 @@ import { Observable,of } from 'rxjs';
|
|||||||
import {GeoJSON} from 'ol/format';
|
import {GeoJSON} from 'ol/format';
|
||||||
import {getArea} from 'ol/sphere';
|
import {getArea} from 'ol/sphere';
|
||||||
import { withLatestFrom,switchMap,combineLatest } from 'rxjs/operators';
|
import { withLatestFrom,switchMap,combineLatest } from 'rxjs/operators';
|
||||||
import { AbstractItemListItemComponent, ItemListItemComponent } from '../item-list-item/item-list-item.component';
|
|
||||||
|
|
||||||
|
|
||||||
@ForItemType("vnd.farmmaps.itemtype.cropfield")
|
@ForItemType("vnd.farmmaps.itemtype.cropfield")
|
||||||
@ -25,8 +24,7 @@ export class SelectedItemCropfieldComponent extends AbstractSelectedItemComponen
|
|||||||
|
|
||||||
public items: Observable<IListItem[]>;
|
public items: Observable<IListItem[]>;
|
||||||
|
|
||||||
constructor(store: Store<mapReducers.State | commonReducers.State>, itemTypeService: ItemTypeService, location: Location, router: Router, private itemService$: ItemService,private folderService$: FolderService,
|
constructor(store: Store<mapReducers.State | commonReducers.State>, itemTypeService: ItemTypeService, location: Location, router: Router, private itemService$: ItemService,private folderService$: FolderService) {
|
||||||
private componentFactoryResolver: ComponentFactoryResolver, @Inject(AbstractItemListItemComponent) public itemComponentList: AbstractItemListItemComponent[] ) {
|
|
||||||
super(store, itemTypeService,location,router);
|
super(store, itemTypeService,location,router);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -41,7 +39,6 @@ export class SelectedItemCropfieldComponent extends AbstractSelectedItemComponen
|
|||||||
}
|
}
|
||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
var componentFactory: ComponentFactory<AbstractItemListItemComponent> = this.componentFactoryResolver.resolveComponentFactory(ItemListItemComponent); // default
|
|
||||||
var childItems = this.folderService$.getItems(this.item.code, 0, 1000);
|
var childItems = this.folderService$.getItems(this.item.code, 0, 1000);
|
||||||
var atLocationItems = this.itemService$.getItemList(null,null,null,this.item.code,true);
|
var atLocationItems = this.itemService$.getItemList(null,null,null,this.item.code,true);
|
||||||
this.items = childItems.pipe(
|
this.items = childItems.pipe(
|
||||||
@ -50,12 +47,8 @@ export class SelectedItemCropfieldComponent extends AbstractSelectedItemComponen
|
|||||||
let retVal:IListItem[] = [];
|
let retVal:IListItem[] = [];
|
||||||
let codes = {};
|
let codes = {};
|
||||||
ci.forEach((listItem) => {
|
ci.forEach((listItem) => {
|
||||||
if (this.itemComponentList.findIndex(i =>
|
|
||||||
i.item['forItemType'].indexOf(this.item.itemType) >= 0 &&
|
|
||||||
i.item['forSourceTask'].indexOf(this.item.sourceTask) >= 0) >= 0) {
|
|
||||||
retVal.push(listItem);
|
retVal.push(listItem);
|
||||||
codes[listItem.code]=listItem;
|
codes[listItem.code]=listItem;
|
||||||
}
|
|
||||||
});
|
});
|
||||||
ali.forEach((atlocationitem) => {
|
ali.forEach((atlocationitem) => {
|
||||||
let listItem = atlocationitem as IListItem;
|
let listItem = atlocationitem as IListItem;
|
||||||
|
Loading…
Reference in New Issue
Block a user