예제 #1
0
    def process(self, commit, *args, **kwargs):
        data = commit.data

        try:
            state = State.objects.get(id=data.get("id"))
        except State.DoesNotExist:
            state = State()
            state.id = data.get("id")

        state.interest = data.get("interest")
        # state.commits.append(commit)
        commit.save()
        state.save()
예제 #2
0
    def process(self, commit, *args, **kwargs):
        data = commit.data

        try:
            state = State.objects.get(id=data.get("id"))
        except State.DoesNotExist:
            state = State()
            state.id = data.get("id")

        state.last_payment = data.get("state_last_payment")
        state.paid = data.get("paid")
        # state.commits.append(commit)
        commit.save()
        state.save()