+ Dear {{ $request->getRequestedBy()->getFullName() }},
+ User {{ $request->getSpeaker()->getFullName() }} has approved your request to edit his/her Speaker Profile.
+
+
+ Dear {{ $request->getRequestedBy()->getFullName() }},
+ User {{ $request->getSpeaker()->getFullName() }} has rejected your request to edit his/her Speaker Profile.
+
+
+ Dear {{ $request->getSpeaker()->getFullName() }},
+ User {{ $request->getRequestedBy()->getFullName() }} has requested to be able to edit your Speaker Profile.
+ To Allow that please click on the following link Allow.
+
+
+
+ Your Speaker Edit Profile Permission Request was Approved!.
+
+
+@stop
\ No newline at end of file
diff --git a/resources/views/speakers/edit_permissions/approved_error.blade.php b/resources/views/speakers/edit_permissions/approved_error.blade.php
new file mode 100644
index 00000000..fcd61d74
--- /dev/null
+++ b/resources/views/speakers/edit_permissions/approved_error.blade.php
@@ -0,0 +1,9 @@
+@extends('layouts.master')
+@section('title', 'Speaker Edit Permission - Approved Error')
+@section('content')
+
+
+ There was a problem with your request.
+
+
+@stop
\ No newline at end of file
diff --git a/resources/views/speakers/edit_permissions/approved_validation_error.blade.php b/resources/views/speakers/edit_permissions/approved_validation_error.blade.php
new file mode 100644
index 00000000..c013e573
--- /dev/null
+++ b/resources/views/speakers/edit_permissions/approved_validation_error.blade.php
@@ -0,0 +1,9 @@
+@extends('layouts.master')
+@section('title', 'Speaker Edit Permission - Approved Validation Error')
+@section('content')
+
+
+ There was a problem with your request. the permission request its already approved!.
+
+
+@stop
\ No newline at end of file
diff --git a/resources/views/speakers/edit_permissions/rejected.blade.php b/resources/views/speakers/edit_permissions/rejected.blade.php
new file mode 100644
index 00000000..7a9cca96
--- /dev/null
+++ b/resources/views/speakers/edit_permissions/rejected.blade.php
@@ -0,0 +1,9 @@
+@extends('layouts.master')
+@section('title', 'Speaker Edit Permission - Rejected')
+@section('content')
+
+
+ Your Speaker Edit Profile Permission Request was Rejected!.
+
+
+@stop
\ No newline at end of file
diff --git a/resources/views/speakers/edit_permissions/rejected_error.blade.php b/resources/views/speakers/edit_permissions/rejected_error.blade.php
new file mode 100644
index 00000000..cd4ec893
--- /dev/null
+++ b/resources/views/speakers/edit_permissions/rejected_error.blade.php
@@ -0,0 +1,9 @@
+@extends('layouts.master')
+@section('title', 'Speaker Edit Permission - Rejected Error')
+@section('content')
+
+
+ There was a problem with your request.
+
+
+@stop
\ No newline at end of file
diff --git a/resources/views/speakers/edit_permissions/rejected_validation_error.blade.php b/resources/views/speakers/edit_permissions/rejected_validation_error.blade.php
new file mode 100644
index 00000000..a153ae60
--- /dev/null
+++ b/resources/views/speakers/edit_permissions/rejected_validation_error.blade.php
@@ -0,0 +1,9 @@
+@extends('layouts.master')
+@section('title', 'Speaker Edit Permission - Rejected Validation Error')
+@section('content')
+
+
+ There was a problem with your request. the permission request its already redeem !.
+
+
+@stop
\ No newline at end of file
diff --git a/tests/OAuth2SpeakersApiTest.php b/tests/OAuth2SpeakersApiTest.php
index 85033512..001f6e43 100644
--- a/tests/OAuth2SpeakersApiTest.php
+++ b/tests/OAuth2SpeakersApiTest.php
@@ -622,4 +622,64 @@ final class OAuth2SpeakersApiTest extends ProtectedApiTest
$presentations = json_decode($content);
$this->assertTrue(!is_null($presentations));
}
+
+ public function testRequestSpeakerEditPermission()
+ {
+
+ $headers = [
+ "HTTP_Authorization" => " Bearer " . $this->access_token,
+ "CONTENT_TYPE" => "application/json"
+ ];
+
+ $params = [
+ 'speaker_id' => 9
+ ];
+
+ $response = $this->action
+ (
+ "PUT",
+ "OAuth2SummitSpeakersApiController@requestSpeakerEditPermission",
+ $params,
+ [],
+ [],
+ [],
+ $headers
+ );
+
+ $this->assertResponseStatus(201);
+ $content = $response->getContent();
+ $request = json_decode($content);
+ $this->assertTrue($request->id > 0);
+ return $request;
+ }
+
+ public function testGetRequestSpeakerEditPermission()
+ {
+
+ $headers = [
+ "HTTP_Authorization" => " Bearer " . $this->access_token,
+ "CONTENT_TYPE" => "application/json"
+ ];
+
+ $params = [
+ 'speaker_id' => 9
+ ];
+
+ $response = $this->action
+ (
+ "GET",
+ "OAuth2SummitSpeakersApiController@getSpeakerEditPermission",
+ $params,
+ [],
+ [],
+ [],
+ $headers
+ );
+
+ $this->assertResponseStatus(200);
+ $content = $response->getContent();
+ $request = json_decode($content);
+ $this->assertTrue($request->id > 0);
+ return $request;
+ }
}
\ No newline at end of file
diff --git a/tests/ProtectedApiTest.php b/tests/ProtectedApiTest.php
index 90b13375..a863dfb6 100644
--- a/tests/ProtectedApiTest.php
+++ b/tests/ProtectedApiTest.php
@@ -139,7 +139,6 @@ abstract class ProtectedApiTest extends \Tests\BrowserKitTestCase
{
$app = parent::createApplication();
App::singleton('App\Models\ResourceServer\IAccessTokenService', 'AccessTokenServiceStub');
-
return $app;
}