mirror of
https://gh.wpcy.net/https://github.com/WeblateOrg/weblate.git
synced 2026-04-26 07:59:21 +08:00
Some checks are pending
API / API Lint (push) Waiting to run
Documentation / update-autogenerated-docs (push) Waiting to run
Documentation / list-languages (push) Blocked by required conditions
Documentation / Sphinx (push) Blocked by required conditions
FOSSA / fossa-scan (push) Waiting to run
Linkcheck / Linkcheck (push) Waiting to run
macOS / macos (push) Waiting to run
Migrations / postgresql (push) Waiting to run
mypy / mypy (push) Waiting to run
Pre-commit check / pre-commit (push) Waiting to run
pylint check / pylint (push) Waiting to run
Rundev / Test development Docker (push) Waiting to run
jsonschema update / jsonschema-update (push) Waiting to run
Scorecard supply-chain security / Scorecard analysis (push) Waiting to run
Distribution / Build packages (push) Waiting to run
Distribution / Lint packages (push) Blocked by required conditions
Distribution / Build release notes (push) Waiting to run
Distribution / Publish to PyPI (push) Blocked by required conditions
Distribution / Publish to GitHub (push) Blocked by required conditions
Test / py3.12, latest deps (push) Waiting to run
Test / py3.12, minimal deps (push) Waiting to run
Test / py3.13, latest deps (push) Waiting to run
Test / py3.14, latest deps (push) Waiting to run
Test / py3.14, edge deps (push) Waiting to run
uv lock update / uv-update (push) Waiting to run
Add ComponentLink explicit through model for Component.links M2M with an optional category FK, enabling shared components to be organized into categories within the target project. Add a separate "Share in Projects" tab in component settings and add a dynamic category input based on selected project when creating a component link.
11 lines
373 B
Python
11 lines
373 B
Python
# Copyright © Michal Čihař <michal@weblate.org>
|
|
#
|
|
# SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
"""Set up component links for migration testing."""
|
|
|
|
from weblate.trans.models import Component, Project
|
|
|
|
project = Project.objects.create(name="link-target", slug="link-target")
|
|
component = Component.objects.filter(project__slug="test").first()
|
|
component.links.add(project)
|