Hi Massimo,

so, I'm not sure what's the most relevant, so i'm posting what seems
to be relevant (unless I missed something)

The code for the widget is straight out of slices, so even I can't
break a copy & paste (or, unlikely to ;) ) which is in the model.

def multiselect_widget(f,v):
    import uuid
    ...

the table looks like this (I borrowed from the audit trail slice you
posted):

db.define_table('p4NewUserRequest',audit,p4Request,
 
Field('depot',requires=IS_IN_DB(db,db.p4Depots.name),widget=multiselect_widget),Field('permissions','boolean',
default=False, comment="'read' is the default. check the box for
'write'"),Field('comments','text',represent=lambda t: MARKMIN(t)))

and I have these lines in the model as well:

response.files.append(URL(r=request,c='static/
multiselect',f='jquery.multiSelect.js'))
response.files.append(URL(r=request,c='static/
multiselect',f='jquery.multiSelect.css'))


I am also using the webgrid (again from slices) with this in the
default controller (although probably not relevant to the issue):

def p4_grid():
    grid=webgrid.WebGrid(crud)
    grid.crud_function='data'
    grid.datasource=db.p4NewUserRequest
    grid.pagesize=50
    grid.fields=['p4NewUserRequest.ticket',
                 'p4NewUserRequest.status',
                 'p4NewUserRequest.requested_by',
                 'p4NewUserRequest.completed_on',
                 'p4NewUserRequest.employee_Name',
                 'p4NewUserRequest.p4User',
                 'p4NewUserRequest.depot',
                 'p4NewUserRequest.permissions',
                 'p4NewUserRequest.comments']
    grid.filters=['']
    grid.filter_query=lambda f,v:f>=v
    return dict(grid=grid())

and the following bit comes from a plugin_wiki page:

 <div class="request"><br><br><h2>please use these links</
h2><p><H3>[new user request]</H3></div>
 <div class="request2 hidden">
           <fieldset>
                 <legend><h2>new user request</h2></legend>
                    {{=plugin_wiki.widget('create',
                                           table='p4NewUserRequest',
                                           message='records updated',
                                           next='/appRequest/default/
index')}} </fieldset> </div> ``:template


thanks for taking a look! :)

Mart :)

On May 9, 9:58 pm, Massimo Di Pierro <massimo.dipie...@gmail.com>
wrote:
> Please post the relevant code so we can reproduce the problem.
>
> On May 9, 5:47 pm, mart <msenecal...@gmail.com> wrote:
>
>
>
>
>
>
>
> > Hi
>
> > seems, I can not update table that has multi-select widgetas one of
> > the fields unless that is specifically updated... . I'm using the
> > audit trail code and multi-select widget, both  from web2pyslices.
>
> > Anybody know of a work around? My only idea is to have a selectable
> > "update/no_update" to toggle back and forth... but that's probably not
> > the best solution ;)
>
> > Thanks,
> > Mart :)

Reply via email to