mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
20 lines
388 B
PHP
20 lines
388 B
PHP
|
<?php
|
||
|
|
||
|
namespace SilverStripe\Dev\Tests\CsvBulkLoaderTest;
|
||
|
|
||
|
use SilverStripe\Dev\CsvBulkLoader;
|
||
|
use SilverStripe\Dev\TestOnly;
|
||
|
|
||
|
class CustomLoader extends CsvBulkLoader implements TestOnly
|
||
|
{
|
||
|
public function importFirstName(&$obj, $val, $record)
|
||
|
{
|
||
|
$obj->FirstName = "Customized {$val}";
|
||
|
}
|
||
|
|
||
|
public function updatePlayer(&$obj, $val, $record)
|
||
|
{
|
||
|
$obj->FirstName .= $val . '. ';
|
||
|
}
|
||
|
}
|