| | |
| | | > |
| | | <template slot-scope="scope"> |
| | | <span v-if="scope.row.run_type === -1">-</span> |
| | | <span v-else-if="scope.row.TaskNames != null">{{(scope.row.TaskNames || []).map(r => r.taskName).join('/') || ''}}</span> |
| | | <span v-else-if="scope.row.allTasks != null">{{ |
| | | scope.row.allTasks | allTaskList |
| | | }}</span> |
| | | <span v-else>-</span> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | > |
| | | <template slot-scope="scope"> |
| | | <span v-if="scope.row.run_type === -1">-</span> |
| | | <span v-else>{{ scope.row.run_server_name }}</span> |
| | | <span v-else>{{ scope.row.runServerName }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column |
| | |
| | | > |
| | | <template slot-scope="scope"> |
| | | <span v-if="scope.row.run_type === -1">-</span> |
| | | <span v-else-if="scope.row.run_type === 1">{{ "轮询" }}</span> |
| | | <span v-else>{{ "实时" }}</span> |
| | | <!-- <toggle-button |
| | | <toggle-button |
| | | v-else |
| | | :value="scope.row.run_type === 1" |
| | | :width="60" |
| | |
| | | }" |
| | | :sync="true" |
| | | @change="pollSwitch(scope.row)" |
| | | /> --> |
| | | /> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | cameraType(type) { |
| | | return type === -1 ? "监控摄像机" : "AI摄像机"; |
| | | }, |
| | | taskList(tasks) { |
| | | taskList(tasks) {//执行算法 |
| | | return tasks |
| | | .filter((task) => { |
| | | return task.hasRule; |
| | |
| | | return task.taskname; |
| | | }) |
| | | .join(","); |
| | | }, |
| | | allTaskList(allTasks) { |
| | | return allTasks |
| | | .map((allTasks) => { |
| | | return allTasks.taskName; |
| | | }) |
| | | .join(" / "); |
| | | }, |
| | | switchText(type) { |
| | | return type ? "已开启" : "未开启"; |
| | |
| | | _this.statistic(); |
| | | }, 10 * 1000); |
| | | }, |
| | | pollSwitch(row) { |
| | | pollSwitch(row) {//轮询功能 暂未实现 |
| | | // changeRunType({ camera_ids: [row.id], run_type: row.run_type ^ 1 }).then( |
| | | // (rsp) => { |
| | | // if (rsp && rsp.success) { |