Skip to content

Commit afb92cd

Browse files
authored
Merge pull request #510 from hhaccessibility/issue-489
Issue 489
2 parents 0a72290 + 6cd7df0 commit afb92cd

5 files changed

Lines changed: 97 additions & 64 deletions

File tree

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<?php
2+
3+
use Illuminate\Support\Facades\Schema;
4+
use Illuminate\Database\Schema\Blueprint;
5+
use Illuminate\Database\Migrations\Migration;
6+
7+
/*
8+
This migration adds a new is_required_config to the question table.
9+
10+
is_required_config will be useful for determining if the question is
11+
applicable based on associated question_tag or answers to other questions.
12+
13+
For example, If a location has an elevator, asking if the doorway is wide enough
14+
for a wheelchair is applicable.
15+
*/
16+
class AddRequiredConfigToQuestionTable extends Migration
17+
{
18+
public function up()
19+
{
20+
Schema::table('question', function (Blueprint $table) {
21+
$table->json('is_required_config')->nullable();
22+
});
23+
}
24+
25+
public function down()
26+
{
27+
Schema::table('question', function (Blueprint $table) {
28+
$table->dropColumn('is_required_config');
29+
});
30+
}
31+
}

app/database/seeds/data/data_source.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,7 @@
66
{"id": 5, "name": "Yelp.com", "description": "For information taken from yelp.com and yelp.ca"},
77
{"id": 6, "name": "Google Places", "description": "For information downloaded using Google Places API's"},
88
{"id": 7, "name": "AccessLocator End Users", "description": "For information entered by end users while using AccessLocator"},
9-
{"id": 8, "name": "Mandarin Restaurant Website", "description": "For information downloaded from https://mandarinrestaurant.com"}
9+
{"id": 8, "name": "Mandarin Restaurant Website", "description": "For information downloaded from https://mandarinrestaurant.com"},
10+
{"id": 9, "name": "Access Earth", "description": "For information downloaded from https://access.earth/"},
11+
{"id": 10, "name": "ableroad.com", "description": "For information downloaded from http://ableroad.com"}
1012
]

0 commit comments

Comments
 (0)