Compare commits

...

6 Commits

Author SHA1 Message Date
b7710390fa Add new VSL app with initial models and admin configuration.
Created VslDest model with fields for ID, name, creation date, and update date.
Added VslConfig to settings.py.
Configured admin interface for VslDest.
Initialized migrations for VslDest model.
Included basic test and view files for future development.
2025-06-04 15:04:13 +00:00
github-actions[bot]
9702c54572 Increment version to v3.1.69 2025-05-07 14:23:05 +00:00
241b04e6ff change gitea runner contrainte
Some checks failed
Build and Push Docker Image / build (push) Failing after 1m37s
2025-05-07 14:21:51 +00:00
1dc776d888 Merge branch 'master' of https://gitea.prod.resk-u.ch/CLERC/Reskreen
Some checks failed
Build and Push Docker Image / build (push) Has been cancelled
2025-05-07 14:15:53 +00:00
3802a3ce61 changer volume reskreen-data 2025-05-07 14:15:51 +00:00
github-actions[bot]
6688861a95 Increment version to v3.1.68 2025-04-15 15:24:55 +00:00
15 changed files with 131 additions and 7 deletions

View File

@@ -9,7 +9,7 @@ on:
jobs:
build:
if: github.actor != 'github-actions[bot]'
runs-on: self-hosted
#runs-on: self-hosted
container:
image: alpine:latest
steps:

View File

@@ -52,6 +52,7 @@ INSTALLED_APPS = [
'studenteval.apps.StudentevalConfig',
'comm_op.apps.CommOpConfig',
'custom_admin.apps.CustomAdminConfig',
'vsl.apps.VslConfig',
'rangefilter',
'django.contrib.admin',
'carnet_rouge.apps.CarnetRougeConfig',

View File

@@ -1 +1 @@
v3.1.67
v3.1.69

View File

@@ -67,11 +67,7 @@ networks:
external: true
volumes:
reskreen-data:
driver: local
driver_opts:
device: /home/prod/Reskreen
o: bind
type: none
configs:
env-reskreen-frontend:
external: true

0
vsl/__init__.py Normal file
View File

11
vsl/admin.py Normal file
View File

@@ -0,0 +1,11 @@
from django.contrib import admin
from vsl.models import VslDest
@admin.register(VslDest)
class vsl_destAdmin(admin.ModelAdmin):
list_display = ('id', 'name')
ordering = ('id',)
list_per_page = 100
search_fields = ('name',)

6
vsl/apps.py Normal file
View File

@@ -0,0 +1,6 @@
from django.apps import AppConfig
class VslConfig(AppConfig):
default_auto_field = 'django.db.models.BigAutoField'
name = 'vsl'

View File

@@ -0,0 +1,23 @@
# Generated by Django 5.0.10 on 2025-06-04 16:48
from django.db import migrations, models
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='VslDest',
fields=[
('id', models.AutoField(primary_key=True, serialize=False, verbose_name='ID du Suivi')),
('name', models.CharField(max_length=255, verbose_name='Dénomination')),
('date_creation', models.DateTimeField(auto_now_add=True, verbose_name='Date de création')),
('date_modification', models.DateTimeField(auto_now=True, verbose_name='Date de modification')),
],
),
]

View File

@@ -0,0 +1,23 @@
# Generated by Django 5.0.10 on 2025-06-04 16:49
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('vsl', '0001_initial'),
]
operations = [
migrations.RenameField(
model_name='vsldest',
old_name='date_creation',
new_name='dtCreate',
),
migrations.RenameField(
model_name='vsldest',
old_name='date_modification',
new_name='dtUpdate',
),
]

View File

@@ -0,0 +1,18 @@
# Generated by Django 5.0.10 on 2025-06-04 16:50
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('vsl', '0002_rename_date_creation_vsldest_dtcreate_and_more'),
]
operations = [
migrations.RenameField(
model_name='vsldest',
old_name='name',
new_name='dest',
),
]

View File

@@ -0,0 +1,18 @@
# Generated by Django 5.0.10 on 2025-06-04 16:51
from django.db import migrations
class Migration(migrations.Migration):
dependencies = [
('vsl', '0003_rename_name_vsldest_dest'),
]
operations = [
migrations.RenameField(
model_name='vsldest',
old_name='dest',
new_name='name',
),
]

View File

22
vsl/models.py Normal file
View File

@@ -0,0 +1,22 @@
from django.db import models
class VslDest(models.Model):
# ID auto-incrémenté par défaut
id = models.AutoField("ID du Suivi", primary_key=True)
# Champ de chaîne de caractères avec une longueur maximale de 255 caractères
name = models.CharField("Dénomination", max_length=255)
# Champ pour la date de création, automatiquement défini à la création
dtCreate = models.DateTimeField("Date de création", auto_now_add=True)
# Champ pour la date de modification, automatiquement mis à jour à chaque modification
dtUpdate = models.DateTimeField("Date de modification", auto_now=True)
def __str__(self):
return self.name
class Meta:
verbose_name = "Destination VSL"
verbose_name_plural = "Destinations VSL"
ordering = ["id"]

3
vsl/tests.py Normal file
View File

@@ -0,0 +1,3 @@
from django.test import TestCase
# Create your tests here.

3
vsl/views.py Normal file
View File

@@ -0,0 +1,3 @@
from django.shortcuts import render
# Create your views here.