mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-25 10:10:08 +02:00
Upgrade Mongoose and the Mongo driver in web GitOrigin-RevId: 2cad1aabe57eae424a9e4c68b2e0062f0e78ffaf
24 lines
613 B
JavaScript
24 lines
613 B
JavaScript
const mongoose = require('../infrastructure/Mongoose')
|
|
const { Schema } = mongoose
|
|
|
|
const UserAuditLogEntrySchema = new Schema(
|
|
{
|
|
userId: { type: Schema.Types.ObjectId, index: true },
|
|
info: { type: Object },
|
|
initiatorId: { type: Schema.Types.ObjectId },
|
|
ipAddress: { type: String },
|
|
operation: { type: String },
|
|
timestamp: { type: Date, default: Date.now },
|
|
},
|
|
{
|
|
collection: 'userAuditLogEntries',
|
|
minimize: false,
|
|
}
|
|
)
|
|
|
|
exports.UserAuditLogEntry = mongoose.model(
|
|
'UserAuditLogEntry',
|
|
UserAuditLogEntrySchema
|
|
)
|
|
exports.UserAuditLogEntrySchema = UserAuditLogEntrySchema
|