Skip to content

Commit

Permalink
Fix the mysql map
Browse files Browse the repository at this point in the history
Signed-off-by: matdave <[email protected]>
  • Loading branch information
matdave committed Oct 22, 2024
1 parent 34e21f2 commit e54a877
Show file tree
Hide file tree
Showing 16 changed files with 340 additions and 358 deletions.
2 changes: 1 addition & 1 deletion _build/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"lowCaseName": "fred",
"description": "Frontend Editor",
"author": "John Peca",
"version": "3.1.0-pl",
"version": "3.1.1-pl",
"package": {
"menus": [
{
Expand Down
2 changes: 1 addition & 1 deletion _build/gpm.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"lowCaseName": "fred",
"description": "Frontend Editor",
"author": "John Peca",
"version": "3.1.0-pl",
"version": "3.1.1-pl",
"menus": [
{
"text": "fred.menu.fred",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ fred.grid.Blueprints = function (config) {
width: 70,
renderer: function (value, metaData, record, rowIndex, colIndex, store) {
return `<div class="fred-x-grid-cell-name">
<h3><a href="?a=blueprint/update&namespace=fred&id=${record.data.id}"${value}</a></h3>
<h3><a href="?a=blueprint/update&namespace=fred&id=${record.data.id}">${value}</a></h3>
<small>${_('fred.global.uuid')}: ${record.data.uuid}</small>
<small>${record.data.description}</small>
</div>`;
Expand Down
88 changes: 43 additions & 45 deletions core/components/fred/model/fred/mysql/fredblueprint.map.inc.php
Original file line number Diff line number Diff line change
@@ -1,71 +1,69 @@
<?php

/**
* @package fred
*/

$xpdo_meta_map['FredBlueprint'] = array (
$xpdo_meta_map['FredBlueprint']= array (
'package' => 'fred',
'version' => '2.0',
'table' => 'fred_blueprints',
'tableMeta' =>
'tableMeta' =>
array (
'engine' => 'InnoDB',
),
'fields' =>
'fields' =>
array (
'name' => null,
'uuid' => null,
'name' => NULL,
'uuid' => NULL,
'description' => '',
'image' => '',
'category' => null,
'category' => NULL,
'rank' => 0,
'complete' => 0,
'public' => 0,
'createdBy' => 0,
'data' => '',
),
'fieldMeta' =>
'fieldMeta' =>
array (
'name' =>
'name' =>
array (
'dbtype' => 'varchar',
'precision' => '127',
'phptype' => 'string',
'null' => false,
),
'uuid' =>
'uuid' =>
array (
'dbtype' => 'varchar',
'precision' => '36',
'phptype' => 'string',
'null' => false,
'index' => 'unique',
),
'description' =>
'description' =>
array (
'dbtype' => 'varchar',
'precision' => '255',
'phptype' => 'string',
'null' => false,
'default' => '',
),
'image' =>
'image' =>
array (
'dbtype' => 'text',
'phptype' => 'string',
'null' => false,
'default' => '',
),
'category' =>
'category' =>
array (
'dbtype' => 'int',
'attributes' => 'unsigned',
'precision' => '10',
'phptype' => 'integer',
'null' => false,
),
'rank' =>
'rank' =>
array (
'dbtype' => 'int',
'attributes' => 'unsigned',
Expand All @@ -74,7 +72,7 @@
'null' => false,
'default' => 0,
),
'complete' =>
'complete' =>
array (
'dbtype' => 'tinyint',
'attributes' => 'unsigned',
Expand All @@ -83,15 +81,15 @@
'null' => false,
'default' => 0,
),
'public' =>
'public' =>
array (
'dbtype' => 'tinyint',
'precision' => '1',
'phptype' => 'boolean',
'null' => false,
'default' => 0,
),
'createdBy' =>
'createdBy' =>
array (
'dbtype' => 'int',
'attributes' => 'unsigned',
Expand All @@ -100,115 +98,115 @@
'null' => false,
'default' => 0,
),
'data' =>
'data' =>
array (
'dbtype' => 'mediumtext',
'phptype' => 'json',
'null' => false,
'default' => '',
),
),
'fieldAliases' =>
'fieldAliases' =>
array (
'content' => 'data',
),
'indexes' =>
'indexes' =>
array (
'uuid' =>
'uuid' =>
array (
'alias' => 'uuid',
'primary' => false,
'unique' => true,
'type' => 'BTREE',
'columns' =>
'columns' =>
array (
'uuid' =>
'uuid' =>
array (
'length' => '',
'collation' => 'A',
'null' => false,
),
),
),
'category' =>
'category' =>
array (
'alias' => 'category',
'primary' => false,
'unique' => false,
'type' => 'BTREE',
'columns' =>
'columns' =>
array (
'category' =>
'category' =>
array (
'length' => '',
'collation' => 'A',
'null' => false,
),
),
),
'rank' =>
'rank' =>
array (
'alias' => 'rank',
'primary' => false,
'unique' => false,
'type' => 'BTREE',
'columns' =>
'columns' =>
array (
'rank' =>
'rank' =>
array (
'length' => '',
'collation' => 'A',
'null' => false,
),
),
),
'complete' =>
'complete' =>
array (
'alias' => 'complete',
'primary' => false,
'unique' => false,
'type' => 'BTREE',
'columns' =>
'columns' =>
array (
'complete' =>
'complete' =>
array (
'length' => '',
'collation' => 'A',
'null' => false,
),
),
),
'createdBy' =>
'createdBy' =>
array (
'alias' => 'createdBy',
'primary' => false,
'unique' => false,
'type' => 'BTREE',
'columns' =>
'columns' =>
array (
'createdBy' =>
'createdBy' =>
array (
'length' => '',
'collation' => 'A',
'null' => false,
),
),
),
'name_category' =>
'name_category' =>
array (
'alias' => 'name_category',
'primary' => false,
'unique' => true,
'type' => 'BTREE',
'columns' =>
'columns' =>
array (
'name' =>
'name' =>
array (
'length' => '',
'collation' => 'A',
'null' => false,
),
'category' =>
'category' =>
array (
'length' => '',
'collation' => 'A',
Expand All @@ -217,9 +215,9 @@
),
),
),
'composites' =>
'composites' =>
array (
'BlueprintTemplatesAccess' =>
'BlueprintTemplatesAccess' =>
array (
'class' => 'FredBlueprintTemplateAccess',
'local' => 'id',
Expand All @@ -228,17 +226,17 @@
'owner' => 'local',
),
),
'aggregates' =>
'aggregates' =>
array (
'User' =>
'User' =>
array (
'class' => 'modUser',
'local' => 'user',
'foreign' => 'id',
'cardinality' => 'one',
'owner' => 'foreign',
),
'Category' =>
'Category' =>
array (
'class' => 'FredBlueprintCategory',
'local' => 'category',
Expand Down
Loading

0 comments on commit e54a877

Please sign in to comment.