Giter Club home page Giter Club logo

Comments (13)

kamshory avatar kamshory commented on July 27, 2024

The state maybe difference each device. Normally, we don't need the state. The state of check in and check out can be determined from the sequence of attendance at certain time intervals. You should compare it with other attendance at that time span, for example employee shifts.

from zklibrary.

kamshory avatar kamshory commented on July 27, 2024

My best practice, I get the attendance data and I save it into the database. I create a event trigger on the table on insert. If there is no attendance of the user at the time span, so the attendance will be considered as check in, else the attendance will be considered as check out.
To get the real check out, select the last attendance of the user at the time span. But if the is only one attendance of the user at the time span, check out is not exist.

from zklibrary.

RahamSher avatar RahamSher commented on July 27, 2024

@kamshory hats off.Thank you sir...

from zklibrary.

abdulraheemzaqout avatar abdulraheemzaqout commented on July 27, 2024

sir can i take the break time??

from zklibrary.

kamshory avatar kamshory commented on July 27, 2024

I have any time.
Tell me what can I do.

from zklibrary.

abdulraheemzaqout avatar abdulraheemzaqout commented on July 27, 2024

hello
sir i mean can i take the break in /out for employee?

from zklibrary.

kamshory avatar kamshory commented on July 27, 2024

I live in Jakarta. How do we can talk?

from zklibrary.

abdulraheemzaqout avatar abdulraheemzaqout commented on July 27, 2024

from zklibrary.

junaidranjha avatar junaidranjha commented on July 27, 2024

@RahamSher were you able to differtentiate between check in and check out? If yes, then how?

from zklibrary.

kamshory avatar kamshory commented on July 27, 2024

The first check on the day is check in and the last check on the day is check out. So, at least user check twice in a day.

from zklibrary.

wombiro avatar wombiro commented on July 27, 2024

So is the checkin/checkout showing now?

from zklibrary.

abdulraheemzaqout avatar abdulraheemzaqout commented on July 27, 2024

sir i want to take the leave time from the machine and the overtime can i take this moves??

from zklibrary.

gusbenites avatar gusbenites commented on July 27, 2024

In the Zkteco MB360 the check in and check out value is in position 66 and they are 2 characters.

00: entry
01: output
04: intermediate entry
05: intermediate output

zkattendance.php in zkgetattendance($self) function


while ( strlen($attendancedata) > 40 ) {
                $u = unpack( 'H78', substr( $attendancedata, 0, 39 ) );
                //24s1s4s11s

                //$uid = hexdec( substr( $u[1], 0, 6 ) );
                //$uid = explode(chr(0), $uid);
                //$uid = intval( $uid[0] );
                /*$u1 = hexdec( substr($u[1], 4, 2) );
                $u2 = hexdec( substr($u[1], 6, 2) );
                $uid = $u1+($u2*256);*/
                $uid = trim(substr( $attendancedata, 4, 14 ), "\x0");
                
                $id = intval( str_replace("\0", '', hex2bin( substr($u[1], 6, 8) ) ) );
                $state = hexdec( substr( $u[1], 56, 2 ) );
                $timestamp = decode_time( hexdec( reverseHex( substr($u[1], 58, 8) ) ) ); 
                $sentido =hexdec(substr($u[1], 66,2));  // <---------------- check in - check out
                # Clean up some messy characters from the user name
                #uid = unicode(uid.strip('\x00|\x01\x10x'), errors='ignore')
                #uid = uid.split('\x00', 1)[0]
                #print "%s, %s, %s" % (uid, state, decode_time( int( reverseHex( timestamp.encode('hex') ), 16 ) ) )
                
               array_push( $attendance, array( $uid, $id, $sentido, $timestamp, $state  ) ); // <-- modify
                
                $attendancedata = substr( $attendancedata, 40 );
            }`

from zklibrary.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.