Re: django: creating tag groups

2013-01-15 Thread Sammael
вторник, 15 января 2013 г., 5:56:51 UTC+4 пользователь Amirouche написал: > Why are you creating two groups of tags ? Why not use a specific widgets > like a tree widget ? > Great idea! Think, I'll give this a try. I think that it would be useful. maybe try widgets attrs

Re: "Principle of least privilege" in accessing a DB from an app

2013-01-15 Thread Isaac Perez
Hi John, I think you are going one step further of what I intended to protect from. That makes me think about what you are saying but I think it's going to be too complicated, I'll have to see the risk of that happening. In a few words what I want to protect from is that an sql query could be pas

Re: Project Structure - Lots of scattered custom views

2013-01-15 Thread Sanjay Bhangar
On Mon, Jan 14, 2013 at 8:16 PM, chad petzoldt wrote: >> It had occurred to me that Django wasn't the right tool for this job - >> not everything is a nail :) > > > I am embedding these files within a template, so they are not direct static > serves. But the content must be inserted within the tem

Re: Anyway to use innovaeditor in admin?

2013-01-15 Thread frocco
Thanks, I ended up using ckeditor. I would have perferred using the one I just purchased. The vendor has no experience with django. Mostly .net and PHP On Monday, January 14, 2013 9:39:36 AM UTC-5, frocco wrote: > > src='scripts/innovaeditor.js'> > > Initialize the Editor below any ** you’d

Re: Model object save gives Warning: Data truncated for column

2013-01-15 Thread Bill Freeman
Does the field in question have "max_length" specified (assuming that it is a character field or a sub class)? Does introspecting the database with the database's tools indicate that the corresponding field has that size? Was the database created using Django's syncdb, or are you attempting to use

Re: django: creating tag groups

2013-01-15 Thread Amirouche Boubekki
> Why are you creating two groups of tags ? Why not use a specific widgets >> like a tree widget ? >> > > Great idea! Think, I'll give this a try. > It's not the same UX though... > > Are you sure you use the good parameter to pass the queryset to the >> underlying Field >> > > It's just an exam

cursor.execute with multiple parameters might be broken

2013-01-15 Thread Andy Woods
Hi there, I'm having trouble with cusor.execute with multiple parameters. This works fine: cursor.execute("SELECT '%s' FROM '%s'" % (column,expt_id)) However, it is not advised, according to the documentation. For one parameter, this works: cursor.execute("""SELECT %s FROM '99'""", ["test"])

youtube video embedding

2013-01-15 Thread joy
hello, my problem is bout embedding youtube's video in my application. I found some workarounds, the first, works for a normal iframe, and uses the url.py to redirect the src tag to youtube: http://sta

Insane sql logging

2013-01-15 Thread Matteo Suppo
Sometimes people ask for strange features, like "I want to log every database query except select". There will be drawbacks, of course: it will be slower, for example, but they won't care. It happened to us, and we had to ship this insanity: import logging from logging.handlers import Rotating

Re: "Principle of least privilege" in accessing a DB from an app

2013-01-15 Thread Javier Guerra Giraldez
On Tue, Jan 15, 2013 at 5:27 AM, Isaac Perez wrote: > In a few words what I want to protect from is that an sql query could be > passed in the main input text box and it could access other users passwords > or information. this simply doesn't happen with modern client libraries, as long as you do

Re: Insane sql logging

2013-01-15 Thread Addy Yeow
Why not do this at database level? e.g. using http://dev.mysql.com/doc/refman/5.1/en/query-log.html On Tue, Jan 15, 2013 at 9:35 PM, Matteo Suppo wrote: > Sometimes people ask for strange features, like "I want to log every > database query except select". > > There will be drawbacks, of course:

Re: Correct way to specifiy database-level column defaults

2013-01-15 Thread john . woltman
I have read the Django docs on adding custom SQL commands to an app's sql subfolder, so that is what I'm going to do. I'm not yet using South, but I will review it if I start. I agree item #2 seems the hardest problem. On testing, I have found that the Django test runner executes my custom SQL

Re: Model object save gives Warning: Data truncated for column

2013-01-15 Thread Chen Xu
I am using my existing mysql db. I found out that if I have an enum and try to insert a value not present in the enum this error will occur. However, my problem occurs on a TimeField. I created this field using phpMyAdmin, it is a timestamp, and default is current time. Therefore, I did the follow

CRM like / email thread functionality for Users

2013-01-15 Thread Alexander Todorov
Hi folks, I'm looking for an application/module to achieve the following functionality: 1) Be able to send email (via send_email) to a specific User of my site 2) Record what was sent and when 3) Be able to capture incoming replies and record them 4) Route the incoming reply to an admin. Ideall

Re: Model object save gives Warning: Data truncated for column

2013-01-15 Thread Bill Freeman
Not being a MySQL expert, I'll still have a guess. The TimeField just represents the time of day, with no notion of what day, see http://docs.python.org/2.7/library/datetime.html#time-objects . The term "timestamp", on the other hand, means to me a point in time in the more grand sense, such as t

Re: Insane sql logging

2013-01-15 Thread Matteo Suppo
Good question. We decided not to do it at database level because we didn't want to write every select on the file, but only the update/insert/delete. Probably it was better that way, though, and clean the file later. Matteo Suppo - Social Media Badass "C'è sempre un altro modo" "Ho l'80% di prob

Re: Model object save gives Warning: Data truncated for column

2013-01-15 Thread Chen Xu
Yes, this sound reasonable, and I verified it. You are absolutely correct. Thanks for your help Best regards On Tue, Jan 15, 2013 at 10:25 AM, Bill Freeman wrote: > Not being a MySQL expert, I'll still have a guess. The TimeField just > represents the time of day, with no notion of what day,

Re: CRM like / email thread functionality for Users

2013-01-15 Thread m1chael
I've done something similar with using Postfix and having postfix deliver to a local python script On Tue, Jan 15, 2013 at 10:11 AM, Alexander Todorov wrote: > Hi folks, > I'm looking for an application/module to achieve the following > functionality: > > 1) Be able to send email (via send_email)

Re: Anyway to use innovaeditor in admin?

2013-01-15 Thread Nikolas Stevenson-Molnar
You may be able adapt the methods used for integrating coeditor in the admin to integrate innovaeditor. The basic workflow is to query all textarea elements when the page loads and replace them with the rich text editor of your choice. You do this be adding a script to the media definitions for

How to set a specific database to use in one ModelForm in Django?

2013-01-15 Thread Fellipe Henrique
I'm realy need to set a database to model form use to validate and save all data.. how can I pass this type of parameter? like .using(dbname) in view? Without use db route, because I need all auth database and select to get in a specific database all other is set in my UserProfile database nam

Re: Any good Open Source Django-Based CRM's ?

2013-01-15 Thread scaphilo
Hi Perhaps koalixcrm is something for you, its open source and below BSD license www.koalix.org https://github.com/scaphilo/koalixcrm It offers less functionality then vTiger or SugerCRM but perhaps you want to start with something small. You can find a demo of the koalixcrm here: demo

Re: Django CRM Tool

2013-01-15 Thread scaphilo
Hi Well this thread is a bit outdated but as you have not had any answers yet. Insted of starting from scratch you could perhaps start with www.koalix.org https://github.com/scaphilo/koalixcrm Its open source and under BSD licsense. So you can use it, modify it and sell it. Am Samstag, 2. Jun

Re: Insane sql logging

2013-01-15 Thread Sam Solomon
The word "Insane" caught my eye and lo and behold it was relevant to what we've done. We actually do this for security reasons and it does help with debugging sometimes (we actually log all queries, not just INSERT/UPDATE/DELETE). We also store fk to user (with a pre_delete hook to unattach use

Intermingling applications

2013-01-15 Thread Travis J
Hi, I have an annoying problem I've inherited that I'm trying to clean up. I'm looking for advice on the best way to clean it up. We have a Django web app. It is essentially a view in a running log (call it *reader*) from a database. The db log is populated by an event queue (call it *writer

Re: CRM like / email thread functionality for Users

2013-01-15 Thread Russell Keith-Magee
On Tue, Jan 15, 2013 at 11:11 PM, Alexander Todorov wrote: > Hi folks, > I'm looking for an application/module to achieve the following > functionality: > > 1) Be able to send email (via send_email) to a specific User of my site > 2) Record what was sent and when > 3) Be able to capture incoming

Re: Insane sql logging

2013-01-15 Thread Trevor Joynson
We just parse MySQL binary logs as they only contain modification queries. You can dump the real SQL query out petty easily. I can send you the base of our dump script if you want. On Jan 15, 2013 10:26 AM, "Matteo Suppo" wrote: > Good question. We decided not to do it at database level because w

print shop framework

2013-01-15 Thread Bobby Roberts
hi all... a possible client of mine is looking for an online custom print shop like 4over4.com. Are there any open source frameworks like this out there? I'd prefer a django app but will consider other languages. -- You received this message because you are subscribed to the Google Groups "D

Re: print shop framework

2013-01-15 Thread Lachlan Musicman
It's just an online shop right? There are plenty of FLOSS frameworks and apps already written for online shops. http://www.satchmoproject.com/ or https://www.django-shop.org/ecosystem/ for instance. The hard work isn't in the construction of the site logic, it's the data entry (all the items, all

Re: print shop framework

2013-01-15 Thread SkuFlow.com
well i'm look for something like 4over4.com where you can design your own stuff to print then submit it for printing... ie a print shop, not just an ecommerce storefront. On Tue, Jan 15, 2013 at 9:48 PM, Lachlan Musicman wrote: > It's just an online shop right? > > There are plenty of FLOSS fr

Re: print shop framework

2013-01-15 Thread Lachlan Musicman
On Wed, Jan 16, 2013 at 1:51 PM, SkuFlow.com wrote: > well i'm look for something like 4over4.com where you can design your own > stuff to print then submit it for printing... ie a print shop, not just an > ecommerce storefront. > > Ok, I didn't quite pick up on that subtlety - but the concept is

Django 1.5 sendemail when doing password reset

2013-01-15 Thread Detectedstealth
Hi, For some reason when trying to use password reset I am getting the following message: SMTPDataError: (550, 'Administrative prohibition') However when I send emails from other areas in the application I don't have this issue. What can be causing this? -- Regards, Bruce -- You received th

Re: InMemoryUploadedFile no `encoding` Attribute

2013-01-15 Thread Braden Walters
Thanks to both of you. That actually makes a lot more sense now. -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/ehJ4g2H8N3wJ. To post to this group, send e

Re: Django 1.5 sendemail when doing password reset

2013-01-15 Thread Detectedstealth
Found the issue, there was no from_email but still have no idea why I got that error for there not being an email. PasswordResetForm save send_mail(subject, message, from_email, [to_email]) On Tuesday, January 15, 2013 7:28:03 PM UTC-8, Detectedstealth wrote: > > Hi, > > For some reas

Re: Django CRM Tool

2013-01-15 Thread Frankline
I've just seen the koalixcrm. Nice interface. On Wed, Jan 16, 2013 at 12:05 AM, scaphilo wrote: > Hi > Well this thread is a bit outdated but as you have not had any answers yet. > > Insted of starting from scratch you could perhaps start with > www.koalix.org > https://github.com/scaphilo/koali

Source code from book djangobook.com ?

2013-01-15 Thread Subodh Nijsure
Sorry if this is a very obvious question does any body know if source code from the online book http://www.djangobook.com/ is available some where in git repo? I have searched on github and most hits are for actual book chapters. -Subodh -- You received this message because you are subscribed to

Re: Source code from book djangobook.com ?

2013-01-15 Thread Iñigo Medina
On Tue, Jan 15, 2013 at 09:44:56PM -0800, Subodh Nijsure wrote: > Sorry if this is a very obvious question does any body know if source code > from the online book http://www.djangobook.com/ is available some where in > git repo? I have searched on github and most hits are for actual book > chapter

Re: Source code from book djangobook.com ?

2013-01-15 Thread Russell Keith-Magee
Hi, Do you mean the source code for the book (i.e., the code that is used to produce the book), or the Python/Django code that the book provides as examples? If you're looking for the former, it's linked from the djangobook.comhomepage. https://github.com/jacobian/djangobook.com If you're looki

Re: CSRFmiddlewaretoken issue ?

2013-01-15 Thread Travis J
{% csrf_token %} introduces a hidden field into your form that will be posted. Second, request.raw_post_data is going to be form-encoded, so it will look like "csrf_token=adsjadsf&body=" (generally you would only use raw_post_data for binary files and the like). To get it working quickly, use