Skip to main content
Version: 1.0.0

Log_Loading_Models

Purpose​

The Log_Loading_Models collection defines the log structure for 3D model loading and variant management.
Its purpose is to store detailed information about actions performed on glasses models, including assignments, approvals, rejections, and publication events.

Document schema​

{
"glassesRef": "reference",
"lista_log_Glasses": [
{
"account": "reference",
"action": "string",
"color_frame": "string",
"color_lense": "string",
"data": "timestamp",
"modelRef": "string",
"modify_model": {
"rejectCount": "number",
"requestCount": "number",
"status": "boolean"
},
"sizeRef": "string",
"sku_number": "string"
}
],
"lista_log_variant": [
{
"account": "reference",
"action": "string",
"color_frame": "string",
"color_lense": "string",
"data": "timestamp",
"modelRef": "string",
"modify_model": {
"rejectCount": "number",
"requestCount": "number",
"status": "boolean"
},
"sizeRef": "string",
"sku_number": "string"
}
],
"refModeller": "reference"
}

Indexes​

  • glassesRef is a reference to Occhiale collection;
  • lista_log_Glasses.account is a reference to Profile collection;
  • lista_log_variant.account is a reference to Profile collection;
  • refModeller is a reference to Profile collection.

Query examples​

// Fetch the Reference Doc from Firebase
const logLoadingModelsRefDoc = doc(db, "Log_Loading_Models", logId);

// Get the Document Snapshot from the Reference Doc
const logLoadingModelsRefSnap = await getDoc(logLoadingModelsRefDoc);