Skip to content
Next
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Switch to GitLab Next
Sign in / Register
Toggle navigation
Minds Frontend
Project
Project
Details
Activity
Releases
Dependency List
Cycle Analytics
Insights
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Locked Files
Issues
808
Issues
808
List
Boards
Labels
Service Desk
Milestones
Merge Requests
52
Merge Requests
52
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Minds
Minds Frontend
Commits
23fdbe18
Commit
23fdbe18
authored
5 hours ago
by
Emiliano Balbuena
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
(chore): Disallow cancelling if not created or approved
parent
31f20098
goal/boost-campaigns-e24
1 merge request
!387
WIP: Boost Campaigns (&24)
Pipeline
#71166146
passed with stages
in 29 minutes and 3 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
3 deletions
+7
-3
creator.component.html
...pp/modules/boost/campaigns/creator/creator.component.html
+2
-2
creator.component.ts
src/app/modules/boost/campaigns/creator/creator.component.ts
+5
-1
No files found.
src/app/modules/boost/campaigns/creator/creator.component.html
View file @
23fdbe18
...
...
@@ -7,7 +7,7 @@
<div
class=
"m-page--section-button-bar"
>
<h1>
<ng-container
*
ngIf=
"!isEditing; else titleIsEditing"
i18n
>
New Campaign
</ng-container>
<ng-template
#
titleIsEditing
>
Edit Campaign
</ng-template>
<ng-template
#
titleIsEditing
i18n
>
Edit Campaign
</ng-template>
</h1>
<div
class=
"m-page--section-button-bar--buttons"
>
...
...
@@ -185,7 +185,7 @@
<div
class=
"m-form--error"
*
ngIf=
"currentError && !inProgress"
>
{{currentError}}
</div>
</div>
<div
class=
"m-form--field"
*
ngIf=
"
isEditing
"
>
<div
class=
"m-form--field"
*
ngIf=
"
canCancel()
"
>
<button
type=
"button"
(
click
)="
cancel
($
event
);"
...
...
This diff is collapsed.
Click to expand it.
src/app/modules/boost/campaigns/creator/creator.component.ts
View file @
23fdbe18
import
{
ChangeDetectionStrategy
,
ChangeDetectorRef
,
Component
,
OnDestroy
,
OnInit
}
from
"
@angular/core
"
;
import
{
ActivatedRoute
,
Router
}
from
'
@angular/router
'
;
import
{
Campaign
,
CampaignPayment
}
from
"
../campaigns.type
"
;
import
{
Campaign
,
Campaign
DeliveryStatus
,
Campaign
Payment
}
from
"
../campaigns.type
"
;
import
{
CampaignsService
}
from
'
../campaigns.service
'
;
import
{
Subscription
}
from
'
rxjs
'
;
import
{
Tag
}
from
'
../../../hashtags/types/tag
'
;
...
...
@@ -148,6 +148,10 @@ export class BoostCampaignsCreatorComponent implements OnInit, OnDestroy {
}
}
canCancel
()
{
return
this
.
isEditing
&&
([
'
created
'
,
'
approved
'
]
as
CampaignDeliveryStatus
[]).
indexOf
(
this
.
campaign
.
delivery_status
)
>
-
1
;
}
get
types
()
{
return
this
.
service
.
getTypes
();
}
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment