Skip to content

Instantly share code, notes, and snippets.

View wesleyvicthor's full-sized avatar

wmsan wesleyvicthor

View GitHub Profile
regex=/^([1-9][1-9] +|\([1-9][1-9]\) *)[1-9]\d{2,4}[ .-]?\d{4}$/;
strings=[
/* Só numéricos com espaços que casam */
'11 9990000',
'11 99990000',
'11 999990000',
'11 999 0000',
'11 9999 0000',
'11 99999 0000',
{% set value = data.xpath('string[2]') %}
{{ value[0] }}
{{ value.current }}
{{ value.index }}
{{ value.first }}
@wesleyvicthor
wesleyvicthor / gist:1392133
Created November 24, 2011 19:43
twig array
{% if cases_list.ProcessInstance is defined %}
{% for case in cases_list.ProcessInstance %}
{% for activity in case.activities.children() %}
<tr>
{% for variable in case.clientVariables.children() %}
{% for data in variable.xpath('string[2]') %}
<td>{{ data }}</td>
{% endfor %}
{% endfor %}
<td><a href="{{ cloud_link_address }}{{ activity.uuid.value }}" target="_blank">{{ activity.name }}</a></td>
@wesleyvicthor
wesleyvicthor / gist:1392036
Created November 24, 2011 19:14
twig array
{% %}