Merge remote-tracking branch 'origin/v3' into v3-master

This commit is contained in:
snipe 2016-06-21 11:09:31 -07:00
commit 3107b3679d
3 changed files with 12 additions and 12 deletions

View file

@ -396,7 +396,7 @@ class AssetImportCommand extends Command {
if ($user_asset_purchase_date!='') {
$asset->purchase_date = $user_asset_purchase_date;
} else {
$asset->purchase_date = NULL;
$asset->purchase_date = null;
}
if ($user_asset_purchase_cost!='') {
$asset->purchase_cost = ParseFloat(e($user_asset_purchase_cost));
@ -414,7 +414,7 @@ class AssetImportCommand extends Command {
if ($user_asset_purchase_date!='') {
$asset->purchase_date = $user_asset_purchase_date;
} else {
$asset->purchase_date = NULL;
$asset->purchase_date = null;
}
$asset->notes = e($user_asset_notes);

View file

@ -266,7 +266,7 @@ class LicenseImportCommand extends Command {
}
} else {
$user = new User;
$user->user_id = NULL;
$user->user_id = null;
}
@ -293,7 +293,7 @@ class LicenseImportCommand extends Command {
if ($user_license_purchase_date!='') {
$license->purchase_date = $user_license_purchase_date;
} else {
$license->purchase_date = NULL;
$license->purchase_date = null;
}
$license->serial = e($user_license_serial);
$license->seats = e($user_license_seats);
@ -302,7 +302,7 @@ class LicenseImportCommand extends Command {
if ($user_license_purchase_date!='') {
$license->purchase_date = $user_license_purchase_date;
} else {
$license->purchase_date = NULL;
$license->purchase_date = null;
}
$license->license_name = $user_licensed_to_name;
$license->license_email = $user_licensed_to_email;
@ -323,7 +323,7 @@ class LicenseImportCommand extends Command {
if ($x==0) {
$license_seat->assigned_to = $user->id;
} else {
$license_seat->assigned_to = NULL;
$license_seat->assigned_to = null;
}
if ($license_seat->save()) {

View file

@ -82,7 +82,7 @@ class ObjectImportCommand extends Command {
$csv = Reader::createFromPath($this->argument('filename'));
$csv->setNewline("\r\n");
$results = $csv->fetchAssoc();
$newarray = NULL;
$newarray = null;
foreach ($results as $index => $arraytoNormalize)
{
@ -103,7 +103,7 @@ class ObjectImportCommand extends Command {
$this->accessories = Accessory::All(['name']);
$this->consumables = Consumable::All(['name']);
$this->customfields = CustomField::All(['name']);
$bar = NULL;
$bar = null;
if(!$this->option('web-importer')) {
$bar = $this->output->createProgressBar(count($newarray));
}
@ -716,7 +716,7 @@ class ObjectImportCommand extends Command {
$asset_image = $this->array_smart_fetch($row, "image");
$asset_warranty_months = intval($this->array_smart_fetch($row, "warranty months"));
if(empty($asset_warranty_months)) {
$asset_warranty_months = NULL;
$asset_warranty_months = null;
}
// Check for the asset model match and create it if it doesn't exist
$asset_model = $this->createOrFetchAssetModel($row, $item["category"], $item["manufacturer"]);
@ -751,7 +751,7 @@ class ObjectImportCommand extends Command {
if ($item["purchase_date"] != '') {
$asset->purchase_date = $item["purchase_date"];
} else {
$asset->purchase_date = NULL;
$asset->purchase_date = null;
}
if( array_key_exists('custom_fields', $item)) {
@ -828,7 +828,7 @@ class ObjectImportCommand extends Command {
if (!empty($item["purchase_date"])) {
$accessory->purchase_date = $item["purchase_date"];
} else {
$accessory->purchase_date = NULL;
$accessory->purchase_date = null;
}
if (!empty($item["purchase_cost"])) {
$accessory->purchase_cost = number_format(e($item["purchase_cost"]),2);
@ -894,7 +894,7 @@ class ObjectImportCommand extends Command {
if(!empty($item["purchase_date"])) {
$consumable->purchase_date = $item["purchase_date"];
} else {
$consumable->purchase_date = NULL;
$consumable->purchase_date = null;
}
if(!empty($item["purchase_cost"])) {