ForgeFlow / stock-rma

Stock RMA
GNU Affero General Public License v3.0
38 stars 41 forks source link

[14.0][REF] rma: change rules to route in warehouse #456

Open DavidJForgeFlow opened 1 year ago

DavidJForgeFlow commented 1 year ago

The stock.rule fields are not used anywhere on rma. It's only usability is automatically setting the rules when setting a new warehouse with a RMA system. However, these rules are created by default in the main warehouse by the data. I propose to change the rules for routes to keep a good track of the RMA routes in warehouses and avoid duplicates.

@ForgeFlow

codecov-commenter commented 1 year ago

Codecov Report

Merging #456 (25b3a45) into 14.0 (fb9af9b) will decrease coverage by 0.02%. The diff coverage is 73.33%.

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456/graphs/tree.svg?width=650&height=150&src=pr&token=hagShlnibr&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent)](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent) ```diff @@ Coverage Diff @@ ## 14.0 #456 +/- ## ========================================== - Coverage 80.67% 80.65% -0.02% ========================================== Files 156 156 Lines 4858 4855 -3 Branches 894 892 -2 ========================================== - Hits 3919 3916 -3 + Misses 729 727 -2 - Partials 210 212 +2 ``` | [Files](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent) | Coverage Δ | | |---|---|---| | [rma/tests/test\_rma.py](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent#diff-cm1hL3Rlc3RzL3Rlc3Rfcm1hLnB5) | `99.56% <100.00%> (-0.44%)` | :arrow_down: | | [rma\_account/tests/test\_rma\_stock\_account.py](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent#diff-cm1hX2FjY291bnQvdGVzdHMvdGVzdF9ybWFfc3RvY2tfYWNjb3VudC5weQ==) | `98.06% <100.00%> (-1.29%)` | :arrow_down: | | [rma/models/stock\_warehouse.py](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent#diff-cm1hL21vZGVscy9zdG9ja193YXJlaG91c2UucHk=) | `82.05% <69.23%> (+3.22%)` | :arrow_up: | ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent). Last update [fb9af9b...25b3a45](https://app.codecov.io/gh/ForgeFlow/stock-rma/pull/456?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Eficent).
AaronHForgeFlow commented 11 months ago

Also, I think the mehtod def _default_routes(self): in rma_operation should be changed so it takes the routes of the default warehouse