Skip to content

Commit

Permalink
Merge branch 'new-subgraph-query' into qos-dashboard
Browse files Browse the repository at this point in the history
  • Loading branch information
vincenttaglia committed Oct 13, 2024
2 parents d931c91 + 00dcd8f commit 172a945
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/store/allocations.js
Original file line number Diff line number Diff line change
Expand Up @@ -433,6 +433,7 @@ export const useAllocationStore = defineStore('allocationStore', {
subgraphDeployment{
versions(first:1, orderBy:version, orderDirection:desc){
subgraph{
id
metadata{
image
displayName
Expand Down
6 changes: 3 additions & 3 deletions src/store/newAllocationSetter.js
Original file line number Diff line number Diff line change
Expand Up @@ -211,8 +211,8 @@ export const useNewAllocationSetterStore = defineStore('allocationSetter', {
customPOI = `${state.customPOIs[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash]} true `;
}
}
if(Object.keys(state.newAllocations).includes(allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash)){
if(BigNumber(allocationStore.getSelectedAllocations[i].allocatedTokens).dividedBy(10**18) > BigNumber(state.newAllocations[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash])){
if(subgraphStore.selected.includes(allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash)){
if(BigNumber(allocationStore.getSelectedAllocations[i].allocatedTokens).dividedBy(10**18).gt(BigNumber(state.newAllocations[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash]))){
reallocate += `graph indexer actions queue reallocate ${allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash} ${allocationStore.getSelectedAllocations[i].id} ${state.newAllocations[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash]} ${customPOI}--network ${chainStore.getActiveChain.id}\n`;
} else{
reallocate2 += `graph indexer actions queue reallocate ${allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash} ${allocationStore.getSelectedAllocations[i].id} ${state.newAllocations[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash]} ${customPOI}--network ${chainStore.getActiveChain.id}\n`;
Expand All @@ -239,7 +239,7 @@ export const useNewAllocationSetterStore = defineStore('allocationSetter', {
//console.log("CHECK");
//console.log(BigNumber(allocationStore.getSelectedAllocations[i].allocatedTokens).dividedBy(10**18).toString());
//console.log(state.newAllocations[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash]);
if(BigNumber(allocationStore.getSelectedAllocations[i].allocatedTokens).dividedBy(10**18) > BigNumber(state.newAllocations[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash])){
if(BigNumber(allocationStore.getSelectedAllocations[i].allocatedTokens).dividedBy(10**18).gt(BigNumber(state.newAllocations[allocationStore.getSelectedAllocations[i].subgraphDeployment.ipfsHash]))){
allo = {
status: 'queued',
type: 'reallocate',
Expand Down
2 changes: 1 addition & 1 deletion src/views/ActionQueueManager.vue
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<br>
<div class="d-flex justify-space-between">
<div class="d-flex mr-auto flex-1-1-0 align-center">
<v-btn text="Refresh actions" prepend-icon="mdi-refresh" @click="queryActions()" class="mx-5 my-6 d-inline-block align-self-center justify-center" v-if="accountStore.getAgentConnectStatus" stacked></v-btn>
<v-btn text="Refresh actions" prepend-icon="mdi-refresh" @click="queryActions()" class="mx-5 my-6" v-if="accountStore.getAgentConnectStatus" stacked></v-btn>
<v-select
v-model="managerSettingStore.settings.statusFilter"
:items="[{title: 'Queued', value: 'queued'}, {title:'Approved', value: 'approved'}, {title: 'Pending', value: 'pending'}, {title: 'Success', value: 'success'}, {title: 'Failed', value: 'failed'}, {title: 'Canceled', value: 'canceled'}]"
Expand Down

0 comments on commit 172a945

Please sign in to comment.