The discussion revolves around locating staff notices in the Discourse database. j127 is trying to query staff notices, specifically a recent custom one, but is having trouble finding where they are stored. tgxworld suggests using PlugintStoreRow.where(plugin_name: "user_notes"), but j127 clarifies they are looking for “staff notices” (a core feature) rather than “user notes” (a plugin).
tgxworld points out that staff notices are stored in custom fields, referencing the Discourse GitHub repository. j127 shares a Rails console command to skim through the data, but ultimately doesn’t find the custom text they were looking for, suggesting the staff notice they sought isn’t live.
Does anyone know how to query staff notes notices from the database? I’ve been looking around in the code but haven’t been able to find where they are stored.
My main goal is to find a specific staff notice that was written in the past week, so I’m looking for a way to skim through the recent custom ones.
Edit: I was having trouble, because I was looking for “staff notes”. I’ve just found a custom_field that might be what I’m looking for, but I’m not sure how to list all the staff notices with custom text.