Fetch the data based on the Employee Entered.

Hi,

i am Developing Employee Data Managemnt Application, Here the we can create Employees, and Create Projects, and there work codes , and map Project and work codes to the employees, After the Work Code is Mapped to the Employee, When he logged in he should be able to see the work codes that he assigned, and he should be able to fill the no of hours that he worked for a week on each work day as shown below


When he Enter and submit the data should be stored in work code wise....but in my case the same data was storing for all the work codes of all the employees..as shown below


i attached my oml file to this can any one please check and help me with this problem that i am facing...

Thanks&Regard

BasiviReddy M

Hi BasiviReddy,

This happens because there is no relation between timesheet line and employee.

Try to follow these steps

1. Add an attribute EmployeeId in the Timesheet line entity.

2. On submit button, if employee himself filling the timesheet then assign getuserid().

Check attached oml.

Hope it helps

Regards

Seema

Please check the records in your table using vew data and see if you really have duplicate records inserted (one for each work code) in table (this is less likely) or your aggrigate is not designed properly and it is returning wrong data to show same data for each work code.

I am suggesting this because your forign keys in TimeSheetLine entity are all non-mendatory and you are doing join on a join on it while feting data to display.

Seema Pandey wrote:

Hi BasiviReddy,

This happens because there is no relation between timesheet line and employee.

Try to follow these steps

1. Add an attribute EmployeeId in the Timesheet line entity.

2. On submit button, if employee himself filling the timesheet then assign getuserid().

Check attached oml.

Hope it helps

Regards

Seema

Hi,

Thankyou very much for your replay, i checked the oml that u have attach, but when the emloyee login and enter the Current week data it was Storing good,but when Employee  want to enter the next week data , the current week and next week are merged

example: Now i entered jan 6th to jan 12th now if i enter submit it was storing good...

But now if the employee entered the jan 13 to jan 19th data and if he submit the data was merging with the current week data


i want this data to show only when we select the next week ....

Can u please help me with this....


Thanks&Regards

BasiviReddy M