Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Fatal error: Uncaught Error: Undefined class constant 'CACHE_TAG' in
- C:xampphtdocstest-localappcodeTestingSimpleNewsModelNews.php:9
- Stack trace: #0 C:xampphtdocstest-localvendormagentoframeworkAppCacheTagStrategyIdentifier.php(25):TestingSimpleNewModeNews->getIdentities()
- #1 C:xampphtdocstest-localvendormagentoframeworkAppCacheTagResolver.php(43): MagentoFrameworkAppCacheTagStrategyIdentifier->getTags(Object(TestingSimpleNewsModelNews))
- #2 C:xampphtdocstest-localvendormagentomodule-page-cacheObserverFlushCacheByTags.php(64): MagentoFrameworkAppCacheTagResolver->getTags(Object(TestingSimpleNewsModelNews))
- #3 C:xampphtdocstest-localvendormagentoframeworkEventInvokerInvokerDefault.php(72): MagentoPageCacheObserverFlushCacheByTags->execute(Object(MagentoFrameworkEventObserver))
- #4 C:xampphtdocstest-localvendormagentoframeworkEventInvokerInvokerDefault.php(60): MagentoFrameworkEventInvokerInvokerDefault->_callObserverMethod(Object(Magento in C:xampphtdocstest-localappcodeTestingSimpleNewsModelNews.php on line 9
- <?php
- namespace TestingSimpleNewsModel;
- class News extends MagentoFrameworkModelAbstractModel implements MagentoFrameworkDataObjectIdentityInterface
- {
- public function getIdentities()
- {
- return [self::CACHE_TAG . '_' . $this->getId()];
- }
- public function getDefaultValues()
- {
- $values = [];
- return $values;
- }
- /**
- * Define resource model
- */
- protected function _construct()
- {
- $this->_init('TestingSimpleNewsModelResourceNews');
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement