Project

General

Profile

« Previous | Next » 

Revision 2e9a060e

Added by Mikaël Ates over 11 years ago

scripts: update search acts imported multiple times.

View differences:

scripts/check_double.py
28 28
                        if lockeds.count() >= 1:
29 29
                            keep = lockeds[0]
30 30
                        else:
31
                            keep = same_acts[0]
31
                            for a in same_acts:
32
                                state = a.get_state()
33
                                if state and state.state_name != 'NON_VALIDE':
34
                                    keep = a
35
                                    break
36
                            if not keep:
37
                                keep = same_acts[0]
32 38
                    same_acts.exclude(pk=keep.pk).delete()
33 39
                    i += 1
34 40
    print "Nb actes redondants traites: %d" % i

Also available in: Unified diff