top of page

import { getAttendanceAssignmentOptions, saveAttendanceRecords } from "backend/sgvccPortal.web"; $w.onReady(async function () { const panel = $w("#html1"); ["Text", "Button", "TextInput", "NumberInput", "Dropdown", "DatePicker"].forEach((type) => { try { $w(type).collapse(); } catch (error) {} }); ["#button2", "#awardDate", "#seasonInput", "#studentDropdown", "#awardDropdown"].forEach((id) => { try { $w(id).collapse(); } catch (error) {} }); panel.onMessage(async (event) => { const message = event.data || {}; if (message.type === "ready") { await loadStudents(panel); return; } if (message.type === "saveAttendance") { try { const result = await saveAttendanceRecords({ date: message.date, records: message.records || [] }); panel.postMessage({ type: "result", ok: true, saved: result.saved }); } catch (error) { console.error("Attendance save failed", error); panel.postMessage({ type: "result", ok: false, message: "Unable to save attendance. Please sign in with a Wix staff account." }); } } }); await loadStudents(panel); }); async function loadStudents(panel) { try { const students = await getAttendanceAssignmentOptions(); panel.postMessage({ type: "students", students }); } catch (error) { console.error("Student loading failed", error); panel.postMessage({ type: "students", students: [] }); } }

import { getAttendanceAssignmentOptions, saveAttendanceRecords } from "backend/sgvccPortal.web"; $w.onReady(async function () { const panel = $w("#html1"); ["Text", "Button", "TextInput", "NumberInput", "Dropdown", "DatePicker"].forEach((type) => { try { $w(type).collapse(); } catch (error) {} }); ["#button2", "#awardDate", "#seasonInput", "#studentDropdown", "#awardDropdown"].forEach((id) => { try { $w(id).collapse(); } catch (error) {} }); panel.onMessage(async (event) => { const message = event.data || {}; if (message.type === "ready") { await loadStudents(panel); return; } if (message.type === "saveAttendance") { try { const result = await saveAttendanceRecords({ date: message.date, records: message.records || [] }); panel.postMessage({ type: "result", ok: true, saved: result.saved }); } catch (error) { console.error("Attendance save failed", error); panel.postMessage({ type: "result", ok: false, message: "Unable to save attendance. Please sign in with a Wix staff account." }); } } }); await loadStudents(panel); }); async function loadStudents(panel) { try { const students = await getAttendanceAssignmentOptions(); panel.postMessage({ type: "students", students }); } catch (error) { console.error("Student loading failed", error); panel.postMessage({ type: "students", students: [] }); } }

import { getAttendanceAssignmentOptions, saveAttendanceRecords } from "backend/sgvccPortal.web"; $w.onReady(async function () { const panel = $w("#html1"); ["Text", "Button", "TextInput", "NumberInput", "Dropdown", "DatePicker"].forEach((type) => { try { $w(type).collapse(); } catch (error) {} }); ["#button2", "#awardDate", "#seasonInput", "#studentDropdown", "#awardDropdown"].forEach((id) => { try { $w(id).collapse(); } catch (error) {} }); panel.onMessage(async (event) => { const message = event.data || {}; if (message.type === "ready") { await loadStudents(panel); return; } if (message.type === "saveAttendance") { try { const result = await saveAttendanceRecords({ date: message.date, records: message.records || [] }); panel.postMessage({ type: "result", ok: true, saved: result.saved }); } catch (error) { console.error("Attendance save failed", error); panel.postMessage({ type: "result", ok: false, message: "Unable to save attendance. Please sign in with a Wix staff account." }); } } }); await loadStudents(panel); }); async function loadStudents(panel) { try { const students = await getAttendanceAssignmentOptions(); panel.postMessage({ type: "students", students }); } catch (error) { console.error("Student loading failed", error); panel.postMessage({ type: "students", students: [] }); } }

9953 Las Tunas Dr. Temple City, CA 91780

©2026 by San Gabriel Valley Children's Choir (SGVCC) 南加兒童合唱團

  • Yelp
  • Youtube
  • Facebook
  • Google Places
bottom of page