All datasources done. Now to wire them up in the components.

Plus ElementRefs are now optional as they cannot be initialized
This commit is contained in:
2020-11-23 10:25:53 +05:30
parent 39e3cc51bb
commit af343cb7f9
66 changed files with 556 additions and 328 deletions

View File

@ -130,7 +130,10 @@ async def show_list(db: Session = Depends(get_db), user: UserToken = Depends(get
"isActive": item.is_active,
"isReconcilable": item.is_reconcilable,
"isStarred": item.is_starred,
"costCentre": item.cost_centre.name,
"costCentre": {
"id": item.cost_centre_id,
"name": item.cost_centre.name,
},
"isFixture": item.is_fixture,
}
for item in db.query(Account).order_by(Account.type).order_by(Account.name).order_by(Account.code).all()

View File

@ -132,7 +132,10 @@ async def show_list(db: Session = Depends(get_db), user: UserToken = Depends(get
"salary": item.salary,
"points": item.points,
"isActive": item.is_active,
"costCentre": item.cost_centre.name,
"costCentre": {
"id": item.cost_centre_id,
"name": item.cost_centre.name,
},
"joiningDate": item.joining_date.strftime("%d-%b-%Y"),
"leavingDate": "" if item.is_active else item.leaving_date.strftime("%d-%b-%Y"),
"isStarred": item.is_starred,