0003-workflow-ignore-empty-items-on-workflow-import-31823.patch
tests/test_workflow_import.py | ||
---|---|---|
568 | 568 |
st1 = wf.add_status('Status1', 'st1') |
569 | 569 | |
570 | 570 |
sendsms = SendSMSWorkflowStatusItem() |
571 |
sendsms.to = ['0123456789'] |
|
571 |
sendsms.to = ['0123456789', '']
|
|
572 | 572 |
sendsms.body = 'hello' |
573 | 573 |
st1.items.append(sendsms) |
574 | 574 |
sendsms.parent = st1 |
wcs/workflows.py | ||
---|---|---|
832 | 832 |
continue |
833 | 833 |
if list(el): |
834 | 834 |
if type(getattr(self, attribute)) is list: |
835 |
v = [x.text.encode(charset) for x in el] |
|
835 |
v = [x.text.encode(charset) if x.text is not None else '' |
|
836 |
for x in el] |
|
836 | 837 |
elif type(getattr(self, attribute)) is dict: |
837 | 838 |
v = {} |
838 | 839 |
for e in el: |
839 |
- |