Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Peeglid
EkrkSignupPeegel
Commits
e6c33b2b
Commit
e6c33b2b
authored
May 06, 2015
by
Argo Roots
Browse files
Fleep integration
parent
eebf2dd5
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
index.html
View file @
e6c33b2b
This diff is collapsed.
Click to expand it.
source/javascripts/script.js
View file @
e6c33b2b
...
...
@@ -2,6 +2,7 @@ var PAGE_URL = 'http://c3sregistration.studyitin.ee/'
var
API_URL
=
'
https://entu.keeleressursid.ee/api2/
'
var
API_USER
=
711
var
API_KEY
=
'
s2SuDSy9Bx5Qowj492ThZSKgZ8yCL7B1qBW2D11qeBF9KivEDCkM8LBvlPoa0Ddb
'
var
FLEEP_HOOK_URL
=
'
https://fleep.io/hook/abypGACaReaTyC6PGvw1SQ
'
function
cl
(
d
)
{
console
.
log
(
d
)
...
...
@@ -79,8 +80,21 @@ angular.module('ekrkApp', ['ngRoute', 'ngResource'])
})
})
.
success
(
function
(
data
)
{
$scope
.
sending
=
false
$scope
.
sent
=
true
$http
({
method
:
'
POST
'
,
url
:
FLEEP_HOOK_URL
,
data
:
{
'
message
'
:
'
https://entu.keeleressursid.ee/entity/person/
'
+
$scope
.
id
}
})
.
success
(
function
(
data
)
{
$scope
.
sending
=
false
$scope
.
sent
=
true
})
.
error
(
function
(
data
)
{
cl
(
data
.
error
)
$scope
.
sending
=
false
})
})
.
error
(
function
(
data
)
{
cl
(
data
.
error
)
...
...
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