Coder Social home page Coder Social logo

django-redmine-models's Introduction

django-redmine-models

PyPI Version

Using django-redmine-models

Define the database parameters as usual in the DATABASES setting then add:

REDMINE_DATABASE = "the-redmine-db-key-in-DATABASES"

and define (or add) the database router:

DATABASE_ROUTERS = ["redmine_models.routers.DatabaseRouter"]

By default, it is supposed that an external redmine service is being accessed, and thus the models are unmanaged. If that's not desired, e.g. for testing you want the test tables to be created automatically, use the following setting:

REDMINE_MODELS_MANAGED = True

Then use the models:

from redmine_models.models import Project
print Project.objects.all()
# etc...

django-redmine-models's People

Contributors

immerrr avatar meschenbacher avatar zvin avatar

Watchers

 avatar

django-redmine-models's Issues

Structural incompatibility between database model changesets_issues and django

The ChangesetsIssue model uses a primary key consisting of two columns (changeset_id, issue_id) and while we're able to model that as a unique constraint with django, django does not support multi column primary keys (https://code.djangoproject.com/wiki/MultipleColumnPrimaryKeys).

Without a AutoField or a field with primary_key=True, django automatically adds a primary key, resulting in non-recoverable run time errors because it is looking for a changesets_issues.id column.

I'm not sure how to continue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.