Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
module-eav
Model
Entity
Increment
AbstractIncrement.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Eav\Model\Entity\Increment
;
7
18
abstract
class
AbstractIncrement
extends
\Magento\Framework\DataObject
implements
19
\Magento\Eav\Model\Entity\Increment\IncrementInterface
20
{
26
public
function
getPadLength
()
27
{
28
$padLength = $this->
getData
(
'pad_length'
);
29
if
(empty($padLength)) {
30
$padLength = 8;
31
}
32
return
$padLength;
33
}
34
40
public
function
getPadChar
()
41
{
42
$padChar = $this->
getData
(
'pad_char'
);
43
if
(empty($padChar)) {
44
$padChar =
'0'
;
45
}
46
return
$padChar;
47
}
48
55
public
function
format
(
$id
)
56
{
57
$result
= $this->getPrefix();
58
$result
.= str_pad((
string
)
$id
, $this->
getPadLength
(), $this->
getPadChar
(), STR_PAD_LEFT);
59
return
$result
;
60
}
61
69
public
function
frontendFormat
(
$id
)
70
{
71
return
$id
;
72
}
73
}
$result
$result
Definition:
product_configurable_not_available_rollback.php:26
Magento\Eav\Model\Entity\Increment\AbstractIncrement\getPadChar
getPadChar()
Definition:
AbstractIncrement.php:40
Magento\Framework\DataObject\getData
getData($key='', $index=null)
Definition:
DataObject.php:119
Magento\Eav\Model\Entity\Increment
Definition:
AbstractIncrement.php:6
$id
$id
Definition:
fieldset.phtml:14
Magento\Eav\Model\Entity\Increment\AbstractIncrement\frontendFormat
frontendFormat($id)
Definition:
AbstractIncrement.php:69
Magento\Framework\DataObject
Definition:
DataObject.php:15
Magento\Eav\Model\Entity\Increment\AbstractIncrement
Definition:
AbstractIncrement.php:18
Magento\Eav\Model\Entity\Increment\AbstractIncrement\format
format($id)
Definition:
AbstractIncrement.php:55
Magento\Eav\Model\Entity\Increment\AbstractIncrement\getPadLength
getPadLength()
Definition:
AbstractIncrement.php:26