# |
Apr 5th 2019, 02:39 |
liaogz82 |
is there a way to use phpspec with Cake? can't seem to find a good example |
# |
Apr 4th 2019, 20:46 |
blackjccl |
well here I set the UTF-8 `$pdf = new PdfSer ('L', PDF_UNIT, PDF_PAGE_FORMAT, TRUE, 'UTF-8', FALSE); $pdf->SetCreator (PDF_CREATOR);` |
# |
Apr 4th 2019, 20:43 |
etipaced |
My guess is there must be a way to configure tcpdf to use UTF-8, but I’ve never used that library so I can’t be sure. |
# |
Apr 4th 2019, 20:43 |
blackjccl |
This is inside my code |
# |
Apr 4th 2019, 20:41 |
blackjccl |
if in my layout I have `<? = $ this-> Html-> charset ()?>` and in app.config it is thus `'encoding' => env ('APP_ENCODING', 'UTF-8')` |
# |
Apr 4th 2019, 20:37 |
etipaced |
With `'encoding' => env('APP_ENCODING', 'UTF-8'),` in app.php? |
# |
Apr 4th 2019, 20:37 |
etipaced |
Do you have `$this->Html->charset()` in your layout file? |
# |
Apr 4th 2019, 20:35 |
blackjccl |
error message |
# |
Apr 4th 2019, 20:34 |
blackjccl |
hello community, I have a problem with the tcpdf library when generating a pdf |
# |
Apr 4th 2019, 18:43 |
ricksaccous |
i see |
# |
Apr 4th 2019, 18:43 |
this.impetus |
metaphorically, yeah, probably; having back-end creds on the CV opens doors. but actually? naw man betty crocker has my back |
# |
Apr 4th 2019, 18:39 |
ricksaccous |
are you trying to be a professional chef? |
# |
Apr 4th 2019, 18:35 |
this.impetus |
lul even in the kitchen that's untrue. but one can aspire. |
# |
Apr 4th 2019, 18:34 |
ricksaccous |
np, keep on trucking cake master |
# |
Apr 4th 2019, 18:18 |
this.impetus |
ty for your time |
# |
Apr 4th 2019, 18:18 |
this.impetus |
yeah, understandable. I *know* how to achieve this, in any case... it's jsut that with cake there's almost always a "if you'd just set it up this way...." solution that avoids my writing manual code. The trick is always being knowledgeable about Cake's magic |
# |
Apr 4th 2019, 18:17 |
ricksaccous |
lol |
# |
Apr 4th 2019, 18:17 |
ricksaccous |
but we are not about to sink time into bake templates unless i can convince a lead dev to do so |
# |
Apr 4th 2019, 18:17 |
ricksaccous |
i probably should |
# |
Apr 4th 2019, 18:16 |
ricksaccous |
yeah, it's on the template i'd think, i'm not quite sure i really don't bake a lot |
# |
Apr 4th 2019, 18:15 |
this.impetus |
really? it's a template issue? I was imagining that the request for the associated models somehow lacked an instruction about which column is meant to be retrieved for display purposes |
# |
Apr 4th 2019, 18:15 |
ricksaccous |
i need more context here i think |
# |
Apr 4th 2019, 18:15 |
ricksaccous |
that data is probably already selected though |
# |
Apr 4th 2019, 18:15 |
ricksaccous |
or you want to just select that data |
# |
Apr 4th 2019, 18:15 |
ricksaccous |
not sure if you mean you want the default baked template to display that |
# |
Apr 4th 2019, 18:14 |
ricksaccous |
i think the query select's all the fields though |
# |
Apr 4th 2019, 18:14 |
ricksaccous |
i'm not sure i haven't messed with bake templates, but you'd have to mess with bake templates |
# |
Apr 4th 2019, 18:13 |
slackebot2 |
does one arrange this, short of manually doing this in the index method of the controller? |
# |
Apr 4th 2019, 18:13 |
this.impetus |
there's something I knew how to do in cake2, years ago, but have no idea how to accomplish in cake 3. The baked index views for a model with associations doesn't always display the most useful field for said associations—often, just the ID. So for example, in an theoretical 'articles' model, the 'author_id' column is literally what's generated in the model; I'd obviously prefer it retrieved the display field for 'authors' instead. How |
# |
Apr 4th 2019, 18:11 |
this.impetus |
Can I bug you, @ricksaccous, for one last easy question? |
# |
Apr 4th 2019, 18:10 |
this.impetus |
awesome |
# |
Apr 4th 2019, 18:10 |
this.impetus |
... that... worked... |
# |
Apr 4th 2019, 18:08 |
ricksaccous |
also try a bin/cake schema_cache clear |
# |
Apr 4th 2019, 18:08 |
ricksaccous |
how does the paginator present the info? |
# |
Apr 4th 2019, 18:08 |
this.impetus |
"int" (sorry I keep hitting enter instead of quote); still, the paginator presents the info as an int—in fact it's a year, but 2,019 doesn't connote the same thing. What am I missing? |
# |
Apr 4th 2019, 18:07 |
this.impetus |
*I've changed this in the table, the Model/Table, and Fixtures. Everywhere I can find that labels this column |
# |
Apr 4th 2019, 18:06 |
this.impetus |
Maybe y'all getting tired of my nub questions, wouldn't fault you, but have another one. In the baked index view for one of my models, I'd originally misidentified a column as "int" when it ought to have been "string". I |
# |
Apr 4th 2019, 18:00 |
dereuromark |
many use cases would benefit from it. |
# |
Apr 4th 2019, 17:58 |
dereuromark |
never seen it. maybe you can port sth like https://github.com/juampi92/cursor-pagination into cake pagination as opt in Plugin-extension/replacement |
# |
Apr 4th 2019, 17:32 |
np |
@neon1024 > Did anyone ever develop a cursor paginator for Cake? We use this approach in our shells when push data into solr. |
# |
Apr 4th 2019, 17:08 |
this.impetus |
as an additional bit of info... my error is thrown at this line ```$supervisedTheses = $this->paginate($this->SupervisedTheses);```; adding ```debug($this->SupervisedTheses);``` immediately before this line just prints ```false``` |