Our site www.viart.com site is operated by latest Viart Shop 5 with default Clear design
Topic Information
arkid
arkid
Hi all
 
Something I thought I would share quickly. I often use Viart for customers that will be using only a very small percentage of all its features. Because I know a large number of what it offers are going to be totally outside of the scope of their knowledge and usage I nowadays like to hide as much of what is not needed as possible from the CMS.
 
A key part of this is hiding whole tabs; specifically within the product properties page which is without a doubt one of the most accessed parts of just about any viart shop admin.
 
I always find I dont need half the properties inside the properties page and half the options just provoke unnescesery questions and confusion in the mind of my clients.
 
 
So to hide a whole tab, within Viart 4 (I think this is different in viart 3.x) you need to just do the following:
 
Go into templates/admin_product.html and look through the file. You'll see DIV wrappers that wrap around the entire contents of each tab. So for example, if I want to remove the whole downloads tab I need to find the part that starts...
 
<div id="data_downloads" style="{downloads_style}">
 
Now just updated this to read
 
<div id="data_downloads" style="display:none">
 
 
 
Next just update the related PHP file in your admin folder...
admin/admin_product.php
 
 
Now locate the comment "// set styles for tabs". Under here just remark out the line relating to the the corresponding tabs your hiding. In the example below im hiding a whole host of them....
 
 
// set styles for tabs
$tabs = array(
"general" => array("title" => PROD_GENERAL_TAB),
"desc" => array("title" => "Description & SEO Properties"),
/*
following tabs will be hidden
 
"quantity_prices" => array("title" => QUANTITY_PRICES_MSG),
"images" => array("title" => IMAGES_AND_APPEARANCE_MSG),
"points" => array("title" => POINTS_AND_CREDITS_MSG),
"other" => array("title" => PROD_NOTES_TAB),
"recurring" => array("title" => PROD_RECURRING_TAB),
"downloads" => array("title" => ADMIN_DOWNLOADABLE_MSG),
*/
"stock" => array("title" => STOCK_AND_SHIPPING_MSG),
"special_offer" => array("title" => PROD_SPECIAL_OFFER_TAB),
"notifications" => array("title" => PROD_NOTIFICATION_TAB),
"sites" => array("title" => ADMIN_SITES_MSG, "show" => $sitelist),
"subscriptions" => array( "title" => ACCESS_LEVELS_MSG, "show" => $has_any_subscriptions),
// "icecat" => array( "title" => "ICECat", "show" => true), // TODO: icecat
);
 
 
 
 
I hope this helps someone?!
 
arkid
arkid
I would add to this that its best to always duplicate the default /templates/admin folder and setup a new "Layout" inside the cms that points to the duplicated set of admin template files. This way you can switch back to the default layout easily which is useful for troubleshooting and also a help if viart or other 3rd parties ever need to access your setup and are confused by its modified menus.
 
Also its best to rename your actual /admin folder (to avoid hacking attempts) to something else. For changes to the php files in the admin folder, to assist troubleshooting its best to have an identical copy of your modified admin folder (minus your changes) handy so again if someone needs to access it they can and see the admin without the mods.