cpee-worklist 1.0.20 → 1.0.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/cpee-worklist.gemspec +1 -1
- data/lib/cpee-worklist/implementation.rb +25 -10
- data/lib/cpee-worklist/organisation.rng +3 -1
- data/lib/cpee-worklist/wlengine.xml +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 829230e05700e3690314636b97718b8ce3f93d75e544efc5977dc5ec6e6a71c2
|
|
4
|
+
data.tar.gz: 1ef8e72be3ed60a2cf3b7ce9f2be8a41357bdf0509219552ca5fced72f51ba87
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 6bb1e150e8174ce17592093bda91b86d531711458aee10f31fc4b9ed2c2acb49461e82547064fd44389bc4897251e227893d7eb313074cd2081046c1b3ea8e3a
|
|
7
|
+
data.tar.gz: 7a4fd5d1dfc77f786e00eee33da828ed7a827f6bd19d4bb77b77968c20f4bfacd80391f0aee98620cc2ad0cc319bfd688f05e45b0684e4ee1036f14b7ea2d5b2
|
data/cpee-worklist.gemspec
CHANGED
|
@@ -63,17 +63,32 @@ module CPEE
|
|
|
63
63
|
controller = @a[0]
|
|
64
64
|
|
|
65
65
|
activity = {}
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
66
|
+
if @h.keys.include?('CPEE_INSTANCE')
|
|
67
|
+
activity['process'] = @h.keys.include?('CPEE_ATTR_INFO') ? "#{@h['CPEE_ATTR_INFO']} (#{@h['CPEE_INSTANCE'].split('/').last})" : "DUMMY PROCESS (#{@h['CPEE_INSTANCE'].split('/').last})"
|
|
68
|
+
activity['label'] = @h.keys.include?('CPEE_INSTANCE') ? "#{@h['CPEE_LABEL']}" : 'DUMMY LABEL'
|
|
69
|
+
activity['user'] = []
|
|
70
|
+
activity['url'] = @h['CPEE_CALLBACK']
|
|
71
|
+
activity['id'] = @h['CPEE_CALLBACK_ID']
|
|
72
|
+
|
|
73
|
+
activity['cpee_activity_id'] = @h['CPEE_ACTIVITY']
|
|
74
|
+
activity['cpee_base'] = @h['CPEE_BASE']
|
|
75
|
+
activity['cpee_instance'] = @h['CPEE_INSTANCE']
|
|
76
|
+
|
|
77
|
+
activity['uuid'] = @h['CPEE_ATTR_UUID']
|
|
78
|
+
else
|
|
79
|
+
activity['process'] = @h.keys.include?('P_NAME') ? "#{@h['P_NAME']} (#{@h['P_INSTANCE']})" : "DUMMY PROCESS (#{@h['P_INSTANCE']})"
|
|
80
|
+
activity['label'] = @h.keys.include?('A_LABEL') ? "#{@h['A_LABEL']}" : 'DUMMY LABEL'
|
|
81
|
+
activity['user'] = []
|
|
82
|
+
activity['id'] = @h['A_CALLBACK']
|
|
83
|
+
activity['id'] = SecureRandom.uuid if @h['A_CALLBACK'].nil? || @h['A_CALLBACK'].strip == ''
|
|
84
|
+
activity['url'] = "https://cpee.org/callbacks/#{activity['id']}/"
|
|
71
85
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
86
|
+
activity['cpee_activity_id'] = ''
|
|
87
|
+
activity['cpee_base'] = ''
|
|
88
|
+
activity['cpee_instance'] = ''
|
|
75
89
|
|
|
76
|
-
|
|
90
|
+
activity['uuid'] = @h['P_INSTANCE'] || SecureRandom.uuid
|
|
91
|
+
end
|
|
77
92
|
|
|
78
93
|
omo = @p.shift.value
|
|
79
94
|
activity['orgmodel'] = @h[ 'CPEE_ATTR_' + omo.upcase] || omo
|
|
@@ -92,7 +107,7 @@ module CPEE
|
|
|
92
107
|
activity['deadline'] = @p.first.name == 'deadline' ? ((Time.now + ChronicDuration.parse(@p.shift.value)) rescue nil): nil
|
|
93
108
|
activity['restrictions'] = []
|
|
94
109
|
rests = JSON::parse(@p.shift.value) rescue nil
|
|
95
|
-
activity['restrictions'] += rests unless rests.nil?
|
|
110
|
+
activity['restrictions'] += rests unless rests.nil? || rests.empty?
|
|
96
111
|
if @p.first.name == 'prioritization'
|
|
97
112
|
val = @p.shift.value
|
|
98
113
|
activity['prioritization'] = (JSON::parse(val) rescue val.gsub(/[\[\]()<>"']/,'').split(/\s*[,;]\s*/))
|