|
|
|
@ -3,7 +3,7 @@
|
|
|
|
<a-layout style="width: 1500px">
|
|
|
|
<a-layout style="width: 1500px">
|
|
|
|
<a-layout style="width: 100%;height: 310px">
|
|
|
|
<a-layout style="width: 100%;height: 310px">
|
|
|
|
<a-layout-sider width="110px">
|
|
|
|
<a-layout-sider width="110px">
|
|
|
|
<a-tabs default-active-key="1" tab-position="left" @change="changeTabLeft" v-if="total.row > nums.row">
|
|
|
|
<a-tabs :activeKey="this.select.row" tab-position="left" @change="changeTabLeft" v-if="total.row > nums.row">
|
|
|
|
<a-tab-pane
|
|
|
|
<a-tab-pane
|
|
|
|
v-for="index in latticeRow"
|
|
|
|
v-for="index in latticeRow"
|
|
|
|
:key="index"
|
|
|
|
:key="index"
|
|
|
|
@ -39,10 +39,11 @@
|
|
|
|
</a-layout>
|
|
|
|
</a-layout>
|
|
|
|
<a-layout-footer>
|
|
|
|
<a-layout-footer>
|
|
|
|
<!-- <a-tabs default-active-key="1" tab-position="bottom" @change="value => select.row = value" v-if="total.row > nums.row"> -->
|
|
|
|
<!-- <a-tabs default-active-key="1" tab-position="bottom" @change="value => select.row = value" v-if="total.row > nums.row"> -->
|
|
|
|
<a-tabs default-active-key="1" tab-position="bottom" @change="changeTab" v-if="total.column > nums.column">
|
|
|
|
<a-tabs :activeKey="this.select.column" tab-position="bottom" @change="changeTab" v-if="total.column > nums.column">
|
|
|
|
<a-tab-pane
|
|
|
|
<a-tab-pane
|
|
|
|
v-for="index in latticeColumn"
|
|
|
|
v-for="index in latticeColumn"
|
|
|
|
:key="index"
|
|
|
|
:key="index"
|
|
|
|
|
|
|
|
|
|
|
|
>
|
|
|
|
>
|
|
|
|
<span slot="tab">
|
|
|
|
<span slot="tab">
|
|
|
|
{{ getRandom(index, latticeColumn, nums.column, total.column) }}
|
|
|
|
{{ getRandom(index, latticeColumn, nums.column, total.column) }}
|
|
|
|
@ -156,7 +157,7 @@ export default {
|
|
|
|
row: {},
|
|
|
|
row: {},
|
|
|
|
column: {}
|
|
|
|
column: {}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
timer: null
|
|
|
|
timer: null,
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
mounted() {
|
|
|
|
mounted() {
|
|
|
|
@ -180,7 +181,21 @@ export default {
|
|
|
|
this.timer = null;
|
|
|
|
this.timer = null;
|
|
|
|
},
|
|
|
|
},
|
|
|
|
created() {
|
|
|
|
created() {
|
|
|
|
|
|
|
|
var nameEQC = "s"+this.streetId+"d"+this.direction+"e"+this.side + "c" + "=";
|
|
|
|
|
|
|
|
var nameEQR = "s"+this.streetId+"d"+this.direction+"e"+this.side + "r" + "=";
|
|
|
|
|
|
|
|
var ca = document.cookie.split(';');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
for(var i=0;i < ca.length;i++) {
|
|
|
|
|
|
|
|
var c = ca[i];
|
|
|
|
|
|
|
|
while (c.charAt(0)==' ') c = c.substring(1,c.length);
|
|
|
|
|
|
|
|
if (c.indexOf(nameEQC) == 0) {
|
|
|
|
|
|
|
|
this.select.column = Number(c.substring(nameEQC.length,c.length));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
if (c.indexOf(nameEQR) == 0) {
|
|
|
|
|
|
|
|
this.select.row = Number(c.substring(nameEQR.length,c.length));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
},
|
|
|
|
},
|
|
|
|
destroyed() {
|
|
|
|
destroyed() {
|
|
|
|
window.clearInterval(this.timer);
|
|
|
|
window.clearInterval(this.timer);
|
|
|
|
@ -189,10 +204,15 @@ export default {
|
|
|
|
|
|
|
|
|
|
|
|
methods: {
|
|
|
|
methods: {
|
|
|
|
changeTab(value){
|
|
|
|
changeTab(value){
|
|
|
|
|
|
|
|
document.cookie = "s"+this.streetId+"d"+this.direction+"e"+this.side + "c"+ "=" +value;
|
|
|
|
|
|
|
|
|
|
|
|
this.select.column = value
|
|
|
|
this.select.column = value
|
|
|
|
this.getStatus()
|
|
|
|
this.getStatus()
|
|
|
|
},
|
|
|
|
},
|
|
|
|
changeTabLeft(value){
|
|
|
|
changeTabLeft(value){
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
document.cookie = "s"+this.streetId+"d"+this.direction+"e"+this.side + "r" + "=" +value;
|
|
|
|
|
|
|
|
|
|
|
|
this.select.row = value
|
|
|
|
this.select.row = value
|
|
|
|
this.getStatus()
|
|
|
|
this.getStatus()
|
|
|
|
|
|
|
|
|
|
|
|
@ -207,6 +227,7 @@ export default {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
// 获取行和列的范围数组
|
|
|
|
// 获取行和列的范围数组
|
|
|
|
getRandomRow(val) {
|
|
|
|
getRandomRow(val) {
|
|
|
|
|
|
|
|
console.log(" "+this.latticeRow);
|
|
|
|
console.log(this.latticeRow + 1 - val, this.latticeRow, this.nums.row, this.total.row)
|
|
|
|
console.log(this.latticeRow + 1 - val, this.latticeRow, this.nums.row, this.total.row)
|
|
|
|
return this.getRandom(this.latticeRow + 1 - val, this.latticeRow, this.nums.row, this.total.row).split(' - ').map(item => Number(item));
|
|
|
|
return this.getRandom(this.latticeRow + 1 - val, this.latticeRow, this.nums.row, this.total.row).split(' - ').map(item => Number(item));
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|