00 Day
00 Hour
00 Min
00 Sec

JuacOHI

Forum Replies Created

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • in reply to: Problem with Document Manager Add-On #57372
    JuacOHI
    Participant

    I saw a new update today in the main plugin and i didn’t see this included, so i guess you’ve to update the add on instead of the main plugin or am i wrong ?

    in reply to: Problem with Document Manager Add-On #57290
    JuacOHI
    Participant

    Hey, thanks for the quick answer!. I sent an email in the Contact section as well.
    Hope you guys can fix it soon because it gave me a huuuuuuuge problem and at the end i had to deactivate the CRM module.

    in reply to: Bug report: Termination Date #16462
    JuacOHI
    Participant

    I FOUND THE ERROR

    In the file modules/hrm/inclues/models/employee.php
    In line 29, it says ‘termination_datA’,
    It should be ‘termination_datE’,

    in reply to: Bug report: Termination Date #16461
    JuacOHI
    Participant

    I checked and..
    From the v1.3.0 (Jan 09) in advance you can’t update the termination_date when you terminate an employee.

    in reply to: Error 414 URL Too Long #10829
    JuacOHI
    Participant

    Hey, sorry for the late reply, i was on vacations.. hehe

    It isn’t that i’m gonna search the same employee, it was just an example so you didn’t have to add mroe than one emplyoee and do the research… i don’t search the same employee, but its the same result with same or different ones..
    I’ve a lot employees, so when someone has to search a lot of employees for any reason, they just search them and then they open the employee in a new tab so they can keep searching in the same tab that they currently are.

    Its weird that i get the error, like i said, its a 100% clean install..

    Maybe there’s a problem with the spanish translation ?.. I’ve wordpress in spanish, but everything is by default. didn’t change a thing.

    Here is a video: https://drive.google.com/file/d/1mOg2n7t7f7h9vO0xD90NE9fPLEDmTH0N/view

    Btw, i can work with this issue, i’m jsut reporting the bug to make this plugin even better 🙂

    in reply to: Error 414 URL Too Long #10188
    JuacOHI
    Participant

    I just made a clean and fresh install with xampp, and i still got the error.
    To make it happen, do this:

    -Search an employee, any that you have
    -When it shows you the result, don’t open the employee nor do something, just click the search button again (it will still have the name that you searched). And again. And again.

    If you copy/paste the url, you will notice that its really long, and its how i described before.

    This is a pain in the ass when for example someone has to search 5+ employees and uses the search button and opens the profile of the employee in a new tab, After the error, will always have to refresh the page… so its time wasted

    in reply to: Roles or Edit only in the same Location #7066
    JuacOHI
    Participant

    Thanks! That works really good and I’m sure that a lot people will be happy with this easy fix 😀

    btw you copy/pasted it wront, because it should be:
    $man​ager = new \WeDevs\ERP\HRM\Employee( get_current_user_id() );
    if ( $employee->get_work_location_id() === $manager->get_work_location_id() ) {
    // write your code here
    }

    You missed the “$man”

    Thanks for the quick help!!

    in reply to: Roles or Edit only in the same Location #7014
    JuacOHI
    Participant

    Mhm.. sadly I’m not so good in PHP or making plugins to make one for custom roles and things like that.. For me its easier to add some line of code and “fix/patch” it to what i need..
    Can you help me with this ?, how can i ask to get the current user work location ? so i could add an IF asking something like this:
    if ( $employee->get_work_location () == current_user_work_location () ){
    With that line of code i could get what i want, i just don’t know how to get the current user work location.

    in reply to: Roles or Edit only in the same Location #6905
    JuacOHI
    Participant

    Sorry if i wasn’t clear.

    I’m asking if is possible to only let people edit employees that are from the same location. (From ERP Settings -> Locations), which when you add a new employee is this data: (I deleted the part that it says php becaue can’t paste php code)
    <li data-selected="{{ data.work.location }}">
    erp_html_form_input( array(
    'label' => __( 'Location', 'erp' ),
    'name' => 'work[location]',
    'value' => '{{ data.work.location }}',
    'custom_attr' => array( 'data-id' => 'erp-company-new-location' ),
    // 'class' => 'erp-hrm-select2-add-more erp-hr-location-drop-down',
    'class' => 'erp-hrm-select2',
    'type' => 'select',
    'options' => erp_company_get_location_dropdown_raw()
    ) );

    So, in resume if I have 3 locations (main location, second and third), and I have an employee that can manage HRM , and this person is from Main Location, only let him edit employees that are from Main Location and NOT from second and third.
    After taking in consideration what i just said, if i go to single.php (where you can find all the code to show the employee), I think that I could add a condition in the button edit to ONLY show that button if i’m from the same Location, and if not, hide the button but i can still see the employee from other locations.

    So I think that the code would be something like… get current user and ask his location, and then ask the location of the employee that i’m seeing, and if both match, let me edit that employee.
    My best guess is that it should be in this line of code, which is when it shows the edit button in the Action Box.
    <h3 class="hndle"><span>( 'Actions', 'erp' ); ?></span></h3>
    <div class="inside">

    if ( current_user_can( 'erp_edit_employee', $employee->id ) ) {

    <span class="edit">id; ?>" data-single="true" href="#">_e( 'Edit', 'erp' ); ?></span>
    }

Viewing 9 posts - 1 through 9 (of 9 total)

Contact Us

Reach out to us for any inquiry

You must enter full name
You must enter email
You must enter message

We received your query

We will reply to you very soon :)