Added Fabulous Cash sites.

This commit is contained in:
DebaucheryLibrarian
2023-04-06 01:28:59 +02:00
parent 5448100b3b
commit 54b1c03a8d
95 changed files with 156 additions and 24 deletions

View File

@@ -21,6 +21,7 @@ async function pgSettings(req) {
// console.log(PgAggregatesPlugin);
/*
const TagsAggregatePlugin = (builder) => {
builder.hook('build', (build) => {
const pgAggregateSpecs = [
@@ -29,8 +30,8 @@ const TagsAggregatePlugin = (builder) => {
humanLabel: 'tags',
HumanLabel: 'Tags',
sqlAggregateWrap: (sqlFrag) => {
console.log('sql frag', sqlFrag);
return build.pgSql.fragment`sum(${sqlFrag})`;
// console.log('sql frag', sqlFrag);
return build.pgSql.fragment`select tag_id from tags where release_id = ${sqlFrag}`;
},
isSuitableType: (pgType) => {
// console.log('pg type', pgType);
@@ -39,9 +40,12 @@ const TagsAggregatePlugin = (builder) => {
},
];
build.pgAggregateSpecs = pgAggregateSpecs; // eslint-disable-line no-param-reassign
build.pgAggregateGroupBySpecs = pgAggregateSpecs; // eslint-disable-line no-param-reassign
return build;
});
};
*/
module.exports = postgraphile(
connectionString,
@@ -69,7 +73,7 @@ module.exports = postgraphile(
...SitePlugins,
...ReleasePlugins,
...MediaPlugins,
TagsAggregatePlugin,
// TagsAggregatePlugin,
],
pgSettings,
},