mes to defining and
altering tables and using web2py's authentication and authorization
features?
Kind regards,
Annet.
x27;t
documented anywhere, is it? I did indeed solve my problem.
Kind regards,
Annet.
.delete").click(function() { if
(this.checked) if(!confirm("{{=T('Sure you want to delete this
object?')}}")) this.checked=false; });
... so that the code connects to the onclick event of the submit and
not the onclick event of the checkbox?
Kind regards,
Annet.
ave a db server.
Kind regards,
Annet.
Maybe this post:
http://groups.google.com/group/web2py/browse_thread/thread/420e0001e3c8949c/32a262d1c39cdb02?lnk=gst&q=Mar+24#32a262d1c39cdb02
Annet.
execute this task.
Kind regards,
Annet.
ks.
Kind regards,
Annet.
Hi Sverre,
I am using Allan Jardine's DataTables: http://www.datatables.net/
Regards,
Annet.
and
which parts of the db.py file should the function contain?
Then, I should write an import statement in each of the applications
db.py files:
local_import('db_stuff',app='base')
My second question is: what code do these db.py files contain apart
from the import statement?
Kind regards,
Annet.
/applications
directory. You can then upload and install a packed web2py app via the
web interface.
Kind regards,
Annet.
lublocatordetails('%s')"%URL(r=request,f='details',args=[company.id]))}}
{{=company.name}}
{{pass}}
Here the link opens a details view in a new window, but that's
optional.
Regards,
Annet.
(-1)'))
This one doesn't:
form[0][-1]
[1].append(INPUT(_type='button',_value='Cancel',_onclick='javascript:closeWin()'))
Does one of you know why not?
Kind regards,
Annet.
nt on this idea.
Kind regards,
Annet.
Hi,
Thank you very much for your extensive reply, it's very helpful, at
least I now have an idea of how to approach this problem.
Kind regards,
Annet
/admin/cron/expire_sessions.py
I wonder whether this is correct and whether this a local setting or
works on the server as well.
Kind regards,
Annet.
/yourdomain.com/url/of/script' to your crontab, in order
to trigger a web request to the script.
I hope this helps you help me solve the problem,
Annet.
quest,f=next)),message=message,deletable=deletable)
form[0][-1]
[1].append(INPUT(_type="button",_value="Cancel",_onclick="javascript:history.go(-1)"))
return form
I hope you get the idea.
Kind regards,
Annet.
have some built-in
feature which makes them work similar to crontab, but it is a
completely separate system than your "real" crontab (the one you see
when you runt 'crontab -l').
By the way, the Web2py installation that I have is running behind
Apache + mod_wsgi.
Kind regards,
Annet.
return(projects=projects,form=form)
I hope this helps to point you in right direction.
Annet.
7;t this: from documents back to device and
from documents back to workorder contradict this: from device or
workorder view back to documents controller?
Kind regards,
Annet
Massimo,
Thank you very much for providing me with this code, problem solved.
Kind regards,
Annet.
but that doesn't work, why not?
Kind regards,
Annet.
uth_user.email')]),
Field('password', 'password', readable=False, label='Password',
requires=CRYPT(auth.settings.hmac_key)),
Field('registration_key', length=512, writable=False,
readable=False,default=''),
Field('reset_password_key', length=512, writable=False,
readable=False, default=''))
What is the reset_password_key for? I guess I'd better use the latter
table definition, don't I need any validators?
Kind regards,
Annet.
engoworks autocomplete every time I need an autocomplete field isn't
this simple. However, the drop box displaying the options doesn't
disappear after selecting a city name or typing the full name. Could
that be fixed, it covers some other form fields.
Kind regards,
Annet.
uest.vars.q
f = request.vars.field
t = request.vars.table
fld = db[t][f]
rows = db(fld.upper().like(q.upper()
+"%")).select(fld,distinct=True)
itms = [str(t[f]) for t in rows]
return '\n'.join(itms)
... and put this in the table definition:
db.address.city.widget=autocomplete_widget
Is that right?
Kind regards,
Annet.
tnull=True),
migrate=’tagline.table’)
Now user with user_id 1 and group_id user_1(1) should get the
permission to create, update and delete all records in the tagline
table that have company_id 443. Is that possible in web2py's, or do I
have to customize one of the auth tables to make this possible?
Kind regards,
Annet.
Hi,
> @Annet:
> Sorry, but what do you mean "emil"?
Emil works at WebFaction, where I host my application in a Shared 1
plan. Using web2py's crontab doesn't work at WebFaction, I have to use
my 'real' crontab to clean up sessions in my web2py applicati
rm=crud.update(db.tagline,record_id,next=(URL(r=request,f='index')),message='',deletable=True)
return dict(form=form)
This works, however, in my opinion, it interferes too much with
web2py's authentication and authorization workflow. Therefore, I had
hoped there would be another solution. Like linking user and company
in the permissions table, instead of the user table.
Kind regards,
Annet.
plete
plugin?
Kind regards,
Annet.
secret doors were, except me. Almost two
years ago I discovered my secret door: web2py.
So yes, +1 and thanks to all developers and the group and their
support to get me started with web2py, and make web development a joy
instead of an annoyance.
Annet.
have been searching for these kind of best practices myself, in
order to make developing and maintaining applications easier, up til
now it's been a matter of trial and error.
Kind regards,
Annet.
> Sorry, I don't understand. In get_items, request.vars.field and
> request.vars.table contain the field and table names of the requesting
> autocompleter. Is that what you mean?
Yes, thank you, now I understand.
Annet
cked. When I click
submit again the tagline is being deleted and the Insert tagline flash
displays,
3) whereas I would like a flash telling the user that the tagline has
been deleted.
How do I solve these three problems?
Kind regards,
Annet.
sh}}
{{pass}}
{{if form:}}
{{=form}}
{{pass}}
Kind regards,
Annet.
alid_login='your customized message'
Kind regards,
Annet.
regards,
Annet.
folder of the cms application.
Is there a way to upload the in the cms application into the uploads
folder of the init application. Furthermore I would like to let every
user have his own subfolder in the uploads folder, is that possible?
If so, how would I implement that?
Kind regards,
Annet.
rm)
Does the folder have to exist already or will it be made when a folder
named company_company_id doesn't exist?
> User A uploads and image into pathA. If user B wants to
> download the image posted by user A, web2py will search for it in
> pathB.
This won't be a problem, since user A cannot download user B's images
and vice versa.
Kind regards,
Annet.
ze I could also upload the images to the .../cms/uploads/
company_xxx folder and then change the downloads function in the .../
init/homepage/ controller to download the images from the cms/uploads/
company_xxx folder, is this a better way to proceed?
Kind regards,
Annet.
rgs=id))
return dict(...)
When a club has status 2 there is a redirect to a different function,
since this function's view is larger I would like to resize the
browser window. The problem is I don't know how to code this and where
the code should go, I hope one of you knows how to solve this problem.
Kind regards,
Annet.
is possible combine requirements.
If the above decorator works, would it be possible to combine a
requirement the following way:
@auth.requires(auth.user.account=='3' or auth.user.account=='2')
def update_xxx():
return(form=form)
Kind regards,
Annet.
Massimo,
> Yes but
Great, this makes it possible to code my cms more generic.
Kind regards,
Annet.
ation='%s';"%URL(r=request,f='index')))
IndexError: string index out of range
is there a way to prevent this from happening?
Kind regards,
Annet.
derby=db.city.name)
r=''
for row in rows:
r='%s%s\n'%(r,row.name)
return r
The auto complete works in empty forms, however, when I use
crud.update(db.address,...) the city field is empty, whereas the
database record contains a value for city.
I guess I have to adjust the cityAC() function, but I don't know
how...
Kind regards,
Annet.
reate_form and the update_form read the same, the cancel button
in the update_form works, the form above the table containing the
opening hours disappears and just the table is displayed.
I hope one of you knows why this happens and how I can fix this
problem.
Kind regards,
Annet.
ny_' +
str(club[0].id), args=image_1[0].image))}}
When I expose the related function the scr attribute reads like:
http:///[app]/default/download/[filename]
"""
return response.download(request,db)
Kind regards,
Annet.
After a lot of trial and error I figured out how to implement this, so
subject closed.
On May 24, 6:45 pm, annet wrote:
> I have the following layout:
>
>
>
> .header.
>
>
>
> .1.
>
>
>
> You can try replace
>
> if not response.init_flash: response.init_flash='Insert tagline'
>
> with
>
> response.init_flash='Insert tagline'
That solved the problem, thanks.
Annet.
Setting the cancel button to:
form[0][-1]
[1].append(INPUT(_type="button",_value="Cancel",_onclick='javascript:history.go(-1);'))
at least gives the user a way to cancel the function, not the way I
wanted it, but it's better than getting an error.
Annet
Yes, you're right, I hadn't thought of that. Thanks for providing me
with a better solution.
Kind regards,
Annet.
The problem is that crud.update shows a placeholder for the image
instead of a preview of the image.
Safari's inspect element shows the following src attribute:
scr="/cms/default/download/image.file.b4d69...jpg"
Why isn't the image being displayed?
Kind regards,
Annet.
System:
Mac OS X 10.5.8
Python 2.5
Web2py 1.76.5
successfully, until next time
' + auth.user.first_name + ' ' + auth.user.last_name
Kind regards,
Annet.
ogin_next and logout_url set) both the login message
and the logout message works, so who are you to tell me that it
doesn't work. As I said:
> It's probably not the most elegant of solutions, but in db.py I simply
> set:
Kind regards,
Annet.
args=id))
return dict(...)
When a club has status 2 there is a redirect to a different function,
since this function's view is larger I would like to resize the
browser window.
Would it be possible to define a second javascript function that re-
sizes the window to the desired height and width and call that
function in the redirect somehow?
Kind regards,
Annet.
Safari 4.0.5 : 115 0ut of 160
Failing on: Geolocation, Forms and User interaction.
Annet.
he correct syntax.
Kind regards,
Annet.
In your table definitions (in db.py) you could set a label on the
fields:
db.person.id.label='Person's ID'
db.person.name.label='Person's Name'
Kind regards,
Annet.
I have a form:
form=SQLFORM(db.signup_auth)
in which I don't want some of the labels to show, I tried:
db.signup_auth.akkoord_incasso.label=None
but that doesn't work, is there a way to disable labels on fields?
Kind regards,
Annet
Massimo,
Indeed it was easier to use form.element(...), thanks for providing me
with this solution.
Annet.
On Jun 7, 8:13 pm, mdipierro wrote:
> form[0] #table
> form[0][21] # 22nd row
> form[0][21][1] # second column of above row
> form[0][21][1].insert(0,H4('Text')
to the downloads folder on the users computer. Is that
possible from within web2py?
Kind regards,
Annet.
Massimo,
I used:
> {{=A('terms of service',_href=URL(r=request,c='static',f='cms/files/
> tos_fitwise.pdf',vars=dict(attachment=True)))}}
and it works, so problem solved thanks.
Annet.
Thanks for providing me with this solution, problem solved.
I have another problem with this form. In the first column some of the
field names are split up, like:
Sub-dossiernumber *
:
Is there a way to solve this?
Kind regards,
Annet.
Setting:
label {
white-space: nowrap;
}
solved the problem, thanks for providing me with this solution.
Annet.
Massimo,
At the moment this is the only static file I serve, so web2py does all
the work.
Annet.
n in
general. I built an application that, based on a company_id, exposes a
fully functional web application. If the customers domain cannot
reference this application, this idea is useless.
Is there a way to solve this problem?
Kind regards,
Annet.
n in
general. I built an application that, based on a company_id, exposes a
fully functional web application. If the customers domain cannot
reference this application, this idea is useless.
Is there a way to solve this problem?
Kind regards,
Annet.
an tell me what is being explained here.
Kind regards,
Annet.
and routes.py.
According to webfaction's support people you cannot install only one
web2py application in an account, when I install a second web2py
called secondweb2py, how do customweb2py and secondweb2py know about
each others existence?
Kind regards,
Annet.
y/gluon/sql.py", line
1694, in _create
self._db._execute(query)
File "/Library/Python/2.5/site-packages/web2py/gluon/sql.py", line
958, in
self._execute = lambda *a, **b: self._cursor.execute(*a, **b)
ProgrammingError: relation "auth_user" already exists
I thought setting fake_migrate=True would prevent me from having this
problem?
Kind regards,
Annet.
Hi Jonhy,
Thanks for your reply. I am using PostgreSQL, and the auth_ tables
contain data, so I cannot simply drop them, empty the databases folder
and redefine them. I hope there is a solution which allows me to keep
the tables in the PostgreSQL database.
Kind regards,
Annet.
refore you must call auth.define_tables() or, as far as
web2py is concerned, they do not exist. When you define them at the
web2py level, if migrate=False, web2py assumes thay also exist in the
DB, if migrate=True it does not assumes that and looks into the .table
files.""
Kind regards,
Annet.
ing overwritten.
The auth_... already exists problem also occurred when I extended my
database with a new table, to prevent this from happening I put all my
table definition in a separate db_xx.py file.
I am very much aware that these are layman solutions, and I am very
much looking forward to the day I come up with am more professional
solution.
Kind regards,
Annet.
e function:
['Contact
form',request.function=='contact_form',URL(r=request,a='utilities',c='forms',f='contact_form',args='init')]]
To keep their behaviour consistent I would like to open the menu item
in a new window also, is that possible?
Kind regards,
Annet.
ed in an internal
error.
I hope one of you could provide me with detailed instructions of how
to send an html e-mail newsletter from a Web2py application.
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post t
e: what goes here: to= [''] the mail address to
which I would like to send the mail is in nfas.adres and how does this
function end, I mean what goes at the ...
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users&qu
ess, but that's all. What happens when the send function
returns a False? Shouldn't I keep track of the Trues and Falses the
send function returns for every mail sent?
Kind regards,
Annet
--
You received this message because you are subscribed to the Google Groups
"web2py-users"
()
record_id=record[0].id
I thought that was similar to:
for nfa in nfas:
recipient=nfa.adres
I do see the difference now, thanks.
Kind regards,
Annet
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to thi
ut it doesn't. In all mail clients and web based
apps, it displays as plain text, so the html is not rendered. I have
been trying to find out why for two days now, and hope one of you can
come to my rescue.
Kind regards,
Annet.
--
You received this message because you are subscribed
ely understand the class
outlined in the wiki, and consequently unable to use it properly.
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscr
ere another
way to solve this problem?
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to
web2py+unsubscr...@go
f the unsubscribe
request.
Did one of you face a similar problem? How did you solve it?
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from t
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to
web2py+unsubscr...@googlegroups.com.
For more options, v
Yarko,
> Hope this helps a little.
Yes, actually it helped me a lot.
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from thi
Today, I upgraded my web2py installation to version 1.76.5. In this
web2py version the drop boxes display an empty key value pair first,
and then the key value pairs from the tables I based them on. What
causes this change in behaviour? How do I correct it?
Kind regards,
Annet.
--
You received
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to
web2py+unsubscr...@googlegroups.com.
For more options, visi
,
Annet
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to
web2py+unsubscr...@googlegroups.com.
For more options, visit this grou
When I use the custom install script at WebFaction to install web2py
the docs point me to the following caveat:
Web2py won't work properly if it is mounted to a sub-URL like
http://domain.com/web2py/. it must be mounted to the domain root.
What exactly does this mean?
Kind regards,
ive
However, when I click one of the archived months links I get an
invalid request error.
The link in the view reads like: March 2010
... the URL in the browser reads like:
http://127.0.0.1:8000/init/news/archive/3/maart%202010
Since the function works without args, I suppose the error has
som
However, when I click one of the archived months links I get an
invalid request error.
The link in the view reads like: March 2010
... the URL in the browser reads like:
http://127.0.0.1:8000/init/news/archive/3/March%202010
Since the function works without args, I suppose the error has
something t
quest,args=[3,'maart 2010']))}}
The space is being replaced with %20 and the function no longer works.
Hopes this helps you help me solve the problem.
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to
st,args=[3,'maart 2010']))}}
The space is being replaced with %20 and the function no longer works.
Hopes this helps you help me solve the problem.
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to
27;)}}
to have the month display like without the underscore: April 2009
instead of April_2009
Kind regards,
Annet.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubsc
r" already exists
Does this mean I cannot make changes to the db.py file in which
Authorization and Authentication are enabled? i.e. I can only save the
db.py file once.
Kind regards,
Annet.
--
To unsubscribe, reply using "remove me" as the subject.
rschreidt 128 tekens'), IS_EMAIL(), IS_NOT_EMPTY()]
db.auth_user.email.label='E-mail * '
db.auth_user.site.default=False
db.auth_user.username.requires=[IS_LENGTH(128,error_message='lengte
overschreidt 128 tekens'), IS_NOT_EMPTY(), IS_NOT_IN_DB(db,
'auth_user.username')]
db.au
em.
Kind regards,
Annet.
--
To unsubscribe, reply using "remove me" as the subject.
, and after the tables have been created set their
migrates to migrate=False. I mean to not use auth.define_tables() to
create the tables. In that case the auth_xxx tables are created once,
and longer touched when I edit the db.py file.
Kind regards,
Annet.
--
To unsubscribe, reply using "
;ll get in touch with them, and reference the links you posted. I'll
let you know when the problem is solved.
Kind regards,
Annet.
--
To unsubscribe, reply using "remove me" as the subject.
aller script to install
web2py, and emphasized that I should not start/stop web2py myself.
I'll get in touch with them, and reference our findings. I'll let you
know when the problem is solved.
Kind regards,
Annet.
--
To unsubscribe, reply using "remove me" as the subject.
ng this email? View it in your browser
Does one of you know why, and how to solve this problem?
Kind regards,
Annet.
--
Subscription settings: http://groups.google.com/group/web2py/subscribe?hl=en
persoon.contactpersoon==db.contactpersoon.id)&(db.bedrijfinschrijving.inschrijving==2)&
\
(db.contactpersoon.subscription==True))\
.select(db.bedrijf.bedrijfsnaam,db.bedrijfcontactpersoon.bedrijf,db.contactpersoon.id,db.contactpersoon.email,
\
orderby=db.bedrijfcontactpersoon.bedrijf)
return dict(item=item)
And in the view replace item with item[0]. Then, when I expose the
not_send_mail function the view is rendered correctly:
"Having trouble viewing this email?"
Kind regards,
Annet
--
Subscription settings: http://groups.google.com/group/web2py/subscribe?hl=en
1 - 100 of 1659 matches
Mail list logo