Hello all i have a problem relating a record to auth_group records
creating in admin a new record in table menus, referencing one or more
auth_group record results in a record with None in visibleTo field.
Why ?
[image: image.png]
db.define_table("apps",
Field("title"),
Field("icon"),
is that possible?
similar to the web2py
{{=form.custom.begin}}Name:
{{=form.custom.widget.name}}{{=form.custom.submit}}{{=form.custom.end}}
form.element('input[name=name]')['_id']='myid'
form.element('input[name=name]')['_class']='myclass'
Thanks
Alex
--
Resources:
-
I had an issue with line breaks too, I remove lie breaks like this with
python 3.7
some_string = some_string.replace(“\n”, ””).replace(“\r”, ””)
XML(some_string, sanitize=True)
Cheers
Chris
El El mié, 12 de feb. de 2020 a la(s) 04:37, Clemens <
clemens.odend...@claret-clover.de> escribió:
>
correct model
db.define_table("apps",
Field("title"),
Field("icon"),
Field("bg"),
Field("url"),
format='%(title)s'
)
db.define_table('menus',
Field("visibleTo",'reference auth_group'),
Field("app",'reference apps'),
any help ?
thank you
Em qua., 12 de fev. de 2020 às 11:31, António Ramos
escreveu:
> correct model
> db.define_table("apps",
> Field("title"),
> Field("icon"),
> Field("bg"),
> Field("url"),
> format='%(title)s'
> )
> db.define_table('menus',
>
problem solved.
Forgot to add "*list:*reference auth_group"
regards
António
Em qua., 12 de fev. de 2020 às 11:31, António Ramos
escreveu:
> any help ?
> thank you
>
> Em qua., 12 de fev. de 2020 às 11:31, António Ramos
> escreveu:
>
>> correct model
>> db.define_table("apps",
>>
Hello i cant understand how to solve this issue.
I have a record with portuguese characters
"Ações de cada um" that passing it to the view results in a different
value.
How do i understand it to solve it ?
[image: image.png]
This is the result in my view
My layout has
and my view is just
Hello Ramos,
since I can't see your screenshot, I have to guess. But in German we also
our special characters and I encode these by the following procedure:
import re
> import sys
>
> def convert_special_chars(label):
> if sys.version_info[0]==2: # python 2.x
> label =
Hi Chris,
thanks a lot for your help! But the problem still exists even replacing my
str_replace routine by str.replace() as proposed by you. Yes, I had the
same problem with line breaks crashing the view. And replacing the line
breaks by fixed it. But switching form python 2.7 to 3.6 raises
Hello Chris,
thanks for your answer! But just kicking out all line breaks is a little
harsh, since in my case the description is mostly a few lines long with 2
or 3 paragraphs. And I had the problem already solved by this procedure and
the call as described in my question:
def
Hi Clemens,
Replace can handle big text it does not matter if is 1 - 1000 lines or
more, It will replace all the occurrences in the text, also is faster.
chaining "replace" is more faster than other methods.
description = his_item.description.replace("\n","").replace("\r","
I've used web2py happily until today, but seems need to switch to py4web :)
I've never looked into py4web; just saw msgs going back and forth about it.
What's the best way to start? Any tutorials? Is there a book similar to the
one on web2py? What's the home page (assuming it's separate from
On Wednesday, February 12, 2020 at 12:02:10 PM UTC-8, Vlad wrote:
>
> I've used web2py happily until today, but seems need to switch to py4web :)
>
> I've never looked into py4web; just saw msgs going back and forth about
> it.
>
> What's the best way to start? Any tutorials? Is there a book
13 matches
Mail list logo