(domainId: string, uid: number)
| 47 | } |
| 48 | |
| 49 | static getByUser(domainId: string, uid: number) { |
| 50 | return document.getMulti( |
| 51 | domainId, document.TYPE_PROBLEM_SOLUTION, |
| 52 | { parentType: document.TYPE_PROBLEM, owner: uid }, |
| 53 | ).sort({ _id: -1 }); |
| 54 | } |
| 55 | |
| 56 | static reply(domainId: string, psid: ObjectId, owner: number, content: string) { |
| 57 | return document.push(domainId, document.TYPE_PROBLEM_SOLUTION, psid, 'reply', content, owner); |