Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
31736 Vues
def _reste(self, cr, uid, ids, context=None):
        data = self.pool.get('hr.line.echeancier').browse (cr, uid, ids, context=context)
        if data.move_check:
           res_obj=self.pool.get('hr.avance.pret').browse(cr, uid, ids)
           res_obj.reste_payer = res_obj.montant_credit - res_obj.montant 
           return res_obj.reste_payer

i have this ERROR: IndentationError: unindent does not match any outer indentation level BUT i can't understand what is the problem hier ?? help please :-)

Avatar
Ignorer

i suggest you to check your code with a clever code editor. maybe there's a mix of spaces and tabs

Meilleure réponse

Hi, for each block indentation must be 4 spaces, see your corrected code (corrected just for indentation).

def _reste(self, cr, uid, ids, context=None):
    data = self.pool.get('hr.line.echeancier').browse (cr, uid, ids, context=context)
    if data.move_check:
        res_obj=self.pool.get('hr.avance.pret').browse(cr, uid, ids)
        res_obj.reste_payer = res_obj.montant_credit - res_obj.montant 
        return res_obj.reste_payer

Bye

Avatar
Ignorer
Auteur

Thank you !

Publications associées Réponses Vues Activité
1
janv. 24
4474
1
mars 15
3814
2
mars 15
4458
0
janv. 20
3743
0
juin 19
3448