Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd

In  WORKED DAYS table i have 2 line


code ​ ​number_of_days


GLOBAL -​2


GLOBAL ​-1


and my code in 


Salary Rules, i create:

Amount Type: Python code


def get_total_days_global():

  total = 0

  for line in worked_days.GLOBAL:

    total += line.number_of_days

  return total


result = worked_days.GLOBAL and (contract.wage / worked_days.WORK100.number_of_days) * get_total_days_global()


This code get only number_of_days of line 2 ( number_of_days = -1)

Avatar
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
2
mei 25
4055
0
mei 23
3532
1
mrt. 18
4424
3
dec. 24
4825
2
dec. 24
2276