librelist archives

« back to archive

filter bug

filter bug

From:
fengxq
Date:
2012-07-22 @ 10:04
1.Model define

local UserGroup
UserGroup = Model:extend {
__tag = 'Bamboo.Model.UserGroup';
__name = 'UserGroup';
__desc = 'UserGroup is the basic tree like model';
__indexfd = "name";
__fields = {
['name'] = {},
['cate'] = {},--system, member or special
['stars'] = {type="number"};--1~9


2 filter:
group = UserGroup:filter({cate="member",stars=group.stars+1});

3.return
{}

4.原因:
getPartialFromRedisPipeline() 没有对number字段做转换

Re: [bamboo] filter bug

From:
Tang Daogang
Date:
2012-07-22 @ 11:23
确实是。已试着修正。请git pull试用。

On Sun, Jul 22, 2012 at 6:04 PM, fengxq <fengxq@legerobot.com> wrote:

> 1.Model define
>
> local UserGroup
> UserGroup = Model:extend {
> __tag = 'Bamboo.Model.UserGroup';
> __name = 'UserGroup';
> __desc = 'UserGroup is the basic tree like model';
> __indexfd = "name";
> __fields = {
> ['name'] = {},
> ['cate'] = {},--system, member or special
> ['stars'] = {type="number"};--1~9
>
>
> 2 filter:
> group = UserGroup:filter({cate="member",stars=group.stars+1});
>
> 3.return
> {}
>
> 4.原因:
> getPartialFromRedisPipeline() 没有对number字段做转换
>



-- 
Nothing is impossible.