This commit is contained in:
payacom
2026-08-31 20:45:41 +03:30
parent fa9f23c61d
commit 3f416a7a60
367 changed files with 621895 additions and 6443 deletions

View File

@@ -27,6 +27,27 @@ const notificationSchema = new mongoose.Schema({
read: {
type: Boolean,
default: false // وضعیت خوانده شده یا نشده
},
actor_id: {
type: mongoose.Schema.Types.ObjectId,
ref: 'User',
required: false
},
// فقط برای اعلان‌های همگانی پنل — جدا از read (که یعنی صفحه اعلان‌ها باز شده)،
// seen یعنی پوش واقعاً به دستگاه رسیده و clicked یعنی کاربر روش ضربه زده
broadcast_id: {
type: mongoose.Schema.Types.ObjectId,
ref: 'AdminBroadcast',
required: false,
index: true
},
push_delivered_seen: {
type: Boolean,
default: false
},
push_clicked: {
type: Boolean,
default: false
}
})