PHP Classes

Yii2 Active Record Explicit: Provide explicit behaviors to Yii2 ActiveRecord

Recommend this page to a friend!
  Info   View files View files (34)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog (1)    
Last Updated Ratings Unique User Downloads Download Rankings
2023-06-14 (8 months ago) RSS 2.0 feedNot yet rated by the usersTotal: 19 All time: 11,161 This week: 117Up
Version License PHP version Categories
yii2-active-record-e 1.0MIT/X Consortium ...5PHP 5, Databases, Libraries, Data types, D...
Description 

Author

The package can provide explicit behaviors to Yii2 ActiveRecord.

It provides class extensions to the Yii2 framework ActiveRecord base classes to provide new behaviors using additional behavior implementation classes.

Currently, it implements behavior classes to:

- Make certain model attributes read-only so they cannot be changed

- Make an attribute be handled like a timestamp

- Add support for type-casting attributes

Innovation Award
PHP Programming Innovation award nominee
June 2023
Number 6
ActiveRecord is a common design pattern many software applications use to map objects containing the information of entities that the applications need to manipulate into database records.

There are ActiveRecord implementations in many programming languages that use different frameworks.

The package extends the ActiveRecord implementation of the PHP Yii2 framework to implement more explicit behaviors useful for many applications, such as specifying read-only attributes, timestamp attributes, and type casting.

Manuel Lemos
Picture of Smoren  Freelight
  Performance   Level  
Name: Smoren Freelight <contact>
Classes: 35 packages by
Country: Russian Federation Russian Federation
Age: 34
All time rank: 291979 in Russian Federation Russian Federation
Week rank: 6 Up1 in Russian Federation Russian Federation Up
Innovation award
Innovation award
Nominee: 15x

Details

yii2-active-record-explicit

Extended and more explicit behavior for ActiveRecord classes for Yii2

How to install to Yii2 project

composer require smoren/yii2-active-record-explicit

  Files folder image Files  
File Role Description
Files folder imagesrc (10 directories)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files  /  src  
File Role Description
Files folder imagebehaviors (3 files)
Files folder imagecomponents (7 files)
Files folder imageexceptions (4 files)
Files folder imageforms (2 files)
Files folder imagehelpers (1 file)
Files folder imageinterfaces (3 files)
Files folder imagemodels (4 files)
Files folder imagerepository (3 files)
Files folder imagetraits (1 file)
Files folder imagewrappers (3 files)

  Files folder image Files  /  src  /  behaviors  
File Role Description
  Plain text file AttributeTypecastBehavior.php Class Class source
  Plain text file ReadonlyBehavior.php Class Class source
  Plain text file TimestampBehavior.php Class Class source

  Files folder image Files  /  src  /  components  
File Role Description
  Plain text file ActiveDataProvider.php Class Class source
  Plain text file ActiveRecordFieldAccessor.php Class Class source
  Plain text file ActiveRecordGenerator.php Class Class source
  Plain text file ActiveRecordQueueGenerator.php Class Class source
  Plain text file NestedPDO.php Class Class source
  Plain text file NestedTransactionManager.php Class Class source
  Plain text file TransactionManager.php Class Class source

  Files folder image Files  /  src  /  exceptions  
File Role Description
  Plain text file AccessorException.php Class Class source
  Plain text file DbConnectionManagerException.php Class Class source
  Plain text file DbException.php Class Class source
  Plain text file TransactionLogicException.php Class Class source

  Files folder image Files  /  src  /  forms  
File Role Description
  Plain text file CollectionForm.php Class Class source
  Plain text file ItemForm.php Class Class source

  Files folder image Files  /  src  /  helpers  
File Role Description
  Plain text file FormValidator.php Class Class source

  Files folder image Files  /  src  /  interfaces  
File Role Description
  Plain text file DbConnectionManagerInterface.php Class Class source
  Plain text file DbRepositoryInterface.php Class Class source
  Plain text file RepositoryInterface.php Class Class source

  Files folder image Files  /  src  /  models  
File Role Description
  Plain text file ActiveQuery.php Class Class source
  Plain text file ActiveRecord.php Class Class source
  Plain text file Migration.php Class Class source
  Plain text file Model.php Class Class source

  Files folder image Files  /  src  /  repository  
File Role Description
  Plain text file DbConnectionManager.php Class Class source
  Plain text file DbRepository.php Class Class source
  Plain text file TransactionalDbRepository.php Class Class source

  Files folder image Files  /  src  /  traits  
File Role Description
  Plain text file ActiveRecordTransactionalTrait.php Class Class source

  Files folder image Files  /  src  /  wrappers  
File Role Description
  Plain text file ActiveRecordWrapper.php Class Class source
  Plain text file BaseWrapper.php Class Class source
  Plain text file WrappableInterface.php Class Class source

 Version Control Unique User Downloads Download Rankings  
 100%
Total:19
This week:0
All time:11,161
This week:117Up