Closed
Bug 488517
Opened 16 years ago
Closed 16 years ago
Create Tag CRUD
Categories
(addons.mozilla.org Graveyard :: Public Pages, defect)
addons.mozilla.org Graveyard
Public Pages
Tracking
(Not tracked)
RESOLVED
FIXED
5.0.7
People
(Reporter: clouserw, Assigned: yem.huynh)
References
Details
(Whiteboard: [webmocha])
Attachments
(4 files)
This is the core of our tagging framework. Once bug 488516 is finished we'll have the Tag namespace free. We must swoop in and stake our new claim before something else in the database decides to rename itself to `tags` (`ratings` has shifty eyes...keep an eye on that table). This bug builds on the spec ( http://docs.google.com/Doc?docid=dds6vwb4_1dxwx5vg3&hl=en ) and is specifically for:
1.1, 1.4, 1.6, 1.8: Building the general format and restrictions for tags. Additional info is at http://micropipes.com/blog/2009/03/06/the-tagging-plan-for-amo/
1.2, 1.3: Users can add tags (track which users add which tags)
1.5: Users can delete tags
1.13: Admin blacklist
Reporter | ||
Updated•16 years ago
|
This task involves:
MySQL: Creating optimal tables & join tables to integrate tagging into addons, developer & user tags, and the blacklist table (the database schema).
Cake: Creating all required models for tags.
Oops, another task for the list:
SimpleTest: Write unit tests for models created.
Comment 3•16 years ago
|
||
(In reply to comment #2)
> Oops, another task for the list:
>
> SimpleTest: Write unit tests for models created.
Hells yeah! :)
Reporter | ||
Updated•16 years ago
|
Assignee: nobody → mikelee
Comment 4•16 years ago
|
||
I don't have a fully layered PSD so this is kind of hacked together, but this builds on what Clearleft has already done for tags.
Comment 5•16 years ago
|
||
Here's the flow for how we could implement adding a tag. When there are no Tags for that particular add-on you would only have the Tags heading and the "+ Add a tag" link.
Comment 6•16 years ago
|
||
Here's the flow for how removing a tag could work. Instead of prompting the user I suggest we implement undo instead - it's a better experience overall and gives the user a way to back out of a change.
Updated•16 years ago
|
Whiteboard: webmocha
Updated•16 years ago
|
Whiteboard: webmocha → [webmocha]
-added create sql scripts for new tables in /site/app/config/sql/remora.sql
-added new tag models
-added simpletests
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Reporter | ||
Comment 9•16 years ago
|
||
Hey,
I was just glancing through some of the commits and ran across r27398 - it's not the only code that does this but as an example:
in the addTag(), removeUserTagFromAddon(), etc. functions you do a SELECT query and then if it's empty you do an INSERT and increment TagStat. There would be less db queries if you used a REPLACE INTO instead of the double query (there are a bunch of places that do the double query that I saw) and there would be less overall db traffic if you used database triggers everywhere that you are incrementing/decrementing tag statistics or strength instead of doing separate queries.
Comment 10•16 years ago
|
||
Thank you for those comments, Wil. Reopening bug. Yem, please look into this. Thanks.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 11•16 years ago
|
||
Assignee | ||
Comment 12•16 years ago
|
||
-added triggers to update tag_stat when records are added/removed from users_tags_addons.
-removed uses of TagStat->increment() from all code
-updated functions that add/remove users_tags_addons records to utilize INSERT IGNORE instead of doing a find and then insert if it does not exist.
Revision 28448.
NOTE:
====
Developers please update your schemas with the attached sql script (trg.sql)
Assignee | ||
Comment 13•16 years ago
|
||
marking as fixed.
Status: ASSIGNED → RESOLVED
Closed: 16 years ago → 16 years ago
Resolution: --- → FIXED
Comment 14•16 years ago
|
||
For reference in ViewVC:
r28448
Reporter | ||
Updated•16 years ago
|
Attachment #385054 -
Attachment mime type: text/x-sql → text/plain
Updated•9 years ago
|
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•