..., 'content' => ...]。 * id 与巴利原文 / 译文一致(book-para-word_start-word_end),便于按句对应。 * 无 nissaya 数据时返回空数组。 * * @return array */ public function forParagraph(int $book, int $para): array { $sentences = Sentence::nissaya() ->language('my') // 缅文 nissaya ->where('book_id', $book) ->where('paragraph', $para) ->orderBy('word_start') ->get(); $result = []; foreach ($sentences as $sentence) { if (empty($sentence->content)) { continue; } $id = "{$sentence->book_id}-{$sentence->paragraph}-{$sentence->word_start}-{$sentence->word_end}"; $result[] = ['id' => $id, 'content' => $sentence->content]; } return $result; } }