Esempio n. 1
0
def setSupplierIDs(idslist):
    """
    Set suppliers ID's list, called when ListContacts packet received from Central server.
    """
    global _SuppliersChangedCallback
    global _ContactsChangedCallback
    oldsuppliers = contactsdb.suppliers()
    oldcontacts = contactsdb.contacts()
    contactsdb.set_suppliers(idslist)
    if _SuppliersChangedCallback is not None:
        _SuppliersChangedCallback(oldsuppliers, contactsdb.suppliers())
    if _ContactsChangedCallback is not None:
        _ContactsChangedCallback(oldcontacts, contactsdb.contacts())
Esempio n. 2
0
def getSupplierIDs():
    """
    Return list of suppliers ID's.
    """
    return contactsdb.suppliers()