# |
Aug 27th 2019, 08:46 |
challgren |
Well its really late evening, here |
# |
Aug 27th 2019, 08:28 |
conehead |
good mornin |
# |
Aug 27th 2019, 08:27 |
challgren |
morning |
# |
Aug 27th 2019, 08:03 |
vossen.steven |
o/ |
# |
Aug 27th 2019, 07:57 |
neon1024 |
Morning all :wave: |
# |
Aug 27th 2019, 01:58 |
challgren |
https://github.com/cakephp/debug_kit/releases/tag/3.20.2 |
# |
Aug 27th 2019, 01:58 |
ricksaccous |
Awesome ;) |
# |
Aug 27th 2019, 01:57 |
challgren |
@ricksaccous DebugKit is fixed now |
# |
Aug 26th 2019, 21:57 |
slackebot2 |
ProductsTable and Product respectively, which does not seem to be the case I, for example, use Table->getAlias() and Entity->getSource() and both of these return RecommendedProducts instead of Products, meaning I get errors due to unkown table/entity. Now my question is how would I setup the relationship properly to get the results I need, or am I going about this the wrong way? An example of my use case is that I have meta_tags that have a foreign_id |
# |
Aug 26th 2019, 21:57 |
slackebot2 |
$itemTable = TableRegistry::getTableLocator()->get($this->getSource()); $metaTags = $metaTagsTable->find() ->cache(sprintf('meta_tags_%s_%s', $itemTable->getAlias(), $this->id), '_meta_tags_') ->where([ $metaTagsTable->aliasField('foreign_id') => $this->id, $metaTagsTable->aliasField('foreign_model') => $itemTable->getAlias(), ]) |
# |
Aug 26th 2019, 21:57 |
slackebot2 |
->first(); if ($metaTags !== null) { $this->_metaTags = $metaTags->value; } } return $this->_metaTags; } ``` |
# |
Aug 26th 2019, 21:57 |
slackebot2 |
+ foreign_model, which I fetch and cache in my default entity, but since my Table->getAlias() and Entity->getSource() return the wrong values I can't get the right meta tag ``` DefaultEntity /** @var string|null */ private $_metaTags; /** * @return string|null */ protected function _getMetaTags() { if ($this->_metaTags === null) { $metaTagsTable = TableRegistry::getTableLocator()->get('MetaTags'); |
# |
Aug 26th 2019, 21:57 |
vossen.steven |
Hey guys, got a question about self referencing BelongsToMany I have Products with a BelongsToMany to RecommendedProducts ``` ProductsTable $this->belongsToMany('RecommendedProducts', [ 'className' => 'Products', 'joinTable' => 'products_recommended_products', ]); ``` Now on to the problem, for me it seemed logical that both the RecommendedProductsTable and RecommendedProduct would reference |
# |
Aug 26th 2019, 18:52 |
ricksaccous |
i just threw in an issue |
# |
Aug 26th 2019, 18:52 |
ricksaccous |
nah it's a bug i believe |
# |
Aug 26th 2019, 18:38 |
lpj145 |
and install or update again... |
# |
Aug 26th 2019, 18:38 |
lpj145 |
try delet vendors folder |
# |
Aug 26th 2019, 18:35 |
ricksaccous |
has anyone else run into this yet? |
# |
Aug 26th 2019, 18:34 |
ricksaccous |
``` Undefined index: plugin [ROOT/vendor/cakephp/debug_kit/src/Panel/RoutesPanel.php, line 43] ``` |
# |
Aug 26th 2019, 18:34 |
ricksaccous |
i'm getting an error with debugkit routes |
# |
Aug 26th 2019, 18:33 |
slackebot2 |
<lpj145> |
# |
Aug 26th 2019, 18:32 |
lpj145 |
thanks bro! |
# |
Aug 26th 2019, 18:32 |
lpj145 |
is a old legacy system! |
# |
Aug 26th 2019, 18:32 |
slackebot2 |
<lpj145> |
# |
Aug 26th 2019, 18:32 |
lpj145 |
ok, i'm solved my issue! |
# |
Aug 26th 2019, 18:24 |
lpj145 |
if i put id session from root dir to subfolder cakephp application this works as expected. |
# |
Aug 26th 2019, 18:23 |
lpj145 |
someone know how solve this ? |
# |
Aug 26th 2019, 18:23 |
lpj145 |
Cakephp try submodule folder api initialize session with another id and lost session data on root dir... |
# |
Aug 26th 2019, 18:22 |
lpj145 |
is about session id... |
# |
Aug 26th 2019, 18:22 |
lpj145 |
ok, now i'm can understando what is wrong... |
# |
Aug 26th 2019, 18:05 |
lpj145 |
can understand me ? |
# |
Aug 26th 2019, 18:05 |
lpj145 |
i need to check some custom data session by other application... |
# |
Aug 26th 2019, 18:05 |
lpj145 |
because is a check of auth ? |
# |
Aug 26th 2019, 18:03 |
ricksaccous |
that way it will be available in the middleware |
# |
Aug 26th 2019, 18:03 |
ricksaccous |
@lpj145 why don't you throw any data into the request instead |
# |
Aug 26th 2019, 18:03 |
lpj145 |
someone show me how i can get this data ? |
# |
Aug 26th 2019, 18:03 |
lpj145 |
when i seach on doc, not found nothing about session_start $_SESSION var wrapper... |
# |
Aug 26th 2019, 18:03 |
lpj145 |
Hello everyone, i maked middleware, but needed to check session data... |
# |
Aug 26th 2019, 17:32 |
inoas |
urgh |
# |
Aug 26th 2019, 17:32 |
inoas |
so slack shows me as jh |
# |
Aug 26th 2019, 17:32 |
inoas |
hm |