From 68a3400f515292352bb58940a4cf9fb3265b8361 Mon Sep 17 00:00:00 2001 From: team-devstage Date: Mon, 26 Oct 2020 15:39:59 +0100 Subject: [PATCH] update skeema files, adding roles, belong to samirs work --- mithril_client | 2 +- skeema/gradido_community/admin_errors.sql | 2 +- .../gradido_community/community_profiles.sql | 13 +++++++------ skeema/gradido_community/operator_types.sql | 8 ++++---- skeema/gradido_community/operators.sql | 8 ++++---- .../gradido_community/pending_transactions.sql | 14 +++++++------- skeema/gradido_community/roles.sql | 6 ++++++ skeema/gradido_community/server_users.sql | 14 +++++++------- skeema/gradido_community/state_balances.sql | 8 ++++---- skeema/gradido_community/state_created.sql | 14 +++++++------- skeema/gradido_community/state_errors.sql | 10 +++++----- .../state_group_addresses.sql | 8 ++++---- .../state_group_relationships.sql | 10 +++++----- skeema/gradido_community/state_groups.sql | 8 ++++---- .../state_relationship_types.sql | 8 ++++---- skeema/gradido_community/state_user_roles.sql | 6 ++++++ skeema/gradido_community/state_users.sql | 18 +++++++++--------- .../transaction_creations.sql | 10 +++++----- .../transaction_group_addaddress.sql | 8 ++++---- .../transaction_group_allowtrades.sql | 8 ++++---- .../transaction_group_creates.sql | 10 +++++----- .../transaction_send_coins.sql | 14 +++++++------- .../transaction_signatures.sql | 6 +++--- skeema/gradido_community/transaction_types.sql | 8 ++++---- skeema/gradido_community/transactions.sql | 12 ++++++------ src/protobuf | 2 +- 26 files changed, 124 insertions(+), 111 deletions(-) create mode 100644 skeema/gradido_community/roles.sql create mode 100644 skeema/gradido_community/state_user_roles.sql diff --git a/mithril_client b/mithril_client index 21d4a0a5e..a04d47699 160000 --- a/mithril_client +++ b/mithril_client @@ -1 +1 @@ -Subproject commit 21d4a0a5e9a19f251e26c0ae07ce74be2fa99bbf +Subproject commit a04d4769974b9d93ba72e490ed7dca3fbaed768c diff --git a/skeema/gradido_community/admin_errors.sql b/skeema/gradido_community/admin_errors.sql index 877b1d7db..020b4078b 100644 --- a/skeema/gradido_community/admin_errors.sql +++ b/skeema/gradido_community/admin_errors.sql @@ -1,5 +1,5 @@ CREATE TABLE `admin_errors` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `state_user_id` int(11) NOT NULL, `controller` varchar(255) NOT NULL, `action` varchar(255) NOT NULL, diff --git a/skeema/gradido_community/community_profiles.sql b/skeema/gradido_community/community_profiles.sql index ce77b6ead..07d475fdf 100644 --- a/skeema/gradido_community/community_profiles.sql +++ b/skeema/gradido_community/community_profiles.sql @@ -1,8 +1,9 @@ CREATE TABLE `community_profiles` ( - `id` INT UNSIGNED NOT NULL AUTO_INCREMENT, - `state_user_id` INT UNSIGNED NOT NULL, - `profile_img` LONGBLOB NULL, - `profile_desc` VARCHAR(2000) NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `state_user_id` int(10) unsigned NOT NULL, + `profile_img` longblob, + `profile_desc` varchar(2000) COLLATE utf8mb4_unicode_ci DEFAULT NULL, PRIMARY KEY (`id`), - FOREIGN KEY (`state_user_id`) REFERENCES `state_users`(`id`) -) ENGINE=InnoDB; + KEY `state_user_id` (`state_user_id`), + CONSTRAINT `community_profiles_ibfk_1` FOREIGN KEY (`state_user_id`) REFERENCES `state_users` (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/operator_types.sql b/skeema/gradido_community/operator_types.sql index ccf779b0b..35df5264e 100644 --- a/skeema/gradido_community/operator_types.sql +++ b/skeema/gradido_community/operator_types.sql @@ -1,6 +1,6 @@ CREATE TABLE `operator_types` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `name` varchar(25) NOT NULL, - `text` varchar(255) NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `name` varchar(25) COLLATE utf8mb4_unicode_ci NOT NULL, + `text` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/operators.sql b/skeema/gradido_community/operators.sql index e995ff25e..74808be9b 100644 --- a/skeema/gradido_community/operators.sql +++ b/skeema/gradido_community/operators.sql @@ -1,8 +1,8 @@ CREATE TABLE `operators` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `username` varchar(50) NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `username` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL, `user_pubkey` binary(32) NOT NULL, - `data_base64` varchar(255) NOT NULL, + `data_base64` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL, `modified` datetime NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/pending_transactions.sql b/skeema/gradido_community/pending_transactions.sql index b3f94f38f..e3d6a4a08 100644 --- a/skeema/gradido_community/pending_transactions.sql +++ b/skeema/gradido_community/pending_transactions.sql @@ -1,10 +1,10 @@ CREATE TABLE `pending_transactions` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transactionID` varchar(25) NOT NULL, - `service` varchar(20) NOT NULL, - `method` varchar(20) NOT NULL, - `h_server_id` int NOT NULL, - `timeout` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transactionID` varchar(25) COLLATE utf8mb4_unicode_ci NOT NULL, + `service` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, + `method` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL, + `h_server_id` int(11) NOT NULL, + `timeout` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (`id`), UNIQUE KEY `transactionID` (`transactionID`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/roles.sql b/skeema/gradido_community/roles.sql new file mode 100644 index 000000000..5444cff76 --- /dev/null +++ b/skeema/gradido_community/roles.sql @@ -0,0 +1,6 @@ +CREATE TABLE `roles` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `title` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + PRIMARY KEY (`id`), + UNIQUE KEY `roles_id_IDX` (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/server_users.sql b/skeema/gradido_community/server_users.sql index 801eacef0..982a4bdc3 100644 --- a/skeema/gradido_community/server_users.sql +++ b/skeema/gradido_community/server_users.sql @@ -1,12 +1,12 @@ CREATE TABLE `server_users` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `username` varchar(50) NOT NULL, - `password` varchar(255) NOT NULL, - `email` varchar(50) NOT NULL, - `role` varchar(20) NOT NULL DEFAULT 'admin', - `activated` tinyint NOT NULL DEFAULT 0, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `username` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL, + `password` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL, + `email` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL, + `role` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'admin', + `activated` tinyint(4) NOT NULL DEFAULT '0', `last_login` datetime DEFAULT NULL, `created` datetime NOT NULL, `modified` datetime NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_balances.sql b/skeema/gradido_community/state_balances.sql index 9afb308ac..c8b013d44 100644 --- a/skeema/gradido_community/state_balances.sql +++ b/skeema/gradido_community/state_balances.sql @@ -1,7 +1,7 @@ CREATE TABLE `state_balances` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `state_user_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `state_user_id` int(10) unsigned NOT NULL, `modified` datetime NOT NULL, - `amount` bigint NOT NULL, + `amount` bigint(20) NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_created.sql b/skeema/gradido_community/state_created.sql index 05a2a8c97..5bc139594 100644 --- a/skeema/gradido_community/state_created.sql +++ b/skeema/gradido_community/state_created.sql @@ -1,11 +1,11 @@ CREATE TABLE `state_created` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transaction_id` int UNSIGNED NOT NULL, - `month` tinyint UNSIGNED NOT NULL, - `year` smallint UNSIGNED NOT NULL, - `state_user_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transaction_id` int(10) unsigned NOT NULL, + `month` tinyint(3) unsigned NOT NULL, + `year` smallint(5) unsigned NOT NULL, + `state_user_id` int(10) unsigned NOT NULL, `created` datetime NOT NULL, - `short_ident_hash` int UNSIGNED NOT NULL, + `short_ident_hash` int(10) unsigned NOT NULL, PRIMARY KEY (`id`), KEY `short_ident_hash` (`short_ident_hash`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_errors.sql b/skeema/gradido_community/state_errors.sql index 141e97562..8088f6ed2 100644 --- a/skeema/gradido_community/state_errors.sql +++ b/skeema/gradido_community/state_errors.sql @@ -1,8 +1,8 @@ CREATE TABLE `state_errors` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `state_user_id` int UNSIGNED NOT NULL, - `transaction_type_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `state_user_id` int(10) unsigned NOT NULL, + `transaction_type_id` int(10) unsigned NOT NULL, `created` datetime NOT NULL, - `message_json` text NOT NULL, + `message_json` text COLLATE utf8mb4_unicode_ci NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_group_addresses.sql b/skeema/gradido_community/state_group_addresses.sql index 38e8c36a8..1d256f3e0 100644 --- a/skeema/gradido_community/state_group_addresses.sql +++ b/skeema/gradido_community/state_group_addresses.sql @@ -1,7 +1,7 @@ CREATE TABLE `state_group_addresses` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `group_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `group_id` int(10) unsigned NOT NULL, `public_key` binary(32) NOT NULL, - `address_type_id` int UNSIGNED NOT NULL, + `address_type_id` int(10) unsigned NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_group_relationships.sql b/skeema/gradido_community/state_group_relationships.sql index 19f7f5752..d2eecbfc0 100644 --- a/skeema/gradido_community/state_group_relationships.sql +++ b/skeema/gradido_community/state_group_relationships.sql @@ -1,7 +1,7 @@ CREATE TABLE `state_group_relationships` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `group1_id` int UNSIGNED NOT NULL, - `group2_id` int UNSIGNED NOT NULL, - `state_relationship_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `group1_id` int(10) unsigned NOT NULL, + `group2_id` int(10) unsigned NOT NULL, + `state_relationship_id` int(10) unsigned NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_groups.sql b/skeema/gradido_community/state_groups.sql index 1ac95ec6c..30a810a19 100644 --- a/skeema/gradido_community/state_groups.sql +++ b/skeema/gradido_community/state_groups.sql @@ -1,8 +1,8 @@ CREATE TABLE `state_groups` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, `index_id` varbinary(64) NOT NULL, - `name` varchar(50) NOT NULL, + `name` varchar(50) COLLATE utf8mb4_unicode_ci NOT NULL, `root_public_key` binary(32) NOT NULL, - `user_count` smallint UNSIGNED NOT NULL DEFAULT 0, + `user_count` smallint(5) unsigned NOT NULL DEFAULT '0', PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_relationship_types.sql b/skeema/gradido_community/state_relationship_types.sql index 99c428afd..fd901b8ac 100644 --- a/skeema/gradido_community/state_relationship_types.sql +++ b/skeema/gradido_community/state_relationship_types.sql @@ -1,6 +1,6 @@ CREATE TABLE `state_relationship_types` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `name` varchar(25) NOT NULL, - `text` varchar(255) DEFAULT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `name` varchar(25) COLLATE utf8mb4_unicode_ci NOT NULL, + `text` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_user_roles.sql b/skeema/gradido_community/state_user_roles.sql new file mode 100644 index 000000000..5cbc2baac --- /dev/null +++ b/skeema/gradido_community/state_user_roles.sql @@ -0,0 +1,6 @@ +CREATE TABLE `state_user_roles` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `state_user_id` int(11) NOT NULL, + `role_id` int(11) NOT NULL, + PRIMARY KEY (`id`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/state_users.sql b/skeema/gradido_community/state_users.sql index ca1f4c022..706fa699e 100644 --- a/skeema/gradido_community/state_users.sql +++ b/skeema/gradido_community/state_users.sql @@ -1,13 +1,13 @@ CREATE TABLE `state_users` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `index_id` smallint NOT NULL DEFAULT 0, - `group_id` int UNSIGNED NOT NULL DEFAULT 0, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `index_id` smallint(6) NOT NULL DEFAULT '0', + `group_id` int(10) unsigned NOT NULL DEFAULT '0', `public_key` binary(32) NOT NULL, - `email` varchar(255) DEFAULT NULL, - `first_name` varchar(255) DEFAULT NULL, - `last_name` varchar(255) DEFAULT NULL, - `username` varchar(255) DEFAULT NULL, - `disabled` tinyint DEFAULT 0, + `email` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `first_name` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `last_name` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `username` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL, + `disabled` tinyint(4) DEFAULT '0', PRIMARY KEY (`id`), UNIQUE KEY `public_key` (`public_key`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transaction_creations.sql b/skeema/gradido_community/transaction_creations.sql index 0fcb92582..a2ff37539 100644 --- a/skeema/gradido_community/transaction_creations.sql +++ b/skeema/gradido_community/transaction_creations.sql @@ -1,9 +1,9 @@ CREATE TABLE `transaction_creations` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transaction_id` int UNSIGNED NOT NULL, - `state_user_id` int UNSIGNED NOT NULL, - `amount` bigint NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transaction_id` int(10) unsigned NOT NULL, + `state_user_id` int(10) unsigned NOT NULL, + `amount` bigint(20) NOT NULL, `ident_hash` binary(32) NOT NULL, `target_date` timestamp NULL DEFAULT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transaction_group_addaddress.sql b/skeema/gradido_community/transaction_group_addaddress.sql index 1c6fe826c..dceac273c 100644 --- a/skeema/gradido_community/transaction_group_addaddress.sql +++ b/skeema/gradido_community/transaction_group_addaddress.sql @@ -1,7 +1,7 @@ CREATE TABLE `transaction_group_addaddress` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transaction_id` int UNSIGNED NOT NULL, - `address_type_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transaction_id` int(10) unsigned NOT NULL, + `address_type_id` int(10) unsigned NOT NULL, `public_key` binary(32) NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transaction_group_allowtrades.sql b/skeema/gradido_community/transaction_group_allowtrades.sql index e2c299b34..923e0d5d0 100644 --- a/skeema/gradido_community/transaction_group_allowtrades.sql +++ b/skeema/gradido_community/transaction_group_allowtrades.sql @@ -1,7 +1,7 @@ CREATE TABLE `transaction_group_allowtrades` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transaction_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transaction_id` int(10) unsigned NOT NULL, `remote_group_id` varbinary(64) NOT NULL, - `allow` tinyint NOT NULL DEFAULT 0, + `allow` tinyint(4) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transaction_group_creates.sql b/skeema/gradido_community/transaction_group_creates.sql index afb8caf88..b5d7629b4 100644 --- a/skeema/gradido_community/transaction_group_creates.sql +++ b/skeema/gradido_community/transaction_group_creates.sql @@ -1,8 +1,8 @@ CREATE TABLE `transaction_group_creates` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transaction_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transaction_id` int(10) unsigned NOT NULL, `group_public_key` binary(32) NOT NULL, - `group_id` varchar(64) NOT NULL, - `name` varchar(64) NOT NULL, + `group_id` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL, + `name` varchar(64) COLLATE utf8mb4_unicode_ci NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transaction_send_coins.sql b/skeema/gradido_community/transaction_send_coins.sql index d55d57b51..f57a2175e 100644 --- a/skeema/gradido_community/transaction_send_coins.sql +++ b/skeema/gradido_community/transaction_send_coins.sql @@ -1,10 +1,10 @@ CREATE TABLE `transaction_send_coins` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transaction_id` int UNSIGNED NOT NULL, - `state_user_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transaction_id` int(10) unsigned NOT NULL, + `state_user_id` int(10) unsigned NOT NULL, `receiver_public_key` binary(32) NOT NULL, - `receiver_user_id` int UNSIGNED NOT NULL, - `amount` bigint NOT NULL, - `sender_final_balance` bigint NOT NULL, + `receiver_user_id` int(10) unsigned NOT NULL, + `amount` bigint(20) NOT NULL, + `sender_final_balance` bigint(20) NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transaction_signatures.sql b/skeema/gradido_community/transaction_signatures.sql index 2e8507c23..0c13b77da 100644 --- a/skeema/gradido_community/transaction_signatures.sql +++ b/skeema/gradido_community/transaction_signatures.sql @@ -1,7 +1,7 @@ CREATE TABLE `transaction_signatures` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `transaction_id` int UNSIGNED NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `transaction_id` int(10) unsigned NOT NULL, `signature` binary(64) NOT NULL, `pubkey` binary(32) NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transaction_types.sql b/skeema/gradido_community/transaction_types.sql index 4d1c13b55..87492e1fe 100644 --- a/skeema/gradido_community/transaction_types.sql +++ b/skeema/gradido_community/transaction_types.sql @@ -1,6 +1,6 @@ CREATE TABLE `transaction_types` ( - `id` int UNSIGNED NOT NULL AUTO_INCREMENT, - `name` varchar(24) NOT NULL, - `text` varchar(255) NOT NULL, + `id` int(10) unsigned NOT NULL AUTO_INCREMENT, + `name` varchar(24) COLLATE utf8mb4_unicode_ci NOT NULL, + `text` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/skeema/gradido_community/transactions.sql b/skeema/gradido_community/transactions.sql index c6072d20c..0e8c00ce6 100644 --- a/skeema/gradido_community/transactions.sql +++ b/skeema/gradido_community/transactions.sql @@ -1,9 +1,9 @@ CREATE TABLE `transactions` ( - `id` bigint UNSIGNED NOT NULL AUTO_INCREMENT, - `state_group_id` int UNSIGNED DEFAULT NULL, - `transaction_type_id` int UNSIGNED NOT NULL, + `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT, + `state_group_id` int(10) unsigned DEFAULT NULL, + `transaction_type_id` int(10) unsigned NOT NULL, `tx_hash` binary(32) DEFAULT NULL, - `memo` varchar(255) NOT NULL, - `received` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `memo` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL, + `received` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (`id`) -) ENGINE=InnoDB; +) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci; diff --git a/src/protobuf b/src/protobuf index 81a461566..9004e6978 160000 --- a/src/protobuf +++ b/src/protobuf @@ -1 +1 @@ -Subproject commit 81a461566e46d71533dc3e284fa075d7d68fd020 +Subproject commit 9004e6978ac3dafcc635b2ffcf8bc6a156451cca