Wedge

Public area => The Pub => Features => Topic started by: Arantor on February 14th, 2012, 03:13 PM

Title: Moderation filters UI
Post by: Arantor on February 14th, 2012, 03:13 PM
Opening this in a new topic to keep it separate from guts of how it all works since the user-side stuff is a very tricky beast to make work.

To recap, we have this very flexible rules based system that allows you to set multiple criteria in which to do something on a post as it's being made. Each rule has one action, each rule has one or more conditions to it that all have to be met in order for it to work.[1]

So here's the UI I've been working with; this is still a WIP and is the result of quite a bit of experimentation to get to something I actually like.

Screenshot 1: The initial 'add rule' page, won't do anything until you pick what you want the rule to do.
Screenshot 2: Picked what the rule does, now have to pick the most important part of when it runs.
Screenshot 3: We've picked what it does and whether it runs on new topics or all posts, now we start to add the conditions.
Screenshot 4: Adding a condition

(This is as far as I've got but the idea is that you pick one or more of the checkboxes, then an 'add' button will pop up, so it adds it to the table above, and clears the bottom part out the way, then once you've added at least one rule, it gives you the final save button)

Does this sound workable? I suspect it might need to be demonstrated to really get a feel for it - and I will very likely go away and make a YT video demoing it.
 1. If you want two different situations that cause the same outcome, that's two rules. E.g. moderating posts if they have a rude word in, or the user has 5 or less posts, that's two rules, one for the rude word, one for the posts.
Title: Re: Moderation filters UI
Post by: billy2 on February 14th, 2012, 03:40 PM
 :lol:
Even I can follow that, excellent.


Title: Re: Moderation filters UI
Post by: Dr. Deejay on February 14th, 2012, 03:41 PM
Indeed, excellent work :)
Title: Re: Moderation filters UI
Post by: Nao on February 14th, 2012, 06:04 PM
There's a strange little textarea in the Moderation settings page... Is it supposed to be there? It's called postmod_rules and has no description text... Also, it's very narrow relative to its height.

Additionally, I went to the Moderation filters page, clicked to add a filter and it didn't do anything -- which isn't surprising, since there's no form tag around the input... :^^;:

Is it a work in progress, or something? I haven't got time to look into the PHP itself, as I'm busy rewriting some portions of the autosuggest....
Title: Re: Moderation filters UI
Post by: Arantor on February 14th, 2012, 06:10 PM
Quote
There's a strange little textarea in the Moderation settings page... Is it supposed to be there? It's called postmod_rules and has no description text... Also, it's very narrow relative to its height.
Probably because as per the change log that was the only way to add rules using bare XML for now (for testing purposes) and that it was only temporary. :P As for its relatively narrow width, that's a side effect of using large_text which doesn't allow for width specification.
Quote
Additionally, I went to the Moderation filters page, clicked to add a filter and it didn't do anything -- which isn't surprising, since there's no form tag around the input...
No, again because it's not supposed to.

I only checked in the page that displays the rules - what I've attached here is the WIP on my PC from today of the UI that actually builds the rules (which will remove that textbox)
Title: Re: Moderation filters UI
Post by: Nao on February 14th, 2012, 06:45 PM
Yeah, and having seen these screenshots, I went to see them in action :P
Also wanted to check my translation...
Title: Re: Moderation filters UI
Post by: Arantor on February 15th, 2012, 03:20 PM
OK, well, some of the interface is working, it's still heavily WIP though (and doesn't save any rules yet)

Latest screenshot attached.
Title: Re: Moderation filters UI
Post by: Dismal Shadow on February 15th, 2012, 04:54 PM
Permissions are renamed to rules? :P
Title: Re: Moderation filters UI
Post by: Nao on February 15th, 2012, 04:54 PM
I don't believe it's the same thing... :whistle:
Title: Re: Moderation filters UI
Post by: Arantor on February 15th, 2012, 05:15 PM
No, it's not the same thing at all, and that's precisely why I didn't call it 'moderation rules' as a whole thing.

When you start using the functionality, it becomes very clear that its overlap with permissions is... limited at best.
Title: Re: Moderation filters UI
Post by: Arantor on February 16th, 2012, 12:01 PM
OK, I think it's time to start working on the saving logic, because the two remaining types of moderation filter (user id and permissions) require a lot more energy on my part to implement (user id will depend on auto-suggest so I don't want to get into that until I know it's not likely to change any time soon, and permissions is complicated because I don't want to have to do anything manual to keep it updated)

But at least this way you'll be able to start using the UI properly :D