|
|
|
@ -172,7 +172,7 @@
|
|
|
|
|
<!-- 添加或修改通报对话框 -->
|
|
|
|
|
<el-dialog
|
|
|
|
|
:visible.sync="open"
|
|
|
|
|
width="500px"
|
|
|
|
|
width="1000px"
|
|
|
|
|
append-to-body
|
|
|
|
|
custom-class="dialog-box"
|
|
|
|
|
>
|
|
|
|
@ -184,64 +184,90 @@
|
|
|
|
|
label-width="auto"
|
|
|
|
|
class="dialog-from"
|
|
|
|
|
>
|
|
|
|
|
<el-form-item label="区域id" prop="areaId">
|
|
|
|
|
<el-select v-model="form.areaId" placeholder="请选择区域" filterable>
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="dict in townList"
|
|
|
|
|
:key="dict.value"
|
|
|
|
|
:label="dict.label"
|
|
|
|
|
:value="parseInt(dict.value)"
|
|
|
|
|
></el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="通报类型" prop="tbType">
|
|
|
|
|
<el-select v-model="form.tbType" placeholder="请选择通报类型">
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="dict in dict.type.tc_tb_type"
|
|
|
|
|
:key="dict.value"
|
|
|
|
|
:label="dict.label"
|
|
|
|
|
:value="parseInt(dict.value)"
|
|
|
|
|
></el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="部门名称" prop="depName">
|
|
|
|
|
<el-input v-model="form.depName" placeholder="请输入部门名称" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="目标IP/域名" prop="depName">
|
|
|
|
|
<el-input v-model="form.depName" placeholder="请输入目标IP/域名" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="处置状态" prop="depName">
|
|
|
|
|
<el-select v-model="form.tbType" placeholder="请选择处置状态">
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="dict in dict.type.tc_tb_type"
|
|
|
|
|
:key="dict.value"
|
|
|
|
|
:label="dict.label"
|
|
|
|
|
:value="parseInt(dict.value)"
|
|
|
|
|
></el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item
|
|
|
|
|
label="属地名称"
|
|
|
|
|
prop="locationName"
|
|
|
|
|
|
|
|
|
|
>
|
|
|
|
|
<el-input v-model="form.locationName" placeholder="请输入属地名称" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
|
|
<el-form-item label="通报时间" prop="tbTime">
|
|
|
|
|
<el-date-picker
|
|
|
|
|
clearable
|
|
|
|
|
size="small"
|
|
|
|
|
v-model="form.tbTime"
|
|
|
|
|
type="date"
|
|
|
|
|
value-format="yyyy-MM-dd"
|
|
|
|
|
placeholder="选择通报时间"
|
|
|
|
|
>
|
|
|
|
|
</el-date-picker>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-form-item label="附件上传" prop="fileName">
|
|
|
|
|
<FileUpload v-model="fileList" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="区域id" prop="areaId">
|
|
|
|
|
<el-select
|
|
|
|
|
v-model="form.areaId"
|
|
|
|
|
placeholder="请选择区域"
|
|
|
|
|
filterable
|
|
|
|
|
>
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="dict in townList"
|
|
|
|
|
:key="dict.value"
|
|
|
|
|
:label="dict.label"
|
|
|
|
|
:value="parseInt(dict.value)"
|
|
|
|
|
></el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="通报类型" prop="tbType">
|
|
|
|
|
<el-select v-model="form.tbType" placeholder="请选择通报类型">
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="dict in dict.type.tc_tb_type"
|
|
|
|
|
:key="dict.value"
|
|
|
|
|
:label="dict.label"
|
|
|
|
|
:value="parseInt(dict.value)"
|
|
|
|
|
></el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="部门名称" prop="depName">
|
|
|
|
|
<el-input v-model="form.depName" placeholder="请输入部门名称" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="目标IP/域名" prop="ip">
|
|
|
|
|
<el-input v-model="form.ip" placeholder="请输入目标IP/域名" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="处置状态" prop="state">
|
|
|
|
|
<el-select v-model="form.state" placeholder="请选择处置状态">
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="dict in dict.type.tc_steam_state"
|
|
|
|
|
:key="dict.value"
|
|
|
|
|
:label="dict.label"
|
|
|
|
|
:value="parseInt(dict.value)"
|
|
|
|
|
></el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="属地名称" prop="locationName">
|
|
|
|
|
<el-input
|
|
|
|
|
v-model="form.locationName"
|
|
|
|
|
placeholder="请输入属地名称"
|
|
|
|
|
/>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="通报时间" prop="tbTime">
|
|
|
|
|
<el-date-picker
|
|
|
|
|
clearable
|
|
|
|
|
size="small"
|
|
|
|
|
v-model="form.tbTime"
|
|
|
|
|
type="date"
|
|
|
|
|
value-format="yyyy-MM-dd"
|
|
|
|
|
placeholder="选择通报时间"
|
|
|
|
|
>
|
|
|
|
|
</el-date-picker>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="12">
|
|
|
|
|
<el-form-item label="附件上传" prop="fileName">
|
|
|
|
|
<FileUpload v-model="fileList" />
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
</el-form>
|
|
|
|
|
<div slot="footer" class="dialog-footer">
|
|
|
|
|
<el-button type="primary" @click="submitForm">确 定</el-button>
|
|
|
|
@ -251,7 +277,7 @@
|
|
|
|
|
<!--查看通报详情页-->
|
|
|
|
|
<el-dialog
|
|
|
|
|
:visible.sync="infoOpen"
|
|
|
|
|
width="1200px"
|
|
|
|
|
width="1000px"
|
|
|
|
|
append-to-body
|
|
|
|
|
:close-on-click-modal="false"
|
|
|
|
|
:destroy-on-close="true"
|
|
|
|
@ -269,22 +295,29 @@
|
|
|
|
|
$filterTown(form.areaId)
|
|
|
|
|
}}</el-descriptions-item>
|
|
|
|
|
|
|
|
|
|
<el-descriptions-item label="通报类型">
|
|
|
|
|
<dict-tag :options="dict.type.tc_tb_type" :value="form.tbType" />
|
|
|
|
|
</el-descriptions-item>
|
|
|
|
|
|
|
|
|
|
<el-descriptions-item label="部门名称">{{
|
|
|
|
|
form.depName
|
|
|
|
|
}}</el-descriptions-item>
|
|
|
|
|
<el-descriptions-item label="目标IP/域名">{{
|
|
|
|
|
form.ip
|
|
|
|
|
}}</el-descriptions-item>
|
|
|
|
|
<el-descriptions-item label="处置状态">
|
|
|
|
|
<dict-tag :options="dict.type.tc_steam_state" :value="form.state" />
|
|
|
|
|
</el-descriptions-item>
|
|
|
|
|
|
|
|
|
|
<el-descriptions-item label="属地名称">{{
|
|
|
|
|
form.locationName
|
|
|
|
|
}}</el-descriptions-item>
|
|
|
|
|
|
|
|
|
|
<el-descriptions-item label="通报类型">
|
|
|
|
|
<dict-tag :options="dict.type.tc_tb_type" :value="form.tbType" />
|
|
|
|
|
</el-descriptions-item>
|
|
|
|
|
|
|
|
|
|
<el-descriptions-item label="通报时间">{{
|
|
|
|
|
form.tbTime
|
|
|
|
|
}}</el-descriptions-item>
|
|
|
|
|
</el-descriptions>
|
|
|
|
|
<FileView :fileList="fileList" />
|
|
|
|
|
</el-dialog>
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
@ -305,10 +338,10 @@ export default {
|
|
|
|
|
},
|
|
|
|
|
name: "Tb",
|
|
|
|
|
//注释字典
|
|
|
|
|
dicts: ["tc_tb_type"],
|
|
|
|
|
dicts: ["tc_tb_type", "tc_steam_state"],
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
fileList:[],
|
|
|
|
|
fileList: [],
|
|
|
|
|
tableHeigth: 0,
|
|
|
|
|
//查看详情
|
|
|
|
|
infoOpen: false,
|
|
|
|
@ -339,12 +372,13 @@ export default {
|
|
|
|
|
pageNum: 1,
|
|
|
|
|
pageSize: 10,
|
|
|
|
|
depName: null,
|
|
|
|
|
|
|
|
|
|
locationName: null,
|
|
|
|
|
|
|
|
|
|
tbType: null,
|
|
|
|
|
|
|
|
|
|
tbTime: null,
|
|
|
|
|
ip: null,
|
|
|
|
|
state: null,
|
|
|
|
|
fileName: null,
|
|
|
|
|
fileUrl: null,
|
|
|
|
|
},
|
|
|
|
|
// 表单参数
|
|
|
|
|
form: {},
|
|
|
|
@ -406,7 +440,12 @@ export default {
|
|
|
|
|
updateTime: null,
|
|
|
|
|
|
|
|
|
|
remark: null,
|
|
|
|
|
ip: null,
|
|
|
|
|
state: null,
|
|
|
|
|
fileName: null,
|
|
|
|
|
fileUrl: null,
|
|
|
|
|
};
|
|
|
|
|
this.fileList = [];
|
|
|
|
|
this.resetForm("form");
|
|
|
|
|
},
|
|
|
|
|
/** 搜索按钮操作 */
|
|
|
|
@ -430,6 +469,7 @@ export default {
|
|
|
|
|
this.reset();
|
|
|
|
|
const id = row.id || this.ids;
|
|
|
|
|
getTb(id).then((response) => {
|
|
|
|
|
this.filterFile(2, response.data.fileName, response.data.fileUrl);
|
|
|
|
|
this.form = response.data;
|
|
|
|
|
this.infoOpen = true;
|
|
|
|
|
this.infoTitle = "查看通报详情";
|
|
|
|
@ -446,15 +486,48 @@ export default {
|
|
|
|
|
this.reset();
|
|
|
|
|
const id = row.id || this.ids;
|
|
|
|
|
getTb(id).then((response) => {
|
|
|
|
|
this.filterFile(2, response.data.fileName, response.data.fileUrl);
|
|
|
|
|
this.form = response.data;
|
|
|
|
|
this.open = true;
|
|
|
|
|
this.title = "修改通报";
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
filterFile(state, fileName, fileUrl) {
|
|
|
|
|
//1.提交 else 查看
|
|
|
|
|
if (state == 1) {
|
|
|
|
|
let fileName = [];
|
|
|
|
|
let fileUrl = [];
|
|
|
|
|
if (this.fileList.length > 0) {
|
|
|
|
|
this.fileList.forEach((item) => {
|
|
|
|
|
fileName.push(item.name);
|
|
|
|
|
fileUrl.push(item.url);
|
|
|
|
|
});
|
|
|
|
|
this.form.fileName = fileName.join(",");
|
|
|
|
|
this.form.fileUrl = fileUrl.join(",");
|
|
|
|
|
} else {
|
|
|
|
|
this.form.fileName = "";
|
|
|
|
|
this.form.fileUrl = "";
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
if (fileName || fileUrl) {
|
|
|
|
|
fileName = fileName.split(",");
|
|
|
|
|
fileUrl = fileUrl.split(",");
|
|
|
|
|
fileName.forEach((item, index) => {
|
|
|
|
|
this.fileList.push({
|
|
|
|
|
name: item,
|
|
|
|
|
url: fileUrl[index],
|
|
|
|
|
});
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
this.fileList = [];
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
/** 提交按钮 */
|
|
|
|
|
submitForm() {
|
|
|
|
|
this.$refs["form"].validate((valid) => {
|
|
|
|
|
if (valid) {
|
|
|
|
|
this.filterFile(1);
|
|
|
|
|
if (this.form.id != null) {
|
|
|
|
|
updateTb(this.form).then((response) => {
|
|
|
|
|
this.$modal.msgSuccess("修改成功");
|
|
|
|
|