Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
207 commits
Select commit Hold shift + click to select a range
ef05fce
Draft for meeting registrations
evyncke Mar 14, 2026
a0fd930
Add totals, + nicer JS code
evyncke Mar 14, 2026
7dfa8d4
Coherent URL parameters
evyncke Mar 14, 2026
25c79a5
Handle error case when per-continent stats is requested
evyncke Mar 14, 2026
557291f
Remove redundant code
evyncke Mar 14, 2026
ebc4bdc
Dynamic get the current IETF meeting
evyncke Mar 14, 2026
2e55643
Display %-age when hovering
evyncke Mar 14, 2026
ac4f28e
Add test for meeting statistics
evyncke Mar 15, 2026
62a6784
Add test
evyncke Mar 16, 2026
14780b9
Add statistics per affiliation
evyncke Mar 16, 2026
90aa3ac
More code coverage for test
evyncke Mar 16, 2026
dd64825
Merge branch 'main' into feat-statistics
evyncke Mar 16, 2026
b159b48
Nicer canonical affiliation
evyncke Mar 16, 2026
b0d2842
Allow navigation by buttons
evyncke Mar 16, 2026
fa4354f
Merge branch 'main' into feat-statistics
evyncke Mar 17, 2026
e41a545
Also add participants count in the legend
evyncke Mar 17, 2026
19233d4
Add timeline over meetings (total and per country)
evyncke Mar 24, 2026
c294660
Merge branch 'main' into feat-statistics
evyncke Mar 24, 2026
94e00ac
Default index refers to current meeting stats by number
evyncke Mar 25, 2026
8a989e0
Remove unused JS code
evyncke Mar 25, 2026
0067933
Add test coverage for timeline statistics
evyncke Mar 25, 2026
f803986
No need to import test coverage
evyncke Mar 25, 2026
c8adc61
Use stacked lines of onsite/remote when displaying the total timeline
evyncke Mar 25, 2026
beb2424
fix a comment
evyncke Mar 25, 2026
9fb3ab7
Add timeline for affiliation
evyncke Mar 26, 2026
582a9b7
Expanding the test coverage to affiliation timeline
evyncke Mar 26, 2026
46c0901
Remove unused botocore (unsure how it was added though)
evyncke Mar 26, 2026
76f9b6a
Remove unused package
evyncke Mar 26, 2026
eeb28c6
Code clean-up, add pan & zoom on timelines
evyncke Mar 27, 2026
1d1c209
Fix button type
evyncke Mar 27, 2026
27e77d2
Very first draft
evyncke Apr 1, 2026
7e964e9
Use pub_date() also for streams stats
evyncke Apr 2, 2026
9018d68
Don't fill the graphics
evyncke Apr 28, 2026
8585901
Merge remote-tracking branch 'upstream/main' into feat-doc-stats
evyncke Apr 30, 2026
7f7c12f
Also display active 'All' button
evyncke Apr 30, 2026
9d6350c
Consistent color scheme for country/affiliation
evyncke Apr 30, 2026
7a1272f
Merge remote-tracking branch 'upstream/main' into feat-doc-stats
evyncke May 3, 2026
4827450
No need for autocolor anymore
evyncke May 3, 2026
b8adc9c
More explanations about chart.js
evyncke May 3, 2026
66ba85b
More colors to reduce collision
evyncke May 3, 2026
d2df794
Split authors/documents stats
evyncke May 3, 2026
f8d3e4d
Complete separation of docs & authors stats
evyncke May 3, 2026
acf5bb6
Polishing statistics on authors
evyncke May 3, 2026
c26b64c
More explanations about shown data
evyncke May 3, 2026
d851e59
Add RFC category and draft intended status
evyncke May 4, 2026
e942fdc
Support displaying WG stats
evyncke May 4, 2026
3b3989d
Update since autocolor from chart.js was removed
evyncke May 4, 2026
11d2b06
Fix typo
evyncke May 5, 2026
f4cc0c5
Tests for documents timelines
evyncke May 5, 2026
9250bea
Authors statistics tests completed
evyncke May 5, 2026
a9f33a7
Merge branch 'main' into feat-doc-stats
evyncke May 5, 2026
2836321
Require Alt for all pan/scroll
evyncke May 9, 2026
e510419
Working draft for totals in addition to timeline
evyncke May 9, 2026
533f35e
JS for the total statistics
evyncke May 9, 2026
e87de05
Hide clicked on bar and rescale
evyncke May 10, 2026
9f9b6a1
Display all bar legends even if many of them
evyncke May 10, 2026
0ebe055
Add AffiliationMainName model + initial content
evyncke May 10, 2026
32aff47
AffiliationMainName migration
evyncke May 10, 2026
435cce6
Pass the "top-n" value as a query parameter
evyncke May 10, 2026
7339d41
Less debug logging
evyncke May 10, 2026
98bc837
More affiliations clean-up/canonicalizations
evyncke May 10, 2026
8530e34
Force the use of Alt for all mouse moves
evyncke May 11, 2026
961c5de
Only use the affiliation aliases from utils (and the DB)
evyncke May 11, 2026
5f58319
No need for ordering in AffiliationMainName and more country aliases
evyncke May 11, 2026
163db7e
Only use aliases (country & affiliation) in utils and no more hardcoded
evyncke May 11, 2026
cb96f26
Avoid overlapping labels
evyncke May 11, 2026
5eb117c
Handle top_n for documents timeline
evyncke May 11, 2026
6346066
ID field is automatic
evyncke May 11, 2026
70f02df
Add Alias Main Name for API
evyncke May 11, 2026
46eab55
Create the id field at migration time, remove the main_name is unique
evyncke May 11, 2026
6669c24
Fix the migration (verbose_name typo and unique=True)
evyncke May 11, 2026
e9fa928
Update tests for the country/affiliation aliases
evyncke May 11, 2026
53136b2
Use & rather than "&"
evyncke May 11, 2026
770948a
URL contains plural meetings for the timeline graphics
evyncke May 11, 2026
9adc330
Add top_n for meetings timeline
evyncke May 11, 2026
41f8596
Test the authors total graphics
evyncke May 11, 2026
15276c8
Display full country name in per meeting stat
evyncke May 12, 2026
cd48b92
Use top-n rather than minimum participants in per meeting stats
evyncke May 12, 2026
b6bf986
Fix affiliation factory
evyncke May 12, 2026
1c9ec97
Merge branch 'main' into feat-doc-stats
evyncke May 12, 2026
6763893
The other bin was never computed
evyncke May 12, 2026
cdc3044
Add total bars for documents
evyncke May 12, 2026
bc9b69f
Draft test for total documents
evyncke May 12, 2026
04f9cae
More tests for documents totals
evyncke May 12, 2026
5672ce2
Remove debugging console.log()
evyncke May 13, 2026
7b07e5d
Use all documents even in dev mode
evyncke May 13, 2026
e09c6c7
Allow changing the number of categories to display
evyncke May 13, 2026
1cfb6ca
Fix HTML label
evyncke May 13, 2026
ebcbfa4
Merge branch 'main' into feat-doc-stats
evyncke May 13, 2026
98b3480
Failed (?) attempt to use a cache
evyncke May 13, 2026
8213881
Wider input field for top_n
evyncke May 13, 2026
eb36f78
Remove cache debugging
evyncke May 13, 2026
faa1d3d
Merge branch 'main' into feat-doc-stats
evyncke May 13, 2026
a1fb7c6
Forgot one alias to remove
evyncke May 13, 2026
0c16703
Add message to assertTrue()
evyncke May 14, 2026
ab2e237
Remove case folding code from the affiliation aliases
evyncke May 14, 2026
471a3d9
No need to import collection
evyncke May 14, 2026
8f2fced
Merge branch 'main' into feat-doc-stats
evyncke May 19, 2026
ddc8881
Merge branch 'main' into feat-doc-stats
evyncke May 20, 2026
ef5cba4
Merge branch 'main' into feat-doc-stats
evyncke May 21, 2026
f3e28fa
fix: country factory does not use canonical names
evyncke May 21, 2026
817afff
fix typo in code
evyncke May 21, 2026
37871da
fix: another country name fix for the factory
evyncke May 21, 2026
0e7d8f6
Merge branch 'main' into feat-doc-stats
evyncke Jun 1, 2026
c0c3f1b
Split the large views.py in smaller views_foo.py
evyncke Jun 1, 2026
5f6c4f8
Add some guidance on the chart
evyncke Jun 1, 2026
aa4108b
Fixing Cabo Verde canonical country name
evyncke Jun 1, 2026
a4d973b
Move the reviews stats in views_reviews.py
evyncke Jun 1, 2026
3fabad6
fix templates to use views_reviews
evyncke Jun 2, 2026
d8b1228
Merge branch 'main' into feat-doc-stats
evyncke Jun 3, 2026
9eeec47
Merge branch 'main' into feat-doc-stats
evyncke Jun 3, 2026
1c484b1
Remove unused parameters
evyncke Jun 4, 2026
3866a19
After a co-pilot review ;-)
evyncke Jun 4, 2026
1ea13f6
Merge branch 'main' into feat-doc-stats
evyncke Jun 4, 2026
3d2ea96
Refactoring with co-pilot
evyncke Jun 4, 2026
470f0fd
Merge remote-tracking branch 'refs/remotes/origin/feat-doc-stats' int…
evyncke Jun 4, 2026
0c9440c
More typing
evyncke Jun 5, 2026
cf0a2d2
More co-pilot reviews
evyncke Jun 5, 2026
d552f75
Remove redundant line
evyncke Jun 5, 2026
e3f734d
Add types for functions parameters
evyncke Jun 9, 2026
ffd1cd6
Add docstrings
evyncke Jun 9, 2026
6b24aee
Merge branch 'main' into feat-doc-stats
evyncke Jun 30, 2026
5cbe725
Revert .gitignore change from 163db7e04f
evyncke Jun 30, 2026
112ac0f
Misc fixes after Jennifer's review (more to come)
evyncke Jun 30, 2026
4a589ed
Fix typo in Migration() to match the fix in models.py
evyncke Jun 30, 2026
2ba9375
Limit the choice of top_n to a pre-defined lists of values
evyncke Jun 30, 2026
eb7aa93
More readble comments
evyncke Jun 30, 2026
ecf9079
Use elif construct
evyncke Jun 30, 2026
7f08570
New URLs with a total suffix
evyncke Jun 30, 2026
277d7fd
Canonicalize British Virgin Islands
evyncke Jun 30, 2026
4a5fdf5
Ensure only 'rfc' and 'draft' doc_type are fetched
evyncke Jun 30, 2026
ff35f78
Merge branch 'main' into feat-doc-stats
evyncke Jun 30, 2026
7680e9e
Ensure that all documents are limited to rfc and draft typename
evyncke Jun 30, 2026
c20c73e
Fix for issue#11123
evyncke Jul 1, 2026
5171fa3
use document__group__type_id=wg rather than name draft-ietf-*
evyncke Jul 1, 2026
bfd0f50
Canonicalise Pitcairn Island
evyncke Jul 1, 2026
04d7b42
Fix English grammar
evyncke Jul 2, 2026
770cce7
Minor code clean-up
evyncke Jul 2, 2026
0e574c8
Merge branch 'main' into feat-doc-stats
evyncke Jul 2, 2026
e6c11e0
More affiliation alises
evyncke Jul 3, 2026
e0f5326
Explain how authors are counted
evyncke Jul 3, 2026
dc192af
Use RfcAuthor for RFC rather than DocumentAuthor
evyncke Jul 3, 2026
68e20a6
Make ruff happy
evyncke Jul 3, 2026
c98f339
More changes in order to use RfcAuthor
evyncke Jul 3, 2026
5944234
Make ruff happier
evyncke Jul 3, 2026
e07cb6e
Merge branch 'main' into feat-doc-stats
evyncke Jul 3, 2026
7e304dc
Make ruff happier for more files
evyncke Jul 4, 2026
bb10e9f
Tame the UI to avoid per country stats about RFC to bypass RfcAuthor …
evyncke Jul 4, 2026
1165661
Nicer identation
evyncke Jul 5, 2026
0f7804c
More robust tests
evyncke Jul 5, 2026
2e42be1
Select faster default statistics
evyncke Jul 5, 2026
9f9fcac
Refer to faster statistics
evyncke Jul 5, 2026
f893689
Temporary fix for test_bash() test that appears to be TZ-sensitive
evyncke Jul 5, 2026
1026ce7
Revert the temporary fix
evyncke Jul 6, 2026
19fc849
Merge branch 'main' into feat-doc-stats
evyncke Jul 10, 2026
e35868a
Merge branch 'main' into feat-doc-stats
evyncke Jul 10, 2026
7257a26
Merge branch 'main' into feat-doc-stats
evyncke Jul 11, 2026
d662a86
Use 'registration types' rather than 'total' for meetings
evyncke Jul 12, 2026
8f8256f
And also update the test URL...
evyncke Jul 12, 2026
03d0e6d
Better template for reg_type meetings timeline
evyncke Jul 12, 2026
aed7bbb
Slighlty better templace for registration types timeiine
evyncke Jul 12, 2026
b492d6b
Add CSV download for per meeting statistics
evyncke Jul 14, 2026
7564dfb
Add CSV download for meetings timeline
evyncke Jul 14, 2026
1cfbc6c
Ruff for long lines...
evyncke Jul 14, 2026
57cc0cf
Merge branch 'main' into feat-doc-stats
evyncke Jul 16, 2026
c9c84d8
Ensure that "IAB" is not canonicalised in to "I"
evyncke Jul 18, 2026
5d01907
add stats/usedaffiliations to display all affiliation canonicalisatio…
evyncke Aug 21, 2026
759f72a
Stats static JS files are now prefixed by stats_ to avoid overwriting...
evyncke Aug 21, 2026
f2a7777
Merge from current main branch
evyncke Aug 21, 2026
92f4ce9
Merging to main branch - bis
evyncke Aug 21, 2026
fe03f7b
Strict JS correctness
evyncke Aug 21, 2026
5266af9
Do not import unused module
evyncke Aug 21, 2026
bc198fd
Add test coverage for used affiliations
evyncke Aug 22, 2026
edc1a3b
Add list of affiliations/countries in the main menu for LLC staff
evyncke Aug 22, 2026
c3c8aeb
Address the "correctness" items from RjS's Claude review
evyncke Aug 22, 2026
70dc628
Removed unused import
evyncke Aug 22, 2026
71709c1
Improve queries and caching performances
evyncke Aug 22, 2026
90f762b
Consistent top_n checks
evyncke Aug 22, 2026
5ae85ee
performance improvement per RjS' review
evyncke Aug 22, 2026
83f5822
Display 'other' line only if there is date
evyncke Aug 22, 2026
da61f44
Redirect some old stats/meeting URL for consistency
evyncke Aug 22, 2026
e6506cf
Fixing RjS' review of the test
evyncke Aug 22, 2026
8295d1b
Fixing the nits from RjS' review
evyncke Aug 23, 2026
d23beae
Reflect models.py changes
evyncke Aug 23, 2026
29a1567
More update after models.py
evyncke Aug 23, 2026
4bb14b6
Fix secr/telechat intermittent failure
evyncke Aug 23, 2026
b75d437
Fix secr/telechat intermittent failure using SPC rather than TAB
evyncke Aug 23, 2026
5efe5cf
Merge branch 'ietf-tools:main' into feat-doc-stats
evyncke Aug 23, 2026
4613204
Use helper functions to avoid code duplication
evyncke Aug 23, 2026
f9fd7be
Add types to same function calls
evyncke Aug 23, 2026
b09b53a
Display only valid meeting numbers in the choice
evyncke Aug 25, 2026
ed1b4b1
Error message rather than top_n clamping
evyncke Aug 25, 2026
8b53bbb
Add more data in the cache
evyncke Aug 25, 2026
d5cf863
Only LLC staff can view used affiliations and known countries
evyncke Aug 25, 2026
373bb44
Minor fixes
evyncke Aug 25, 2026
6b57878
Query performance improvment
evyncke Aug 25, 2026
404f460
Fix typos in aliases
evyncke Aug 25, 2026
7a3a026
Fix MyPy very strict test for no-redef
evyncke Aug 25, 2026
2f6f125
fix get_aliased_affiliations() issue with white spaces, add new alias…
evyncke Aug 25, 2026
a1888e7
Longuest-prefix first in affiliation main names
evyncke Aug 26, 2026
3142426
Nits in templates
evyncke Aug 26, 2026
6da988a
Use names rather than slugs for publication status
evyncke Aug 26, 2026
5ff4e5f
Fix tests by using names rather than slug in publication status
evyncke Aug 26, 2026
cc610a1
Add URL redirects to 'legacy' stats URLs
evyncke Aug 27, 2026
4798bb8
Minor tests improvements by using assertEqual rather than assertTrue(…
evyncke Aug 27, 2026
7b9b41e
Remove duplicates of {% origin %}
evyncke Aug 27, 2026
21687a7
Nit: fixing a comment
evyncke Aug 28, 2026
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
1 change: 1 addition & 0 deletions ietf/secr/telechat/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ def test_doc_detail_charter(self):

def test_bash(self):
today = date_today()
TelechatDate.objects.filter(date=today).delete() # Clean up first
TelechatDate.objects.create(date=today)
url = reverse('ietf.secr.telechat.views.bash',kwargs={'date':today.strftime('%Y-%m-%d')})
self.client.login(username="secretary", password="secretary+password")
Expand Down
89 changes: 89 additions & 0 deletions ietf/static/js/stats_document_timeline.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
// Copyright The IETF Trust 2026, All Rights Reserved
import Chart from 'chart.js/auto'
import zoomPlugin from 'chartjs-plugin-zoom'

document.addEventListener('DOMContentLoaded', () => {
Chart.register(zoomPlugin) // enable the zoom plugin

// ── Safely parse JSON data injected from Django view ──
const chartData = JSON.parse(document.getElementById('chart_data').textContent) ;
const objects = JSON.parse(document.getElementById('objects').textContent) ;
const stackedLines = false ;

function displayChart (id, data) {
const ctx = document.getElementById(id).getContext('2d') ;
return new Chart(ctx, {
type: 'line',
data: data,
options: {
responsive: true,
scales: {
y: {
stacked: stackedLines,
},
x: {
title: {
display: true,
text: 'Year',
},
},
},
plugins: {
legend: {
position: 'bottom',
labels: {
usePointStyle: true,
padding: 15,
font: { size: 12 },
},
},
tooltip: {
backgroundColor: 'rgba(0,0,0,0.8)',
titleFont: { size: 14 },
bodyFont: { size: 13 },
callbacks: {
title: function(items) {
return `${items[0].label}`;
},
label: function(context) {
return ` ${context.dataset.label}: ${context.parsed.y} ${objects}`;
}
}
},
zoom: {
zoom: {
wheel: {
enabled: true,
modifierKey: 'alt' // Alt + scroll wheel to zoom
}, // scroll to zoom
pinch: {
enabled: true
}, // pinch on mobile
drag: { // drag to select range
enabled: true,
modifierKey: 'alt'
},
mode: 'xy', // zoom X-axis and Y-axis
},
pan: {
enabled: true,
modifierKey: 'alt',
mode: 'xy', // pan X-axis and Y-axis
},
},
}
}
})
}

const documentsChart = displayChart('documentsChart', chartData) ;

document.addEventListener('keydown', (event) => {
if (event.key === 'Escape') {
documentsChart.resetZoom()
}
})
document.getElementById('resetButton').addEventListener('click', () => {
documentsChart.resetZoom()
})
})
117 changes: 117 additions & 0 deletions ietf/static/js/stats_document_total.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
// Copyright The IETF Trust 2026, All Rights Reserved
import Chart from 'chart.js/auto'
import zoomPlugin from 'chartjs-plugin-zoom'

document.addEventListener('DOMContentLoaded', () => {
Chart.register(zoomPlugin) // enable the zoom plugin
const hidden = new Set(); // track suppressed categories

// ── Safely parse JSON data injected from Django view ──
const chartData = JSON.parse(document.getElementById('chart_data').textContent) ;
const objects = JSON.parse(document.getElementById('objects').textContent) ;

function refreshChart(chart) {
// On first call, snapshot the original data onto the chart instance itself
if (!chart._originalData) {
chart._originalData = {
labels: [...chart.data.labels],
values: [...chart.data.datasets[0].data],
colors: Array.isArray(chart.data.datasets[0].backgroundColor)
? [...chart.data.datasets[0].backgroundColor]
: chart.data.labels.map(() => chart.data.datasets[0].backgroundColor),
};
}

const original = chart._originalData;
const labels = [], values = [], colors = [];

original.labels.forEach((lbl, i) => {
if (!hidden.has(lbl)) {
labels.push(lbl);
values.push(original.values[i]);
colors.push(original.colors[i]);
}
});

chart.data.labels = labels;
chart.data.datasets[0].data = values;
chart.data.datasets[0].backgroundColor = colors;
chart.update();
}

function displayChart (id, data) {
const ctx = document.getElementById(id).getContext('2d') ;
let chart = new Chart(ctx, {
type: 'bar',
data: data,
options: {
indexAxis: 'y',
onClick: (event, elements) => {
if (elements.length > 0) {
const idx = elements[0].index;
const label = chart.data.labels[idx];
hidden.add(label);
refreshChart(chart);
}
},
responsive: true,
scales: {
x: {
title: {
display: true,
text: 'Number of ' + objects,
},
},
y: {
ticks: {
autoSkip: false, // Display all labels even if messy...
}
},
},
plugins: {
legend: {
display: false,
},
tooltip: {
backgroundColor: 'rgba(0,0,0,0.8)',
titleFont: { size: 14 },
bodyFont: { size: 13 },
callbacks: {
title: function(items) {
return `${items[0].label}`;
},
label: function(context) {
return `${context.formattedValue} ${objects}`;
}
}
},
zoom: {
zoom: {
wheel: {
enabled: true,
modifierKey: 'alt' // Alt + scroll wheel to zoom
}, // scroll to zoom
pinch: {
enabled: true

}, // pinch on mobile
drag: { // drag to select range
enabled: true,
modifierKey: 'alt'
},
mode: 'xy', // zoom X-axis and Y-axis
},
pan: {
enabled: true,
modifierKey: 'alt',
mode: 'xy', // pan X-axis and Y-axis
},
},
}
}
}) ;
return chart;
}

displayChart('documentsChart', chartData) ;
})
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
// Copyright The IETF Trust 2026, All Rights Reserved
import Chart from 'chart.js/auto'
import autocolors from 'chartjs-plugin-autocolors'

document.addEventListener('DOMContentLoaded', () => {
Chart.register(autocolors)
// ── Safely parse JSON data injected from Django view ──
const totalChartData = JSON.parse(document.getElementById('total-chart-data').textContent)
const inPersonChartData = JSON.parse(document.getElementById('in-person-chart-data').textContent)
Expand All @@ -16,9 +14,6 @@ document.addEventListener('DOMContentLoaded', () => {
options: {
responsive: true,
plugins: {
autocolors: {
mode: 'data' // Required for Pie charts to color individual slices
},
legend: {
position: 'bottom',
labels: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,14 @@ document.addEventListener('DOMContentLoaded', () => {
},
zoom: {
zoom: {
wheel: { enabled: true }, // scroll to zoom
pinch: { enabled: true }, // pinch on mobile
wheel: {
enabled: true,
modifierKey: 'alt' // Alt + scroll wheel to zoom
}, // scroll to zoom
pinch: {
enabled: true,
modifierKey: 'alt'
}, // pinch on mobile
drag: { // drag to select range
enabled: true,
modifierKey: 'alt'
Expand All @@ -63,6 +69,7 @@ document.addEventListener('DOMContentLoaded', () => {
},
pan: {
enabled: true,
modifierKey: 'alt',
mode: 'xy', // pan X-axis and Y-axis
},
},
Expand Down
7 changes: 6 additions & 1 deletion ietf/stats/admin.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from django.contrib import admin

from ietf.stats.models import AffiliationAlias, AffiliationIgnoredEnding, CountryAlias, MeetingRegistration
from ietf.stats.models import AffiliationAlias, AffiliationIgnoredEnding, AffiliationMainName, CountryAlias, MeetingRegistration


class AffiliationAliasAdmin(admin.ModelAdmin):
Expand All @@ -14,6 +14,11 @@ class AffiliationIgnoredEndingAdmin(admin.ModelAdmin):
search_fields = ["ending"]
admin.site.register(AffiliationIgnoredEnding, AffiliationIgnoredEndingAdmin)

class AffiliationMainNameAdmin(admin.ModelAdmin):
list_display = ('main_name',)
search_fields = ('main_name',)
admin.site.register(AffiliationMainName, AffiliationMainNameAdmin)

class CountryAliasAdmin(admin.ModelAdmin):
list_filter = ["country"]
list_display = ["alias", "country"]
Expand Down
16 changes: 15 additions & 1 deletion ietf/stats/factories.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,24 @@

import factory

from ietf.stats.models import MeetingRegistration
from ietf.stats.models import AffiliationIgnoredEnding, AffiliationMainName, MeetingRegistration
from ietf.meeting.factories import MeetingFactory
from ietf.person.factories import PersonFactory

class AffiliationIgnoredEndingFactory(factory.django.DjangoModelFactory):
class Meta:
model = AffiliationIgnoredEnding

ending = 'Inc\\.?'


class AffiliationMainNameFactory(factory.django.DjangoModelFactory):
Comment thread
evyncke marked this conversation as resolved.
class Meta:
model = AffiliationMainName

main_name = factory.Faker('company')


class MeetingRegistrationFactory(factory.django.DjangoModelFactory):
class Meta:
model = MeetingRegistration
Expand Down
Loading
Loading