Fix Change Phase
This commit is contained in:
@@ -58,7 +58,7 @@ const renderedPhases = computed(() => {
|
||||
})
|
||||
|
||||
const changeActivePhase = async (key) => {
|
||||
let item = await useSupabaseSelectSingle("projects",props.item.id,'*')
|
||||
let item = await useEntities("projects").selectSingle(props.item.id,'*')
|
||||
|
||||
let phaseLabel = ""
|
||||
|
||||
@@ -75,16 +75,18 @@ const changeActivePhase = async (key) => {
|
||||
return p
|
||||
})
|
||||
|
||||
const {error:updateError} = await supabase.from("projects").update({phases: item.phases}).eq("id",item.id)
|
||||
const res = await useEntities("projects").update(item.id, {phases:item.phases})
|
||||
|
||||
//const {error:updateError} = await supabase.from("projects").update({phases: item.phases}).eq("id",item.id)
|
||||
|
||||
|
||||
|
||||
const {error} = await supabase.from("historyitems").insert({
|
||||
/*const {error} = await supabase.from("historyitems").insert({
|
||||
createdBy: profileStore.activeProfile.id,
|
||||
tenant: profileStore.currentTenant,
|
||||
text: `Aktive Phase zu "${phaseLabel}" gewechselt`,
|
||||
project: item.id
|
||||
})
|
||||
})*/
|
||||
|
||||
emit("updateNeeded")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user