moves logic to PlayerView, adds simple notifications when debugging
This commit is contained in:
@@ -130,7 +130,7 @@ export const AppStorage = {
|
||||
// Put a claim on an item from group chest.
|
||||
putRequest (itemId) {
|
||||
const playerId = this.state.player_id
|
||||
Api.putClaim(playerId, itemId)
|
||||
return Api.putClaim(playerId, itemId)
|
||||
.then(done => {
|
||||
// Update cliend-side state
|
||||
this.state.player_claims[playerId].push(itemId);
|
||||
@@ -139,7 +139,7 @@ export const AppStorage = {
|
||||
// Withdraws a claim.
|
||||
cancelRequest(itemId) {
|
||||
const playerId = this.state.player_id
|
||||
Api.unClaim(playerId, itemId)
|
||||
return Api.unClaim(playerId, itemId)
|
||||
.then(done => {
|
||||
var idx = this.state.player_claims[playerId].indexOf(itemId);
|
||||
if (idx > -1) {
|
||||
|
||||
Reference in New Issue
Block a user