- Timestamp:
- 2021-09-20T16:50:02+12:00 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/model-interfaces-dev/atea/korero-maori-asr/src/main.js
r35432 r35433 13 13 constructor(transcription, file) { 14 14 /** @type {String} The UUID of this transcription. */ 15 this.id = file.name + file.size + file.type; // Should be a fairly reliable indicator of uniqueness.15 this.id = TranscriptionViewModel.getId(file); // Should be a fairly reliable indicator of uniqueness. 16 16 17 17 /** @type {String} The transcription. */ … … 26 26 /** @type {File} The file from which the transcription was generated. */ 27 27 this.file = file; 28 } 29 30 static getId(file) { 31 return file.name + file.size + file.type; 28 32 } 29 33 } … … 110 114 state.translations = translations; 111 115 } 116 }, 117 getters: { 118 hasTranscriptionOfFile: (state) => (file) => { 119 const id = TranscriptionViewModel.getId(file); 120 return state.rawTranscriptions.has(id); 121 } 112 122 } 113 123 });
Note:
See TracChangeset
for help on using the changeset viewer.