mirror of
https://we.phorge.it/source/phorge.git
synced 2024-12-29 08:50:58 +01:00
6d6211d441
Summary: Ref T8498. I want to add Spaces to these, and the logic for getting Spaces right is a bit tricky, so swap these to ApplicationTransactions. One new piece of tech: made it easier for Editors to raise DuplicateKeyException as a normal ValidationException, so callers don't have to handle this case specially. One behavioral change: we no longer require these addresses to be at the `auth.email-domains` domains -- I think this wasn't quite right in the general case. It's OK to require users to have `@mycompany.com` addresses but add `@phabricator.mycompany-infrastructure.com` addresses here if you want. Test Plan: - Tried to create a duplicate email. - Tried to create an empty email. - Tried to create an invalid email. - Created a new email. - Deleted an email. Reviewers: btrahan Reviewed By: btrahan Subscribers: epriestley Maniphest Tasks: T8498 Differential Revision: https://secure.phabricator.com/D13246
19 lines
858 B
SQL
19 lines
858 B
SQL
CREATE TABLE {$NAMESPACE}_metamta.metamta_applicationemailtransaction (
|
|
id INT UNSIGNED NOT NULL AUTO_INCREMENT PRIMARY KEY,
|
|
phid VARBINARY(64) NOT NULL,
|
|
authorPHID VARBINARY(64) NOT NULL,
|
|
objectPHID VARBINARY(64) NOT NULL,
|
|
viewPolicy VARBINARY(64) NOT NULL,
|
|
editPolicy VARBINARY(64) NOT NULL,
|
|
commentPHID VARBINARY(64) DEFAULT NULL,
|
|
commentVersion INT UNSIGNED NOT NULL,
|
|
transactionType VARCHAR(32) COLLATE {$COLLATE_TEXT} NOT NULL,
|
|
oldValue LONGTEXT COLLATE {$COLLATE_TEXT} NOT NULL,
|
|
newValue LONGTEXT COLLATE {$COLLATE_TEXT} NOT NULL,
|
|
contentSource LONGTEXT COLLATE {$COLLATE_TEXT} NOT NULL,
|
|
metadata LONGTEXT COLLATE {$COLLATE_TEXT} NOT NULL,
|
|
dateCreated INT UNSIGNED NOT NULL,
|
|
dateModified INT UNSIGNED NOT NULL,
|
|
UNIQUE KEY `key_phid` (`phid`),
|
|
KEY `key_object` (`objectPHID`)
|
|
) ENGINE=InnoDB, COLLATE {$COLLATE_TEXT};
|