待处理检验订单模块修改

earthstar-new
Mr.Dong 2025-02-12 11:48:44 +08:00
parent b258cfe73d
commit 22bf3f8327
10 changed files with 112 additions and 60 deletions

View File

@ -26,6 +26,7 @@ export function getProductMetaMsg(data) {
return realityRequest({
url: "common/getMetadataInfo",
method: "post",
headers: { "Content-Type": "application/json" },
data
});
}
@ -56,6 +57,16 @@ export function getProductMsg(data) {
});
}
export function getOrderAndProduct(data) {
return microwaveRequest({
url: "validationOrder/getOrderAndProduct",
method: "post",
headers: { "Content-Type": "application/json" },
data
});
}
//更新订单编辑状态
export function updateOrderStatus(orderId) {
return microwaveRequest({

View File

@ -851,13 +851,13 @@ export default {
}
},
flyToThePro(tifPath) {
getProductMetaMsg(qs.stringify({ dataPath: tifPath })).then((res) => {
getProductMetaMsg(JSON.stringify({ dataPath: tifPath })).then((res) => {
if (res !== null) {
cu.flyToLayerRect(
res.boundBoxMinX,
res.boundBoxMinY,
res.boundingBoxMaxX,
res.boundBoxMaxY
res.data.boundBoxMinX,
res.data.boundBoxMinY,
res.data.boundingBoxMaxX,
res.data.boundBoxMaxY
);
}
});

View File

@ -689,11 +689,11 @@ export default {
fileFormat: this.showCKPlan.productMsg.fileFormat,
});
getProductMsg(qs.stringify({ productId: productId })).then((res) => {
if (res || res.length !== 0) {
const r = res[0];
if (res.code == 200) {
const r = res.data[0];
this.productData[0].uploadDate = r.uploadDate;
this.tifPath = r.tifPath;
getProductMetaMsg(qs.stringify({ dataPath: r.tifPath })).then(
getProductMetaMsg(JSON.stringify({ dataPath: r.tifPath })).then(
(res) => {
if (res !== null) {
(this.pData.satellite = this.changeSatName(

View File

@ -26,7 +26,7 @@ class CesiumUtils {
mapMode2D: Cesium.MapMode2D.INFINITE_SCROLL,
imageryProvider: new Cesium.WebMapTileServiceImageryProvider({
url:
"https://{s}.tianditu.gov.cn/img_w/wmts?service=wmts&request=GetTile&version=1.0.0&LAYER=img&tileMatrixSet=w&TileMatrix={TileMatrix}&TileRow={TileRow}&TileCol={TileCol}&style=default&format=tiles&tk=d7648495378ad7ebe74327207dfc09a8",
"https://{s}.tianditu.gov.cn/img_w/wmts?service=wmts&request=GetTile&version=1.0.0&LAYER=img&tileMatrixSet=w&TileMatrix={TileMatrix}&TileRow={TileRow}&TileCol={TileCol}&style=default&format=tiles&tk=f679e73fcff0fa8d9b89dc052c35624b",
layer: "tdtBasicLayer",
style: "default",
maximumLevel: 18,

View File

@ -4,7 +4,7 @@ import { Message } from "element-ui";
// create an axios instance
const service = axios.create({
baseURL: process.env.VUE_APP_MICROWAVE_API, // url = base url + request url
// baseURL: 'http://10.0.31.126:8086/macApi/', // url = base url + request url
// baseURL: 'http://192.168.1.205:8086/macApi/', // url = base url + request url
timeout: 5000000 // request timeout
});

View File

@ -3,8 +3,8 @@ import { Message } from "element-ui";
// create an axios instance
const service = axios.create({
// baseURL: process.env.VUE_APP_BASE_API,
baseURL: "https://caplos.aircas.ac.cn/lxyweb/", // url = base url + request url
baseURL: process.env.VUE_APP_BASE_API,
// baseURL: "https://caplos.aircas.ac.cn/lxyweb/", // url = base url + request url
timeout: 5000000 // request timeout
});

View File

@ -129,22 +129,27 @@ export default {
let routeHerf = null;
switch (key) {
case "/":
routeHerf = `${LXYLOGIN_URL}`;
// routeHerf = `${LXYLOGIN_URL}`;
this.$router.push("/");
break;
case "/daichuli":
routeHerf = `${DAICHULI_URL}`;
// routeHerf = `${DAICHULI_URL}`;
this.$router.push("/daichuli");
break;
case "/yichuli":
routeHerf = `${YICHULI_URL}`;
// routeHerf = `${YICHULI_URL}`;
this.$router.push("/yichuli");
break;
case "/daishenhe":
routeHerf = `${DAISHENHE_URL}`;
// routeHerf = `${DAISHENHE_URL}`;
this.$router.push("/daishenhe");
break;
case "/yishenhe":
routeHerf = `${YISHENHE_URL}`;
// routeHerf = `${YISHENHE_URL}`;
this.$router.push("/yishenhe");
break;
}
window.location.href = routeHerf;
// window.location.href = routeHerf;
},
//
getBreadcrumb() {

View File

@ -150,17 +150,18 @@
</template>
<script>
import cu from "@/lib/cesiumUtils";
//
import {
getOrderMsg,
getPendingProductMsg,
orderFeedback,
updateOrderStage,
getSamplesList,
getUserInfo,
getFeatureMap,
} from "@/api/lang/pendingOrder";
//
import { getOrderAndProduct, getOrderSamples, updateFeature, getProductMetaMsg, orderFeedback } from '@/api/pendingOrder';
import { productSubTypeVal } from "@/lib/contract.js";
import qs from "qs";
import ProductInfo from "../../../components/productInfo/index";
@ -194,6 +195,9 @@ export default {
userName: null,
token: null,
orderId: null,
productId: null,
orderCode: null,
productType: null,
productMsg: "",
pageshow: true,
isShow: false,
@ -274,49 +278,69 @@ export default {
methods: {
async initOrderMsg() {
const self = this;
self.token = this.$route.query.token;
const userMsg = await getUserInfo(self.token);
if (userMsg.code === 200) {
self.userId = userMsg.data.userid;
self.userName = userMsg.data.username;
localStorage.setItem("userId", self.userId);
localStorage.setItem("userName", self.userName);
}
// self.token = this.$route.query.token;
// const userMsg = await getUserInfo(self.token);
// if (userMsg.code === 200) {
// self.userId = userMsg.data.userid;
// self.userName = userMsg.data.username;
// localStorage.setItem("userId", self.userId);
// localStorage.setItem("userName", self.userName);
// }
const orderId = (self.orderId = this.$route.query.orderId);
getOrderMsg(orderId).then((res) => {
const productId = (self.productId = this.$route.query.productId);
const orderCode = (self.orderCode = this.$route.query.orderCode);
console.log(orderId,productId,orderCode);
getOrderAndProduct(JSON.stringify({ productId: Number(productId), orderCode: orderCode })).then((res) => {
function formatFileSize(bytes) {
if (bytes === 0) return '0 B';
const units = ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];
const index = Math.floor(Math.log(bytes) / Math.log(1024));
const size = (bytes / Math.pow(1024, index)).toFixed(2);
return `${size} ${units[index]}`;
}
if (res.code === 200) {
self.orderMsg = res.data;
console.log(res.data,'1231321');
self.productType = res.data.productType;
// const psId = res.data.productSubClassId;
this.getSqlData();
getPendingProductMsg(orderId).then((res) => {
getProductMetaMsg(JSON.stringify({ dataPath: res.data.tifPath })).then((res) => {
if (res.code === 200) {
const pm = (self.productMsg = res.data);
console.log(pm, 'pm');
const om = self.orderMsg;
console.log(om, 'om');
//
self.orderData = [];
self.orderData.push({
orderCode: om.orderCode,
orderSource: om.orderResourceName,
uploadDate: om.createDate,
fileName: pm.fileName,
fileSize: pm.fileSize,
fileFormat: pm.fileFormat,
orderCode: orderCode,
orderSource: this.orderSourceFilter(om.orderResource),
uploadDate: om.uploadDate,
fileName: om.fileName,
fileSize: formatFileSize(om.fileSize),
fileFormat: om.fileFormat,
});
const minLat = parseFloat(Number(pm.minLatitude).toFixed(8));
const maxLat = parseFloat(Number(pm.maxLatitude).toFixed(8));
const minLon = parseFloat(Number(pm.minLongitude).toFixed(8));
const maxLon = parseFloat(Number(pm.maxLongitude).toFixed(8));
console.log(self.orderData, 'self.orderData');
const minLat = parseFloat(Number(pm.boundBoxMinY).toFixed(8));
const maxLat = parseFloat(Number(pm.boundBoxMaxY).toFixed(8));
const minLon = parseFloat(Number(pm.boundBoxMinX).toFixed(8));
const maxLon = parseFloat(Number(pm.boundingBoxMaxX).toFixed(8));
console.log(minLat, maxLat, minLon, maxLon, 'minLat,maxLat,minLon,maxLon');
//
self.formInline = {
satellite: om.satelliteName,
load: om.satelliteLoadName,
producedDate: pm.collectDate,
proLevel: om.productSubClassId == 45 || om.productSubClassId == 51 ? '3' : '5',
producedDate: om.uploadDate,
proLevel: om.productSubclassId == 45 || om.productSubclassId == 51 ? '3' : '5',
resRatio:
pm.productSpaceResolution > 0.01
? pm.productSpaceResolution + "米"
: (pm.productSpaceResolution * 111194.926).toFixed(2) +
pm.imageResolution > 0.01
? pm.imageResolution + "米"
: (pm.imageResolution * 111194.926).toFixed(2) +
"米",
coordinateSys: pm.coordinateSystem,
minLat: minLat,
@ -326,19 +350,19 @@ export default {
};
sessionStorage.setItem('metaDataId', pm.metaDataId)
// geoserver
const geoWS = pm.geoWorkspace;
const geoLN = pm.geoLayerName;
const geoWS = om.geoWorkspace;
const geoLN = om.layerName;
this.workSpace = geoWS;
this.layerName = geoLN;
cu.addlayer(geoWS, geoLN);
cu.flyToLayerRect(minLon, minLat, maxLon, maxLat);
const proSubId = om.productSubClassId;
//
if (proSubId === 39) {
self.groudClassShow = true;
document.cookie = 'KJInspect-Token=' + self.token
getFeatureMap(self.userId, orderId, self.token).then(res => {
updateFeature(self.userId, orderId, self.token).then(res => {
if (res.code == 200) {
const rd = res.dataList;
const gda = []
@ -360,6 +384,15 @@ export default {
}
});
},
//🐍
orderSourceFilter(orderSource) {
const orderSourceMap = {
0: '用户上传',
1: '历史上传',
2: '平台共享'
}
return orderSourceMap[orderSource]
},
inspection() {
let param = {
userId: this.userId,
@ -456,10 +489,10 @@ export default {
},
//
getSqlData() {
const psid = this.orderMsg.productSubClassId;
getSamplesList(this.orderId).then((res) => {
const psid = this.orderMsg.productSubclassId;
getOrderSamples(this.orderId, psid).then((res) => {
if (res.code == 200) {
const sp = res.data.list;
const sp = res.data;
if (sp.length === 0) {
this.$message({
type: "warning",
@ -473,8 +506,8 @@ export default {
}
} else {
for (let i in sp) {
const alt = JSON.parse(sp[i].paramStr).alt;
cu.addPoint(sp[i].lng, sp[i].lat, alt !== "null" ? alt : 10);
const alt = sp[i].alt;
cu.addPoint(sp[i].lon, sp[i].lat, alt !== "null" ? alt : 10);
}
}
}

View File

@ -165,7 +165,10 @@ export default {
//
// 153079 :153086 153087 152945
this.$router.push("/orderUnprocessed?orderId=154090&token=WEB*1719907102702@TY84_ZZX-gxfw001132_4ff8a6f9de7f4d37837ba22354972efb");
console.log(orderMsg,1231232);
// this.$router.push(`/orderUnprocessed?orderId=${orderMsg.id}&token=WEB*1719907102702@TY84_ZZX-gxfw001132_4ff8a6f9de7f4d37837ba22354972efb`);
this.$router.push(`/orderUnprocessed?productId=${orderMsg.product_upload_id}&orderId=${orderMsg.id}&orderCode=${orderMsg.order_code}`);
},
},
};

View File

@ -22,7 +22,7 @@ module.exports = {
open: false,
proxy: {
[process.env.VUE_APP_BASE_API]: {
target: "http://124.16.188.131:28030",
target: "http://192.168.1.205:8086",
changeOrigin: true,
pathRewrite: {
["^" + process.env.VUE_APP_BASE_API]: ""