Пример #1
0
def on_blip_submitted(event, wavelet):
    if preferences.is_preferences_wave(wavelet): return
    logging.info('%s called', event.type)
    setup_oauth(wavelet.robot, wavelet.domain)

    if wavelet.root_blip and event.blip_id == wavelet.root_blip.blip_id:
        general.wavelet_init(wavelet, event.modified_by)

    notifications.notify_submitted(wavelet, event.blip, event.modified_by)
Пример #2
0
def on_blip_submitted(event, wavelet):
    if preferences.is_preferences_wave(wavelet): return
    logging.info('%s called', event.type)
    setup_oauth(wavelet.robot, wavelet.domain)

    if wavelet.root_blip and event.blip_id == wavelet.root_blip.blip_id:
        general.wavelet_init(wavelet, event.modified_by)

    notifications.notify_submitted(wavelet, event.blip, event.modified_by)
Пример #3
0
def reply_wavelet(wave_id, wavelet_id, blip_id, participant, message):
    wavelet = fetch_wavelet(wave_id, wavelet_id, participant)
    body = '%s: %s' % (participant, message) # TODO remove when proxy_for works
    if blip_id in wavelet.blips:
        blip = wavelet.blips[blip_id]
        blip = blip.reply()
        blip.append(body)
    else:
        blip = wavelet.reply(body)

    wavelet.robot.submit(wavelet)

    from notifiy import notifications
    notifications.notify_submitted(wavelet, blip, participant, message)
Пример #4
0
def reply_wavelet(wave_id, wavelet_id, blip_id, participant, message):
    wavelet = fetch_wavelet(wave_id, wavelet_id, participant)
    body = '%s: %s' % (participant, message
                       )  # TODO remove when proxy_for works
    if blip_id in wavelet.blips:
        blip = wavelet.blips[blip_id]
        blip = blip.reply()
        blip.append(body)
    else:
        blip = wavelet.reply(body)

    wavelet.robot.submit(wavelet)

    from notifiy import notifications
    notifications.notify_submitted(wavelet, blip, participant, message)