fix:删除多的模块
This commit is contained in:
parent
cafb787b65
commit
35fe16bf53
@ -1,395 +0,0 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="88px">
|
||||
<el-form-item label="视频名称" prop="productName">
|
||||
<el-input
|
||||
v-model="queryParams.productName"
|
||||
placeholder="请输入视频名称"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="地区" prop="batchInfo">
|
||||
<el-input
|
||||
v-model="queryParams.batchInfo"
|
||||
placeholder="请输入地区"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="经度" prop="lengthInfo">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.lengthInfo"-->
|
||||
<!-- placeholder="请输入经度"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="纬度" prop="wideInfo">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.wideInfo"-->
|
||||
<!-- placeholder="请输入纬度"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="状态" prop="heightInfo">
|
||||
<el-input
|
||||
v-model="queryParams.heightInfo"
|
||||
placeholder="请输入状态"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="角度" prop="angle">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.angle"-->
|
||||
<!-- placeholder="请输入角度"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="视频时间">
|
||||
<el-date-picker
|
||||
v-model="daterangeDetectTime"
|
||||
style="width: 240px"
|
||||
value-format="yyyy-MM-dd"
|
||||
type="daterange"
|
||||
range-separator="-"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"
|
||||
></el-date-picker>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="结果" prop="detectResult">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.detectResult"-->
|
||||
<!-- placeholder="请输入结果"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="primary"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="handleAdd"
|
||||
v-hasPermi="['qcfgjManage:dock:add']"
|
||||
>新增</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="success"
|
||||
plain
|
||||
icon="el-icon-edit"
|
||||
size="mini"
|
||||
:disabled="single"
|
||||
@click="handleUpdate"
|
||||
v-hasPermi="['qcfgjManage:dock:edit']"
|
||||
>修改</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="danger"
|
||||
plain
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
:disabled="multiple"
|
||||
@click="handleDelete"
|
||||
v-hasPermi="['qcfgjManage:dock:remove']"
|
||||
>删除</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-download"
|
||||
size="mini"
|
||||
@click="handleExport"
|
||||
v-hasPermi="['qcfgjManage:dock:export']"
|
||||
>导出</el-button>
|
||||
</el-col>
|
||||
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="dockList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="视频名称" align="center" prop="productName" />
|
||||
<el-table-column label="地区" align="center" prop="batchInfo" />
|
||||
<el-table-column label="经度" align="center" prop="lengthInfo" />
|
||||
<el-table-column label="纬度" align="center" prop="wideInfo" />
|
||||
<el-table-column label="状态" align="center" prop="heightInfo" />
|
||||
<!-- <el-table-column label="角度" align="center" prop="angle" />-->
|
||||
<!-- <el-table-column label="要求" align="center" prop="standards" />-->
|
||||
<!-- <el-table-column label="图片信息" align="center" prop="imageInfo" width="100">-->
|
||||
<!-- <template slot-scope="scope">-->
|
||||
<!-- <image-preview :src="scope.row.imageInfo" :width="50" :height="50"/>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<el-table-column label="视频时间" align="center" prop="detectTime" width="180">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ parseTime(scope.row.detectTime, '{y}-{m}-{d}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column label="结果" align="center" prop="detectResult" >-->
|
||||
<!-- <template slot-scope="scope">-->
|
||||
<!-- <el-tag type="warning" v-if="scope.row.detectResult === '处理中'">{{scope.row.detectResult}}</el-tag>-->
|
||||
<!-- <el-tag type="success" v-else-if="scope.row.detectResult === '合格'">{{scope.row.detectResult}}</el-tag>-->
|
||||
<!-- <el-tag type="danger" v-else-if="scope.row.detectResult === '未识别'">{{scope.row.detectResult}}</el-tag>-->
|
||||
<!-- <el-tag type="info" v-else>{{scope.row.detectResult}}</el-tag>-->
|
||||
<!-- </template>-->
|
||||
<!-- </el-table-column>-->
|
||||
<el-table-column label="备注" align="center" prop="remark" />
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-edit"
|
||||
@click="handleUpdate(scope.row)"
|
||||
v-hasPermi="['qcfgjManage:dock:edit']"
|
||||
>修改</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete(scope.row)"
|
||||
v-hasPermi="['qcfgjManage:dock:remove']"
|
||||
>删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
v-show="total>0"
|
||||
:total="total"
|
||||
:page.sync="queryParams.pageNum"
|
||||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
|
||||
<!-- 添加或修改产品数据信息对接对话框 -->
|
||||
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="88px">
|
||||
<el-form-item label="视频名称" prop="productName">
|
||||
<el-input v-model="form.productName" placeholder="请输入视频名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="地区" prop="batchInfo">
|
||||
<el-input v-model="form.batchInfo" placeholder="请输入地区" />
|
||||
</el-form-item>
|
||||
<el-form-item label="经度" prop="lengthInfo">
|
||||
<el-input v-model="form.lengthInfo" placeholder="请输入经度" />
|
||||
</el-form-item>
|
||||
<el-form-item label="纬度" prop="wideInfo">
|
||||
<el-input v-model="form.wideInfo" placeholder="请输入纬度" />
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="heightInfo">
|
||||
<el-input v-model="form.heightInfo" placeholder="请输入状态" />
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="角度" prop="angle">-->
|
||||
<!-- <el-input v-model="form.angle" placeholder="请输入角度" />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="标准要求" prop="standards">-->
|
||||
<!-- <el-input v-model="form.standards" type="textarea" placeholder="请输入内容" />-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="视频信息" prop="imageInfo">
|
||||
<file-upload v-model="form.imageInfo" :file-type="type" :file-size="500"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="视频时间" prop="detectTime">
|
||||
<el-date-picker clearable
|
||||
v-model="form.detectTime"
|
||||
type="date"
|
||||
value-format="yyyy-MM-dd"
|
||||
placeholder="请选择视频时间">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="结果" prop="detectResult">-->
|
||||
<!-- <el-input v-model="form.detectResult" placeholder="请输入结果" />-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" placeholder="请输入备注" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||
<el-button @click="cancel">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { listDock, getDock, delDock, addDock, updateDock } from "@/api/qcfgjManage/dock";
|
||||
const dataType="现场固定视频整合接入";
|
||||
export default {
|
||||
//产品外观尺寸数据对接
|
||||
name: "Dock",
|
||||
data() {
|
||||
return {
|
||||
// 遮罩层
|
||||
loading: true,
|
||||
// 选中数组
|
||||
ids: [],
|
||||
// 非单个禁用
|
||||
single: true,
|
||||
// 非多个禁用
|
||||
multiple: true,
|
||||
// 显示搜索条件
|
||||
showSearch: true,
|
||||
// 总条数
|
||||
total: 0,
|
||||
// 产品数据信息对接表格数据
|
||||
dockList: [],
|
||||
// 弹出层标题
|
||||
title: "",
|
||||
// 是否显示弹出层
|
||||
open: false,
|
||||
// 数据类型时间范围
|
||||
daterangeDetectTime: [],
|
||||
type:['mp4'],
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
productName: null,
|
||||
batchInfo: null,
|
||||
lengthInfo: null,
|
||||
wideInfo: null,
|
||||
heightInfo: null,
|
||||
angle: null,
|
||||
standards: null,
|
||||
imageInfo: null,
|
||||
detectTime: null,
|
||||
detectResult: null,
|
||||
dataType: dataType
|
||||
},
|
||||
// 表单参数
|
||||
form: {},
|
||||
// 表单校验
|
||||
rules: {
|
||||
}
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getList();
|
||||
},
|
||||
methods: {
|
||||
/** 查询产品数据信息对接列表 */
|
||||
getList() {
|
||||
this.loading = true;
|
||||
this.queryParams.params = {};
|
||||
if (null != this.daterangeDetectTime && '' != this.daterangeDetectTime) {
|
||||
this.queryParams.params["beginDetectTime"] = this.daterangeDetectTime[0];
|
||||
this.queryParams.params["endDetectTime"] = this.daterangeDetectTime[1];
|
||||
}
|
||||
listDock(this.queryParams).then(response => {
|
||||
this.dockList = response.rows;
|
||||
this.total = response.total;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
// 取消按钮
|
||||
cancel() {
|
||||
this.open = false;
|
||||
this.reset();
|
||||
},
|
||||
// 表单重置
|
||||
reset() {
|
||||
this.form = {
|
||||
id: null,
|
||||
productName: null,
|
||||
batchInfo: null,
|
||||
lengthInfo: null,
|
||||
wideInfo: null,
|
||||
heightInfo: null,
|
||||
angle: null,
|
||||
standards: null,
|
||||
imageInfo: null,
|
||||
detectTime: null,
|
||||
detectResult: null,
|
||||
remark: null,
|
||||
dataType: null
|
||||
};
|
||||
this.resetForm("form");
|
||||
},
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
this.queryParams.pageNum = 1;
|
||||
this.getList();
|
||||
},
|
||||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.daterangeDetectTime = [];
|
||||
this.resetForm("queryForm");
|
||||
this.handleQuery();
|
||||
},
|
||||
// 多选框选中数据
|
||||
handleSelectionChange(selection) {
|
||||
this.ids = selection.map(item => item.id)
|
||||
this.single = selection.length!==1
|
||||
this.multiple = !selection.length
|
||||
},
|
||||
/** 新增按钮操作 */
|
||||
handleAdd() {
|
||||
this.reset();
|
||||
this.open = true;
|
||||
this.title = "添加"+dataType;
|
||||
this.form.dataType=dataType;
|
||||
},
|
||||
/** 修改按钮操作 */
|
||||
handleUpdate(row) {
|
||||
this.reset();
|
||||
const id = row.id || this.ids
|
||||
getDock(id).then(response => {
|
||||
this.form = response.data;
|
||||
this.open = true;
|
||||
this.title = "修改"+dataType;
|
||||
});
|
||||
},
|
||||
/** 提交按钮 */
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (valid) {
|
||||
if (this.form.id != null) {
|
||||
updateDock(this.form).then(response => {
|
||||
this.$modal.msgSuccess("修改成功");
|
||||
this.open = false;
|
||||
this.getList();
|
||||
});
|
||||
} else {
|
||||
addDock(this.form).then(response => {
|
||||
this.$modal.msgSuccess("新增成功");
|
||||
this.open = false;
|
||||
this.getList();
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
/** 删除按钮操作 */
|
||||
handleDelete(row) {
|
||||
const ids = row.id || this.ids;
|
||||
this.$modal.confirm('是否确认删除'+dataType+'编号为"' + ids + '"的数据项?').then(function() {
|
||||
return delDock(ids);
|
||||
}).then(() => {
|
||||
this.getList();
|
||||
this.$modal.msgSuccess("删除成功");
|
||||
}).catch(() => {});
|
||||
},
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
this.download('qcfgjManage/dock/export', {
|
||||
...this.queryParams
|
||||
}, `dock_${new Date().getTime()}.xlsx`)
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
Loading…
Reference in New Issue
Block a user