Compare commits

...

63 Commits

Author SHA1 Message Date
snipe a5b2dbfaf0 Merge remote-tracking branch 'origin/develop' 2015-07-23 12:33:26 -07:00
snipe e455b2af6e Only update email if password locking isn't set to true 2015-07-23 12:30:44 -07:00
snipe d26c40b26e Fixed issue where email not saved on edit 2015-07-23 12:28:26 -07:00
snipe abb970fe39 Merge remote-tracking branch 'origin/develop' 2015-07-17 16:25:55 -07:00
snipe f8ecbed829 Added purchase date to importer 2015-07-17 16:25:20 -07:00
snipe 9ac093e0be Merge remote-tracking branch 'origin/develop' 2015-07-17 14:18:20 -07:00
snipe 38c9d8d6ca Added notes/order number to asset view 2015-07-17 14:18:08 -07:00
snipe 4557502b1d Added notes/order number to controller 2015-07-17 14:15:08 -07:00
snipe b85d972488 Added mod rewrite to force SSL 2015-07-16 20:32:10 -07:00
snipe 61e16a4668 Merge remote-tracking branch 'origin/develop' 2015-07-16 16:25:15 -07:00
snipe e447159d4a Added checks for missing fields, added email column, asset notes 2015-07-16 16:23:35 -07:00
snipe b191406a0c Ignore couscous 2015-07-16 14:58:22 -07:00
snipe dacbdd9aa5 Delete book.json 2015-07-10 19:46:17 -07:00
snipe e1eb2da5f3 Create book.json 2015-07-09 13:32:26 -07:00
snipe f5d4eb5842 Merge pull request #897 from madd15/patch-2
Fix #896 - Only show Checkout/Checkin if deployable
2015-07-09 01:19:57 -07:00
snipe 9936cf4a43 Better production default for #903 2015-07-09 00:53:58 -07:00
snipe e9443a244c Small fix to config value 2015-07-09 00:52:05 -07:00
snipe f8be47dfbf Fixes #903 - adds config variable for multi_login, overrides Sentry method 2015-07-09 00:41:46 -07:00
snipe c2d63915c3 Fixed insecure font call 2015-07-08 17:48:59 -07:00
snipe fd59ca0802 Fixed spacing 2015-07-08 17:33:51 -07:00
snipe de23ec5785 Fixes #544 - disable checking an asset out to a user if it is not a deployable status 2015-07-08 17:18:46 -07:00
snipe 05f0b94bf6 Fixed language string 2015-07-08 13:05:17 -07:00
snipe f54c86db87 Command line asset importer 2015-07-08 13:05:05 -07:00
madd15 a22687abc5 Fix #896 - Only show Checkout/Checkin if deployable 2015-07-07 14:38:28 +09:30
snipe 82892a38b8 Merge pull request #891 from madd15/patch-3
Fix #873 - Remove serial, assigned_to & macaddress when cloning asset
2015-07-06 16:50:58 -07:00
madd15 61836f20c5 Clear Mac Address on Clone 2015-07-07 08:23:51 +09:30
madd15 62d382d704 Remove serial and assigned_to when cloning asset 2015-07-07 08:19:58 +09:30
snipe 3746bc333b Better checking for model name and category name 2015-07-06 14:12:49 -07:00
snipe ccde517c88 Use showAssetName to get asset name 2015-07-06 14:10:24 -07:00
snipe f855bfd4ef Better error checking for eol data 2015-07-06 14:09:48 -07:00
snipe 1601bdd4eb Added rtd_location_id back into selected columns 2015-07-02 16:52:08 -07:00
snipe 552bdfdc2d Switched defaultLoc to belongsTo relationship 2015-07-02 16:51:52 -07:00
snipe 1d4cfcfd58 Only save uploaded logo if not in demo mode 2015-06-30 22:38:40 -07:00
snipe 6915987239 Added demo language string 2015-06-30 22:38:19 -07:00
snipe 3a44a7e8bb Disable logo upload for demo 2015-06-30 22:38:12 -07:00
snipe f2abbd0e8f Deny editing users on demo 2015-06-30 22:10:23 -07:00
snipe 62f8d002e3 Temp commented out some stuff 2015-06-30 22:05:21 -07:00
snipe 0766ae2d17 Disallow group edit for demo 2015-06-30 22:04:48 -07:00
snipe 95920be8ea Fixed weird commenting 2015-06-30 22:04:05 -07:00
snipe 588ff742fe Add manufacturer to models listing for clarity 2015-06-30 19:15:43 -07:00
snipe 5084836737 Merge pull request #861 from strand/patch-1
Update Code of Conduct to Contributor Covenant 1.1.0
2015-06-19 09:16:08 -07:00
Strand McCutchen 063e3bbea6 Update Code of Conduct to Contributor Covenant 1.1.0 2015-06-19 10:15:05 -06:00
snipe c3c4e9def2 Fixes #852 - localized string for file types, added zip and rar for asset upload 2015-06-16 12:54:53 -07:00
snipe 7820efc121 Fixes #822 and #847 - added notes field on import for MySQL strict mode 2015-06-15 11:20:09 -07:00
snipe 5a6fe6ccf8 Fixes #806 2015-06-09 02:20:00 -07:00
snipe c69038d3ae Fixes #836 2015-06-09 02:00:55 -07:00
snipe 5939e46eee Bumped version for fixed 1.2.7 2015-06-01 17:52:03 -07:00
snipe a8a0a59982 Fixes #825 - title bar spacing issue 2015-06-01 17:51:20 -07:00
snipe 73a08c031c Fixes #818, and randomizes password for dummy user 2015-05-27 11:45:44 -07:00
snipe c77e7bf725 Merge pull request #816 from tomcastleman/develop
Reassignable should default to true on create form
2015-05-24 10:49:41 -07:00
Tom Castleman 7a4299c724 Reassignable should default to true on create form 2015-05-24 13:35:28 +01:00
snipe b9b0239837 Merge pull request #813 from tomcastleman/develop-1
Update develop following PR #809
2015-05-22 11:51:50 -07:00
snipe a43ae71afd Merge pull request #812 from tomcastleman/develop
Reassignable License Setting
2015-05-22 11:50:44 -07:00
Tom Castleman c4339a5d94 Merge branch 'master' into develop
* master:
  Removed debugbar:publish
2015-05-22 14:37:01 +01:00
Tom Castleman b161a38e9b Add licenses.reassignable migration
Implement licenses.reassignable

View edit for licenses.reassignable

Add licenses.reassignable to LicensesController

Disable Check In when !license->reassignable

Validate license check-in post
2015-05-22 14:11:36 +01:00
snipe 735268034d Merge pull request #809 from tomcastleman/patch-1
Removed debugbar:publish
2015-05-21 18:56:49 -07:00
snipe aad473486f Merge pull request #798 from DanielNemanic/patch-8
Generating Asset Name to Label Print
2015-05-21 18:56:36 -07:00
Tom Castleman 08970f2b7b Removed debugbar:publish
As per:
```
NOTICE: Since laravel-debugbar 1.7.x, publishing assets is no longer necessary. The assets in public/packages/barryvdh/laravel-debugbar and maximebf/php-debugbar can be safely removed.
```
2015-05-21 16:59:20 +01:00
Daniel Nemanic 6e8ad5b085 Generating Asset Name to Label Print
Added the Asset Name to the Label printing page.
2015-05-13 10:51:06 +02:00
snipe 145d386ce2 Updated lock file 2015-05-12 15:13:18 -07:00
snipe 94bfab762b Merge pull request #791 from DanielNemanic/patch-7
Updating Dashboard Link URL
2015-05-07 00:39:53 -07:00
Daniel Nemanic 20d8ad29e5 Updating Dashboard Link URL
Updating link to real application URL.
2015-05-07 09:38:16 +02:00
snipe bbdbd5397c Check for valid asset before attempting to get name 2015-05-04 00:46:26 -07:00
44 changed files with 1446 additions and 447 deletions
+2
View File
@@ -22,3 +22,5 @@ public/uploads/logo.gif
public/uploads/logo.png
.siteflow
public/assets/.siteflow
app/config/local/session.php
.couscous
+4 -2
View File
@@ -1,4 +1,4 @@
## Contributor Code of Conduct
# Contributor Code of Conduct
As contributors and maintainers of this project, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
@@ -8,6 +8,8 @@ Examples of unacceptable behavior by participants include the use of sexual lang
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. Project maintainers who do not follow the Code of Conduct may be removed from the project team.
This code of conduct applies both within project spaces and in public spaces when an individual is representing the project or its community.
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers.
This Code of Conduct is adapted from the [Contributor Covenant](http:contributor-covenant.org), version 1.0.0, available at [http://contributor-covenant.org/version/1/0/0/](http://contributor-covenant.org/version/1/0/0/)
This Code of Conduct is adapted from the [Contributor Covenant](http://contributor-covenant.org), version 1.1.0, available at [http://contributor-covenant.org/version/1/1/0/](http://contributor-covenant.org/version/1/1/0/)
+5 -4
View File
@@ -31,7 +31,7 @@ class AppCommand extends Command
'email' => null,
'password' => null
);
protected $dummyData = true;
/**
@@ -103,7 +103,7 @@ class AppCommand extends Command
$this->call('db:seed', array('--force'=>true));
}
else
{
{
// Seeding Settings table is mandatory
$this->call('db:seed', array('--class' => 'SettingsSeeder', '--force'=>true));
// Seeding Statuslabels is strongly recommended
@@ -207,7 +207,7 @@ class AppCommand extends Command
$this->userData['password'] = $password;
} while( ! $password);
}
/**
* Asks the user to create dummy data
*
@@ -350,7 +350,8 @@ class AppCommand extends Command
'first_name' => 'John',
'last_name' => 'Doe',
'email' => 'john.doe@example.com',
'password' => 'johndoe',
'password' => substr(str_shuffle(str_repeat('0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ', mt_rand(1,10))),1,10),
'notes' => 'Generated on install',
'activated' => 1,
'manager_id' => 1,
);
+364
View File
@@ -0,0 +1,364 @@
<?php
use Illuminate\Console\Command;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\InputArgument;
use League\Csv\Reader;
class ImportCommand extends Command {
/**
* The console command name.
*
* @var string
*/
protected $name = 'import:csv';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Import from CSV';
/**
* Create a new command instance.
*
* @return void
*/
public function __construct()
{
parent::__construct();
}
/**
* Execute the console command.
*
* @return mixed
*/
public function fire()
{
$filename = $this->argument('filename');
if (!$this->option('testrun')=='true') {
$this->comment('======= Importing '.$filename.' =========');
} else {
$this->comment('====== TEST ONLY Import for '.$filename.' ====');
$this->comment('============== NO DATA WILL BE WRITTEN ==============');
}
if (! ini_get("auto_detect_line_endings")) {
ini_set("auto_detect_line_endings", '1');
}
$csv = Reader::createFromPath($this->argument('filename'));
$csv->setNewline("\r\n");
$csv->setOffset(1);
$duplicates = '';
// Loop through the records
$nbInsert = $csv->each(function ($row) use ($duplicates) {
$status_id = 1;
// Let's just map some of these entries to more user friendly words
if (array_key_exists('0',$row)) {
$user_name = $row[0];
} else {
$user_name = '';
}
if (array_key_exists('1',$row)) {
$user_email = $row[1];
} else {
$user_email = '';
}
if (array_key_exists('2',$row)) {
$user_asset_category = $row[2];
} else {
$user_asset_category = '';
}
if (array_key_exists('3',$row)) {
$user_asset_name = $row[3];
} else {
$user_asset_name = '';
}
if (array_key_exists('4',$row)) {
$user_asset_mfgr = $row[4];
} else {
$user_asset_mfgr = '';
}
if (array_key_exists('5',$row)) {
$user_asset_modelno = $row[5];
} else {
$user_asset_modelno = '';
}
if (array_key_exists('6',$row)) {
$user_asset_serial = $row[6];
} else {
$user_asset_serial = '';
}
if (array_key_exists('7',$row)) {
$user_asset_tag = $row[7];
} else {
$user_asset_tag = '';
}
if (array_key_exists('8',$row)) {
$user_asset_location = $row[8];
} else {
$user_asset_location = '';
}
if (array_key_exists('9',$row)) {
$user_asset_notes = $row[9];
} else {
$user_asset_notes = '';
}
if (array_key_exists('9',$row)) {
$user_asset_purchase_date = date("Y-m-d 00:00:01", strtotime($row[10]));
} else {
$user_asset_purchase_date = '';
}
// A number was given instead of a name
if (is_numeric($user_name)) {
$this->comment('User '.$user_name.' is not a name - assume this user already exists');
// No name was given
} elseif ($user_name=='') {
$this->comment('No user data provided - skipping user creation, just adding asset');
$first_name = '';
$last_name = '';
} else {
$name = explode(" ", $user_name);
$first_name = $name[0];
$email_last_name = '';
if (!array_key_exists(1, $name)) {
$last_name='';
$email_last_name = $last_name;
$email_prefix = $first_name;
} else {
$last_name = str_replace($first_name,'',$user_name);
if ($this->option('email_format')=='filastname') {
$email_last_name.=str_replace(' ','',$last_name);
$email_prefix = $first_name[0].$email_last_name;
} elseif ($this->option('email_format')=='firstname.lastname') {
$email_last_name.=str_replace(' ','',$last_name);
$email_prefix = $first_name.'.'.$email_last_name;
} elseif ($this->option('email_format')=='firstname') {
$email_last_name.=str_replace(' ','',$last_name);
$email_prefix = $first_name;
}
}
// Generate an email based on their name if no email address is given
if ($user_email=='') {
if ($first_name=='Unknown') {
$status_id = 7;
}
$email = strtolower($email_prefix).'@'.$this->option('domain');
$user_email = str_replace("'",'',$email);
}
}
$this->comment('Full Name: '.$user_name);
$this->comment('First Name: '.$first_name);
$this->comment('Last Name: '.$last_name);
$this->comment('Email: '.$user_email);
$this->comment('Category Name: '.$user_asset_category);
$this->comment('Item: '.$user_asset_name);
$this->comment('Manufacturer ID: '.$user_asset_mfgr);
$this->comment('Model No: '.$user_asset_modelno);
$this->comment('Serial No: '.$user_asset_serial);
$this->comment('Asset Tag: '.$user_asset_tag);
$this->comment('Location: '.$user_asset_location);
$this->comment('Purchase Date: '.$user_asset_purchase_date);
$this->comment('Notes: '.$user_asset_notes);
$this->comment('------------- Action Summary ----------------');
if ($user_email!='') {
if ($user = User::where('email', $user_email)->first()) {
$this->comment('User '.$user_email.' already exists');
} else {
// Create the user
$user = Sentry::createUser(array(
'first_name' => $first_name,
'last_name' => $last_name,
'email' => $user_email,
'password' => substr(str_shuffle("0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"), 0, 10),
'activated' => true,
'permissions' => array(
'admin' => 0,
'user' => 1,
),
'notes' => 'Imported user'
));
// Find the group using the group id
$userGroup = Sentry::findGroupById(3);
// Assign the group to the user
$user->addGroup($userGroup);
$this->comment('User '.$first_name.' created');
}
} else {
$user = new User;
}
// Check for the location match and create it if it doesn't exist
if ($location = Location::where('name', $user_asset_location)->first()) {
$this->comment('Location '.$user_asset_location.' already exists');
} else {
$location = new Location();
$location->name = e($user_asset_location);
$location->address = '';
$location->city = '';
$location->state = '';
$location->country = '';
$location->user_id = 1;
if (!$this->option('testrun')=='true') {
if ($location->save()) {
$this->comment('Location '.$user_asset_location.' was created');
} else {
$this->comment('Something went wrong! Location '.$user_asset_location.' was NOT created');
}
} else {
$this->comment('Location '.$user_asset_location.' was (not) created - test run only');
}
}
// Check for the category match and create it if it doesn't exist
if ($category = Category::where('name', $user_asset_category)->where('category_type', 'asset')->first()) {
$this->comment('Category '.$user_asset_category.' already exists');
} else {
$category = new Category();
$category->name = e($user_asset_category);
$category->category_type = 'asset';
$category->user_id = 1;
if ($category->save()) {
$this->comment('Category '.$user_asset_category.' was created');
} else {
$this->comment('Something went wrong! Category '.$user_asset_category.' was NOT created');
}
}
// Check for the manufacturer match and create it if it doesn't exist
if ($manufacturer = Manufacturer::where('name', $user_asset_mfgr)->first()) {
$this->comment('Manufacturer '.$user_asset_mfgr.' already exists');
} else {
$manufacturer = new Manufacturer();
$manufacturer->name = e($user_asset_mfgr);
$manufacturer->user_id = 1;
if ($manufacturer->save()) {
$this->comment('Manufacturer '.$user_asset_mfgr.' was created');
} else {
$this->comment('Something went wrong! Manufacturer '.$user_asset_mfgr.' was NOT created');
}
}
// Check for the asset model match and create it if it doesn't exist
if ($asset_model = Model::where('name', $user_asset_name)->where('modelno', $user_asset_modelno)->where('category_id', $category->id)->where('manufacturer_id', $manufacturer->id)->first()) {
$this->comment('The Asset Model '.$user_asset_name.' with model number '.$user_asset_modelno.' already exists');
} else {
$asset_model = new Model();
$asset_model->name = e($user_asset_name);
$asset_model->manufacturer_id = $manufacturer->id;
$asset_model->modelno = e($user_asset_modelno);
$asset_model->category_id = $category->id;
$asset_model->user_id = 1;
if ($asset_model->save()) {
$this->comment('Asset Model '.$user_asset_name.' with model number '.$user_asset_modelno.' was created');
} else {
$this->comment('Something went wrong! Asset Model '.$user_asset_name.' was NOT created');
}
}
// Check for the asset match and create it if it doesn't exist
$asset = new Asset();
$asset->name = e($user_asset_name);
$asset->serial = e($user_asset_serial);
$asset->asset_tag = e($user_asset_tag);
$asset->model_id = $asset_model->id;
$asset->assigned_to = $user->id;
$asset->rtd_location_id = $location->id;
$asset->user_id = 1;
$asset->status_id = $status_id;
$asset->purchase_date = $user_asset_purchase_date;
$asset->notes = e($user_asset_notes);
if ($asset->save()) {
$this->comment('Asset '.$user_asset_name.' with serial number '.$user_asset_serial.' was created');
} else {
$this->comment('Something went wrong! Asset '.$user_asset_name.' was NOT created');
}
$this->comment('=====================================');
return true;
});
}
/**
* Get the console command arguments.
*
* @return array
*/
protected function getArguments()
{
return array(
array('filename', InputArgument::REQUIRED, 'File for the CSV import.'),
);
}
/**
* Get the console command options.
*
* @return array
*/
protected function getOptions()
{
return array(
array('domain', null, InputOption::VALUE_REQUIRED, 'Email domain for generated email addresses.', null),
array('email_format', null, InputOption::VALUE_REQUIRED, 'The format of the email addresses that should be generated. Options are firstname.lastname, firstname, filastname', null),
array('testrun', null, InputOption::VALUE_REQUIRED, 'Test the output without writing to the database or not.', null),
);
}
}
+140
View File
@@ -0,0 +1,140 @@
<?php
return array(
/*
|--------------------------------------------------------------------------
| Default Session Driver
|--------------------------------------------------------------------------
|
| This option controls the default session "driver" that will be used on
| requests. By default, we will use the lightweight native driver but
| you may specify any of the other wonderful drivers provided here.
|
| Supported: "file", "cookie", "database", "apc",
| "memcached", "redis", "array"
|
*/
'driver' => 'file',
/*
|--------------------------------------------------------------------------
| Session Lifetime
|--------------------------------------------------------------------------
|
| Here you may specify the number of minutes that you wish the session
| to be allowed to remain idle before it expires. If you want them
| to immediately expire on the browser closing, set that option.
|
*/
'lifetime' => 12000,
'expire_on_close' => false,
/*
|--------------------------------------------------------------------------
| Session File Location
|--------------------------------------------------------------------------
|
| When using the native session driver, we need a location where session
| files may be stored. A default has been set for you but a different
| location may be specified. This is only needed for file sessions.
|
*/
'files' => storage_path().'/sessions',
/*
|--------------------------------------------------------------------------
| Session Database Connection
|--------------------------------------------------------------------------
|
| When using the "database" or "redis" session drivers, you may specify a
| connection that should be used to manage these sessions. This should
| correspond to a connection in your database configuration options.
|
*/
'connection' => null,
/*
|--------------------------------------------------------------------------
| Session Database Table
|--------------------------------------------------------------------------
|
| When using the "database" session driver, you may specify the table we
| should use to manage the sessions. Of course, a sensible default is
| provided for you; however, you are free to change this as needed.
|
*/
'table' => 'sessions',
/*
|--------------------------------------------------------------------------
| Session Sweeping Lottery
|--------------------------------------------------------------------------
|
| Some session drivers must manually sweep their storage location to get
| rid of old sessions from storage. Here are the chances that it will
| happen on a given request. By default, the odds are 2 out of 100.
|
*/
'lottery' => array(2, 100),
/*
|--------------------------------------------------------------------------
| Session Cookie Name
|--------------------------------------------------------------------------
|
| Here you may change the name of the cookie used to identify a session
| instance by ID. The name specified here will get used every time a
| new session cookie is created by the framework for every driver.
|
*/
'cookie' => 'snipeit_session',
/*
|--------------------------------------------------------------------------
| Session Cookie Path
|--------------------------------------------------------------------------
|
| The session cookie path determines the path for which the cookie will
| be regarded as available. Typically, this will be the root path of
| your application but you are free to change this when necessary.
|
*/
'path' => '/',
/*
|--------------------------------------------------------------------------
| Session Cookie Domain
|--------------------------------------------------------------------------
|
| Here you may change the domain of the cookie used to identify a session
| in your application. This will determine which domains the cookie is
| available to in your application. A sensible default has been set.
|
*/
'domain' => null,
/*
|--------------------------------------------------------------------------
| HTTPS Only Cookies
|--------------------------------------------------------------------------
|
| By setting this option to true, session cookies will only be sent back
| to the server if the browser has a HTTPS connection. This will keep
| the cookie from being sent to you if it can not be done securely.
|
*/
'secure' => false,
);
+154
View File
@@ -0,0 +1,154 @@
<?php
return array(
/*
|--------------------------------------------------------------------------
| Default Session Driver
|--------------------------------------------------------------------------
|
| This option controls the default session "driver" that will be used on
| requests. By default, we will use the lightweight native driver but
| you may specify any of the other wonderful drivers provided here.
|
| Supported: "file", "cookie", "database", "apc",
| "memcached", "redis", "array"
|
*/
'driver' => 'file',
/*
|--------------------------------------------------------------------------
| Session Lifetime
|--------------------------------------------------------------------------
|
| Here you may specify the number of minutes that you wish the session
| to be allowed to remain idle before it expires. If you want them
| to immediately expire on the browser closing, set that option.
|
*/
'lifetime' => 12000,
'expire_on_close' => false,
/*
|--------------------------------------------------------------------------
| Session File Location
|--------------------------------------------------------------------------
|
| When using the native session driver, we need a location where session
| files may be stored. A default has been set for you but a different
| location may be specified. This is only needed for file sessions.
|
*/
'files' => storage_path().'/sessions',
/*
|--------------------------------------------------------------------------
| Session Database Connection
|--------------------------------------------------------------------------
|
| When using the "database" or "redis" session drivers, you may specify a
| connection that should be used to manage these sessions. This should
| correspond to a connection in your database configuration options.
|
*/
'connection' => null,
/*
|--------------------------------------------------------------------------
| Session Database Table
|--------------------------------------------------------------------------
|
| When using the "database" session driver, you may specify the table we
| should use to manage the sessions. Of course, a sensible default is
| provided for you; however, you are free to change this as needed.
|
*/
'table' => 'sessions',
/*
|--------------------------------------------------------------------------
| Session Sweeping Lottery
|--------------------------------------------------------------------------
|
| Some session drivers must manually sweep their storage location to get
| rid of old sessions from storage. Here are the chances that it will
| happen on a given request. By default, the odds are 2 out of 100.
|
*/
'lottery' => array(2, 100),
/*
|--------------------------------------------------------------------------
| Session Cookie Name
|--------------------------------------------------------------------------
|
| Here you may change the name of the cookie used to identify a session
| instance by ID. The name specified here will get used every time a
| new session cookie is created by the framework for every driver.
|
*/
'cookie' => 'snipeit_session',
/*
|--------------------------------------------------------------------------
| Session Cookie Path
|--------------------------------------------------------------------------
|
| The session cookie path determines the path for which the cookie will
| be regarded as available. Typically, this will be the root path of
| your application but you are free to change this when necessary.
|
*/
'path' => '/',
/*
|--------------------------------------------------------------------------
| Session Cookie Domain
|--------------------------------------------------------------------------
|
| Here you may change the domain of the cookie used to identify a session
| in your application. This will determine which domains the cookie is
| available to in your application. A sensible default has been set.
|
*/
'domain' => null,
/*
|--------------------------------------------------------------------------
| HTTPS Only Cookies
|--------------------------------------------------------------------------
|
| By setting this option to true, session cookies will only be sent back
| to the server if the browser has a HTTPS connection. This will keep
| the cookie from being sent to you if it can not be done securely.
|
*/
'secure' => false,
/*
|--------------------------------------------------------------------------
| Allow multiple logins from different devices at the same time
|--------------------------------------------------------------------------
|
| By default, if a user logs into an account where someone is already
| logged in, the previous user will be logged out. We recommend leaving
| this set to false for security reasons.
|
*/
'multi_login' => false,
);
+154
View File
@@ -0,0 +1,154 @@
<?php
return array(
/*
|--------------------------------------------------------------------------
| Default Session Driver
|--------------------------------------------------------------------------
|
| This option controls the default session "driver" that will be used on
| requests. By default, we will use the lightweight native driver but
| you may specify any of the other wonderful drivers provided here.
|
| Supported: "file", "cookie", "database", "apc",
| "memcached", "redis", "array"
|
*/
'driver' => 'file',
/*
|--------------------------------------------------------------------------
| Session Lifetime
|--------------------------------------------------------------------------
|
| Here you may specify the number of minutes that you wish the session
| to be allowed to remain idle before it expires. If you want them
| to immediately expire on the browser closing, set that option.
|
*/
'lifetime' => 12000,
'expire_on_close' => false,
/*
|--------------------------------------------------------------------------
| Session File Location
|--------------------------------------------------------------------------
|
| When using the native session driver, we need a location where session
| files may be stored. A default has been set for you but a different
| location may be specified. This is only needed for file sessions.
|
*/
'files' => storage_path().'/sessions',
/*
|--------------------------------------------------------------------------
| Session Database Connection
|--------------------------------------------------------------------------
|
| When using the "database" or "redis" session drivers, you may specify a
| connection that should be used to manage these sessions. This should
| correspond to a connection in your database configuration options.
|
*/
'connection' => null,
/*
|--------------------------------------------------------------------------
| Session Database Table
|--------------------------------------------------------------------------
|
| When using the "database" session driver, you may specify the table we
| should use to manage the sessions. Of course, a sensible default is
| provided for you; however, you are free to change this as needed.
|
*/
'table' => 'sessions',
/*
|--------------------------------------------------------------------------
| Session Sweeping Lottery
|--------------------------------------------------------------------------
|
| Some session drivers must manually sweep their storage location to get
| rid of old sessions from storage. Here are the chances that it will
| happen on a given request. By default, the odds are 2 out of 100.
|
*/
'lottery' => array(2, 100),
/*
|--------------------------------------------------------------------------
| Session Cookie Name
|--------------------------------------------------------------------------
|
| Here you may change the name of the cookie used to identify a session
| instance by ID. The name specified here will get used every time a
| new session cookie is created by the framework for every driver.
|
*/
'cookie' => 'snipeit_session',
/*
|--------------------------------------------------------------------------
| Session Cookie Path
|--------------------------------------------------------------------------
|
| The session cookie path determines the path for which the cookie will
| be regarded as available. Typically, this will be the root path of
| your application but you are free to change this when necessary.
|
*/
'path' => '/',
/*
|--------------------------------------------------------------------------
| Session Cookie Domain
|--------------------------------------------------------------------------
|
| Here you may change the domain of the cookie used to identify a session
| in your application. This will determine which domains the cookie is
| available to in your application. A sensible default has been set.
|
*/
'domain' => null,
/*
|--------------------------------------------------------------------------
| HTTPS Only Cookies
|--------------------------------------------------------------------------
|
| By setting this option to true, session cookies will only be sent back
| to the server if the browser has a HTTPS connection. This will keep
| the cookie from being sent to you if it can not be done securely.
|
*/
'secure' => true,
/*
|--------------------------------------------------------------------------
| Allow multiple logins from different devices at the same time
|--------------------------------------------------------------------------
|
| By default, if a user logs into an account where someone is already
| logged in, the previous user will be logged out. We recommend leaving
| this set to false for security reasons.
|
*/
'multi_login' => true,
);
+2 -2
View File
@@ -1,5 +1,5 @@
<?php
return array (
'app_version' => 'v1.2.7-beta',
'hash_version' => 'v1.2.7-beta-10-g48ccf84',
'app_version' => 'v1.2.8-26',
'hash_version' => 'v1.2.8-26-gf5d4eb5',
);
+117 -91
View File
@@ -54,9 +54,14 @@ class AssetsController extends AdminController
public function getCreate($model_id = null)
{
/*
// Grab the dropdown list of models
//$model_list = array('' => 'Select a Model') + Model::orderBy('name', 'asc')->lists('name'.' '. 'modelno', 'id');
$model_list = Model::select(DB::raw('concat(manufacturers.name," ",name) as name, id'))->orderBy('name', 'asc')->with('manufacturer')->lists('name', 'id');
//$model_list = array('' => Lang::get('general.select_model'));
*/
$model_list = array('' => Lang::get('general.select_model')) + DB::table('models')
->select(DB::raw('concat(name," / ",modelno) as name, id'))->orderBy('name', 'asc')
->orderBy('modelno', 'asc')
@@ -70,7 +75,7 @@ class AssetsController extends AdminController
// Grab the dropdown list of status
$statuslabel_list = Statuslabel::orderBy('name', 'asc')->lists('name', 'id');
$statuslabel_list = array('' => Lang::get('general.select_statuslabel')) + Statuslabel::orderBy('name', 'asc')->lists('name', 'id');
$view = View::make('backend/hardware/edit');
$view->with('supplier_list',$supplier_list);
@@ -156,7 +161,7 @@ class AssetsController extends AdminController
} else {
$asset->rtd_location_id = e(Input::get('rtd_location_id'));
}
$checkModel = Config::get('app.url').'/api/models/'.e(Input::get('model_id')).'/check';
$asset->mac_address = ($checkModel == true) ? e(Input::get('mac_address')) : NULL;
@@ -293,7 +298,7 @@ class AssetsController extends AdminController
} else {
$asset->rtd_location_id = e(Input::get('rtd_location_id'));
}
$checkModel = Config::get('app.url').'/api/models/'.e(Input::get('model_id')).'/check';
$asset->mac_address = ($checkModel == true) ? e(Input::get('mac_address')) : NULL;
@@ -441,20 +446,20 @@ class AssetsController extends AdminController
$data['first_name'] = $user->first_name;
$data['item_name'] = $asset->showAssetName();
$data['require_acceptance'] = $asset->requireAcceptance();
$settings = Setting::getSettings();
if ($settings->slack_endpoint) {
$slack_settings = [
'username' => $settings->botname,
'channel' => $settings->slack_channel,
'link_names' => true
];
$client = new \Maknz\Slack\Client($settings->slack_endpoint,$slack_settings);
try {
$client->attach([
'color' => 'good',
@@ -468,13 +473,13 @@ class AssetsController extends AdminController
'value' => e($logaction->note)
],
]
])->send('Asset Checked Out');
} catch (Exception $e) {
}
}
@@ -563,18 +568,18 @@ class AssetsController extends AdminController
$log = $logaction->logaction('checkin from');
$settings = Setting::getSettings();
if ($settings->slack_endpoint) {
$slack_settings = [
'username' => $settings->botname,
'channel' => $settings->slack_channel,
'link_names' => true
];
$client = new \Maknz\Slack\Client($settings->slack_endpoint,$slack_settings);
try {
$client->attach([
'color' => 'good',
@@ -587,16 +592,16 @@ class AssetsController extends AdminController
'title' => 'Note:',
'value' => e($logaction->note)
],
]
])->send('Asset Checked In');
} catch (Exception $e) {
}
}
if ($backto=='user') {
return Redirect::to("admin/users/".$return_to.'/view')->with('success', Lang::get('admin/hardware/message.checkin.success'));
} else {
@@ -703,6 +708,9 @@ class AssetsController extends AdminController
$asset = clone $asset_to_clone;
$asset->id = null;
$asset->asset_tag = '';
$asset->serial = '';
$asset->assigned_to = '';
$asset->mac_address = '';
return View::make('backend/hardware/edit')->with('supplier_list',$supplier_list)->with('model_list',$model_list)->with('statuslabel_list',$statuslabel_list)->with('assigned_to',$assigned_to)->with('asset',$asset)->with('location_list',$location_list);
}
@@ -752,7 +760,7 @@ class AssetsController extends AdminController
foreach(Input::file('assetfile') as $file) {
$rules = array(
'assetfile' => 'required|mimes:png,gif,jpg,jpeg,doc,docx,pdf,txt|max:2000'
'assetfile' => 'required|mimes:png,gif,jpg,jpeg,doc,docx,pdf,txt,zip,rar|max:2000'
);
$validator = Validator::make(array('assetfile'=> $file), $rules);
@@ -872,51 +880,51 @@ class AssetsController extends AdminController
**/
public function postBulkEdit($assets = null)
{
if (!Input::has('edit_asset')) {
return Redirect::back()->with('error', 'No assets selected');
} else {
$asset_raw_array = Input::get('edit_asset');
$asset_raw_array = Input::get('edit_asset');
foreach ($asset_raw_array as $asset_id => $value) {
$asset_ids[] = $asset_id;
$asset_ids[] = $asset_id;
}
}
if (Input::has('bulk_actions')) {
// Create labels
if (Input::get('bulk_actions')=='labels') {
$assets = Asset::find($asset_ids);
$assetcount = count($assets);
$count = 0;
$settings = Setting::getSettings();
$settings = Setting::getSettings();
return View::make('backend/hardware/labels')->with('assets',$assets)->with('settings',$settings)->with('count',$count);
// Bulk edit
// Bulk edit
} elseif (Input::get('bulk_actions')=='edit') {
$assets = Input::get('edit_asset');
$supplier_list = array('' => '') + Supplier::orderBy('name', 'asc')->lists('name', 'id');
$statuslabel_list = array('' => '') + Statuslabel::lists('name', 'id');
$location_list = array('' => '') + Location::lists('name', 'id');
return View::make('backend/hardware/bulk')->with('assets',$assets)->with('supplier_list',$supplier_list)->with('statuslabel_list',$statuslabel_list)->with('location_list',$location_list);
}
} else {
return Redirect::back()->with('error', 'No action selected');
return Redirect::back()->with('error', 'No action selected');
}
}
@@ -990,8 +998,8 @@ class AssetsController extends AdminController
public function getDatatable($status = null)
{
$assets = Asset::with('model','assigneduser','assigneduser.userloc','assetstatus','defaultLoc','assetlog','model','model.category')->Hardware()->select(array('id', 'name','model_id','assigned_to','asset_tag','serial','status_id','purchase_date','deleted_at'));
$assets = Asset::with('model','assigneduser','assigneduser.userloc','assetstatus','defaultLoc','assetlog','model','model.category')->Hardware()->select(array('id', 'name','model_id','assigned_to','asset_tag','serial','status_id','purchase_date','deleted_at','rtd_location_id','notes','order_number'));
switch ($status) {
case 'Pending':
@@ -1015,95 +1023,113 @@ class AssetsController extends AdminController
case 'Deleted':
$assets->withTrashed()->Deleted();
break;
}
}
$assets = $assets->orderBy('asset_tag', 'ASC')->get();
$actions = new \Chumper\Datatable\Columns\FunctionColumn('actions', function ($assets)
{
$actions = new \Chumper\Datatable\Columns\FunctionColumn('actions', function ($assets)
{
if ($assets->deleted_at=='') {
return '<a href="'.route('update/hardware', $assets->id).'" class="btn btn-warning btn-sm"><i class="fa fa-pencil icon-white"></i></a> <a data-html="false" class="btn delete-asset btn-danger btn-sm" data-toggle="modal" href="'.route('delete/hardware', $assets->id).'" data-content="'.Lang::get('admin/hardware/message.delete.confirm').'" data-title="'.Lang::get('general.delete').' '.htmlspecialchars($assets->asset_tag).'?" onClick="return false;"><i class="fa fa-trash icon-white"></i></a>';
} elseif ($assets->model->deleted_at=='') {
return '<a href="'.route('restore/hardware', $assets->id).'" class="btn btn-warning btn-sm"><i class="fa fa-recycle icon-white"></i></a>';
}
});
$inout = new \Chumper\Datatable\Columns\FunctionColumn('inout', function ($assets)
{
if (($assets->assigned_to !='') && ($assets->assigned_to > 0)) {
return '<a href="'.route('checkin/hardware', $assets->id).'" class="btn btn-primary btn-sm">'.Lang::get('general.checkin').'</a>';
} else {
return '<a href="'.route('checkout/hardware', $assets->id).'" class="btn btn-info btn-sm">'.Lang::get('general.checkout').'</a>';
}
});
$inout = new \Chumper\Datatable\Columns\FunctionColumn('inout', function ($assets)
{
if ($assets->assetstatus->deployable != 0) {
if (($assets->assigned_to !='') && ($assets->assigned_to > 0)) {
return '<a href="'.route('checkin/hardware', $assets->id).'" class="btn btn-primary btn-sm">'.Lang::get('general.checkin').'</a>';
} else {
return '<a href="'.route('checkout/hardware', $assets->id).'" class="btn btn-info btn-sm">'.Lang::get('general.checkout').'</a>';
}
}
});
return Datatable::collection($assets)
->addColumn('',function($assets)
{
return '<input type="checkbox" name="edit_asset['.$assets->id.']" class="one_required">';
{
return '<input type="checkbox" name="edit_asset['.$assets->id.']" class="one_required">';
})
->addColumn('name',function($assets)
{
return '<a title="'.$assets->name.'" href="hardware/'.$assets->id.'/view">'.$assets->name.'</a>';
})
})
->addColumn('asset_tag',function($assets)
{
return '<a title="'.$assets->asset_tag.'" href="hardware/'.$assets->id.'/view">'.$assets->asset_tag.'</a>';
})
})
->showColumns('serial')
->addColumn('model',function($assets)
{
return $assets->model->name;
if ($assets->model) {
return $assets->model->name;
} else {
return 'No model';
}
})
->addColumn('status',function($assets)
{
{
if ($assets->assigned_to!='') {
return link_to('../admin/users/'.$assets->assigned_to.'/view', $assets->assigneduser->fullName());
} else {
return $assets->assetstatus->name;
return $assets->assetstatus->name;
}
})
->addColumn('location',function($assets)
{
if ($assets->assigned_to && $assets->assigneduser->userloc) {
return link_to('admin/location/'.$assets->assigneduser->userloc->id.'/edit', $assets->assigneduser->userloc->name);
if ($assets->assigned_to && ($assets->assigneduser->userloc!='')) {
return link_to('admin/settings/locations/'.$assets->assigneduser->userloc->id.'/edit', $assets->assigneduser->userloc->name);
} elseif ($assets->defaultLoc){
return link_to('admin/location/'.$assets->defaultLoc->id.'/edit', $assets->defaultLoc->name);
return link_to('admin/settings/locations/'.$assets->defaultLoc->id.'/edit', $assets->defaultLoc->name);
}
})
->addColumn('category',function($assets)
{
return $assets->model->category->name;
if (isset($assets->model->category)) {
return $assets->model->category->name;
} else {
return 'No category';
}
})
})
->addColumn('eol',function($assets)
{
return $assets->eol_date();
})
})
->addColumn('notes',function($assets)
{
return $assets->notes;
})
->addColumn('order_number',function($assets)
{
return $assets->order_number;
})
->addColumn('checkout_date',function($assets)
{
{
if (($assets->assigned_to!='') && ($assets->assetlog->first())) {
return $assets->assetlog->first()->created_at->format('Y-m-d');
}
})
->addColumn($inout)
->addColumn($actions)
->searchColumns('name', 'asset_tag', 'serial', 'model', 'status','location','eol','checkout_date', 'inout','category')
->orderColumns('name', 'asset_tag', 'serial', 'model', 'status','location','eol','checkout_date', 'inout')
}
})
->addColumn($inout)
->addColumn($actions)
->searchColumns('name', 'asset_tag', 'serial', 'model', 'status','location','eol','checkout_date', 'inout','category','notes','order_number')
->orderColumns('name', 'asset_tag', 'serial', 'model', 'status','location','eol','checkout_date', 'inout','notes','order_number')
->make();
}
}
+19 -13
View File
@@ -161,21 +161,27 @@ class GroupsController extends AdminController
return Redirect::back()->withInput()->withErrors($validator);
}
try {
// Update the group data
$group->name = Input::get('name');
$group->permissions = Input::get('permissions');
if (!Config::get('app.lock_passwords')) {
// Was the group updated?
if ($group->save()) {
// Redirect to the group page
return Redirect::route('update/group', $id)->with('success', Lang::get('admin/groups/message.success.update'));
} else {
// Redirect to the group page
return Redirect::route('update/group', $id)->with('error', Lang::get('admin/groups/message.error.update'));
try {
// Update the group data
$group->name = Input::get('name');
$group->permissions = Input::get('permissions');
// Was the group updated?
if ($group->save()) {
// Redirect to the group page
return Redirect::route('update/group', $id)->with('success', Lang::get('admin/groups/message.success.update'));
} else {
// Redirect to the group page
return Redirect::route('update/group', $id)->with('error', Lang::get('admin/groups/message.error.update'));
}
} catch (NameRequiredException $e) {
$error = Lang::get('admin/group/message.group_name_required');
}
} catch (NameRequiredException $e) {
$error = Lang::get('admin/group/message.group_name_required');
} else {
return Redirect::route('update/group', $id)->withInput()->with('error', 'Denied! Editing groups is not allowed in the demo.');
}
// Redirect to the group page
@@ -22,6 +22,7 @@ use Response;
use Datatable;
use Slack;
use Config;
use Session;
class LicensesController extends AdminController
{
@@ -229,6 +230,7 @@ class LicensesController extends AdminController
$license->depreciation_id = e(Input::get('depreciation_id'));
$license->purchase_order = e(Input::get('purchase_order'));
$license->maintained = e(Input::get('maintained'));
$license->reassignable = e(Input::get('reassignable'));
if ( e(Input::get('supplier_id')) == '') {
$license->supplier_id = NULL;
@@ -269,6 +271,12 @@ class LicensesController extends AdminController
$license->maintained = e(Input::get('maintained'));
}
if ( e(Input::get('reassignable')) == '') {
$license->reassignable = 0;
} else {
$license->reassignable = e(Input::get('reassignable'));
}
if ( e(Input::get('purchase_order')) == '') {
$license->purchase_order = '';
} else {
@@ -607,6 +615,12 @@ class LicensesController extends AdminController
$license = License::find($licenseseat->license_id);
if(!$license->reassignable) {
// Not allowed to checkin
Session::flash('error', 'License not reassignable.');
return Redirect::back()->withInput();
}
// Declare the rules for the form validation
$rules = array(
'note' => 'alpha_space',
+11 -7
View File
@@ -236,7 +236,7 @@ class ModelsController extends AdminController
return Redirect::to('hardware/models')->with('success', Lang::get('admin/models/message.delete.success'));
}
}
public function getRestore($modelId = null)
{
@@ -308,7 +308,7 @@ class ModelsController extends AdminController
return $view;
}
public function getDatatable($status = null)
{
$models = Model::orderBy('created_at', 'DESC')->with('category','assets','depreciation');
@@ -324,6 +324,9 @@ class ModelsController extends AdminController
});
return Datatable::collection($models)
->addColumn('manufacturer', function($models) {
return $models->manufacturer->name;
})
->addColumn('name', function ($models) {
return link_to('/hardware/models/'.$models->id.'/view', $models->name);
})
@@ -345,15 +348,15 @@ class ModelsController extends AdminController
->orderColumns('name','modelno','asset_count','depreciation','category','eol','actions')
->make();
}
public function getDataView($modelID)
{
$model = Model::withTrashed()->find($modelID);
$modelassets = $model->assets;
$actions = new \Chumper\Datatable\Columns\FunctionColumn('actions', function ($modelassets)
{
$actions = new \Chumper\Datatable\Columns\FunctionColumn('actions', function ($modelassets)
{
if (($modelassets->assigned_to !='') && ($modelassets->assigned_to > 0)) {
return '<a href="'.route('checkin/hardware', $modelassets->id).'" class="btn btn-primary btn-sm">'.Lang::get('general.checkin').'</a>';
} else {
@@ -363,7 +366,8 @@ class ModelsController extends AdminController
return Datatable::collection($modelassets)
->addColumn('name', function ($modelassets) {
return link_to('/hardware/'.$modelassets->id.'/view', $modelassets->name);
return link_to('/hardware/'.$modelassets->id.'/view', $modelassets->showAssetName());
// return $modelassets->name;
})
->addColumn('asset_tag', function ($modelassets) {
return link_to('/hardware/'.$modelassets->id.'/view', $modelassets->asset_tag);
+9 -7
View File
@@ -64,7 +64,7 @@ class SettingsController extends AdminController
// Declare the rules for the form validation
$rules = array(
"per_page" => 'required|min:1|numeric',
"qr_text" => 'min:1|max:31',
@@ -74,12 +74,12 @@ class SettingsController extends AdminController
"slack_channel" => 'regex:/(?<!\w)#\w+/',
"slack_botname" => 'alpha_dash',
);
if (Config::get('app.lock_passwords')==false) {
$rules['site_name'] = 'required|min:3';
}
}
// Create a new validator instance from our validation rules
$validator = Validator::make(Input::all(), $rules);
@@ -93,6 +93,7 @@ class SettingsController extends AdminController
if (Input::get('clear_logo')=='1') {
$setting->logo = NULL;
} elseif (Input::file('logo')) {
if (!Config::get('app.lock_passwords')) {
$image = Input::file('logo');
$file_name = "logo.".$image->getClientOriginalExtension();
$path = public_path('uploads/'.$file_name);
@@ -101,16 +102,17 @@ class SettingsController extends AdminController
$constraint->upsize();
})->save($path);
$setting->logo = $file_name;
}
}
// Update the asset data
$setting->id = '1';
if (Config::get('app.lock_passwords')==false) {
$setting->site_name = e(Input::get('site_name'));
}
}
$setting->per_page = e(Input::get('per_page'));
$setting->qr_code = e(Input::get('qr_code', '0'));
$setting->barcode_type = e(Input::get('barcode_type'));
+93 -88
View File
@@ -47,7 +47,7 @@ class UsersController extends AdminController
*/
public function getIndex()
{
// Show the page
return View::make('backend/users/index');
}
@@ -144,22 +144,22 @@ class UsersController extends AdminController
// Redirect to the new user page
//return Redirect::route('update/user', $user->id)->with('success', $success);
if (Input::get('email_user')==1) {
// Send the credentials through email
$data = array();
$data['email'] = e(Input::get('email'));
$data['first_name'] = e(Input::get('first_name'));
$data['password'] = e(Input::get('password'));
Mail::send('emails.send-login', $data, function ($m) use ($user) {
$m->to($user->email, $user->first_name . ' ' . $user->last_name);
$m->subject('Welcome ' . $user->first_name);
});
}
return Redirect::route('users')->with('success', $success);
}
@@ -245,6 +245,11 @@ class UsersController extends AdminController
$this->decodePermissions($permissions);
app('request')->request->set('permissions', $permissions);
// Only update the email address if locking is set to false
if (Config::get('app.lock_passwords')) {
return Redirect::route('users')->with('error', 'Denied! You cannot update user information on the demo.');
}
try {
// Get the user information
$user = Sentry::getUserProvider()->findById($id);
@@ -276,16 +281,11 @@ class UsersController extends AdminController
// Ooops.. something went wrong
return Redirect::back()->withInput()->withErrors($validator);
}
// Only update the email address if locking is set to false
if (!Config::get('app.lock_passwords')) {
$user->email = Input::get('email');
}
try {
// Update the user
$user->first_name = Input::get('first_name');
$user->last_name = Input::get('last_name');
$user->last_name = Input::get('last_name');
$user->employee_num = Input::get('employee_num');
$user->activated = Input::get('activated', $user->activated);
$user->permissions = Input::get('permissions');
@@ -309,6 +309,11 @@ class UsersController extends AdminController
$user->password = $password;
}
// Do we want to update the user email?
if (!Config::get('app.lock_passwords')) {
$user->email = Input::get('email');
}
// Get the current user groups
$userGroups = $user->groups()->lists('group_id', 'group_id');
@@ -325,14 +330,13 @@ class UsersController extends AdminController
// Assign the user to groups
foreach ($groupsToAdd as $groupId) {
$group = Sentry::getGroupProvider()->findById($groupId);
$user->addGroup($group);
}
// Remove the user from groups
foreach ($groupsToRemove as $groupId) {
$group = Sentry::getGroupProvider()->findById($groupId);
$user->removeGroup($group);
}
}
@@ -466,7 +470,7 @@ class UsersController extends AdminController
}
/**
* Unsuspend the given user.
*
@@ -568,7 +572,7 @@ class UsersController extends AdminController
return Redirect::route('users')->with('error', $error);
}
}
/**
* User import.
*
@@ -589,8 +593,8 @@ class UsersController extends AdminController
// Show the page
return View::make('backend/users/import', compact('groups', 'selectedGroups', 'permissions', 'selectedPermissions'));
}
/**
* User import form processing.
*
@@ -598,96 +602,97 @@ class UsersController extends AdminController
*/
public function postImport()
{
if (! ini_get("auto_detect_line_endings")) {
ini_set("auto_detect_line_endings", '1');
}
$csv = Reader::createFromPath(Input::file('user_import_csv'));
$csv = Reader::createFromPath(Input::file('user_import_csv'));
$csv->setNewline("\r\n");
if (Input::get('has_headers')==1) {
$csv->setOffset(1);
$csv->setOffset(1);
}
$duplicates = '';
$duplicates = '';
$nbInsert = $csv->each(function ($row) use ($duplicates) {
if (array_key_exists(2, $row)) {
if (Input::get('activate')==1) {
$activated = '1';
$activated = '1';
} else {
$activated = '0';
$activated = '0';
}
$pass = substr(str_shuffle("0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"), 0, 10);
try {
try {
// Check if this email already exists in the system
$user = DB::table('users')->where('email', $row[2])->first();
if ($user) {
if ($user) {
$duplicates .= $row[2].', ';
} else {
$newuser = array(
'first_name' => $row[0],
'last_name' => $row[1],
'email' => $row[2],
'password' => $pass,
'activated' => $activated,
'permissions' => '{"user":1}'
'permissions' => '{"user":1}',
'notes' => 'Imported user'
);
DB::table('users')->insert($newuser);
$udpateuser = Sentry::findUserByLogin($row[2]);
$updateuser = Sentry::findUserByLogin($row[2]);
// Update the user details
$udpateuser->password = $pass;
$updateuser->password = $pass;
// Update the user
$udpateuser->save();
$updateuser->save();
if (Input::get('email_user')==1) {
// Send the credentials through email
$data = array();
$data['email'] = $row[2];
$data['first_name'] = $row[0];
$data['password'] = $pass;
Mail::send('emails.send-login', $data, function ($m) use ($newuser) {
$m->to($newuser['email'], $newuser['first_name'] . ' ' . $newuser['last_name']);
$m->subject('Welcome ' . $newuser['first_name']);
});
}
}
} catch (Exception $e) {
echo 'Caught exception: ', $e->getMessage(), "\n";
}
return true;
}
});
});
return Redirect::route('users')->with('duplicates',$duplicates)->with('success', 'Success');
}
public function getDatatable($status = null)
{
$users = User::with('assets','licenses','manager','sentryThrottle');
switch ($status) {
case 'deleted':
$users->GetDeleted();
@@ -695,24 +700,24 @@ class UsersController extends AdminController
case '':
$users->GetNotDeleted();
break;
}
$users = $users->orderBy('created_at', 'DESC')->get();
$actions = new \Chumper\Datatable\Columns\FunctionColumn('actions', function ($users)
{
}
$users = $users->orderBy('created_at', 'DESC')->get();
$actions = new \Chumper\Datatable\Columns\FunctionColumn('actions', function ($users)
{
$action_buttons = '';
if ( ! is_null($users->deleted_at)) {
$action_buttons .= '<a href="'.route('restore/user', $users->id).'" class="btn btn-warning btn-sm"><i class="fa fa-share icon-white"></i></a> ';
} else {
if ($users->accountStatus()=='suspended') {
$action_buttons .= '<a href="'.route('unsuspend/user', $users->id).'" class="btn btn-warning btn-sm"><span class="fa fa-time icon-white"></span></a> ';
}
$action_buttons .= '<a href="'.route('update/user', $users->id).'" class="btn btn-warning btn-sm"><i class="fa fa-pencil icon-white"></i></a> ';
if ((Sentry::getId() !== $users->id) && (!Config::get('app.lock_passwords'))) {
$action_buttons .= '<a data-html="false" class="btn delete-asset btn-danger btn-sm" data-toggle="modal" href="'.route('delete/user', $users->id).'" data-content="Are you sure you wish to delete this user?" data-title="Delete '.htmlspecialchars($users->first_name).'?" onClick="return false;"><i class="fa fa-trash icon-white"></i></a> ';
} else {
@@ -720,51 +725,51 @@ class UsersController extends AdminController
}
}
return $action_buttons;
});
return Datatable::collection($users)
->addColumn('name',function($users)
{
return '<a title="'.$users->fullName().'" href="users/'.$users->id.'/view">'.$users->fullName().'</a>';
})
})
->addColumn('email',function($users)
{
return '<a title="'.$users->email.'" href="mailto:'.$users->email.'">'.$users->email.'</a>';
})
->addColumn('manager',function($users)
{
if ($users->manager) {
return '<a title="'.$users->manager->fullName().'" href="users/'.$users->manager->id.'/view">'.$users->manager->fullName().'</a>';
}
}
})
->addColumn('assets',function($users)
{
return $users->assets->count();
})
->addColumn('licenses',function($users)
{
return $users->licenses->count();
})
})
->addColumn('activated',function($users)
{
return $users->isActivated() ? '<i class="fa fa-check"></i>' : '';
})
->addColumn($actions)
})
->addColumn($actions)
->searchColumns('name','email','manager','activated', 'licenses','assets')
->orderColumns('name','email','manager','activated', 'licenses','assets')
->make();
}
}
}
@@ -0,0 +1,35 @@
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddReassignableToLicenses extends Migration {
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('licenses', function(Blueprint $table)
{
$table->boolean('reassignable')->default(true);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('licenses', function(Blueprint $table)
{
//
$table->dropColumn('reassignable');
});
}
}
+2 -2
View File
@@ -5,7 +5,7 @@ return array(
'about_accessories_text' => 'Accessories are anything you issue to users but that do not have a serial number (or you do not care about tracking them uniquely). For example, computer mice or keyboards.',
'accessory_category' => 'Accessory Category',
'accessory_name' => 'Accessory Name',
'create' => 'Create Category',
'create' => 'Create Accessory',
'eula_text' => 'Category EULA',
'eula_text_help' => 'This field allows you to customize your EULAs for specific types of assets. If you only have one EULA for all of your assets, you can check the box below to use the primary default.',
'require_acceptance' => 'Require users to confirm acceptance of assets in this category.',
@@ -13,7 +13,7 @@ return array(
'qty' => 'QTY',
'total' => 'Total',
'remaining' => 'Avail',
'update' => 'Update Category',
'update' => 'Update Accessory',
'use_default_eula' => 'Use the <a href="#" data-toggle="modal" data-target="#eulaModal">primary default EULA</a> instead.',
'use_default_eula_disabled' => '<del>Use the primary default EULA instead.</del> No primary default EULA is set. Please add one in Settings.',
+1 -1
View File
@@ -19,7 +19,7 @@ return array(
'eol_rate' => 'EOL Rate',
'expires' => 'Expires',
'fully_depreciated' => 'Fully Depreciated',
'help_checkout' => 'If you wish to assign this asset immediately, you should select "Ready to Deploy" from the status list above, or unexpected things may happen. ',
'help_checkout' => 'If you wish to assign this asset immediately, select "Ready to Deploy" from the status list above. ',
'mac_address' => 'MAC Address',
'manufacturer' => 'Manufacturer',
'model' => 'Model',
+1
View File
@@ -9,6 +9,7 @@ return array(
'deployable' => 'Deployable',
'deleted' => 'This asset has been deleted. <a href="/hardware/:asset_id/restore">Click here to restore it</a>.',
'edit' => 'Edit Asset',
'filetype_info' => 'Allowed filetypes are png, gif, jpg, doc, docx, pdf, txt, rar and zip.',
'model_deleted' => 'This Assets model has been deleted. You must restore the model before you can restore the Asset.<br/> <a href="/hardware/models/:model_id/restore">Click here to restore the model</a>.',
'requestable' => 'Requestable',
'restore' => 'Restore Asset',
+1
View File
@@ -10,6 +10,7 @@ return array(
'depreciation' => 'Depreciation',
'expiration' => 'Expiration Date',
'maintained' => 'Maintained',
'reassignable' => 'Reassignable',
'name' => 'Software Name',
'no_depreciation' => 'Do Not Depreciate',
'notes' => 'Notes',
+1
View File
@@ -7,6 +7,7 @@ return array(
'checkout' => 'Checkout License Seat',
'edit' => 'Edit License',
'clone' => 'Clone License',
'filetype_info' => 'Allowed filetypes are png, gif, jpg, doc, docx, pdf, txt, rar and zip.',
'history_for' => 'History for ',
'in_out' => 'In/Out',
'info' => 'License Info',
+4 -2
View File
@@ -21,8 +21,8 @@ return array(
'avatar_upload' => 'Upload Avatar',
'back' => 'Back',
'cancel' => 'Cancel',
'categories' => 'Asset Categories',
'category' => 'Asset Category',
'categories' => 'Asset/Accessory Categories',
'category' => 'Category',
'changeemail' => 'Change Email Address',
'changepassword' => 'Change Password',
'checkin' => 'Checkin',
@@ -66,6 +66,7 @@ return array(
'licenses' => 'Licenses',
'list_all' => 'List All',
'loading' => 'Loading',
'lock_passwords' => 'This field cannot be edited in this installation.',
'location' => 'Location',
'locations' => 'Locations',
'logout' => 'Logout',
@@ -101,6 +102,7 @@ return array(
'select_supplier' => 'Select a Supplier',
'select_user' => 'Select a User',
'select_date' => 'Select Date',
'select_statuslabel' => 'Select Status',
'settings' => 'Settings',
'sign_in' => 'Sign in',
'site_name' => 'Site Name',
+14 -10
View File
@@ -10,6 +10,7 @@ class Asset extends Depreciable
protected $rules = array(
'name' => 'alpha_space|min:2|max:255',
'model_id' => 'required',
'status_id' => 'required',
'warranty_months' => 'integer|min:0|max:240',
'note' => 'alpha_space',
'notes' => 'alpha_space',
@@ -58,11 +59,11 @@ class Asset extends Depreciable
/**
* Get the asset's location based on the assigned user
* Get the asset's location based on default RTD location
**/
public function defaultLoc()
{
return $this->hasOne('Location', 'id', 'rtd_location_id');
return $this->belongsTo('Location', 'rtd_location_id');
}
@@ -119,9 +120,9 @@ class Asset extends Depreciable
{
return $this->belongsTo('Statuslabel','status_id');
}
/**
* Get name for EULA
/**
* Get name for EULA
**/
public function showAssetName()
{
@@ -131,7 +132,7 @@ class Asset extends Depreciable
return $this->name;
}
}
public function warrantee_expires()
{
$date = date_create($this->purchase_date);
@@ -175,7 +176,7 @@ class Asset extends Depreciable
{
return $this->belongsTo('Supplier','supplier_id');
}
public function months_until_eol()
{
@@ -194,9 +195,12 @@ class Asset extends Depreciable
public function eol_date()
{
$date = date_create($this->purchase_date);
date_add($date, date_interval_create_from_date_string($this->model->eol.' months'));
return date_format($date, 'Y-m-d');
if (($this->purchase_date) && ($this->model)) {
$date = date_create($this->purchase_date);
date_add($date, date_interval_create_from_date_string($this->model->eol.' months'));
return date_format($date, 'Y-m-d');
}
}
+5 -5
View File
@@ -40,13 +40,13 @@ class Model extends Elegant
{
return $this->belongsTo('Manufacturer','manufacturer_id');
}
/**
-----------------------------------------------
BEGIN QUERY SCOPES
-----------------------------------------------
* -----------------------------------------------
* BEGIN QUERY SCOPES
* -----------------------------------------------
**/
/**
* Query builder scope for Deleted assets
*
+31 -12
View File
@@ -23,7 +23,7 @@ class User extends SentryUserModel
{
return "{$this->first_name} {$this->last_name}";
}
/**
* Returns the user Gravatar image url.
@@ -43,7 +43,7 @@ class User extends SentryUserModel
{
return $this->hasMany('Asset', 'assigned_to')->withTrashed();
}
public function accessories()
{
return $this->belongsToMany('Accessory', 'accessories_users', 'assigned_to','accessory_id')->withPivot('id')->withTrashed();
@@ -77,36 +77,55 @@ class User extends SentryUserModel
{
return $this->belongsTo('User','manager_id')->withTrashed();
}
public function accountStatus()
{
if ($this->sentryThrottle) {
if ($this->sentryThrottle->suspended==1) {
return 'suspended';
return 'suspended';
} elseif ($this->sentryThrottle->banned==1) {
return 'banned';
} else {
return 'banned';
} else {
return false;
}
} else {
return false;
}
}
public function sentryThrottle() {
return $this->hasOne('Throttle');
public function sentryThrottle() {
return $this->hasOne('Throttle');
}
public function scopeGetDeleted($query)
{
return $query->withTrashed()->whereNotNull('deleted_at');
}
public function scopeGetNotDeleted($query)
{
return $query->whereNull('deleted_at');
}
/**
* Override the SentryUser getPersistCode method for
* multiple logins at one time
**/
public function getPersistCode()
{
if (!Config::get('session.multi_login') || (!$this->persist_code))
{
$this->persist_code = $this->getRandomString();
// Our code got hashed
$persistCode = $this->persist_code;
$this->save();
return $persistCode;
}
return $this->persist_code;
}
}
+15 -7
View File
@@ -10,6 +10,17 @@ Route::group(array('prefix' => 'api', 'namespace' => 'Controllers\Admin', 'befor
Route::resource('/', 'AssetsController');
Route::get('list/{status?}', array('as'=>'api.hardware.list', 'uses'=>'AssetsController@getDatatable'));
});
/*---Status Label API---*/
Route::group(array('prefix'=>'statuslabels'), function() {
Route::get('{statuslabelId}/deployable', function ($statuslabelId) {
$statuslabel = Statuslabel::find($statuslabelId);
if (($statuslabel->deployable=='1') && ($statuslabel->pending!='1') && ($statuslabel->archived!='1')) {
return $statuslabel->deployable;
}
});
});
/*---Accessories API---*/
Route::group(array('prefix'=>'accessories'), function () {
Route::resource('/', 'AccessoriesController');
@@ -29,7 +40,7 @@ Route::group(array('prefix' => 'api', 'namespace' => 'Controllers\Admin', 'befor
/*---Models API---*/
Route::group(array('prefix'=>'models'), function() {
Route::resource('/', 'ModelsController');
Route::get('list/{status?}', array('as'=>'api.models.list', 'uses'=>'ModelsController@getDatatable'));
Route::get('list/{status?}', array('as'=>'api.models.list', 'uses'=>'ModelsController@getDatatable'));
Route::get('{modelId}/check', function ($modelId) {
$model = Model::find($modelId);
return $model->show_mac_address;
@@ -255,7 +266,7 @@ Route::group(array('prefix' => 'admin', 'before' => 'admin-auth', 'namespace' =>
# User Management
Route::group(array('prefix' => 'users'), function () {
Route::get('create', array('as' => 'create/user', 'uses' => 'UsersController@getCreate'));
Route::post('create', 'UsersController@postCreate');
Route::get('import', array('as' => 'import/user', 'uses' => 'UsersController@getImport'));
@@ -269,7 +280,7 @@ Route::group(array('prefix' => 'admin', 'before' => 'admin-auth', 'namespace' =>
Route::get('{userId}/view', array('as' => 'view/user', 'uses' => 'UsersController@getView'));
Route::get('{userId}/unsuspend', array('as' => 'unsuspend/user', 'uses' => 'UsersController@getUnsuspend'));
Route::get('/', array('as' => 'users', 'uses' => 'UsersController@getIndex'));
});
# Group Management
@@ -387,13 +398,10 @@ Route::group(array('before' => 'reporting-auth', 'namespace' => 'Controllers\Adm
Route::get('reports/custom', array('as' => 'reports/custom', 'uses' => 'ReportsController@getCustomReport'));
Route::post('reports/custom', 'ReportsController@postCustom');
Route::get('reports/activity', array('as' => 'reports/activity', 'uses' => 'ReportsController@getActivityReport'));
});
Route::get('/', array('as' => 'home', 'before' => 'admin-auth', 'uses' => 'Controllers\Admin\DashboardController@getIndex'));
+1
View File
@@ -14,3 +14,4 @@
Artisan::add(new AppCommand);
Artisan::add(new SendExpirationAlerts);
Artisan::add(new Versioning);
Artisan::add(new ImportCommand);
+3 -3
View File
@@ -48,11 +48,11 @@
<td>{{{ $activity->adminlog->fullName() }}}</td>
<td>
@if ($activity->asset_type=="hardware")
@if (($activity->assetlog) && ($activity->asset_type=="hardware"))
{{ $activity->assetlog->showAssetName() }}
@elseif ($activity->asset_type=="software")
@elseif (($activity->licenselog) && ($activity->asset_type=="software"))
{{ $activity->licenselog->name }}
@elseif ($activity->asset_type=="accessory")
@elseif (($activity->asset_type) && ($activity->asset_type=="accessory"))
{{ $activity->accessorylog->name }}
@endif
+40 -18
View File
@@ -154,11 +154,24 @@
<div class="form-group {{ $errors->has('status_id') ? ' has-error' : '' }}">
<label for="status_id" class="col-md-2 control-label">@lang('admin/hardware/form.status') <i class='fa fa-asterisk'></i></label>
<div class="col-md-7">
{{ Form::select('status_id', $statuslabel_list , Input::old('status_id', $asset->status_id), array('class'=>'select2', 'style'=>'width:350px')) }}
{{ Form::select('status_id', $statuslabel_list , Input::old('status_id', $asset->status_id), array('class'=>'select2 status_id', 'style'=>'width:350px')) }}
<p class="help-block">@lang('admin/hardware/form.help_checkout')</p>
{{ $errors->first('status_id', '<br><span class="alert-msg"><i class="fa fa-times"></i> :message</span>') }}
</div>
</div>
@if (!$asset->id)
<!-- Assigned To -->
<div id="assigned_to" style="display: none;" class="form-group {{ $errors->has('assigned_to') ? ' has-error' : '' }}">
<label for="parent" class="col-md-2 control-label">@lang('admin/hardware/form.checkout_to')
</label>
<div class="col-md-7">
{{ Form::select('assigned_to', $assigned_to , Input::old('assigned_to', $asset->assigned_to), array('class'=>'select2', 'style'=>'min-width:350px')) }}
{{ $errors->first('assigned_to', '<br><span class="alert-msg"><i class="fa fa-times"></i> :message</span>') }}
</div>
</div>
@endif
<!-- Notes -->
<div class="form-group {{ $errors->has('notes') ? ' has-error' : '' }}">
<label for="notes" class="col-md-2 control-label">@lang('admin/hardware/form.notes')</label>
@@ -169,28 +182,14 @@
</div>
<!-- Default Location -->
<div class="form-group {{ $errors->has('status_id') ? ' has-error' : '' }}">
<label for="status_id" class="col-md-2 control-label">@lang('admin/hardware/form.default_location')</label>
<div class="form-group {{ $errors->has('rtd_location_id') ? ' has-error' : '' }}">
<label for="rtd_location_id" class="col-md-2 control-label">@lang('admin/hardware/form.default_location')</label>
<div class="col-md-7">
{{ Form::select('rtd_location_id', $location_list , Input::old('rtd_location_id', $asset->rtd_location_id), array('class'=>'select2', 'style'=>'width:350px')) }}
{{ $errors->first('status_id', '<br><span class="alert-msg"><i class="fa fa-times"></i> :message</span>') }}
{{ $errors->first('rtd_location_id', '<br><span class="alert-msg"><i class="fa fa-times"></i> :message</span>') }}
</div>
</div>
@if (!$asset->id)
<!-- Assigned To -->
<div class="form-group {{ $errors->has('assigned_to') ? ' has-error' : '' }}">
<label for="parent" class="col-md-2 control-label">@lang('admin/hardware/form.checkout_to')
</label>
<div class="col-md-7">
{{ Form::select('assigned_to', $assigned_to , Input::old('assigned_to', $asset->assigned_to), array('class'=>'select2', 'style'=>'min-width:350px')) }}
<p class="help-block">@lang('admin/hardware/form.help_checkout')</p>
{{ $errors->first('assigned_to', '<br><span class="alert-msg"><i class="fa fa-times"></i> :message</span>') }}
</div>
</div>
@endif
<!-- Requestable -->
<div class="form-group">
<div class="col-sm-offset-2 col-sm-10">
@@ -237,6 +236,29 @@
}
});
};
var $eventSelect = $(".status_id");
$eventSelect.on("change", function () { user_add($eventSelect.val()); });
$(function() {
var deployable = $(".status_id option:selected").val();
if(deployable!=''){
user_add(deployable);
}
});
function user_add(id) {
$.ajax({
url: "{{Config::get('app.url')}}/api/statuslabels/"+id+"/deployable",
success: function(data) {
if(data == true){
$("#assigned_to").css("display", "block");
} else {
$("#assigned_to").css("display", "none");
}
}
});
};
</script>
@stop
+16 -14
View File
@@ -1,7 +1,7 @@
@extends('backend/layouts/default')
@section('title0')
@if (Input::get('status'))
@if (Input::get('status')=='Pending')
@lang('general.pending')
@@ -57,16 +57,18 @@
{{ Datatable::table()
->addColumn('<input type="checkbox" id="checkAll" style="padding-left: 0px;">',Lang::get('admin/hardware/form.name'),
Lang::get('admin/hardware/table.asset_tag'),
->addColumn('<div class="text-center"><input type="checkbox" id="checkAll" style="padding-left: 0px;"></div>',Lang::get('admin/hardware/form.name'),
Lang::get('admin/hardware/table.asset_tag'),
Lang::get('admin/hardware/table.serial'),
Lang::get('admin/hardware/form.model'),
Lang::get('admin/hardware/table.status'),
Lang::get('admin/hardware/table.location'),
Lang::get('general.category'),
Lang::get('admin/hardware/table.eol'),
Lang::get('admin/hardware/table.checkout_date'),
Lang::get('admin/hardware/table.change'),
Lang::get('general.notes'),
Lang::get('admin/hardware/form.order'),
Lang::get('admin/hardware/table.checkout_date'),
Lang::get('admin/hardware/table.change'),
Lang::get('table.actions'))
->setOptions(
array(
@@ -75,8 +77,8 @@
'lengthMenu' => Lang::get('general.page_menu'),
'loadingRecords' => Lang::get('general.loading'),
'zeroRecords' => Lang::get('general.no_results'),
'info' => Lang::get('general.pagination_info'),
'processing' => Lang::get('general.processing'),
'info' => Lang::get('general.pagination_info'),
'processing' => '<i class="fa fa-spinner fa-spin"></i> '.Lang::get('general.processing'),
'paginate'=> array(
'first'=>Lang::get('general.first'),
'previous'=>Lang::get('general.previous'),
@@ -84,10 +86,10 @@
'last'=>Lang::get('general.last'),
),
),
'sAjaxSource'=> route('api.hardware.list', Input::get('status')),
'sAjaxSource'=> route('api.hardware.list', array(''=>Input::get('status'),'order_number'=>Input::get('order_number'))),
'dom' =>'CT<"clear">lfrtip',
'colVis'=> array('showAll'=>'Show All','restore'=>'Restore','exclude'=>array(0,10,11),'activate'=>'mouseover'),
'columnDefs'=> array(array('visible'=>false,'targets'=>array(7,8,9)),array('orderable'=>false,'targets'=>array(0,10,11))),
'colVis'=> array('showAll'=>'Show All','restore'=>'Restore','exclude'=>array(0,12,13),'activate'=>'mouseover'),
'columnDefs'=> array(array('visible'=>false,'targets'=>array(7,8,9)),array('orderable'=>false,'targets'=>array(0,12,13))),
'order'=>array(array(1,'asc')),
)
)
@@ -112,17 +114,17 @@
$('#bulkEdit').attr('disabled', 'disabled');
}
}
$('table').on('change','input.one_required',checkForChecked);
$("#checkAll").change(function () {
$("input:checkbox").prop('checked', $(this).prop("checked"));
checkForChecked();
});
});
</script>
+4 -1
View File
@@ -52,7 +52,10 @@
{{ $settings->qr_text }}
<br><br>
@endif
@if ($asset->name!='')
<b>N: {{ $asset->name }}</b>
<br>
@endif
@if ($asset->asset_tag!='')
T: {{ $asset->asset_tag }}
<br>
+11 -11
View File
@@ -124,7 +124,7 @@
<div class="col-md-12" style="padding-bottom: 5px;"><strong>@lang('admin/hardware/form.fully_depreciated'): </strong>
@if ($asset->time_until_depreciated()->y > 0)
{{{ $asset->time_until_depreciated()->y }}}
@lang('admin/hardware/form.years'),
@lang('admin/hardware/form.years'),
@endif
{{{ $asset->time_until_depreciated()->m }}}
@lang('admin/hardware/form.months')
@@ -192,8 +192,8 @@
</div>
</div>
@endif
<div class="col-md-12">
@@ -262,7 +262,7 @@
<tbody>
@if (count($asset->assetlog) > 0)
@foreach ($asset->assetlog as $log)
<tr>
<td>{{{ $log->created_at }}}</td>
<td>
@@ -289,7 +289,7 @@
@endif
</td>
</tr>
@endforeach
@endif
<tr>
@@ -333,8 +333,8 @@
</li>
</ul>
@endif
@if (($asset->assigneduser) && ($asset->assigned_to > 0) && ($asset->deleted_at==''))
<h6><br>@lang('admin/hardware/form.checkedout_to')</h6>
<ul>
@@ -373,14 +373,14 @@
@if ($asset->assetstatus)
<h6><br>
@if (($asset->assetstatus->deployable=='1') && ($asset->assigned_to > 0))
@lang('admin/hardware/general.asset')
@lang('admin/hardware/general.asset')
@lang('general.deployed')
@else
{{{ $asset->assetstatus->name }}}
{{{ $asset->assetstatus->name }}}
@lang('admin/hardware/general.asset')
@endif
<ul>
@if (($asset->assetstatus->deployable=='1') && ($asset->assigned_to > 0) && ($asset->deleted_at==''))
<li><br /><a href="{{ route('checkin/hardware', $asset->id) }}" class="btn btn-primary btn-sm">@lang('admin/hardware/general.checkin')</a></li>
@elseif ((($asset->assetstatus->deployable=='1') && (($asset->assigned_to=='') || ($asset->assigned_to==0))) && ($asset->deleted_at==''))
@@ -423,7 +423,7 @@
'files' => true, 'class' => 'form-horizontal' ]) }}
<div class="modal-body">
<p>Allowed filetypes are png, gif, jpg, doc, docx, pdf, and txt.</p>
<p><p>@lang('admin/hardware/general.filetype_info')</p>.</p>
<div class="form-group col-md-12">
<div class="input-group col-md-12">
+2 -2
View File
@@ -43,7 +43,7 @@
<!-- open sans font -->
<link href='http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css'>
<link href='//fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css'>
<!-- global header javascripts -->
<script src="{{ asset('assets/js/jquery-latest.js') }}"></script>
@@ -249,7 +249,7 @@
<ul id="dashboard-menu">
@if(Sentry::getUser()->hasAccess('admin'))
<li{{ (Request::is('*/') ? ' class="active"><div class="pointer"><div class="arrow"></div><div class="arrow_border"></div></div>' : '>') }}
<a href="/"><i class="fa fa-dashboard"></i><span>Dashboard</span></a>
<a href="{{ Config::get('app.url') }}"><i class="fa fa-dashboard"></i><span>Dashboard</span></a>
</li>
<li{{ (Request::is('hardware*') ? ' class="active"><div class="pointer"><div class="arrow"></div><div class="arrow_border"></div></div>' : '>') }}
<a href="{{ URL::to('hardware') }}" class="dropdown-toggle">
@@ -84,6 +84,15 @@
</div>
</div>
<!-- Reassignable -->
<div class="form-group {{ $errors->has('reassignable') ? ' has-error' : '' }}">
<label for="reassignable" class="col-md-3 control-label">@lang('admin/licenses/form.reassignable')</label>
<div class="col-md-7 input-group">
{{ Form::Checkbox('reassignable', '1', Input::old('reassignable', $license->id ? $license->reassignable : '1')) }}
@lang('general.yes')
</div>
</div>
<!-- Supplier -->
<div class="form-group {{ $errors->has('supplier_id') ? ' has-error' : '' }}">
<label for="supplier_id" class="col-md-3 control-label">@lang('admin/licenses/form.supplier')</label>
+14 -5
View File
@@ -3,7 +3,7 @@
{{-- Page title --}}
@section('title')
@lang('admin/licenses/general.view')
{{{ $license->name }}} ::
- {{{ $license->name }}}
@parent
@stop
@@ -80,7 +80,7 @@
<strong>@lang('admin/hardware/form.fully_depreciated'): </strong>
@if ($license->time_until_depreciated()->y > 0)
{{{ $license->time_until_depreciated()->y }}}
@lang('admin/hardware/form.years'),
@lang('admin/hardware/form.years'),
@endif
{{{ $license->time_until_depreciated()->m }}}
@lang('admin/hardware/form.months')
@@ -134,8 +134,13 @@
</td>
<td>
@if (($licensedto->assigned_to) || ($licensedto->asset_id))
<a href="{{ route('checkin/license', $licensedto->id) }}" class="btn btn-primary btn-sm">
@lang('general.checkin')</a>
@if ($license->reassignable)
<a href="{{ route('checkin/license', $licensedto->id) }}" class="btn btn-primary btn-sm">
@lang('general.checkin')
</a>
@else
<span>Assigned</span>
@endif
@else
<a href="{{ route('checkout/license', $licensedto->id) }}" class="btn btn-info btn-sm">
@lang('general.checkout')</a>
@@ -216,7 +221,7 @@
'files' => true, 'class' => 'form-horizontal' ]) }}
<div class="modal-body">
<p>Allowed filetypes are png, gif, jpg, doc, docx, pdf, and txt.</p>
<p>@lang('admin/licenses/general.filetype_info')</p>
<div class="form-group col-md-12">
<div class="input-group col-md-12">
@@ -333,6 +338,10 @@
{{{ $license->seats }}} </li>
@endif
<li><strong>@lang('admin/licenses/form.reassignable'):</strong>
{{ $license->reassignable ? 'Yes' : 'No' }}
</li>
@if ($license->notes)
<li><strong>@lang('admin/licenses/form.notes'):</strong>
<li class="break-word">{{ nl2br(e($license->notes)) }}</li>
+4 -3
View File
@@ -23,12 +23,13 @@
<div class="row form-wrapper">
{{ Datatable::table()
->addColumn(Lang::get('admin/models/table.title'),
->addColumn(Lang::get('general.manufacturer'),
Lang::get('admin/models/table.title'),
Lang::get('admin/models/table.modelnumber'),
Lang::get('admin/models/table.numassets'),
Lang::get('general.depreciation'),
Lang::get('general.category'),
Lang::get('general.eol'),
Lang::get('general.eol'),
Lang::get('table.actions'))
->setOptions(
array(
@@ -37,7 +38,7 @@
'lengthMenu' => Lang::get('general.page_menu'),
'loadingRecords' => Lang::get('general.loading'),
'zeroRecords' => Lang::get('general.no_results'),
'info' => Lang::get('general.pagination_info'),
'info' => Lang::get('general.pagination_info'),
'processing' => Lang::get('general.processing'),
'paginate'=> array(
'first'=>Lang::get('general.first'),
+7 -7
View File
@@ -52,13 +52,13 @@
</td>
<td>
@if ($log_action->asset_type=="hardware")
{{ $log_action->assetlog->showAssetName() }}
@elseif ($log_action->asset_type=="software")
{{ $log_action->licenselog->name }}
@elseif ($log_action->asset_type=="accessory")
{{ $log_action->accessorylog->name }}
@endif
@if (($log_action->assetlog) && ($log_action->asset_type=="hardware"))
{{ $log_action->assetlog->showAssetName() }}
@elseif (($log_action->licenselog) && ($log_action->asset_type=="software"))
{{ $log_action->licenselog->name }}
@elseif (($log_action->asset_type) && ($log_action->asset_type=="accessory"))
{{ $log_action->accessorylog->name }}
@endif
</td>
+31 -25
View File
@@ -19,7 +19,7 @@ padding: 0px 20px;
</style>
<div id="pad-wrapper" class="user-profile">
<!-- header -->
<div class="pull-right">
@@ -31,9 +31,9 @@ padding: 0px 20px;
<div class="profile">
<!-- bio, new note & orders column -->
<div class="col-md-9 bio">
<div class="profile-box">
<br>
@@ -42,11 +42,11 @@ padding: 0px 20px;
<!-- CSRF Token -->
{{ Form::hidden('_token', csrf_token()) }}
@foreach ($settings as $setting)
<h4>@lang('admin/settings/general.general_settings')</h4>
<div class="form-group {{ $errors->has('site_name') ? 'error' : '' }}">
<div class="col-md-3">
{{ Form::label('site_name', Lang::get('admin/settings/general.site_name')) }}
@@ -54,11 +54,11 @@ padding: 0px 20px;
<div class="col-md-9">
@if (Config::get('app.lock_passwords')===true)
{{ Form::text('site_name', Input::old('site_name', $setting->site_name), array('class' => 'form-control', 'disabled'=>'disabled','placeholder' => 'Snipe-IT Asset Management')) }}
@else
@else
{{ Form::text('site_name', Input::old('site_name', $setting->site_name), array('class' => 'form-control','placeholder' => 'Snipe-IT Asset Management')) }}
@endif
{{ $errors->first('site_name', '<br><span class="alert-msg">:message</span>') }}
</div>
</div>
@@ -69,9 +69,15 @@ padding: 0px 20px;
{{ Form::label('logo', Lang::get('admin/settings/general.logo')) }}
</div>
<div class="col-md-9">
{{ Form::file('logo') }}
{{ $errors->first('logo', '<br><span class="alert-msg">:message</span>') }}
{{ Form::checkbox('clear_logo', '1', Input::old('clear_logo')) }} Remove
@if (Config::get('app.lock_passwords'))
<p class="help-block">@lang('general.lock_passwords')</p>
@else
{{ Form::file('logo') }}
{{ $errors->first('logo', '<br><span class="alert-msg">:message</span>') }}
{{ Form::checkbox('clear_logo', '1', Input::old('clear_logo')) }} Remove
@endif
</div>
</div>
@@ -115,7 +121,7 @@ padding: 0px 20px;
</div>
</div>
<div class="checkbox col-md-offset-3">
<label>
@@ -220,7 +226,7 @@ padding: 0px 20px;
</div>
<hr>
<h4>@lang('admin/settings/general.slack_integration') (@lang('admin/settings/general.optional'))</h4>
<p class="help-inline">@lang('admin/settings/general.slack_integration_help',array('slack_link' => 'https://my.slack.com/services/new/incoming-webhook'))</p>
@@ -229,17 +235,17 @@ padding: 0px 20px;
{{ Form::label('slack_endpoint', Lang::get('admin/settings/general.slack_endpoint')) }}
</div>
<div class="col-md-9">
@if (Config::get('app.lock_passwords')===true)
{{ Form::text('slack_endpoint', Input::old('slack_endpoint', $setting->slack_endpoint), array('class' => 'form-control','disabled'=>'disabled','placeholder' => 'https://hooks.slack.com/services/XXXXXXXXXXXXXXXXXXXXX')) }}
@else
@else
{{ Form::text('slack_endpoint', Input::old('slack_endpoint', $setting->slack_endpoint), array('class' => 'form-control','placeholder' => 'https://hooks.slack.com/services/XXXXXXXXXXXXXXXXXXXXX')) }}
@endif
{{ $errors->first('slack_endpoint', '<br><span class="alert-msg">:message</span>') }}
</div>
</div>
<div class="form-group {{ $errors->has('slack_channel') ? 'error' : '' }}">
<div class="col-md-3">
{{ Form::label('slack_channel', Lang::get('admin/settings/general.slack_channel')) }}
@@ -247,13 +253,13 @@ padding: 0px 20px;
<div class="col-md-9">
@if (Config::get('app.lock_passwords')===true)
{{ Form::text('slack_channel', Input::old('slack_channel', $setting->slack_channel), array('class' => 'form-control','disabled'=>'disabled','placeholder' => '#IT-Ops')) }}
@else
@else
{{ Form::text('slack_channel', Input::old('slack_channel', $setting->slack_channel), array('class' => 'form-control','placeholder' => '#IT-Ops')) }}
@endif
@endif
{{ $errors->first('slack_channel', '<br><span class="alert-msg">:message</span>') }}
</div>
</div>
<div class="form-group {{ $errors->has('slack_botname') ? 'error' : '' }}">
<div class="col-md-3">
{{ Form::label('slack_botname', Lang::get('admin/settings/general.slack_botname')) }}
@@ -261,9 +267,9 @@ padding: 0px 20px;
<div class="col-md-9">
@if (Config::get('app.lock_passwords')===true)
{{ Form::text('slack_botname', Input::old('slack_botname', $setting->slack_botname), array('class' => 'form-control','disabled'=>'disabled','placeholder' => 'Snipe-IT Bot')) }}
@else
@else
{{ Form::text('slack_botname', Input::old('slack_botname', $setting->slack_botname), array('class' => 'form-control','placeholder' => 'Snipe-IT Bot')) }}
@endif
@endif
{{ $errors->first('slack_botname', '<br><span class="alert-msg">:message</span>') }}
</div>
</div>
@@ -280,10 +286,10 @@ padding: 0px 20px;
<button type="submit" class="btn-flat success"><i class="fa fa-check icon-white"></i> @lang('general.save')</button>
</div>
</div>
</form>
</form>
</div>
</div>
<!-- side address column -->
+1 -1
View File
@@ -6,7 +6,7 @@
<title>Error 403 - Forbidden</title>
<meta name="viewport" content="width=device-width">
<style type="text/css">
@import url(http://fonts.googleapis.com/css?family=Droid+Sans);
@import url(//fonts.googleapis.com/css?family=Droid+Sans);
article, aside, details, figcaption, figure, footer, header, hgroup, nav, section { display: block; }
audio, canvas, video { display: inline-block; *display: inline; *zoom: 1; }
+1 -1
View File
@@ -6,7 +6,7 @@
<title>Error 404 - Not Found</title>
<meta name="viewport" content="width=device-width">
<style type="text/css">
@import url(http://fonts.googleapis.com/css?family=Droid+Sans);
@import url(//fonts.googleapis.com/css?family=Droid+Sans);
article, aside, details, figcaption, figure, footer, header, hgroup, nav, section { display: block; }
audio, canvas, video { display: inline-block; *display: inline; *zoom: 1; }
+1 -1
View File
@@ -6,7 +6,7 @@
<title>Error 500 - Internal Server Error</title>
<meta name="viewport" content="width=device-width">
<style type="text/css">
@import url(http://fonts.googleapis.com/css?family=Droid+Sans);
@import url(//fonts.googleapis.com/css?family=Droid+Sans);
article, aside, details, figcaption, figure, footer, header, hgroup, nav, section { display: block; }
audio, canvas, video { display: inline-block; *display: inline; *zoom: 1; }
+1 -1
View File
@@ -6,7 +6,7 @@
<title>Scheduled Maintenance</title>
<meta name="viewport" content="width=device-width">
<style type="text/css">
@import url(http://fonts.googleapis.com/css?family=Droid+Sans);
@import url(//fonts.googleapis.com/css?family=Droid+Sans);
article, aside, details, figcaption, figure, footer, header, hgroup, nav, section { display: block; }
audio, canvas, video { display: inline-block; *display: inline; *zoom: 1; }
+1 -3
View File
@@ -47,11 +47,9 @@
],
"post-update-cmd": [
"php artisan optimize",
"php artisan debugbar:publish"
"php artisan optimize"
],
"post-install-cmd": [
"php artisan debugbar:publish"
],
"post-create-project-cmd": [
"php artisan key:generate"
Generated
+96 -97
View File
@@ -420,12 +420,12 @@
"source": {
"type": "git",
"url": "https://github.com/doctrine/cache.git",
"reference": "9d141335b758cbff3c58b52777836ce945522a68"
"reference": "c2ab51e8f3c4a8170ca91b702e3789881dd2a6c2"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/doctrine/cache/zipball/9d141335b758cbff3c58b52777836ce945522a68",
"reference": "9d141335b758cbff3c58b52777836ce945522a68",
"url": "https://api.github.com/repos/doctrine/cache/zipball/c2ab51e8f3c4a8170ca91b702e3789881dd2a6c2",
"reference": "c2ab51e8f3c4a8170ca91b702e3789881dd2a6c2",
"shasum": ""
},
"require": {
@@ -482,7 +482,7 @@
"cache",
"caching"
],
"time": "2015-04-28 19:52:40"
"time": "2015-05-07 20:41:18"
},
{
"name": "doctrine/collections",
@@ -971,12 +971,12 @@
"source": {
"type": "git",
"url": "https://github.com/guzzle/RingPHP.git",
"reference": "2f75325d08c9ec39e5d3af54fcb6b9c0e7fd6114"
"reference": "2498ee848cd01639aecdcf3d5a257bace8665b7c"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/guzzle/RingPHP/zipball/2f75325d08c9ec39e5d3af54fcb6b9c0e7fd6114",
"reference": "2f75325d08c9ec39e5d3af54fcb6b9c0e7fd6114",
"url": "https://api.github.com/repos/guzzle/RingPHP/zipball/2498ee848cd01639aecdcf3d5a257bace8665b7c",
"reference": "2498ee848cd01639aecdcf3d5a257bace8665b7c",
"shasum": ""
},
"require": {
@@ -1014,7 +1014,7 @@
}
],
"description": "Provides a simple API and specification that abstracts away the details of HTTP into a single PHP function.",
"time": "2015-04-27 21:47:43"
"time": "2015-05-01 04:57:09"
},
{
"name": "guzzlehttp/streams",
@@ -1072,12 +1072,12 @@
"source": {
"type": "git",
"url": "https://github.com/Intervention/image.git",
"reference": "6626d7624ac0895137a38c123943afedd0827efc"
"reference": "79f0a35da7d4f75bb85d9c04513dd5929e21f75e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/Intervention/image/zipball/6626d7624ac0895137a38c123943afedd0827efc",
"reference": "6626d7624ac0895137a38c123943afedd0827efc",
"url": "https://api.github.com/repos/Intervention/image/zipball/79f0a35da7d4f75bb85d9c04513dd5929e21f75e",
"reference": "79f0a35da7d4f75bb85d9c04513dd5929e21f75e",
"shasum": ""
},
"require": {
@@ -1120,7 +1120,7 @@
"thumbnail",
"watermark"
],
"time": "2015-04-24 14:50:48"
"time": "2015-05-09 16:06:30"
},
{
"name": "ircmaxell/password-compat",
@@ -1333,12 +1333,12 @@
"source": {
"type": "git",
"url": "https://github.com/thephpleague/csv.git",
"reference": "f17b7214baeb2475ad7860bec03ffa766690c97e"
"reference": "3a2a199d686bc8b52689b74d5a66cb2e9b9370c9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thephpleague/csv/zipball/f17b7214baeb2475ad7860bec03ffa766690c97e",
"reference": "f17b7214baeb2475ad7860bec03ffa766690c97e",
"url": "https://api.github.com/repos/thephpleague/csv/zipball/3a2a199d686bc8b52689b74d5a66cb2e9b9370c9",
"reference": "3a2a199d686bc8b52689b74d5a66cb2e9b9370c9",
"shasum": ""
},
"require": {
@@ -1381,7 +1381,7 @@
"read",
"write"
],
"time": "2015-04-23 13:50:36"
"time": "2015-05-06 12:03:42"
},
{
"name": "maknz/slack",
@@ -1494,12 +1494,12 @@
"source": {
"type": "git",
"url": "https://github.com/Seldaek/monolog.git",
"reference": "d84ba2cb20186688230a5a11f76a70e97fe2f886"
"reference": "bf2bff61743f20a13dc46ff1e3bbd0f19c997d2b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/Seldaek/monolog/zipball/d84ba2cb20186688230a5a11f76a70e97fe2f886",
"reference": "d84ba2cb20186688230a5a11f76a70e97fe2f886",
"url": "https://api.github.com/repos/Seldaek/monolog/zipball/bf2bff61743f20a13dc46ff1e3bbd0f19c997d2b",
"reference": "bf2bff61743f20a13dc46ff1e3bbd0f19c997d2b",
"shasum": ""
},
"require": {
@@ -1561,7 +1561,7 @@
"logging",
"psr-3"
],
"time": "2015-04-25 10:55:55"
"time": "2015-05-11 14:51:05"
},
{
"name": "nesbot/carbon",
@@ -2001,19 +2001,19 @@
"source": {
"type": "git",
"url": "https://github.com/swiftmailer/swiftmailer.git",
"reference": "728eba28e355e081b0729b4c18cb9c13abe12560"
"reference": "ac8b475454c120bfb31f5bef475233dd4fb6b626"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/swiftmailer/swiftmailer/zipball/728eba28e355e081b0729b4c18cb9c13abe12560",
"reference": "728eba28e355e081b0729b4c18cb9c13abe12560",
"url": "https://api.github.com/repos/swiftmailer/swiftmailer/zipball/ac8b475454c120bfb31f5bef475233dd4fb6b626",
"reference": "ac8b475454c120bfb31f5bef475233dd4fb6b626",
"shasum": ""
},
"require": {
"php": ">=5.3.3"
},
"require-dev": {
"mockery/mockery": "~0.9.1"
"mockery/mockery": "~0.9.1,<0.9.4"
},
"type": "library",
"extra": {
@@ -2045,7 +2045,7 @@
"mail",
"mailer"
],
"time": "2015-03-30 15:09:02"
"time": "2015-05-06 16:40:00"
},
{
"name": "symfony/browser-kit",
@@ -2108,12 +2108,12 @@
"source": {
"type": "git",
"url": "https://github.com/symfony/Config.git",
"reference": "b9a3893998ddb7a6e84088ac21a0540c4fa51627"
"reference": "8555ecc6e2a47441b4be56dbfde5cea68c916755"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Config/zipball/b9a3893998ddb7a6e84088ac21a0540c4fa51627",
"reference": "b9a3893998ddb7a6e84088ac21a0540c4fa51627",
"url": "https://api.github.com/repos/symfony/Config/zipball/8555ecc6e2a47441b4be56dbfde5cea68c916755",
"reference": "8555ecc6e2a47441b4be56dbfde5cea68c916755",
"shasum": ""
},
"require": {
@@ -2139,18 +2139,18 @@
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony Config Component",
"homepage": "http://symfony.com",
"time": "2015-04-24 07:03:44"
"homepage": "https://symfony.com",
"time": "2015-05-12 15:16:46"
},
{
"name": "symfony/console",
@@ -2376,12 +2376,12 @@
"source": {
"type": "git",
"url": "https://github.com/symfony/EventDispatcher.git",
"reference": "44bde9645703fe92da9f5dd2755298f7c2c6fa92"
"reference": "8766cebf28beac9a45b511d7dba053da9d35eb9f"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/EventDispatcher/zipball/44bde9645703fe92da9f5dd2755298f7c2c6fa92",
"reference": "44bde9645703fe92da9f5dd2755298f7c2c6fa92",
"url": "https://api.github.com/repos/symfony/EventDispatcher/zipball/8766cebf28beac9a45b511d7dba053da9d35eb9f",
"reference": "8766cebf28beac9a45b511d7dba053da9d35eb9f",
"shasum": ""
},
"require": {
@@ -2415,18 +2415,18 @@
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony EventDispatcher Component",
"homepage": "http://symfony.com",
"time": "2015-04-24 07:03:44"
"homepage": "https://symfony.com",
"time": "2015-05-12 15:16:46"
},
{
"name": "symfony/filesystem",
@@ -2434,12 +2434,12 @@
"source": {
"type": "git",
"url": "https://github.com/symfony/Filesystem.git",
"reference": "41b7d35d812653a54fd931a6c8cf139767a95abb"
"reference": "6c4f6245440b53e55d4b5d3c3bd98532d6c6e11e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Filesystem/zipball/41b7d35d812653a54fd931a6c8cf139767a95abb",
"reference": "41b7d35d812653a54fd931a6c8cf139767a95abb",
"url": "https://api.github.com/repos/symfony/Filesystem/zipball/6c4f6245440b53e55d4b5d3c3bd98532d6c6e11e",
"reference": "6c4f6245440b53e55d4b5d3c3bd98532d6c6e11e",
"shasum": ""
},
"require": {
@@ -2464,18 +2464,18 @@
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony Filesystem Component",
"homepage": "http://symfony.com",
"time": "2015-04-24 07:03:44"
"homepage": "https://symfony.com",
"time": "2015-05-12 15:16:46"
},
{
"name": "symfony/finder",
@@ -2835,12 +2835,12 @@
"source": {
"type": "git",
"url": "https://github.com/symfony/Stopwatch.git",
"reference": "20c8903372e2a924421d93d55928be80c617cf3a"
"reference": "548bdb98ca54e9121e603ad9789775aa8ddb153d"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Stopwatch/zipball/20c8903372e2a924421d93d55928be80c617cf3a",
"reference": "20c8903372e2a924421d93d55928be80c617cf3a",
"url": "https://api.github.com/repos/symfony/Stopwatch/zipball/548bdb98ca54e9121e603ad9789775aa8ddb153d",
"reference": "548bdb98ca54e9121e603ad9789775aa8ddb153d",
"shasum": ""
},
"require": {
@@ -2865,18 +2865,18 @@
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony Stopwatch Component",
"homepage": "http://symfony.com",
"time": "2015-04-24 07:03:44"
"homepage": "https://symfony.com",
"time": "2015-05-12 15:16:46"
},
{
"name": "symfony/translation",
@@ -2940,12 +2940,12 @@
"source": {
"type": "git",
"url": "https://github.com/symfony/var-dumper.git",
"reference": "2bb458cc26efc9fa6ae88bcbcbd0525d4ecf6672"
"reference": "5b0473622df3e313509b8771356eefa8b29bdc74"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/2bb458cc26efc9fa6ae88bcbcbd0525d4ecf6672",
"reference": "2bb458cc26efc9fa6ae88bcbcbd0525d4ecf6672",
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/5b0473622df3e313509b8771356eefa8b29bdc74",
"reference": "5b0473622df3e313509b8771356eefa8b29bdc74",
"shasum": ""
},
"require": {
@@ -2976,22 +2976,22 @@
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Nicolas Grekas",
"email": "p@tchwork.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony mechanism for exploring and dumping PHP variables",
"homepage": "http://symfony.com",
"homepage": "https://symfony.com",
"keywords": [
"debug",
"dump"
],
"time": "2015-04-24 07:03:44"
"time": "2015-05-12 15:16:46"
},
{
"name": "symfony/yaml",
@@ -2999,12 +2999,12 @@
"source": {
"type": "git",
"url": "https://github.com/symfony/Yaml.git",
"reference": "4ededb1d00dc2c65fcd16ae3dafc785f92b3f95f"
"reference": "2396832f6f9ab2b8f62f00b5d3f2e722fc773d65"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/Yaml/zipball/4ededb1d00dc2c65fcd16ae3dafc785f92b3f95f",
"reference": "4ededb1d00dc2c65fcd16ae3dafc785f92b3f95f",
"url": "https://api.github.com/repos/symfony/Yaml/zipball/2396832f6f9ab2b8f62f00b5d3f2e722fc773d65",
"reference": "2396832f6f9ab2b8f62f00b5d3f2e722fc773d65",
"shasum": ""
},
"require": {
@@ -3029,18 +3029,18 @@
"MIT"
],
"authors": [
{
"name": "Symfony Community",
"homepage": "http://symfony.com/contributors"
},
{
"name": "Fabien Potencier",
"email": "fabien@symfony.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony Yaml Component",
"homepage": "http://symfony.com",
"time": "2015-04-24 07:03:44"
"homepage": "https://symfony.com",
"time": "2015-05-12 15:16:46"
}
],
"packages-dev": [
@@ -3050,12 +3050,12 @@
"source": {
"type": "git",
"url": "https://github.com/doctrine/instantiator.git",
"reference": "fc999e2f0508e434645ec2bfadeb89d39fa6453c"
"reference": "cd3fe91baa28da6e119d619612439eb2db0d8d88"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/doctrine/instantiator/zipball/fc999e2f0508e434645ec2bfadeb89d39fa6453c",
"reference": "fc999e2f0508e434645ec2bfadeb89d39fa6453c",
"url": "https://api.github.com/repos/doctrine/instantiator/zipball/cd3fe91baa28da6e119d619612439eb2db0d8d88",
"reference": "cd3fe91baa28da6e119d619612439eb2db0d8d88",
"shasum": ""
},
"require": {
@@ -3096,20 +3096,20 @@
"constructor",
"instantiate"
],
"time": "2015-04-12 20:59:10"
"time": "2015-05-10 22:20:19"
},
{
"name": "hamcrest/hamcrest-php",
"version": "v1.2.1",
"version": "v1.2.2",
"source": {
"type": "git",
"url": "https://github.com/hamcrest/hamcrest-php.git",
"reference": "ac50c470531243944f977b8de75be0b684a9cb51"
"reference": "b37020aa976fa52d3de9aa904aa2522dc518f79c"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/hamcrest/hamcrest-php/zipball/ac50c470531243944f977b8de75be0b684a9cb51",
"reference": "ac50c470531243944f977b8de75be0b684a9cb51",
"url": "https://api.github.com/repos/hamcrest/hamcrest-php/zipball/b37020aa976fa52d3de9aa904aa2522dc518f79c",
"reference": "b37020aa976fa52d3de9aa904aa2522dc518f79c",
"shasum": ""
},
"require": {
@@ -3141,7 +3141,7 @@
"keywords": [
"test"
],
"time": "2015-01-20 19:34:09"
"time": "2015-05-11 14:41:42"
},
{
"name": "mockery/mockery",
@@ -3214,12 +3214,12 @@
"source": {
"type": "git",
"url": "https://github.com/phpDocumentor/ReflectionDocBlock.git",
"reference": "d1da796ba5565789a623052eb9f2cf59d57fec60"
"reference": "ae15da2ce234d3ffe5d7fafcdad19c7f1acf3568"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/d1da796ba5565789a623052eb9f2cf59d57fec60",
"reference": "d1da796ba5565789a623052eb9f2cf59d57fec60",
"url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/ae15da2ce234d3ffe5d7fafcdad19c7f1acf3568",
"reference": "ae15da2ce234d3ffe5d7fafcdad19c7f1acf3568",
"shasum": ""
},
"require": {
@@ -3229,7 +3229,6 @@
"phpunit/phpunit": "~4.0"
},
"suggest": {
"dflydev/markdown": "~1.0",
"erusev/parsedown": "~1.0",
"league/commonmark": "*"
},
@@ -3256,7 +3255,7 @@
"email": "mike.vanriel@naenius.com"
}
],
"time": "2015-02-27 09:28:18"
"time": "2015-05-12 07:21:12"
},
{
"name": "phpspec/prophecy",
@@ -3324,12 +3323,12 @@
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
"reference": "1678cee3b7f93f994da6acf7e998b23a98e955f1"
"reference": "9ef4b8cbf3e839a44a9b375d8c59e109ac7aa020"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/1678cee3b7f93f994da6acf7e998b23a98e955f1",
"reference": "1678cee3b7f93f994da6acf7e998b23a98e955f1",
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/9ef4b8cbf3e839a44a9b375d8c59e109ac7aa020",
"reference": "9ef4b8cbf3e839a44a9b375d8c59e109ac7aa020",
"shasum": ""
},
"require": {
@@ -3378,7 +3377,7 @@
"testing",
"xunit"
],
"time": "2015-04-16 05:00:01"
"time": "2015-05-09 04:40:58"
},
{
"name": "phpunit/php-file-iterator",
+5 -1
View File
@@ -5,6 +5,10 @@
RewriteEngine On
# Uncomment these two lines to force SSL redirect
# RewriteCond %{HTTPS} off
# RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
# Redirect Trailing Slashes...
RewriteRule ^(.*)/$ /$1 [L,R=301]
@@ -12,4 +16,4 @@
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</IfModule>
</IfModule>