1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2025-01-17 06:52:27 +01:00

share on twitter with title

This commit is contained in:
Sylvain 2016-09-26 16:44:45 +02:00
parent a1fd69f309
commit 30c52dfe95
2 changed files with 2 additions and 2 deletions

View File

@ -417,7 +417,7 @@ Application.Controllers.controller "ShowEventController", ["$scope", "$state", "
# Return the URL allowing to share the current project on the Twitter social network
##
$scope.shareOnTwitter = ->
'https://twitter.com/intent/tweet?url='+encodeURIComponent($state.href('app.public.events_show', {id: $scope.event.id}, {absolute: true}));
'https://twitter.com/intent/tweet?url='+encodeURIComponent($state.href('app.public.events_show', {id: $scope.event.id}, {absolute: true}))+'&text='+encodeURIComponent($scope.event.title)

View File

@ -471,5 +471,5 @@ Application.Controllers.controller "ShowProjectController", ["$scope", "$state",
# Return the URL allowing to share the current project on the Twitter social network
##
$scope.shareOnTwitter = ->
'https://twitter.com/intent/tweet?url='+encodeURIComponent($state.href('app.public.projects_show', {id: $scope.project.slug}, {absolute: true}));
'https://twitter.com/intent/tweet?url='+encodeURIComponent($state.href('app.public.projects_show', {id: $scope.project.slug}, {absolute: true}))+'&text='+encodeURIComponent($scope.project.name)
]