luisramos0
ef61310bad
Fix long lines in order_cycle_permissions and permissions
2019-07-04 17:17:58 +01:00
luisramos0
bb9c54a445
Use enterprises.id instead of :id to remove ambiguous column errors
2019-07-03 22:03:40 +01:00
luisramos0
e5f396f975
Fix Permissions.related_enterprises_granted by adding explicit reference to table
2019-07-03 20:18:01 +01:00
luisramos0
a57a93d414
Adapt permissions.rb and order_cycle_permissions to rails 4
2019-07-03 20:18:01 +01:00
luisramos0
5184fa540c
Adapt enterprise_relationship permitting and permitted_by scopes to rails 4
2019-07-03 20:18:00 +01:00
luisramos0
86b0d71c7e
Result of rubocop auto-correct and rebuilding rubocop_manual_todo
2019-05-28 12:57:29 +01:00
Pau Perez
147a74f005
Fix Rubocop violations reported by Code Climate
2018-04-16 10:27:44 +02:00
Pau Perez
33ea2c0b07
Auto correct Rubocop's Layout/FirstParameterIndentation cop
2018-04-09 18:47:18 +02:00
Rob Harrington
04e48989c9
Replace references to 'standing order' with 'subscription' (lib)
2018-02-09 14:44:13 +11:00
Rob Harrington
c18c1c67d1
Adding visibility permissions for standing orders
2018-02-09 14:43:32 +11:00
Rob Harrington
357040f67a
Enterprise User can create and update schedules via OC index
2018-02-09 14:43:28 +11:00
Rob Harrington
920f52e112
Adding schedules to Order Cycles interface
2018-02-09 14:43:28 +11:00
Pau Perez
cee24dcca7
Use indented style for multiline method calls
...
This enables the Rubocop's Style/MultilineMethodCallIndentation cop with
indentend enforced style. Which makes you split multiline method calls like:
orders = Spree::Order
.an_scope
.another_scope
.where(id: list_of_ids)
It also autofixes the current violations and updates the
rubocop_todo.yml
2017-07-12 10:40:53 +02:00
Rob Harrington
465649475d
Revoke ability to overide variants based on shared management/ownership (ie. only explicit permissions)
2016-03-02 12:10:49 +11:00
Rob Harrington
186d1c1f26
Revoking ability to create variant overrides via OC permission
2016-03-02 12:10:49 +11:00
Rob Harrington
ae7e744644
WIP: BOM Refactor, adding for_line_items action to enterprises controller
2015-11-04 15:02:29 +11:00
Rob Harrington
8132f07d88
Adding visible products method to permissions
2015-05-20 15:53:10 +10:00
Rob Harrington
01d4cf6ecf
Renaming managed_products permissions method to editable_products
2015-05-20 15:02:36 +10:00
Rob Harrington
a7019e7e78
Adding permissions method for order report enterprises
2015-05-07 12:50:56 +10:00
Rob Harrington
bd66091d75
Push logic for checking of user super admin status down into private method
2015-05-07 12:50:56 +10:00
Rob Harrington
d8f5669fbb
Renaming granted > related_enterprises_granted
2015-05-07 12:50:56 +10:00
Rob Harrington
5806f50a84
Renaming granting > related_enterprises_granting
2015-05-07 12:50:56 +10:00
Rob Harrington
5cd528a87d
Removing obsolete related_enterprises_with permission method
2015-05-07 12:50:56 +10:00
Rob Harrington
f0f7e0ee2f
Making permissions method managed_and_related_enterprise_with method more specific
2015-05-07 12:50:56 +10:00
Rob Harrington
7ffe0f042e
Moving accessible_by scope on Enterprise to permissions
2015-05-07 12:50:55 +10:00
Rob Harrington
0a03483e36
Adding permissions methods for visible and editable orders and line_items
2015-05-07 12:50:55 +10:00
Rob Harrington
bc89018ee1
Refer to the right variable doofus
2015-04-11 23:24:50 +10:00
Rob Harrington
6f81a9ba18
Save common permission method results as instance variables
2015-04-11 22:53:57 +10:00
Rob Harrington
26d55baa35
Moving order cycle permissions to their own permissions class
2015-04-11 21:11:10 +10:00
Rob Harrington
c28ebf63ab
As participating Hub, I cannot edit incoming exchanges despite being granted P-OC by the producer
2015-04-09 13:41:43 +10:00
Rob Harrington
b1624a733e
Editable variants for incoming exchanges for hubs include those for producers that have granted my hub P-OC
2015-04-08 13:38:37 +10:00
Rob Harrington
b8ce6ed0fc
Coordinator can see any enterprises that are already in the order cycle
2015-04-08 13:28:49 +10:00
Rob Harrington
104a8ddecf
Refactor order_cycle_enterpises_for permission method, now requires an order cycle
2015-04-08 13:00:17 +10:00
Rob Harrington
4dcfec1de9
make enterprises_for_order_cycle permissions more correct
2015-04-08 12:12:02 +10:00
Rob Harrington
8859aa27ee
Slight refactor of order cycle enterprises
2015-04-08 10:33:32 +10:00
Rob Harrington
24062e5585
Adding permissions for outgoing hubs to see producers whose variants they are distributing, despite P-OC not existing
2015-04-08 10:15:50 +10:00
Rob Harrington
4a87798bb4
Variants belonging to a producer I manager that are already in an outgoing an exchange need not be editable
2015-04-06 23:30:43 +10:00
Rob Harrington
f20844c2a0
Adding editable scope for variants in outgoing exchanges
2015-04-05 15:25:44 +10:00
Rob Harrington
136d361134
Fixing comment
2015-04-05 14:14:47 +10:00
Rob Harrington
009b25a491
Adding an editable variants scope for incoming exchanges
2015-04-05 13:59:00 +10:00
Rob Harrington
d28fc7e42d
Hubs can see incoming exchanges of producers who have given them P-OC or whose variants they are actively distributing
2015-04-03 14:58:01 +11:00
Rob Harrington
74b7feda53
coordinator of a simple order cycle has permission to add their own variants to outgoing exchanges
2015-03-27 16:16:13 +11:00
Rob Harrington
524645aff4
Replacing visible_variants_for(exchange) with more general methods for determining visbility based on the enterprises involced and the current order cyclegs
2015-03-27 16:16:11 +11:00
Rob Harrington
b747f61eb1
P-OC permissions don't apply when determining which enterprises are loaded for order cycle interface
2015-03-27 16:16:10 +11:00
Rob Harrington
7e24e6743e
enterprises_for is now order_cycle_enterprises_for, and can be passed an order_cycle or a coordinator (for new order_cycles)
2015-03-27 16:16:09 +11:00
Rob Harrington
d8c4e292c8
Adding method for determining variant override hubs
2015-03-27 16:09:45 +11:00
Rob Harrington
81765de7a7
Building a permission method to determine which enterprises are visible to the user for a given OC
2015-03-27 16:07:38 +11:00
Rob Harrington
00821a60cc
More specific references to enterprise id in permissions querying methods
2015-03-27 16:07:37 +11:00
Rob Harrington
252ddf9beb
Adding method to permissions library for scoping the list of visible variants in a given exchange to a particular user
2015-03-27 16:07:37 +11:00
Rob Harrington
22161bfd6e
rewriting permissions query functions in permissions library, to make scoping easier
2015-03-27 16:07:37 +11:00