Skip to content
Projects
Groups
Snippets
Help
Sign in / Register
Toggle navigation
Minds Frontend
Project overview
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
801
Merge Requests
50
CI / CD
Security & Compliance
Packages
Wiki
Snippets
Members
Collapse sidebar
Close sidebar
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Minds
Minds Frontend
Commits
41650ade
Commit
41650ade
authored
1 hour ago
by
Emiliano Balbuena
Browse files
Options
Download
(feat): Spinner while doing admin withdrawal operations
parent
ef3e7658
goal/withdrawals-approval
1 merge request
!652
(feat): Withdrawal status support
Pipeline
#95490706
passed with stages
in 38 minutes and 18 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
2 deletions
+18
-2
src/app/controllers/admin/withdrawals/withdrawals.component.html
View file @
41650ade
...
...
@@ -89,6 +89,7 @@
<button
class=
"mf-button mf-button--smaller"
[disabled]=
"inProgress"
(click)=
"approve(request)"
>
Approve
...
...
@@ -96,6 +97,7 @@
<button
class=
"mf-button mf-button--destructive mf-button--smaller"
[disabled]=
"inProgress"
(click)=
"reject(request)"
>
Reject
...
...
This diff is collapsed.
src/app/controllers/admin/withdrawals/withdrawals.component.ts
View file @
41650ade
...
...
@@ -84,6 +84,8 @@ export class AdminWithdrawals {
return
;
}
this
.
inProgress
=
true
;
try
{
const
endpoint
=
`api/v2/admin/rewards/withdrawals/
${[
withdrawal
.
user_guid
,
...
...
@@ -95,8 +97,13 @@ export class AdminWithdrawals {
withdrawal
.
status
=
'
approved
'
;
}
catch
(
e
)
{
alert
(
'
There was an issue while approving withdrawal
'
);
alert
(
`There was an issue while approving withdrawal:
${(
e
&&
e
.
message
)
||
'
Unknown server error
'
}
`
);
}
this
.
inProgress
=
false
;
}
async
reject
(
withdrawal
)
{
...
...
@@ -104,6 +111,8 @@ export class AdminWithdrawals {
return
;
}
this
.
inProgress
=
true
;
try
{
const
endpoint
=
`api/v2/admin/rewards/withdrawals/
${[
withdrawal
.
user_guid
,
...
...
@@ -115,7 +124,12 @@ export class AdminWithdrawals {
withdrawal
.
status
=
'
rejected
'
;
}
catch
(
e
)
{
alert
(
'
There was an issue while rejecting withdrawal
'
);
alert
(
`There was an issue while rejecting withdrawal:
${(
e
&&
e
.
message
)
||
'
Unknown server error
'
}
`
);
}
this
.
inProgress
=
false
;
}
}
This diff is collapsed.
Please
register
or
sign in
to comment