瀏覽代碼

[backend] Documents : correctif indexAction (groupBy nécessaire pour une bonne pagination)

dev
Guillaume 4 年之前
父節點
當前提交
15131e7dbe
共有 3 個檔案被更改,包括 6 行新增3 行删除
  1. +2
    -1
      common/models/DeliveryNoteSearch.php
  2. +2
    -1
      common/models/InvoiceSearch.php
  3. +2
    -1
      common/models/QuotationSearch.php

+ 2
- 1
common/models/DeliveryNoteSearch.php 查看文件

@@ -64,7 +64,8 @@ class DeliveryNoteSearch extends DeliveryNote
->with($optionsSearch['with'])
->joinWith($optionsSearch['join_with'])
->where(['delivery_note.id_producer' => GlobalParam::getCurrentProducerId()])
->orderBy('delivery_note.status ASC, delivery_note.reference DESC');
->orderBy('delivery_note.status ASC, delivery_note.reference DESC')
->groupBy('delivery_note.id');

$dataProvider = new ActiveDataProvider([
'query' => $query,

+ 2
- 1
common/models/InvoiceSearch.php 查看文件

@@ -62,7 +62,8 @@ class InvoiceSearch extends Invoice
->with($optionsSearch['with'])
->joinWith($optionsSearch['join_with'])
->where(['invoice.id_producer' => GlobalParam::getCurrentProducerId()])
->orderBy('invoice.status ASC, invoice.reference DESC');
->orderBy('invoice.status ASC, invoice.reference DESC')
->groupBy('invoice.id');

$dataProvider = new ActiveDataProvider([
'query' => $query,

+ 2
- 1
common/models/QuotationSearch.php 查看文件

@@ -62,7 +62,8 @@ class QuotationSearch extends Quotation
->with($optionsSearch['with'])
->joinWith($optionsSearch['join_with'])
->where(['quotation.id_producer' => GlobalParam::getCurrentProducerId()])
->orderBy('quotation.status ASC, quotation.reference DESC');
->orderBy('quotation.status ASC, quotation.reference DESC')
->groupBy('quotation.id');

$dataProvider = new ActiveDataProvider([
'query' => $query,

Loading…
取消
儲存