Modified the item's delete feature at index page

Codereview: http://codereview.appspot.com/4837074/

Issue: how to display the response messages, as of now i am receiving the messages from backend but not displaying it. So if a item couldnt be deleted then what message it should show, "Operation not permitted" ?

reply can you do this by showing an icon, e.g. the red X we have on moin-1.9 for editor conflict.

And suppose i sent 10 items for deletion, out of them 4 got deleted and 6 didn't, so how will i show this through js, (currently i am showing it as "4 items deleted, 6 not deleted"), Or do i need to show the error message for each of them and if yes then wouldn't it occupy too much space on page.

reply those are deleted get the trash icon, those with some problems the red X

And when i try to send i18n messages via json i get this error.

File "/usr/lib/python2.7/json/encoder.py", line 178, in default

TypeError: lu'Deleted' is not JSON serializable

reply please verify that your code runs with 2.6.0

So i am not using any i18n now.

reply hmm, how exactly did you do this?

this works for us

    def meta_dict_to_text(self, meta, use_filter=True):
        """ convert meta data from a dict to a text fragment """
        meta = dict(meta)
        if use_filter:
            meta = self.meta_filter(meta)
        return json.dumps(meta, sort_keys=True, indent=2, ensure_ascii=False)

MoinMoin: AkashSinha/Gsoc2011Diary/2011-08-11 (last edited 2011-08-11 21:41:17 by ReimarBauer)