Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
See what's new at GitLab
4
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Switch to GitLab Next
Sign in / Register
Toggle navigation
Causes Cash
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
15
Issues
15
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Test Cases
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Metrics
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Bitcoin Please
Causes Cash
Commits
4acd478e
Commit
4acd478e
authored
Aug 16, 2020
by
Bitcoin Please
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added banner to media.
parent
9eea3958
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
80 additions
and
31 deletions
+80
-31
src/views/Campaign/Details/Content.vue
src/views/Campaign/Details/Content.vue
+5
-5
src/views/Campaign/Details/Content/Payouts.vue
src/views/Campaign/Details/Content/Payouts.vue
+27
-19
src/views/Campaign/Details/History/News.vue
src/views/Campaign/Details/History/News.vue
+6
-1
src/views/Campaign/Details/Title.vue
src/views/Campaign/Details/Title.vue
+14
-6
src/views/Campaign/Manage/Media.vue
src/views/Campaign/Manage/Media.vue
+28
-0
No files found.
src/views/Campaign/Details/Content.vue
View file @
4acd478e
...
...
@@ -55,7 +55,7 @@
<div
class=
"author-profile"
>
<a
class=
"author-icon"
href=
"javascript://"
>
<img
:src=
"ownerAvatar"
alt=
""
></a>
by
<a
class=
"author-name"
href=
"javascript://"
>
{{
ownerN
ickn
ame
}}
</a>
by
<a
class=
"author-name"
href=
"javascript://"
>
{{
ownerName
}}
</a>
</div>
<div
class=
"author-address"
>
...
...
@@ -373,11 +373,11 @@ export default {
},
/**
* Owner N
ickn
ame
* Owner Name
*/
ownerN
ickn
ame
()
{
if
(
this
.
campaign
&&
this
.
campaign
.
owner
.
nickname
)
{
return
this
.
campaign
.
owner
.
nickname
ownerName
()
{
if
(
this
.
campaign
&&
(
this
.
campaign
.
owner
.
label
||
this
.
campaign
.
owner
.
nickname
)
)
{
return
this
.
campaign
.
owner
.
label
||
this
.
campaign
.
owner
.
nickname
}
else
{
return
null
}
...
...
src/views/Campaign/Details/Content/Payouts.vue
View file @
4acd478e
...
...
@@ -170,7 +170,7 @@ import Nito from 'nitojs'
import
numeral
from
'
numeral
'
import
QRCode
from
'
qrcode
'
import
superagent
from
'
superagent
'
import
Swal
from
'
sweetalert2
'
//
import Swal from 'sweetalert2'
// const { Contract, SignatureTemplate } = require('cashscript')
import
{
Contract
,
SignatureTemplate
}
from
'
cashscript
'
...
...
@@ -247,7 +247,13 @@ export default {
}
}
QRCode
.
toString
(
this
.
pledgeAddress
,
params
,
(
err
,
value
)
=>
{
/* Calculate pledge amount (in BCH). */
const
amount
=
parseFloat
(
this
.
pledgeSatoshis
/
100000000.0
)
/* Set payment URL. */
const
paymentUrl
=
`
${
this
.
pledgeAddress
}
?amount=
${
amount
}
`
QRCode
.
toString
(
paymentUrl
,
params
,
(
err
,
value
)
=>
{
if
(
err
)
{
return
console
.
error
(
'
QR Code ERROR:
'
,
err
)
}
...
...
@@ -385,23 +391,25 @@ export default {
* Wallet Pay
*/
walletPay
()
{
Swal
.
fire
({
title
:
'
Are you sure?
'
,
text
:
"
You won't be able to revert this!
"
,
icon
:
'
warning
'
,
showCancelButton
:
true
,
confirmButtonColor
:
'
#3085d6
'
,
cancelButtonColor
:
'
#d33
'
,
confirmButtonText
:
'
Yes, delete it!
'
}).
then
((
result
)
=>
{
if
(
result
.
value
)
{
Swal
.
fire
(
'
Deleted!
'
,
'
Your file has been deleted.
'
,
'
success
'
)
}
})
this
.
toast
([
'
Oops!
'
,
'
Your wallet balance is not enough
'
,
'
error
'
])
// Swal.fire({
// title: 'Are you sure?',
// text: "You won't be able to revert this!",
// icon: 'warning',
// showCancelButton: true,
// confirmButtonColor: '#3085d6',
// cancelButtonColor: '#d33',
// confirmButtonText: 'Yes, delete it!'
// }).then((result) => {
// if (result.value) {
// Swal.fire(
// 'Deleted!',
// 'Your file has been deleted.',
// 'success'
// )
// }
// })
},
/**
...
...
src/views/Campaign/Details/History/News.vue
View file @
4acd478e
...
...
@@ -118,8 +118,13 @@ export default {
return
article
})
/* Sort by date (newest first). */
articles
.
sort
((
a
,
b
)
=>
{
return
b
.
createdAt
-
a
.
createdAt
})
/* Return (reversed) array. */
return
articles
.
reverse
()
return
articles
},
...
...
src/views/Campaign/Details/Title.vue
View file @
4acd478e
...
...
@@ -46,7 +46,10 @@ export default {
watch: {
campaign: function (_campaign) {
if (_campaign && _campaign.title) {
console.log(
'
CAMPAIGN
HAS
CHANGED
,
UPDATE
TITLE
!!
'
, _campaign)
// console.log(
'
CAMPAIGN
HAS
CHANGED
,
UPDATE
TITLE
!!
'
, _campaign)
/* Update banner. */
this.updateBanner()
/* Update title. */
this.updateTitle()
...
...
@@ -66,11 +69,16 @@ export default {
* Update Banner
*/
updateBanner() {
/* Set banner URL. */
// this.bannerUrl =
'
https
:
//i.imgur.com/3UPJZT6.jpg' // sofa
// this.bannerUrl = 'https://i.imgur.com/2NuUJxd.jpg' // headphones
this
.
bannerUrl
=
'
https://i.imgur.com/JQbiIbD.jpg
'
// working @ desk
// this.bannerUrl = 'https://i.imgur.com/9vNfGgt.jpg' // organized desk
if (this.campaign && this.campaign.media && this.campaign.media.banner) {
/* Set banner URL. */
this.bannerUrl = this.campaign.media.banner
} else {
/* Set banner URL. */
// this.bannerUrl =
'
https
:
//i.imgur.com/3UPJZT6.jpg' // sofa
// this.bannerUrl = 'https://i.imgur.com/2NuUJxd.jpg' // headphones
this
.
bannerUrl
=
'
https://i.imgur.com/JQbiIbD.jpg
'
// working @ desk
// this.bannerUrl = 'https://i.imgur.com/9vNfGgt.jpg' // organized desk
}
},
/**
...
...
src/views/Campaign/Manage/Media.vue
View file @
4acd478e
...
...
@@ -117,6 +117,31 @@
<hr
/>
<div
class=
"field"
>
<label
for=
"uploadfile"
>
Campaign Banner Image
</label>
<!--
<span
class=
"label-desc"
>
This is the first thing that people will see when they come across your campaign.
Choose an image that’s crisp and text-free.
570px by 400px recommended resolution.
<a
href=
"javascript://"
>
Here are some tips.
</a>
</span>
-->
<img
:src=
"bannerUrl"
/>
<input
type=
"text"
id=
"capaignstory"
placeholder=
"Banner URL"
v-model=
"bannerUrl"
>
</div>
<hr
/>
<div
class=
"field"
>
<label
for=
"uploadfile1"
>
Campaign Video
...
...
@@ -286,6 +311,8 @@ export default {
// fundId: null,
// referrerId: null,
bannerUrl
:
null
,
videoCaption
:
null
,
videoDescription
:
null
,
...
...
@@ -349,6 +376,7 @@ export default {
/* Set media. */
const
media
=
{
main
:
this
.
photo1Url
||
null
,
banner
:
this
.
bannerUrl
||
null
,
cover
:
this
.
photo1Url
||
null
,
gallery
:
[
this
.
photo2Url
||
null
,
...
...
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