Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(34)  |  Call(29)  |  Derive(0)  |  Import(5)
Factory for creating i18n messages.

src/f/t/ftw.publisher.sender-2.2.0/ftw/publisher/sender/browser/configlet.py   ftw.publisher.sender(Download)
from ZODB.POSException import ConflictError
from ftw.publisher.core import states
from ftw.publisher.sender import message_factory as _
from ftw.publisher.sender.browser.interfaces import IEditRealmSchema
from ftw.publisher.sender.browser.interfaces import IRealmSchema
# lets translate the actions with i18ndude
TRANSLATED_ACTIONS = {
    'push': _(u'action_push', default=u'Push'),
    'move': _(u'action_move', default=u'Move'),
    'delete': _(u'action_delete', default=u'Delete'),
    def get_clear_confirm_message(self):
        """Translated confirm message for clearing the queue
        """
        return self.context.translate(_(
                u'confirm_clear_queue',

src/f/t/ftw.publisher.sender-2.2.0/ftw/publisher/sender/browser/blacklist.py   ftw.publisher.sender(Download)
from Products.Five import BrowserView
from Products.statusmessages.interfaces import IStatusMessage
from ftw.publisher.sender import message_factory as _
from ftw.publisher.sender.browser.interfaces import IBlacklistPathSchema
from ftw.publisher.sender.interfaces import IConfig
    fields = field.Fields(IBlacklistPathSchema)
    ignoreContext = True
    label = _(u'form_label_add_path',
              default=u'Add path')
 
                raise Exception('Path does not start with /')
            config.appendPathToBlacklist(path)
            message = _(u'info_path_added',
                        default=u'Path added')
            IStatusMessage(self.request).addStatusMessage(
    def __call__(self, *args, **kwargs):
        delete = self.request.get('delete', None)
        if delete:
            if self.config.removePathFromBlacklist(delete):
                msg = _(u'info_path_removed',

src/f/t/ftw.publisher.sender-2.2.0/ftw/publisher/sender/browser/interfaces.py   ftw.publisher.sender(Download)
from ftw.publisher.sender import message_factory as _
from ftw.publisher.sender.interfaces import IRealm
from zope import schema
from zope.interface import Interface
 
 
    password = schema.Password(
        title=_(u'label_realm_password',
                u'Password'),
        required = False)
class IBlacklistPathSchema(Interface):
 
    path = schema.TextLine(
        title = _(u'label_path',
                  default=u'Path'),

src/f/t/ftw.publisher.sender-2.2.0/ftw/publisher/sender/browser/views.py   ftw.publisher.sender(Download)
from ftw.publisher.core import states
from ftw.publisher.sender import getLogger, getErrorLogger
from ftw.publisher.sender import message_factory as _
from ftw.publisher.sender.events import AfterPushEvent, QueueExecutedEvent
from ftw.publisher.sender.events import BeforeQueueExecutionEvent
        # status message
        if msg is None:
            msg = _(u'This object has been added to the queue.')
        IStatusMessage(self.request).addStatusMessage(
            msg,
        # status message
        if msg is None:
            msg = _(u'Object move/rename action has been added to the queue.')
        IStatusMessage(self.request).addStatusMessage(
            msg,
        # status message
        if msg is None:
            msg = _(u'This object will be deleted at the remote sites.')
        add_transaction_aware_status_message(self.request, msg, type='info')
 

src/f/t/ftw.publisher.sender-2.2.0/ftw/publisher/sender/browser/publishformgen.py   ftw.publisher.sender(Download)
from Products.Five import BrowserView
from Products.statusmessages.interfaces import IStatusMessage
from ftw.publisher.sender import getLogger
from ftw.publisher.sender import message_factory as _
from ftw.publisher.sender.persistence import Queue
        # status message
        if msg is None:
            msg = _(u'This object has been added to the queue.')
        IStatusMessage(self.request).addStatusMessage(
            msg,