liar with
edit_inline code has some suggestions, please chime in :)
//Dmitri
On Nov 25, 2007 7:04 PM, William Waites <[EMAIL PROTECTED]> wrote:
>
> On Fri, Nov 23, 2007 at 02:05:28PM -0800, Dmitri Fedortchenko wrote:
> >
> > I found this ticket:
> > http://code.django
I found this ticket:
http://code.djangoproject.com/ticket/2445
It's not seen much activity for a while, but in september jkocherhans
posted some news which I found interesting. So since I needed this
functionality, I wrote a patch for it.
The patch is still shaky on edit_inline objects, but it w
Expression for some strange hacks, then they may have some
issues.
//D
On Nov 18, 4:41 pm, Dmitri Fedortchenko <[EMAIL PROTECTED]> wrote:
> I found something.
>
> FilterExpression seems to be a bad boy.
>
> Check out these two pieces of code (in the __init__
lace('\"','"') to the "constant" in the first piece of code
will solve this little problem and it seems only fair that you should
be able to escape doublequotes (since it's clearly possible in filter
arguments)...
Should I start a new ticket for this or ba
w it's time for bed.
//D
On Nov 18, 4:09 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Sat, 2007-11-17 at 17:47 -0800, Dmitri Fedortchenko wrote:
> > Once again I return with my whacky ideas.
>
> > I want to apply filters to my translations in the templates.
/Dmitri
On Nov 18, 4:08 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Sat, 2007-11-17 at 18:27 -0800, Dmitri Fedortchenko wrote:
> > The django.template.TokenParser has a little problem.
>
> > I am not sure if this is a problem actually, but it is inconsistent
> >
The django.template.TokenParser has a little problem.
I am not sure if this is a problem actually, but it is inconsistent
when parsing filters that follow constant strings or variables.
Meaning that:
{% tag thevar|filter sometag %} will produce:
self.value() = "thevar|filter"
self.tag() = "somet
Once again I return with my whacky ideas.
I want to apply filters to my translations in the templates. So.
I have created a patch which allows use of the following syntax:
{% trans "username"|capfirst|slice:"2:" noop %}
{% trans somevar|slice:"2:" %}
The filters are applied on the resu
007-11-07 at 13:01 +, Dmitri Fedortchenko wrote:
> > I am trying to figure out the state of the translation tags in the
> > django template system.
> >
> > My ticket has been rejected, but I am not satisfied with the RTFM
> > answer given there, based on the claim
I am trying to figure out the state of the translation tags in the
django template system.
My ticket has been rejected, but I am not satisfied with the RTFM
answer given there, based on the claim that python-stuff should not
work in the template system.
So why then do the i18n docs state that {%
>
> On 11/7/07, Dmitri Fedortchenko <[EMAIL PROTECTED]> wrote:
> >
> > The Admin class should be able to define post_ and pre_save hooks that
> are
> > called before or after all Manipulation of the model is done (there are
> > post_save hooks for th
after all Manipulation of the model is done (there are
post_save hooks for the save method, but they are still called before the
Manipulator is done working with the model)
On 11/7/07, Collin Grady <[EMAIL PROTECTED]> wrote:
>
>
> Dmitri Fedortchenko said the following:
> > W
re is that your site is edited by a staff, or a client, or
maybe just you and you don't want to have to deal with creating backend
interfaces just to manage content.]
The message seems clear to me. ;)
//D
On 11/7/07, Collin Grady <[EMAIL PROTECTED]> wrote:
>
>
> Dmitri F
That is what I thought as well, however I checked, and the
_add_items() method is only called once with the correct objects
(meaning the existing keywords and the keywords that I added).
Are you telling me that the admin actually has it's own method for
setting the relationships that is outside t
tails this very problem:
http://www.progprog.com/articles/2007/03/03/django-when-save-is-not-safe
It seems that no simple solution exists yet...
//D
On Nov 7, 2:25 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Wed, 2007-11-07 at 00:50 +, Dmitri Fedortchenko wrote:
> >
admin list_display. So whenever a list is
displayed this method is called and thus the body of the article is
scanned for keywords to be added. Not the most optimal solution, but
the only one I could think of.
Still, the most logical course is to override the save method.
//D
On Nov 7, 1:50 am, D
itial post.
So repeating this should not be a problem...
I'll try to delve deeper into the transaction side of things, but any
insight you can give me would be appreciated.
//Dmitri
On Nov 7, 2:25 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Wed, 2007-11-07 at 00:50 +,
Example code:
def save(self):
regex = re.compile("\{\{([^\}]{2,60})\}\}")
words = regex.findall(self.body)
self.body = regex.sub("\\1",self.body)
super(Chapter,self).save()
for word in words:
if len(word.strip()) > 0:
Sounds good.
I'll try to clean up the patch as much as possible when I get some time too.
Right now it's a little rough around the edges.
//D
On 11/1/07, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote:
>
>
> On Wed, 2007-10-31 at 19:17 +0100, Dmitri Fedortchenko wro
I opened a ticket, looking forward to your input and ideas.
http://code.djangoproject.com/ticket/5849
On 10/31/07, Dmitri Fedortchenko <[EMAIL PROTECTED]> wrote:
>
> Now that I re-read your definition, there is one difference between your
> suggestion and my patch.
> My patch j
Tredinnick <[EMAIL PROTECTED]> wrote:
>
>
> On Sun, 2007-10-28 at 21:46 +, Dmitri Fedortchenko wrote:
> > That's a great idea! I'll see if I can squeeze out a patch for this,
> > since I feel that I want to be able to indent blocktrans without
> > having the
<[EMAIL PROTECTED]> wrote:
>
>
> On Sun, 2007-10-28 at 21:46 +, Dmitri Fedortchenko wrote:
> > That's a great idea! I'll see if I can squeeze out a patch for this,
> > since I feel that I want to be able to indent blocktrans without
> > having the extr
d we strip the subsequent lines based on the indentation of the
second line, or assume that the user wants to keep the text as is?
:)
Please advise.
On Oct 27, 12:41 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Fri, 2007-10-26 at 15:04 +, Dmitri Fedortchenko wrote:
>
I've started using blocktrans in my templates and noticed that when
using make_messages it includes all the tabs and linebreaks around the
text that is surrounded by blocktrans tags.
For example:
{% blocktrans %}
Translate this string
{% plural %}
24 matches
Mail list logo