Merge pull request #12975 from inietov/fixes/import_asset_notes

Fixed Notes field doesn't get populate when creating/updating assets via Importer [sc-23222]
This commit is contained in:
snipe 2023-05-08 13:11:50 -07:00 committed by GitHub
commit d685335aea
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -67,7 +67,6 @@ class Importer extends Component
'location' => 'Location', 'location' => 'Location',
'maintained' => 'Maintained', 'maintained' => 'Maintained',
'manufacturer' => 'Manufacturer', 'manufacturer' => 'Manufacturer',
'notes' => 'Notes',
'order_number' => 'Order Number', 'order_number' => 'Order Number',
'purchase_cost' => 'Purchase Cost', 'purchase_cost' => 'Purchase Cost',
'purchase_date' => 'Purchase Date', 'purchase_date' => 'Purchase Date',
@ -81,11 +80,14 @@ class Importer extends Component
static $accessories = [ static $accessories = [
'model_number' => 'Model Number', 'model_number' => 'Model Number',
'notes' => 'Notes',
]; ];
static $assets = [ static $assets = [
'asset_tag' => 'Asset Tag', 'asset_tag' => 'Asset Tag',
'asset_model' => 'Model Name', 'asset_model' => 'Model Name',
'asset_notes' => 'Asset Notes',
'model_notes' => 'Model Notes',
'byod' => 'BYOD', 'byod' => 'BYOD',
'checkout_class' => 'Checkout Type', 'checkout_class' => 'Checkout Type',
'checkout_location' => 'Checkout Location', 'checkout_location' => 'Checkout Location',
@ -99,6 +101,7 @@ class Importer extends Component
static $consumables = [ static $consumables = [
'item_no' => "Item Number", 'item_no' => "Item Number",
'model_number' => "Model Number", 'model_number' => "Model Number",
'notes' => 'Notes',
'min_amt' => "Minimum Quantity", 'min_amt' => "Minimum Quantity",
]; ];
@ -111,12 +114,14 @@ class Importer extends Component
'purchase_order' => 'Purchase Order', 'purchase_order' => 'Purchase Order',
'reassignable' => 'Reassignable', 'reassignable' => 'Reassignable',
'seats' => 'Seats', 'seats' => 'Seats',
'notes' => 'Notes',
]; ];
static $users = [ static $users = [
'employee_num' => 'Employee Number', 'employee_num' => 'Employee Number',
'first_name' => 'First Name', 'first_name' => 'First Name',
'last_name' => 'Last Name', 'last_name' => 'Last Name',
'notes' => 'Notes',
'jobtitle' => 'Job Title', 'jobtitle' => 'Job Title',
'phone_number' => 'Phone Number', 'phone_number' => 'Phone Number',
'manager_first_name' => 'Manager First Name', 'manager_first_name' => 'Manager First Name',
@ -144,6 +149,7 @@ class Importer extends Component
'manager_username' => 'Manager Username', 'manager_username' => 'Manager Username',
'manager' => 'Manager', 'manager' => 'Manager',
'parent_location' => 'Parent Location', 'parent_location' => 'Parent Location',
'notes' => 'Notes',
]; ];
//array of "real fieldnames" to a list of aliases for that field //array of "real fieldnames" to a list of aliases for that field