|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <div class="app-container">
|
|
|
+ <div class="app-container inghse">
|
|
|
<div style="background-color: #fff;padding: 20px;border-radius: 10px; padding-bottom: 0;">
|
|
|
<p style="margin: 0; font-weight: 800;font-size: 16px;color: #343434;display: flex;align-items: center;margin-bottom: 20px;border-left: 6px solid #03BF8A;margin-left: -20px;">
|
|
|
<!-- <img src="../../../assets/images/icon_htgl_btzs.png" alt="" style="width: 16px;height: 20px;"> -->
|
|
@@ -24,6 +24,12 @@
|
|
|
</div>
|
|
|
|
|
|
<el-row :gutter="10" class="mb8">
|
|
|
+ <div style="display: flex; justify-content: space-between;">
|
|
|
+ <p style="margin: 0; font-weight: 800;font-size: 16px;color: #343434;display: flex;align-items: center;margin-bottom: 20px;border-left: 6px solid #03BF8A;">
|
|
|
+ <!-- <img src="../../../assets/images/icon_htgl_btzs.png" alt="" style="width: 16px;height: 20px;"> -->
|
|
|
+ <span style="margin-left: 10px;">任务列表</span>
|
|
|
+ </p>
|
|
|
+ <div>
|
|
|
<el-col :span="1.5">
|
|
|
<el-button
|
|
|
type="success"
|
|
@@ -63,10 +69,88 @@
|
|
|
v-hasPermi="['manage:taskManage:export']"
|
|
|
>导出</el-button>
|
|
|
</el-col>
|
|
|
- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <!-- <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar> -->
|
|
|
</el-row>
|
|
|
+ <div class="infinite-list" :style="dynamicStyle">
|
|
|
+ <el-row v-masonry :gutter="10" style="margin: 0; ">
|
|
|
+ <el-col v-masonry-tile :span="6" v-for="(item,index) in taskManageList" :key="index">
|
|
|
+ <div class="section_11 flex-col" style="position: relative; padding-left: 0; padding-right: 0; padding-bottom: 0;">
|
|
|
+ <div class="section_12 flex-row" style="height: 30px; border-bottom: 1px solid #E6E6E6; justify-content:flex-start;padding: 0 10px;">
|
|
|
+ <div @click="handleSelectionChange(item)" style="">
|
|
|
+ <img
|
|
|
+ class="thumbnail_21"
|
|
|
+ referrerpolicy="no-referrer"
|
|
|
+ src="../../../assets/images/icon_lby_gx_normal.png"
|
|
|
+ v-show="!item.isnum && isgsow"
|
|
|
+ />
|
|
|
+ <img
|
|
|
+ class="thumbnail_21"
|
|
|
+ referrerpolicy="no-referrer"
|
|
|
+ src="../../../assets/images/icon_lby_gx_selcted.png"
|
|
|
+ v-show="item.isnum && isgsow"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ <div style="display: flex;width: 82%;">
|
|
|
+ <div style="width: 84%; display: flex;">
|
|
|
+ <el-tooltip class="item" effect="dark" :content="item.taskNum" placement="top-start">
|
|
|
+ <span class="text_26" style="margin-top: 0; height: 15px; line-height: 14px;">{{item.taskNum}}</span>
|
|
|
+ </el-tooltip>
|
|
|
+ <!-- <img
|
|
|
+ @click="handleUpdate(item)" v-hasPermi="['system:user:edit']"
|
|
|
+ class="thumbnail_14"
|
|
|
+ referrerpolicy="no-referrer"
|
|
|
+ style="cursor: pointer;"
|
|
|
+ src="../../../assets/images/icon_htgl_rylb_bjs.png"
|
|
|
+ /> -->
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div>
|
|
|
+ <!-- <el-switch v-model="item.status" active-value="0" inactive-value="1" @change="handleStatusChange(item)"></el-switch> -->
|
|
|
+ </div>
|
|
|
|
|
|
- <el-table :height="tableMaxHeight" v-loading="loading" :data="taskManageList" @selection-change="handleSelectionChange">
|
|
|
+ </div>
|
|
|
+ <div class="text-wrapper_15 ingsjlegsng " style="margin: 0; margin-top: 10px; padding: 0 10px;">
|
|
|
+ <div style="display: flex">
|
|
|
+ <p class="paragraph_5" style="width: 30%;">视频地址:</p>
|
|
|
+ <el-tooltip class="item" effect="dark" :content="'视频地址:' + item.videoAddress" placement="left-start">
|
|
|
+ <p class="paragraph_5" style="color: #2068F8;width: 70%; ">{{item.videoAddress}}</p>
|
|
|
+ </el-tooltip>
|
|
|
+ </div>
|
|
|
+ <div style="display: flex">
|
|
|
+ <p class="paragraph_5" style="width: 30%;">工作计划:</p>
|
|
|
+ <p class="paragraph_5" style="width: 70%; ">{{item.clockName}}</p>
|
|
|
+ </div>
|
|
|
+ <div style="display: flex;margin-top: 5px;">
|
|
|
+ <p class="paragraph_5">IO口信号输出:</p>
|
|
|
+ <dict-tag :options="dict.type.tyoe_yes" :value="item.ioOutput"/>
|
|
|
+ </div>
|
|
|
+ <div style="display: flex ; margin-top: 5px; width: 100%; margin-bottom: 5px;">
|
|
|
+ <div style="display: flex; flex-wrap: wrap; width: 100%;">
|
|
|
+ <p class="paragraph_5" style="width: 30%;">算法类型:</p>
|
|
|
+ <div style="flex: 1; width: 70%; display: flex;flex-wrap: wrap;" >
|
|
|
+ <div style="margin-left: 3px; margin-bottom: 4px;" :class="itemt.color" v-for="(itemt,index) in item.algorithmSetList" :key="index">
|
|
|
+ {{itemt.algorithmName}}
|
|
|
+ </div>
|
|
|
+ <!-- <dict-tag style="margin-bottom: 5px; margin-right: 5px;" v-for="(itemt,index) in item.algorithmSetList" :key="index" :options="algorithmSetList" :value="itemt.algorithmId"/> -->
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div style="display: flex;" class="njgsebott njgsebottinghe ">
|
|
|
+ <p style="color: red;" @click="handleDelete(item)" v-hasPermi="['manage:taskManage:remove']">删除</p>
|
|
|
+ <p style="border-right: none; color: #03BF8A;" @click="handleUpdate(item)" v-hasPermi="['manage:taskManage:edit']">编辑</p>
|
|
|
+ <!-- <p @click="handleAuthRole(item)" v-hasPermi="['system:user:edit']">分配角色</p> -->
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ <div v-if='taskManageList.length == 0'>
|
|
|
+ <el-empty :image-size="200"></el-empty>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <!-- <el-table :height="tableMaxHeight" v-loading="loading" :data="taskManageList" @selection-change="handleSelectionChange">
|
|
|
<el-table-column type="selection" width="55" align="center" />
|
|
|
<el-table-column label="任务编号" align="center" prop="taskNum" />
|
|
|
<el-table-column label="任务描述" align="center" prop="taskDetails" />
|
|
@@ -96,7 +180,7 @@
|
|
|
>删除</el-button>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- </el-table>
|
|
|
+ </el-table> -->
|
|
|
|
|
|
<pagination
|
|
|
v-show="total>0"
|
|
@@ -107,7 +191,16 @@
|
|
|
/>
|
|
|
|
|
|
<!-- 添加或修改任务管理对话框 -->
|
|
|
- <el-dialog :title="title" :visible.sync="open" width="700px" append-to-body>
|
|
|
+ <el-drawer
|
|
|
+ :title="title"
|
|
|
+ :visible.sync="open"
|
|
|
+ direction="rtl"
|
|
|
+ custom-class="demo-drawer"
|
|
|
+ ref="drawer"
|
|
|
+ :size="580"
|
|
|
+ :modal="false"
|
|
|
+ >
|
|
|
+ <div class="demo-drawer__content">
|
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
|
|
<el-row>
|
|
|
<el-col :span="12">
|
|
@@ -115,79 +208,123 @@
|
|
|
<el-input v-model="form.taskNum" placeholder="请输入任务编号" />
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+
|
|
|
<el-col :span="12">
|
|
|
- <el-form-item label="视频地址" prop="videoAddress">
|
|
|
- <el-input v-model="form.videoAddress" placeholder="请输入视频地址" />
|
|
|
+ <el-form-item label="工作计划" prop="clockSetId">
|
|
|
+ <el-select style="width: 100%;" v-model="form.clockSetId" placeholder="请选择工作计划">
|
|
|
+ <el-option
|
|
|
+ v-for="dict in clockSetList "
|
|
|
+ :key="dict.clockSetId"
|
|
|
+ :label="dict.clockName"
|
|
|
+ :value="dict.clockSetId"
|
|
|
+ @click.native="gonjsue(dict)"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
+ <!-- <el-input v-model="form.videoAddress" placeholder="请输入视频地址" /> -->
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="12">
|
|
|
- <el-form-item label="上报地址" prop="reportAddress">
|
|
|
- <el-input v-model="form.reportAddress" placeholder="请输入上报地址" />
|
|
|
+ <el-col :span="12" class="ngosie">
|
|
|
+ <el-form-item label="IO口 信号输出" prop="ioOutput">
|
|
|
+ <el-select style="width: 100%;" v-model="form.ioOutput" placeholder="请选择设备类型">
|
|
|
+ <el-option
|
|
|
+ v-for="dict in dict.type.tyoe_yes"
|
|
|
+ :key="dict.value"
|
|
|
+ :label="dict.label"
|
|
|
+ :value="dict.value"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
+
|
|
|
<el-col :span="12">
|
|
|
- <el-form-item label="通道编号" prop="channelId">
|
|
|
- <el-select style="width: 100%;" v-model="form.channelId" placeholder="请选择通道ID">
|
|
|
+ <el-form-item label="任务描述" prop="taskDetails">
|
|
|
+ <el-input v-model="form.taskDetails" placeholder="请输入内容" />
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="24">
|
|
|
+ <el-form-item label="视频地址" prop="channelId">
|
|
|
+ <el-select style="width: 100%;" v-model="form.channelId" placeholder="请选择视频地址">
|
|
|
<el-option
|
|
|
+ @click.native="diane(dict)"
|
|
|
v-for="dict in channelNumberList "
|
|
|
:key="dict.channelId"
|
|
|
- :label="dict.channelNum"
|
|
|
+ :label="dict.videoAddress"
|
|
|
:value="dict.channelId"
|
|
|
></el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="24">
|
|
|
- <el-form-item label="算法编号" prop="algorithmSet">
|
|
|
- <el-select multiple style="width: 100%;" v-model="form.algorithmSet" placeholder="请选择算法编号">
|
|
|
- <el-option
|
|
|
- v-for="dict in dict.type.algorithm_settings"
|
|
|
- :key="dict.value"
|
|
|
- :label="dict.label"
|
|
|
- :value="dict.value"
|
|
|
- ></el-option>
|
|
|
- </el-select>
|
|
|
+ <el-form-item label="算法编号" prop="algorithmSetIds" class="renset" >
|
|
|
+ <el-row :gutter="5" style="margin-left: 0;">
|
|
|
+ <el-col :span="6" v-for="(item,index) in algorithmSetListtolt" :key="index">
|
|
|
+ <el-checkbox-group @change="insgse" v-model="checkList">
|
|
|
+ <el-checkbox :label="item.algorithmName"></el-checkbox>
|
|
|
+ </el-checkbox-group>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
|
|
|
+ <el-col :span="24" v-if="show">
|
|
|
+ <div style="padding: 0 8px;">
|
|
|
+ <div style="display: flex; padding-left: 20px; border-top: 1px solid #E6E6E6; padding-top: 10px;margin-bottom: 10px; flex-wrap: wrap;">
|
|
|
+ <p style="margin: 0; font-weight: bold;font-size: 13px;color: #222327;" v-for="(item,index) in checkList" :key="index">{{item}},</p>
|
|
|
+ </div>
|
|
|
+ <div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
|
|
|
- <el-col :span="12">
|
|
|
- <el-form-item label="任务描述" prop="taskDetails">
|
|
|
- <el-input v-model="form.taskDetails" placeholder="请输入内容" />
|
|
|
- </el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :span="12">
|
|
|
- <el-form-item label="备注" prop="remark">
|
|
|
- <el-input v-model="form.remark" placeholder="请输入内容" />
|
|
|
- </el-form-item>
|
|
|
+ <el-col :span="12" style="padding-left: 20px;" v-if="show">
|
|
|
+ <div style="height: 40px;border-radius: 4px; padding: 0 5px; display: flex; border: 1px solid #E6E6E6; align-items: center; justify-content: space-between;">
|
|
|
+ <p style="margin: 0; font-weight: 500;font-size: 13px;color: #222327;">开启严格模式</p>
|
|
|
+ <el-switch v-model="form.isStrict" active-value="0" inactive-value="1" ></el-switch>
|
|
|
+ </div>
|
|
|
+ <!-- <el-form-item label="严检测" prop="remark">
|
|
|
+ <el-select multiple style="width: 100%;" v-model="form.algorithmSet" placeholder="请选择算法编号">
|
|
|
+ <el-option
|
|
|
+ v-for="dict in dict.type.sys_yes_no"
|
|
|
+ :key="dict.value"
|
|
|
+ :label="dict.label"
|
|
|
+ :value="dict.value"
|
|
|
+ ></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item> -->
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12" v-if="showpay">
|
|
|
+ <div style="display: flex; font-weight: 500;font-size: 13px;color: #009FE8; align-items: center;justify-content: space-between;
|
|
|
+ border: 1px solid #009FE8; background-color: #F2FBFF;padding: 0 10px; line-height: 40px;
|
|
|
+ margin: 0 10px; height: 40px; border-radius: 4px;" @click="submitForm(0)">
|
|
|
+ <span>点击进行详细设置</span>
|
|
|
+ <span>>></span>
|
|
|
+ </div>
|
|
|
+ <!-- <el-button style="margin-left: 10px;" type="success" @click="submitForm(0)" plain>离岗/玩手机设置</el-button> -->
|
|
|
</el-col>
|
|
|
-
|
|
|
</el-row>
|
|
|
-
|
|
|
-
|
|
|
<!-- <el-form-item label="通道ID" prop="channelId">
|
|
|
<el-input v-model="form.channelId" placeholder="请输入通道ID" />
|
|
|
</el-form-item> -->
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
</el-form>
|
|
|
- <div slot="footer" class="dialog-footer">
|
|
|
- <el-button style="background-color:#03BF8A ; border-color: #03BF8A;" type="primary" @click="submitForm">确 定</el-button>
|
|
|
+ <div slot="footer" class="dialog-footer" style="padding: 0 20px; float: right; margin-top: 8px;">
|
|
|
+ <el-button style="background-color:#03BF8A ; border-color: #03BF8A;" type="primary" @click="submitForm(1)">确 定</el-button>
|
|
|
<el-button style="background-color:#DDEBE7 ; border-color: #DDEBE7; color: #475669;" @click="cancel">取 消</el-button>
|
|
|
</div>
|
|
|
- </el-dialog>
|
|
|
+ </div>
|
|
|
+ </el-drawer>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import { listTaskManage, getTaskManage, delTaskManage, addTaskManage, updateTaskManage } from "@/api/manage/taskManage"
|
|
|
-import { listChannelNumber, getChannelNumber, delChannelNumber, addChannelNumber, updateChannelNumber } from "@/api/system/channelNumber"
|
|
|
+import { listChannelNumber,listChannelNumbernopa, getChannelNumber, delChannelNumber, addChannelNumber, updateChannelNumber } from "@/api/system/channelNumber"
|
|
|
+import { listClockSet, getClockSet, delClockSet, addClockSet, updateClockSet } from "@/api/manage/clockSet"
|
|
|
+import { listAlgorithmSet, getAlgorithmSet, delAlgorithmSet, addAlgorithmSet, updateAlgorithmSet } from "@/api/manage/algorithmSet"
|
|
|
+import Masonry from "masonry-layout";
|
|
|
export default {
|
|
|
name: "TaskManage",
|
|
|
- dicts: ['algorithm_settings'],
|
|
|
+ dicts: ['algorithm_settings','sys_yes_no','tyoe_yes'],
|
|
|
data() {
|
|
|
return {
|
|
|
// 遮罩层
|
|
@@ -200,6 +337,9 @@ export default {
|
|
|
multiple: true,
|
|
|
// 显示搜索条件
|
|
|
showSearch: true,
|
|
|
+ show:false,
|
|
|
+ value:true,
|
|
|
+ showpay:false,
|
|
|
// 总条数
|
|
|
total: 0,
|
|
|
// 任务管理表格数据
|
|
@@ -209,10 +349,11 @@ export default {
|
|
|
title: "",
|
|
|
// 是否显示弹出层
|
|
|
open: false,
|
|
|
+ checkList:[],
|
|
|
// 查询参数
|
|
|
queryParams: {
|
|
|
pageNum: 1,
|
|
|
- pageSize: 10,
|
|
|
+ pageSize: 8,
|
|
|
taskNum: null,
|
|
|
taskDetails: null,
|
|
|
channelId: null,
|
|
@@ -227,21 +368,47 @@ export default {
|
|
|
taskNum: [
|
|
|
{ required: true, message: "不能为空", trigger: "blur" }
|
|
|
],
|
|
|
- algorithmSet: [
|
|
|
+ clockName: [
|
|
|
+ { required: true, message: "不能为空", trigger: "blur" }
|
|
|
+ ],
|
|
|
+ channelId: [
|
|
|
{ required: true, message: "不能为空", trigger: "blur" }
|
|
|
],
|
|
|
},
|
|
|
tableMaxHeight:'200',
|
|
|
+ spdjOptions:[],
|
|
|
+ clockSetList:[],
|
|
|
+ isgsow:true,
|
|
|
+ algorithmSetListtolt:[],
|
|
|
+ sstt: [
|
|
|
+ "ss1",
|
|
|
+ "ss2",
|
|
|
+ "ss3",
|
|
|
+ "ss4",
|
|
|
+ ]
|
|
|
}
|
|
|
},
|
|
|
created() {
|
|
|
this.getList()
|
|
|
- this.getListt()
|
|
|
+ // this.getListt()
|
|
|
+ // this.getListtime()
|
|
|
+ // this.getListsf()
|
|
|
+ this.getDicts("algorithm_settings").then(response => {
|
|
|
+ this.spdjOptions = response.data;
|
|
|
+ });
|
|
|
window.onresize = () => {
|
|
|
this.changeTableMaxHeight()
|
|
|
}
|
|
|
this.changeTableMaxHeight()
|
|
|
},
|
|
|
+ computed: {
|
|
|
+ dynamicStyle() {
|
|
|
+ return {
|
|
|
+ overflow:'auto',
|
|
|
+ height: this.tableMaxHeight + 'px',
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
mounted() {
|
|
|
window.onresize = () => {
|
|
|
this.changeTableMaxHeight()
|
|
@@ -249,11 +416,19 @@ export default {
|
|
|
this.changeTableMaxHeight()
|
|
|
},
|
|
|
methods: {
|
|
|
+
|
|
|
/** 查询任务管理列表 */
|
|
|
getList() {
|
|
|
this.loading = true
|
|
|
listTaskManage(this.queryParams).then(response => {
|
|
|
this.taskManageList = response.rows
|
|
|
+ this.taskManageList.filter(rou=>{
|
|
|
+ rou.isnum = false
|
|
|
+ rou.algorithmSetList.forEach((item, index) => {
|
|
|
+ item.color = this.sstt[index%4]
|
|
|
+ })
|
|
|
+ })
|
|
|
+ console.log(this.taskManageList)
|
|
|
this.total = response.total
|
|
|
this.loading = false
|
|
|
})
|
|
@@ -265,11 +440,70 @@ export default {
|
|
|
pageNum: 1,
|
|
|
pageSize: 200,
|
|
|
}
|
|
|
- listChannelNumber(snge).then(response => {
|
|
|
+ listChannelNumbernopa().then(response => {
|
|
|
this.channelNumberList = response.rows
|
|
|
this.loading = false
|
|
|
})
|
|
|
},
|
|
|
+ /** 查询模板列表 */
|
|
|
+ getListtime() {
|
|
|
+ this.loading = true
|
|
|
+ let snge={
|
|
|
+ pageNum: 1,
|
|
|
+ pageSize: 300,
|
|
|
+ }
|
|
|
+ listClockSet(snge).then(response => {
|
|
|
+ this.clockSetList = response.rows
|
|
|
+ this.loading = false
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 查询算法类别
|
|
|
+ getListsf() {
|
|
|
+ this.loading = true
|
|
|
+ let snge={
|
|
|
+ pageNum: 1,
|
|
|
+ pageSize: 300,
|
|
|
+ }
|
|
|
+ listAlgorithmSet(snge).then(response => {
|
|
|
+ this.algorithmSetListtolt = response.rows
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 视频选择
|
|
|
+ diane(row){
|
|
|
+ // console.log(row)
|
|
|
+ this.form.channelId = row.channelId
|
|
|
+ this.form.videoAddress = row.videoAddress
|
|
|
+ this.checkList = []
|
|
|
+ if(row.algorithmSetList.length !=0){
|
|
|
+ row.algorithmSetList.filter(rou=>{
|
|
|
+ // rou.algorithmId = rou.algorithmId-0
|
|
|
+ this.checkList.push(rou.algorithmName)
|
|
|
+ this.insgse()
|
|
|
+ })
|
|
|
+ }
|
|
|
+ console.log(this.checkList)
|
|
|
+ },
|
|
|
+ // 工作计划选择
|
|
|
+ gonjsue(row){
|
|
|
+ this.form.clockSetId = row.clockSetId
|
|
|
+ this.form.clockName = row.clockName
|
|
|
+ },
|
|
|
+ // 多选框选种
|
|
|
+ insgse(){
|
|
|
+ // console.log(this.checkList)
|
|
|
+ if(this.checkList.length != 0){
|
|
|
+ this.show = true
|
|
|
+ }else{
|
|
|
+ this.show = false
|
|
|
+ }
|
|
|
+ if(this.checkList.includes('离岗检测') || this.checkList.includes('抽烟打电话检测')){
|
|
|
+ this.showpay = true
|
|
|
+ }else{
|
|
|
+ this.showpay = false
|
|
|
+ }
|
|
|
+ // this.checkList.
|
|
|
+ //
|
|
|
+ },
|
|
|
// 取消按钮
|
|
|
cancel() {
|
|
|
this.open = false
|
|
@@ -284,13 +518,15 @@ export default {
|
|
|
channelId: null,
|
|
|
videoAddress: null,
|
|
|
reportAddress: null,
|
|
|
- algorithmSet: null,
|
|
|
+ algorithmSetIds: null,
|
|
|
delFlag: null,
|
|
|
createBy: null,
|
|
|
createTime: null,
|
|
|
updateBy: null,
|
|
|
updateTime: null,
|
|
|
- remark: null
|
|
|
+ remark: null,
|
|
|
+ ioOutput:'2',
|
|
|
+ isStrict:'0'
|
|
|
}
|
|
|
this.resetForm("form")
|
|
|
},
|
|
@@ -306,25 +542,52 @@ export default {
|
|
|
},
|
|
|
// 多选框选中数据
|
|
|
handleSelectionChange(selection) {
|
|
|
- this.ids = selection.map(item => item.taskId)
|
|
|
- this.single = selection.length!==1
|
|
|
- this.multiple = !selection.length
|
|
|
+ // console.log(selection)
|
|
|
+ this.isgsow = false
|
|
|
+ selection.isnum = !selection.isnum
|
|
|
+ this.isgsow = true
|
|
|
+ let nhseg= []
|
|
|
+ this.taskManageList.filter(rou=>{
|
|
|
+ if(rou.isnum == true){
|
|
|
+ nhseg.push(rou)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ console.log(nhseg)
|
|
|
+ this.ids = nhseg.map(item => item.taskId)
|
|
|
+ console.log(this.ids,nhseg)
|
|
|
+ this.single = nhseg.length!==1
|
|
|
+ this.multiple = !nhseg.length
|
|
|
},
|
|
|
+
|
|
|
/** 新增按钮操作 */
|
|
|
handleAdd() {
|
|
|
this.reset()
|
|
|
this.open = true
|
|
|
this.title = "添加任务管理"
|
|
|
+ this.checkList = []
|
|
|
+ this.insgse()
|
|
|
+ this.getListtime()
|
|
|
+ this.getListsf()
|
|
|
+ this.getListt()
|
|
|
},
|
|
|
/** 修改按钮操作 */
|
|
|
handleUpdate(row) {
|
|
|
this.reset()
|
|
|
const taskId = row.taskId || this.ids
|
|
|
+ this.getListsf()
|
|
|
+ this.getListtime()
|
|
|
+ this.getListt()
|
|
|
getTaskManage(taskId).then(response => {
|
|
|
this.form = response.data
|
|
|
- if(this.form.algorithmSet != null){
|
|
|
- if(this.form.algorithmSet.length !=0){
|
|
|
- this.form.algorithmSet = this.form.algorithmSet.split(',')
|
|
|
+ this.checkList = []
|
|
|
+ if(this.form.algorithmSetList != null){
|
|
|
+ if(this.form.algorithmSetList.length !=0){
|
|
|
+ this.form.algorithmSetList.filter(rou=>{
|
|
|
+ // rou.algorithmId = rou.algorithmId-0
|
|
|
+ this.checkList.push(rou.algorithmName)
|
|
|
+ this.insgse()
|
|
|
+ })
|
|
|
+ console.log(this.checkList)
|
|
|
}
|
|
|
}
|
|
|
this.open = true
|
|
@@ -332,9 +595,24 @@ export default {
|
|
|
})
|
|
|
},
|
|
|
/** 提交按钮 */
|
|
|
- submitForm() {
|
|
|
+ submitForm(row) {
|
|
|
this.$refs["form"].validate(valid => {
|
|
|
if (valid) {
|
|
|
+ // checkList
|
|
|
+ this.form.algorithmSetIds = []
|
|
|
+ if(this.checkList.length == 0){
|
|
|
+ this.$message.error('请选择算法');
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if(this.checkList.length !=0){
|
|
|
+ this.checkList.filter(rou=>{
|
|
|
+ this.algorithmSetListtolt.filter(rout=>{
|
|
|
+ if(rou == rout.algorithmName ){
|
|
|
+ this.form.algorithmSetIds.push(rout.algorithmId)
|
|
|
+ }
|
|
|
+ })
|
|
|
+ })
|
|
|
+ }
|
|
|
if(this.form.algorithmSet != null){
|
|
|
if(this.form.algorithmSet.length !=0){
|
|
|
this.form.algorithmSet = this.form.algorithmSet.join(',')
|
|
@@ -345,12 +623,28 @@ export default {
|
|
|
this.$modal.msgSuccess("修改成功")
|
|
|
this.open = false
|
|
|
this.getList()
|
|
|
+ if(row == 0){
|
|
|
+ this.$router.push({
|
|
|
+ path: '/shebecanshuhuabu',
|
|
|
+ query: {
|
|
|
+ 'id':this.form.channelId,
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
})
|
|
|
} else {
|
|
|
addTaskManage(this.form).then(response => {
|
|
|
this.$modal.msgSuccess("新增成功")
|
|
|
this.open = false
|
|
|
this.getList()
|
|
|
+ if(row == 0){
|
|
|
+ this.$router.push({
|
|
|
+ path: '/shebecanshuhuabu',
|
|
|
+ query: {
|
|
|
+ 'id':this.form.channelId,
|
|
|
+ }
|
|
|
+ })
|
|
|
+ }
|
|
|
})
|
|
|
}
|
|
|
}
|
|
@@ -359,12 +653,10 @@ export default {
|
|
|
/** 删除按钮操作 */
|
|
|
handleDelete(row) {
|
|
|
const taskIds = row.taskId || this.ids
|
|
|
- this.$modal.confirm('是否确认删除任务管理编号为"' + taskIds + '"的数据项?').then(function() {
|
|
|
- return delTaskManage(taskIds)
|
|
|
- }).then(() => {
|
|
|
- this.getList()
|
|
|
+ delTaskManage(taskIds).then(response => {
|
|
|
this.$modal.msgSuccess("删除成功")
|
|
|
- }).catch(() => {})
|
|
|
+ this.getList()
|
|
|
+ })
|
|
|
},
|
|
|
/** 导出按钮操作 */
|
|
|
handleExport() {
|
|
@@ -391,6 +683,30 @@ export default {
|
|
|
}
|
|
|
</script>
|
|
|
<style lang="scss">
|
|
|
+ .njgsebottinghe{
|
|
|
+ margin: 0 !important;
|
|
|
+ height: 40px;
|
|
|
+ p{
|
|
|
+ height: 40px !important;
|
|
|
+ line-height: 40px !important;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .ingsjlegsng{
|
|
|
+ .paragraph_5{
|
|
|
+ font-family: PingFang SC;
|
|
|
+ font-weight: 500;
|
|
|
+ font-size: 13px;
|
|
|
+ color: #222327;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .ngosie{
|
|
|
+ .el-form-item--medium .el-form-item__label{
|
|
|
+ line-height: 19px;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ .renset{
|
|
|
+ margin-bottom: 0;
|
|
|
+ }
|
|
|
.el-table .el-table__header-wrapper th, .el-table .el-table__fixed-header-wrapper th{
|
|
|
background-color:#F5F6F8;
|
|
|
}
|
|
@@ -411,5 +727,38 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ .ss1{
|
|
|
+ font-size: 13px;
|
|
|
+ color: #FD7F10;
|
|
|
+ background-color: #FFF4EB;
|
|
|
+ border: 1px solid #FD7F10;
|
|
|
+ padding: 3px 5px;
|
|
|
+ border-radius: 3px;
|
|
|
+ }
|
|
|
+ .ss2{
|
|
|
+ font-size: 13px;
|
|
|
+ color:#009FE8;
|
|
|
+ background-color: #F0FAFF;
|
|
|
+ border: 1px solid #009FE8;
|
|
|
+ padding: 3px 5px;
|
|
|
+ border-radius: 3px;
|
|
|
+ }
|
|
|
+ .ss3 {
|
|
|
+ font-size: 13px;
|
|
|
+ color: #28C529;
|
|
|
+ background-color: #F2F8F2;
|
|
|
+ border: 1px solid #28C529;
|
|
|
+ padding: 3px 5px;
|
|
|
+ border-radius: 3px;
|
|
|
+ }
|
|
|
+ .ss4{
|
|
|
+ font-size: 13px;
|
|
|
+ color: #FF6969;
|
|
|
+ background-color: #FFF4F4;
|
|
|
+ border: 1px solid #FF6969;
|
|
|
+ padding: 3px 5px;
|
|
|
+ border-radius: 3px;
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
</style>
|