From 71adf3179af944addaeb34d45985fb044e5cef27 Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@63.com>
Date: 星期三, 06 四月 2022 09:07:26 +0800
Subject: [PATCH] #
---
static/js/app.js | 15 +++----
static/js/data/Asrs.js | 30 ++++++++++----
static/js/data/ConveyData.js | 48 ++++++++++++------------
static/js/object/ObjectSelect.js | 1
static/js/object/StoreConvey.js | 1
5 files changed, 53 insertions(+), 42 deletions(-)
diff --git a/static/js/app.js b/static/js/app.js
index 0520b6a..8abe956 100644
--- a/static/js/app.js
+++ b/static/js/app.js
@@ -72,6 +72,7 @@
this.stats.end();
this.queryCrn();
this.crnMove();
+ this.staMove()
}
this.initScene = function () {
this.scene = new THREE.Scene();
@@ -356,20 +357,16 @@
}
}
}
- this.getExistedGoodType=function(state){
- for (let i=0;i<this.goodTypes.length;i++) {
- let type=this.goodTypes[i];
- if(type.type===state) {
- return type.object;
- }
- }
- return null;
- }
this.crnMove = function (object) {
for (let crnTask of this.crnTasks) {
crnTask.move();
}
}
+ this.staMove = function (object) {
+ // for (let crnTask of this.crnTasks) {
+ // crnTask.move();
+ // }
+ }
// 鍔熻兘鏂规硶鍖�
this.changeStats = function () {
diff --git a/static/js/data/Asrs.js b/static/js/data/Asrs.js
index 8e0cf56..ed54974 100644
--- a/static/js/data/Asrs.js
+++ b/static/js/data/Asrs.js
@@ -3,7 +3,22 @@
setInterval(function () {
queryCrnCurrent();
+ queryStaCurrent();
},1000);
+
+var Store3DData;
+function initStore() {
+ $.ajax({
+ // url: 'http://47.97.1.152:58080/jkwcs/three/init/store/v1',
+ url: 'http://localhost:9090/jkwcs/three/init/store/v1',
+ type: "POST",
+ data: {},
+ // async: false,
+ success: function (res) {
+ Store3DData = res;
+ }
+ })
+}
var CrnDatas = null;
function queryCrnCurrent() {
@@ -18,18 +33,15 @@
})
}
-var Store3DData;
-function initStore() {
+var StaDatas = null;
+function queryStaCurrent() {
$.ajax({
- // url: 'http://47.97.1.152:58080/jkwcs/three/init/store/v1',
- url: 'http://localhost:9090/jkwcs/three/init/store/v1',
- type: "POST",
+ // url: 'http://47.97.1.152:58080/jkwcs/three/query/crn/cache/v1',
+ url: 'http://localhost:9090/jkwcs/three/query/sta/cache/v1',
+ type: "GET",
data: {},
- // async: false,
success: function (res) {
- Store3DData = res;
+ StaDatas = res.data;
}
})
-
}
-
diff --git a/static/js/data/ConveyData.js b/static/js/data/ConveyData.js
index cf871b6..6b228db 100644
--- a/static/js/data/ConveyData.js
+++ b/static/js/data/ConveyData.js
@@ -2,7 +2,7 @@
objects: [
// 閾炬潯杈撻�佹満 1F 绗�1鍒� --------------------------------------------------------------------------------------------
{
- no: '1',
+ no: '123',
objectType: 'chain',
position: {
x: 48 + 57,
@@ -10,7 +10,7 @@
}
},
{
- no: '1',
+ no: '122',
objectType: 'chain',
position: {
x: 48 + 146,
@@ -18,7 +18,7 @@
}
},
{
- no: '1',
+ no: '121',
objectType: 'chain',
position: {
x: 48 + 287,
@@ -26,7 +26,7 @@
}
},
{
- no: '1',
+ no: '120',
objectType: 'chain',
position: {
x: 48 + 376,
@@ -34,7 +34,7 @@
}
},
{
- no: '1',
+ no: '119',
objectType: 'chain',
position: {
x: 48 + 517,
@@ -42,7 +42,7 @@
}
},
{
- no: '1',
+ no: '118',
objectType: 'chain',
position: {
x: 48 + 606,
@@ -50,7 +50,7 @@
}
},
{
- no: '1',
+ no: '117',
objectType: 'chain',
position: {
x: 48 + 747,
@@ -58,7 +58,7 @@
}
},
{
- no: '1',
+ no: '116',
objectType: 'chain',
position: {
x: 48 + 836,
@@ -66,7 +66,7 @@
}
},
{
- no: '1',
+ no: '115',
objectType: 'chain',
position: {
x: 48 + 977,
@@ -74,7 +74,7 @@
}
},
{
- no: '1',
+ no: '114',
objectType: 'chain',
position: {
x: 48 + 1066,
@@ -82,7 +82,7 @@
}
},
{
- no: '1',
+ no: '113',
objectType: 'chain',
position: {
x: 48 + 1207,
@@ -90,7 +90,7 @@
}
},
{
- no: '1',
+ no: '112',
objectType: 'chain',
position: {
x: 48 + 1296,
@@ -98,7 +98,7 @@
}
},
{
- no: '1',
+ no: '111',
objectType: 'chain',
position: {
x: 48 + 1437,
@@ -106,7 +106,7 @@
}
},
{
- no: '1',
+ no: '110',
objectType: 'chain',
position: {
x: 48 + 1526,
@@ -114,7 +114,7 @@
}
},
{
- no: '1',
+ no: '109',
objectType: 'chain',
position: {
x: 48 + 1667,
@@ -122,7 +122,7 @@
}
},
{
- no: '1',
+ no: '108',
objectType: 'chain',
position: {
x: 48 + 1756,
@@ -130,7 +130,7 @@
}
},
{
- no: '1',
+ no: '107',
objectType: 'chain',
position: {
x: 48 + 1897,
@@ -138,7 +138,7 @@
}
},
{
- no: '1',
+ no: '106',
objectType: 'chain',
position: {
x: 48 + 1986,
@@ -146,7 +146,7 @@
}
},
{
- no: '1',
+ no: '105',
objectType: 'chain',
position: {
x: 48 + 2127,
@@ -154,7 +154,7 @@
}
},
{
- no: '1',
+ no: '104',
objectType: 'chain',
position: {
x: 48 + 2216,
@@ -162,7 +162,7 @@
}
},
{
- no: '1',
+ no: '103',
objectType: 'chain',
position: {
x: 48 + 2357,
@@ -170,7 +170,7 @@
}
},
{
- no: '1',
+ no: '102',
objectType: 'chain',
position: {
x: 48 + 2446,
@@ -178,7 +178,7 @@
}
},
{
- no: '1',
+ no: '101',
objectType: 'chain',
position: {
x: 48 + 2587,
@@ -186,7 +186,7 @@
}
},
{
- no: '1',
+ no: '100',
objectType: 'chain',
position: {
x: 48 + 2676,
diff --git a/static/js/object/ObjectSelect.js b/static/js/object/ObjectSelect.js
index 83cc006..1c03e22 100644
--- a/static/js/object/ObjectSelect.js
+++ b/static/js/object/ObjectSelect.js
@@ -1,3 +1,4 @@
+
function ObjectSelect(_scene, _camera,outlinePass) {
var raycaster = new THREE.Raycaster();
var mouse = new THREE.Vector2();
diff --git a/static/js/object/StoreConvey.js b/static/js/object/StoreConvey.js
index 5228fab..e844b24 100644
--- a/static/js/object/StoreConvey.js
+++ b/static/js/object/StoreConvey.js
@@ -91,6 +91,7 @@
let positionZ = info.position.z || 0;
let rotateY = info.rotateY || 0;
+ clone.name = info.no + "-sta";
clone.position.x = 0 + positionX;
clone.position.y = 0 + positionY;
clone.position.z = 0 + positionZ;
--
Gitblit v1.9.1