Ejemplo n.º 1
0
    def PagarParcela(self, id):
        # print(self.tb_parcelasVenda.item(id, 0).text())

        if self.tb_APagar.cellWidget(id, 6).text():
            INSERI = CrudAPagar()
            INSERI.idConta = id
            INSERI.valorPago = self.tb_APagar.cellWidget(id, 6).text().replace(
                ",", ".")

            INSERI.dataPagamento = QtCore.QDate.toString(
                QtCore.QDate.currentDate(), "yyyy-MM-dd")

            INSERI.cadContaPagar()
            self.tabelaAPagar()
Ejemplo n.º 2
0
    def Pagar(self, id):
        # print(self.tb_Parcelas.item(id, 0).text())

        if self.tb_Parcelas.cellWidget(id, 3).text():
            INSERI = CrudAPagar()
            INSERI.idConta = self.tb_Parcelas.item(id, 0).text()
            INSERI.valorPago = self.tb_Parcelas.cellWidget(
                id, 3).text().replace(",", ".")
            INSERI.formaPagamento = self.cb_FormaPagamento.currentData()
            INSERI.dataPagamento = QtCore.QDate.toString(
                QtCore.QDate.currentDate(), "yyyy-MM-dd")

            INSERI.PagarConta()
            self.ParcelasAPagar()
Ejemplo n.º 3
0
    def PagarParcela(self, id):

        if not self.tx_valorPago.text():
            self.tx_valorPago.setFocus()
        elif not self.cb_formaPagamento.currentData():
            self.cb_formaPagamento.setFocus()
        else:
            INSERI = CrudAPagar()
            INSERI.idConta = self.tx_Cod.text()
            INSERI.formaPagamento = self.cb_formaPagamento.currentData()
            INSERI.valorPago = self.tx_valorPago.text().replace(",", ".")
            INSERI.dataPagamento = QtCore.QDate.toString(
                QtCore.QDate.currentDate(), "yyyy-MM-dd")
            INSERI.PagarConta()
            self.BuscaContaAPagar(self.tx_Cod.text())

        pass