Project

General

Profile

Actions

Defect #1349

closed

Bug generator generates invalid username

Added by Ondřej Kopr over 5 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Ondřej Kopr
Category:
Generating values
Target version:
Start date:
10/25/2018
Due date:
% Done:

100%

Estimated time:
Affected versions:
Owner:

Description

Username generator generates invalid usernames eq:

first name: Peter
last name: Bimbo Šourek

generated username (eq): peter.bimbo sourek

please replace/remove all whitespaces with given configuration property.

Affected version <9.2.2

Actions #1

Updated by Ondřej Kopr over 5 years ago

  • Status changed from New to In Progress
Actions #3

Updated by Ondřej Kopr over 5 years ago

Petr Michal wrote:

Imho default generator should cut name on first white space. Common behavior is to use peter.bimbo instead of peter.bimbosourek.

I have request from Vlada about this big bug, that I must add new parameter with character that replace white spaces. If you want cutoff everything after whitespace. The best way for now is create new generator, or I must implement new configuration property for this use case.

Actions #4

Updated by Ondřej Kopr over 5 years ago

  • % Done changed from 0 to 60

New property for email and username generator was added - replaceWhiteSpacesCharacter. Configuration contains character/s that will be used for replace white spaces. Now is for example replace white space with another white space (usefull feature), or with dot.

Configuration is visible from frontend.

Missing replace new screenshots in documentation and tests.

Actions #5

Updated by Ondřej Kopr over 5 years ago

  • Status changed from In Progress to Needs feedback
  • Assignee changed from Ondřej Kopr to Vladimír Kotýnek
  • % Done changed from 60 to 90

I added tests and update documentation.

doc: https://wiki.czechidm.com/9.2/documentation/generated_values
commit: https://github.com/bcvsolutions/CzechIdMng/commit/489267fdbd64b841f559505894cb97c68ac0ffdf (branch develop)

Please Vlada you are best for check the bugfix (Radek and Vitek hasn't time for my review :( ). I just add new configuration property for generators and remove or replace white spaces. You can test is via frontend. Thank you.

Actions #6

Updated by Vladimír Kotýnek over 5 years ago

  • Assignee changed from Vladimír Kotýnek to Ondřej Kopr

Neither do I have time for review. Also I think I'm not capable to do product code review. Ondra, please find someone else.

Actions #7

Updated by Ondřej Kopr over 5 years ago

  • Assignee changed from Ondřej Kopr to Vít Švanda

Vladimír Kotýnek wrote:

Neither do I have time for review. Also I think I'm not capable to do product code review. Ondra, please find someone else.

I thought you are the best, because you founded the bug and review is only about tested new frontend functionality. It was simple test war exists on jenkins.

So someone (Vitek probably) you must do review! Do it today or tomorrow, thank you.

Actions #8

Updated by Vít Švanda over 5 years ago

  • Assignee changed from Vít Švanda to Ondřej Kopr
  • % Done changed from 90 to 100

I did review and test. It works nice. I have only one comment: When is more spaces next to each other, then every single space is replaced for defined character. It is predicated behavior, but may be it is not correct in the all situations (may be yes, if depends ...).

Actions #9

Updated by Ondřej Kopr over 5 years ago

  • Status changed from Needs feedback to Closed

Vít Švanda wrote:

I did review and test. It works nice. I have only one comment: When is more spaces next to each other, then every single space is replaced for defined character. It is predicated behavior, but may be it is not correct in the all situations (may be yes, if depends ...).

I know it best solution for me. I want review from some more guy who is more business interest, but Vlada hasn't time for this. So thank you for review, I close this ticket for now.

Actions

Also available in: Atom PDF