-
Notifications
You must be signed in to change notification settings - Fork 292
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Ands and reworks models and uses db namespace.
- Loading branch information
1 parent
a366e2d
commit 3880f2e
Showing
59 changed files
with
9,116 additions
and
61 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,9 +20,7 @@ | |
## script. | ||
|
||
## Initialize autoconf and automake: | ||
AC_INIT([invenio], | ||
m4_esyscmd([./git-version-gen .tarball-version]), | ||
[[email protected]]) | ||
AC_INIT([invenio],[m4_esyscmd(./git-version-gen .tarball-version)],[[email protected]]) | ||
AM_INIT_AUTOMAKE([tar-ustar]) | ||
|
||
## By default we shall install into /opt/invenio. (Do not use | ||
|
@@ -42,7 +40,7 @@ AM_GNU_GETTEXT_VERSION(0.14.4) | |
|
||
## Check for MySQL client: | ||
AC_MSG_CHECKING(for mysql) | ||
AC_ARG_WITH(mysql, AC_HELP_STRING([--with-mysql], [path to a specific MySQL binary (optional)]), MYSQL=${withval}) | ||
AC_ARG_WITH(mysql, AS_HELP_STRING([--with-mysql],[path to a specific MySQL binary (optional)]), MYSQL=${withval}) | ||
if test -n "$MYSQL"; then | ||
AC_MSG_RESULT($MYSQL) | ||
else | ||
|
@@ -57,7 +55,7 @@ fi | |
|
||
## Check for Python: | ||
AC_MSG_CHECKING(for python) | ||
AC_ARG_WITH(python, AC_HELP_STRING([--with-python], [path to a specific Python binary (optional)]), PYTHON=${withval}) | ||
AC_ARG_WITH(python, AS_HELP_STRING([--with-python],[path to a specific Python binary (optional)]), PYTHON=${withval}) | ||
if test -n "$PYTHON"; then | ||
AC_MSG_RESULT($PYTHON) | ||
else | ||
|
@@ -72,7 +70,7 @@ fi | |
|
||
## Check for OpenOffice.org Python binary: | ||
AC_MSG_CHECKING(for OpenOffice.org Python binary) | ||
AC_ARG_WITH(openoffice-python, AC_HELP_STRING([--with-openoffice-python], [path to a specific OpenOffice.org Python binary (optional)]), OPENOFFICE_PYTHON=`which ${withval}`) | ||
AC_ARG_WITH(openoffice-python, AS_HELP_STRING([--with-openoffice-python],[path to a specific OpenOffice.org Python binary (optional)]), OPENOFFICE_PYTHON=`which ${withval}`) | ||
|
||
if test -z "$OPENOFFICE_PYTHON"; then | ||
OPENOFFICE_PYTHON=`locate -l 1 -r "o.*office/program/python$"` | ||
|
@@ -415,7 +413,7 @@ fi | |
|
||
## Check for CLISP: | ||
AC_MSG_CHECKING(for clisp) | ||
AC_ARG_WITH(clisp, AC_HELP_STRING([--with-clisp], [path to a specific CLISP binary (optional)]), CLISP=${withval}) | ||
AC_ARG_WITH(clisp, AS_HELP_STRING([--with-clisp],[path to a specific CLISP binary (optional)]), CLISP=${withval}) | ||
if test -n "$CLISP"; then | ||
AC_MSG_RESULT($CLISP) | ||
else | ||
|
@@ -434,7 +432,7 @@ fi | |
|
||
## Check for CMUCL: | ||
AC_MSG_CHECKING(for cmucl) | ||
AC_ARG_WITH(cmucl, AC_HELP_STRING([--with-cmucl], [path to a specific CMUCL binary (optional)]), CMUCL=${withval}) | ||
AC_ARG_WITH(cmucl, AS_HELP_STRING([--with-cmucl],[path to a specific CMUCL binary (optional)]), CMUCL=${withval}) | ||
if test -n "$CMUCL"; then | ||
AC_MSG_RESULT($CMUCL) | ||
else | ||
|
@@ -457,7 +455,7 @@ fi | |
|
||
## Check for SBCL: | ||
AC_MSG_CHECKING(for sbcl) | ||
AC_ARG_WITH(sbcl, AC_HELP_STRING([--with-sbcl], [path to a specific SBCL binary (optional)]), SBCL=${withval}) | ||
AC_ARG_WITH(sbcl, AS_HELP_STRING([--with-sbcl],[path to a specific SBCL binary (optional)]), SBCL=${withval}) | ||
if test -n "$SBCL"; then | ||
AC_MSG_RESULT($SBCL) | ||
else | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,221 @@ | ||
# -*- coding: utf-8 -*- | ||
# | ||
## Author: Jiri Kuncar <[email protected]> | ||
## | ||
## This file is part of Invenio. | ||
## Copyright (C) 2011, 2012 CERN. | ||
## | ||
## Invenio is free software; you can redistribute it and/or | ||
## modify it under the terms of the GNU General Public License as | ||
## published by the Free Software Foundation; either version 2 of the | ||
## License, or (at your option) any later version. | ||
## | ||
## Invenio is distributed in the hope that it will be useful, but | ||
## WITHOUT ANY WARRANTY; without even the implied warranty of | ||
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
## General Public License for more details. | ||
## | ||
## You should have received a copy of the GNU General Public License | ||
## along with Invenio; if not, write to the Free Software Foundation, Inc., | ||
## 59 Temple Place, Suite 330, Boston, MA 02D111-1307, USA. | ||
|
||
""" | ||
bibauthorid database models. | ||
""" | ||
|
||
# General imports. | ||
from invenio.sqlalchemyutils import db | ||
|
||
# Create your models here. | ||
|
||
#FIX ME Add db.relationships | ||
|
||
class AidAUTHORNAMES(db.Model): | ||
"""Represents a AidAUTHORNAMES record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidAUTHORNAMES' | ||
__table_args__ = {'useexisting':True}#, 'extend_existing': True} | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
Name = db.Column(db.String(255), nullable=False, | ||
index=True) | ||
bibrefs = db.Column(db.String(200), nullable=False, | ||
index=True) | ||
db_name = db.Column(db.String(255), nullable=True, | ||
index=True) | ||
|
||
class AidAUTHORNAMESBIBREFS(db.Model): | ||
"""Represents a AidAUTHORNAMESBIBREFS record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidAUTHORNAMESBIBREFS' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
Name_id = db.Column(db.BigInteger(15), nullable=False, | ||
index=True) | ||
bibref = db.Column(db.String(200), nullable=False, | ||
index=True) | ||
|
||
class AidCACHE(db.Model): | ||
"""Represents a AidCACHE record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidCACHE' | ||
id = db.Column(db.Integer(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
object_name = db.Column(db.String(120), nullable=False, | ||
index=True) | ||
object_key = db.Column(db.String(120), nullable=False, | ||
index=True) | ||
object_value = db.Column(db.Text, nullable=True) | ||
last_updated = db.Column(db.DateTime, nullable=False, | ||
index=True) | ||
|
||
|
||
class AidDOCLIST(db.Model): | ||
"""Represents a AidDOCLIST record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidDOCLIST' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
bibrecID = db.Column(db.BigInteger(15), nullable=False, | ||
index=True) | ||
processed_author = db.Column(db.BigInteger(15), nullable=True, | ||
index=True) | ||
|
||
class AidPERSONID(db.Model): | ||
"""Represents a AidPERSONID record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidPERSONID' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
personid = db.Column(db.BigInteger(15), nullable=False, | ||
index=True) | ||
tag = db.Column(db.String(50), nullable=False, | ||
index=True) | ||
data = db.Column(db.String(250), nullable=False, | ||
index=True) | ||
flag = db.Column(db.Integer(11), nullable=False, server_default='0', | ||
index=True) | ||
lcul = db.Column(db.Integer(11), nullable=False, server_default='0', | ||
index=True) | ||
#__table_args__ = {#'indexes': (db.Index('tdf-b', tag, data, flag), | ||
# # db.Index('ptf-b', personid, data, flag)), | ||
# 'extend_existing': True} | ||
|
||
class AidREALAUTHORDATA(db.Model): | ||
"""Represents a AidREALAUTHORDATA record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidREALAUTHORDATA' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
realauthorID = db.Column(db.BigInteger(15), nullable=False) | ||
tag = db.Column(db.String(50), nullable=False, | ||
index=True) | ||
value = db.Column(db.String(255), nullable=False, | ||
index=True) | ||
va_count = db.Column(db.Integer(8), nullable=False, | ||
server_default='0') | ||
va_names_p = db.Column(db.Double, nullable=False, | ||
server_default='0') | ||
va_p = db.Column(db.Double, nullable=False, server_default='0') | ||
#__table_args__ = (db.Index('realauthorID-b', realauthorID, tag), | ||
# {}) | ||
|
||
|
||
class AidUSERINPUTLOG(db.Model): | ||
"""Represents a AidUSERINPUTLOG record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidUSERINPUTLOG' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
transactionid = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True, index=True) | ||
timestamp = db.Column(db.DateTime, nullable=False, | ||
index=True) | ||
userinfo = db.Column(db.String(255), nullable=False, | ||
index=True) | ||
personid = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True, index=True) | ||
action = db.Column(db.String(50), nullable=False, | ||
index=True) | ||
tag = db.Column(db.String(50), nullable=False, | ||
index=True) | ||
value = db.Column(db.String(200), nullable=False, | ||
index=True) | ||
comment = db.Column(db.Text, nullable=True) | ||
|
||
class AidVIRTUALAUTHORS(db.Model): | ||
"""Represents a AidVIRTUALAUTHORS record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidVIRTUALAUTHORS' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
virtualauthorID = db.Column(db.BigInteger(15), | ||
db.ForeignKey(AidAUTHORNAMES.id), | ||
nullable=False, index=True) | ||
authornamesID = db.Column(db.BigInteger(15), nullable=False, | ||
index=True) | ||
p = db.Column(db.Float, nullable=False) | ||
clusterID = db.Column(db.BigInteger(15), nullable=False, | ||
server_default='0', | ||
index=True) | ||
|
||
class AidVIRTUALAUTHORSCLUSTERS(db.Model): | ||
"""Represents a AidVIRTUALAUTHORSCLUSTERS record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidVIRTUALAUTHORSCLUSTERS' | ||
id = db.Column(db.Integer(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
cluster_name = db.Column(db.String(60), nullable=False) | ||
|
||
class AidVIRTUALAUTHORSDATA(db.Model): | ||
"""Represents a AidVIRTUALAUTHORSDATA record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidVIRTUALAUTHORSDATA' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
virtualauthorID = db.Column(db.BigInteger(15), | ||
db.ForeignKey(AidVIRTUALAUTHORS.id), | ||
nullable=False, index=True) | ||
tag = db.Column(db.String(255), nullable=False, | ||
index=True) | ||
value = db.Column(db.String(255), nullable=False, | ||
index=True) | ||
|
||
class AidREALAUTHORS(db.Model): | ||
"""Represents a AidREALAUTHORS record.""" | ||
def __init__(self): | ||
pass | ||
__tablename__ = 'aidREALAUTHORS' | ||
id = db.Column(db.BigInteger(15), nullable=False, | ||
primary_key=True, | ||
autoincrement=True) | ||
realauthorID = db.Column(db.BigInteger(15), nullable=False, | ||
index=True) | ||
virtualauthorID = db.Column(db.BigInteger(15), | ||
db.ForeignKey(AidVIRTUALAUTHORS.id), | ||
nullable=False, index=True) | ||
p = db.Column(db.Float, nullable=False) | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.