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

Bug : customer code with mask @99 #8344

Closed
Vaadasch opened this issue Mar 11, 2018 · 1 comment
Closed

Bug : customer code with mask @99 #8344

Vaadasch opened this issue Mar 11, 2018 · 1 comment

Comments

@Vaadasch
Copy link
Contributor

Vaadasch commented Mar 11, 2018

Impossible to create new customer with Elephant model and mask with @99

Environment

  • Version: [Version 7]
  • OS: [Synology DSM 6.1]
  • Web server: [Nginx vers.??]
  • PHP: [PHP 5.6]
  • Database: [MariaDB 5]

Expected and actual behavior

When we use the Elephant model in Third Party module to set the mask of the customer code and use the @99 option to reset at 0 every month, it is impossible to create new customer (and probably other things to).
The new customer form is filled, then the "Create third party" button is hit, the form appear again with no error. The expected behavior is to access to the "Customer/Prospect" section of the newly created third party.

Steps to reproduce the behavior

Use the Elephant module of the third party module and set customer mask at C{yy}{mm}{000@99}
Try to create new customer

@Vaadasch
Copy link
Contributor Author

Vaadasch commented Mar 11, 2018

It work well with Dolibarr vers. 5.0.1.

I've made my workarround with the following modifications :
File : htdocs/core/lib/functions2.lib.php line 1240 :

< if ($maskraz > 12) return 'ErrorBadMaskBadRazMonth';
> if ($maskraz > 12 && $maskraz != 99) return 'ErrorBadMaskBadRazMonth';

@Vaadasch Vaadasch changed the title Bug : client code with mask @99 Bug : customer code with mask @99 Mar 11, 2018
eldy added a commit that referenced this issue May 18, 2019
@eldy eldy closed this as completed in 1d98034 May 19, 2019
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

1 participant