Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MMI-3116 Update Source and Series CBRA source #2354

Merged
merged 5 commits into from
Dec 5, 2024
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file not shown.
2 changes: 1 addition & 1 deletion app/editor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"redux-logger": "3.0.6",
"styled-components": "6.1.11",
"stylis": "4.3.2",
"tno-core": "0.1.152"
"tno-core": "0.1.153"
},
"devDependencies": {
"@simbathesailor/use-what-changed": "2.0.0",
Expand Down
1 change: 1 addition & 0 deletions app/editor/src/features/admin/series/SeriesDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ const SeriesDetails: React.FC = () => {
<FormikCheckbox label="Is Enabled" name="isEnabled" />
<FormikCheckbox label="Use in Topics" name="useInTopics" />
<FormikCheckbox label="Automatically transcribe when saved" name="autoTranscribe" />
<FormikCheckbox label="Is CBRA Source" name="isCBRASource" />
</Col>
<Show visible={!!values.id}>
<Row>
Expand Down
7 changes: 7 additions & 0 deletions app/editor/src/features/admin/series/constants/columns.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,11 @@ export const columns: ITableHookColumn<ISeriesModel>[] = [
hAlign: 'center',
cell: (cell) => <CellCheckbox checked={cell.original.isEnabled} />,
},
{
label: 'Is CBRA Source',
accessor: 'isCBRASource',
width: 1,
hAlign: 'center',
cell: (cell) => <CellCheckbox checked={cell.original.isCBRASource} />,
},
];
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@ export const defaultSeries: ISeriesForm = {
sortOrder: 0,
autoTranscribe: false,
useInTopics: false,
isCBRASource: false,
};
1 change: 1 addition & 0 deletions app/editor/src/features/admin/sources/SourceDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ const SourceDetails: React.FC<ISourceDetailsProps> = () => {
<FormikCheckbox label="Default filter for papers" name="configuration.isDailyPaper" />
<FormikCheckbox label="Automatically transcribe when saved" name="autoTranscribe" />
<FormikCheckbox label="Disable transcript requests" name="disableTranscribe" />
<FormikCheckbox label="Is CBRA Source" name="isCBRASource" />
</Col>
</styled.SourceDetails>
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,5 @@ export const defaultSource: ISourceForm = {
},
actions: [],
metrics: [],
isCBRASource: false,
};
10 changes: 5 additions & 5 deletions app/editor/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -11009,7 +11009,7 @@ __metadata:
sass-extract-loader: 1.1.0
styled-components: 6.1.11
stylis: 4.3.2
tno-core: 0.1.152
tno-core: 0.1.153
typescript: 4.9.5
languageName: unknown
linkType: soft
Expand Down Expand Up @@ -15184,9 +15184,9 @@ __metadata:
languageName: node
linkType: hard

"tno-core@npm:0.1.152":
version: 0.1.152
resolution: "tno-core@npm:0.1.152"
"tno-core@npm:0.1.153":
version: 0.1.153
resolution: "tno-core@npm:0.1.153"
dependencies:
"@elastic/elasticsearch": ^8.13.1
"@fortawesome/free-solid-svg-icons": ^6.4.2
Expand Down Expand Up @@ -15219,7 +15219,7 @@ __metadata:
styled-components: ^6.1.11
stylis: ^4.3.2
yup: ^1.1.1
checksum: 8bfd08dac5674f43ebd2212d646fb82f12bee3f28c21ec6f588623362bc569c9e631e3efb8881c252b3c5b1c5ef94e7923af2a450100d5ad7dfcc35737c8108d
checksum: 1c8fb17596519ce1c2eda297439cfae4468c33fd6c77d29697de1d6515659695ffded7b4994ce9b5949b8a904671b55c497e8cffdc39ca49a7914324f369aea0
languageName: node
linkType: hard

Expand Down
Binary file not shown.
2 changes: 1 addition & 1 deletion app/subscriber/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
"sheetjs": "file:packages/xlsx-0.20.1.tgz",
"styled-components": "6.1.11",
"stylis": "4.3.2",
"tno-core": "0.1.152"
"tno-core": "0.1.153"
},
"devDependencies": {
"@testing-library/jest-dom": "6.4.5",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ export const generateSeries = (options: IGenerateSeriesOptions) => {
isOther: false,
autoTranscribe: false,
useInTopics: false,
isCBRASource: false,
...options.init,
};
return entity;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export const generateSource = (options: IGenerateSourceOptions) => {
configuration: {},
actions: [],
metrics: [],
isCBRASource: false,
...options.init,
};
return entity;
Expand Down
10 changes: 5 additions & 5 deletions app/subscriber/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -10665,7 +10665,7 @@ __metadata:
sheetjs: "file:packages/xlsx-0.20.1.tgz"
styled-components: 6.1.11
stylis: 4.3.2
tno-core: 0.1.152
tno-core: 0.1.153
typescript: 4.9.5
languageName: unknown
linkType: soft
Expand Down Expand Up @@ -14698,9 +14698,9 @@ __metadata:
languageName: node
linkType: hard

"tno-core@npm:0.1.152":
version: 0.1.152
resolution: "tno-core@npm:0.1.152"
"tno-core@npm:0.1.153":
version: 0.1.153
resolution: "tno-core@npm:0.1.153"
dependencies:
"@elastic/elasticsearch": ^8.13.1
"@fortawesome/free-solid-svg-icons": ^6.4.2
Expand Down Expand Up @@ -14733,7 +14733,7 @@ __metadata:
styled-components: ^6.1.11
stylis: ^4.3.2
yup: ^1.1.1
checksum: 8bfd08dac5674f43ebd2212d646fb82f12bee3f28c21ec6f588623362bc569c9e631e3efb8881c252b3c5b1c5ef94e7923af2a450100d5ad7dfcc35737c8108d
checksum: 1c8fb17596519ce1c2eda297439cfae4468c33fd6c77d29697de1d6515659695ffded7b4994ce9b5949b8a904671b55c497e8cffdc39ca49a7914324f369aea0
languageName: node
linkType: hard

Expand Down
1 change: 1 addition & 0 deletions libs/net/dal/Configuration/SeriesConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ public override void Configure(EntityTypeBuilder<Series> builder)
builder.Property(m => m.SourceId).IsRequired(false);
builder.Property(m => m.AutoTranscribe).IsRequired();
builder.Property(m => m.UseInTopics).IsRequired();
builder.Property(m => m.IsCBRASource).IsRequired();

builder.HasOne(m => m.Source).WithMany(m => m.Series).HasForeignKey(m => m.SourceId).OnDelete(DeleteBehavior.Cascade);
builder.HasMany(m => m.MediaTypeSearchMappings).WithMany(m => m.SeriesSearchMappings).UsingEntity<SeriesMediaTypeSearchMapping>();
Expand Down
1 change: 1 addition & 0 deletions libs/net/dal/Configuration/SourceConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ public override void Configure(EntityTypeBuilder<Source> builder)
builder.Property(m => m.DisableTranscribe).IsRequired();
builder.Property(m => m.UseInTopics).IsRequired();
builder.Property(m => m.Configuration).IsRequired().HasColumnType("jsonb").HasDefaultValueSql("'{}'::jsonb");
builder.Property(m => m.IsCBRASource).IsRequired();

builder.HasOne(m => m.Owner).WithMany().HasForeignKey(m => m.OwnerId).OnDelete(DeleteBehavior.SetNull);
builder.HasOne(m => m.License).WithMany(m => m.Sources).HasForeignKey(m => m.LicenseId).OnDelete(DeleteBehavior.Restrict);
Expand Down
Loading
Loading