Skip to content

Commit a01e865

Browse files
committed
CollecTF migrated
1 parent 5387fea commit a01e865

File tree

3 files changed

+15
-13
lines changed

3 files changed

+15
-13
lines changed

public/CollecTF.db.gz

-17.6 MB
Binary file not shown.

src/db/queries/search.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@ export async function getTFWithFamilies() {
2222

2323
const query = `
2424
SELECT
25-
tff.TF_family_id as family_id, tff.name as family_name,
25+
tff.tf_family_id as family_id, tff.name as family_name,
2626
tf.TF_id as element_id, tf.name as element_name
2727
FROM core_tffamily tff
28-
LEFT JOIN core_tf tf ON tff.TF_family_id = tf.family_id
28+
LEFT JOIN core_tf tf ON tff.tf_family_id = tf.family_id
2929
ORDER BY tff.name, tf.name;
3030
`
3131
//This will return something like this:
@@ -41,7 +41,7 @@ export async function getTFWithFamilies() {
4141
}
4242

4343
export async function getAllTfFamilies() {
44-
return runQuery("SELECT TF_family_id, name FROM core_tffamily")
44+
return runQuery("SELECT tf_family_id, name FROM core_tffamily")
4545
}
4646

4747
export async function getNameAndFamilyIdFromTf(tfId) {

src/utils/serverless.js

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,17 @@
22
const dispatchUrl = "https://collectf.vercel.app/api/functions/send-form.ts" // "https://collectf.vercel.app/api/functions/send-form.ts"; "http://localhost:3000/api/auth/functions/send-form.ts"
33

44
export async function dispatchWorkflow(data) {
5-
6-
const res = await fetch(dispatchUrl, {
7-
method: 'POST',
8-
headers: {
9-
'Content-Type': 'application/json',
10-
},
11-
credentials: 'include',
12-
body: JSON.stringify(data),
13-
});
145

15-
return await res;
6+
console.log("Data to dispatch:", data);
7+
8+
const res = await fetch(dispatchUrl, {
9+
method: 'POST',
10+
headers: {
11+
'Content-Type': 'application/json',
12+
},
13+
credentials: 'include',
14+
body: JSON.stringify(data),
15+
});
16+
17+
return await res;
1618
}

0 commit comments

Comments
 (0)