2009/02/18(水)ploneへのパッチ

アクションボタンをすべてのページで表示する

アクションボタンの表示

plone/lib/python/plone/app/content/browser/foldercontents.py
201: if self.context.cb_dataValid():

201: if self.context.cb_dataValid() or 1:

importだけ表示 2009/02/27

ZipFileTransportに含まれるImportボタンです

Importボタンの表示

plone/lib/python/plone/app/content/browser/foldercontents.py
200:    if not len(self.items):
201:        if self.context.cb_dataValid():
202:            for button in button_actions:
203:                if button['id'] == 'paste':
204:                     return [self.setbuttonclass(button)]
205:        else:
206:            return []
↓
200:    if not len(self.items):
201:        if self.context.cb_dataValid():
202:            for button in button_actions:
203:                if button['id'] == 'paste' or button['id'] == 'import':
204:                    buttons.append(self.setbuttonclass(button))
205:            return buttons
206:        else:
207:            for button in button_actions:
208:                if button['id'] == 'import':
209:                    return [self.setbuttonclass(button)]
210:            return []