瀏覽代碼

add id behind sentence

visuddhinanda 9 月之前
父節點
當前提交
bc7867b3fe
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      api-v8/app/Services/SearchPaliDataService.php

+ 1 - 1
api-v8/app/Services/SearchPaliDataService.php

@@ -113,7 +113,7 @@ class SearchPaliDataService
         foreach ($sentences as $key => $sentence) {
             $content = $this->getSentenceText($book, $para, $sentence->word_begin, $sentence->word_end);
             $id = "{$book}-{$para}-{$sentence->word_begin}-{$sentence->word_end}";
-            $markdown[] = $content['markdown'];
+            $markdown[] = "`id:{$id}`" . $content['markdown'];
             $text[] = $content['text'];
             $wordList = array_merge($wordList, $content['words']);
         }