~evanj/cms

4e6befbb576c2e14bcbb5b05e127ae40c9c6073e — Evan J 2 months ago b8638df
Fix(hook service): Hook service was broke for list of hooks. Encapsulate
in anonymous func to fix.
M internal/s/db/migrations_embed.go => internal/s/db/migrations_embed.go +2 -2
@@ 14,11 14,11 @@ func tostring(in string) string {
func init() {
	migrations = make(map[string]string)

	migrations["sql/00001.sql"] = tostring("Q1JFQVRFIFRBQkxFIGNtc19taWdyYXRlICgKCUlEIElOVEVHRVIgUFJJTUFSWSBLRVkgQVVUT19JTkNSRU1FTlQsCglOQU1FIHZhcmNoYXIoMjU2KSBVTklRVUUgTk9UIE5VTEwsCiAgREFURSBUSU1FU1RBTVAgTk9UIE5VTEwgREVGQVVMVCBDVVJSRU5UX1RJTUVTVEFNUAopOwoKQ1JFQVRFIFRBQkxFIGNtc191c2VyICgKCUlEIElOVEVHRVIgUFJJTUFSWSBLRVkgQVVUT19JTkNSRU1FTlQsCglOQU1FIHZhcmNoYXIoMjU2KSBVTklRVUUgTk9UIE5VTEwsCglIQVNIIHZhcmNoYXIoMjU2KSBOT1QgTlVMTAopOwoKQ1JFQVRFIFRBQkxFIGNtc19zcGFjZSAoCglJRCBJTlRFR0VSIFBSSU1BUlkgS0VZIEFVVE9fSU5DUkVNRU5ULAoJTkFNRSB2YXJjaGFyKDI1NikgTk9UIE5VTEwsCglERVNDUklQVElPTiB2YXJjaGFyKDI1NikgTk9UIE5VTEwKKTsKCkNSRUFURSBUQUJMRSBjbXNfdXNlcl90b19zcGFjZSAoCglJRCBJTlRFR0VSIFBSSU1BUlkgS0VZIEFVVE9fSU5DUkVNRU5ULAoJVVNFUl9JRCBJTlRFR0VSIE5PVCBOVUxMLAoJU1BBQ0VfSUQgSU5URUdFUiBOT1QgTlVMTCwKCUZPUkVJR04gS0VZKFVTRVJfSUQpIFJFRkVSRU5DRVMgY21zX3VzZXIoSUQpLAoJRk9SRUlHTiBLRVkoU1BBQ0VfSUQpIFJFRkVSRU5DRVMgY21zX3NwYWNlKElE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VSIFRBQkxFIGNtc19vcmcgRFJPUCBDT0xVTU4gQk9HVVNfVVNFUl9JRDsKCkFMVEVSIFRBQkxFIGNtc191c2VyIEFERCBDT05TVFJBSU5UIENNU19VU0VSX09SR19JRF9GSyBGT1JFSUdOIEtFWShPUkdfSUQpIFJFRkVSRU5DRVMgY21zX29yZyhJRCk7CgpBTFRFUiBUQUJMRSBjbXNfc3BhY2UgQUREIE9SR19JRCBJTlRFR0VSIE5PVCBOVUxMOwoKVVBEQVRFIGNtc19zcGFjZQpKT0lOIGNtc191c2VyX3RvX3NwYWNlIE9OIFNQQUNFX0lEPWNtc19zcGFjZS5JRCAKSk9JTiBjbXNfdXNlciBPTiBVU0VSX0lEPWNtc191c2VyLklECkpPSU4gY21zX29yZyBPTiBjbXNfdXNlci5PUkdfSUQ9Y21zX29yZy5JRApTRVQgY21zX3NwYWNlLk9SR19JRD1jbXNfb3JnLklEOwoKQUxURVIgVEFCTEUgY21zX3NwYWNlIEFERCBDT05TVFJBSU5UIENNU19TUEFDRV9PUkdfSURfRksgRk9SRUlHTiBLRVkoT1JHX0lEKSBSRUZFUkVOQ0VTIGNtc19vcmcoSUQpOwoKRFJPUCBUQUJMRSBjbXNfdXNlcl90b19zcGFjZTsK")

	migrations["sql/00004.sql"] = tostring("Q1JFQVRFIFRBQkxFIGNtc19iaWxsaW5nICgKCUlEIElOVEVHRVIgUFJJTUFSWSBLRVkgQVVUT19JTkNSRU1FTlQsCiAgUEFZTUVOVF9DVVNUT01FUiB2YXJjaGFyKDI1NikgTk9UIE5VTEwsCiAgVElFUl9OQU1FIHZhcmNoYXIoMjU2KSBOT1QgTlVMTCwKICBPUkdfSUQgSU5URUdFUiBOT1QgTlVMTCwKICBDT05TVFJBSU5UIENNU19CSUxMSU5HX1RPX09SR19GSyBGT1JFSUdOIEtFWShPUkdfSUQpIFJFRkVSRU5DRVMgY21zX29yZyhJRCkKKTsKCg==")


M internal/s/db/sql/00001.sql => internal/s/db/sql/00001.sql +0 -2
@@ 76,8 76,6 @@ CREATE TABLE cms_value_date (
	VALUE DATE NOT NULL
);

-- TODO: Reconsider these ON DELETE CASCADES after this point.

CREATE TABLE cms_value_reference (
	ID INTEGER PRIMARY KEY AUTO_INCREMENT,
	VALUE INTEGER NOT NULL,

M internal/s/db/sql/00003.sql => internal/s/db/sql/00003.sql +0 -8
@@ 4,12 4,8 @@ CREATE TABLE cms_org (
	CONSTRAINT BOGUS_USER_ID_FK FOREIGN KEY(BOGUS_USER_ID) REFERENCES cms_user(ID) ON DELETE CASCADE
);

-- Fix user to org.

ALTER TABLE cms_user ADD ORG_ID INTEGER NOT NULL;

-- NOTE: At this point in time we haven't supported user<->space.

INSERT INTO cms_org (BOGUS_USER_ID)
SELECT cms_user.ID FROM cms_user;



@@ 22,8 18,6 @@ ALTER TABLE cms_org DROP COLUMN BOGUS_USER_ID;

ALTER TABLE cms_user ADD CONSTRAINT CMS_USER_ORG_ID_FK FOREIGN KEY(ORG_ID) REFERENCES cms_org(ID);

-- Fix space to org.

ALTER TABLE cms_space ADD ORG_ID INTEGER NOT NULL;

UPDATE cms_space


@@ 34,6 28,4 @@ SET cms_space.ORG_ID=cms_org.ID;

ALTER TABLE cms_space ADD CONSTRAINT CMS_SPACE_ORG_ID_FK FOREIGN KEY(ORG_ID) REFERENCES cms_org(ID);

-- Drop extras.

DROP TABLE cms_user_to_space;

M internal/s/hook/hook.go => internal/s/hook/hook.go +6 -4
@@ 99,10 99,12 @@ func (h *Hook) Do(user user.User, space space.Space, content content.Content, ht
		}
		before = hooks.Before()

		for _, hook := range hooks.List() {
			eg.Go(func() error {
				return h.do(ctx, content, hook, ht)
			})
		for _, item := range hooks.List() {
			func(hook hook.Hook) {
				eg.Go(func() error {
					return h.do(ctx, content, hook, ht)
				})
			}(item)
		}

		if err := eg.Wait(); err != nil {

M internal/v/html/stripe.html => internal/v/html/stripe.html +1 -1
@@ 14,7 14,7 @@
    {{ template "html/_footer.html" $ }}
  </main>
  {{ template "html/_scripts.html" }}
  <script src="//js.stripe.com/v3/"></script>
  <script src="https://js.stripe.com/v3/"></script>
  <script>
    (function() { 
      var stripe = Stripe('{{.StripePK}}');

M internal/v/tmpls_embed.go => internal/v/tmpls_embed.go +1 -1
@@ 52,7 52,7 @@ func init() {

	tmpls["html/space.html"] = tostring("PCFET0NUWVBFIGh0bWw+CjxodG1sIGxhbmc9ZW4+CjxoZWFkPgogIHt7IHRlbXBsYXRlICJodG1sL19oZWFkLmh0bWwiIH19CiAgPHRpdGxlPlNraXBwZXIgQ01TIHwge3sgLlNwYWNlLk5hbWUgfX08L3RpdGxlPgo8L2hlYWQ+Cjxib2R5IGNsYXNzPSdzcGFjZSBiZy1saWdodCc+CiAgPHN0eWxlPnt7IHRlbXBsYXRlICJjc3MvbWFpbi5jc3MiIH19PC9zdHlsZT4KICA8bWFpbj4KICAgIHt7IHRlbXBsYXRlICJodG1sL19oZWFkZXIuaHRtbCIgJCB9fQogICAgPGRpdiBjbGFzcz0icHJpY2luZy1oZWFkZXIgcHgtMyBweS0zIHB0LW1kLTUgcGItbWQtNCBteC1hdXRvIHRleHQtY2VudGVyIj4KICAgICAgPGgxIGNsYXNzPSJkaXNwbGF5LTQiPnt7LlNwYWNlLk5hbWV9fTwvaDE+CiAgICAgIDxwIGNsYXNzPSJsZWFkIj57ey5TcGFjZS5EZXNjfX08L3A+CiAgICA8L2Rpdj4KICAgIDxhcnRpY2xlPgogICAgICA8Zm9ybSBtZXRob2Q9UE9TVCBhY3Rpb249Jy9jb250ZW50dHlwZScgZW5jdHlwZT0nbXVsdGlwYXJ0L2Zvcm0tZGF0YSc+CiAgICAgICAgPGlucHV0IHR5cGU9aGlkZGVuIG5hbWU9bWV0aG9kIHZhbHVlPVBPU1QgLz4KICAgICAgICA8aW5wdXQgcmVxdWlyZWQgdHlwZT1oaWRkZW4gbmFtZT1zcGFjZSB2YWx1ZT0ie3sgLlNwYWNlLklEIH19IiAvPgogICAgICAgIDxkaXYgY2xhc3M9Im1vZGFsIGZhZGUiI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hc3M9J2NvbnRhaW5lci1mbHVpZCBweC0wIG1iLTMnPgogICAgICAgICAgICAgICAgICA8bGFiZWwgZm9yPSJmaWVsZHNldEZpcnN0Ij5GaWVsZHM8L2xhYmVsPgogICAgICAgICAgICAgICAgICA8aW5wdXQgaWQ9ImZpZWxkc2V0Rmlyc3QiIGNsYXNzPSJtYi0zIGZvcm0tY29udHJvbCIgcmVhZG9ubHk9InJlYWRvbmx5IiByZXF1aXJlZCB0eXBlPXRleHQgbmFtZT0iZmllbGRfbmFtZV8xIiB2YWx1ZT0ibmFtZSIgLz4KICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz0nZm9ybS1ncm91cCByb3cnPgogICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9J2NvbC02Jz4KICAgICAgICAgICAgICAgICAgICAgIDxzZWxlY3QgY2xhc3M9InctMTAwIGZvcm0tY29udHJvbCIgcmVhZG9ubHk9InJlYWRvbmx5IiByZXF1aXJlZCBuYW1lPSJmaWVsZF90eXBlXzEiPgogICAgICAgICAgICAgICAgICAgICAgICA8b3B0aW9uIGRpc2FibGVkIHZhbHVlPkZpZWxkIFR5cGU8L29wdGlvbj4KICAgICAgICAgICAgICAgICAgICAgICAgPG9wdGlvbiBzZWxlY3RlZCB2YWx1ZT0iU3RyaW5nU21hbGwiPlN0cmluZyBTbWFsbDwvb3B0aW9uPgogICAgICAgICAgICAgICAgICAgICAgICA8b3B0aW9uIGRpc2FibGVkIHZhbHVlPSJTdHJpbmdCaWciPlN0cmluZyBCaWc8L29wdGlvbj4KICAgICAgICAgICAgICAgICAgICAgICAgPG9wdGlvbiBkaXNhYmxlZCB2YWx1ZT0iSW5wdXRIVE1MIj5IVE1MPC9vcHRpb24+CiAgICAgICAgICAgICAgICAgICAgICAgIDxvcHRpb24gZGlzYWJsZWQgdmFsdWU9IklucHV0TWFya2Rvd24iPk1hcmtkb3duPC9vcHRpb24+CiAgICAgICAgICAgICAgICAgICAgICAgIDxvcHRpb24gZGlzYWJsZWQgdmFsdWU9IkZpbGUiPkZpbGU8L29wdGlvbj4KICAgICAgICAgICAgICAgICAgICAgICAgPG9wdGlvbiBkaXNhYmxlZCB2YWx1ZT0iRGF0ZSI+RGF0ZTwvb3B0aW9uPgogICAgICAgICAgICAgICAgICAgICAgICA8b3B0aW9uIGRpc2FibGVkIHZhbHVlPSJSZWZlcmVuY2UiPlJlZmVyZW5jZTwvb3B0aW9uPgogICAgICAgICAgICAgICAgICAgICAgICA8b3B0aW9uIGRpc2FibGVkIHZhbHVlPSJSZWZlcmVuY2VMaXN0Ij5SZWZlcmVuY2VMaXN0PC9vcHRpb24+CiAgICAgICAgICAgICAgICAgICAgICA8L3NlbGVjdD4KICAgICAgICAgICAgICAgICAgICA8L2Rpdj4KICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPSdjb2wtNic+CiAgICAgICAgICAgICAgICAgICAgICA8YnV0dG9uIGNsYXNzPSd3LTEwMCBidG4gYnRuLXByaW1hcnknIGRpc2FibGVkIHR5cGU9YnV0dG9uPlJlbW92ZSBGaWVsZDwvYnV0dG9uPgogICAgICAgICAgICAgICAgICAgIDwvZGl2PgogICAgICAgICAgICAgICAgICA8L2Rpdj4KICAgICAgICAgICAgICAgIDwvZGl2PgogICAgICAgICAgICAgICAgPGEgaHJlZj0nIycgY2xhc3M9J2J0biBidG4tbGluaycgaWQ9J2FkZC1maWVsZGJ0bic+QWRkIEFub3RoZXIgRmllbGQ8L2E+CiAgICAgICAgICAgICAgPC9kaXY+CiAgICAgICAgICAgICAgPGRpdiBjbGFzcz0ibW9kYWwtZm9vdGVyIj4KICAgICAgICAgICAgICAgIDxidXR0b24gdHlwZT0iYnV0dG9uIiBjbGFzcz0iYnRuIGJ0bi1zZWNvbmRhcnkiIGRhdGEtZGlzbWlzcz0ibW9kYWwiPkNsb3NlPC9idXR0b24+CiAgICAgICAgICAgICAgICA8YnV0dG9uIHR5cGU9InN1Ym1pdCIgY2xhc3M9ImJ0biBidG4tcHJpbW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wvYT4KICAgICAgICAgICAgICAgIDwvc21hbGw+CiAgICAgICAgICAgICAgPGg2IGNsYXNzPSJib3JkZXItYm90dG9tIGJvcmRlci1ncmF5IHBiLTIgbWItMCI+WW91ciBjb250ZW50IHR5cGVzPC9oNj4KICAgICAgICAgICAgICB7eyBpZiAuQ29udGVudFR5cGVzLkxpc3QgfX0KICAgICAgICAgICAgICAgIHt7IHJhbmdlIC5Db250ZW50VHlwZXMuTGlzdCB9fQogICAgICAgICAgICAgICAgPGRpdiBjbGFzcz0ibWVkaWEgdGV4dC1tdXRlZCBwdC0zIj4KICAgICAgICAgICAgICAgICAgPGEgaHJlZj0nL2NvbnRlbnR0eXBlL3t7ICQuU3BhY2UuSUQgfX0ve3sgLklEIH19JyAgY2xhc3M9ImQtYmxvY2sgbWVkaWEtYm9keSBwYi0zIG1iLTAgc21hbGwgbGgtMTI1IGJvcmRlci1ib3R0b20gYm9yZGVyLWdyYXkiPgogICAgICAgICAgICAgICAgICAgIDxzdHJvbmcgY2xhc3M9ImQtYmxvY2sgdGV4dC1ncmF5LWRhcmsiPnt7IC5OYW1lIH19PC9zdHJvbmc+CiAgICAgICAgICAgICAgICAgIDwvYT4KICAgICAgICAgICAgICAgIDwvZGl2PgogICAgICAgICAgICAgICAge3sgZW5kIH19CiAgICAgICAgICAgICAgICB7eyBpZiAuQ29udGVudFR5cGVzLk1vcmUgfX0KICAgICAgICAgICAgICAgIDxzbWFsbCBjbGFzcz0iZC1ibG9jayB0ZXh0LXJpZ2h0IG10LTMiPgogICAgICAgICAgICAgICAgICA8YSBocmVmPSIvc3BhY2Uve3sgLlNwYWNlLklEIH19P2JlZm9yZWN0PXt7IC5Db250ZW50VHlwZXMuQmVmb3JlIH19Ij5Mb2FkIG1vcmU8L2E+CiAgICAgICAgICAgICAgICA8L3NtYWxsPgogICAgICAgICAgICAgICAge3sgZW5kIH19CiAgICAgICAgICAgICAge3sgZWxzZSB9fQogICAgICAgICAgICAgICAgPGRpdiBjbGFzcz0ib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