Selaa lähdekoodia

分公有私有及标签

zhangliang2 2 vuotta sitten
vanhempi
commit
fead593709

+ 145 - 90
src/views/systemManagement/sceneLibraryManagement/common/util.less

@@ -1,119 +1,174 @@
-.labelPanel {
-    :last-child {
-        margin-right: 0;
+.labelsBox {
+    b {
+        display: inline-block;
+        line-height: 1;
+        font-weight: 500;
+        white-space: nowrap;
+        vertical-align: middle;
+        background: #fff;
+        border: 1px solid #dcdfe6;
+        -webkit-appearance: none;
+        text-align: center;
+        -webkit-box-sizing: border-box;
+        box-sizing: border-box;
+        outline: 0;
+        // margin-bottom: 10px;
+        margin-right: 20px;
+        position: relative;
+        padding: 12px 20px;
+        font-size: 14px;
+        cursor: pointer;
     }
-}
-
-.labelBox {
-    display: inline-block;
-    line-height: 1;
-    font-weight: 500;
-    white-space: nowrap;
-    vertical-align: middle;
-    background: #fff;
-    border: 1px solid #dcdfe6;
-    -webkit-appearance: none;
-    text-align: center;
-    -webkit-box-sizing: border-box;
-    box-sizing: border-box;
-    outline: 0;
-    margin-bottom: 10px;
-    margin-right: 20px;
-    position: relative;
-    padding: 12px 20px;
-    font-size: 14px;
-}
-
-
-.el-checkbox-button {
-    margin-right: 20px;
-}
-
-.labelA {
 
-    /deep/ .el-checkbox-button__inner,
-    &.labelBox {
+    .labelA {
         border: 1px solid @greenA;
         color: @greenA;
         border-radius: 4px;
         background-color: @greenBgA;
     }
 
-    &.is-checked {
-        /deep/ .el-checkbox-button__inner {
-            color: #FFFFFF;
-            background-color: @greenA;
-            border-color: @greenA;
-        }
-    }
-}
-
-.labelB {
-
-    /deep/ .el-checkbox-button__inner,
-    &.labelBox {
+    .labelB {
         border: 1px solid @orangeA;
         color: @orangeA;
         border-radius: 4px;
         background-color: @orangeBgA;
     }
 
-    &.is-checked {
-        /deep/ .el-checkbox-button__inner {
-            color: #FFFFFF;
-            background-color: @orangeA;
-            border-color: @orangeA;
-        }
-    }
-}
-
-.labelC {
-
-    /deep/ .el-checkbox-button__inner,
-    &.labelBox {
+    .labelC {
         border: 1px solid @lightBlueA;
         color: @lightBlueA;
         border-radius: 4px;
         background-color: @lightBlueBgA;
     }
 
-    &.is-checked {
-        /deep/ .el-checkbox-button__inner {
-            color: #FFFFFF;
-            background-color: @lightBlueA;
-            border-color: @lightBlueA;
-        }
-    }
-}
-
-.labelD {
-
-    /deep/ .el-checkbox-button__inner,
-    &.labelBox {
+    .labelD {
         border: 1px solid @purpleA;
         color: @purpleA;
         border-radius: 4px;
         background-color: @purpleBgA;
     }
-
-    &.is-checked {
-        /deep/ .el-checkbox-button__inner {
-            color: #FFFFFF;
-            background-color: @purpleA;
-            border-color: @purpleA;
-        }
-    }
 }
 
-.videoBox {
-    width: 100%;
-    padding: 30 60px;
 
-    video {
-        width: 100%;
-    }
-}
 
-.btnsPanel {
-    margin: 45px 40px 15px;
-}
+
+
+// .labelPanel {
+//     :last-child {
+//         margin-right: 0;
+//     }
+// }
+
+// .labelBox {
+//     display: inline-block;
+//     line-height: 1;
+//     font-weight: 500;
+//     white-space: nowrap;
+//     vertical-align: middle;
+//     background: #fff;
+//     border: 1px solid #dcdfe6;
+//     -webkit-appearance: none;
+//     text-align: center;
+//     -webkit-box-sizing: border-box;
+//     box-sizing: border-box;
+//     outline: 0;
+//     margin-bottom: 10px;
+//     margin-right: 20px;
+//     position: relative;
+//     padding: 12px 20px;
+//     font-size: 14px;
+// }
+
+
+// .el-checkbox-button {
+//     margin-right: 20px;
+// }
+
+// .labelA {
+
+//     /deep/ .el-checkbox-button__inner,
+//     &.labelBox {
+//         border: 1px solid @greenA;
+//         color: @greenA;
+//         border-radius: 4px;
+//         background-color: @greenBgA;
+//     }
+
+//     &.is-checked {
+//         /deep/ .el-checkbox-button__inner {
+//             color: #FFFFFF;
+//             background-color: @greenA;
+//             border-color: @greenA;
+//         }
+//     }
+// }
+
+// .labelB {
+
+//     /deep/ .el-checkbox-button__inner,
+//     &.labelBox {
+//         border: 1px solid @orangeA;
+//         color: @orangeA;
+//         border-radius: 4px;
+//         background-color: @orangeBgA;
+//     }
+
+//     &.is-checked {
+//         /deep/ .el-checkbox-button__inner {
+//             color: #FFFFFF;
+//             background-color: @orangeA;
+//             border-color: @orangeA;
+//         }
+//     }
+// }
+
+// .labelC {
+
+//     /deep/ .el-checkbox-button__inner,
+//     &.labelBox {
+//         border: 1px solid @lightBlueA;
+//         color: @lightBlueA;
+//         border-radius: 4px;
+//         background-color: @lightBlueBgA;
+//     }
+
+//     &.is-checked {
+//         /deep/ .el-checkbox-button__inner {
+//             color: #FFFFFF;
+//             background-color: @lightBlueA;
+//             border-color: @lightBlueA;
+//         }
+//     }
+// }
+
+// .labelD {
+
+//     /deep/ .el-checkbox-button__inner,
+//     &.labelBox {
+//         border: 1px solid @purpleA;
+//         color: @purpleA;
+//         border-radius: 4px;
+//         background-color: @purpleBgA;
+//     }
+
+//     &.is-checked {
+//         /deep/ .el-checkbox-button__inner {
+//             color: #FFFFFF;
+//             background-color: @purpleA;
+//             border-color: @purpleA;
+//         }
+//     }
+// }
+
+// .videoBox {
+//     width: 100%;
+//     padding: 30 60px;
+
+//     video {
+//         width: 100%;
+//     }
+// }
+
+// .btnsPanel {
+//     margin: 45px 40px 15px;
+// }

+ 5 - 1
src/views/systemManagement/sceneLibraryManagement/generalizationScene.vue

@@ -118,6 +118,7 @@ export default {
                 fileName: [], // 功能模块
                 scenarioWeather: [], // 天气
                 scenarioTime: "", // 时间
+                share: "0",
             },
             labels: [],
             fileNameList: [],
@@ -173,7 +174,9 @@ export default {
                 type: "post",
                 // firstRequest: false,
                 data: this.$api.sceneLibrary.querySceneGeneralTemplateList,
-                param: {},
+                param: {
+                    share: "0",
+                },
             },
             dialogVisible: false,
             autoplay: false,
@@ -209,6 +212,7 @@ export default {
                 fileName: [],
                 scenarioWeather: [],
                 scenarioTime: "",
+                share: "0",
             };
             this.labels = [];
             this.doSearch();

+ 134 - 5
src/views/systemManagement/sceneLibraryManagement/naturalDrivingScene.vue

@@ -84,7 +84,7 @@
                 ></el-cascader>
             </template>
             <template slot="searchItem27">
-                <el-checkbox-group v-model="labels">
+                <!-- <el-checkbox-group v-model="labels">
                     <el-checkbox-button label="1" :key="1" class="labelA"
                         >高速</el-checkbox-button
                     >
@@ -106,7 +106,16 @@
                     <el-checkbox-button label="7" :key="7" class="labelC"
                         >掉头</el-checkbox-button
                     >
-                </el-checkbox-group>
+                </el-checkbox-group> -->
+                <div class="labelsBox">
+                    <b class="labelA" @click="conditions(1)">高速</b>
+                    <b class="labelB" @click="conditions(2)">切入</b>
+                    <b class="labelC" @click="conditions(3)">切出</b>
+                    <b class="labelD" @click="conditions(4)">变道</b>
+                    <b class="labelA" @click="conditions(5)">匝道</b>
+                    <b class="labelB" @click="conditions(6)">隧道</b>
+                    <b class="labelC" @click="conditions(7)">掉头</b>
+                </div>
             </template>
             <template slot="searchBtn1">
                 <el-button type="primary" @click="doSearch">查询</el-button>
@@ -208,6 +217,8 @@ export default {
                 cutOut: [], // 切出
                 laneChange: [], // 变道
                 turnAround: [], // 掉头
+
+                share: "0",
             },
             labels: [],
             list: [],
@@ -265,7 +276,9 @@ export default {
                 type: "post",
                 // firstRequest: false,
                 data: this.$api.sceneLibrary.querySceneNaturalList,
-                param: {},
+                param: {
+                    share: "0",
+                },
             },
             dialogVisible: false,
             autoplay: false,
@@ -312,7 +325,7 @@ export default {
 
     methods: {
         doSearch() {
-            this.searchParams.highSpeed = this.labels.includes("1")
+            /* this.searchParams.highSpeed = this.labels.includes("1")
                 ? [["roadType", "高速"]]
                 : [];
             this.searchParams.cutIn = this.labels.includes("2")
@@ -406,7 +419,8 @@ export default {
                       ["selfBehavior", "直路掉头"],
                       ["selfBehavior", "selfBehavior", "路口掉头"],
                   ]
-                : [];
+                : []; */
+
             this.refreshList(this.searchParams);
         },
         //刷新table
@@ -432,10 +446,125 @@ export default {
                 cutOut: [],
                 laneChange: [],
                 turnAround: [],
+                share: "0",
             };
             this.labels = [];
             this.doSearch();
         },
+        conditions(v) {
+            switch (v) {
+                case 1:
+                    this.searchParams.road = [
+                        ...this.searchParams.road,
+                        ["roadType", "高速"],
+                    ];
+                    break;
+                case 2:
+                    this.searchParams.targetBehavior = [
+                        ...this.searchParams.targetBehavior,
+                        [
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "机动车从左侧切入成功",
+                        ],
+                        [
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "机动车从右侧切入成功",
+                        ],
+                    ];
+                    break;
+                case 3:
+                    this.searchParams.targetBehavior = [
+                        ...this.searchParams.targetBehavior,
+                        [
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "机动车向左侧切出成功",
+                        ],
+                        [
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "targetBehavior",
+                            "机动车向右侧切出成功",
+                        ],
+                    ];
+                    break;
+                case 4:
+                    this.searchParams.selfBehavior = [
+                        ...this.searchParams.selfBehavior,
+                        [
+                            "selfBehavior",
+                            "selfBehavior",
+                            "selfBehavior",
+                            "向左变道成功",
+                        ],
+                        [
+                            "selfBehavior",
+                            "selfBehavior",
+                            "selfBehavior",
+                            "向右变道成功",
+                        ],
+                        [
+                            "selfBehavior",
+                            "selfBehavior",
+                            "selfBehavior",
+                            "向左连续变道",
+                        ],
+                        [
+                            "selfBehavior",
+                            "selfBehavior",
+                            "selfBehavior",
+                            "向右连续变道",
+                        ],
+                        [
+                            "selfBehavior",
+                            "selfBehavior",
+                            "selfBehavior",
+                            "向左变道超车",
+                        ],
+                        [
+                            "selfBehavior",
+                            "selfBehavior",
+                            "selfBehavior",
+                            "向右变道超车",
+                        ],
+                    ];
+                    break;
+                case 5:
+                    this.searchParams.road = [
+                        ...this.searchParams.road,
+                        ["ramp", "是"],
+                    ];
+                    break;
+                case 6:
+                    this.searchParams.road = [
+                        ...this.searchParams.road,
+                        ["tunnel", "是"],
+                    ];
+                    break;
+                case 7:
+                    this.searchParams.selfBehavior = [
+                        ...this.searchParams.selfBehavior,
+                        ["selfBehavior", "直路掉头"],
+                        ["selfBehavior", "selfBehavior", "路口掉头"],
+                    ];
+                    break;
+                default:
+                    break;
+            }
+        },
         viewRow(row) {
             this.dialogVisible = true;
             this.videoDiaTitle = row.naturalName;

+ 53 - 5
src/views/systemManagement/sceneLibraryManagement/standardRegulationSimulationScene.vue

@@ -42,7 +42,7 @@
                 </el-input>
             </template>
             <template slot="searchItem27">
-                <el-checkbox-group v-model="labels">
+                <!-- <el-checkbox-group v-model="labels">
                     <el-checkbox-button label="ISO" :key="1" class="labelA"
                         >ISO</el-checkbox-button
                     >
@@ -55,7 +55,13 @@
                     <el-checkbox-button label="E-NCAP" :key="4" class="labelD"
                         >E-NCAP</el-checkbox-button
                     >
-                </el-checkbox-group>
+                </el-checkbox-group> -->
+                <div class="labelsBox">
+                    <b class="labelA" @click="conditions(1)">ISO</b>
+                    <b class="labelB" @click="conditions(2)">GB</b>
+                    <b class="labelC" @click="conditions(3)">C-NCAP</b>
+                    <b class="labelD" @click="conditions(4)">E-NCAP</b>
+                </div>
             </template>
             <template slot="searchBtn1">
                 <el-button type="primary" @click="doSearch">查询</el-button>
@@ -127,6 +133,7 @@ export default {
                 regulationType: [], //法规类型
                 standardType: "", //标准类型
                 label: [],
+                share: "0",
             },
             labels: [], // 标签
             // regulationTypeList: [],
@@ -169,7 +176,9 @@ export default {
                 type: "post",
                 // firstRequest: false,
                 data: this.$api.sceneLibrary.queryStandardsRegulationsList,
-                param: {},
+                param: {
+                    share: "0",
+                },
             },
             dialogVisible: false,
             autoplay: false,
@@ -192,7 +201,7 @@ export default {
 
     methods: {
         doSearch() {
-            this.searchParams.label = [...this.labels];
+            // this.searchParams.label = [...this.labels];
             this.refreshList(this.searchParams);
         },
         //刷新table
@@ -207,10 +216,49 @@ export default {
                 regulationType: [],
                 standardType: "",
                 label: [],
+                share: "0",
             };
-            this.labels = [];
+            // this.labels = [];
             this.doSearch();
         },
+        conditions(v) {
+            switch (v) {
+                case 1:
+                    if (!this.searchParams.regulationType.includes("ISO")) {
+                        this.searchParams.regulationType = [
+                            ...this.searchParams.regulationType,
+                            "ISO",
+                        ];
+                    }
+                    break;
+                case 2:
+                    if (!this.searchParams.regulationType.includes("GB")) {
+                        this.searchParams.regulationType = [
+                            ...this.searchParams.regulationType,
+                            "GB",
+                        ];
+                    }
+                    break;
+                case 3:
+                    if (!this.searchParams.regulationType.includes("C-NCAP")) {
+                        this.searchParams.regulationType = [
+                            ...this.searchParams.regulationType,
+                            "C-NCAP",
+                        ];
+                    }
+                    break;
+                case 4:
+                    if (!this.searchParams.regulationType.includes("E-NCAP")) {
+                        this.searchParams.regulationType = [
+                            ...this.searchParams.regulationType,
+                            "E-NCAP",
+                        ];
+                    }
+                    break;
+                default:
+                    break;
+            }
+        },
         viewRow(row) {
             this.dialogVisible = true;
             this.videoDiaTitle = row.sceneName;

+ 65 - 6
src/views/systemManagement/sceneLibraryManagement/trafficAccidentSimulationScene.vue

@@ -94,7 +94,7 @@
                 </el-select>
             </template>
             <template slot="searchItem27">
-                <el-checkbox-group v-model="labels">
+                <!-- <el-checkbox-group v-model="labels">
                     <el-checkbox-button label="追尾" :key="1" class="labelA"
                         >追尾</el-checkbox-button
                     >
@@ -113,7 +113,17 @@
                         class="labelD"
                         >机动车-机动车冲突</el-checkbox-button
                     >
-                </el-checkbox-group>
+                </el-checkbox-group> -->
+                <div class="labelsBox">
+                    <b class="labelA" @click="conditions(1)">追尾</b>
+                    <b class="labelB" @click="conditions(2)">目标车切入</b>
+                    <b class="labelC" @click="conditions(3)"
+                        >目标车沿弯道行驶</b
+                    >
+                    <b class="labelD" @click="conditions(4)"
+                        >机动车-机动车冲突</b
+                    >
+                </div>
             </template>
             <template slot="searchBtn1">
                 <el-button type="primary" @click="doSearch">查询</el-button>
@@ -191,6 +201,7 @@ export default {
                 cutIn: "", // 切入
                 driveCurve: "", // 沿弯道行驶
                 carConflict: "", // 机动车-机动车冲突
+                share: "0",
             },
             labels: [],
             // selfDrivingList: [],
@@ -248,7 +259,9 @@ export default {
                 type: "post",
                 // firstRequest: false,
                 data: this.$api.sceneLibrary.querySceneAccidentList,
-                param: {},
+                param: {
+                    share: "0",
+                },
             },
             dialogVisible: false,
             autoplay: false,
@@ -287,7 +300,7 @@ export default {
 
     methods: {
         doSearch() {
-            this.searchParams.rearEndCollision = this.labels.includes("追尾")
+            /* this.searchParams.rearEndCollision = this.labels.includes("追尾")
                 ? "追尾"
                 : "";
             this.searchParams.cutIn = this.labels.includes("切入")
@@ -300,7 +313,8 @@ export default {
                 "机动车-机动车冲突"
             )
                 ? "机动车-机动车"
-                : "";
+                : ""; */
+
             this.refreshList(this.searchParams);
         },
         //刷新table
@@ -321,10 +335,55 @@ export default {
                 cutIn: "",
                 driveCurve: "",
                 carConflict: "",
+                share: "0",
             };
-            this.labels = [];
+            // this.labels = [];
             this.doSearch();
         },
+        conditions(v) {
+            switch (v) {
+                case 1:
+                    if (!this.searchParams.conflictBehavior.includes("追尾")) {
+                        this.searchParams.conflictBehavior = [
+                            ...this.searchParams.conflictBehavior,
+                            "追尾",
+                        ];
+                    }
+                    break;
+                case 2:
+                    if (!this.searchParams.targetDriving.includes("切入")) {
+                        this.searchParams.targetDriving = [
+                            ...this.searchParams.targetDriving,
+                            "切入",
+                        ];
+                    }
+                    break;
+                case 3:
+                    if (
+                        !this.searchParams.targetDriving.includes("沿弯道行驶")
+                    ) {
+                        this.searchParams.targetDriving = [
+                            ...this.searchParams.targetDriving,
+                            "沿弯道行驶",
+                        ];
+                    }
+                    break;
+                case 4:
+                    if (
+                        !this.searchParams.conflictType.includes(
+                            "机动车-机动车"
+                        )
+                    ) {
+                        this.searchParams.conflictType = [
+                            ...this.searchParams.conflictType,
+                            "机动车-机动车",
+                        ];
+                    }
+                    break;
+                default:
+                    break;
+            }
+        },
         viewRow(row) {
             this.dialogVisible = true;
             this.videoDiaTitle = row.sceneName;

+ 36 - 10
src/views/systemManagement/scenePacketListManagement/index.vue

@@ -15,7 +15,7 @@
             </template>
             <template slot="searchItem2">
                 <span class="label">操作时间</span>
-                <el-date-picker
+                <!-- <el-date-picker
                     v-model="createDate"
                     type="daterange"
                     format="yyyy-MM-dd"
@@ -24,6 +24,25 @@
                     start-placeholder="开始日期"
                     end-placeholder="结束日期"
                 >
+                </el-date-picker> -->
+                <el-date-picker
+                    v-model="searchParams.yearMin"
+                    type="date"
+                    format="yyyy-MM-dd"
+                    value-format="yyyy-MM-dd"
+                    placeholder="开始日期"
+                    class="dateRangeInput"
+                >
+                </el-date-picker>
+                <span class="dateSeparator">至</span>
+                <el-date-picker
+                    v-model="searchParams.yearMax"
+                    type="date"
+                    format="yyyy-MM-dd"
+                    value-format="yyyy-MM-dd"
+                    placeholder="结束日期"
+                    class="dateRangeInput"
+                >
                 </el-date-picker>
             </template>
 
@@ -225,18 +244,25 @@ export default {
     },
     methods: {
         doSearch() {
-            if (this.createDate) {
-                this.searchParams.yearMin = `${this.createDate[0]}`;
-                this.searchParams.yearMax = `${this.createDate[1]}`;
-            } else {
-                this.searchParams.yearMin = "";
-                this.searchParams.yearMax = "";
+            let yearMin = "";
+            if (this.searchParams.yearMin) {
+                yearMin = `${this.searchParams.yearMin} 00:00:00`;
+            }
+
+            let yearMax = "";
+            if (this.searchParams.yearMax) {
+                yearMax = `${this.searchParams.yearMax} 23:59:59`;
+            }
+
+            if (yearMin && yearMax && yearMin > yearMax) {
+                this.$message.error("结束时间不能早于开始时间");
+                return;
             }
 
             let pageMap = {
                 packageName: this.searchParams.packageName,
-                yearMin: this.searchParams.yearMin,
-                yearMax: this.searchParams.yearMax,
+                yearMin,
+                yearMax,
             };
             this.refreshList(pageMap);
         },
@@ -252,7 +278,7 @@ export default {
                 yearMin: "",
                 yearMax: "",
             };
-            this.createDate = "";
+            // this.createDate = "";
             this.doSearch();
         },
         addOne() {