Merge pull request #21960 from colemanw/afformBaseModule
[civicrm-core.git] / Civi / Api4 / FinancialItem.php
index 7f1c3966e93ebf6e28735ede17e55d07667f5eab..9ca7131a9239f552429cf298118a999025089a64 100644 (file)
@@ -1,5 +1,4 @@
 <?php
-
 /*
  +--------------------------------------------------------------------+
  | Copyright CiviCRM LLC. All rights reserved.                        |
@@ -9,13 +8,6 @@
  | and copyright information, see https://civicrm.org/licensing       |
  +--------------------------------------------------------------------+
  */
-
-/**
- *
- * @package CRM
- * @copyright CiviCRM LLC https://civicrm.org/licensing
- */
-
 namespace Civi\Api4;
 
 /**
@@ -26,23 +18,10 @@ namespace Civi\Api4;
  * If your interest is really in payments you should use that api.
  *
  * @see https://docs.civicrm.org/dev/en/latest/financial/financialentities/#financial-items
- *
+ * @since 5.40
  * @package Civi\Api4
  */
 class FinancialItem extends Generic\DAOEntity {
-
-  /**
-   * @see \Civi\Api4\Generic\AbstractEntity::permissions()
-   * @return array
-   */
-  public static function permissions() {
-    $permissions = \CRM_Core_Permission::getEntityActionPermissions()['financial_item'] ?? [];
-
-    // Merge permissions for this entity with the defaults
-    return array_merge($permissions, [
-      'create' => [\CRM_Core_Permission::ALWAYS_DENY_PERMISSION],
-      'update' => [\CRM_Core_Permission::ALWAYS_DENY_PERMISSION],
-    ]);
-  }
+  use Generic\Traits\ReadOnly;
 
 }