Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
getRewriteArticleslastId example
$elementId
,
$shopId
]
=
$this
->
SeoIndex
(
)
->
getCachedTime
(
)
;
$this
->
SeoIndex
(
)
->
setCachedTime
(
$currentTime
->
format
(
'Y-m-d H:i:s'
)
,
$elementId
,
$shopId
)
;
$this
->
RewriteTable
(
)
->
baseSetup
(
)
;
$limit
= 10000;
$lastId
= null;
$lastUpdateVal
= '0000-00-00 00:00:00';
do
{
$lastUpdateVal
=
$this
->
RewriteTable
(
)
->
sCreateRewriteTableArticles
(
$lastUpdateVal
,
$limit
)
;
$lastId
=
$this
->
RewriteTable
(
)
->
getRewriteArticleslastId
(
)
;
}
while
(
$lastId
!== null
)
;
$this
->
SeoIndex
(
)
->
setCachedTime
(
$currentTime
->
format
(
'Y-m-d H:i:s'
)
,
$elementId
,
$shopId
)
;
$context
=
$this
->
get
(
ContextServiceInterface::
class
)
->
createShopContext
(
$shopId
)
;
$this
->
RewriteTable
(
)
->
sCreateRewriteTableCategories
(
)
;
$this
->
RewriteTable
(
)
->
sCreateRewriteTableCampaigns
(
)
;
$this
->
RewriteTable
(
)
->
sCreateRewriteTableContent
(
)
;
$this
->
RewriteTable
(
)
->
sCreateRewriteTableBlog
(
null, null,
$context
)
;
$this
->
RewriteTable
(
)
->
createManufacturerUrls
(
$context
)
;
$elementId
,
$shopId
]
=
$this
->seoIndex->
getCachedTime
(
)
;
$this
->seoIndex->
setCachedTime
(
$currentTime
->
format
(
'Y-m-d H:i:s'
)
,
$elementId
,
$shopId
)
;
$this
->rewriteTable->
baseSetup
(
)
;
$limit
= 10000;
$lastId
= null;
$lastUpdateVal
= '0000-00-00 00:00:00';
do
{
$lastUpdateVal
=
$this
->rewriteTable->
sCreateRewriteTableArticles
(
$lastUpdateVal
,
$limit
)
;
$lastId
=
$this
->rewriteTable->
getRewriteArticleslastId
(
)
;
}
while
(
$lastId
!== null
)
;
$this
->seoIndex->
setCachedTime
(
$currentTime
->
format
(
'Y-m-d H:i:s'
)
,
$elementId
,
$shopId
)
;
$context
=
$this
->container->
get
(
ContextServiceInterface::
class
)
->
createShopContext
(
$shopId
)
;
$this
->rewriteTable->
sCreateRewriteTableCategories
(
)
;
$this
->rewriteTable->
sCreateRewriteTableCampaigns
(
)
;
$this
->rewriteTable->
sCreateRewriteTableContent
(
)
;
$this
->rewriteTable->
sCreateRewriteTableBlog
(
null, null,
$context
)
;
$this
->rewriteTable->
createManufacturerUrls
(
$context
)
;