-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from ECLK/master
update
- Loading branch information
Showing
28 changed files
with
3,239 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/vendor/ | ||
node_modules/ | ||
npm-debug.log | ||
yarn-error.log | ||
|
||
# Laravel 4 specific | ||
bootstrap/compiled.php | ||
app/storage/ | ||
|
||
# Laravel 5 & Lumen specific | ||
public/storage | ||
public/hot | ||
|
||
# Laravel 5 & Lumen specific with changed public path | ||
public_html/storage | ||
public_html/hot | ||
|
||
storage/*.key | ||
.env | ||
Homestead.yaml | ||
Homestead.json | ||
/.vagrant | ||
.phpunit.result.cache | ||
storage/framework/views/ae5a9a730500788d3a7068e5205c4fdaa854b85b.php | ||
storage/logs/laravel.log | ||
storage/logs/laravel.log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?php | ||
|
||
namespace App\Providers; | ||
|
||
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider; | ||
use GuzzleHttp\Client; | ||
|
||
class NominationClientServiceProvider extends ServiceProvider | ||
{ | ||
|
||
public function register() | ||
{ | ||
$this->app->bind('nomination.client', function () { | ||
$config = [ | ||
'base_uri' => env('NOMINETION_API'), | ||
'headers' => [ | ||
'Authorization' => 'Bearer ' . env('NOMINETION_API_KEY') | ||
] | ||
]; | ||
return new Client($config); | ||
}); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
@push('scripts') | ||
<script> | ||
//------------------------------------------------------------------------ | ||
$("select[name='election']").change(function () { | ||
var election_id = $("select[name='election']").val(); | ||
if (election_id !== '' && election_id !== null) { | ||
$("select[name='district']").prop('disabled', | ||
false).find('option[value]').remove(); | ||
$.ajaxSetup({ | ||
headers: { | ||
'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content') | ||
} | ||
}); | ||
$.ajax({ | ||
method: 'POST', | ||
url: '/getDistrict', | ||
data: {id: election_id }, | ||
success: function(response){ | ||
$.each(response, function (key, value) { | ||
$("select[name='district']") | ||
.append($("<option></option>") | ||
.attr("value", key) | ||
.text(value)); | ||
}); | ||
}, | ||
error: function(response){ | ||
} | ||
}); | ||
$.ajax({ | ||
type: 'POST', | ||
url: {{ url('/getDistrict') }}, | ||
data: {id: election_id }, | ||
}) | ||
.done(function (data) { | ||
$.each(data, function (key, value) { | ||
$("select[name='district']") | ||
.append($("<option></option>") | ||
.attr("value", key) | ||
.text(value)); | ||
}); | ||
}) | ||
.fail(function(jqXHR, textStatus){ | ||
console.log(jqXHR); | ||
}); | ||
} else { | ||
$("select[name='district']").prop('disabled', | ||
true).find("option[value]").remove(); | ||
} | ||
}); | ||
// ------------------------------------------------------------------------ | ||
</script> | ||
|
||
@ndpush |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
.../seAzWjj2cbgYR75Js5dCi1BUXe1nOjRSPQSKnIoy → .../CpbSL8Fwh80M4d5IdtfwCYjo3T3SOYWME7hYGII0
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
a:3:{s:6:"_token";s:40:"fE8w05ChkJnQ18hjzcwIBS8uJ04GUjqdZqDBVeEZ";s:9:"_previous";a:1:{s:3:"url";s:30:"http://localhost:8000/pe30x1x2";}s:6:"_flash";a:2:{s:3:"old";a:0:{}s:3:"new";a:0:{}}} | ||
a:3:{s:6:"_token";s:40:"ZIjByK6yKfQqSn74odE2bs6SFfLh1sv4mDDMPY98";s:9:"_previous";a:1:{s:3:"url";s:30:"http://localhost:8000/pe30x1x2";}s:6:"_flash";a:2:{s:3:"old";a:0:{}s:3:"new";a:0:{}}} |
1 change: 0 additions & 1 deletion
1
storage/framework/sessions/GjePa7kuVOlZkLn3m5U8F346CkYy1vI0u1KyYAj9
This file was deleted.
Oops, something went wrong.
1 change: 0 additions & 1 deletion
1
storage/framework/sessions/QlZwk35qZVGYKNQXhGNEzhKtvohs8u3kKxAI0k3v
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.