No, unfortunately we haven't separate person edit interface, which would be handy. But the person data (in crm_persons table) should be deleted automatically when all connections (records in crm_contacts) are deleted. But I have just tested and it is not.
This seems to be a bug, I will investigate it further.
J.

Above description is how it works in contact browsers, but the same is implemented in delete_entity_contacts(), which is used when deleting customer/supplier.
J.

Crm contacts deletion is implemented in contacts.db_delete method. As any person can be connected to more than one action, person cannot be deleted until all contacts are deleted. So the person is preserved until you delete all related contacts, and deleted with the last contact of this person in database.
J.

29

(15 replies, posted in Report Bugs here)

Recognising http vs https is how it worked before the change.  But this means that once logged in to your installation via http, it willl be selected always on later logins (unless there is automatic http>https redirection). Logging via http means sending password in plain, which is completely unsecure and should be avoided if possible.
IMO user safety should be prioritized when dealing with sensitive data (like accounting), so sending cookies only via secure channel is just better policy  default. Admin choice to lower down security is now required to be made as conscious decision, and should not depend on arbitrary ISP server settings.
J.

30

(15 replies, posted in Report Bugs here)

This change was introduced to enforce secure session in FA, so all works as expected if FA is accessed via https.
For rare situations when https is not available, additional configuration value could be handy, so we have added it.
Now, if you know what you are doing, you can switch off https cookies enforcing in session.inc.
Unfortunately  this option cannot be added in sysprefs/config.php because the settings are not available before session is started.
J.

Yes, indeed those were traces of some never implemented per customer multicurrency clearences. Fixed.
J.

On the second screenshot some fields are not editable because the quotation has been realized by items delivery or invoicing. This is proper behavior: you can change quotation only until it is not used as base for any legal transaciton.

J.

33

(2 replies, posted in Report Bugs here)

This helper function was implemented for additional fine grained access control. Current access scheme allows only constraints on access to application page. As far as I know it was never fully implemented in core FA code, maybe some extensions use it.
J.

Thank you notrinos. The results seems to be similar, but in fact problem can also depend on specific database content/structure as kvvaradha suggested.

@kvvaradha

Could you check the change proposed above with the same database you had timeouts before?

J.

So I guess problem appears just for huge customer table.

@kvaradha, notrinos
Please test slightly changed inquiry helper, I hope this form will behave better:

//----------------------------------------------------------------------------------------
function get_sql_for_customer_inquiry($from, $to, $cust_id = ALL_TEXT, $filter = ALL_TEXT, $show_voided = 0)
{
    $date_after = date2sql($from);
    $date_to = date2sql($to);

      $sql = "SELECT
          trans.type,
        trans.trans_no,
        trans.order_,
        trans.reference,
        trans.tran_date,
        trans.due_date,
        debtor.name,
        branch.br_name,
        debtor.curr_code,
        IF(prep_amount, prep_amount, trans.ov_amount + trans.ov_gst + trans.ov_freight
            + trans.ov_freight_tax + trans.ov_discount)    AS TotalAmount,"
        . "IF(trans.type IN(".implode(',',  array(ST_CUSTCREDIT,ST_CUSTPAYMENT,ST_BANKDEPOSIT))."), -1, 1)
                *(IF(prep_amount, prep_amount, trans.ov_amount + trans.ov_gst + trans.ov_freight
            + trans.ov_freight_tax + trans.ov_discount)-trans.alloc) Balance,
        debtor.debtor_no,";

        $sql .= "trans.alloc AS Allocated,
        ((trans.type = ".ST_SALESINVOICE." || trans.type = ".ST_JOURNAL.")
            AND trans.due_date < '" . date2sql(Today()) . "') AS OverDue ,
        Sum(line.quantity-line.qty_done) AS Outstanding,
        Sum(line.qty_done) AS HasChild,
        prep_amount
        FROM "
            .TB_PREF."debtor_trans as trans
            LEFT JOIN ".TB_PREF."debtor_trans_details as line
                ON trans.trans_no=line.debtor_trans_no AND trans.type=line.debtor_trans_type
            LEFT JOIN ".TB_PREF."voided as v
                ON trans.trans_no=v.id AND trans.type=v.type
                        LEFT JOIN ".TB_PREF."audit_trail as audit ON (trans.type=audit.type AND trans.trans_no=audit.trans_no)
                        LEFT JOIN ".TB_PREF."users as user ON (audit.user=user.id)
            LEFT JOIN ".TB_PREF."cust_branch as branch ON trans.branch_code=branch.branch_code
            LEFT JOIN ".TB_PREF."debtors_master as debtor ON debtor.debtor_no = trans.debtor_no" // exclude voided transactions and self-balancing (journal) transactions:
            ." WHERE";

    if ($filter == '2')
        $sql .= " ABS(IF(prep_amount, prep_amount, trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount)-trans.alloc)>"
            .FLOAT_COMP_DELTA;
    else {
        $sql .= " trans.tran_date >= '$date_after'
            AND trans.tran_date <= '$date_to'";
    }

    if (!$show_voided)     
             $sql .= " AND ISNULL(v.date_) AND (trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount) != 0";


       if ($cust_id != ALL_TEXT)
           $sql .= " AND trans.debtor_no = ".db_escape($cust_id);

       if ($filter != ALL_TEXT)
       {
           if ($filter == '1')
           {
               $sql .= " AND (trans.type = ".ST_SALESINVOICE.") ";
           }
           elseif ($filter == '2')
           {
               $sql .= " AND (trans.type <> ".ST_CUSTDELIVERY.") ";
           }
           elseif ($filter == '3')
           {
            $sql .= " AND (trans.type = " . ST_CUSTPAYMENT
                    ." OR trans.type = ".ST_BANKDEPOSIT." OR trans.type = ".ST_BANKPAYMENT.") ";
           }
           elseif ($filter == '4')
           {
            $sql .= " AND trans.type = ".ST_CUSTCREDIT." ";
           }
           elseif ($filter == '5')
           {
            $sql .= " AND trans.type = ".ST_CUSTDELIVERY." ";
           }

        if ($filter == '2')
        {
            $today =  date2sql(Today());
            $sql .= " AND trans.due_date < '$today'
                AND (trans.ov_amount + trans.ov_gst + trans.ov_freight_tax +
                trans.ov_freight + trans.ov_discount - trans.alloc > 0) ";
        }
       }

    $sql .= " GROUP BY trans.trans_no, trans.type";

       return $sql;
}

Here cross product of debtor_trans and debtor_master is superseded by LEFT JOIN which should reduce processing time.
J.

Seems the query used here is suboptimal. Really 10 seconds should be enough to retrieve 10 records from database.
Unfortunately I don't have such big databse to test, but you can experiment with query form in get_sql_for_customer_inquiry().

J.

Inquires use paged transaction lookup ie only limited number of records is retrieved at once,  so this issue should not appear here. Unless you will set 10000 records per page to be displayed :-).
J.

I think better solution is change in line 103 of reporting/includes/reports_classes.inc (fifth argument of submit() call).
When you change 'default popup' string here to 'default progress popup' effective report engine timeout should change to max. 10 minutes (this is visualised by progressbar icon instead of swirl).
Could you please test if this fix works for you without any side effects?

Janusz

39

(4 replies, posted in Development)

boxygen wrote:

Is there any way we can activate Ajax on Input Text Field if the value is changed then Ajax is called?

Yes, you can use text_cells_ex helper which has optional submit_on_change parameter.

Braath Waate suggested commit seems to be part of wider code change, so I think it would be easier just to use existing helper option in your customization.

J.

Yes, while I have not found the issue on standard themes, this can be a problem when SVG element are used.
Thank you for investigating the issue, I have pushed the fix to FA repo.
J.

Yes, seems good idea. The hooks were implemented to allow extension modules deal with extra fields in databases. I think the overall pre/post hooks system needs some review. I have added mantis report for this issue.

Repo has been updated. Thank you.
J.

FA indeed needs better mechanism to avoid problems with ajax timeout, but the javascript code is complex, so it wll need some time to adopt. For now I have included in repo proposed additional checks for payment allocations (for both supplier and customer).

If you have any ready bugfix  or complete improvement suitable for most FA users you can send it either to contributions mailbox or via mantis, but better is approach seems to be presenting proposed changes on forum. This allows wider change review and usually helps make changes mature enough to be integrated into main code.

Janusz

44

(3 replies, posted in Report Bugs here)

This works properly for me too. random_id function used here makes 3 different approaches to generate random filename, the last being Mersenne Twister generator, which does not rely on any special php extension, so should work in all php versions.  Also, uniquid() is not random, so this change would open additional vulnerability in FA, making temporary copy of pdf documents easy to find.
If you will find source of this problem, please report it again, we will try to fix it.
Janusz

45

(8 replies, posted in Translations)

Translations have been added to repo and FA installer.
Thank you very much.
J.

46

(12 replies, posted in Fixed Assets)

Update_no=-1 make no sense. More over, audit trail update at this point is just obsolete. Fixed in repo.

Janusz

47

(27 replies, posted in Wish List)

I have pushed additional  fixes to repo, hopefully all will work now as expected. Regarding change in attachments.filetype length it will be addressed in 2.5 upgrade scripts.
Thank you.
J.

48

(27 replies, posted in Wish List)

@ApMuthu

Thanks for the fix. But in the three mentioned files 'false'/'true' string appears in completely different context i.e. as text representation of boolean value, so there s no need for change here.

@rafat
I will fix those issues too.

If you want test  it, you have to add 'custom'=>$customer_id  in parameters array of $Refs->get_next() wherever applicable, e.g. in sales/sales_order_entry.php:479
J.

@boxygen
I have to reopen this thread for a moment.

Finally to maintain database consistency on existing installations I have reverted the changes in add_stock_adjustment_item() and related fixes in reports rep301, rep308.  We will address all this in forthgoing 2.5 release. We plan to change stock_moves table structure to better upport inventory cost tracking. All comments regarding this feature are welcome  in this thread.

As far as I understand, after revertion all should still work as expected, as suggested changes where mostly technical. If I'm wrong, please do not hesitate to reopen the thread and explain the lasting problems (if any) once again.
J.