mirror of
https://gitlab.com/signalytic/client-external/streamline/streamline-emr.git
synced 2026-09-13 11:41:31 +00:00
updated streamline-setup v2
This commit is contained in:
@@ -0,0 +1,55 @@
|
||||
<?php
|
||||
namespace Database\Seeders;
|
||||
|
||||
use Illuminate\Database\Seeder;
|
||||
//use Illuminate\Support\Facades\DB;
|
||||
use Streamline\Models\UnitOfMeasure;
|
||||
|
||||
class UnitOfMeasureTableSeeder extends Seeder {
|
||||
|
||||
/**
|
||||
* Run the database seeders.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function run() {
|
||||
$names = array(
|
||||
'tablets',
|
||||
'packets',
|
||||
'bottles',
|
||||
'applications',
|
||||
'vial',
|
||||
'ampoule',
|
||||
'tube',
|
||||
'capsule',
|
||||
'canister',
|
||||
'litre',
|
||||
'tebts',
|
||||
'kit tin',
|
||||
'roll',
|
||||
'pce',
|
||||
'sacket',
|
||||
'jug',
|
||||
'jerrican',
|
||||
'set',
|
||||
'kg',
|
||||
'g',
|
||||
'NA',
|
||||
'Mmol/L',
|
||||
'mLs',
|
||||
'pessary',
|
||||
'drops'
|
||||
);
|
||||
|
||||
foreach ($names as $name) {
|
||||
|
||||
// Prevent re-seeding the same data
|
||||
UnitOfMeasure::firstOrCreate([
|
||||
'name' => $name,
|
||||
'created_by' => 1,
|
||||
'updated_by' => 1
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user