Refactor Dockerfile and update models and frontend components

- Removed the APP_VERSION argument from the Dockerfile and added TARGETARCH for architecture-specific wkhtmltopdf installation.
- Updated models.py to reintroduce the import of PartCountry for consistency.
- Enhanced parts.ts interface by adding new optional fields: immex_type, disable_movements, pga_program_code, non_discharge_clients, bom_items, and countries.
- Changed formType default in partForm.svelte and edit page to 'fa' for better alignment with the intended functionality.
- Improved type handling for non_discharge_clients in partForm.svelte.
- Adjusted column span logic in partForm.svelte for better rendering.
- Fixed image error handling in partForm.svelte for improved user experience.
- Updated license expiration date calculation in init_first_time.sh for compatibility with macOS.
This commit is contained in:
AlexeerCT
2026-03-13 16:53:42 -06:00
parent dfa44aaff7
commit ef5564dd25
6 changed files with 20 additions and 14 deletions

View File

@@ -2,12 +2,6 @@ FROM python:3.11-slim
WORKDIR /app
# ========================================
# ARG para recibir la versión desde CI/CD
# ========================================
ARG APP_VERSION="dev"
ENV APP_VERSION=${APP_VERSION}
# Instalar dependencias del sistema
RUN apt-get update && apt-get install -y \
gcc \
@@ -32,7 +26,9 @@ RUN apt-get update \
&& rm -rf /var/lib/apt/lists/*
# Instalar wkhtmltopdf binario oficial con soporte para footers/headers
RUN curl -k -L -o /tmp/wkhtmltox.deb https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6.1-3/wkhtmltox_0.12.6.1-3.bookworm_amd64.deb \
# TARGETARCH permite amd64 y arm64 (Apple Silicon)
ARG TARGETARCH
RUN curl -k -L -o /tmp/wkhtmltox.deb "https://github.com/wkhtmltopdf/packaging/releases/download/0.12.6.1-3/wkhtmltox_0.12.6.1-3.bookworm_${TARGETARCH}.deb" \
&& apt-get update \
&& apt-get install -y /tmp/wkhtmltox.deb \
&& rm /tmp/wkhtmltox.deb \

View File

@@ -26,6 +26,7 @@ from api.v1.modules.public.reference_data.currency_types.models import CurrencyT
from api.v1.modules.a24.fa.fa_parts.models import FaPart
from api.v1.modules.a24.inv.inv_parts.models import InvPart
from api.v1.modules.a24.inv.bom.models import BillOfMaterial
from api.v1.modules.a24.inv.part_countries.models import PartCountry
if TYPE_CHECKING:
@@ -33,7 +34,6 @@ if TYPE_CHECKING:
from api.v1.modules.a76.general_catalogs.units_of_measure.models import (
UnitOfMeasure,
)
from api.v1.modules.a24.inv.part_countries.models import PartCountry
class Part(Base, TenantScopedMixin, TimestampMixin):