Commits

jbe  committed b635156

Added column "notify_email_lock_expiry"; Corrected "manual_freeze" comment

  • Participants
  • Parent commits 964cab0
  • Tags v1.1.0

Comments (0)

Files changed (2)

         "notify_email_unconfirmed"     TEXT,
         "notify_email_secret"          TEXT     UNIQUE,
         "notify_email_secret_expiry"   TIMESTAMPTZ,
+        "notify_email_lock_expiry"     TIMESTAMPTZ,
         "password_reset_secret"        TEXT     UNIQUE,
         "password_reset_secret_expiry" TIMESTAMPTZ,
         "name"                  TEXT            NOT NULL UNIQUE,
 COMMENT ON COLUMN "member"."notify_email_unconfirmed"   IS 'Unconfirmed email address provided by the member to be copied into "notify_email" field after verification';
 COMMENT ON COLUMN "member"."notify_email_secret"        IS 'Secret sent to the address in "notify_email_unconformed"';
 COMMENT ON COLUMN "member"."notify_email_secret_expiry" IS 'Expiry date/time for "notify_email_secret"';
+COMMENT ON COLUMN "member"."notify_email_lock_expiry"   IS 'Date/time until no further email confirmation mails may be sent (abuse protection)';
 COMMENT ON COLUMN "member"."name"                 IS 'Distinct name of the member';
 COMMENT ON COLUMN "member"."identification"       IS 'Optional identification number or code of the member';
 COMMENT ON COLUMN "member"."organizational_unit"  IS 'Branch or division of the organization the member belongs to';
     END;
   $$;
 
-COMMENT ON FUNCTION "freeze_after_snapshot"
+COMMENT ON FUNCTION "manual_freeze"
   ( "issue"."id"%TYPE )
   IS 'Freeze an issue manually (fully) and start voting';
 

File update/core-update.v1.0.3-v1.1.0.sql

   SELECT * FROM (VALUES ('1.1.0', 1, 1, 0))
   AS "subquery"("string", "major", "minor", "revision");
 
+ALTER TABLE "member" ADD COLUMN "notify_email_lock_expiry" TIMESTAMPTZ;
+COMMENT ON COLUMN "member"."notify_email_lock_expiry" IS 'Date/time until no further email confirmation mails may be sent (abuse protection)';
+
 ALTER TABLE "direct_population_snapshot" DROP COLUMN "interest_exists";
 
 CREATE OR REPLACE FUNCTION "create_population_snapshot"
     END;
   $$;
 
+COMMENT ON FUNCTION "freeze_after_snapshot"
+  ( "issue"."id"%TYPE )
+  IS 'This function freezes an issue (fully) and starts voting, but must only be called when "create_snapshot" was called in the same transaction.';
+
+COMMENT ON FUNCTION "manual_freeze"
+  ( "issue"."id"%TYPE )
+  IS 'Freeze an issue manually (fully) and start voting';
+
 DROP FUNCTION "delete_member_data"("member"."id"%TYPE);
 
 CREATE FUNCTION "delete_member"("member_id_p" "member"."id"%TYPE)