Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
This is a generalization of the search improvements made in
7da2edeaa0f6cf7794f4f8f68960497dc1be893c and
92235222dba4e5d0c7713d53ef12e0f10e371b83
And has been applied to the dropdown searches for producers, staff, tags
and traits.
For all those searches, exact matches are listed first, followed by
prefix matches, and then substring matches. Relevance is currently only
based on the primary name/title and ignores aliases (except for staff).
This is fixable, but not trivial, and I'm not sure it's all that useful.
|
|
Newer versions of DBD::Pg do this automatically.
|
|
DBD::Pg doesn't recognize the 'xml' data type as textual data, and thus
doesn't decode it for us. This fixes the display of non-ASCII
characters.
|
|
This changes quite a bit to the way the editing functions work. Because
these functions are very repetitive and it's easy to keep things out of
sync, I created a script to generate them automatically. I had to rename
a few function and table names for consistency to make this work.
Since database entries don't have a 'latest' column anymore, and since
the order in which tables are updated doesn't have to be fixed, I
dropped many of the SQL triggers and replaced them with a
edit_committed() function which is called from edit_*_commit() and
checks for stuff to be done.
Don't forget to run 'make' before importing the update script.
|
|
This basically makes VNDB browsable again, but editing entries is still
broken.
I split off the get-old-revision functionality from the db*Get() methods
into db*GetRev(). This split makes sense even with the old SQL schema:
db*Get() had to special-case some joins/filters when fetching an older
revision, and none of the other filters would work in that case. This
split does cause some code duplication in that all db*GetRev() methods
look very much alike, and that the columns they fetch is almost
identical to the db*Get() methods. Not sure yet how to avoid the
duplication elegantly.
I didn't do a whole lot of query optimization yet (most issues require
extra indices, I'll investigate later which indices will make a big
difference), but I did fix some low hanging fruit whenever I encountered
something.
I don't think I've worsened anything, performance-wise.
|
|
Conflicts:
lib/VNDB/DB/VN.pm
lib/VNDB/Handler/VNPage.pm
|
|
|
|
And call bbSubstLinks() from Handler::Discussions rather than
DB::Discussions - it's not a transformation that the DB layer should do,
IMO.
|
|
Patch from https://vndb.org/t5564.13
|
|
A nice expanded view. It also happens to be faster than the old view in
terms of SQL queries. (In most cases at least)
Can be improved a little more by:
- Adding an 'expand/collapse' feature to list only the VNs
- Adding a column indicating the role of the producer (dev/pub)
|
|
This is implemented by adding ihid (item hidden) and ilock (item
locked) columns to the changes table,
The (vn|release|producer).(hidden|locked) columns now work as a
cache, refering to the changes.(ihid|ilock) columns with
changes.id = (vn|release|producer).latest.
The cached columns are updated automatically each time a new revision is
inserted.
This is a pretty large change, bugs are quite likely.
|
|
|
|
And also changed the way the item_table.latest column was updated: it is
now only updated after the revision insert has completed, making it
easier to write trigger functions in SQL.
|
|
|
|
TODO:
- document the relations
- emit a relgraph notify when needed
|
|
The current list of relations isn't final yet, may be changed later on.
Quite a bit of this code has been copied from the VN relations... need
to find a way to use prober code reuse here.
TODO:
- Nice relation editor interface
- Display relations in revision browser
- Display relations on producer pages
- Generate relation graphs
- Sync update_2.8.sql into dump.sql
|
|
This is a very important column in a very important table, I hope I
didn't forget to update a piece of code somewhere...
|
|
|
|
That was the last one. I hope I haven't forgotten to update anything.
|
|
Using the same method as 203509ffd8fc2fbbd76129d701a6c20110f6050d
|
|
dbProducerGet()
Added an 'extended' flag to the 'what' argument, which should be used
if more columns are desired.
|
|
|
|
17:00:20 <ImmLff> Can someone explain why p440 have relation to v198 without having a release?
17:00:20 <Multi> [p440] Team Free @ http://vndb.org/p440
17:00:20 <Multi> [v198] Princess Holiday @ http://vndb.org/v198
17:01:07 <applehq> it's deleted...
17:01:14 <Yorhel> oh my, a bug
|
|
DB/{Votes,VNList,WishList}.pm into ULists.pm
|
|
go to Multi again
|
|
They pretty much all work the same anyway
|
|
...and those URL regexes are getting more and more complex >.>
|
|
Though there's no diff viewer or revision browser yet, so you can't
really see the changelog itself
|
|
|
|
|
|
dbProducerGet is mostly stolen from 1.x
|