Merge branch 'main' of http://47.92.168.204:3000/VoRDM/vordm-admin
This commit is contained in:
commit
fdcf70cf38
|
@ -236,10 +236,11 @@ const openDialog = (row) => {
|
|||
state.isShowDialog = true;
|
||||
}
|
||||
const getDate = () => {
|
||||
getList(1, 10, { disasterId: state.data.disasterId }).then(res => {
|
||||
getList(1, 9999, { disasterId: state.data.disasterId }).then(res => {
|
||||
let data = res.records;
|
||||
for (let index = 0; index < data.length; index++) {
|
||||
const element = data[index];
|
||||
|
||||
if (element.type == 2) {
|
||||
state.baidu = element;
|
||||
}
|
||||
|
@ -310,12 +311,12 @@ const start = (text) => {
|
|||
if(text =='baidu' || text == 'bing'){
|
||||
news(ret[0].disasterId, keywords, page, (text == "baidu"), ret[0].id).then(res => {
|
||||
ElMessage.success("Data is being acquired!")
|
||||
getData();
|
||||
getDate();
|
||||
})
|
||||
}else if(text == 'twitter'){
|
||||
twitter(ret[0].disasterId,keywords,state.twitter.date[0],state.twitter.date[1],ret[0].id).then(res=>{
|
||||
ElMessage.success("Data is being acquired!")
|
||||
getData();
|
||||
getDate();
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
|
@ -339,9 +339,16 @@ const startCrawl = () => {
|
|||
})
|
||||
//调用爬虫服务
|
||||
rs2(state.data.disasterId,arrParams,state.startTime,state.endTime).then(res => {
|
||||
//获取arrParams中的type 使用,分割
|
||||
var typeArr=[];
|
||||
arrParams.forEach(item=>{
|
||||
typeArr.push(item.type)
|
||||
})
|
||||
var typeStr=typeArr.join('、')
|
||||
|
||||
// getData();
|
||||
ElMessage({
|
||||
message: 'Success, Start crawling. sentinel',
|
||||
message: 'Successfully launched '+typeStr+' crawler',
|
||||
type: 'success',
|
||||
})
|
||||
})
|
||||
|
|
|
@ -25,14 +25,14 @@
|
|||
<el-col :xs="24" :sm="24" :md="24" :lg="24" :xl="24" class="mb20">
|
||||
<el-row :gutter="35" v-for="(v, k) in state.ruleForm.children" :key="k">
|
||||
<el-col :xs="24" :sm="12" :md="12" :lg="12" :xl="12" class="mb20">
|
||||
<el-form-item :prop="`list[${k}].label`" label-width="180">
|
||||
<el-form-item :prop="`list[${k}].label`" label-width="240">
|
||||
<template #label>
|
||||
<el-button type="primary" circle size="small" @click="onAddRow" v-if="k === 0">
|
||||
<el-button type="primary" circle size="small" @click="onAddRow" v-if="k === state.ruleForm.children.length-1">
|
||||
<el-icon>
|
||||
<ele-Plus />
|
||||
</el-icon>
|
||||
</el-button>
|
||||
<el-button type="danger" circle size="small" @click="onDelRow(k)" v-else>
|
||||
<el-button type="danger" circle size="small" @click="onDelRow(k)">
|
||||
<el-icon>
|
||||
<ele-Delete />
|
||||
</el-icon>
|
||||
|
|
|
@ -2,8 +2,8 @@
|
|||
<div class="system-dic-container layout-padding">
|
||||
<el-card shadow="hover" class="layout-padding-auto">
|
||||
<div class="system-user-search mb15">
|
||||
<el-input size="default" placeholder="Please enter a dictionary name" style="max-width: 180px" v-model="state.query.dictValue"> </el-input>
|
||||
<el-button size="default" type="primary" class="ml10">
|
||||
<el-input size="default" placeholder="Please enter a dictionary name" style="max-width: 180px" v-model="state.query.dictValue"> </el-input>
|
||||
<el-button size="default" type="primary" class="ml10" @click="getTableData()">
|
||||
<el-icon>
|
||||
<ele-Search />
|
||||
</el-icon>
|
||||
|
@ -79,7 +79,7 @@ const state = reactive({
|
|||
// 初始化表格数据
|
||||
const getTableData = () => {
|
||||
state.tableData.loading = true;
|
||||
getList().then((res) => {
|
||||
getList({dictValue_equal:state.query.dictValue}).then((res) => {
|
||||
state.tableData.data = res;
|
||||
state.tableData.loading = false;
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue