void dspTimePhasedSalesByItem::sPopulateMenu(QMenu *menuThis, QTreeWidgetItem *, int pColumn) { QAction *menuItem; _column = pColumn; menuItem = menuThis->addAction(tr("View Sales Detail..."), this, SLOT(sViewShipments())); menuItem->setEnabled(_privileges->check("ViewSalesHistory")); }
void dspTimePhasedSalesByItem::sPopulateMenu(QMenu *menuThis, QTreeWidgetItem *, int pColumn) { int menuItem; _column = pColumn; menuItem = menuThis->insertItem(tr("View Sales Detail..."), this, SLOT(sViewShipments()), 0); if (!_privileges->check("ViewSalesHistory")) menuThis->setItemEnabled(menuItem, FALSE); }