phpDocumentor

CouponRepository
in package

Table of Contents

$queryBuilder  : CI_DB_query_builder
__construct()  : mixed
getCouponByCode()  : CouponEntity
getCouponById()  : CouponEntity
storeCoupon()  : void
Stores a coupon in database.
createCouponEntityFromDatabaseRow()  : CouponEntity

Properties

Methods

__construct()

public __construct(CI_DB_query_builder $queryBuilder) : mixed
Parameters
$queryBuilder : CI_DB_query_builder
Return values
mixed

storeCoupon()

Stores a coupon in database.

public storeCoupon(CouponEntity $coupon) : void

If the CouponEntity has a non-empty CouponId, it is assumed to represent an existing record which will be updated, otherwise a new record is created and the CouponId set accordingly.

Parameters
$coupon : CouponEntity
Return values
void

createCouponEntityFromDatabaseRow()

protected createCouponEntityFromDatabaseRow(array<string|int, mixed> $couponRow) : CouponEntity
Parameters
$couponRow : array<string|int, mixed>
Tags
throws
Exception
Return values
CouponEntity

Search results