News:

Looking for documentation? Take a look on our wiki

Main Menu

VM3 Synthetic Dashboard (free)

Started by nordmograph, September 18, 2012, 15:40:30 PM

Previous topic - Next topic

Actlas

I installed the new module but I can't see where the time period for totals can be changed?
The graph isn't properly displayed on our website though. Could you check your PM?

nordmograph

Hello

I recommend you use our forum for support. It makes it easier for us to track posts.
The time period to be set in the module settings. The total shows at the end of the table (table to be displayed)
The charts width is displayed at its best when module tab is the one open when the page loads.

Actlas

The module from your download link still appears to be created Sep2012.
Is this the right version? I don't see the totals at the end of the table.

lindapowers

Hi, is happening the same to me, actually I didn't notice any difference,

regards

nordmograph

I just reuploaded again and checked. You can redownload it.
:)

nordmograph

Module has just got a new little update: a new tab with a RSS feed genarator/updater for store latest products.
Somehow usefull has VM2 doesn't have that feature anymore.

Feedback welcome.

lindapowers

Hi nordmograph

At the first version of the module I clicked at the order tab and next time I went log in the administrator my last view (order tab) was saved.

Not a big issue but would be nice if we could somehow show or choose the initial view.

Regards

lindapowers

Hi Nordmograph

When you have time could you please make the module show the translations correctly for the order status.

When we use this keys as order status the module doesn't show the value, instead displays the key. Language files have been updated and at the order status we have to use this keys which get translated correctly everywhere.

COM_VIRTUEMART_ORDER_STATUS_SHIPPED
COM_VIRTUEMART_ORDER_STATUS_REFUNDED
COM_VIRTUEMART_ORDER_STATUS_CANCELLED
COM_VIRTUEMART_ORDER_STATUS_CONFIRMED
COM_VIRTUEMART_ORDER_STATUS_CONFIRMED_BY_SHOPPER
COM_VIRTUEMART_ORDER_STATUS_PENDING

Regards

nordmograph

Hello

I updated the module for a minor bugfix causing a duplicate month name entry only happening in the last days of the month.
Just fixed.

lindapowers

Since I can die waiting for you to fix the multilingual issue I did a semi fix myself, at least it shows the order status letter code correctly:

administrator\modules\mod_vmsynthdashboard\tmpl\default.php

Around line 312 change:

<a href = "<?php echo $order_name_link?>" ><?php  echo $row->order_status_name?></a>

to:

<a href = "<?php echo $order_name_link?>" ><?php  echo $row->order_status?></a>






nordmograph

#25
Hey Lindapowers

I updated the module just for you,(actually you only complained about these backend language strings).
I'm not using those from VM language files, the module has its own strings for order statuses. They also have style.
Make a backup of the old module and upgrade to the latest.

And add this to your language file
C="<font style='color:green;'>Confirmed</font>"
U="<font style='color:green;'>Confirmed by shopper</font>"
S="<font style='color:blue;'>Shipped</font>"
P="<font style='color:orange;'>Pending</font>"
X="<font style='color:red;'>Canceled</font>"
R="<font style='color:red;'>Refunded</font>"

lindapowers

Quote from: nordmograph on November 05, 2013, 16:57:03 PM
Hey Lindapowers

I updated the module just for you,(actually you only complained about these backend language strings).
I'm not using those from VM language files, the module has its own strings for order statuses. They also have style.
Make a backup of the old module and upgrade to the latest.

And add this to your language file
C="<font style='color:green;'>Confirmed</font>"
U="<font style='color:green;'>Confirmed by shopper</font>"
S="<font style='color:blue;'>Shipped</font>"
P="<font style='color:orange;'>Pending</font>"
X="<font style='color:red;'>Canceled</font>"
R="<font style='color:red;'>Refunded</font>"


Well thanks a lot, however my request affects ALL multilingual websites.

And I posted in your forum how the module showed those status, not my problem if people can't even notice or probably care about having the module display:

COM_VIRTUEMART_ORDER_STATUS_CONFIRMED instead of Confirmed or Confirmado in our case.

I was the only one requesting here the use of 2 taxes in the same order to make orders legally correct for all Europe... something from now on implemented in the core of VM, so im glad being alone sometimes ;)

Regards

WebStuff

#27
Hi, installed the module but I have made a tweak to the code as I have different Order statuses that I want to count e.g. Collected, Shipped and Confirmed.

Here are the changes if you want to add them feel free.

1/.
In file: administrator/modules/mod_vmsynthdashboard/mod_vmsynthdashboard.xml
Change:
<fieldset name="basic">
to :

<fieldset name="basic" addfieldpath="administrator/modules/mod_vmsynthdashboard/elements">
<field name="orderstates" type="vmorderstates" multiple="multiple" label="Order Statuses To Report" description="List of Order Statuses to count towards totals" />
You could change the literal strings or add them to a translation file.
And add <folder>elements</folder> to the <files> section

2/.
Add folder /elements to /administrator/modules/mod_vmsynthdashboard  folder.
and create a file called vmorderstates.php
paste this into that.
<?php
// Check to ensure this file is included in Joomla!
defined('_JEXEC') or die( 'Restricted access' );

jimport'joomla.form.fields.list' );

class 
JFormFieldVMOrderStates extends JFormFieldList {

    
/**
     * Element name
     * @access protected
     * @var string
     */
    
var $_name 'vmorderstates';

protected function getOptions() {

$lang JFactory::getLanguage();
$lang->load('com_virtuemart',JPATH_ADMINISTRATOR);
$db JFactory::getDBO ();
$sql $db->getQuery(true)
->select('order_status_code,order_status_name')
->from($db->qn('#__virtuemart_orderstates'))
->where($db->qn('virtuemart_vendor_id').'= 1')
->where($db->qn('order_status_code').'<> \'I\'')
->order('ordering');
$db->setQuery($sql);
$orderstates $db->loadObjectList ();

$options = array();
foreach ($orderstates as $orderstate) {
$orderstate->order_status_nameJText::($orderstate->order_status_name);
$options[] = JHTML::_('select.option'$orderstate->order_status_code$orderstate->order_status_name);
}

return $options;

}

}


3/.
Open administrator/modules/mod_vmsynthdashboard/helper.php for editing
In the function getXMonthSells (around line 22)
add the following:

$vmorderstates = $params->get('orderstates', array('C'));
$orderstates = "";
for( $i=0 ; $i < count($vmorderstates); $i++) {
$orderstates .= "`order_status`='".$vmorderstates[$i]."' ";
if ( $i < (count($vmorderstates)-1) ) {
$orderstates .= "OR ";
}
}

and alter query statement around line 69 to be:
$q ="SELECT `order_total` FROM `#__virtuemart_orders` WHERE ( $orderstates ) AND SUBSTRING(`created_on`,1,7) = '".$q_date."' " ;


That's it. Enjoy.
I've attached a screenshot of the settings with the altered code.

[attachment cleanup by admin]

nordmograph

Great  8)
I just added your changes to the archive.
Thanks a lot, very usefull, I'm sure it wil please many.

lindapowers

Thanks guys works great, with this fixes is even better,