ringo-framework / ringo_news

News extension for the Ringo framework
GNU General Public License v3.0
0 stars 1 forks source link

Add CLI command to manage news #7

Open toirl opened 8 years ago

toirl commented 8 years ago

Background:

Often new are added by the administration to inform the users about importent news. Problem is that the administration does not have access to the webapplication to direkly enter the news in the webinterface.

Therefor we need a CLI which can be used to direktly insert new news into the database. The tool is aimed to be used by administrational users.

The news extension is ideally able to enhance the allready known ringo-admin command with new commands.

Proposal:

JSON:

{"subject": "Foo", "date": "YYYY-MM-DD", "text": "Foo text the body of the message"}

If the json contains an id then the command will try to update the news in the database. Otherwise it will create a new news item. If there is no id at all then a new id will be generated.

On default the added news will be added to all users in the system. Later enhancements might be giving a list of usernames, filtering by groups and roles etc.

toirl commented 8 years ago

@ringo-framework/ringo-core-dev @gsiv what do you think of this proposal does it sound reasonable?