Sort mapping accounts (#497)

This commit is contained in:
guibescos 2023-01-16 19:40:25 -06:00 committed by GitHub
parent e55a3bbb96
commit d2d82136c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 24 additions and 19 deletions

View File

@ -36,7 +36,12 @@ function MinPublishers() {
</thead>
<tbody>
{rawConfig.mappingAccounts.length ? (
rawConfig.mappingAccounts[0].products.map((product) =>
rawConfig.mappingAccounts
.sort(
(mapping1, mapping2) =>
mapping2.products.length - mapping1.products.length
)[0]
.products.map((product) =>
product.priceAccounts.map((priceAccount) => {
return (
<tr