Merge pull request #21762 from jitendrapurohit/job-alert
[civicrm-core.git] / Civi / Api4 / EntityFinancialTrxn.php
1 <?php
2 /*
3 +--------------------------------------------------------------------+
4 | Copyright CiviCRM LLC. All rights reserved. |
5 | |
6 | This work is published under the GNU AGPLv3 license with some |
7 | permitted exceptions and without any warranty. For full license |
8 | and copyright information, see https://civicrm.org/licensing |
9 +--------------------------------------------------------------------+
10 */
11 namespace Civi\Api4;
12
13 /**
14 * EntityFinancialTrxns. Joins financial transactions to contributions
15 * and financial items.
16 *
17 * @see https://docs.civicrm.org/dev/en/latest/financial/financialentities/
18 *
19 * @searchable bridge
20 * @since 5.37
21 * @package Civi\Api4
22 */
23 class EntityFinancialTrxn extends Generic\DAOEntity {
24 use Generic\Traits\EntityBridge;
25 use Generic\Traits\ReadOnly;
26
27 /**
28 * @return array
29 */
30 public static function getInfo() {
31 $info = parent::getInfo();
32 $info['bridge'] = [
33 'entity_id' => ['to' => 'financial_trxn_id'],
34 'financial_trxn_id' => ['to' => 'entity_id'],
35 ];
36 return $info;
37 }
38
39 }