Christophe Simonis
505e308cd6
[MERGE] forward port of branch 7.0 up to e12cece
2015-07-14 15:00:33 +02:00
Denis Ledoux
89e1aae508
[FIX] base_action_rule: using relativedelta instead of timedelta
...
For the simple reason that `months` isn't an accepted argument
of `timedelta`
2015-07-10 17:18:37 +02:00
Christophe Simonis
e20dcda50d
[MERGE] forward port of branch 7.0 up to 99c87b6
2015-05-21 16:33:45 +02:00
Olivier Dony
53980b7c52
[FIX] account, mail, etc.: uniformize evaluated expressions
...
opw-626694
2015-05-21 16:07:21 +02:00
Denis Ledoux
8c4a7cb371
[MERGE] forward port of branch 7.0 up to 5035c76
2014-11-04 12:19:58 +01:00
Sandy Carter
1661cf53e9
[FIX] base_action_rule: Make sure model exists before trying to wrap hooks
...
In certain cases, before running an update unregistered models will try to
register hooks. Trying to wrap create and write on these will cause
AttributeError on model_obj which would be None
Signed-off-by: Sandy Carter <sandy.carter@savoirfairelinux.com>
2014-10-30 10:02:04 +01:00
Stéphane Wirtel
1ff7ed2758
[IMP] Optimize the schedulers of the calendar, fetchmail and base_action_rules modules
...
Disable the the crons when they'd have nothing to do, re-enable them when a
task is (probably) introduced
2014-09-02 18:32:27 +02:00
Christophe Simonis
bdc4dd4a65
[MERGE] forward port of branch 7.0 up to 95cff0b
2014-06-27 16:00:28 +02:00
Martin Trigaux
60ec300493
[FIX] base_action_rule: more flexible wrapper signature
...
Some objects (e.g. account.move.line) have a different signature than the classical 'cr, uid, ids, vals, context=None' and may add extra arguments.
This fix allows to create rules on these objects and still pass the valid arguments.
(opw 609204)
2014-06-25 14:42:55 +02:00
Olivier Dony
9f0ecb3572
[MERGE] Forward-port of 7.0 bugfixes up to 4d3a5df
2014-06-12 13:49:32 +02:00
Olivier Dony
5ccfeaaeda
[FIX] base_action_rule: automatic commit during background processing of rules
...
This will make sure already processed rules are persisted
in case a timeout occurs while processing the next ones,
ensuring that *some* progress can be made in most cases.
2014-06-11 18:42:18 +02:00
Olivier Dony
cf0be50f04
[FIX] base_action_rule: prevent recursive rule trigger also when processing time-based rules
...
A safety guard already in place prevents the recursive
trigger of rules while another rule is being executed,
as a simple measure to prevent endless loops.
This guard was missing when processing time-based rules.
2014-06-11 18:42:18 +02:00
Olivier Dony
d4356263f2
[FIX] base_action_rule: do not repeatedly trigger already-executed rules based on time condition
...
A programming error introduced at rco@openerp.com-20121220142445-emzzvhlw400q37c9
fails to properly check when a rule has already been executed in the past.
Time-based rules should only be executed if the trigger date is in the past and:
- either they never executed before
- or the last execution date is older than the trigger date
2014-06-11 18:42:18 +02:00
Olivier Dony
ff8b843b18
[FIX] base_action_rule: do not force registry reload when writing on a rule unless really needed
...
Executing a rule always updates the `last_run` value, which would
always force a useless registry reload to occur. Only signal the
change if the rule applies to a model that was not previoulsy
monitored for base action rules.
2014-06-11 18:42:18 +02:00
Olivier Dony
bbd813e76e
[MERGE] Forward-port of latest saas-2 (incl. 7.0) bugfixes, up to rev. 9127 odo@openerp.com-20140212122042-3m2tysmr31mtecnc
...
bzr revid: odo@openerp.com-20140212175141-i9yz8zlseglrk8sb
2014-02-12 18:51:41 +01:00
Denis Ledoux
65257c48b5
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 9835 revid:launchpad_translations_on_behalf_of_openerp-20140213064742-xiotlx8wzfhexnhc
...
bzr revid: dle@openerp.com-20140210160759-oybxhdwgv2q4ma5a
bzr revid: odo@openerp.com-20140212122042-3m2tysmr31mtecnc
bzr revid: dle@openerp.com-20140212143044-0c94q4evxl4ltwr0
bzr revid: dle@openerp.com-20140213115951-h7c2o65lgg26aosv
2014-02-13 12:59:51 +01:00
Olivier Dony
5d4f139df2
[FIX] base_action_rule: attempt to reuse creator language when evaluating action filters
...
Some filters needs to be evaluated with the same
language as their author, e.g. when searching on
translatable field values. When a time-based
action is processed by the scheduled task,
we should thus attempt to reuse the same
language as the author of the corresponding
filter.
bzr revid: odo@openerp.com-20140212113924-77sh4oj6dl2qwqka
2014-02-12 12:39:24 +01:00
Thibault Delavallée
f92f824b30
[MERGE] Sync with trunk
...
bzr revid: tde@openerp.com-20140110124928-jz1ie9qyh6n99fi7
2014-01-10 13:49:28 +01:00
Olivier Dony
89a6771f6a
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 9698, revision-id: odo@openerp.com-20131216142049-xh9gxy5cir3p2i09
...
bzr revid: dle@openerp.com-20131216111534-0w0jdod25ff3iapc
bzr revid: odo@openerp.com-20131216142246-unt6qqb23uq53we1
2013-12-16 15:22:46 +01:00
Olivier Dony
d08821442e
[FIX] base_action_rule: upon update/create of an automated action in multiprocess mode, force registry reload
...
Short of signaling the other workers, the (new) automated
rule may be randomly ignored, depending on which worker
handles the request (until the workers all reload
their registries).
bzr revid: odo@openerp.com-20131216142049-xh9gxy5cir3p2i09
2013-12-16 15:20:49 +01:00
Thibault Delavallée
03d7a17880
[MERGE] Sync with trunk
...
bzr revid: tde@openerp.com-20131210093307-gxn4g59xba3l82zx
2013-12-10 10:33:07 +01:00
Thibault Delavallée
023777a86f
[IMP] base_action_rule: added 'on_create_or_write' kind that is triggered
...
on both creation or update. This kind is added especially for migrations
to help migrating old actions not necessarily tailored for 'on_create'
or 'on_write' kind that are new in saas-2.
bzr revid: tde@openerp.com-20131016091305-k9w3tuayl1kag8oc
2013-10-16 11:13:05 +02:00
Thibault Delavallée
6e1cb5226b
[IMP] hr_contract: added override of base_action_rule (+ dependency) to add the possibility to use a user-related working scheduling.
...
bzr revid: tde@openerp.com-20130902134200-xvy5hb7lqv2wv0um
2013-09-02 15:42:00 +02:00
Thibault Delavallée
4923499534
[IMP] base_action_rule: when using a timed condition on days, allow to use a working calendar to compute days.
...
bzr revid: tde@openerp.com-20130821105127-182i9f7mzkoo4cf0
2013-08-21 12:51:27 +02:00
Martin Trigaux
ccb38117ee
[MERGE] Forward porting of saas-1 until rev 8739
...
bzr revid: mat@openerp.com-20130605090453-e4mg37kms5j1r18n
2013-06-05 11:04:53 +02:00
Vo Minh Thu
3f8551e68c
[MERGE] merged trunk.
...
bzr revid: vmt@openerp.com-20130604131428-nh9ikodh8lit5p7b
2013-06-04 15:14:28 +02:00
Olivier Dony
0f983a0146
[MERGE] Forward-port of latest 7.0 bugfixes, up to rev. 9183
...
rev-id launchpad_translations_on_behalf_of_openerp-20130531070107-7d2k818beg8965ll
bzr revid: odo@openerp.com-20130603121852-jdl6vlo9dmjk0rlc
2013-06-03 14:18:52 +02:00
Martin Trigaux
ab85cf0e86
[IMP] base_action_rule: add help message on trigger date field
...
bzr revid: mat@openerp.com-20130529104202-ofyadlqo6ax10axe
2013-05-29 12:42:02 +02:00
Raphael Collet
96ad608854
[IMP] general: use registry[X] instead registry.get(X) when X is dynamic
...
bzr revid: rco@openerp.com-20130329143720-80pkd4csemlk1aqz
2013-03-29 15:37:20 +01:00
Raphael Collet
2a0245b20c
[IMP] base_action_rule: use better value names for new selection field
...
bzr revid: rco@openerp.com-20130304094951-7452svzw0cgzu6jp
2013-03-04 10:49:51 +01:00
Raphael Collet
f1f15f52b3
[FIX] base_action_rule: undefined variable (due to code move)
...
bzr revid: rco@openerp.com-20130301131929-3q4egd9jpasss88w
2013-03-01 14:19:29 +01:00
Raphael Collet
3bad12f1cf
[IMP] base_action_rule: adapt views to new field
...
bzr revid: rco@openerp.com-20130301112705-hqn8wqz1l20ix2tu
2013-03-01 12:27:05 +01:00
Raphael Collet
9c21a6902a
[IMP] base_action_rule: update records before executing server actions
...
bzr revid: rco@openerp.com-20130301110301-xu4iaxi7hysmclm4
2013-03-01 12:03:01 +01:00
Raphael Collet
50a893a66e
[IMP] base_action_rule: add selection field on action rules to indicate when to execute them
...
bzr revid: rco@openerp.com-20130301103649-up2b2yrye2y80e1t
2013-03-01 11:36:49 +01:00
Quentin (OpenERP)
3be6693f3e
[MERGE] base_action_rule: adding onchange on model_id in order to get the related field updated. Fix issue 586436. Merge of jco branch with small refactoring and context added
...
bzr revid: qdp-launchpad@openerp.com-20130225174112-aoe9ts8linp5fx1l
2013-02-25 18:41:12 +01:00
Josse Colpaert
62404c7a72
[FIX] When you change the model, it will change the related domain for the filters
...
bzr revid: jco@openerp.com-20130221100208-1w6ypan5f3mrv0bm
2013-02-21 11:02:08 +01:00
Raphael Collet
1671b9e03a
[IMP] base_action_rule: form view improvement
...
bzr revid: rco@openerp.com-20121221144934-erkp8md6kq14070a
2012-12-21 15:49:34 +01:00
Raphael Collet
6502ec2af8
[IMP] base_action_rule: typo
...
bzr revid: rco@openerp.com-20121221142333-ml6saych44rl99ok
2012-12-21 15:23:33 +01:00
Raphael Collet
0cd5dc1195
[IMP] base_action_rule: put the 'loop avoidance' code together
...
bzr revid: rco@openerp.com-20121221142220-c5wjr9m4suq3jfdm
2012-12-21 15:22:20 +01:00
Raphael Collet
375a5820ae
[MERGE] lp:~c2c/openobject-addons/trunk-trg_dates-base_action-rule-20120510
...
replace the field 'trg_date_type' by a many2one field to ir.model.fields
bzr revid: rco@openerp.com-20121221113957-gd1c80h4vszg1h4g
2012-12-21 12:39:57 +01:00
Raphael Collet
a7ef28fd94
[IMP] base_action_rule: make code more robust
...
bzr revid: rco@openerp.com-20121221105436-3t553dlzdvjb5hfe
2012-12-21 11:54:36 +01:00
Raphael Collet
d17d474fc7
[IMP] base_action_rule: remove unused import
...
bzr revid: rco@openerp.com-20121221103812-u6ejn5rifw2ctjsx
2012-12-21 11:38:12 +01:00
Raphael Collet
306267ef55
[IMP] base_action_rule: improve field labels
...
bzr revid: rco@openerp.com-20121221103233-lllh3c5f1azuffc7
2012-12-21 11:32:33 +01:00
Raphael Collet
fed5651f1c
[IMP] base_action_rule: small code improvement
...
bzr revid: rco@openerp.com-20121221103003-tl689nm2ser3u001
2012-12-21 11:30:03 +01:00
Raphael Collet
ee5121a590
[IMP] base_action_rule: remove deprecated field act_state from base.action.rule
...
bzr revid: rco@openerp.com-20121221102753-qejsv25g952gz8nx
2012-12-21 11:27:53 +01:00
Raphael Collet
b2864c4feb
[FIX] crm: adapt overridden method of base_action_rule
...
bzr revid: rco@openerp.com-20121220162615-zerev9bxpcqxtip1
2012-12-20 17:26:15 +01:00
Raphael Collet
5301d15429
[IMP] base_action_rule: improve code using datetimes
...
bzr revid: rco@openerp.com-20121220143914-qwxmiixc4d455u5h
2012-12-20 15:39:14 +01:00
Raphael Collet
5662720773
[IMP] base_action_rule: refactor code
...
bzr revid: rco@openerp.com-20121220142445-emzzvhlw400q37c9
2012-12-20 15:24:45 +01:00
Raphael Collet
d29a1bf9b1
[IMP] base_action_rule: change the field 'server_action_ids' into a many2many
...
bzr revid: rco@openerp.com-20121220132318-mjc46h4mnw63svok
2012-12-20 14:23:18 +01:00
Raphael Collet
0228273ffb
[FIX] base_action_rule: fix in wrapper method
...
bzr revid: rco@openerp.com-20121219150723-n25qqmczh3oau1cn
2012-12-19 16:07:23 +01:00