Created
April 5, 2018 20:07
-
-
Save BrandonDyer64/011c929b8ba81bd899e4ff8e31e1862e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
include("../../bin/do_not_change/standard_validation_regex.php"); | |
unset($field); | |
unset($index); | |
$table = "${master}_document"; | |
$table_type = "master_id_with_auto"; | |
$is_slave_table_to[] = "${master}"; | |
$thing_display = preg_replace("/_/", " ", $table); | |
$Thing_display = ucfirst($thing_display); | |
$things_display = "${thing_display}s"; | |
$Things_display = ucfirst($things_display); | |
$indefinite_article = "a"; | |
$display_name_as = "uploaded_as"; | |
$field[] = array("name"=>"id", | |
"type"=>"INT UNSIGNED", | |
"not_null" => TRUE, | |
"auto_increment" => TRUE, | |
"display_in_table_list_column" => TRUE, | |
"display_field_in_vertical_table" => TRUE, | |
"field_is_required_in_form" => TRUE, | |
"human_display" => "ID" | |
); | |
$field[] = array("name"=>"${master}_id", | |
"type"=>"INT UNSIGNED", | |
"not_null" => TRUE, | |
"make_link" => TRUE, | |
"dont_make_select_list" => TRUE, | |
"display_in_table_list_column" => TRUE, | |
"display_field_in_vertical_table" => TRUE, | |
"field_is_required_in_form" => FALSE, | |
"filterable" => TRUE, | |
"filter_operator" => "=", | |
"human_display" => "Campaign Source" | |
); | |
$field[] = array("name"=>"description", | |
"type"=>"VARCHAR", | |
"size"=>"255", | |
"not_null" => TRUE, | |
"display_in_table_list_column" => TRUE, | |
"display_field_in_vertical_table" => TRUE, | |
"field_is_required_in_form" => TRUE, | |
"filterable" => TRUE, | |
"filter_operator" => "LIKE", | |
"human_display" => "Description" | |
); | |
include("../../bin/do_not_change/standard_config_files/STANDARD_FILE_UPLOAD_AS_UPLOADED_AS"); | |
$field[] = array("name"=>"comments", | |
"type"=>"TEXT", | |
"display_in_table_list_column" => TRUE, | |
"display_field_in_vertical_table" => TRUE, | |
"field_is_required_in_form" => FALSE, | |
"filterable" => TRUE, | |
"filter_operator" => "LIKE", | |
"human_display" => "Comments" | |
); | |
include("../../bin/do_not_change/standard_config_files/STANDARD_TABLE_FIELDS"); | |
$index[] = array("type"=>"PRIMARY KEY", | |
"name"=>array("${master}_id","id") | |
); | |
$startup_sql[] = "INSERT IGNORE INTO thing (id, name, active, date_added) VALUES ('$table','$Thing_display','y',NOW())"; | |
// give admin group read/write permissions | |
$startup_sql[] = "INSERT IGNORE INTO jusergroup_thing (usergroup_id, thing_id, read_access, write_access, active, date_added) VALUES ('2','$table','all','all','y',NOW())"; | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment