修改三维课程大铁考试数据结构

This commit is contained in:
sunzhenyu 2021-09-18 18:01:53 +08:00
parent fdd2701512
commit d92906d7d5
3 changed files with 509 additions and 439 deletions

View File

@ -326,13 +326,9 @@ export function ControlManager(dom,scene,lessonData,lessonIndex) {
var intersects = raycaster.intersectObject( modelManager.otherModel.children[1],true);
if(intersects.length>0){
for(let td=0;td<trainDeviceList.length;td++){
if(trainDeviceList[td].id == intersects[0].object.name){
trainDeviceList[td].color = "#fff";
trainDeviceList[td].value = "已检查";
}
}
jl3dZzwwTrainTestUpdate(intersects[0].object.name);
}
}

View File

@ -3,459 +3,528 @@ export function ZzwwTrain() {
let scope = this;
this.deviceList = [
{
id:"ZLQ",
name:"止轮器",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"防溜防护检查",
text:"",
devices:[
{
id:"ZLQ",
name:"止轮器",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"FD",
name:"风笛",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆端部检查(前端)",
text:"",
devices:[
{
id:"FD",
name:"风笛",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"SDD",
name:"上大灯",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"XDD",
name:"下大灯",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"YGQ",
name:"雨刮器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"DFBL",
name:"挡风玻璃",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"BYC",
name:"百叶窗",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"DCFS",
name:"调车扶手",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"XTB",
name:"下踏板",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"SD",
name:"上灯",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆端部检查(前端)",
text:"",
devices:[
{
id:"CG",
name:"车钩",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"GS",
name:"钩舌",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"SDD",
name:"上大灯",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆端部检查(前端)",
text:"",
devices:[
{
id:"ZJSM",
name:"折角塞门",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZDGRG",
name:"制动管软管",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"XDD",
name:"下大灯",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆端部检查(前端)",
text:"",
devices:[
{
id:"FCD",
name:"防尘堵",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"AQL",
name:"安全链",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"YGQ",
name:"雨X刮器",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆端部检查(前端)",
text:"",
devices:[
{
id:"PZQ",
name:"排障器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"SSQ",
name:"扫石器",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"DFBL",
name:"挡风玻璃",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"左前部",
text:"",
devices:[
{
id:"ZJF",
name:"中继阀",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZYFG",
name:"作用风缸",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZDSM",
name:"制动塞门",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"JCXHCGQ",
name:"信号传感器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"TJ",
name:"托架",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"KYJ",
name:"空压机",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"KYJPD",
name:"空压机皮带",
color:"#ff0000",
status:"",
value:"未检查",
}
// ,
// {
// id:"PDYL",
// name:"皮带压轮",
// color:"#ff0000",
// status:"",
// value:"未检查",
// }
]
},
{
id:"BYC",
name:"百叶窗",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"转向架左侧",
text:"",
devices:[
{
id:"ZXTH",
name:"轴箱弹簧",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZXDG",
name:"轴箱端盖",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"YYJZQ",
name:"液压减震器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CL",
name:"车轮踏面",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"DCFS",
name:"调车扶手",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"转向架左侧",
text:"",
devices:[
{
id:"QYZ",
name:"牵引座",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"QYG",
name:"牵引杆",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"GB",
name:"拐臂",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"XTB",
name:"下踏板",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"转向架左侧",
text:"",
devices:[
{
id:"SDCGQ",
name:"速度传感器",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"CG",
name:"车钩",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"转向架左侧",
text:"",
devices:[
{
id:"ZDG",
name:"制动缸",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZW",
name:"闸瓦",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZWT",
name:"闸瓦托",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZWTZG",
name:"闸瓦调整杆",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"GS",
name:"钩舌",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆中部(左侧)",
text:"",
devices:[
{
id:"RYX",
name:"燃油箱",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"XDCX",
name:"蓄电池箱",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"CG1",
name:"车钩",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"左侧后部",
text:"",
devices:[
{
id:"RLZDJAZZ",
name:"人力制动机",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"ZJSM",
name:"折角塞门",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆(右侧)",
text:"",
devices:[
{
id:"ZFG",
name:"总风缸",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZFGSM",
name:"总风缸塞门",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"XYQ",
name:"消音器",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"ZDGRG",
name:"制动管软管",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"右前部",
text:"",
devices:[
{
id:"KLQ",
name:"空滤器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"JCXHCGQ",
name:"信号传感器",
color:"#ff0000",
status:"",
value:"未检查",
},
]
},
{
id:"ZDGRG1",
name:"制动管软管",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆底部检查",
text:"",
devices:[
{
id:"GWS",
name:"钩尾销",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"BSX",
name:"变速箱",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"FDJ",
name:"发动机",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CL",
name:"车轮",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CZ",
name:"车轴",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CDZ",
name:"传动轴",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CZCLX",
name:"车轴齿轮箱",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"FCD",
name:"防尘堵",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆底部检查",
text:"",
devices: [
{
id:"FLP",
name:"法兰盘",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"AQL",
name:"安全链",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车辆底部检查",
text:"",
devices:[
{
id:"ZJHXX",
name:"中间换向箱",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"GDZ",
name:"固定轴",
color:"#ff0000",
status:"",
value:"未检查",
}
]
},
{
id:"AQL1",
name:"安全链",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"PZQ",
name:"排障器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"PZQ1",
name:"排障器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"PSQ",
name:"排石器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"PSQ1",
name:"排石器1",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZJF",
name:"中继阀",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZYFG",
name:"作用风缸",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZDSM",
name:"制动塞门",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"",
name:"",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZDSM1",
name:"制动塞门",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"JCXHCGQ",
name:"信号传感器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"TJ",
name:"托架",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"KYJ",
name:"空压机",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"KYJPD",
name:"空压机皮带",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"PDYL",
name:"皮带压轮",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZXTH",
name:"轴箱弹簧",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZXDG",
name:"轴箱端盖",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"YYJZQ",
name:"液压减震器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CLTM",
name:"车轮踏面",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"QYZ",
name:"牵引座",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"QYG",
name:"牵引杆",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"GB",
name:"拐臂",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"SDCGQ",
name:"速度传感器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZDG",
name:"制动缸",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZW",
name:"闸瓦",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZWT",
name:"闸瓦托",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZWTZG",
name:"闸瓦调整杆",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"RYX",
name:"燃油箱",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"YW",
name:"油位",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"XDCX",
name:"蓄电池箱",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"RLZDJAZZ",
name:"人力制动机",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZFG",
name:"总风缸",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"XYQ",
name:"消音器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"JCXHCGQ1",
name:"信号传感器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"KLQ",
name:"空滤器",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"GWS",
name:"钩尾销",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"FDJ",
name:"发动机",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CL",
name:"车轮",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CZ",
name:"车轴",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CDZ",
name:"传动轴",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CZCLX",
name:"车轴齿轮箱",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CZCLX1",
name:"车轴齿轮箱1",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"ZJHXX",
name:"中间换向箱",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"GDZ",
name:"固定轴",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CC",
name:"车窗",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CM",
name:"车门",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"BPX",
name:"备品箱",
color:"#ff0000",
status:"",
value:"未检查",
tittle:"车上检查",
text:"",
devices:[
{
id:"CC",
name:"车窗",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"CM",
name:"车门",
color:"#ff0000",
status:"",
value:"未检查",
},
{
id:"BPX",
name:"备品箱",
color:"#ff0000",
status:"",
value:"未检查",
}
]
}
];
}

View File

@ -2,12 +2,10 @@
<div class="traintestpaneover" :style="{'background-image': 'url('+lessonbg+')'}">
<div class="traintesttittle"> 待检查设备:</div>
<div class="addtraintestdivs" :style="{'color':item.color}" v-for="(item,index) in trainDeviceData.deviceList" @click="selsectTrainDevice(item)">
<div class="addtraintestdivs" :style="{'color':item.color}" v-for="(item,index) in trainDeviceData.deviceList[testIndex].devices" @click="selsectTrainDevice(item)">
{{item.name}}:{{item.value}}
</div>
<!-- <div class="addtraintestdiv"
:style="{'background-image': 'url('+localstatic+'/lesson3d/addbutton.png)'}"
@click="addjob(index)"></div> -->
</div>
</template>
@ -28,6 +26,7 @@
data() {
return {
localstatic:JL3D_LOCAL_STATIC,
testIndex:0,
jobList:[],
showJobList:false,
showJob:false,
@ -45,6 +44,7 @@
},
mounted() {
// this.initJobList();
window.jl3dZzwwTrainTestUpdate = this.jl3dZzwwTrainTestUpdate;
},
beforeDestroy() {
@ -63,19 +63,24 @@
initJobList(data){
this.jobList = data;
},
selectJob(item){
this.selectedJob = item;
jl3dZzwwTrainTestUpdate(upname){
let nextText = true;
console.log(upname);
for(let td=0;td<this.trainDeviceData.deviceList[this.testIndex].devices.length;td++){
},
addjob(index){
this.selectedJob.controlList[index].data.push({
cname:this.generateUUID(),
text:"内容",
explainRole:"角色",
nextNode:"null",
sceneId:this.lessonData.lessonData.lessonProgress[this.lessonEditIndex].id,
type:"",
});
if(this.trainDeviceData.deviceList[this.testIndex].devices[td].id == upname){
this.trainDeviceData.deviceList[this.testIndex].devices[td].color = "#fff";
this.trainDeviceData.deviceList[this.testIndex].devices[td].value = "已检查";
}
if(this.trainDeviceData.deviceList[this.testIndex].devices[td].color != "#fff"){
nextText = false;
}
}
if(nextText && this.testIndex<=this.trainDeviceData.deviceList.length){
this.testIndex += 1;
}
},
selsectTrainDevice(selectTool,jobList){