Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save onmotion/40be2ea1bb754df0cb15b397bd270de7 to your computer and use it in GitHub Desktop.
Save onmotion/40be2ea1bb754df0cb15b397bd270de7 to your computer and use it in GitHub Desktop.
<?php
$dataProvider = new ActiveDataProvider([
'query' => $query->select('client.*')->joinWith(['r_cli_tt.tt'])->addSelect('SUM(r_cli_tt_potential_sellers_cnt) as potentialsSum')->groupBy(['client_id']),
]);
и соответственно добавить potentialsSum в модель
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment