Exemplo n.º 1
0
def change_post_save(sender, instance, raw, using, **kwargs):
    if not op_template:
        logger.debug('Skipping creating ticket since op_template not set in config.')
        return
    if instance.type in chdb.REGISTER_CHANGE_TYPES:
        if not instance.external_key:
            getfunc(create_issue)(instance.id)
Exemplo n.º 2
0
def change_post_save(sender, instance, raw, using, **kwargs):
    if not op_template:
        logger.debug(
            'Skipping creating ticket since op_template not set in config.')
        return
    if instance.type in chdb.REGISTER_CHANGE_TYPES:
        if not instance.external_key:
            getfunc(create_issue)(instance.id)
Exemplo n.º 3
0
def change_post_save(sender, instance, raw, using, **kwargs):
    if not OP_TEMPLATE or not OP_START_DATE or not OP_TICKETS_ENABLE:
        logger.debug(
            'Settings not configured for OP tickets registration. Skipping.')
        return
    if ((instance.type in chdb.REGISTER_CHANGE_TYPES)
        and (instance.time.date() >= date_from_str(OP_START_DATE))
        and not instance.external_key):
            getfunc(create_issue)(instance.id)
Exemplo n.º 4
0
def register_issue_handler(sender, change_id, **kwargs):
    instance = chdb.CIChange.objects.get(id=change_id)
    if can_register_change(instance):
        getfunc(create_issue)(instance.id)
Exemplo n.º 5
0
def register_issue_handler(sender, change_id, **kwargs):
    instance = chdb.CIChange.objects.get(id=change_id)
    if can_register_change(instance):
        getfunc(create_issue)(instance.id)
Exemplo n.º 6
0
def change_post_save(sender, instance, raw, using, **kwargs):
    if instance.type in chdb.REGISTER_CHANGE_TYPES:
        if not instance.external_key:
            getfunc(create_issue)(instance.id)