Log message #4199762

# At Username Text
# Aug 23rd 2019, 14:01 ricksaccous by default it just attempts to send all emails at once i believe
# Aug 23rd 2019, 14:01 ricksaccous you'd have to set things up so the plugin handles email sending though
# Aug 23rd 2019, 14:00 ricksaccous using the plugin you can specify a rate
# Aug 23rd 2019, 14:00 ricksaccous @davorminchorov if you need something like that I'd recommend the Queue plugin
# Aug 23rd 2019, 13:59 davorminchorov Is there a rate limit configuration for emails in CakePHP?
# Aug 23rd 2019, 13:54 dereuromark I would also think that the route itself is enough in that case
# Aug 23rd 2019, 13:52 neon1024 Only advantage I can see is that the controller method tells me which methods it likes right in the code
# Aug 23rd 2019, 13:51 neon1024 i don’t have fallback routes in this prefix, so I’m guessing checking in the controller is redundant as the route just won’t match right?
# Aug 23rd 2019, 13:51 neon1024 Feels like I’m doing the same thing from different ends
# Aug 23rd 2019, 13:50 neon1024 If I specify an http method in my route as `->setMethods(['get'])` for example, do I need to check `$this->getRequest->allowMethod('get')` in my controller?
# Aug 23rd 2019, 13:34 admad shell classes are deprecated, replaced by command classes. It is planned to make commands lib standalone but markstory hasnt got around to it
# Aug 23rd 2019, 13:32 val @admad Hi, would it be possible to have a standalone 3.x shell classes library like standalone ORM https://github.com/cakephp/orm?
# Aug 23rd 2019, 12:49 admad if you absolutely want to support both uuid and int then make 2 fk fields and configure which field to use in association
# Aug 23rd 2019, 12:48 slackebot2 'length' => 64, ```
# Aug 23rd 2019, 12:48 slackebot2 ->addColumn('parent_asset_id', 'integer', [ 'null' => true, 'default' => null, ]) - ->addColumn('foreign_key', 'string', [ - 'null' => true, 'default' => null, 'length' => 36, + ->addColumn('foreign_key', 'integer', [ + 'null' => true, 'default' => null, ]) ->addColumn('model', 'string', [ 'null' => true, 'default' => null,
# Aug 23rd 2019, 12:48 rchavik solved: ``` diff --git a/FileManager/config/Migrations/20131130074112_AssetsInitialMigration.php b/FileManager/config/Migrations/20131130074112_AssetsInitialMigration.php index 2be8a93f..b1a24282 100644 --- a/FileManager/config/Migrations/20131130074112_AssetsInitialMigration.php +++ b/FileManager/config/Migrations/20131130074112_AssetsInitialMigration.php @@ -64,8 +64,8 @@ class AssetsInitialMigration extends AbstractMigration {
# Aug 23rd 2019, 12:47 admad hehe, it happens, something we get too focused trying to solve things one way
# Aug 23rd 2019, 12:47 rchavik :face_palm:
# Aug 23rd 2019, 12:47 rchavik it never occured to me to change the damn schema
# Aug 23rd 2019, 12:47 rchavik you know..
# Aug 23rd 2019, 12:46 admad ah, noble cause :slightly_smiling_face:
# Aug 23rd 2019, 12:45 rchavik yeah, this was trying to support integer and char(36) for uuids
# Aug 23rd 2019, 12:45 admad not sure how db db will handle if the value isn't quoted
# Aug 23rd 2019, 12:44 admad overriding field type might creating problems when saving data
# Aug 23rd 2019, 12:44 admad but best is to avoid creating unnecessary problems which you have to solve :slightly_smiling_face:
# Aug 23rd 2019, 12:43 rchavik noted, i will try to change the field
# Aug 23rd 2019, 12:43 admad you can try overriding the field type in table table schema in Table::_initalizeSchema()
# Aug 23rd 2019, 12:41 admad *same as
# Aug 23rd 2019, 12:41 admad so don't do such wacky things, fk field type should be same and primary key field type
# Aug 23rd 2019, 12:28 slackebot2 ^ ``` which I think is because postgres does not like it when trying to compare a string field Assets.foreign_key against an integer field Attachments.id
# Aug 23rd 2019, 12:28 rchavik Eg: I have Asset table, with assets.id = integer. And the relationship is: ``` class AssetsTable extends Table { $this->belongsTo('Attachments', [ 'foreignKey' => 'foreign_key', ... ``` This errored out with ```Error: [PDOException] SQLSTATE[42883]: Undefined function: 7 ERROR: operator does not exist: integer = character varying LINE 1: ...achments ON (Assets.model = $1 AND Attachments.id = (Assets.foreign_key)
# Aug 23rd 2019, 12:22 rchavik how can i cast the type of the foreignKey in an automatic join created by belongsTo() ?
# Aug 23rd 2019, 12:00 rchavik works!
# Aug 23rd 2019, 11:41 rchavik ah... trying this now https://github.com/cakephp/migrations/issues/370
# Aug 23rd 2019, 11:38 rchavik for sqlite and postgres, mysql is fine
# Aug 23rd 2019, 11:37 rchavik hi, getting "There is no active transaction" error when running seed() for this file: https://github.com/croogo/croogo/blob/4.0/Users/config/Seeds/UsersSeed.php#L25 I found https://github.com/cakephp/migrations/issues/83 but still could not work.
# Aug 23rd 2019, 10:27 alexdd55976 anyone has experience with authenticate against a Domain Controller?
# Aug 23rd 2019, 10:06 alexdd55976 ok
# Aug 23rd 2019, 10:06 conehead did not really help. actually changed the id type of 2 entities now and wrote migrations
# Aug 23rd 2019, 10:04 alexdd55976 did you try a fulltext index on foreign id then? not the solution, but maybe a way to speed it up
# Aug 23rd 2019, 10:03 alexdd55976 yeah.. i thought so... this is why is pointed it out