I explored a bit further through the REST API.
I gather that the edit made to a custom metrics value via the Player List are stored only in the Player Lists (the “/v2/lists/XX” schema).
The new value is not propagated to the Players data (“/v2/players/YY” schema).
So this seems to be by design.
The problem I face is that I am using these custom metrics in an equation. But the equation only takes values from the players schema rather than the player lists schema.
Updating each players custom metrics is quite tedious as the number of players is very large, so I was hoping to achieve this through a table like the player lists from one single page.
Is there any other trick that can be used to update the players custom metrics easily, rather than through the Edit Player section. I am also willing to dabble with the API to write a new frontend if that is the only way ..
Plugin Contributor
Savvas
(@savvasha)
Hi @rawnomad,
Unfortunately this is how SportsPress is designed.
Probably @brianmiyaji can give us more info.
Plugin Author
Brian
(@brianmiyaji)
@rawnomad There is a one-way override of player data, which can be changed via player lists. However, as you pointed out, the core player data will not be affected by editing a player list. This is by design, to allow multiple player lists with different sets of data (filtered by season, league, and team, for example).
Because of these filters, each player list is capable of having different sets of data for each player. This also means that player data must be edited directly to modify the player itself, rather than that player’s row within a player list.
For usability, I would definitely be supportive of having a simpler player edit screen where multiple players could be edited simultaneously. I’d recommend separating this functionality from player lists, though.
I hope this makes sense!