# |
Mar 9th 2018, 13:40 |
braguzz |
so I caould bake without prefixes and evrything worked |
# |
Mar 9th 2018, 13:40 |
braguzz |
in 2.x prefix was handle directli in DB configuration |
# |
Mar 9th 2018, 13:40 |
jkpatel291289 |
@dereuromark i have set virtualfield as display field and i am fetshin display field from model.. $displayField = $this->{$this->name}->getDisplayField(); $term = $this->request->getQuery('term'); $results = $this->{$this->name}->find('all', [ 'conditions' => [ $displayField.' LIKE' => $term . '%'], 'limit' => 10, 'fields'=>['id', $displayField ] ]); |
# |
Mar 9th 2018, 13:34 |
dereuromark |
what do you mean? bake also dosnt do prefixes yet afaik |
# |
Mar 9th 2018, 13:33 |
braguzz |
does it works with bake? |
# |
Mar 9th 2018, 13:33 |
dereuromark |
@braguzz: Ah, found it: https://github.com/dereuromark/cakephp-setup/blob/master/src/Shell/DbMaintenanceShell.php#L166 |
# |
Mar 9th 2018, 13:33 |
braguzz |
;) |
# |
Mar 9th 2018, 13:33 |
braguzz |
thanks |
# |
Mar 9th 2018, 13:32 |
dereuromark |
its easy :slightly_smiling_face: I even had a shell doing that for me |
# |
Mar 9th 2018, 13:32 |
dereuromark |
braguzz: unprefix em |
# |
Mar 9th 2018, 13:32 |
dereuromark |
@jkpatel291289 sure, why not. those are usually just concat(y,z) which would still always work in SQL |
# |
Mar 9th 2018, 13:29 |
braguzz |
3.x doesnt handle the prefix of tables? |
# |
Mar 9th 2018, 13:29 |
braguzz |
my whole tables are prefixed |
# |
Mar 9th 2018, 13:28 |
braguzz |
but I got an obstacle |
# |
Mar 9th 2018, 13:28 |
braguzz |
trying to see if its good to switch from 2.x to 3.x |
# |
Mar 9th 2018, 13:28 |
braguzz |
hi all |
# |
Mar 9th 2018, 13:26 |
jkpatel291289 |
can we use virtual field in where conditon? |
# |
Mar 9th 2018, 12:03 |
birdy247 |
@admad Where would cake be without me lol |
# |
Mar 9th 2018, 11:50 |
admad |
@birdy247 you are this close to getting on my "people I shouldn't help" list. :P |
# |
Mar 9th 2018, 11:04 |
exhogin |
lol |
# |
Mar 9th 2018, 11:03 |
birdy247 |
I got it working :slightly_smiling_face: |
# |
Mar 9th 2018, 11:03 |
exhogin |
@birdy247 convert to ico |
# |
Mar 9th 2018, 11:00 |
birdy247 |
but the icon is a .png not a ico file |
# |
Mar 9th 2018, 11:00 |
birdy247 |
I am trying to make a <link rel = "shortcut icon" witht eh HTML helper |
# |
Mar 9th 2018, 10:59 |
birdy247 |
Am I being thick |
# |
Mar 9th 2018, 10:21 |
neon1024 |
I’m having a read about the Command pattern, and I remember @lorenzo demonstrating it at a Cakefest workshop. Just o clarify for my brain. I could create an `AddCommand` which deals with creating new things in my application, just like a global `Controller:add()`, and I’d pass it a context of the data and where to save it , for example a TableClass name. Is this acorrect way of thinking about the pattern in a Ckaephp context. |
# |
Mar 9th 2018, 09:35 |
admad |
emi1988: are getting error for main site or sub domain? |
# |
Mar 9th 2018, 09:18 |
slackebot |
'view', $usuario->empresa->id]) : '' ?></td> <td><?= $usuario->has('perfile') ? $this->Html->link($usuario->perfile->id, ['controller' => 'Perfiles', 'action' => 'view', $usuario->perfile->id]) : '' ?></td> |
# |
Mar 9th 2018, 09:18 |
portilloster |
Morning everyone guys! Noob question of the day!: I have my table users joined to the table role and company by the role_id and company_id foreing keys on the user table. The thing is that I want to show up on user list not the role or company id but their respective names! This is the code I have on user index.ctp: <td><?= $usuario->has('empresa') ? $this->Html->link($usuario->empresa->id, ['controller' => 'Empresas', 'action' => |
# |
Mar 9th 2018, 09:08 |
neon1024 |
Morning everyone. Happy Friday |
# |
Mar 9th 2018, 09:07 |
emi1988 |
this is what i have done and i cant do otherwise |
# |
Mar 9th 2018, 09:06 |
emi1988 |
i cant create on different folder. Available folder i /public_html where i have an old installation of cake and a new folder "tutorial" with new cake installation. |
# |
Mar 9th 2018, 09:05 |
emi1988 |
i dont have access to create vhosts. I can create a subdomain. So this is so hard to do? |
# |
Mar 9th 2018, 09:02 |
dakota |
Fiddling with .htaccess has never been successful for me :slightly_smiling_face: |
# |
Mar 9th 2018, 09:02 |
dakota |
Easiest way to do that is to have them in different folders, and point the apache vhost’s document root to the correct place |
# |
Mar 9th 2018, 09:01 |
emi1988 |
Thanks |
# |
Mar 9th 2018, 09:01 |
emi1988 |
Now how hi can configure htaccess files to use main domain and subdomain separately. Now i have a 500 internal server error and i dont know what i have to do. |
# |
Mar 9th 2018, 09:00 |
emi1988 |
in this folder there is a new fresh installation of cakephp |
# |
Mar 9th 2018, 08:59 |
emi1988 |
Now i have done a sub domain : http://tutorial.mysite.com . the directory is at the same level as cakephp domain app -> /public_html/tutorial |
# |
Mar 9th 2018, 08:58 |
emi1988 |
http://www.mysite.com/ is a old cakephp installation . |
# |
Mar 9th 2018, 08:58 |
emi1988 |
i would like to use 2 cakephp installazion on web server for domain and subdomain |