Commit 2939678
committed
feat(products): link fees to rate_card_rate and add product_item fee type
Fees produced by the new billing path need to reference the catalog rate that
generated them and a fee type identifying them as coming from a product item.
Add an optional rate_card_rate_id reference to fees (concurrent index,
unvalidated foreign key for a safe rollout) and append product_item to
Fee::FEE_TYPES. The existing fee types and billing path are untouched.1 parent 3f49147 commit 2939678
7 files changed
Lines changed: 53 additions & 2 deletions
File tree
- app/models
- db
- migrate
- spec/models
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
45 | 46 | | |
46 | 47 | | |
47 | 48 | | |
48 | | - | |
| 49 | + | |
49 | 50 | | |
50 | 51 | | |
51 | 52 | | |
| |||
414 | 415 | | |
415 | 416 | | |
416 | 417 | | |
| 418 | + | |
417 | 419 | | |
418 | 420 | | |
419 | 421 | | |
| |||
435 | 437 | | |
436 | 438 | | |
437 | 439 | | |
| 440 | + | |
438 | 441 | | |
439 | 442 | | |
440 | 443 | | |
| |||
449 | 452 | | |
450 | 453 | | |
451 | 454 | | |
| 455 | + | |
452 | 456 | | |
453 | 457 | | |
454 | 458 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
| 37 | + | |
36 | 38 | | |
37 | 39 | | |
38 | 40 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
231 | 231 | | |
232 | 232 | | |
233 | 233 | | |
| 234 | + | |
234 | 235 | | |
235 | 236 | | |
236 | 237 | | |
| |||
690 | 691 | | |
691 | 692 | | |
692 | 693 | | |
| 694 | + | |
693 | 695 | | |
694 | 696 | | |
695 | 697 | | |
| |||
3451 | 3453 | | |
3452 | 3454 | | |
3453 | 3455 | | |
3454 | | - | |
| 3456 | + | |
| 3457 | + | |
3455 | 3458 | | |
3456 | 3459 | | |
3457 | 3460 | | |
| |||
8651 | 8654 | | |
8652 | 8655 | | |
8653 | 8656 | | |
| 8657 | + | |
| 8658 | + | |
| 8659 | + | |
| 8660 | + | |
| 8661 | + | |
| 8662 | + | |
| 8663 | + | |
8654 | 8664 | | |
8655 | 8665 | | |
8656 | 8666 | | |
| |||
11870 | 11880 | | |
11871 | 11881 | | |
11872 | 11882 | | |
| 11883 | + | |
| 11884 | + | |
| 11885 | + | |
| 11886 | + | |
| 11887 | + | |
| 11888 | + | |
| 11889 | + | |
| 11890 | + | |
| 11891 | + | |
| 11892 | + | |
| 11893 | + | |
| 11894 | + | |
| 11895 | + | |
| 11896 | + | |
| 11897 | + | |
| 11898 | + | |
11873 | 11899 | | |
11874 | 11900 | | |
11875 | 11901 | | |
| |||
13658 | 13684 | | |
13659 | 13685 | | |
13660 | 13686 | | |
| 13687 | + | |
13661 | 13688 | | |
13662 | 13689 | | |
13663 | 13690 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
| |||
0 commit comments