""" % (weburl, ln, weburl, ln, weburl, ln, weburl, ln)
if mtype == "perform_showfields" and content:
fin_output += content
elif mtype == "perform_showfields" or not mtype:
fin_output += perform_showfields(ln, callback='')
if mtype == "perform_addfield" and content:
fin_output += content
elif mtype == "perform_addfield" or not mtype:
fin_output += perform_addfield(ln, callback='')
if mtype == "perform_showdetails" and content:
fin_output += content
elif mtype == "perform_showdetails" or not mtype:
fin_output += perform_showdetails(ln, callback='')
return addadminbox("Overview of BibIndex Interface", [fin_output])
def perform_showfields(ln=cdslang, callback='yes', content='', confirm=-1):
"""show the sort fields of this collection.."""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
fld_type = get_fld_nametypes()
subtitle = """1. Edit logical field   [?]""" % (weburl)
fin_output = ''
res = get_fld()
output = ""
if len(res) > 0:
text = """
Field name
"""
output += createhiddenform(action="%s/admin/bibindex/bibindexadmin.py/showfield" % weburl,
text=text,
button="Edit",
ln=ln,
confirm=1)
else:
output += """No logical fields exists"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_index(ln, "perform_showfields", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showfield(fldID, ln=cdslang, mtype='', content='', callback='yes', confirm=-1):
"""form to modify a collection. this method is calling other methods which again is calling this and sending back the output of the method.
if callback, the method will call perform_editcollection, if not, it will just return its output.
colID - id of the collection
mtype - the method that called this method.
content - the output from that method."""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
if fldID in [-1, "-1"]:
return addadminbox("Edit logical field", ["""Please go back and select a logical field"""])
fin_output = """
""" % (weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln)
if mtype == "perform_modifyfield" and content:
fin_output += content
elif mtype == "perform_modifyfield" or not mtype:
fin_output += perform_modifyfield(fldID, ln, callback='')
if mtype == "perform_modifytranslations" and content:
fin_output += content
elif mtype == "perform_modifytranslations" or not mtype:
fin_output += perform_modifytranslations(fldID, ln, callback='')
if mtype == "perform_showfieldtags" and content:
fin_output += content
elif mtype == "perform_showfieldtags" or not mtype:
fin_output += perform_showfieldtags(fldID, ln, callback='')
if mtype == "perform_deletefield" and content:
fin_output += content
elif mtype == "perform_deletefield" or not mtype:
fin_output += perform_deletefield(fldID, ln, callback='')
if mtype == "perform_showdetailsfield" and content:
fin_output += content
elif mtype == "perform_showdetailsfield" or not mtype:
fin_output += perform_showdetailsfield(fldID,ln, callback='')
return addadminbox("Edit logical field '%s'" % fld_dict[int(fldID)], [fin_output])
def perform_modifytranslations(fldID, ln=cdslang, sel_type='', trans=[], confirm=-1, callback='yes'):
"""Modify the translations of a field
sel_type - the nametype to modify
trans - the translations in the same order as the languages from get_languages()"""
output = ''
subtitle = ''
cdslangs = get_languages()
if confirm in ["2", 2] and fldID:
finresult = modify_translations(fldID, cdslangs, sel_type, trans, "field")
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
if fldID and fld_dict.has_key(int(fldID)):
fldID = int(fldID)
subtitle = """3. Modify translations for logical field '%s'   [?]""" % (fld_dict[fldID], weburl)
if type(trans) is str:
trans = [trans]
if sel_type == '':
sel_type = get_fld_nametypes()[0][0]
header = ['Language', 'Translation']
actions = []
types = get_fld_nametypes()
if len(types) > 1:
text = """
Name type
"""
output += createhiddenform(action="modifytranslations#3",
text=text,
button="Select",
fldID=fldID,
ln=ln,
confirm=0)
if confirm in [-1, "-1", 0, "0"]:
trans = []
for (key, value) in cdslangs:
try:
trans_names = get_name(fldID, key, sel_type, "field")
trans.append(trans_names[0][0])
except StandardError, e:
trans.append('')
for nr in range(0,len(cdslangs)):
actions.append(["%s %s" % (cdslangs[nr][1], (cdslangs[nr][0]==cdslang and '(def)' or ''))])
actions[-1].append('' % trans[nr])
text = tupletotable(header=header, tuple=actions)
output += createhiddenform(action="modifytranslations#3",
text=text,
button="Modify",
fldID=fldID,
sel_type=sel_type,
ln=ln,
confirm=2)
if sel_type and len(trans):
if confirm in ["1", 1]:
text = """Please confirm modification of translations for logical field '%s'.""" % (fld_dict[fldID])
output += createhiddenform(action="modifytranslations#3",
text=text,
button="Confirm",
fldID=fldID,
sel_type=sel_type,
trans=trans,
ln=ln,
confirm=2)
elif confirm in ["2", 2]:
if finresult:
output += """Translations modified."""
else:
output += """Sorry, could not modify translations."""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfield(fldID, ln, "perform_modifytranslations", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showdetailsfieldtag(fldID, tagID, ln=cdslang, callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
fldID = int(fldID)
tagname = run_sql("SELECT name from tag where id=%s" % tagID)[0][0]
output = ""
subtitle = """Showing details for MARC tag '%s'""" % tagname
output += " This MARC tag is used directly in these logical fields: "
fld_tag = get_fld_tags('', tagID)
exist = {}
for (id_field,id_tag, tname, tvalue, score) in fld_tag:
output += "%s, " % fld_dict[int(id_field)]
exist[id_field] = 1
output += " This MARC tag is used indirectly in these logical fields: "
tag = run_sql("SELECT value from tag where id=%s" % id_tag)
tag = tag[0][0]
for i in range(0, len(tag) - 1):
res = run_sql("SELECT id_field,id_tag FROM field_tag,tag WHERE tag.id=field_tag.id_tag AND tag.value='%s%%'" % tag[0:i])
for (id_field, id_tag) in res:
output += "%s, " % fld_dict[int(id_field)]
exist[id_field] = 1
res = run_sql("SELECT id_field,id_tag FROM field_tag,tag WHERE tag.id=field_tag.id_tag AND tag.value like '%s'" % tag)
for (id_field, id_tag) in res:
if not exist.has_key(id_field):
output += "%s, " % fld_dict[int(id_field)]
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_showdetailsfieldtag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showdetailsfield(fldID, ln=cdslang, callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
col_dict = dict(get_current_name('', ln, get_col_nametypes()[0][0], "collection"))
fldID = int(fldID)
col_fld = get_col_fld('', '', fldID)
sort_types = dict(get_sort_nametypes())
fin_output = ""
subtitle = """5. Show usage for logical field '%s'""" % fld_dict[fldID]
output = "This logical field is used in these collections: "
ltype = ''
exist = {}
for (id_collection, id_field, id_fieldvalue, ftype, score, score_fieldvalue) in col_fld:
if ltype != ftype:
output += " %s: " % sort_types[ftype]
ltype = ftype
exist = {}
if not exist.has_key(id_collection):
output += "%s, " % col_dict[int(id_collection)]
exist[id_collection] = 1
if not col_fld:
output = "This field is not used by any collections."
fin_output = addadminbox('Collections', [output])
try:
body = [fin_output, extra]
except NameError:
body = [fin_output]
if callback:
return perform_showfield(ln, "perform_showdetailsfield", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_addfield(ln=cdslang, fldNAME='', code='', callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
output = ""
subtitle = """2. Add new logical field"""
code = str.replace(code,' ', '')
text = """
Field name Field code
""" % (fldNAME, code)
output = createhiddenform(action="%s/admin/bibindex/bibindexadmin.py/addfield" % weburl,
text=text,
ln=ln,
button="Add field",
confirm=1)
if fldNAME and code and confirm in ["1", 1]:
res = add_fld(fldNAME, code)
if res:
output += """Added new logical field.
"""
else:
output += """Sorry, could not add logical field, most likely the field already exists.
"""
elif confirm not in ["-1", -1]:
output += """Please give the logical field a name and code.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_index(ln, "perform_addfield", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_deletefield(fldID, ln=cdslang, callback='yes', confirm=0):
"""form to remove a field.
fldID - the field id from table field.
"""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
subtitle = """4. Delete the logical field '%s'   [?]""" % (fld_dict[int(fldID)], weburl)
output = ""
if fldID:
fldID = int(fldID)
if confirm in ["0", 0]:
check = run_sql("SELECT * from idxINDEX_field where id_field=%s" % fldID)
text = ""
if check:
text += """This field is used in an index, deletion may cause problems. """
text += """Do you want to delete the logical field '%s' and all its relations and definitions.""" % (fld_dict[fldID])
output += createhiddenform(action="deletefield#5",
text=text,
button="Confirm",
fldID=fldID,
confirm=1)
elif confirm in ["1", 1]:
res = delete_fld(fldID)
if res:
return """Deleted the logical field '%s'.
""" % (fld_dict[fldID])
else:
return """Cannot delete the logical field.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfield(fldID, ln, "perform_deletefield", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showdetails(ln=cdslang, callback='', confirm=0):
subtitle = """3. Logical fields overview"""
output = """
"""
output += """
%s
%s
%s
""" % ("Field", "MARC Tags", "Translations")
query = "SELECT id,name FROM field"
res = run_sql(query)
col_dict = dict(get_current_name('', ln, get_col_nametypes()[0][0], "collection"))
for field_id,field_name in res:
query = "SELECT tag.value FROM tag, field_tag WHERE tag.id=field_tag.id_tag AND field_tag.id_field=%d ORDER BY field_tag.score DESC,tag.value ASC" % field_id
res = run_sql(query)
field_tags = ""
for row in res:
field_tags = field_tags + row[0] + ", "
if field_tags.endswith(", "):
field_tags = field_tags[:-2]
cdslangs = dict(get_languages())
langs = run_sql("select ln from fieldname where id_field=%s" % field_id)
exists = {}
lang = ''
for lng in langs:
if not exists.has_key(lng[0]):
lang += lng[0] + ", "
exists[lng[0]] = 1
if lang.endswith(", "):
lang = lang [:-2]
if len(exists) == 0:
lang = """None"""
col_fld = get_col_fld('', '', field_id)
cols = ''
exists = {}
for (id_collection, id_field, id_fieldvalue, ftype, score, score_fieldvalue) in col_fld:
if not exists.has_key(id_collection):
cols = cols + col_dict[int(id_collection)]+ ", "
exists[id_collection] = 1
if len(exists) == 0:
cols = """None"""
if cols.endswith(", "):
cols = cols[:-2]
output += """
"""
actions.append([move, tvalue, tname])
for col in [(('Details','showdetailsfieldtag'), ('Modify','modifytag'),('Remove','removefieldtag'),)]:
actions[-1].append('%s' % (weburl, col[0][1], fldID, tagID, ln, col[0][0]))
for (str, function) in col[1:]:
actions[-1][-1] += ' / %s' % (weburl, function, fldID, tagID, ln, str)
output += tupletotable(header=header, tuple=actions)
else:
output += """No fields exists"""
output += content
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfield(fldID, ln, "perform_showfieldtags", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_addtag(fldID, ln=cdslang, value=['',-1], name='', callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
output = ""
subtitle = """Add MARC tag to logical field"""
text = """
Add new tag: Tag value Tag comment
""" % ((name=='' and value[0] or name), value[0])
text += """Or existing tag: Tag
"""
output = createhiddenform(action="%s/admin/bibindex/bibindexadmin.py/addtag" % weburl,
text=text,
fldID=fldID,
ln=ln,
button="Add tag",
confirm=1)
if (value[0] and value[1] in [-1, "-1"]) or (not value[0] and value[1] not in [-1, "-1"]):
if confirm in ["1", 1]:
res = add_fld_tag(fldID, name, (value[0] !='' and value[0] or value[1]))
if res:
output += """Added new MARC tag with value'%s'
""" % (value[0] !='' and value[0] or value[1])
else:
output += """Sorry, could not add MARC tag, most likely the tag already exists in the logical field.
"""
elif confirm not in ["-1", -1]:
output += """Please choose to add either a new or an existing MARC tag, but not both.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_addtag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_modifytag(fldID, tagID, ln=cdslang, name='', value='', callback='yes', confirm=-1):
"""form to modify a field.
fldID - the field to change."""
subtitle = ""
output = ""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
fldID = int(fldID)
tagID = int(tagID)
tag = get_tags(tagID)
if confirm in [-1, "-1"] and not value and not name:
name = tag[0][1]
value = tag[0][2]
subtitle = """Modify MARC tag"""
text = """
Any modifications will apply to all logical fields using this tag. Tag value Comment
""" % (name, value)
output += createhiddenform(action="modifytag#4.1",
text=text,
button="Modify",
fldID=fldID,
tagID=tagID,
ln=ln,
confirm=1)
if name and value and confirm in [1, "1"]:
res = modify_tag(tagID, name, value)
if res:
output += """Modified the MARC tag.
"""
else:
output += """Cannot modify the MARC tag.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_modifytag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_removefieldtag(fldID, tagID, ln=cdslang, callback='yes', confirm=0):
"""form to remove a portalbox from a collection.
colID - the current collection, remove the portalbox from this collection.
sel_ln - remove the portalbox with this language
pbxID - remove the portalbox with this id"""
subtitle = """Remove MARC tag from logical field"""
output = ""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
if fldID and tagID:
fldID = int(fldID)
tagID = int(tagID)
tag = get_fld_tags(fldID, tagID)
if confirm not in ["1", 1]:
text = """Do you want to remove the tag '%s - %s ' from the field '%s'.""" % (tag[0][3], tag[0][2], fld_dict[fldID])
output += createhiddenform(action="removefieldtag#4.1",
text=text,
button="Confirm",
fldID=fldID,
tagID=tagID,
confirm=1)
elif confirm in ["1", 1]:
res = remove_fldtag(fldID, tagID)
if res:
output += """Removed the tag from the logical field.
"""
else:
output += """Cannot remove the tag from the logical field.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_removefieldtag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_switchtagscore(fldID, id_1, id_2, ln=cdslang):
"""Switch the score of id_1 and id_2 in the table type.
colID - the current collection
id_1/id_2 - the id's to change the score for.
type - like "format" """
output = ""
name_1 = run_sql("select name from tag where id=%s" % id_1)[0][0]
name_2 = run_sql("select name from tag where id=%s" % id_2)[0][0]
if switch_score(fldID, id_1, id_2):
output = """ '%s' changed position with '%s'
""" % (name_1, name_2)
else:
output = """ Could not complete the operation."""
return perform_showfieldtags(fldID, ln, content=output)
def perform_deletetag(fldID, ln=cdslang, tagID=-1, callback='yes', confirm=-1):
"""form to delete an MARC tag not in use.
fldID - the collection id of the current collection.
fmtID - the format id to delete."""
subtitle = """Delete an unused MARC tag"""
output = """
Deleting an MARC tag will also delete the translations associated.
"""
fldID = int(fldID)
if tagID not in [-1," -1"] and confirm in [1, "1"]:
ares = delete_tag(tagID)
fld_tag = get_fld_tags()
fld_tag = dict(map(lambda x: (x[1], x[0]), fld_tag))
tags = get_tags()
text = """
MARC tag """
if i == 0:
output += """No unused MARC tags """
else:
output += createhiddenform(action="deletetag#4.1",
text=text,
button="Delete",
fldID=fldID,
ln=ln,
confirm=0)
if tagID not in [-1,"-1"]:
tagID = int(tagID)
tags = get_tags(tagID)
if confirm in [0, "0"]:
text = """Do you want to delete the MARC tag '%s'.
""" % tags[0][2]
output += createhiddenform(action="deletetag#4.1",
text=text,
button="Confirm",
fldID=fldID,
tagID=tagID,
ln=ln,
confirm=1)
elif confirm in [1, "1"]:
if ares:
output += """Deleted the MARC tag.
"""
else:
output += """Cannot delete the MARC tag.
"""
elif confirm not in [-1, "-1"]:
output += """Choose a MARC tag to delete.
"""
try:
body = [output, extra]
except NameError:
body = [output]
output = " " + addadminbox(subtitle, body)
return perform_showfieldtags(fldID, ln, content=output)
def compare_on_val(first, second):
"""Compare the two values"""
return cmp(first[1], second[1])
def get_col_fld(colID=-1, type = '', id_field=''):
"""Returns either all portalboxes associated with a collection, or based on either colID or language or both.
colID - collection id
ln - language id"""
sql = "SELECT id_collection,id_field,id_fieldvalue,type,score,score_fieldvalue FROM collection_field_fieldvalue, field WHERE id_field=field.id"
try:
if id_field:
sql += " AND id_field=%s" % id_field
sql += " ORDER BY type, score desc, score_fieldvalue desc"
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_fld_tags(fldID='', tagID=''):
"""Returns either all portalboxes associated with a collection, or based on either colID or language or both.
colID - collection id
ln - language id"""
sql = "SELECT id_field,id_tag, tag.name, tag.value, score FROM field_tag,tag WHERE tag.id=field_tag.id_tag"
try:
if fldID:
sql += " AND id_field=%s" % fldID
if tagID:
sql += " AND id_tag=%s" % tagID
sql += " ORDER BY score desc, tag.value, tag.name"
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_tags(tagID=''):
"""Returns either all portalboxes associated with a collection, or based on either colID or language or both.
colID - collection id
ln - language id"""
sql = "SELECT id, name, value FROM tag"
try:
if tagID:
sql += " WHERE id=%s" % tagID
sql += " ORDER BY name, value"
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_fld(fldID=''):
"""Returns allfields"""
try:
if not fldID:
res = run_sql("SELECT id, name, code FROM field ORDER by name, code")
else:
res = run_sql("SELECT id, name, code FROM field WHERE id=%s ORDER by name, code" % fldID)
return res
except StandardError, e:
return ""
def get_fld_value(fldvID = ''):
"""Returns fieldvalue"""
try:
sql = "SELECT id, name, value FROM fieldvalue"
if fldvID:
sql += " WHERE id=%s" % fldvID
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_col_nametypes():
"""Return a list of the various translationnames for the fields"""
type = []
type.append(('ln', 'Long name'))
return type
def get_fld_nametypes():
"""Return a list of the various translationnames for the fields"""
type = []
type.append(('ln', 'Long name'))
return type
def get_sort_nametypes():
"""Return a list of the various translationnames for the fields"""
type = {}
type['soo'] = 'Sort options'
type['seo'] = 'Search options'
type['sew'] = 'Search within'
return type
def remove_fld(colID,fldID, fldvID=''):
"""Removes a field from the collection given.
colID - the collection the format is connected to
fldID - the field which should be removed from the collection."""
try:
sql = "DELETE FROM collection_field_fieldvalue WHERE id_collection=%s AND id_field=%s" % (colID, fldID)
if fldvID:
sql += " AND id_fieldvalue=%s" % fldvID
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def remove_fldtag(fldID,tagID):
"""Removes a field from the collection given.
colID - the collection the format is connected to
fldID - the field which should be removed from the collection."""
try:
sql = "DELETE FROM field_tag WHERE id_field=%s AND id_tag=%s" % (fldID, tagID)
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def delete_tag(tagID):
"""Deletes all data for the given field
fldID - delete all data in the tables associated with field and this id """
try:
res = run_sql("DELETE FROM tag where id=%s" % tagID)
return "true"
except StandardError, e:
return ""
def delete_fld(fldID):
"""Deletes all data for the given field
fldID - delete all data in the tables associated with field and this id """
try:
res = run_sql("DELETE FROM collection_field_fieldvalue WHERE id_field=%s" % fldID)
res = run_sql("DELETE FROM field_tag WHERE id_field=%s" % fldID)
res = run_sql("DELETE FROM idxINDEX_field WHERE id_field=%s" % fldID)
res = run_sql("DELETE FROM field WHERE id=%s" % fldID)
return "true"
except StandardError, e:
return ""
def add_fld(name, code):
"""Add a new output format. Returns the id of the format.
code - the code for the format, max 6 chars.
name - the default name for the default language of the format.
rtype - the default nametype"""
try:
type = get_fld_nametypes()[0][0]
res = run_sql("INSERT INTO field (name, code) values('%s','%s')" % (MySQLdb.escape_string(name), MySQLdb.escape_string(code)))
fldID = run_sql("SELECT id FROM field WHERE code='%s'" % MySQLdb.escape_string(code))
res = run_sql("INSERT INTO fieldname (id_field, type, ln, value) VALUES (%s,'%s','%s','%s')" % (fldID[0][0], type, cdslang, MySQLdb.escape_string(name)))
return fldID
except StandardError, e:
return ""
def add_fld_tag(fldID, name, value):
"""Add a sort/search/field to the collection.
colID - the id of the collection involved
fmtID - the id of the format.
score - the score of the format, decides sorting, if not given, place the format on top"""
try:
res = run_sql("SELECT score FROM field_tag WHERE id_field=%s ORDER BY score desc" % (fldID))
if res:
score = int(res[0][0]) + 1
else:
score = 0
res = run_sql("SELECT id FROM tag WHERE value='%s'" % MySQLdb.escape_string(value))
if not res:
if name == '':
name = value
res = run_sql("INSERT INTO tag(name, value) values('%s','%s')" % (MySQLdb.escape_string(name), MySQLdb.escape_string(value)))
res = run_sql("SELECT id FROM tag WHERE value='%s'" % MySQLdb.escape_string(value))
res = run_sql("INSERT INTO field_tag(id_field, id_tag, score) values(%s, %s, %s)" % (fldID, res[0][0], score))
return "true"
except StandardError, e:
return ""
def modify_fld(fldID, code):
"""Modify the dbquery of an collection.
colID - the id of the collection involved
dbquery - the new dbquery"""
try:
sql = "UPDATE field SET code='%s'" % code
sql += " WHERE id=%s" % fldID
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def modify_tag(tagID, name, value):
"""Modify the dbquery of an collection.
colID - the id of the collection involved
dbquery - the new dbquery"""
try:
sql = "UPDATE tag SET name='%s' WHERE id=%s" % (name, tagID)
res = run_sql(sql)
sql = "UPDATE tag SET value='%s' WHERE id=%s" % (value, tagID)
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def switch_score(fldID, id_1, id_2):
"""Switch the scores of id_1 and id_2 in the table given by the argument.
colID - collection the id_1 or id_2 is connected to
id_1/id_2 - id field from tables like format..portalbox...
table - name of the table"""
try:
res1 = run_sql("SELECT score FROM field_tag WHERE id_field=%s and id_tag=%s" % (fldID, id_1))
res2 = run_sql("SELECT score FROM field_tag WHERE id_field=%s and id_tag=%s" % (fldID, id_2))
res = run_sql("UPDATE field_tag SET score=%s WHERE id_field=%s and id_tag=%s" % (res2[0][0], fldID, id_1))
res = run_sql("UPDATE field_tag SET score=%s WHERE id_field=%s and id_tag=%s" % (res1[0][0], fldID, id_2))
return "true"
except StandardError, e:
return ()
diff --git a/modules/bibindex/lib/bibindexadminlib.py.wml b/modules/bibindex/lib/bibindexadminlib.py.wml
index 0170bb153..4073c44f3 100644
--- a/modules/bibindex/lib/bibindexadminlib.py.wml
+++ b/modules/bibindex/lib/bibindexadminlib.py.wml
@@ -1,1115 +1,1118 @@
## Administrator interface for BibIndex
## This file is part of the CERN Document Server Software (CDSware).
## Copyright (C) 2002 CERN.
##
## The CDSware 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.
##
## The CDSware 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 CDSware; if not, write to the Free Software Foundation, Inc.,
## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
## read config variables:
#include "config.wml"
#include "configbis.wml"
#include "cdswmllib.wml"
## $Id$## DO NOT EDIT THIS FILE! IT WAS AUTOMATICALLY GENERATED FROM CDSware WML SOURCES.
"""CDSware BibIndex Administrator Interface."""
__lastupdated__ = """<: print `date +"%d %b %Y %H:%M:%S %Z"`; :>"""
## fill config variables:
import access_control_engine as acce
import cgi
import re
import MySQLdb
import Numeric
import os
import urllib
import time
import random
from zlib import compress,decompress
from bibrankadminlib import modify_translations, get_current_name,get_name,get_rnk_nametypes,get_languages,check_user,is_adminuser,adderrorbox,addadminbox,tupletotable,tupletotable_onlyselected,addcheckboxes,createhiddenform,serialize_via_numeric_array_dumps,serialize_via_numeric_array_compr,serialize_via_numeric_array_escape,serialize_via_numeric_array,deserialize_via_numeric_array,serialize_via_marshal,deserialize_via_marshal
from messages import *
from dbquery import run_sql
from config import *
from webpage import page, pageheaderonly, pagefooteronly
from webuser import getUid, get_email
from mod_python import apache
__version__ = "$Id$"
def getnavtrail(previous = ''):
"""Get the navtrail"""
navtrail = """Admin Area > BibIndex Admin """ % (weburl, weburl)
navtrail = navtrail + previous
return navtrail
def perform_index(ln=cdslang, mtype='', content=''):
"""form to modify a collection. this method is calling other methods which again is calling this and sending back the output of the method.
if callback, the method will call perform_editcollection, if not, it will just return its output.
colID - id of the collection
mtype - the method that called this method.
content - the output from that method."""
fin_output = """
""" % (weburl, ln, weburl, ln, weburl, ln, weburl, ln)
if mtype == "perform_showfields" and content:
fin_output += content
elif mtype == "perform_showfields" or not mtype:
fin_output += perform_showfields(ln, callback='')
if mtype == "perform_addfield" and content:
fin_output += content
elif mtype == "perform_addfield" or not mtype:
fin_output += perform_addfield(ln, callback='')
if mtype == "perform_showdetails" and content:
fin_output += content
elif mtype == "perform_showdetails" or not mtype:
fin_output += perform_showdetails(ln, callback='')
return addadminbox("Overview of BibIndex Interface", [fin_output])
def perform_showfields(ln=cdslang, callback='yes', content='', confirm=-1):
"""show the sort fields of this collection.."""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
fld_type = get_fld_nametypes()
subtitle = """1. Edit logical field   [?]""" % (weburl)
fin_output = ''
res = get_fld()
output = ""
if len(res) > 0:
text = """
Field name
"""
output += createhiddenform(action="%s/admin/bibindex/bibindexadmin.py/showfield" % weburl,
text=text,
button="Edit",
ln=ln,
confirm=1)
else:
output += """No logical fields exists"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_index(ln, "perform_showfields", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showfield(fldID, ln=cdslang, mtype='', content='', callback='yes', confirm=-1):
"""form to modify a collection. this method is calling other methods which again is calling this and sending back the output of the method.
if callback, the method will call perform_editcollection, if not, it will just return its output.
colID - id of the collection
mtype - the method that called this method.
content - the output from that method."""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
if fldID in [-1, "-1"]:
return addadminbox("Edit logical field", ["""Please go back and select a logical field"""])
fin_output = """
""" % (weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln, weburl, fldID, ln)
if mtype == "perform_modifyfield" and content:
fin_output += content
elif mtype == "perform_modifyfield" or not mtype:
fin_output += perform_modifyfield(fldID, ln, callback='')
if mtype == "perform_modifytranslations" and content:
fin_output += content
elif mtype == "perform_modifytranslations" or not mtype:
fin_output += perform_modifytranslations(fldID, ln, callback='')
if mtype == "perform_showfieldtags" and content:
fin_output += content
elif mtype == "perform_showfieldtags" or not mtype:
fin_output += perform_showfieldtags(fldID, ln, callback='')
if mtype == "perform_deletefield" and content:
fin_output += content
elif mtype == "perform_deletefield" or not mtype:
fin_output += perform_deletefield(fldID, ln, callback='')
if mtype == "perform_showdetailsfield" and content:
fin_output += content
elif mtype == "perform_showdetailsfield" or not mtype:
fin_output += perform_showdetailsfield(fldID,ln, callback='')
return addadminbox("Edit logical field '%s'" % fld_dict[int(fldID)], [fin_output])
def perform_modifytranslations(fldID, ln=cdslang, sel_type='', trans=[], confirm=-1, callback='yes'):
"""Modify the translations of a field
sel_type - the nametype to modify
trans - the translations in the same order as the languages from get_languages()"""
output = ''
subtitle = ''
cdslangs = get_languages()
if confirm in ["2", 2] and fldID:
finresult = modify_translations(fldID, cdslangs, sel_type, trans, "field")
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
if fldID and fld_dict.has_key(int(fldID)):
fldID = int(fldID)
subtitle = """3. Modify translations for logical field '%s'   [?]""" % (fld_dict[fldID], weburl)
if type(trans) is str:
trans = [trans]
if sel_type == '':
sel_type = get_fld_nametypes()[0][0]
header = ['Language', 'Translation']
actions = []
types = get_fld_nametypes()
if len(types) > 1:
text = """
Name type
"""
output += createhiddenform(action="modifytranslations#3",
text=text,
button="Select",
fldID=fldID,
ln=ln,
confirm=0)
if confirm in [-1, "-1", 0, "0"]:
trans = []
for (key, value) in cdslangs:
try:
trans_names = get_name(fldID, key, sel_type, "field")
trans.append(trans_names[0][0])
except StandardError, e:
trans.append('')
for nr in range(0,len(cdslangs)):
actions.append(["%s %s" % (cdslangs[nr][1], (cdslangs[nr][0]==cdslang and '(def)' or ''))])
actions[-1].append('' % trans[nr])
text = tupletotable(header=header, tuple=actions)
output += createhiddenform(action="modifytranslations#3",
text=text,
button="Modify",
fldID=fldID,
sel_type=sel_type,
ln=ln,
confirm=2)
if sel_type and len(trans):
if confirm in ["1", 1]:
text = """Please confirm modification of translations for logical field '%s'.""" % (fld_dict[fldID])
output += createhiddenform(action="modifytranslations#3",
text=text,
button="Confirm",
fldID=fldID,
sel_type=sel_type,
trans=trans,
ln=ln,
confirm=2)
elif confirm in ["2", 2]:
if finresult:
output += """Translations modified."""
else:
output += """Sorry, could not modify translations."""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfield(fldID, ln, "perform_modifytranslations", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showdetailsfieldtag(fldID, tagID, ln=cdslang, callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
fldID = int(fldID)
tagname = run_sql("SELECT name from tag where id=%s" % tagID)[0][0]
output = ""
subtitle = """Showing details for MARC tag '%s'""" % tagname
output += " This MARC tag is used directly in these logical fields: "
fld_tag = get_fld_tags('', tagID)
exist = {}
for (id_field,id_tag, tname, tvalue, score) in fld_tag:
output += "%s, " % fld_dict[int(id_field)]
exist[id_field] = 1
output += " This MARC tag is used indirectly in these logical fields: "
tag = run_sql("SELECT value from tag where id=%s" % id_tag)
tag = tag[0][0]
for i in range(0, len(tag) - 1):
res = run_sql("SELECT id_field,id_tag FROM field_tag,tag WHERE tag.id=field_tag.id_tag AND tag.value='%s%%'" % tag[0:i])
for (id_field, id_tag) in res:
output += "%s, " % fld_dict[int(id_field)]
exist[id_field] = 1
res = run_sql("SELECT id_field,id_tag FROM field_tag,tag WHERE tag.id=field_tag.id_tag AND tag.value like '%s'" % tag)
for (id_field, id_tag) in res:
if not exist.has_key(id_field):
output += "%s, " % fld_dict[int(id_field)]
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_showdetailsfieldtag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showdetailsfield(fldID, ln=cdslang, callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
col_dict = dict(get_current_name('', ln, get_col_nametypes()[0][0], "collection"))
fldID = int(fldID)
col_fld = get_col_fld('', '', fldID)
sort_types = dict(get_sort_nametypes())
fin_output = ""
subtitle = """5. Show usage for logical field '%s'""" % fld_dict[fldID]
output = "This logical field is used in these collections: "
ltype = ''
exist = {}
for (id_collection, id_field, id_fieldvalue, ftype, score, score_fieldvalue) in col_fld:
if ltype != ftype:
output += " %s: " % sort_types[ftype]
ltype = ftype
exist = {}
if not exist.has_key(id_collection):
output += "%s, " % col_dict[int(id_collection)]
exist[id_collection] = 1
if not col_fld:
output = "This field is not used by any collections."
fin_output = addadminbox('Collections', [output])
try:
body = [fin_output, extra]
except NameError:
body = [fin_output]
if callback:
return perform_showfield(ln, "perform_showdetailsfield", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_addfield(ln=cdslang, fldNAME='', code='', callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
output = ""
subtitle = """2. Add new logical field"""
code = str.replace(code,' ', '')
text = """
Field name Field code
""" % (fldNAME, code)
output = createhiddenform(action="%s/admin/bibindex/bibindexadmin.py/addfield" % weburl,
text=text,
ln=ln,
button="Add field",
confirm=1)
if fldNAME and code and confirm in ["1", 1]:
res = add_fld(fldNAME, code)
if res:
output += """Added new logical field.
"""
else:
output += """Sorry, could not add logical field, most likely the field already exists.
"""
elif confirm not in ["-1", -1]:
output += """Please give the logical field a name and code.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_index(ln, "perform_addfield", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_deletefield(fldID, ln=cdslang, callback='yes', confirm=0):
"""form to remove a field.
fldID - the field id from table field.
"""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
subtitle = """4. Delete the logical field '%s'   [?]""" % (fld_dict[int(fldID)], weburl)
output = ""
if fldID:
fldID = int(fldID)
if confirm in ["0", 0]:
check = run_sql("SELECT * from idxINDEX_field where id_field=%s" % fldID)
text = ""
if check:
text += """This field is used in an index, deletion may cause problems. """
text += """Do you want to delete the logical field '%s' and all its relations and definitions.""" % (fld_dict[fldID])
output += createhiddenform(action="deletefield#5",
text=text,
button="Confirm",
fldID=fldID,
confirm=1)
elif confirm in ["1", 1]:
res = delete_fld(fldID)
if res:
return """Deleted the logical field '%s'.
""" % (fld_dict[fldID])
else:
return """Cannot delete the logical field.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfield(fldID, ln, "perform_deletefield", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_showdetails(ln=cdslang, callback='', confirm=0):
subtitle = """3. Logical fields overview"""
output = """
"""
output += """
%s
%s
%s
""" % ("Field", "MARC Tags", "Translations")
query = "SELECT id,name FROM field"
res = run_sql(query)
col_dict = dict(get_current_name('', ln, get_col_nametypes()[0][0], "collection"))
for field_id,field_name in res:
query = "SELECT tag.value FROM tag, field_tag WHERE tag.id=field_tag.id_tag AND field_tag.id_field=%d ORDER BY field_tag.score DESC,tag.value ASC" % field_id
res = run_sql(query)
field_tags = ""
for row in res:
field_tags = field_tags + row[0] + ", "
if field_tags.endswith(", "):
field_tags = field_tags[:-2]
cdslangs = dict(get_languages())
langs = run_sql("select ln from fieldname where id_field=%s" % field_id)
exists = {}
lang = ''
for lng in langs:
if not exists.has_key(lng[0]):
lang += lng[0] + ", "
exists[lng[0]] = 1
if lang.endswith(", "):
lang = lang [:-2]
if len(exists) == 0:
lang = """None"""
col_fld = get_col_fld('', '', field_id)
cols = ''
exists = {}
for (id_collection, id_field, id_fieldvalue, ftype, score, score_fieldvalue) in col_fld:
if not exists.has_key(id_collection):
cols = cols + col_dict[int(id_collection)]+ ", "
exists[id_collection] = 1
if len(exists) == 0:
cols = """None"""
if cols.endswith(", "):
cols = cols[:-2]
output += """
"""
actions.append([move, tvalue, tname])
for col in [(('Details','showdetailsfieldtag'), ('Modify','modifytag'),('Remove','removefieldtag'),)]:
actions[-1].append('%s' % (weburl, col[0][1], fldID, tagID, ln, col[0][0]))
for (str, function) in col[1:]:
actions[-1][-1] += ' / %s' % (weburl, function, fldID, tagID, ln, str)
output += tupletotable(header=header, tuple=actions)
else:
output += """No fields exists"""
output += content
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfield(fldID, ln, "perform_showfieldtags", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_addtag(fldID, ln=cdslang, value=['',-1], name='', callback="yes", confirm=-1):
"""form to add a new field.
fldNAME - the name of the new field
code - the field code"""
output = ""
subtitle = """Add MARC tag to logical field"""
text = """
Add new tag: Tag value Tag comment
""" % ((name=='' and value[0] or name), value[0])
text += """Or existing tag: Tag
"""
output = createhiddenform(action="%s/admin/bibindex/bibindexadmin.py/addtag" % weburl,
text=text,
fldID=fldID,
ln=ln,
button="Add tag",
confirm=1)
if (value[0] and value[1] in [-1, "-1"]) or (not value[0] and value[1] not in [-1, "-1"]):
if confirm in ["1", 1]:
res = add_fld_tag(fldID, name, (value[0] !='' and value[0] or value[1]))
if res:
output += """Added new MARC tag with value'%s'
""" % (value[0] !='' and value[0] or value[1])
else:
output += """Sorry, could not add MARC tag, most likely the tag already exists in the logical field.
"""
elif confirm not in ["-1", -1]:
output += """Please choose to add either a new or an existing MARC tag, but not both.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_addtag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_modifytag(fldID, tagID, ln=cdslang, name='', value='', callback='yes', confirm=-1):
"""form to modify a field.
fldID - the field to change."""
subtitle = ""
output = ""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
fldID = int(fldID)
tagID = int(tagID)
tag = get_tags(tagID)
if confirm in [-1, "-1"] and not value and not name:
name = tag[0][1]
value = tag[0][2]
subtitle = """Modify MARC tag"""
text = """
Any modifications will apply to all logical fields using this tag. Tag value Comment
""" % (name, value)
output += createhiddenform(action="modifytag#4.1",
text=text,
button="Modify",
fldID=fldID,
tagID=tagID,
ln=ln,
confirm=1)
if name and value and confirm in [1, "1"]:
res = modify_tag(tagID, name, value)
if res:
output += """Modified the MARC tag.
"""
else:
output += """Cannot modify the MARC tag.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_modifytag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_removefieldtag(fldID, tagID, ln=cdslang, callback='yes', confirm=0):
"""form to remove a portalbox from a collection.
colID - the current collection, remove the portalbox from this collection.
sel_ln - remove the portalbox with this language
pbxID - remove the portalbox with this id"""
subtitle = """Remove MARC tag from logical field"""
output = ""
fld_dict = dict(get_current_name('', ln, get_fld_nametypes()[0][0], "field"))
if fldID and tagID:
fldID = int(fldID)
tagID = int(tagID)
tag = get_fld_tags(fldID, tagID)
if confirm not in ["1", 1]:
text = """Do you want to remove the tag '%s - %s ' from the field '%s'.""" % (tag[0][3], tag[0][2], fld_dict[fldID])
output += createhiddenform(action="removefieldtag#4.1",
text=text,
button="Confirm",
fldID=fldID,
tagID=tagID,
confirm=1)
elif confirm in ["1", 1]:
res = remove_fldtag(fldID, tagID)
if res:
output += """Removed the tag from the logical field.
"""
else:
output += """Cannot remove the tag from the logical field.
"""
try:
body = [output, extra]
except NameError:
body = [output]
if callback:
return perform_showfieldtags(fldID, ln, "perform_removefieldtag", addadminbox(subtitle, body))
else:
return addadminbox(subtitle, body)
def perform_switchtagscore(fldID, id_1, id_2, ln=cdslang):
"""Switch the score of id_1 and id_2 in the table type.
colID - the current collection
id_1/id_2 - the id's to change the score for.
type - like "format" """
output = ""
name_1 = run_sql("select name from tag where id=%s" % id_1)[0][0]
name_2 = run_sql("select name from tag where id=%s" % id_2)[0][0]
if switch_score(fldID, id_1, id_2):
output = """ '%s' changed position with '%s'
""" % (name_1, name_2)
else:
output = """ Could not complete the operation."""
return perform_showfieldtags(fldID, ln, content=output)
def perform_deletetag(fldID, ln=cdslang, tagID=-1, callback='yes', confirm=-1):
"""form to delete an MARC tag not in use.
fldID - the collection id of the current collection.
fmtID - the format id to delete."""
subtitle = """Delete an unused MARC tag"""
output = """
Deleting an MARC tag will also delete the translations associated.
"""
fldID = int(fldID)
if tagID not in [-1," -1"] and confirm in [1, "1"]:
ares = delete_tag(tagID)
fld_tag = get_fld_tags()
fld_tag = dict(map(lambda x: (x[1], x[0]), fld_tag))
tags = get_tags()
text = """
MARC tag """
if i == 0:
output += """No unused MARC tags """
else:
output += createhiddenform(action="deletetag#4.1",
text=text,
button="Delete",
fldID=fldID,
ln=ln,
confirm=0)
if tagID not in [-1,"-1"]:
tagID = int(tagID)
tags = get_tags(tagID)
if confirm in [0, "0"]:
text = """Do you want to delete the MARC tag '%s'.
""" % tags[0][2]
output += createhiddenform(action="deletetag#4.1",
text=text,
button="Confirm",
fldID=fldID,
tagID=tagID,
ln=ln,
confirm=1)
elif confirm in [1, "1"]:
if ares:
output += """Deleted the MARC tag.
"""
else:
output += """Cannot delete the MARC tag.
"""
elif confirm not in [-1, "-1"]:
output += """Choose a MARC tag to delete.
"""
try:
body = [output, extra]
except NameError:
body = [output]
output = " " + addadminbox(subtitle, body)
return perform_showfieldtags(fldID, ln, content=output)
def compare_on_val(first, second):
"""Compare the two values"""
return cmp(first[1], second[1])
def get_col_fld(colID=-1, type = '', id_field=''):
"""Returns either all portalboxes associated with a collection, or based on either colID or language or both.
colID - collection id
ln - language id"""
sql = "SELECT id_collection,id_field,id_fieldvalue,type,score,score_fieldvalue FROM collection_field_fieldvalue, field WHERE id_field=field.id"
try:
if id_field:
sql += " AND id_field=%s" % id_field
sql += " ORDER BY type, score desc, score_fieldvalue desc"
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_fld_tags(fldID='', tagID=''):
"""Returns either all portalboxes associated with a collection, or based on either colID or language or both.
colID - collection id
ln - language id"""
sql = "SELECT id_field,id_tag, tag.name, tag.value, score FROM field_tag,tag WHERE tag.id=field_tag.id_tag"
try:
if fldID:
sql += " AND id_field=%s" % fldID
if tagID:
sql += " AND id_tag=%s" % tagID
sql += " ORDER BY score desc, tag.value, tag.name"
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_tags(tagID=''):
"""Returns either all portalboxes associated with a collection, or based on either colID or language or both.
colID - collection id
ln - language id"""
sql = "SELECT id, name, value FROM tag"
try:
if tagID:
sql += " WHERE id=%s" % tagID
sql += " ORDER BY name, value"
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_fld(fldID=''):
"""Returns allfields"""
try:
if not fldID:
res = run_sql("SELECT id, name, code FROM field ORDER by name, code")
else:
res = run_sql("SELECT id, name, code FROM field WHERE id=%s ORDER by name, code" % fldID)
return res
except StandardError, e:
return ""
def get_fld_value(fldvID = ''):
"""Returns fieldvalue"""
try:
sql = "SELECT id, name, value FROM fieldvalue"
if fldvID:
sql += " WHERE id=%s" % fldvID
res = run_sql(sql)
return res
except StandardError, e:
return ""
def get_col_nametypes():
"""Return a list of the various translationnames for the fields"""
type = []
type.append(('ln', 'Long name'))
return type
def get_fld_nametypes():
"""Return a list of the various translationnames for the fields"""
type = []
type.append(('ln', 'Long name'))
return type
def get_sort_nametypes():
"""Return a list of the various translationnames for the fields"""
type = {}
type['soo'] = 'Sort options'
type['seo'] = 'Search options'
type['sew'] = 'Search within'
return type
def remove_fld(colID,fldID, fldvID=''):
"""Removes a field from the collection given.
colID - the collection the format is connected to
fldID - the field which should be removed from the collection."""
try:
sql = "DELETE FROM collection_field_fieldvalue WHERE id_collection=%s AND id_field=%s" % (colID, fldID)
if fldvID:
sql += " AND id_fieldvalue=%s" % fldvID
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def remove_fldtag(fldID,tagID):
"""Removes a field from the collection given.
colID - the collection the format is connected to
fldID - the field which should be removed from the collection."""
try:
sql = "DELETE FROM field_tag WHERE id_field=%s AND id_tag=%s" % (fldID, tagID)
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def delete_tag(tagID):
"""Deletes all data for the given field
fldID - delete all data in the tables associated with field and this id """
try:
res = run_sql("DELETE FROM tag where id=%s" % tagID)
return "true"
except StandardError, e:
return ""
def delete_fld(fldID):
"""Deletes all data for the given field
fldID - delete all data in the tables associated with field and this id """
try:
res = run_sql("DELETE FROM collection_field_fieldvalue WHERE id_field=%s" % fldID)
res = run_sql("DELETE FROM field_tag WHERE id_field=%s" % fldID)
res = run_sql("DELETE FROM idxINDEX_field WHERE id_field=%s" % fldID)
res = run_sql("DELETE FROM field WHERE id=%s" % fldID)
return "true"
except StandardError, e:
return ""
def add_fld(name, code):
"""Add a new output format. Returns the id of the format.
code - the code for the format, max 6 chars.
name - the default name for the default language of the format.
rtype - the default nametype"""
try:
type = get_fld_nametypes()[0][0]
res = run_sql("INSERT INTO field (name, code) values('%s','%s')" % (MySQLdb.escape_string(name), MySQLdb.escape_string(code)))
fldID = run_sql("SELECT id FROM field WHERE code='%s'" % MySQLdb.escape_string(code))
res = run_sql("INSERT INTO fieldname (id_field, type, ln, value) VALUES (%s,'%s','%s','%s')" % (fldID[0][0], type, cdslang, MySQLdb.escape_string(name)))
return fldID
except StandardError, e:
return ""
def add_fld_tag(fldID, name, value):
"""Add a sort/search/field to the collection.
colID - the id of the collection involved
fmtID - the id of the format.
score - the score of the format, decides sorting, if not given, place the format on top"""
try:
res = run_sql("SELECT score FROM field_tag WHERE id_field=%s ORDER BY score desc" % (fldID))
if res:
score = int(res[0][0]) + 1
else:
score = 0
res = run_sql("SELECT id FROM tag WHERE value='%s'" % MySQLdb.escape_string(value))
if not res:
if name == '':
name = value
res = run_sql("INSERT INTO tag(name, value) values('%s','%s')" % (MySQLdb.escape_string(name), MySQLdb.escape_string(value)))
res = run_sql("SELECT id FROM tag WHERE value='%s'" % MySQLdb.escape_string(value))
res = run_sql("INSERT INTO field_tag(id_field, id_tag, score) values(%s, %s, %s)" % (fldID, res[0][0], score))
return "true"
except StandardError, e:
return ""
def modify_fld(fldID, code):
"""Modify the dbquery of an collection.
colID - the id of the collection involved
dbquery - the new dbquery"""
try:
sql = "UPDATE field SET code='%s'" % code
sql += " WHERE id=%s" % fldID
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def modify_tag(tagID, name, value):
"""Modify the dbquery of an collection.
colID - the id of the collection involved
dbquery - the new dbquery"""
try:
sql = "UPDATE tag SET name='%s' WHERE id=%s" % (name, tagID)
res = run_sql(sql)
sql = "UPDATE tag SET value='%s' WHERE id=%s" % (value, tagID)
res = run_sql(sql)
return "true"
except StandardError, e:
return ""
def switch_score(fldID, id_1, id_2):
"""Switch the scores of id_1 and id_2 in the table given by the argument.
colID - collection the id_1 or id_2 is connected to
id_1/id_2 - id field from tables like format..portalbox...
table - name of the table"""
try:
res1 = run_sql("SELECT score FROM field_tag WHERE id_field=%s and id_tag=%s" % (fldID, id_1))
res2 = run_sql("SELECT score FROM field_tag WHERE id_field=%s and id_tag=%s" % (fldID, id_2))
res = run_sql("UPDATE field_tag SET score=%s WHERE id_field=%s and id_tag=%s" % (res2[0][0], fldID, id_1))
res = run_sql("UPDATE field_tag SET score=%s WHERE id_field=%s and id_tag=%s" % (res1[0][0], fldID, id_2))
return "true"
except StandardError, e:
return ()
diff --git a/modules/bibindex/web/Makefile b/modules/bibindex/web/Makefile
deleted file mode 100644
index d49cd679a..000000000
--- a/modules/bibindex/web/Makefile
+++ /dev/null
@@ -1,334 +0,0 @@
-# Makefile.in generated automatically by automake 1.4-p4 from Makefile.am
-
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-
-SHELL = /bin/sh
-
-srcdir = .
-top_srcdir = ../../..
-
-prefix = /log/cdsware-DEMODEV
-exec_prefix = ${prefix}
-
-bindir = ${exec_prefix}/bin
-sbindir = ${exec_prefix}/sbin
-libexecdir = ${exec_prefix}/libexec
-datadir = ${prefix}/share
-sysconfdir = ${prefix}/etc
-sharedstatedir = ${prefix}/com
-localstatedir = ${prefix}/var
-libdir = ${exec_prefix}/lib
-infodir = ${prefix}/info
-mandir = ${prefix}/man
-includedir = ${prefix}/include
-oldincludedir = /usr/include
-
-DESTDIR =
-
-pkgdatadir = $(datadir)/cdsware
-pkglibdir = $(libdir)/cdsware
-pkgincludedir = $(includedir)/cdsware
-
-top_builddir = ../../..
-
-ACLOCAL = aclocal
-AUTOCONF = autoconf
-AUTOMAKE = automake
-AUTOHEADER = autoheader
-
-INSTALL = /usr/bin/install -c
-INSTALL_PROGRAM = ${INSTALL} $(AM_INSTALL_PROGRAM_FLAGS)
-INSTALL_DATA = ${INSTALL} -m 644
-INSTALL_SCRIPT = ${INSTALL}
-transform = s,x,x,
-
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-ACROREAD = /usr/bin/acroread
-ANTIWORD = /usr/bin/antiword
-CATDOC = /usr/bin/catdoc
-CLIDIR =
-CONVERT = /usr/bin/convert
-DBHOST = cdsdev.cern.ch
-DBNAME = cdsdemodev
-DBPASS = cdsd1m0
-DBUSER = cdsdemo
-FILE = /usr/bin/file
-GIFTEXT = /usr/bin/giftext
-GUNZIP = /bin/gunzip
-GZIP = /bin/gzip
-HTMLTOTEXT = /usr/bin/html2text
-MAKEINFO = makeinfo
-MYSQL = /soft/bin/mysql
-PACKAGE = cdsware
-PDFTOTEXT = /usr/bin/pdftotext
-PHP = /soft/bin/php
-PPTHTML = /usr/bin/ppthtml
-PS2PDF = /usr/bin/ps2pdf
-PSTOASCII = /usr/bin/ps2ascii
-PSTOTEXT =
-PYTHON = /soft/bin/python
-TAR = /bin/tar
-VERSION = 0.3.1.20040503
-WEBDIR = /soft/httpd-bis/host/cdsdev/htdocs/DEMODEV
-WEBURL = http://cdsdev.cern.ch:8000/DEMODEV
-WML = /usr/bin/wml
-WVTEXT = /usr/bin/wvText
-XLHTML = /usr/bin/xlhtml
-
-SUBDIRS = admin
-EXTRA_DIST = $(wildcard *.wml)
-
-CLEANFILES = $(bin_SCRIPTS) $(webapp_DATA) *~ *.tmp search.pyc
-mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
-CONFIG_CLEAN_FILES =
-DATA = $(webapp_DATA)
-
-DIST_COMMON = Makefile.am Makefile.in
-
-
-DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-
-GZIP_ENV = --best
-all: all-redirect
-.SUFFIXES:
-$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOMAKE) --gnu modules/websearch/web/Makefile
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
- cd $(top_builddir) \
- && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-
-install-webappDATA: $(webapp_DATA)
- @$(NORMAL_INSTALL)
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
- @list='$(webapp_DATA)'; for p in $$list; do \
- if test -f $(srcdir)/$$p; then \
- echo " $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p; \
- else if test -f $$p; then \
- echo " $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p; \
- fi; fi; \
- done
-
-uninstall-webappDATA:
- @$(NORMAL_UNINSTALL)
- list='$(webapp_DATA)'; for p in $$list; do \
- rm -f $(DESTDIR)$(webappdir)/$$p; \
- done
-
-# This directory's subdirectories are mostly independent; you can cd
-# into them and run `make' without going through this Makefile.
-# To change the values of `make' variables: instead of editing Makefiles,
-# (1) if the variable is set in `config.status', edit `config.status'
-# (which will cause the Makefiles to be regenerated when you run `make');
-# (2) otherwise, pass the desired values on the `make' command line.
-
-
-
-all-recursive install-data-recursive install-exec-recursive \
-installdirs-recursive install-recursive uninstall-recursive \
-check-recursive installcheck-recursive info-recursive dvi-recursive:
- @set fnord $(MAKEFLAGS); amf=$$2; \
- dot_seen=no; \
- target=`echo $@ | sed s/-recursive//`; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- dot_seen=yes; \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
- done; \
- if test "$$dot_seen" = "no"; then \
- $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
- fi; test -z "$$fail"
-
-mostlyclean-recursive clean-recursive distclean-recursive \
-maintainer-clean-recursive:
- @set fnord $(MAKEFLAGS); amf=$$2; \
- dot_seen=no; \
- rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
- rev="$$subdir $$rev"; \
- test "$$subdir" = "." && dot_seen=yes; \
- done; \
- test "$$dot_seen" = "no" && rev=". $$rev"; \
- target=`echo $@ | sed s/-recursive//`; \
- for subdir in $$rev; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
- done && test -z "$$fail"
-tags-recursive:
- list='$(SUBDIRS)'; for subdir in $$list; do \
- test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
- done
-
-tags: TAGS
-
-ID: $(HEADERS) $(SOURCES) $(LISP)
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- awk ' { files[$$0] = 1; } \
- END { for (i in files) print i; }'`; \
- here=`pwd` && cd $(srcdir) \
- && mkid -f$$here/ID $$unique $(LISP)
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP)
- tags=; \
- here=`pwd`; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
- if test "$$subdir" = .; then :; else \
- test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
- fi; \
- done; \
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- awk ' { files[$$0] = 1; } \
- END { for (i in files) print i; }'`; \
- test -z "$(ETAGS_ARGS)$$unique$(LISP)$$tags" \
- || (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $$unique $(LISP) -o $$here/TAGS)
-
-mostlyclean-tags:
-
-clean-tags:
-
-distclean-tags:
- -rm -f TAGS ID
-
-maintainer-clean-tags:
-
-distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
-
-subdir = modules/websearch/web
-
-distdir: $(DISTFILES)
- here=`cd $(top_builddir) && pwd`; \
- top_distdir=`cd $(top_distdir) && pwd`; \
- distdir=`cd $(distdir) && pwd`; \
- cd $(top_srcdir) \
- && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu modules/websearch/web/Makefile
- @for file in $(DISTFILES); do \
- d=$(srcdir); \
- if test -d $$d/$$file; then \
- cp -pr $$d/$$file $(distdir)/$$file; \
- else \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
- fi; \
- done
- for subdir in $(SUBDIRS); do \
- if test "$$subdir" = .; then :; else \
- test -d $(distdir)/$$subdir \
- || mkdir $(distdir)/$$subdir \
- || exit 1; \
- chmod 777 $(distdir)/$$subdir; \
- (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir=../$(top_distdir) distdir=../$(distdir)/$$subdir distdir) \
- || exit 1; \
- fi; \
- done
-info-am:
-info: info-recursive
-dvi-am:
-dvi: dvi-recursive
-check-am: all-am
-check: check-recursive
-installcheck-am:
-installcheck: installcheck-recursive
-install-exec-am:
-install-exec: install-exec-recursive
-
-install-data-am: install-webappDATA
-install-data: install-data-recursive
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-recursive
-uninstall-am: uninstall-webappDATA
-uninstall: uninstall-recursive
-all-am: Makefile $(DATA)
-all-redirect: all-recursive
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
-installdirs: installdirs-recursive
-installdirs-am:
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
-
-
-mostlyclean-generic:
-
-clean-generic:
- -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
-
-distclean-generic:
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
-
-maintainer-clean-generic:
-mostlyclean-am: mostlyclean-tags mostlyclean-generic
-
-mostlyclean: mostlyclean-recursive
-
-clean-am: clean-tags clean-generic mostlyclean-am
-
-clean: clean-recursive
-
-distclean-am: distclean-tags distclean-generic clean-am
-
-distclean: distclean-recursive
-
-maintainer-clean-am: maintainer-clean-tags maintainer-clean-generic \
- distclean-am
- @echo "This command is intended for maintainers to use;"
- @echo "it deletes files that may require special tools to rebuild."
-
-maintainer-clean: maintainer-clean-recursive
-
-.PHONY: uninstall-webappDATA install-webappDATA install-data-recursive \
-uninstall-data-recursive install-exec-recursive \
-uninstall-exec-recursive installdirs-recursive uninstalldirs-recursive \
-all-recursive check-recursive installcheck-recursive info-recursive \
-dvi-recursive mostlyclean-recursive distclean-recursive clean-recursive \
-maintainer-clean-recursive tags tags-recursive mostlyclean-tags \
-distclean-tags clean-tags maintainer-clean-tags distdir info-am info \
-dvi-am dvi check check-am installcheck-am installcheck install-exec-am \
-install-exec install-data-am install-data install-am install \
-uninstall-am uninstall all-redirect all-am all installdirs-am \
-installdirs mostlyclean-generic distclean-generic clean-generic \
-maintainer-clean-generic clean mostlyclean distclean maintainer-clean
-
-
-%.py: %.py.wml ../../../config/config.wml ../../../config/configbis.wml
- $(WML) -o $@ $<
-
-%: %.wml ../../../config/config.wml ../../../config/configbis.wml
- $(WML) -o $@ $<
- chmod u+x $@
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/modules/bibindex/web/Makefile.am b/modules/bibindex/web/Makefile.am
deleted file mode 100644
index 4f140c3ec..000000000
--- a/modules/bibindex/web/Makefile.am
+++ /dev/null
@@ -1,31 +0,0 @@
-## $Id$
-
-## This file is part of the CERN Document Server Software (CDSware).
-## Copyright (C) 2002 CERN.
-##
-## The CDSware 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.
-##
-## The CDSware 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 CDSware; if not, write to the Free Software Foundation, Inc.,
-## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
-
-SUBDIRS = admin
-
-EXTRA_DIST = $(wildcard *.wml)
-
-CLEANFILES = $(bin_SCRIPTS) $(webapp_DATA) *~ *.tmp search.pyc
-
-%.py: %.py.wml ../../../config/config.wml ../../../config/configbis.wml
- $(WML) -o $@ $<
-
-%: %.wml ../../../config/config.wml ../../../config/configbis.wml
- $(WML) -o $@ $<
- chmod u+x $@
diff --git a/modules/bibindex/web/Makefile.in b/modules/bibindex/web/Makefile.in
deleted file mode 100644
index 8cc2256ec..000000000
--- a/modules/bibindex/web/Makefile.in
+++ /dev/null
@@ -1,337 +0,0 @@
-# Makefile.in generated automatically by automake 1.4-p4 from Makefile.am
-
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-
-SHELL = @SHELL@
-
-srcdir = @srcdir@
-top_srcdir = @top_srcdir@
-VPATH = @srcdir@
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-bindir = @bindir@
-sbindir = @sbindir@
-libexecdir = @libexecdir@
-datadir = @datadir@
-sysconfdir = @sysconfdir@
-sharedstatedir = @sharedstatedir@
-localstatedir = @localstatedir@
-libdir = @libdir@
-infodir = @infodir@
-mandir = @mandir@
-includedir = @includedir@
-oldincludedir = /usr/include
-
-DESTDIR =
-
-pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
-pkgincludedir = $(includedir)/@PACKAGE@
-
-top_builddir = ../../..
-
-ACLOCAL = @ACLOCAL@
-AUTOCONF = @AUTOCONF@
-AUTOMAKE = @AUTOMAKE@
-AUTOHEADER = @AUTOHEADER@
-
-INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-transform = @program_transform_name@
-
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-ACROREAD = @ACROREAD@
-ANTIWORD = @ANTIWORD@
-CATDOC = @CATDOC@
-CLIDIR = @CLIDIR@
-CONVERT = @CONVERT@
-DBHOST = @DBHOST@
-DBNAME = @DBNAME@
-DBPASS = @DBPASS@
-DBUSER = @DBUSER@
-FILE = @FILE@
-GIFTEXT = @GIFTEXT@
-GUNZIP = @GUNZIP@
-GZIP = @GZIP@
-HTMLTOTEXT = @HTMLTOTEXT@
-MAKEINFO = @MAKEINFO@
-MYSQL = @MYSQL@
-PACKAGE = @PACKAGE@
-PDFTOTEXT = @PDFTOTEXT@
-PHP = @PHP@
-PPTHTML = @PPTHTML@
-PS2PDF = @PS2PDF@
-PSTOASCII = @PSTOASCII@
-PSTOTEXT = @PSTOTEXT@
-PYTHON = @PYTHON@
-TAR = @TAR@
-VERSION = @VERSION@
-WEBDIR = @WEBDIR@
-WEBURL = @WEBURL@
-WML = @WML@
-WVTEXT = @WVTEXT@
-XLHTML = @XLHTML@
-
-SUBDIRS = admin
-
-webapp_DATA =
-
-EXTRA_DIST = $(wildcard *.wml)
-
-CLEANFILES = $(bin_SCRIPTS) $(webapp_DATA) *~ *.tmp search.pyc
-mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
-CONFIG_CLEAN_FILES =
-DATA = $(webapp_DATA)
-
-DIST_COMMON = Makefile.am Makefile.in
-
-
-DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-
-GZIP_ENV = --best
-all: all-redirect
-.SUFFIXES:
-$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOMAKE) --gnu modules/websearch/web/Makefile
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
- cd $(top_builddir) \
- && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-
-install-webappDATA: $(webapp_DATA)
- @$(NORMAL_INSTALL)
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
- @list='$(webapp_DATA)'; for p in $$list; do \
- if test -f $(srcdir)/$$p; then \
- echo " $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p; \
- else if test -f $$p; then \
- echo " $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p; \
- fi; fi; \
- done
-
-uninstall-webappDATA:
- @$(NORMAL_UNINSTALL)
- list='$(webapp_DATA)'; for p in $$list; do \
- rm -f $(DESTDIR)$(webappdir)/$$p; \
- done
-
-# This directory's subdirectories are mostly independent; you can cd
-# into them and run `make' without going through this Makefile.
-# To change the values of `make' variables: instead of editing Makefiles,
-# (1) if the variable is set in `config.status', edit `config.status'
-# (which will cause the Makefiles to be regenerated when you run `make');
-# (2) otherwise, pass the desired values on the `make' command line.
-
-@SET_MAKE@
-
-all-recursive install-data-recursive install-exec-recursive \
-installdirs-recursive install-recursive uninstall-recursive \
-check-recursive installcheck-recursive info-recursive dvi-recursive:
- @set fnord $(MAKEFLAGS); amf=$$2; \
- dot_seen=no; \
- target=`echo $@ | sed s/-recursive//`; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- dot_seen=yes; \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
- done; \
- if test "$$dot_seen" = "no"; then \
- $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
- fi; test -z "$$fail"
-
-mostlyclean-recursive clean-recursive distclean-recursive \
-maintainer-clean-recursive:
- @set fnord $(MAKEFLAGS); amf=$$2; \
- dot_seen=no; \
- rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
- rev="$$subdir $$rev"; \
- test "$$subdir" = "." && dot_seen=yes; \
- done; \
- test "$$dot_seen" = "no" && rev=". $$rev"; \
- target=`echo $@ | sed s/-recursive//`; \
- for subdir in $$rev; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || case "$$amf" in *=*) exit 1;; *k*) fail=yes;; *) exit 1;; esac; \
- done && test -z "$$fail"
-tags-recursive:
- list='$(SUBDIRS)'; for subdir in $$list; do \
- test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
- done
-
-tags: TAGS
-
-ID: $(HEADERS) $(SOURCES) $(LISP)
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- awk ' { files[$$0] = 1; } \
- END { for (i in files) print i; }'`; \
- here=`pwd` && cd $(srcdir) \
- && mkid -f$$here/ID $$unique $(LISP)
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) $(LISP)
- tags=; \
- here=`pwd`; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
- if test "$$subdir" = .; then :; else \
- test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
- fi; \
- done; \
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- awk ' { files[$$0] = 1; } \
- END { for (i in files) print i; }'`; \
- test -z "$(ETAGS_ARGS)$$unique$(LISP)$$tags" \
- || (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags $$unique $(LISP) -o $$here/TAGS)
-
-mostlyclean-tags:
-
-clean-tags:
-
-distclean-tags:
- -rm -f TAGS ID
-
-maintainer-clean-tags:
-
-distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
-
-subdir = modules/websearch/web
-
-distdir: $(DISTFILES)
- here=`cd $(top_builddir) && pwd`; \
- top_distdir=`cd $(top_distdir) && pwd`; \
- distdir=`cd $(distdir) && pwd`; \
- cd $(top_srcdir) \
- && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu modules/websearch/web/Makefile
- @for file in $(DISTFILES); do \
- d=$(srcdir); \
- if test -d $$d/$$file; then \
- cp -pr $$d/$$file $(distdir)/$$file; \
- else \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
- fi; \
- done
- for subdir in $(SUBDIRS); do \
- if test "$$subdir" = .; then :; else \
- test -d $(distdir)/$$subdir \
- || mkdir $(distdir)/$$subdir \
- || exit 1; \
- chmod 777 $(distdir)/$$subdir; \
- (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir=../$(top_distdir) distdir=../$(distdir)/$$subdir distdir) \
- || exit 1; \
- fi; \
- done
-info-am:
-info: info-recursive
-dvi-am:
-dvi: dvi-recursive
-check-am: all-am
-check: check-recursive
-installcheck-am:
-installcheck: installcheck-recursive
-install-exec-am:
-install-exec: install-exec-recursive
-
-install-data-am: install-webappDATA
-install-data: install-data-recursive
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-recursive
-uninstall-am: uninstall-webappDATA
-uninstall: uninstall-recursive
-all-am: Makefile $(DATA)
-all-redirect: all-recursive
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
-installdirs: installdirs-recursive
-installdirs-am:
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
-
-
-mostlyclean-generic:
-
-clean-generic:
- -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
-
-distclean-generic:
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
-
-maintainer-clean-generic:
-mostlyclean-am: mostlyclean-tags mostlyclean-generic
-
-mostlyclean: mostlyclean-recursive
-
-clean-am: clean-tags clean-generic mostlyclean-am
-
-clean: clean-recursive
-
-distclean-am: distclean-tags distclean-generic clean-am
-
-distclean: distclean-recursive
-
-maintainer-clean-am: maintainer-clean-tags maintainer-clean-generic \
- distclean-am
- @echo "This command is intended for maintainers to use;"
- @echo "it deletes files that may require special tools to rebuild."
-
-maintainer-clean: maintainer-clean-recursive
-
-.PHONY: uninstall-webappDATA install-webappDATA install-data-recursive \
-uninstall-data-recursive install-exec-recursive \
-uninstall-exec-recursive installdirs-recursive uninstalldirs-recursive \
-all-recursive check-recursive installcheck-recursive info-recursive \
-dvi-recursive mostlyclean-recursive distclean-recursive clean-recursive \
-maintainer-clean-recursive tags tags-recursive mostlyclean-tags \
-distclean-tags clean-tags maintainer-clean-tags distdir info-am info \
-dvi-am dvi check check-am installcheck-am installcheck install-exec-am \
-install-exec install-data-am install-data install-am install \
-uninstall-am uninstall all-redirect all-am all installdirs-am \
-installdirs mostlyclean-generic distclean-generic clean-generic \
-maintainer-clean-generic clean mostlyclean distclean maintainer-clean
-
-
-%.py: %.py.wml ../../../config/config.wml ../../../config/configbis.wml
- $(WML) -o $@ $<
-
-%: %.wml ../../../config/config.wml ../../../config/configbis.wml
- $(WML) -o $@ $<
- chmod u+x $@
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/modules/bibindex/web/admin/Makefile b/modules/bibindex/web/admin/Makefile
deleted file mode 100644
index f6ad86126..000000000
--- a/modules/bibindex/web/admin/Makefile
+++ /dev/null
@@ -1,232 +0,0 @@
-# Makefile.in generated automatically by automake 1.4-p4 from Makefile.am
-
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-
-SHELL = /bin/sh
-
-srcdir = .
-top_srcdir = ../../../..
-
-prefix = /log/cdsware-DEMODEV
-exec_prefix = ${prefix}
-
-bindir = ${exec_prefix}/bin
-sbindir = ${exec_prefix}/sbin
-libexecdir = ${exec_prefix}/libexec
-datadir = ${prefix}/share
-sysconfdir = ${prefix}/etc
-sharedstatedir = ${prefix}/com
-localstatedir = ${prefix}/var
-libdir = ${exec_prefix}/lib
-infodir = ${prefix}/info
-mandir = ${prefix}/man
-includedir = ${prefix}/include
-oldincludedir = /usr/include
-
-DESTDIR =
-
-pkgdatadir = $(datadir)/cdsware
-pkglibdir = $(libdir)/cdsware
-pkgincludedir = $(includedir)/cdsware
-
-top_builddir = ../../../..
-
-ACLOCAL = aclocal
-AUTOCONF = autoconf
-AUTOMAKE = automake
-AUTOHEADER = autoheader
-
-INSTALL = /usr/bin/install -c
-INSTALL_PROGRAM = ${INSTALL} $(AM_INSTALL_PROGRAM_FLAGS)
-INSTALL_DATA = ${INSTALL} -m 644
-INSTALL_SCRIPT = ${INSTALL}
-transform = s,x,x,
-
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-ACROREAD = /usr/bin/acroread
-ANTIWORD = /usr/bin/antiword
-CATDOC = /usr/bin/catdoc
-CLIDIR =
-CONVERT = /usr/bin/convert
-DBHOST = cdsdev.cern.ch
-DBNAME = cdsdemodev
-DBPASS = cdsd1m0
-DBUSER = cdsdemo
-FILE = /usr/bin/file
-GIFTEXT = /usr/bin/giftext
-GUNZIP = /bin/gunzip
-GZIP = /bin/gzip
-HTMLTOTEXT = /usr/bin/html2text
-MAKEINFO = makeinfo
-MYSQL = /soft/bin/mysql
-PACKAGE = cdsware
-PDFTOTEXT = /usr/bin/pdftotext
-PHP = /soft/bin/php
-PPTHTML = /usr/bin/ppthtml
-PS2PDF = /usr/bin/ps2pdf
-PSTOASCII = /usr/bin/ps2ascii
-PSTOTEXT =
-PYTHON = /soft/bin/python
-TAR = /bin/tar
-VERSION = 0.3.1.20040503
-WEBDIR = /soft/httpd-bis/host/cdsdev/htdocs/DEMODEV
-WEBURL = http://cdsdev.cern.ch:8000/DEMODEV
-WML = /usr/bin/wml
-WVTEXT = /usr/bin/wvText
-XLHTML = /usr/bin/xlhtml
-
-webappdir = $(WEBDIR)/admin/bibindex
-
-webapp_DATA = index.html bibindexadmin.py
-
-EXTRA_DIST = $(wildcard *.wml)
-
-CLEANFILES = $(bin_SCRIPTS) $(webapp_DATA) *~ *.tmp search.pyc
-mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
-CONFIG_CLEAN_FILES =
-DATA = $(webapp_DATA)
-
-DIST_COMMON = Makefile.am Makefile.in
-
-
-DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-
-GZIP_ENV = --best
-all: all-redirect
-.SUFFIXES:
-$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOMAKE) --gnu modules/websearch/web/admin/Makefile
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
- cd $(top_builddir) \
- && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-
-install-webappDATA: $(webapp_DATA)
- @$(NORMAL_INSTALL)
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
- @list='$(webapp_DATA)'; for p in $$list; do \
- if test -f $(srcdir)/$$p; then \
- echo " $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p; \
- else if test -f $$p; then \
- echo " $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p; \
- fi; fi; \
- done
-
-uninstall-webappDATA:
- @$(NORMAL_UNINSTALL)
- list='$(webapp_DATA)'; for p in $$list; do \
- rm -f $(DESTDIR)$(webappdir)/$$p; \
- done
-tags: TAGS
-TAGS:
-
-
-distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
-
-subdir = modules/websearch/web/admin
-
-distdir: $(DISTFILES)
- here=`cd $(top_builddir) && pwd`; \
- top_distdir=`cd $(top_distdir) && pwd`; \
- distdir=`cd $(distdir) && pwd`; \
- cd $(top_srcdir) \
- && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu modules/websearch/web/admin/Makefile
- @for file in $(DISTFILES); do \
- d=$(srcdir); \
- if test -d $$d/$$file; then \
- cp -pr $$d/$$file $(distdir)/$$file; \
- else \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
- fi; \
- done
-info-am:
-info: info-am
-dvi-am:
-dvi: dvi-am
-check-am: all-am
-check: check-am
-installcheck-am:
-installcheck: installcheck-am
-install-exec-am:
-install-exec: install-exec-am
-
-install-data-am: install-webappDATA
-install-data: install-data-am
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-am
-uninstall-am: uninstall-webappDATA
-uninstall: uninstall-am
-all-am: Makefile $(DATA)
-all-redirect: all-am
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
-installdirs:
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
-
-
-mostlyclean-generic:
-
-clean-generic:
- -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
-
-distclean-generic:
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
-
-maintainer-clean-generic:
-mostlyclean-am: mostlyclean-generic
-
-mostlyclean: mostlyclean-am
-
-clean-am: clean-generic mostlyclean-am
-
-clean: clean-am
-
-distclean-am: distclean-generic clean-am
-
-distclean: distclean-am
-
-maintainer-clean-am: maintainer-clean-generic distclean-am
- @echo "This command is intended for maintainers to use;"
- @echo "it deletes files that may require special tools to rebuild."
-
-maintainer-clean: maintainer-clean-am
-
-.PHONY: uninstall-webappDATA install-webappDATA tags distdir info-am \
-info dvi-am dvi check check-am installcheck-am installcheck \
-install-exec-am install-exec install-data-am install-data install-am \
-install uninstall-am uninstall all-redirect all-am all installdirs \
-mostlyclean-generic distclean-generic clean-generic \
-maintainer-clean-generic clean mostlyclean distclean maintainer-clean
-
-
-%.py: %.py.wml ../../../../config/config.wml ../../../../config/configbis.wml
- $(WML) -o $@ $<
-
-%.html: %.html.wml ../../../../config/config.wml ../../../../config/configbis.wml
- $(WML) -o\(ALL-LANG_*\)+LANG_EN:$@ $<
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
diff --git a/modules/bibindex/web/admin/Makefile.am b/modules/bibindex/web/admin/Makefile.am
deleted file mode 100644
index 566287cfb..000000000
--- a/modules/bibindex/web/admin/Makefile.am
+++ /dev/null
@@ -1,32 +0,0 @@
-## $Id$
-
-## This file is part of the CERN Document Server Software (CDSware).
-## Copyright (C) 2002 CERN.
-##
-## The CDSware 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.
-##
-## The CDSware 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 CDSware; if not, write to the Free Software Foundation, Inc.,
-## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
-
-webappdir = $(WEBDIR)/admin/bibindex
-
-webapp_DATA= index.html bibindexadmin.py
-
-EXTRA_DIST = $(wildcard *.wml)
-
-CLEANFILES = $(bin_SCRIPTS) $(webapp_DATA) *~ *.tmp search.pyc
-
-%.py: %.py.wml ../../../../config/config.wml ../../../../config/configbis.wml
- $(WML) -o $@ $<
-
-%.html: %.html.wml ../../../../config/config.wml ../../../../config/configbis.wml
- $(WML) -o\(ALL-LANG_*\)+LANG_EN:$@ $<
diff --git a/modules/bibindex/web/admin/Makefile.in b/modules/bibindex/web/admin/Makefile.in
deleted file mode 100644
index 932a2ec65..000000000
--- a/modules/bibindex/web/admin/Makefile.in
+++ /dev/null
@@ -1,232 +0,0 @@
-# Makefile.in generated automatically by automake 1.4-p4 from Makefile.am
-
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-
-SHELL = @SHELL@
-
-srcdir = @srcdir@
-top_srcdir = @top_srcdir@
-VPATH = @srcdir@
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-bindir = @bindir@
-sbindir = @sbindir@
-libexecdir = @libexecdir@
-datadir = @datadir@
-sysconfdir = @sysconfdir@
-sharedstatedir = @sharedstatedir@
-localstatedir = @localstatedir@
-libdir = @libdir@
-infodir = @infodir@
-mandir = @mandir@
-includedir = @includedir@
-oldincludedir = /usr/include
-
-DESTDIR =
-
-pkgdatadir = $(datadir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
-pkgincludedir = $(includedir)/@PACKAGE@
-
-top_builddir = ../../../..
-
-ACLOCAL = @ACLOCAL@
-AUTOCONF = @AUTOCONF@
-AUTOMAKE = @AUTOMAKE@
-AUTOHEADER = @AUTOHEADER@
-
-INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-transform = @program_transform_name@
-
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-ACROREAD = @ACROREAD@
-ANTIWORD = @ANTIWORD@
-CATDOC = @CATDOC@
-CLIDIR = @CLIDIR@
-CONVERT = @CONVERT@
-DBHOST = @DBHOST@
-DBNAME = @DBNAME@
-DBPASS = @DBPASS@
-DBUSER = @DBUSER@
-FILE = @FILE@
-GIFTEXT = @GIFTEXT@
-GUNZIP = @GUNZIP@
-GZIP = @GZIP@
-HTMLTOTEXT = @HTMLTOTEXT@
-MAKEINFO = @MAKEINFO@
-MYSQL = @MYSQL@
-PACKAGE = @PACKAGE@
-PDFTOTEXT = @PDFTOTEXT@
-PHP = @PHP@
-PPTHTML = @PPTHTML@
-PS2PDF = @PS2PDF@
-PSTOASCII = @PSTOASCII@
-PSTOTEXT = @PSTOTEXT@
-PYTHON = @PYTHON@
-TAR = @TAR@
-VERSION = @VERSION@
-WEBDIR = @WEBDIR@
-WEBURL = @WEBURL@
-WML = @WML@
-WVTEXT = @WVTEXT@
-XLHTML = @XLHTML@
-
-webappdir = $(WEBDIR)/admin/bibindex
-
-webapp_DATA = index.html bibindexadmin.py
-
-EXTRA_DIST = $(wildcard *.wml)
-
-CLEANFILES = $(bin_SCRIPTS) $(webapp_DATA) *~ *.tmp search.pyc
-mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
-CONFIG_CLEAN_FILES =
-DATA = $(webapp_DATA)
-
-DIST_COMMON = Makefile.am Makefile.in
-
-
-DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-
-GZIP_ENV = --best
-all: all-redirect
-.SUFFIXES:
-$(srcdir)/Makefile.in: Makefile.am $(top_srcdir)/configure.ac $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOMAKE) --gnu modules/websearch/web/admin/Makefile
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status $(BUILT_SOURCES)
- cd $(top_builddir) \
- && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-
-install-webappDATA: $(webapp_DATA)
- @$(NORMAL_INSTALL)
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
- @list='$(webapp_DATA)'; for p in $$list; do \
- if test -f $(srcdir)/$$p; then \
- echo " $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(webappdir)/$$p; \
- else if test -f $$p; then \
- echo " $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p"; \
- $(INSTALL_DATA) $$p $(DESTDIR)$(webappdir)/$$p; \
- fi; fi; \
- done
-
-uninstall-webappDATA:
- @$(NORMAL_UNINSTALL)
- list='$(webapp_DATA)'; for p in $$list; do \
- rm -f $(DESTDIR)$(webappdir)/$$p; \
- done
-tags: TAGS
-TAGS:
-
-
-distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
-
-subdir = modules/websearch/web/admin
-
-distdir: $(DISTFILES)
- here=`cd $(top_builddir) && pwd`; \
- top_distdir=`cd $(top_distdir) && pwd`; \
- distdir=`cd $(distdir) && pwd`; \
- cd $(top_srcdir) \
- && $(AUTOMAKE) --include-deps --build-dir=$$here --srcdir-name=$(top_srcdir) --output-dir=$$top_distdir --gnu modules/websearch/web/admin/Makefile
- @for file in $(DISTFILES); do \
- d=$(srcdir); \
- if test -d $$d/$$file; then \
- cp -pr $$d/$$file $(distdir)/$$file; \
- else \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
- fi; \
- done
-info-am:
-info: info-am
-dvi-am:
-dvi: dvi-am
-check-am: all-am
-check: check-am
-installcheck-am:
-installcheck: installcheck-am
-install-exec-am:
-install-exec: install-exec-am
-
-install-data-am: install-webappDATA
-install-data: install-data-am
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-am
-uninstall-am: uninstall-webappDATA
-uninstall: uninstall-am
-all-am: Makefile $(DATA)
-all-redirect: all-am
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
-installdirs:
- $(mkinstalldirs) $(DESTDIR)$(webappdir)
-
-
-mostlyclean-generic:
-
-clean-generic:
- -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
-
-distclean-generic:
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
-
-maintainer-clean-generic:
-mostlyclean-am: mostlyclean-generic
-
-mostlyclean: mostlyclean-am
-
-clean-am: clean-generic mostlyclean-am
-
-clean: clean-am
-
-distclean-am: distclean-generic clean-am
-
-distclean: distclean-am
-
-maintainer-clean-am: maintainer-clean-generic distclean-am
- @echo "This command is intended for maintainers to use;"
- @echo "it deletes files that may require special tools to rebuild."
-
-maintainer-clean: maintainer-clean-am
-
-.PHONY: uninstall-webappDATA install-webappDATA tags distdir info-am \
-info dvi-am dvi check check-am installcheck-am installcheck \
-install-exec-am install-exec install-data-am install-data install-am \
-install uninstall-am uninstall all-redirect all-am all installdirs \
-mostlyclean-generic distclean-generic clean-generic \
-maintainer-clean-generic clean mostlyclean distclean maintainer-clean
-
-
-%.py: %.py.wml ../../../../config/config.wml ../../../../config/configbis.wml
- $(WML) -o $@ $<
-
-%.html: %.html.wml ../../../../config/config.wml ../../../../config/configbis.wml
- $(WML) -o\(ALL-LANG_*\)+LANG_EN:$@ $<
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT: