未登录账号禁用爬取按钮
This commit is contained in:
@@ -176,7 +176,7 @@ let pyData = ref({
|
||||
});
|
||||
|
||||
//按钮提交状态
|
||||
let submitting = ref(false);
|
||||
let submitting = ref(true);
|
||||
|
||||
onMounted(() => {
|
||||
//从缓存获取数据
|
||||
@@ -217,14 +217,14 @@ const getIpInfo = async () => {
|
||||
const submit = () => {
|
||||
pyData.value.country = countryData.value;
|
||||
console.log('提交的区间值:', pyData.value);
|
||||
if (tkData.value[0].account == '' || tkData.value[1].account == '') {
|
||||
ElMessage.error('请输入账号密码');
|
||||
return;
|
||||
}
|
||||
if (tkData.value[0].password == '' || tkData.value[1].password == '') {
|
||||
ElMessage.error('请输入账号密码');
|
||||
return;
|
||||
}
|
||||
// if (tkData.value[0].account == '' && tkData.value[1].account == '') {
|
||||
// ElMessage.error('请输入账号密码');
|
||||
// return;
|
||||
// }
|
||||
// if (tkData.value[0].password == '' && tkData.value[1].password == '') {
|
||||
// ElMessage.error('请输入账号密码');
|
||||
// return;
|
||||
// }
|
||||
ElMessageBox.confirm(
|
||||
'确认开始爬取数据?',
|
||||
'开始',
|
||||
@@ -339,6 +339,7 @@ function getloginStatus() {
|
||||
if (data.code == 1) {
|
||||
clearInterval(statusTimer);
|
||||
statusTimer = null;
|
||||
submitting.value = false
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -350,6 +351,8 @@ function getloginStatusCopy() {
|
||||
if (data.code == 1) {
|
||||
clearInterval(statusTimer);
|
||||
statusTimer = null;
|
||||
submitting.value = false
|
||||
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user