-
-
-
-
+
+
+
+
+
@@ -36,8 +37,8 @@ const props = defineProps({
source: {
type: Object,
required: true,
- default: () => ({ url: "", promt: "" })
- }
+ default: () => ({ url: "", promt: "" }),
+ },
});
const emit = defineEmits(["sourceStarted"]);
@@ -48,14 +49,14 @@ const displayUrl = computed({
get: () => props.source.url || "",
set: (val) => {
// Только для чтения
- }
+ },
});
const displayPromt = computed({
get: () => props.source.promt || "",
set: (val) => {
// Только для чтения
- }
+ },
});
const startParsing = async () => {
@@ -65,13 +66,14 @@ const startParsing = async () => {
}
isLoading.value = true;
-
+
try {
- await axios.post("https://allowlgroup.ru/api/parser_all", {
+ // await axios.post("https://allowlgroup.ru/api/8001/parser_all", {
+ await axios.post("http://127.0.0.1:8001/parser_all", {
url: props.source.url,
- promt: props.source.promt
+ promt: props.source.promt,
});
-
+
emit("sourceStarted", props.source.url);
alert(`Парсинг для ${props.source.url} запущен`);
} catch (err) {
@@ -81,4 +83,4 @@ const startParsing = async () => {
isLoading.value = false;
}
};
-
\ No newline at end of file
+