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
$path = public_path() . '/directory/' . $file_name; | |
$i = 0; | |
while(file_exists($path)) { | |
$i++; | |
if($i == 1) { | |
$file_name = pathinfo($path, PATHINFO_FILENAME); | |
$file_extension = pathinfo($path, PATHINFO_EXTENSION); | |
$file_name = $file_name . '-r' . $i . '.' . $file_extension; | |
$path = public_path() . '/directory'/' . $file_name; |
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
$(selector).on('click', '#id or .class name', function() { | |
var id = $(this).closest('tr').find('#id').val(); | |
//post the id to a url to update | |
$.post('/url', { | |
id: id | |
}); | |
}); | |
setInterval(function () { update() }, 10000); |
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
<script> | |
$('.pdf').on('click', function() { | |
var revision_id = $(this).data('revision'); | |
$.ajax({ | |
url:'URL/?revision_id=' +revision_id, | |
dataType: 'JSONP', | |
jsonpCallback: 'callback', | |
jsonp: 'callback', |
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
Show hidden characters
{ | |
"compilerOptions": { | |
"target": "ES5", | |
"module": "commonjs", | |
"sourceMap": true, | |
"emitDecoratorMetadata": true, | |
"experimentalDecorators": true, | |
"removeComments": false, | |
"noImplicitAny": false | |
} |
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
<select class="form-control" ng-options="cat.id as cat.name for cat in categories" ng-model="categoryId"></select> |
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
<div ng-repeat="technician in techniciansArr track by $index"> |
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
<?php header('Access-Control-Allow-Origin: *'); ?> |
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
if(!$scope.$$phase) { $scope.$apply() }; |
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
html | |
<p class="input-group"> | |
<input type="text" class="form-control" datepicker-popup="{{format}}" ng-model="latestRevision(dValue).date_returned" close-text="Close" datepicker-options="datePicker.options" is-open="datePicker.instances['returned'+dValue.document_id]" /> | |
<span class="input-group-btn"> | |
<button type="button" class="btn btn-sm btn-default no-border" datepicker-options="datePicker.options" close-text="Close" ng-click="datePicker.open($event, 'returned'+dValue.document_id)"><i class="fa fa-calendar"></i></button> | |
</span> | |
</p> | |
js | |
$scope.datePicker = (function() { |
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
<?php | |
namespace App; | |
use Jenssegers\Mongodb\Eloquent\Model as Eloquent; | |
//use Illuminate\Contracts\Auth\Authenticatable; | |
use Illuminate\Auth\Authenticatable as AuthenticableTrait; | |
use Illuminate\Auth\Passwords\CanResetPassword; | |
use Illuminate\Contracts\Auth\Authenticatable as AuthenticatableContract; | |
use Illuminate\Contracts\Auth\CanResetPassword as CanResetPasswordContract; |
OlderNewer