Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hr_attendance_analysis error on installation #27

Closed
marcok opened this issue Apr 8, 2015 · 10 comments
Closed

hr_attendance_analysis error on installation #27

marcok opened this issue Apr 8, 2015 · 10 comments

Comments

@marcok
Copy link

marcok commented Apr 8, 2015

When I try to install hr_attendance_analysis on current V8 I get this error, what can I do?

file "/opt/odoo/sources/odoo/openerp/models.py", line 1266, in _validate_fields
    raise ValidationError('\n'.join(errors))
ParseError: "ValidateError
Field(s) `arch` failed against a constraint: Invalid view definition

Error details:
Field `day` does not exist

Error context:
View `hr.attendance.analysis`
[view_id: 924, xml_id: n/a, model: hr.attendance, parent_id: n/a]" while parsing /opt/odoo/additional_addons/hr_attendance_analysis/hr_attendance_view.xml:19, near
<record id="view_attendance_analysis" model="ir.ui.view">
            <field name="name">hr.attendance.analysis</field>
            <field name="model">hr.attendance</field>
            <field name="priority" eval="17"/>
            <field name="arch" type="xml">
                <tree string="Employee attendances analysis">
                    <field name="employee_id"/>
                    <field name="name" string="Start date time"/>
                    <field name="end_datetime"/>
                    <field name="duration" sum="Total hours" widget="float_time"/>
                    <field name="outside_calendar_duration" sum="Overtime" widget="float_time"/>
                    <field name="inside_calendar_duration" sum="Within working schedule" widget="float_time"/>
                    <field name="day" invisible="1"/>
                </tree>
            </field>
        </record>
@eLBati
Copy link
Member

eLBati commented Apr 8, 2015

Hello @marcok hr_attendance_analysis has not been ported to 8.0 yet: https://github.com/OCA/hr-timesheet

@eLBati eLBati closed this as completed Apr 8, 2015
@marcok
Copy link
Author

marcok commented Apr 8, 2015

we are porting it (at least we try :) and make a pull request. ok?

@dreispt
Copy link
Member

dreispt commented Apr 8, 2015

@marcok Of course!

@marcok
Copy link
Author

marcok commented Apr 8, 2015

@dreispt it works now inV8. But I guess we have to add some more features. I would like to discuss it with you, do you have time for a skype session?

@eLBati
Copy link
Member

eLBati commented Apr 9, 2015

@marcok my suggestion: make a PR just to port the module to 8.0
Then, another PR for new features

@dreispt
Copy link
Member

dreispt commented Apr 9, 2015

@marcok If you want to discuss a possible feature, I suggest opening an Issue here. This allows any interested party to participate.

@tafaRU
Copy link
Member

tafaRU commented May 7, 2015

@marcok I'm planning to work on it next week. When have you planned to make the PR?

@marcok
Copy link
Author

marcok commented May 7, 2015

@tafaRU
Actually we did already: https://github.com/stclaus-hg/hr-timesheet/tree/overtime-calculation

Regarding to the new feature:
We recognized that timesheet analysis does not enough for us. It calculates overtime based on hours outside of the working period. But in our thinking overtime is the hours spent more than the daily duty hours (08:00-18:00 means 10h duty hours). And it doesn't matter if the empl. works from 7-17 or 8-17.

This is how overtime is calculated in most of the companies.
So we created a new module for that: https://github.com/stclaus-hg/hr-timesheet/tree/overtime-calculation/hr_timesheet_dh

But i was thinking about to create a complete new module (Employee time clock) which unites those two, Im not a huge fan for this small purpose modules. And overall we also need the full control over the repo, since we build mobile apps based on that module...

----Module Desc so far-----

Employee Time Clock

Employee Time Clock calculates over and undertime based on attendances and contracts/time schedules.
Over- undetime is displayed and stored in employees timesheets. The manager see the current saldo of the timesheet and the overall saldo from beginning as well.
There are two type of overtime calculated:

  • Worked time outside of the contract
  • Worked time more or less then the duty hours in the contract (over- undertime)

The module adds an additional report as well, where managers can analyse attendances, worked hours and over- undertime.
Several analysis settings can be configured, like:

  • Tolerance for sign-in and sign-out
  • Attendances and overtimes rounding
  • Different types of overtime, according to the overtime amount

So what was your plan to work for on this module?

@tafaRU
Copy link
Member

tafaRU commented May 8, 2015

@marcok at the moment we just planned the migration of the module hr_attendance_analysis.
Could you provide a PR goes in this way deducing it from your branch? Otherwise no problem, I will make a new one next week.

@marcok
Copy link
Author

marcok commented May 8, 2015

If its just about make it 8.0 compatible you can take : https://github.com/stclaus-hg/hr-timesheet/tree/overtime-calculation/hr_attendance_analysis
it should be ok.
as I said, atm we have the over-undertime functionality in another module

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants