|
@@ -212,6 +212,7 @@ import {
|
|
midpoint,
|
|
midpoint,
|
|
difference,
|
|
difference,
|
|
} from "@turf/turf";
|
|
} from "@turf/turf";
|
|
|
|
+// import html2canvas from "html2canvas";
|
|
import { getJZDJWord, getWord } from "@/api/zt/ztApi.js";
|
|
import { getJZDJWord, getWord } from "@/api/zt/ztApi.js";
|
|
export default {
|
|
export default {
|
|
data() {
|
|
data() {
|
|
@@ -286,6 +287,21 @@ export default {
|
|
await this.CalculateAnalysisArea();
|
|
await this.CalculateAnalysisArea();
|
|
await this.getGYLandOwnership();
|
|
await this.getGYLandOwnership();
|
|
await this.getJTLandOwnership();
|
|
await this.getJTLandOwnership();
|
|
|
|
+ let entitys = [];
|
|
|
|
+ if (viewer.entities.getById("HZFW")) {
|
|
|
|
+ entitys.push(viewer.entities.getById("HZFW"));
|
|
|
|
+ }
|
|
|
|
+ this.LayerData.GYData.forEach((GYData) => {
|
|
|
|
+ if (viewer.entities.getById(GYData.id)) {
|
|
|
|
+ entitys.push(viewer.entities.getById(GYData.id));
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ this.LayerData.JTData.forEach((JTData) => {
|
|
|
|
+ if (viewer.entities.getById(JTData.id)) {
|
|
|
|
+ entitys.push(viewer.entities.getById(JTData.id));
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ viewer.flyTo(entitys);
|
|
await this.CalculateJZDJ();
|
|
await this.CalculateJZDJ();
|
|
// await this.getGHDK();
|
|
// await this.getGHDK();
|
|
// await this.getJZDJ();
|
|
// await this.getJZDJ();
|
|
@@ -495,8 +511,13 @@ export default {
|
|
}
|
|
}
|
|
});
|
|
});
|
|
});
|
|
});
|
|
|
|
+
|
|
that.gyjtzdj();
|
|
that.gyjtzdj();
|
|
- that.setFXBG();
|
|
|
|
|
|
+
|
|
|
|
+ setTimeout(function () {
|
|
|
|
+ that.setFXBG();
|
|
|
|
+ }, 4000); // 这里的3000毫秒等于3秒
|
|
|
|
+
|
|
debugger;
|
|
debugger;
|
|
} else {
|
|
} else {
|
|
this.$message.error("未配置当前土地用途,请联系管理员添加");
|
|
this.$message.error("未配置当前土地用途,请联系管理员添加");
|
|
@@ -786,98 +807,107 @@ export default {
|
|
* 生成报告
|
|
* 生成报告
|
|
*/
|
|
*/
|
|
async setFXBG() {
|
|
async setFXBG() {
|
|
- let data = {
|
|
|
|
- projectName: this.info.BenchmarkLandPrice.ProjectName, //项目名称
|
|
|
|
- analysisDate: moment(new Date()).format("YYYY-MM-DD HH:mm:ss"), //分析时间
|
|
|
|
- projectType: this.info.BenchmarkLandPrice.ProjectType, //项目类型
|
|
|
|
- buildUnit: this.info.BenchmarkLandPrice.ConstructionUnit, //建设单位
|
|
|
|
- analysisArea: this.formData.fxzmj, //分析面积(平方米)
|
|
|
|
- totalLandPrice: this.formData.zdj, //总地价(万元) 国有+集体 总地价预估合计
|
|
|
|
- areaSCL: 0, //国有建设用地面积(平方米) 国有 土地面积合计
|
|
|
|
- baseLandPriceSCL: 0, //国有建设用地基准地价(万元)
|
|
|
|
- areaCCL: 0, //集体建设用地面积(平方米) 集体 土地面积合计
|
|
|
|
- baseLandPriceCCL: 0, //集体建设用地基准地价(万元)
|
|
|
|
- picList: [], //图片集 分析范围
|
|
|
|
- definitionBLP: this.jzdj_LandUse, //报告类型名称
|
|
|
|
- totalArea: 0, //国有+集体土地面积合计 平方米 tableList01 土地面积 + tableList01土地面积
|
|
|
|
- landPriceESCL: 0, //国有土地地价预估 万元 国有 总地价预估合计 tableList01 总地价预估 累加
|
|
|
|
- landPriceECCL: 0, // 集体土地地价预估 万元 集体 总地价预估合计 tableList02 总地价预估 累加
|
|
|
|
- tableList01: [], //国有建设用地
|
|
|
|
- tableList02: [], //集体建设用地
|
|
|
|
- };
|
|
|
|
- debugger;
|
|
|
|
- this.LayerData.GYData.forEach((gyelement) => {
|
|
|
|
- gyelement.fromData.forEach((element) => {
|
|
|
|
- data.totalArea += element.area;
|
|
|
|
- data.baseLandPriceSCL += element.zdj;
|
|
|
|
- data.areaSCL += element.area;
|
|
|
|
- data.landPriceESCL += element.zdj;
|
|
|
|
- data.tableList01.push({
|
|
|
|
- lv: element.tdjb,
|
|
|
|
- landPrice: Number((element.dj * 666.67).toFixed(2)),
|
|
|
|
- area: Number((element.area / 666.67).toFixed(2)),
|
|
|
|
- landPriceES: Number((element.zdj / 10000).toFixed(2)),
|
|
|
|
|
|
+ let that = this;
|
|
|
|
+ var promise = scene.outputSceneToFile();
|
|
|
|
+ // html2canvas(document.getElementById("cesiumContainer")).then(
|
|
|
|
+ Cesium.when(promise, async function (canvas) {
|
|
|
|
+ // 将canvas转换为base64图片
|
|
|
|
+ // let imageBase64 = canvas.toDataURL("image/jpeg");
|
|
|
|
+ let imageBase64 = canvas;
|
|
|
|
+ debugger;
|
|
|
|
+ let data = {
|
|
|
|
+ projectName: that.info.BenchmarkLandPrice.ProjectName, //项目名称
|
|
|
|
+ analysisDate: moment(new Date()).format("YYYY-MM-DD HH:mm:ss"), //分析时间
|
|
|
|
+ projectType: that.info.BenchmarkLandPrice.ProjectType, //项目类型
|
|
|
|
+ buildUnit: that.info.BenchmarkLandPrice.ConstructionUnit, //建设单位
|
|
|
|
+ analysisArea: that.formData.fxzmj, //分析面积(平方米)
|
|
|
|
+ totalLandPrice: that.formData.zdj, //总地价(万元) 国有+集体 总地价预估合计
|
|
|
|
+ areaSCL: 0, //国有建设用地面积(平方米) 国有 土地面积合计
|
|
|
|
+ baseLandPriceSCL: 0, //国有建设用地基准地价(万元)
|
|
|
|
+ areaCCL: 0, //集体建设用地面积(平方米) 集体 土地面积合计
|
|
|
|
+ baseLandPriceCCL: 0, //集体建设用地基准地价(万元)
|
|
|
|
+ picBase64List: [imageBase64], //图片集 分析范围
|
|
|
|
+ definitionBLP: that.jzdj_LandUse, //报告类型名称
|
|
|
|
+ totalArea: 0, //国有+集体土地面积合计 平方米 tableList01 土地面积 + tableList01土地面积
|
|
|
|
+ landPriceESCL: 0, //国有土地地价预估 万元 国有 总地价预估合计 tableList01 总地价预估 累加
|
|
|
|
+ landPriceECCL: 0, // 集体土地地价预估 万元 集体 总地价预估合计 tableList02 总地价预估 累加
|
|
|
|
+ tableList01: [], //国有建设用地
|
|
|
|
+ tableList02: [], //集体建设用地
|
|
|
|
+ };
|
|
|
|
+ debugger;
|
|
|
|
+ that.LayerData.GYData.forEach((gyelement) => {
|
|
|
|
+ gyelement.fromData.forEach((element) => {
|
|
|
|
+ data.totalArea += element.area;
|
|
|
|
+ data.baseLandPriceSCL += element.zdj;
|
|
|
|
+ data.areaSCL += element.area;
|
|
|
|
+ data.landPriceESCL += element.zdj;
|
|
|
|
+ data.tableList01.push({
|
|
|
|
+ lv: element.tdjb,
|
|
|
|
+ landPrice: Number((element.dj * 666.67).toFixed(2)),
|
|
|
|
+ area: Number((element.area / 666.67).toFixed(2)),
|
|
|
|
+ landPriceES: Number((element.zdj / 10000).toFixed(2)),
|
|
|
|
+ });
|
|
});
|
|
});
|
|
});
|
|
});
|
|
- });
|
|
|
|
- this.LayerData.JTData.forEach((jtelement) => {
|
|
|
|
- jtelement.fromData.forEach((element) => {
|
|
|
|
- data.totalArea += element.area;
|
|
|
|
- data.baseLandPriceCCL += element.zdj;
|
|
|
|
- data.areaCCL += element.area;
|
|
|
|
- data.landPriceECCL += element.zdj;
|
|
|
|
- data.tableList02.push({
|
|
|
|
- lv: element.tdjb,
|
|
|
|
- landPrice: Number((element.dj * 666.67).toFixed(2)),
|
|
|
|
- area: Number((element.area / 666.67).toFixed(2)),
|
|
|
|
- landPriceES: Number((element.zdj / 10000).toFixed(2)),
|
|
|
|
|
|
+ that.LayerData.JTData.forEach((jtelement) => {
|
|
|
|
+ jtelement.fromData.forEach((element) => {
|
|
|
|
+ data.totalArea += element.area;
|
|
|
|
+ data.baseLandPriceCCL += element.zdj;
|
|
|
|
+ data.areaCCL += element.area;
|
|
|
|
+ data.landPriceECCL += element.zdj;
|
|
|
|
+ data.tableList02.push({
|
|
|
|
+ lv: element.tdjb,
|
|
|
|
+ landPrice: Number((element.dj * 666.67).toFixed(2)),
|
|
|
|
+ area: Number((element.area / 666.67).toFixed(2)),
|
|
|
|
+ landPriceES: Number((element.zdj / 10000).toFixed(2)),
|
|
|
|
+ });
|
|
});
|
|
});
|
|
});
|
|
});
|
|
- });
|
|
|
|
- data.analysisArea = Number((data.analysisArea / 666.67).toFixed(2));
|
|
|
|
- data.totalLandPrice = Number((data.totalLandPrice / 10000).toFixed(2));
|
|
|
|
- data.areaSCL = Number((data.areaSCL / 666.67).toFixed(2));
|
|
|
|
- data.areaCCL = Number((data.areaCCL / 666.67).toFixed(2));
|
|
|
|
- data.totalArea = Number((data.totalArea / 666.67).toFixed(2));
|
|
|
|
- data.landPriceESCL = Number((data.landPriceESCL / 10000).toFixed(2));
|
|
|
|
- data.landPriceECCL = Number((data.landPriceECCL / 10000).toFixed(2));
|
|
|
|
- data.baseLandPriceCCL = Number(
|
|
|
|
- (data.baseLandPriceCCL / 10000).toFixed(2)
|
|
|
|
- );
|
|
|
|
- data.baseLandPriceSCL = Number(
|
|
|
|
- (data.baseLandPriceSCL / 10000).toFixed(2)
|
|
|
|
- );
|
|
|
|
- debugger;
|
|
|
|
- let JZDJWordPath = await getJZDJWord(data);
|
|
|
|
- debugger;
|
|
|
|
- if (JZDJWordPath.code == 200) {
|
|
|
|
- this.info.BenchmarkLandPrice.AnalysisStatus = "完成";
|
|
|
|
- this.info.BenchmarkLandPrice.ReportPath = JZDJWordPath.msg;
|
|
|
|
- let BenchmarkLandPrice = window.BenchmarkLandPriceList.find(
|
|
|
|
- (c) => (c.id = this.info.BenchmarkLandPrice.id)
|
|
|
|
|
|
+ data.analysisArea = Number((data.analysisArea / 666.67).toFixed(2));
|
|
|
|
+ data.totalLandPrice = Number((data.totalLandPrice / 10000).toFixed(2));
|
|
|
|
+ data.areaSCL = Number((data.areaSCL / 666.67).toFixed(2));
|
|
|
|
+ data.areaCCL = Number((data.areaCCL / 666.67).toFixed(2));
|
|
|
|
+ data.totalArea = Number((data.totalArea / 666.67).toFixed(2));
|
|
|
|
+ data.landPriceESCL = Number((data.landPriceESCL / 10000).toFixed(2));
|
|
|
|
+ data.landPriceECCL = Number((data.landPriceECCL / 10000).toFixed(2));
|
|
|
|
+ data.baseLandPriceCCL = Number(
|
|
|
|
+ (data.baseLandPriceCCL / 10000).toFixed(2)
|
|
);
|
|
);
|
|
- BenchmarkLandPrice.AnalysisStatus = "完成";
|
|
|
|
- BenchmarkLandPrice.ReportPath = JZDJWordPath.msg;
|
|
|
|
-
|
|
|
|
- // this.$notify({
|
|
|
|
- // title: "成功",
|
|
|
|
- // message:
|
|
|
|
- // this.info.BenchmarkLandPrice.ProjectName + "报告已生成,可下载",
|
|
|
|
- // type: "success",
|
|
|
|
- // });
|
|
|
|
- } else {
|
|
|
|
- this.info.BenchmarkLandPrice.AnalysisStatus = "异常";
|
|
|
|
- let BenchmarkLandPrice = window.BenchmarkLandPriceList.find(
|
|
|
|
- (c) => (c.id = this.info.BenchmarkLandPrice.id)
|
|
|
|
|
|
+ data.baseLandPriceSCL = Number(
|
|
|
|
+ (data.baseLandPriceSCL / 10000).toFixed(2)
|
|
);
|
|
);
|
|
- BenchmarkLandPrice.AnalysisStatus = "异常";
|
|
|
|
- this.$notify.error({
|
|
|
|
- title: "异常",
|
|
|
|
- message:
|
|
|
|
- this.info.BenchmarkLandPrice.ProjectName +
|
|
|
|
- "报告生成异常,请重新选取区域分析",
|
|
|
|
- });
|
|
|
|
- }
|
|
|
|
|
|
+ debugger;
|
|
|
|
+ let JZDJWordPath = await getJZDJWord(data);
|
|
|
|
+ debugger;
|
|
|
|
+ if (JZDJWordPath.code == 200) {
|
|
|
|
+ that.info.BenchmarkLandPrice.AnalysisStatus = "完成";
|
|
|
|
+ that.info.BenchmarkLandPrice.ReportPath = JZDJWordPath.msg;
|
|
|
|
+ let BenchmarkLandPrice = window.BenchmarkLandPriceList.find(
|
|
|
|
+ (c) => (c.id = that.info.BenchmarkLandPrice.id)
|
|
|
|
+ );
|
|
|
|
+ BenchmarkLandPrice.AnalysisStatus = "完成";
|
|
|
|
+ BenchmarkLandPrice.ReportPath = JZDJWordPath.msg;
|
|
|
|
+
|
|
|
|
+ // that.$notify({
|
|
|
|
+ // title: "成功",
|
|
|
|
+ // message:
|
|
|
|
+ // that.info.BenchmarkLandPrice.ProjectName + "报告已生成,可下载",
|
|
|
|
+ // type: "success",
|
|
|
|
+ // });
|
|
|
|
+ } else {
|
|
|
|
+ that.info.BenchmarkLandPrice.AnalysisStatus = "异常";
|
|
|
|
+ let BenchmarkLandPrice = window.BenchmarkLandPriceList.find(
|
|
|
|
+ (c) => (c.id = that.info.BenchmarkLandPrice.id)
|
|
|
|
+ );
|
|
|
|
+ BenchmarkLandPrice.AnalysisStatus = "异常";
|
|
|
|
+ that.$notify.error({
|
|
|
|
+ title: "异常",
|
|
|
|
+ message:
|
|
|
|
+ that.info.BenchmarkLandPrice.ProjectName +
|
|
|
|
+ "报告生成异常,请重新选取区域分析",
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ });
|
|
},
|
|
},
|
|
|
|
|
|
/**
|
|
/**
|