add medreport schema
This commit is contained in:
@@ -137,6 +137,7 @@ async function syncData() {
|
||||
for (const analysisGroup of analysisGroups) {
|
||||
// SAVE ANALYSIS GROUP
|
||||
const { data: insertedAnalysisGroup, error } = await supabase
|
||||
.schema('medreport')
|
||||
.from('analysis_groups')
|
||||
.upsert(
|
||||
{
|
||||
@@ -174,6 +175,7 @@ async function syncData() {
|
||||
const analysisElement = item.UuringuElement;
|
||||
|
||||
const { data: insertedAnalysisElement, error } = await supabase
|
||||
.schema('medreport')
|
||||
.from('analysis_elements')
|
||||
.upsert(
|
||||
{
|
||||
@@ -217,6 +219,7 @@ async function syncData() {
|
||||
if (analyses?.length) {
|
||||
for (const analysis of analyses) {
|
||||
const { data: insertedAnalysis, error } = await supabase
|
||||
.schema('medreport')
|
||||
.from('analyses')
|
||||
.upsert(
|
||||
{
|
||||
@@ -259,7 +262,7 @@ async function syncData() {
|
||||
}
|
||||
}
|
||||
|
||||
await supabase.from('codes').upsert(codes);
|
||||
await supabase.schema('medreport').from('codes').upsert(codes);
|
||||
|
||||
await supabase.schema('audit').from('sync_entries').insert({
|
||||
operation: 'ANALYSES_SYNC',
|
||||
|
||||
Reference in New Issue
Block a user