diff --git a/.github/workflows/django.yml b/.github/workflows/django.yml index f484424b2..caf1b9a39 100644 --- a/.github/workflows/django.yml +++ b/.github/workflows/django.yml @@ -8,10 +8,10 @@ on: jobs: build: - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 services: postgres: - image: postgres:12 + image: postgres:14 env: POSTGRES_PASSWORD: postgres ports: @@ -22,11 +22,11 @@ jobs: --health-timeout 5s --health-retries 5 steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: - python-version: '3.8' + python-version: '3.10' - name: Setup Node uses: actions/setup-node@v3 with: diff --git a/CHANGELOG.md b/CHANGELOG.md index 4729d33ff..0a82be296 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,663 +2,57 @@ All notable changes to this project will be documented in this file. -Since version v2306 the format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), +Since version v2310.1 the format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), This project (not yet) adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## Unreleased +## v2310.1 ### Added -- add markdown rules to editorconfig +- support for celery task queues with a redis message broker +- makefile commands for starting and status checking of celery worker processes +- ai_report field to dashboard moderation comments serializer +- userdashboard: added field "user_reports" to moderation comment serializer +- Ai report serializer for comments viewset (#7571) +- general switch button react component +- switch button to AIreportExplanation component +- show_in_discussion field to AiReport model +- component to show AiReport in userdashboard and a toggle to show/hide + the report in the discussion +- react component to show AI report with dummy data for now +- new filter category for comments in moderator dashboard: "reported by ai" +- project insight model, create insight function, + update insights with signals (#2492) +- pyenv file and vim backup extension in gitignore +- in contrib templates for item_detail: + request http referer for go back/overview to filtered/paginated list +- in topicprio templates for topic_detail: + request http referer for go back/overview to filtered/paginated list +- in budgeting, idea, mapidea, topicprio: + index id to be used with href anchor to navigate back to item list +- in contrib templates for map_filter_and_sort and pagination: + index id to be used with href anchor to navigate back to item list -### Changed - -- reformat CHANGELOG.md - -## v2306 - -### Fixed - -- projects/helpers: simplify comment filter by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2450 -- improve userdashboard filter performance by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2449 -- **warning: contains a potentially long migration!** ### Changed -- update dependency postcss to v8.4.24 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2447 -- update dependency stylelint to v15.7.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2452 -- update dependency sentry-sdk to v1.25.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2424 -- update dependency faker to v18.10.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2428 -- update dependency django-debug-toolbar to v4.1.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2426 -- update dependency pytest to v7.3.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2453 -- update dependency webpack-cli to v5.1.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2454 -- update dependency urllib3 to v2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2399 -- update dependency wagtail to v4.1.6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2448 -- update dependency glob to v10.2.7 by @renovate in https://github.com/liqhttps://keepachangelog.com/d/adhocracy-plus/pull/2455 -- update dependency postcss-loader to v7.3.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2456 -- update dependency sass-loader to v13.3.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2457 -- update babel monorepo to v7.22.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2458 -- update dependency webpack to v5.86.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2460 -- update dependency css-loader to v6.8.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2463 -- update dependency pytest-cov to v4.1.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2459 - -# v2305.2 - -## What's Changed - -- chore(deps): update dependency webpack-merge to v5.9.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2439 -- fix(deps): update dependency sass-loader to v13.3.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2441 -- userdashboard: use new target_creator to improve filtering by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2445 -- deps: update a4 -- deps: update leaflet - -**Full Changelog**: https://github.com/liqd/adhocracy-plus/compare/v2305...v2305.2 - -This release replaces the hotfix before. - -# v2305.1 - -## What's Changed - -- hotfix to be removed after proper fix: delete actions from userdashboard by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2444 - -**Full Changelog**: https://github.com/liqd/adhocracy-plus/compare/v2305...v2305.1 - -## To do next release: - -- remove one commit from release and tag on main with real fix - -# v2305 - -## What's Changed - -- chore(deps): update jest monorepo to v29.4.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2255 -- chore(deps): update dependency eslint to v8.33.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2257 -- chore(deps): update dependency eslint-plugin-react to v7.32.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2258 -- fix(deps): update dependency sass to v1.58.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2263 -- chore(deps): update dependency lint-staged to v13.1.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2270 -- chore(deps): update jest monorepo to v29.4.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2273 -- apps/\*/dashboard: using blueprint types for export component by @khamui in https://github.com/liqd/adhocracy-plus/pull/2272 -- apps/embed: remove embed code by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2209 -- chore(deps): update dependency django to v3.2.18 [security] by @renovate in https://github.com/liqd/adhocracy-plus/pull/2278 -- chore(deps): update dependency lint-staged to v13.1.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2279 -- Jd 2023 03 account serializer lang by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2282 -- assets/shame: make sure comment buttons are styled by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2283 -- fix(deps): update dependency react-markdown to v8.0.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2243 -- chore(deps): update dependency stylelint-declaration-strict-value to v1.9.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2285 -- fix(deps): update dependency sass to v1.58.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2286 -- chore(deps): update babel monorepo by @renovate in https://github.com/liqd/adhocracy-plus/pull/2287 -- fix(deps): update dependency mini-css-extract-plugin to v2.7.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2289 -- chore(deps): update dependency eslint to v8.35.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2288 -- chore(deps): update jest monorepo to v29.5.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2291 -- [#6951]scss/modal: styling modal to match design (depending on a4) by @khamui in https://github.com/liqd/adhocracy-plus/pull/2250 -- chore(deps): update dependency wagtail to v4.1.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2269 -- chore(deps): update dependency black to v23 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2264 -- chore(deps): update dependency isort to v5.12.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2256 -- chore(deps): update dependency faker to v16.9.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2244 -- chore(deps): update dependency pytest to v7.2.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2231 -- chore(deps): update dependency sentry-sdk to v1.16.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2247 -- fix(deps): update dependency terser-webpack-plugin to v5.3.7 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2294 -- chore(deps): update dependency webpack to v5.76.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2295 -- fix(deps): update dependency autoprefixer to v10.4.14 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2299 -- chore(deps): update dependency lint-staged to v13.2.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2300 -- chore(deps): update dependency eslint to v8.36.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2301 -- chore(deps): update dependency webpack to v5.76.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2303 -- fix(deps): update dependency sass to v1.59.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2302 -- chore(deps): update babel monorepo to v7.21.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2305 -- fix(deps): update dependency sass to v1.59.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2306 -- chore(deps): update dependency webpack to v5.76.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2307 -- fix(deps): update dependency mini-css-extract-plugin to v2.7.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2309 -- ideas/serializers: return localized created date by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2311 -- [7154] Kl 2023 03 comment mod feedback by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2314 -- Ks 2023 03 add userdashboard by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2312 -- apps/users//views//models//templates: using profile view as in Kosmo by @khamui in https://github.com/liqd/adhocracy-plus/pull/2313 -- chore(deps): update dependency wagtail to v4.1.4 [security] by @renovate in https://github.com/liqd/adhocracy-plus/pull/2316 -- chore(deps): update dependency django-allauth to v0.54.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2308 -- chore(deps): update dependency whitenoise to v6.4.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2290 -- chore(deps): update dependency faker to v18 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2325 -- chore(deps): update dependency sentry-sdk to v1.18.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2321 -- chore(deps): update dependency black to v23.3.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2320 -- chore(deps): update dependency psycopg2 to v2.9.6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2318 -- chore(deps): update dependency psycopg2-binary to v2.9.6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2319 -- chore(deps): update dependency django-debug-toolbar to v4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2323 -- chore(deps): update babel monorepo to v7.21.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2317 -- fix(deps): update dependency sass-loader to v13.2.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2326 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2322 -- apps/users/templates: adding manual link (from settings) under profil… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2315 -- chore(deps): update dependency faker to v18.3.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2327 -- chore(deps): update dependency sentry-sdk to v1.19.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2328 -- [7210] userdashboard: add filters for moderation dashboard in api and use in… by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2330 -- chore(deps): update dependency webpack to v5.78.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2331 -- fix(deps): update dependency postcss-loader to v7.2.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2332 -- fix(deps): update dependency sass to v1.61.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2335 -- chore(deps): update dependency lint-staged to v13.2.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2336 -- chore(deps): update dependency eslint to v8.38.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2337 -- [#7208] userdashboard clean and some a11y fixes by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2333 -- userdashboard/moderation: renaming by @khamui in https://github.com/liqd/adhocracy-plus/pull/2342 -- apps/userdashboard/ModerationComments: add pagination to the api and … by @khamui in https://github.com/liqd/adhocracy-plus/pull/2345 -- [#7208] React18 syntax and rm un-needed js from being loaded (a11y related) by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2343 -- [7210, 7213] Ks 2023 04 filter for reviewed comments by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2346 -- notifications: add moderation specific emails by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2348 -- [#7208] styling: userdashboard: fix project list tiles and tab location, clean comp li… by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2344 -- chore(deps): update dependency @testing-library/react to v14 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2292 -- chore(deps): update dependency faker to v18.4.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2334 -- chore(deps): update dependency webpack to v5.79.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2354 -- app.js//webpack.common: update poll import so has own entrypoint a4 d… by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2351 -- chore(deps): update dependency postcss to v8.4.22 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2353 -- fix(deps): update dependency sass to v1.62.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2355 -- chore(deps): update dependency pytest to v7.3.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2338 -- [7208] JS test (ModerationNotification) by @khamui in https://github.com/liqd/adhocracy-plus/pull/2349 -- [#7208] a11y: lighthouse and SR improvements by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2356 -- chore(deps): update dependency webpack to v5.80.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2361 -- chore(deps): update dependency postcss to v8.4.23 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2362 -- chore(deps): update dependency webpack-cli to v5.0.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2366 -- fix(deps): update dependency js-cookie to v3.0.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2367 -- chore(deps): update dependency eslint to v8.39.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2368 -- Ks 2023 04 moderation dashboard tests by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2365 -- fix(deps): update dependency js-cookie to v3.0.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2371 -- [2252] single module project heading info added by @khamui in https://github.com/liqd/adhocracy-plus/pull/2375 -- userdashboard: improve db queries for actions by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2347 -- [2364] badge size and colorising fix by @khamui in https://github.com/liqd/adhocracy-plus/pull/2376 -- chore(deps): update dependency faker to v18.5.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2373 -- fix(deps): update dependency sass to v1.62.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2380 -- userdashboard/views: exclude paragraphs from comment actions by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2383 -- userdashboard/views: also exclude paragraphs from comment actions on … by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2384 -- update a4 hash by @khamui in https://github.com/liqd/adhocracy-plus/pull/2385 -- translations: makemessages by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2387 -- chore(deps): update dependency webpack to v5.81.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2388 -- chore(deps): update dependency lint-staged to v13.2.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2386 -- chore(deps): update dependency stylelint to v15 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2275 -- [2261 and 2262] project tile fixes by @khamui in https://github.com/liqd/adhocracy-plus/pull/2372 -- badge.scss: making sure bs and a4 classes are not overwritten by .badge by @khamui in https://github.com/liqd/adhocracy-plus/pull/2381 -- apps/userdashboard/ModerationNotificationList: fix packet size when f… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2390 -- chore(deps): update babel monorepo to v7.21.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2394 -- fix(deps): update dependency postcss-loader to v7.3.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2395 -- install urllib3 < 2 as requests doesn't support it yet by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2397 -- chore(deps): update babel monorepo to v7.21.8 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2402 -- chore(deps): update dependency stylelint to v15.6.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2404 -- a4-comments.scss: adding css for mark element using primary tint to h… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2382 -- Ks 2023 04 mod dashboard issues by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2400 -- apps/userdashboard/moderation: making image fill tile and use copyrig… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2396 -- chore(deps): update dependency sentry-sdk to v1.21.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2359 -- chore(deps): update dependency faker to v18.6.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2393 -- fix(deps): update dependency glob to v10 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2339 -- [#issues] front end release issues by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2391 -- chore(deps): update dependency webpack to v5.82.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2406 -- apps/users: adding "account already exists" email by @khamui in https://github.com/liqd/adhocracy-plus/pull/2398 -- chore(deps): update dependency wagtail to v4.1.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2403 -- chore(deps): update dependency django to v3.2.19 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2405 -- chore(deps): update dependency faker to v18.6.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2407 -- chore(deps): update dependency eslint to v8.40.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2411 -- fix(deps): update dependency terser-webpack-plugin to v5.3.8 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2412 -- chore(deps): update dependency webpack-cli to v5.1.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2413 -- locale: makemessages by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2408 -- chore(deps): update dependency sentry-sdk to v1.22.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2410 -- chore(deps): update dependency webpack-cli to v5.1.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2415 -- fix(deps): update dependency glob to v10.2.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2417 -- chore(deps): update dependency webpack to v5.82.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2419 -- userdashboard: remove unused fetch of comment count by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2416 -- chore(deps): update dependency faker to v18.7.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2414 -- styles/badge: increase specificity for badges by @khamui in https://github.com/liqd/adhocracy-plus/pull/2418 -- apps//userdashboard//projects: fix tiles clickable and shadow (multim… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2401 -- local: add translatied strings by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2420 -- deps: add a4 tag by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2421 -- fix(deps): update dependency glob to v10.2.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2423 -- chore(deps): update dependency stylelint to v15.6.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2429 -- templates/\*: update text bold class for bs 5 and change selectors of … by @philli-m in https://github.com/liqd/adhocracy-plus/pull/2430 -- chore(deps): update dependency webpack to v5.83.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2431 -- fix(deps): update dependency glob to v10.2.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2432 -- fix(deps): update dependency terser-webpack-plugin to v5.3.9 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2433 -- fix(deps): update dependency css-loader to v6.7.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2435 -- fix(deps): update dependency mini-css-extract-plugin to v2.7.6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2436 -- chore(deps): update dependency eslint to v8.41.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2437 -- fix(deps): update dependency glob to v10.2.6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2438 - -**Full Changelog**: https://github.com/liqd/adhocracy-plus/compare/v2301.1...v2305 - -# v2301.3 - -- update a4 to fix organisation terms of use checkbox in child comments -- minor style fix - -Note: -This added 3 cherry-picked commits, so with the release before there are 4 to be reset before next release tagged on main. - -# v2301.2 - -**Full Changelog**: https://github.com/liqd/adhocracy-plus/compare/v2301.1...v2301.2 - -Only one (cherry-picked) commit to update Django. - -# v2301.1 - -## What's Changed - -- Ks 2023 01 add black by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2218 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2219 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2224 -- add git-blame-ignore-revs file by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2228 -- chore(deps): update dependency sentry-sdk to v1.13.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2227 -- chore(deps): update dependency faker to v16 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2216 -- chore(deps): update dependency easy-thumbnails to v2.8.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2215 -- Revert "add git-blame-ignore-revs file" by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2229 -- fix(deps): update dependency glob to v8.1.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2232 -- chore(deps): update dependency eslint to v8.32.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2233 -- organisations/forms: move brackets to right place to make string tran… by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2230 -- settings/base: change wording of a4_blueprint_types by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2236 -- translations: remove unused strings by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2237 -- rename moderatorfeedback by @khamui in https://github.com/liqd/adhocracy-plus/pull/2238 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2242 -- chore(deps): update dependency @babel/runtime to v7.20.13 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2246 -- chore(deps): update jest monorepo to v29.4.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2249 -- [issue] update a4 to fix poll and small style and wording fixes by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2245 -- Kl 2023 01 release prep by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2253 - -**Full Changelog**: https://github.com/liqd/adhocracy-plus/compare/v2301...v2301.1 - -# v2301 - -## What's Changed - -- apps/projects: add project contact info to app project serializer by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/1979 -- chore(deps): update babel monorepo to v7.18.9 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1983 -- chore(deps): update jest monorepo to v28.1.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1984 -- chore(deps): update dependency markdownlint-cli to v0.32.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1985 -- chore(deps): update dependency stylelint-declaration-strict-value to v1.9.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1986 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/1987 -- Ks 2022 07 module type tests and fixes by @Rineee in https://github.com/liqd/adhocracy-plus/pull/1990 -- docs/api: add some curl commands by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/1989 -- cms: form_data already is json in wagtail 3.x by @goapunk in https://github.com/liqd/adhocracy-plus/pull/1992 -- projects/api: only allow authenticated users by @Rineee in https://github.com/liqd/adhocracy-plus/pull/1993 -- chore(deps): update dependency eslint-plugin-jsx-a11y to v6.6.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1997 -- chore(deps): update dependency markdownlint-cli to v0.32.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1998 -- chore(deps): update dependency webpack to v5.74.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1999 -- account//config/urls: add account api and viewset by @Rineee in https://github.com/liqd/adhocracy-plus/pull/1994 -- [6233] apps/users: add user API to get user info in app by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/1995 -- config/urls: remove name of api/account by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2001 -- fix(deps): update dependency sass to v1.54.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2000 -- settings/renovate: make renovate update py packages by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2004 -- fix(deps): update dependency autoprefixer to v10.4.8 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2005 -- api: use slug to lookup projects in app by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2012 -- assets/images: add png fallback images by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2015 -- ideas/api: do not copy request.data, but send image deletion info by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2003 -- Ks 2022 08 use png avatars in app by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2016 -- Ks 2022 08 user account api tests by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2014 -- Ks 2022 08 add images app user serializers by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2018 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2006 -- chore(deps): update babel monorepo to v7.18.10 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2019 -- Jd 2022 08 local a4 by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2017 -- settings/renovate: allow Django versions = 3.2 by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2022 -- chore(deps): update dependency sentry-sdk to v1.9.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2008 -- chore(deps): update dependency faker to v13.15.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2007 -- chore(deps): update dependency django-cloudflare-push to v0.2.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2020 -- chore(deps): update dependency eslint-plugin-jest to v26.8.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2024 -- chore(deps): update dependency postcss to v8.4.16 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2026 -- fix(deps): update dependency sass to v1.54.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2028 -- chore(deps): update dependency django to v3.2.15 [security] by @renovate in https://github.com/liqd/adhocracy-plus/pull/2025 -- chore(deps): update dependency django-ckeditor to v6.5.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2029 -- chore(deps): update dependency sentry-sdk to v1.9.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2027 -- chore(deps): update dependency flake8 to v5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2010 -- chore(deps): update dependency stylelint to v14.10.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2030 -- fix(deps): update dependency terser-webpack-plugin to v5.3.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2034 -- chore(deps): update dependency eslint to v8.22.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2036 -- chore(deps): pin dependency @testing-library/jest-dom to 5.16.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1974 -- chore(deps): update dependency freezegun to v1.2.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2033 -- chore(deps): update dependency stylelint-config-standard to v27 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2031 -- chore(deps): update dependency faker to v14 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2037 -- chore(deps): update dependency easy-thumbnails to v2.8.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2011 -- chore(deps): update dependency eslint-plugin-jest to v26.8.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2038 -- chore(deps): update dependency stylelint-config-standard-scss to v5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1988 -- fix(deps): update dependency shpjs to v4.0.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1973 -- chore(deps): update dependency sentry-sdk to v1.9.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2039 -- fix(deps): update dependency terser-webpack-plugin to v5.3.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2040 -- deps: update a4 by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2041 -- chore(deps): update dependency eslint-plugin-jest to v26.8.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2044 -- fix(deps): update dependency sass to v1.54.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2045 -- chore(deps): update dependency eslint-plugin-jest to v26.8.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2046 -- chore(deps): update dependency markdownlint-cli to v0.32.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2047 -- chore(deps): update dependency stylelint to v14.11.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2048 -- chore(deps): update dependency eslint-plugin-jest to v26.8.7 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2050 -- chore(deps): update dependency eslint-plugin-n to v15.2.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2051 -- chore(deps): update dependency @babel/core to v7.18.13 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2052 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2055 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2057 -- chore(deps): update dependency eslint-plugin-jest to v26.9.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2059 -- fix(deps): update dependency terser-webpack-plugin to v5.3.6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2061 -- fix(deps): update dependency sass to v1.54.6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2062 -- Pm 2022 11 a11y fixes by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2067 -- chore(deps): update dependency django to v3.2.16 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2066 -- chore(deps): update dependency wagtail to v3.0.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2063 -- chore(deps): update dependency eslint-plugin-jest to v27 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2060 -- chore(deps): update dependency bcrypt to v4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2054 -- chore(deps): update dependency faker to v14.2.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2042 -- chore(deps): update dependency django-debug-toolbar to v3.7.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2043 -- chore(deps): update dependency husky to v8.0.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2069 -- chore(deps): update dependency django-ckeditor to v6.5.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2068 -- chore(deps): update dependency stylelint to v14.15.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2080 -- fix(deps): update dependency css-loader to v6.7.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2076 -- fix(deps): update dependency autoprefixer to v10.4.13 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2074 -- chore(deps): update dependency postcss to v8.4.19 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2070 -- fix(deps): update dependency bootstrap to v5.2.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/1991 -- chore(deps): update jest monorepo to v29 (major) by @renovate in https://github.com/liqd/adhocracy-plus/pull/2056 -- chore(deps): update dependency @testing-library/react to v13.4.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2082 -- chore(deps): update dependency sentry-sdk to v1.11.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2079 -- chore(deps): update dependency pytest to v7.2.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2078 -- chore(deps): update dependency psycopg2 to v2.9.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2071 -- chore(deps): update dependency stylelint-declaration-strict-value to v1.9.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2073 -- chore(deps): update babel monorepo by @renovate in https://github.com/liqd/adhocracy-plus/pull/2077 -- chore(deps): update dependency psycopg2-binary to v2.9.5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2072 -- chore(deps): update dependency stylelint-config-standard-scss to v6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2095 -- chore(deps): update dependency pytest-cov to v4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2093 -- chore(deps): update dependency flake8 to v6 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2092 -- chore(deps): update dependency faker to v15 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2091 -- chore(deps): update dependency babel-loader to v9 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2090 -- fix(deps): update dependency mini-css-extract-plugin to v2.7.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2087 -- fix(deps): update dependency sass-loader to v13.2.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2089 -- chore(deps): update dependency webpack to v5.75.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2097 -- fix(deps): update dependency sass to v1.56.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2088 -- chore(deps): update dependency lint-staged to v13.0.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2102 -- [updates] rm planifolia dep and update styling part 1 by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2099 -- chore(deps): update dependency stylelint-config-standard to v29 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2094 -- chore(deps): update babel monorepo by @renovate in https://github.com/liqd/adhocracy-plus/pull/2106 -- [updates] deps react18 by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2104 -- chore(deps): update dependency zeep to v4.2.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2098 -- [updates/issue] fixing styling issues from rm planifolia by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2107 -- fix(deps): update dependency mini-css-extract-plugin to v2.7.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2109 -- fix(deps): update dependency postcss-loader to v7.0.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2110 -- chore(deps): update dependency wagtail to v4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2100 -- webpack.common: update to maplibre -test by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2111 -- Revert "webpack.common: update to maplibre -test" by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2112 -- chore(deps): update dependency webpack-cli to v5 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2101 -- chore(deps): update dependency faker to v15.3.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2113 -- chore(deps): update dependency stylelint to v14.16.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2119 -- chore(deps): update dependency lint-staged to v13.1.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2121 -- [updates] update mapbox to maplibre by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2115 -- [updates/#6749] organisations/react_language_choice.jsx: fix linting error by @khamui in https://github.com/liqd/adhocracy-plus/pull/2116 -- chore(deps): update eslint packages by @renovate in https://github.com/liqd/adhocracy-plus/pull/2085 -- chore(deps): update dependency webpack-cli to v5.0.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2123 -- fix(deps): update dependency mini-css-extract-plugin to v2.7.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2124 -- chore(deps): update dependency django-debug-toolbar to v3.8.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2120 -- [6751] templates/projects/module tile: redo staling of module tiles by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2108 -- [#6759] button clean up according to design clean by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2122 -- chore(deps): update dependency pytest-factoryboy to v2.5.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2117 -- [updates] small style fix to progress line and a4 update by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2129 -- [#6750] a4dashboard: add communication form by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2081 -- dashboard/phases/datetime_input: using same class to assure same heig… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2131 -- fix(deps): update dependency sass to v1.56.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2136 -- chore(deps): update dependency postcss to v8.4.20 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2138 -- chore(deps): update dependency django-filter to v22 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2009 -- project/tiles: tile tiles do not exceed width by @khamui in https://github.com/liqd/adhocracy-plus/pull/2134 -- [6751] component lib and translations by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2137 -- Ks 2022 12 social media image downlaod by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2144 -- chore(deps): update dependency djangorestframework to v3.14.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2084 -- chore(deps): update dependency isort to v5.11.2 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2142 -- dashboard/modules/publish & unpublish switch button: adding css logic… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2140 -- css/\_form.scss: removing spacing (margin-bottom) from input-base & ad… by @khamui in https://github.com/liqd/adhocracy-plus/pull/2125 -- deps: update a4 hash and reliant packages react-flip-move and react-m… by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2150 -- fix(deps): update dependency css-loader to v6.7.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2152 -- Pm 2022 12 styling issues by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2153 -- chore(deps): update dependency eslint-plugin-jest to v27.1.7 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2156 -- components/item_detail.scss: setting item detail's z-index by @khamui in https://github.com/liqd/adhocracy-plus/pull/2164 -- chore(deps): update dependency eslint to v8.30.0 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2157 -- [#6754] add img format and logo checkbox by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2135 -- fix(deps): update dependency sass to v1.57.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2158 -- Ks 2022 12 issues by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2162 -- chore(deps): update dependency isort to v5.11.3 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2159 -- [Issues] templates/\*: improve semantic html and add missing heading headings f… by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2169 -- Kl 2022 12 blocktranslate by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2170 -- Ks 2022 12 communication form tests by @Rineee in https://github.com/liqd/adhocracy-plus/pull/2163 -- chore(deps): update dependency isort to v5.11.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2174 -- apps/projects/templates/project tile: make sure blueprint_type and ic… by @fuzzylogic2000 in https://github.com/liqd/adhocracy-plus/pull/2175 -- [#6754] organisations/forms: update configs to correct differences between pi… by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2180 -- organisation/views: update x axis by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2182 -- Pm 2022 12 story insta by @phillimorland in https://github.com/liqd/adhocracy-plus/pull/2184 -- chore(deps): update babel monorepo to v7.20.7 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2181 -- sharepic: replace deprecated textsize by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2186 -- chore(deps): update dependency @babel/plugin-transform-modules-commonjs to v7.20.11 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2187 -- replace trans with translate by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2185 -- sharepics: add test for aspect ratio calculation by @goapunk in https://github.com/liqd/adhocracy-plus/pull/2179 -- chore(deps): update dependency easy-thumbnails to v2.8.4 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2165 -- chore(deps): update dependency sentry-sdk to v1.12.1 by @renovate in https://github.com/liqd/adhocracy-plus/pull/2155 -- templates/buttons: using
-
diff --git a/apps/dashboard/blueprints.py b/apps/dashboard/blueprints.py index 1c96e8453..c5a3f74fe 100644 --- a/apps/dashboard/blueprints.py +++ b/apps/dashboard/blueprints.py @@ -1,81 +1,11 @@ from django.utils.translation import gettext_lazy as _ from adhocracy4.dashboard.blueprints import ProjectBlueprint -from adhocracy4.polls import phases as poll_phases -from apps.budgeting import phases as budgeting_phases from apps.debate import phases as debate_phases from apps.documents import phases as documents_phases -from apps.ideas import phases as ideas_phases -from apps.interactiveevents import phases as interactiveevent_phases -from apps.mapideas import phases as mapideas_phases from apps.topicprio import phases as topicprio_phases blueprints = [ - ( - "brainstorming", - ProjectBlueprint( - title=_("Brainstorming"), - description=_( - "Participants can submit their own ideas and discuss the " - "ideas of others." - ), - content=[ - ideas_phases.CollectPhase(), - ], - image="images/brainstorming.svg", - settings_model=None, - type="BS", - ), - ), - ( - "map-brainstorming", - ProjectBlueprint( - title=_("Spatial Brainstorming"), - description=_( - "Participants can submit their own ideas and locate them on a " - "map. They can also discuss the ideas of others." - ), - content=[ - mapideas_phases.CollectPhase(), - ], - image="images/map-brainstorming.svg", - settings_model=("a4maps", "AreaSettings"), - type="MBS", - ), - ), - ( - "idea-collection", - ProjectBlueprint( - title=_("Idea Challenge"), - description=_( - "In a first phase, participants can submit their own ideas " - "and discuss the ideas of others. In a second phase, the " - "ideas can be rated (pro/contra)." - ), - content=[ - ideas_phases.CollectPhase(), - ideas_phases.RatingPhase(), - ], - image="images/agenda-setting.svg", - settings_model=None, - type="IC", - ), - ), - ( - "map-idea-collection", - ProjectBlueprint( - title=_("Spatial Idea Challenge"), - description=_( - "In a first phase, participants can submit their own ideas, " - "mark them on a map, and discuss the ideas of others. In a " - "second phase, the ideas can be rated (pro/contra)." - ), - content=[mapideas_phases.CollectPhase(), mapideas_phases.RatingPhase()], - image="images/map-idea-collection.svg", - settings_model=("a4maps", "AreaSettings"), - type="MIC", - ), - ), ( "text-review", ProjectBlueprint( @@ -92,55 +22,6 @@ type="TR", ), ), - ( - "poll", - ProjectBlueprint( - title=_("Poll"), - description=_( - "Participants can answer open and multiple choice questions " - "and comment on the poll." - ), - content=[ - poll_phases.VotingPhase(), - ], - image="images/poll.svg", - settings_model=None, - type="PO", - ), - ), - ( - "participatory-budgeting", - ProjectBlueprint( - title=_("Participatory budgeting"), - description=_( - "Participants can submit their own suggestions, mark them on " - "a map, and add a budget. The ideas of others can be " - "discussed and rated (pro/contra)." - ), - content=[budgeting_phases.RequestPhase()], - image="images/participatory-budgeting.svg", - settings_model=("a4maps", "AreaSettings"), - type="PB", - ), - ), - ( - "interactive-event", - ProjectBlueprint( - title=_("Interactive Event"), - description=_( - "The participants of an event can ask their questions online. " - "Other participants can support the question. You as the " - "moderator can sort the questions by support or " - "affiliation." - ), - content=[ - interactiveevent_phases.IssuePhase(), - ], - image="images/live-discussion.svg", - settings_model=None, - type="IE", - ), - ), ( "topic-prioritization", ProjectBlueprint( diff --git a/apps/moderatorfeedback/serializers.py b/apps/moderatorfeedback/serializers.py index 565c7bcb8..a85e7be65 100644 --- a/apps/moderatorfeedback/serializers.py +++ b/apps/moderatorfeedback/serializers.py @@ -2,6 +2,7 @@ from adhocracy4.comments.models import Comment from adhocracy4.comments_async import serializers as a4_serializers +from apps.ai_reports.serializers import AiReportSerializer from apps.contrib.dates import get_date_display from apps.moderatorfeedback.models import ModeratorCommentFeedback @@ -34,12 +35,11 @@ def get_last_edit(self, feedback): class CommentWithFeedbackSerializer(a4_serializers.CommentSerializer): moderator_feedback = ModeratorCommentFeedbackSerializer(read_only=True) + ai_report = AiReportSerializer(read_only=True) class Meta: model = Comment - read_only_fields = a4_serializers.CommentSerializer.Meta.read_only_fields + ( - "moderator_comment_feedback", - ) + read_only_fields = a4_serializers.CommentSerializer.Meta.read_only_fields exclude = ("creator",) diff --git a/apps/organisations/migrations/0022_alter_organisation_language.py b/apps/organisations/migrations/0022_alter_organisation_language.py new file mode 100644 index 000000000..f58321c4e --- /dev/null +++ b/apps/organisations/migrations/0022_alter_organisation_language.py @@ -0,0 +1,23 @@ +# Generated by Django 3.2.19 on 2023-10-17 09:53 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("a4_candy_organisations", "0021_alter_organisation_logo"), + ] + + operations = [ + migrations.AlterField( + model_name="organisation", + name="language", + field=models.CharField( + choices=[("en", "English"), ("de", "German")], + default="de", + help_text="All e-mails to unregistered users (invites) will be sent in this language.", + max_length=4, + verbose_name="Default language for e-mails", + ), + ), + ] diff --git a/apps/projects/helpers.py b/apps/projects/helpers.py index 52f4d2838..269acf7a3 100644 --- a/apps/projects/helpers.py +++ b/apps/projects/helpers.py @@ -1,12 +1,11 @@ from datetime import timedelta -from django.contrib.contenttypes.models import ContentType from django.db.models import Count from django.db.models import Q +from django.db.models import Sum from django.utils import timezone from adhocracy4.comments.models import Comment -from adhocracy4.reports.models import Report def get_all_comments_project(project): @@ -20,11 +19,12 @@ def get_num_comments_project(project): def get_num_reports(project): - comment_ids_project = get_all_comments_project(project).values_list("id", flat=True) - comment_ct = ContentType.objects.get_for_model(Comment) - return Report.objects.filter( - content_type=comment_ct, object_pk__in=comment_ids_project - ).count() + comments = get_all_comments_project(project) + comments = comments.annotate( + num_reports=Count("reports", distinct=True) + Count("ai_report", distinct=True), + ) + + return comments.aggregate(Sum("num_reports"))["num_reports__sum"] def get_num_latest_comments(project, until={"days": 7}): diff --git a/apps/userdashboard/api.py b/apps/userdashboard/api.py index 5c93bc127..a987014d0 100644 --- a/apps/userdashboard/api.py +++ b/apps/userdashboard/api.py @@ -1,7 +1,5 @@ from django.db.models import Count -from django.db.models import ExpressionWrapper -from django.db.models import Q -from django.db.models.fields import BooleanField +from django.http import JsonResponse from django.shortcuts import get_object_or_404 from django_filters.rest_framework import BooleanFilter from django_filters.rest_framework import DjangoFilterBackend @@ -23,9 +21,20 @@ class ModerationCommentFilterSet(DefaultsRestFilterSet): is_reviewed = BooleanFilter() - has_reports = BooleanFilter() - defaults = {"is_reviewed": "false", "has_reports": "all"} + defaults = {"is_reviewed": "false"} + + @property + def qs(self): + queryset = super().qs + reported_by = self.request.query_params.get("reported_by") + + if reported_by == "ai": + queryset = queryset.filter(ai_report__isnull=False) + elif reported_by == "users": + queryset = queryset.filter(reports__isnull=False) + + return queryset class ModerationCommentPagination(PageNumberPagination): @@ -62,19 +71,31 @@ def get_permission_object(self): return self.project def get_queryset(self): - all_comments_project = helpers.get_all_comments_project(self.project) - num_reports = Count("reports", distinct=True) - return all_comments_project.annotate(num_reports=num_reports).annotate( - has_reports=ExpressionWrapper( - Q(num_reports__gt=0), output_field=BooleanField() - ) + comments = helpers.get_all_comments_project(self.project) + comments = comments.annotate( + num_reports=Count("reports", distinct=True) + + Count("ai_report", distinct=True), ) + return comments + def update(self, request, *args, **kwargs): - if "is_blocked" in self.request.data and request.data["is_blocked"]: + if request.data.get("is_blocked"): NotifyCreatorOnModeratorBlocked.send(self.get_object()) + return super().update(request, *args, **kwargs) + @action(detail=True) + def toggle_show_ai_report(self, request, **kwargs): + comment = self.get_object() + if hasattr(comment, "ai_report"): + comment.ai_report.show_in_discussion = ( + not comment.ai_report.show_in_discussion + ) + comment.ai_report.save() + return JsonResponse(status=200, data={}) + return JsonResponse(status=400, data={}) + @action(detail=True) def mark_read(self, request, **kwargs): comment = self.get_object() diff --git a/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationFeedback.jsx b/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationFeedback.jsx index 40ac8775a..ffce6ef25 100644 --- a/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationFeedback.jsx +++ b/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationFeedback.jsx @@ -8,11 +8,13 @@ export const ModerationFeedback = (props) => { delete: django.gettext('delete'), edit: django.gettext('edit'), feedbackTitle: django.gettext('Moderator\'s feedback'), - editWasOn: django.gettext('Last edit was on ') + editWasOn: django.gettext('Last edit was on '), + feedbackMenu: django.gettext('Feedback menu') + } return ( -
+
  • {translated.feedbackTitle}
    @@ -21,7 +23,7 @@ export const ModerationFeedback = (props) => {
    -
    +
  • ) } diff --git a/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationNotification.jsx b/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationNotification.jsx index 0c2b9c5a7..72087e8c0 100644 --- a/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationNotification.jsx +++ b/apps/userdashboard/assets/js/a4_candy_userdashboard/ModerationNotification.jsx @@ -4,7 +4,8 @@ import api from './api' import { ModerationFeedbackForm } from './ModerationFeedbackForm' import { ModerationFeedback } from './ModerationFeedback' import { ModerationNotificationActionsBar } from './ModerationNotificationActionsBar' -import { alert as Alert } from 'adhocracy4' +import { UserReport } from './UserReport' +import { aiReport as AiReport, alert as Alert } from 'adhocracy4' const alertTime = 6000 @@ -21,7 +22,12 @@ const translated = { notificationRead: django.gettext('Notification successfully marked as read.'), notificationUnread: django.gettext('Notification successfully marked as unread.'), aiClassified: django.gettext('AI'), - postedComment: django.gettext('posted a {}comment{}') + postedComment: django.gettext('posted a {}comment{}'), + notificationMenu: django.gettext('Notification menu'), + reportUser: django.pgettext('defakts', 'Reported by Users'), + reportAi: django.pgettext('defakts', 'Reported by AI'), + reportShown: django.pgettext('defakts', 'Report displayed in comment list'), + reportHidden: django.pgettext('defakts', 'Report hidden in comment list') } export const ModerationNotification = (props) => { @@ -214,12 +220,27 @@ export const ModerationNotification = (props) => { } } + async function toggleShowAiReport () { + const [, error] = + await api.fetch({ + url: props.apiUrl + 'toggle_show_ai_report/' + props.getUrlParams(), + method: 'GET' + }) + if (error) { + setAlert({ + type: 'error', + message: error.message, + timeInMs: alertTime + }) + } + } + // **** End notification methods **** function translatedReportText (reportsFound) { const tmp = django.ngettext( - 'This {}comment{} has been reported 1 time since it\'s creation', - 'This {}comment{} has been reported %s times since it\'s creation', + '\'s {}comment{} has been reported 1 time since it\'s creation', + '\'s {}comment{} has been reported %s times since it\'s creation', reportsFound ) return ( @@ -235,7 +256,9 @@ export const ModerationNotification = (props) => { user_image: userImage, user_name: userName, user_profile_url: userProfileUrl, - num_reports: numReports + num_reports: numReports, + ai_report: aiReport, + user_reports: userReports } = notification const markReadText = django.gettext('Mark as read') const markUnreadText = django.gettext('Mark as unread') @@ -257,19 +280,26 @@ export const ModerationNotification = (props) => { return (
  • -
    -
    +
      +
    • {userImageDiv}
      -

      - {userProfileUrl ? {userName} : userName} {getLink(translated.postedComment, commentUrl)} -

      + {numReports > 0 + ?

      +