Browse Source

[完善]基本信息素材tag为1

master
邵佳豪 4 years ago
parent
commit
6b90c51ae3
  1. 16
      src/app/ui/collection-tools-examinee/collection-tools.component.ts

16
src/app/ui/collection-tools-examinee/collection-tools.component.ts

@ -1,4 +1,4 @@
import { Component, OnInit, Inject, ViewChild,ElementRef,Renderer2, ViewContainerRef } from '@angular/core';
import { Component, OnInit, Inject, ViewChild,ElementRef,Renderer2, ViewContainerRef, ɵConsole } from '@angular/core';
import { HttpClient, HttpHeaders } from '@angular/common/http';
import { MatDialog, MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
import { MatSnackBar, MatSnackBarConfig } from '@angular/material/snack-bar';
@ -483,6 +483,9 @@ export class CollectionToolsExamineeComponent implements OnInit {
.subscribe((data:any) => {
console.log(index,data)
if(data && data.length != 0){
data.forEach(item => {
item.tag = 1
})
element.images = data
this.basicAssetLibraries.push(
element
@ -492,7 +495,7 @@ export class CollectionToolsExamineeComponent implements OnInit {
})
})
}
console.log(55555,this.basicAssetLibraries)
// console.log(55555,this.basicAssetLibraries)
this.allLibrary = [...this.originalallLibrary,...this.basicAssetLibraries]
})
@ -508,6 +511,7 @@ export class CollectionToolsExamineeComponent implements OnInit {
this.canvas.on("select",obj=>{
//选中素材属性注入函数
this.setAssetsProperty(obj.assetData)
})
// 监听canvas组件取消选中素材事件
this.canvas.on("deselect",obj=>{
@ -515,6 +519,7 @@ export class CollectionToolsExamineeComponent implements OnInit {
})
// 监听canvas组件新增素材事件
this.canvas.on("createIcon",obj=>{
console.log(obj.assetData)
// this.renovateTreeData(false)
})
// 监听canvas组件删除素材事件
@ -1076,7 +1081,8 @@ export class CollectionToolsExamineeComponent implements OnInit {
let examParams = {
sitePlanId : e.id,
examinationId : this.route.snapshot.queryParams.examId
examinationId : this.route.snapshot.queryParams.examId,
planComponentId : this.route.snapshot.queryParams.planComponentId
}
this.http.get('/api/ExamSitePlanData',{params:examParams}).subscribe((data:any)=>{
console.log("cnm1",data)
@ -1098,7 +1104,8 @@ export class CollectionToolsExamineeComponent implements OnInit {
this.canvasData.originaleveryStoreyData.buildingAreaId? null : this.canvasData.originaleveryStoreyData.buildingAreaId = e.id || null
let examParams = {
buildingAreaId : e.id,
examinationId : this.route.snapshot.queryParams.examId
examinationId : this.route.snapshot.queryParams.examId,
planComponentId : this.route.snapshot.queryParams.planComponentId
}
this.http.get('/api/ExamBuildingAreaData',{params:examParams}).subscribe((data:any)=>{
console.log("cnm2",data)
@ -1430,6 +1437,7 @@ export class CollectionToolsExamineeComponent implements OnInit {
//点击选中素材库图片时
selectImg (item,items,index) {
console.log(66666666,items)
this.selectLibrary = item.name
this.selectImage = items
this.selectImageIndex = index

Loading…
Cancel
Save