mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 02:16:05 +01:00 
			
		
		
		
	
		
			
	
	
		
			17 lines
		
	
	
		
			313 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
		
		
			
		
	
	
			17 lines
		
	
	
		
			313 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
|  | "use strict"; | ||
|  | 
 | ||
|  | class Note { | ||
|  |     constructor(sql, row) { | ||
|  |         this.sql = sql; | ||
|  | 
 | ||
|  |         for (const key in row) { | ||
|  |             this[key] = row[key]; | ||
|  |         } | ||
|  |     } | ||
|  | 
 | ||
|  |     async attributes() { | ||
|  |         return this.sql.getAll("SELECT * FROM attributes WHERE noteId = ?", [this.noteId]); | ||
|  |     } | ||
|  | } | ||
|  | 
 | ||
|  | module.exports = Note; |