Commit d8ae5338 authored by LE GAC Renaud's avatar LE GAC Renaud
Browse files

Inhibit the delete or the update of the row containing undef value.

parent f65801ca
......@@ -75,6 +75,7 @@
"can be applied on any field of the table using the where syntax. don't work with the foreign table (see smart_query in the web2py)": "can be applied on any field of the table using the where syntax. don't work with the foreign table (see smart_query in the web2py)",
"Can't access the MySQL database !!!": "La base de données MySQL n'est pas accesible !!!",
"Can't delete a publication marked OK.": 'Impossible de détruire une publication marquée OK.',
"Can't delete the undef row.": "Can't delete the undef row.",
"Can't delete this record since several publications refer to it.": 'Impossible de détruire cet enregistrement car des publications lui font référence.',
"Can't insert the article.": 'Impossible de créer cet article.',
"Can't insert the report.": 'Impossible de créer ce rapport.',
......@@ -616,6 +617,9 @@
'Year End': 'Année de fin',
'Year of the publication': 'Année de la publication',
'Year Start': 'Année de début',
'You can not delete the row containing the undefined value.': 'Vous ne pouvez pas détruire la ligne contenant la valeur "indéfini".',
'You can not delete the undef row.': 'You can not delete the undef row.',
'You can not update the row containing the undefined value.': 'Vous ne pouvez pas modifier la ligne contenant la valeur "indéfini".',
'Éditeurs': 'Éditeurs',
'Équipes': 'Équipes',
}
......@@ -8,4 +8,6 @@ db.define_table("authors_roles",
Field("role", "string", length=255, default="", notnull=True),
migrate="authors_roles.table")
db.authors_roles._before_delete.append(INHIBIT_CASCADE_DELETE)
\ No newline at end of file
db.authors_roles._before_delete.append(INHIBIT_CASCADE_DELETE)
db.authors_roles._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.authors_roles._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
......@@ -10,6 +10,10 @@ db.define_table("categories",
migrate="categories.table")
db.categories._before_delete.append(INHIBIT_CASCADE_DELETE)
db.categories._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.categories._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
db.categories.usual.requires = dbui.IS_IN_USET(CAT_USUAL)
db.categories.code.filter_in = dbui.CLEAN_SPACES
db.categories.usual.filter_in = dbui.CLEAN_SPACES
\ No newline at end of file
......@@ -7,4 +7,7 @@ db.define_table("collaborations",
migrate="collaborations.table")
db.collaborations._before_delete.append(INHIBIT_CASCADE_DELETE)
db.collaborations._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.collaborations._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
db.collaborations.collaboration.filter_in = filters.CLEAN_COLLABORATION
\ No newline at end of file
......@@ -7,4 +7,7 @@ db.define_table("countries",
migrate="countries.table")
db.countries._before_delete.append(INHIBIT_CASCADE_DELETE)
db.countries._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.countries._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
db.countries.country.filter_in = dbui.CLEAN_SPACES
\ No newline at end of file
......@@ -8,4 +8,7 @@ db.define_table("projects",
migrate="projects.table")
db.projects._before_delete.append(INHIBIT_CASCADE_DELETE)
db.projects._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.projects._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
db.projects.project.filter_in = dbui.CLEAN_SPACES
\ No newline at end of file
......@@ -8,5 +8,8 @@ db.define_table("publishers",
migrate="publishers.table")
db.publishers._before_delete.append(INHIBIT_CASCADE_DELETE)
db.publishers._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.publishers._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
db.publishers.publisher.filter_in = dbui.CLEAN_SPACES
db.publishers.abbreviation.filter_in = filters.CLEAN_REVIEW
\ No newline at end of file
......@@ -6,4 +6,6 @@ db.define_table("reports",
Field("type", "string", length=255, notnull=True, unique=True),
migrate="reports.table")
db.reports._before_delete.append(INHIBIT_CASCADE_DELETE)
\ No newline at end of file
db.reports._before_delete.append(INHIBIT_CASCADE_DELETE)
db.reports._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.reports._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
......@@ -7,4 +7,6 @@ db.define_table("status",
Field("definition", "text", notnull=True),
migrate="status.table")
db.status._before_delete.append(INHIBIT_CASCADE_DELETE)
\ No newline at end of file
db.status._before_delete.append(INHIBIT_CASCADE_DELETE)
db.status._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.status._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
......@@ -8,5 +8,8 @@ db.define_table("teams",
migrate="teams.table")
db.teams._before_delete.append(INHIBIT_CASCADE_DELETE)
db.teams._before_delete.append(dbui.INHIBIT_DELETE_UNDEF)
db.teams._before_update.append(dbui.INHIBIT_UPDATE_UNDEF)
db.teams.team.filter_in = dbui.CLEAN_SPACES
db.teams.domain.filter_in = dbui.CLEAN_SPACES
\ No newline at end of file
......@@ -2,15 +2,17 @@
HEAD
- Migrate to plugin_dbui 0.6.1.10.
- Consolidate harvesters software.
- Modify the logic of the harvester by introducing the class CheckAndFix.
Modify the logic of the harvester by introducing the class CheckAndFix.
Validation and corrections of each record is performed at only one place.
Should improve code stability and maintenance.
- Review class naming of the invenio and harvester tools modules.
- Improve the UI related to the harvester/controller and publication.
- Improve the UI related to the categories, harvester/controller and publication.
- New wizard EditAndInsert.
It can be run standalone or launched from the harvester report.
- Refactor the ux files to ease the buiding of a new database from scratch.
- Use the new callbacks INHIBIT_DELETE_UNDEF and INHIBIT_UPDATE_UNDEF.
0.8.7.2 (Sep 2014)
- Migrate to plugin_dbui 0.6.1.7.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment