Hi, all.
I want to generate a report of my job status in somedays, so I make a
QuerySet like following:
# Generate query set
jobs = Job.list(request.REQUEST)
#today_jobs = jobs.filter(started_time__gte = date.fromtimestamp
(time.time()))
7days_jobs = jobs.fi
Ahhh!!!
Thank you for you resolved my problem !!!
On Jul 3, 11:46 am, Alex Gaynor wrote:
> On Thu, Jul 2, 2009 at 10:43 PM, Xuqing Kuang wrote:
>
> > Hi, all.
>
> > I want to generate a report of my job status in somedays, so I make a
> &
First define some list contain random values such as:
>>> foo_list = (3, 4, 5, 2)
Then use QuerySet to query the list in a table, but it returns objects
will increase id value.
>>> foo = Foo.objects.filter(id__in = foo_list)
Actually result:
>>> print foo.values
[{'id': 2}, {'id': 3}, {'id': 4
Hi, all.
Are there any way could keep a attribute new set to a item in QuerySet
object ?
For example:
>>> tcs = TestCase.objects.filter(case_id__in = [1123, 1124, 1125])
>>> tcs
[, , ]
>>> tc = tcs[1]
>>> setattr(tc, 'selected_param', [])
>>> tc.selected_param
[]
>>> tcs[1].selected_param
Traceb
Good idea.
Thank you very much :-)
Xuqing
On Dec 15, 7:19 pm, Daniel Roseman wrote:
> On Dec 15, 7:02 am, Xuqing Kuang wrote:
>
>
>
> > Hi, all.
>
> > Are there any way could keep a attribute new set to a item in QuerySet
> > object ?
>
> > For exampl
Hi. all.
I got a strange problem when syncdb.
The syncdb output just like following, as you can see the
auth_group_permissions table create 2 times. It break unit testing
with './manage.py test' process.
The thing happens both mysql and sqlite3 backend.
And I check the models.py code in testre
Ok, thank you very much for your reply.
I will have a try later, and it should noticed in the doc maybe better. ;-)
—
Sent from Mailbox for iPhone
On Mon, Jun 10, 2013 at 4:40 PM, Tom Evans
wrote:
> On Sun, Jun 9, 2013 at 5:07 AM, XQ Kuang wrote:
>> Hi.
>>
>> The form of my app posted the ex
7 matches
Mail list logo