mirror of
https://github.com/serty2005/rmser.git
synced 2026-02-05 03:12:34 -06:00
2701-есть адекватный порядок для строк черновика и фикс пустого поиска
This commit is contained in:
@@ -161,7 +161,7 @@ func (s *Service) ProcessDocument(ctx context.Context, userID uuid.UUID, imgData
|
||||
|
||||
// 7. Матчинг и сохранение позиций
|
||||
var draftItems []drafts.DraftInvoiceItem
|
||||
for _, rawItem := range rawResult.Items {
|
||||
for i, rawItem := range rawResult.Items {
|
||||
item := drafts.DraftInvoiceItem{
|
||||
DraftID: draft.ID,
|
||||
RawName: rawItem.RawName,
|
||||
@@ -170,6 +170,7 @@ func (s *Service) ProcessDocument(ctx context.Context, userID uuid.UUID, imgData
|
||||
Quantity: decimal.NewFromFloat(rawItem.Amount),
|
||||
Price: decimal.NewFromFloat(rawItem.Price),
|
||||
Sum: decimal.NewFromFloat(rawItem.Sum),
|
||||
Order: i + 1,
|
||||
}
|
||||
|
||||
match, _ := s.ocrRepo.FindMatch(serverID, rawItem.RawName)
|
||||
|
||||
Reference in New Issue
Block a user