Commit 34d0e013 authored by Jack Stupple's avatar Jack Stupple

massive update to imports to allow for multple currencies

parent 2c09c5a6
......@@ -187,8 +187,8 @@ class Initial extends Migration
]);
DB::table('languages')->insert([
'name' => 'Français',
'slug' => 'fr',
'name' => 'Nederlands',
'slug' => 'nl',
'enabled' => $this->created_at,
'created_at' => $this->created_at
]);
......
......@@ -24,6 +24,14 @@ class CreateCurrenciesTable extends Migration
$currency = new Currency();
$currency->currency_code = 'EUR';
$currency->save();
$currency = new Currency();
$currency->currency_code = 'GBP';
$currency->save();
$currency = new Currency();
$currency->currency_code = 'NOK';
$currency->save();
}
/**
......
......@@ -15,13 +15,13 @@ class AddNewSupportedLanguages extends Migration
{
$now = date('Y-m-d H:i:s');
// remove the old one that was spelled wrong
$de = \App\Language::where('name', 'Deutch')->first();
$de = \App\Language::where('name', 'Deutsch')->first();
if ($de) {
$de->delete();
}
$de = \App\Language::firstOrCreate([
'name' => 'Nederlands',
'name' => 'Deutsch',
'slug' => 'de'
]);
......
......@@ -22,6 +22,7 @@ class ImportJakeQuestions extends CharacterMigration
*/
public function up()
{
return;
$this->created_at = date('Y-m-d H:i:s');
$this->character = new \App\Character();
......
......@@ -22,6 +22,8 @@ class ImportJamalsQuestions extends CharacterMigration
*/
public function up()
{
return;
$this->created_at = date('Y-m-d H:i:s');
$this->character = new \App\Character();
......
......@@ -22,6 +22,8 @@ class ImportAnnQuestions extends CharacterMigration
*/
public function up()
{
return;
$this->created_at = date('Y-m-d H:i:s');
$this->character = new \App\Character();
......
This diff is collapsed.
This diff is collapsed.
{
"en": [
{
"roundup_text": "Ann qualifies for a government scheme to get subsidies on her electricity and heating costs, so her utility bills have gone down.",
"positive_negative": 1,
"modifiers": [
{
"category": "bills",
"amount": -30
}
]
},
{
"roundup_text": "Ann's dog Billy has fallen ill and will require surgery.",
"positive_negative": -1,
"modifiers": [
{
"category": "other_out",
"amount": 100
}
]
},
{
"roundup_text": "Ann's local bus has stopped running at weekends so she will need to find alternative transport.",
"positive_negative": -1,
"modifiers": [
{
"category": "transport",
"amount": 80
}
]
},
{
"roundup_text": "Ann wins money in a radio competition.",
"positive_negative": 1,
"modifiers": [
{
"category": "other_in",
"amount": 50
}
]
},
{
"roundup_text": "Ann decides to adopt a cat from her friend who can longer look after it.",
"positive_negative": -1,
"modifiers": [
{
"category": "bills",
"amount": 30
}
]
},
{
"roundup_text": "Ann joins her friends in taking up a fitness class.",
"positive_negative": -1,
"modifiers": [
{
"category": "entertainment",
"amount": 20
}
]
},
{
"roundup_text": "Ann helps her friend out at her allotment and get free fruit and vegetables.",
"positive_negative": 1,
"modifiers": [
{
"category": "groceries",
"amount": -60
}
]
},
{
"roundup_text": "Ann's son treats her to a weekend spa break for her birthday.",
"positive_negative": 1,
"modifiers": []
},
{
"roundup_text": "Ann subscribes to a film streaming service.",
"positive_negative": -1,
"modifiers": [
{
"category": "entertainment",
"amount": 9.99
}
]
}
],
"fr": []
}
[
{
"roundup_text": "Ann qualifies for a government scheme to get subsidies on her electricity and heating costs, so her utility bills have gone down.",
"positive_negative": 1,
"modifiers": [
{
"category": "bills",
"amount": -30
}
]
},
{
"roundup_text": "Ann's dog Billy has fallen ill and will require surgery.",
"positive_negative": -1,
"modifiers": [
{
"category": "other_out",
"amount": 100
}
]
},
{
"roundup_text": "Ann's local bus has stopped running at weekends so she will need to find alternative transport.",
"positive_negative": -1,
"modifiers": [
{
"category": "transport",
"amount": 80
}
]
},
{
"roundup_text": "Ann wins money in a radio competition.",
"positive_negative": 1,
"modifiers": [
{
"category": "other_in",
"amount": 50
}
]
},
{
"roundup_text": "Ann decides to adopt a cat from her friend who can longer look after it.",
"positive_negative": -1,
"modifiers": [
{
"category": "bills",
"amount": 30
}
]
},
{
"roundup_text": "Ann joins her friends in taking up a fitness class.",
"positive_negative": -1,
"modifiers": [
{
"category": "entertainment",
"amount": 20
}
]
},
{
"roundup_text": "Ann helps her friend out at her allotment and get free fruit and vegetables.",
"positive_negative": 1,
"modifiers": [
{
"category": "groceries",
"amount": -60
}
]
},
{
"roundup_text": "Ann's son treats her to a weekend spa break for her birthday.",
"positive_negative": 1,
"modifiers": []
},
{
"roundup_text": "Ann subscribes to a film streaming service.",
"positive_negative": -1,
"modifiers": [
{
"category": "entertainment",
"amount": 9.99
}
]
}
]
[
{
"category": "salary",
"amount": 1131
},
{
"category": "rent",
"amount": 450
},
{
"category": "transport",
"amount": 55
},
{
"category": "groceries",
"amount": 66.55
},
{
"category": "bills",
"amount": 60
},
{
"category": "shopping",
"amount": 119.50
},
{
"category": "entertainment",
"amount": 160
},
{
"category": "credit cards \/ loans",
"amount": 50
},
{
"category": "investments",
"amount": 0
},
{
"category": "other_out",
"amount": 0
},
{
"category": "other_in",
"amount": 0
},
{
"category": "savings",
"amount": 30
}
]
{
"eur": [
{
"category": "salary",
"amount": 1131
},
{
"category": "rent",
"amount": 450
},
{
"category": "transport",
"amount": 55
},
{
"category": "groceries",
"amount": 66.55
},
{
"category": "bills",
"amount": 60
},
{
"category": "shopping",
"amount": 119.50
},
{
"category": "entertainment",
"amount": 160
},
{
"category": "credit cards \/ loans",
"amount": 50
},
{
"category": "investments",
"amount": 0
},
{
"category": "other_out",
"amount": 0
},
{
"category": "other_in",
"amount": 0
},
{
"category": "savings",
"amount": 30
}
],
"gbp": [
{
"category": "salary",
"amount": 1131
},
{
"category": "rent",
"amount": 450
},
{
"category": "transport",
"amount": 55
},
{
"category": "groceries",
"amount": 66.55
},
{
"category": "bills",
"amount": 60
},
{
"category": "shopping",
"amount": 119.50
},
{
"category": "entertainment",
"amount": 160
},
{
"category": "credit cards \/ loans",
"amount": 50
},
{
"category": "investments",
"amount": 0
},
{
"category": "other_out",
"amount": 0
},
{
"category": "other_in",
"amount": 0
},
{
"category": "savings",
"amount": 30
}
],
"nok": []
}
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment