Needle
04/14/2022, 4:16 PM/title
command!
We have solved your problem?
Click the button below to archive it.aquaspirit
04/14/2022, 5:57 PMAshwaqAzan
04/14/2022, 7:49 PMEfizzz
04/14/2022, 8:38 PMjavascript
const insertListing = async () => {
try {
const { data, error } = await client
.from("product")
.insert([{ title: "hello" }], { returning: "minimal" });
console.log(data || error);
} catch (error) {
alert(error.message);
}
};
I see that I am an authenticated user in the session when I run the function
And I can see that I am hitting the API:
200 OPTIONS /rest/vi/product
But I get an error in my console:
FetchError: Failed to fetch
Not sure what it's trying to fetch if minimal is on... and this is an insert any way. Should this be an OPTIONS rather than POST?Chezaur
04/14/2022, 8:47 PMdenik1981
04/14/2022, 10:22 PMMuezz
04/14/2022, 11:02 PMsql
if new."category" is "rand_category"
then
//Do somthing
else
//Do somthing else
end if;
kodestallion
04/14/2022, 11:17 PMeoin
04/15/2022, 12:28 AMuid
is checked within an array or jsonb cell for their RLS policy?
What I want: An RLS policy which checks if auth.uid()
is a value within a players
array or jsonb column cell to determine if they should be able to see the /game/uuid
page.nikivi
04/15/2022, 1:33 AMNeedle
04/15/2022, 1:33 AM/title
command!
We have solved your problem?
Click the button below to archive it.Needle
04/15/2022, 1:33 AM/title
command!
We have solved your problem?
Click the button below to archive it.Needle
04/15/2022, 1:33 AM/title
command!
We have solved your problem?
Click the button below to archive it.Needle
04/15/2022, 1:33 AM/title
command!
We have solved your problem?
Click the button below to archive it.chrisb2244
04/15/2022, 1:38 AM(uid() = owner)
in RLS policies...
The goal is to create user profiles with avatars when transferring from a previous site - I can create the users but I don't want to have their images be owned by some sort of admin role...jar
04/15/2022, 2:44 AMNeedle
04/15/2022, 3:50 AM/title
command!
We have solved your problem?
Click the button below to archive it.Kariak
04/15/2022, 4:23 AMApe R Us
04/15/2022, 5:40 AMlet num = 0;
let totalAttendees = [];
let attendee = {
id: 1,
first: '',
age: undefined
};
function addPerson() {
total = [...total, attendee];
}
const add = async (totalAttendees) => {
try { const { error } = await supabase.from('name').upsert(totalAttendees);
if (error) throw error;
} catch (e) {
console.log(e.message);
} finally {
console.log('success');
}
};
this is the input to select how much forms should appear
<input type="number" class="bg-transparent" bind:value={num} />
this is me iterating
{#each Array(num) as _, i}
<div>
<input type="text" bind:value={attendee.first} class="bg-transparent" placeholder="first" />
<input type="number" bind:value={attendee.age} class="bg-transparent" placeholder="age" />
<button type="button" on:click={addPerson}>add</button>
</div>
{/each}
it works, however the problem im getting is that when i enter info in any field its updating in all,
is there anyway where each div inputs will be unique so it wont updateHostile_Zombie
04/15/2022, 7:10 AMakito
04/15/2022, 8:04 AMINSERT
(corresponding to copyObject
, getSignedObject
, and createObject
)? I'm not sure whether getSignedObject
returns just a hash or the actual object like getObject
does. Also, how would I implement limiting to prevent a malicious user from filling up my storage bucket with junk?prattjc
04/15/2022, 8:30 AMcharbs
04/15/2022, 10:23 AMPG_GRAPHQL
?baran
04/15/2022, 10:34 AMHπΆπ³π πΊπ―πΆπ»
04/15/2022, 11:14 AMJonathan H
04/15/2022, 1:52 PMInvader
04/15/2022, 5:50 PMdope
04/15/2022, 5:59 PMDerek
04/15/2022, 8:19 PMbill92
04/15/2022, 10:17 PM