# |
Jul 22nd 2021, 06:30 |
paolo.bragagni |
if the field is already empty Select2 shows the placeholder, otherwise no |
# |
Jul 22nd 2021, 06:25 |
paolo.bragagni |
in add the 'allowClear' and placeholder do the works |
# |
Jul 22nd 2021, 06:25 |
paolo.bragagni |
no way to insert empty selection using Select2 in edit |
# |
Jul 22nd 2021, 05:42 |
slackebot2 |
`'conditions' => array('artifact_id' => $arti_id)` `));` `$this->set(compact('abc'));` `return $this->redirect(['action'=>'view', $abc['id']]);` `}` But I'm unable to access the params from url. Which gives me the below error: I'm pretty sure that error is not of any data type instead it is a mistake in my function but I'm unable to find the mistake. Any idea on this ? Thanks ! |
# |
Jul 22nd 2021, 05:42 |
dpaleria |
hey everyone, I'm accessing this url `http://localhost:2354/images/get-imageid/111223` and now I'm using params to access the number `1112233` and put that as an input for a function in the controllers. This is how the controllers look like: `public function getImageid($id=null)` `{` `$params=$this->request->getParam('pass');` `$arti_id=$params[0];` `$abc = $this->Images->get($id, array(` |
# |
Jul 22nd 2021, 00:21 |
dereuromark |
best to create then a record per entry, this way the queue can run those in parallel even if that's possible/desired |
# |
Jul 22nd 2021, 00:20 |
dereuromark |
ah that was a different person |
# |
Jul 22nd 2021, 00:20 |
dereuromark |
and again, you can just run the reset functionality over your records, it will batch process them all without memory issues etc. |
# |
Jul 22nd 2021, 00:19 |
dereuromark |
the payload is too big, make sure to use only references, not whole objects here |
# |
Jul 21st 2021, 23:09 |
tyler.adam.lazenby |
@dereuromark any ideas on how to troubleshoot that? |
# |
Jul 21st 2021, 23:08 |
tyler.adam.lazenby |
2021-07-21 17:08:32 Notice: Notice (8): unserialize(): Error at offset 64025 of 65535 bytes in [C:\xampp\htdocs\ezBusinessManag er\vendor\dereuromark\cakephp-queue\src\Queue\Processor.php, line 187]\ |
# |
Jul 21st 2021, 23:08 |
tyler.adam.lazenby |
I ALMOST had it.... almost then this started to get spat out |
# |
Jul 21st 2021, 22:20 |
tyler.adam.lazenby |
maybe if I split up the jobs into groups of records |
# |
Jul 21st 2021, 22:13 |
tyler.adam.lazenby |
I am using queue by the way |
# |
Jul 21st 2021, 22:12 |
tyler.adam.lazenby |
Any suggestions how to approach the logic of imporing 5000+ histories into the database? |
# |
Jul 21st 2021, 22:06 |
tyler.adam.lazenby |
Ungh this is so much slower |
# |
Jul 21st 2021, 22:00 |
tyler.adam.lazenby |
I have it in the form of dto's, and unique composite ids |
# |
Jul 21st 2021, 22:00 |
kevin.pfeifer |
then I hope you have your loop detection pretty solid :) |
# |
Jul 21st 2021, 21:51 |
tyler.adam.lazenby |
instead of making the task go through each history (which there might be hundreds), I am going to make the system just create a new task for each history |
# |
Jul 21st 2021, 21:51 |
tyler.adam.lazenby |
hmmmmm, I have an idea |
# |
Jul 21st 2021, 21:16 |
grzes |
but i had a bug in counter cache condition and now i need to refresh all records after fixing the conditions |
# |
Jul 21st 2021, 21:02 |
kevin.pfeifer |
@grzes according to https://book.cakephp.org/4/en/orm/behaviors/counter-cache.html#basic-usage ```The counter's value will be updated each time an entity is saved or deleted. The counter will not be updated when you use updateAll() or deleteAll(), or execute SQL you have written.``` |
# |
Jul 21st 2021, 21:01 |
tyler.adam.lazenby |
I hate it when you have to build for large amounts of data! |
# |
Jul 21st 2021, 20:56 |
grzes |
how can i manually refresh counter cache? |
# |
Jul 21st 2021, 19:40 |
kevin.pfeifer |
the difference between cakephp 3 and 4 wouldn't be that much I would guess |
# |
Jul 21st 2021, 19:40 |
kevin.pfeifer |
maybe try https://github.com/mattmemmesheimer/cakephp-3-acl-example ? |
# |
Jul 21st 2021, 19:20 |
Aspirant |
Hi Everyone any great tutorial for implementation of ACL in cakphp 4.2.8 strawberry |
# |
Jul 21st 2021, 15:15 |
kevin.pfeifer |
you too :wave: |
# |
Jul 21st 2021, 15:14 |
Guest481 |
nice day/evening |
# |
Jul 21st 2021, 15:14 |
Guest481 |
have to leave |
# |
Jul 21st 2021, 15:14 |
Guest481 |
by the way |
# |
Jul 21st 2021, 15:08 |
Guest481 |
completely !! and i didn't follow the train because i moved to Azure and AWS cloud admin and without 3 years playing with theses frameworks...i'm now obsolete and back in that wolrd from scratch haha |
# |
Jul 21st 2021, 15:06 |
kevin.pfeifer |
well those modern frontend JS frameworks are a completely different topic :) |
# |
Jul 21st 2021, 15:05 |
Guest481 |
but i'm an old school jquery guy, not up to date on angular, vue etc.. |
# |
Jul 21st 2021, 15:05 |
Guest481 |
the most complicated is to create a beautiful interface |
# |
Jul 21st 2021, 15:04 |
Guest481 |
lol yes sometimes this is necessarry |
# |
Jul 21st 2021, 14:59 |
kevin.pfeifer |
I too myself just recently refactored a bunch of arrays and other primitive data from their respected classes into actual config arrays ,:) |
# |
Jul 21st 2021, 14:58 |
Guest481 |
yes for now i'll do like that and when my project will be more complete i'll tune all of that |
# |
Jul 21st 2021, 14:56 |
kevin.pfeifer |
but thats something you can pretty easiely adjust at a later time if you so desire |
# |
Jul 21st 2021, 14:55 |
kevin.pfeifer |
but as said from cnizzardini if these constants are "just" strings or integers then a config entry would be much easier to work with |
# |
Jul 21st 2021, 14:54 |
Guest481 |
many thanks for your precious advice |