WORDPRESS PLUGIN: WP Upload Restriction

wp_logoWordPress allows user to upload various types of files using the media upload functionality. There is no visible way for restricting users from uploading files of one or more file types. However you can do this using filters. So, I decided to create a plugin which will provide user interface for selecting which files the users will be able to upload. WP Upload Restriction is the plugin which allows administrators to choose the files types and restricts users from uploading files other than the selected types. It’s a very simple, easy-to-use, yet powerful plugin.

Currently the file type restriction is applied to all users except administrators. In next release(s) role wise restrictions will be added.

To grab a copy of this plugin visit this link https://wordpress.org/plugins/wp-upload-restriction/.

WP Upload Restriction

Share

OpenERP7: Model is not showing in the model list

While creating a SQL backed report I faced a weird issue. Let me share the issue with you and how I solved it.

I added the model for the report to one of my existing modules and restarted the OpenERP server. I created views, window action and menu item to show the report. All worked fine. the report was showing perfectly. But when I went to Model list to set access rights to the model, I could not find the model there. I tried to find out the reason behind it… searched the web for any help… but no luck… it made me crazy. The report was running okay but the model was missing.

I thought to take the model out of the old module and create a new module for it. I did so, installed the new module and when I searched for the model in Model listing it was there. I reverted the changes by moving the model to my old module, uninstalled the old module and reinstalled it. Now the model is in the Model list.

I exactly don’t know what happened. I think when a module is installed OpenERP registers the model. As the old module was already installed, the model failed to register but the object was available to the window action and views. That’s why the report was working.

Hope this will help someone facing this issue.

Share

Great Saying

Two things to remember in life: Take care of your thoughts when you're alone and  take care of your words when you're with people

Share
blog