Ir al contenido
Menú
Se marcó esta pregunta
1 Responder
3371 Vistas

Hi all

i am trying to make overtime rule and get wrong python code

the rule
 result = (((contract.wage/30)/8)*0.25)*(inputs.OVERTIME_DAY_DAYS and inputs.OVERTIME_DAY_DAYS.amount)

 

Avatar
Descartar
Mejor respuesta

I guess the problem is with this part: (inputs.OVERTIME_DAY_DAYS and inputs.OVERTIME_DAY_DAYS.amount).

Try to write it as: (bool(inputs.OVERTIME_DAY_DAYS.amount) and inputs.OVERTIME_DAY_DAYS.amount).

Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
0
may 22
3020
1
may 22
2572
1
ene 22
2310
1
oct 21
14778
2
ene 24
14874