Search found 181 matches

by luis
Tue Jan 15, 2019 8:09 am
Forum: Scripting & Webservices issues
Topic: Searching userrecords
Replies: 3
Views: 539

Re: Searching userrecords

If you want to make sure a record field value is unique, just mark it as unique in the field definition. It will then be unique among all records of this type, regardless of the user. I'd suggest a different approach: find the record using a JPQL and make sure its user is the expected one. It would ...
by luis
Wed Dec 26, 2018 2:19 pm
Forum: Bug - problem reporting
Topic: Can't create user with new phone number
Replies: 1
Views: 345

Re: Can't create user with new phone number

Cyclos uses the libphonenumber (https://github.com/googlei18n/libphonenumber) to handle numbers. Probably there's a newer version of it that supports the new Vietnamese numbers. Just download the JAR for the lastest version on https://repo1.maven.org/maven2/com/googlecode/libphonenumber/libphonenumb...
by luis
Tue Dec 11, 2018 12:25 pm
Forum: Scripting & Webservices issues
Topic: About API search transaction
Replies: 3
Views: 603

Re: About API search transaction

As the transaction is not returned even when no direction filter is set, probably it is excluded by another filter, such as group visibility for admins.
by luis
Mon Dec 10, 2018 7:28 am
Forum: Scripting & Webservices issues
Topic: About API search transaction
Replies: 3
Views: 603

Re: About API search transaction

I've just tested here, and both {"direction": "CREDIT"} and {"direction": "DEBIT"} works as expected.
Are you sure you're using the correct strings? Can you send the full query object?
by luis
Mon Dec 10, 2018 7:11 am
Forum: Scripting & Webservices issues
Topic: Confirm about API authorize the advertisement
Replies: 1
Views: 359

Re: Confirm about API authorize the advertisement

There's no specific method to authorize the advertisement.
Instead, as admin, just set the status from PENDING to ACTIVE in a regular AdService.save(dto).
by luis
Wed Sep 12, 2018 9:08 am
Forum: Scripting & Webservices issues
Topic: Save info in a userprofile field on failing validation
Replies: 3
Views: 628

Re: Save info in a userprofile field on failing validation

There is another alternative. In the first solution, the rollback callback runs after the main transaction finishes. If, for some reason, the server crashes in-between, the database state may be inconsistent. The other solution involves opening a parallel transaction, in which you can wait until it ...
by luis
Wed Sep 12, 2018 8:24 am
Forum: Scripting & Webservices issues
Topic: Script-changes to userprofile are not visible in profile history
Replies: 5
Views: 1156

Re: Script-changes to userprofile are not visible in profile history

For this you have to use the regular save of the UserService, through DTOs, not directly manipulating the entity.
Example:

Code: Select all

def dto = userService.load(userId)
def fields = scriptHelper.wrap(dto)
fields.fieldName = value
userService.save(dto)
by luis
Wed Sep 12, 2018 8:21 am
Forum: Scripting & Webservices issues
Topic: Can a script retrieve the fromName from the smtpConfiguration?
Replies: 2
Views: 528

Re: Can a script retrieve the fromName from the smtpConfiguration?

You can use the following:

Code: Select all

sessionData.configuration.emailName
by luis
Wed Sep 12, 2018 8:17 am
Forum: Scripting & Webservices issues
Topic: Save info in a userprofile field on failing validation
Replies: 3
Views: 628

Re: Save info in a userprofile field on failing validation

Hi, We have an extension script setup when validating users. I am trying to let this script save some information in a user profile field when the validation is failing. The relevant code is like this: def usr = scriptHelper.wrap(user) // .. other code here .. // .. a check indicates something is w...
by luis
Wed Jul 18, 2018 2:31 pm
Forum: Bug - problem reporting
Topic: Unable To Create New Operators
Replies: 3
Views: 725

Re: Unable To Create New Operators

Thanks for the report.
Will be fixed in the next release.
by luis
Thu Dec 07, 2017 9:00 am
Forum: Bug - problem reporting
Topic: EntityManagerHandler fails on search for INamedEntity
Replies: 4
Views: 879

Re: EntityManagerHandler fails on search for INamedEntity

Actually, EntityManagerHandler can find entities by internal name, not by name. In fact, the interface is not INamedEntity, but IInternalNamedEntity instead. And CustomScript doesn't implement IInternalNamedEntity, it has no internal name. If you need a script by name, you can use this query instead...
by luis
Fri Nov 17, 2017 8:17 am
Forum: Bug - problem reporting
Topic: Error when running API and using session
Replies: 4
Views: 873

Re: Error when running API and using session

Accessing via basic authentication (stateless) or via session (stateful) shouldn't impact on the problem, which is on locating a user. Maybe the product of the user creating the ticket doesn't have either columns "User list" or "User keywords"? Without any of those 2 set it is not possible for a use...
by luis
Thu Oct 26, 2017 10:43 am
Forum: Bug - problem reporting
Topic: System request to change password for running API
Replies: 2
Views: 549

Re: System request to change password for running API

On the password type there is a setting for password expiration.
Probably that is the case.
by luis
Thu Oct 26, 2017 10:37 am
Forum: Bug - problem reporting
Topic: [API] PasswordService->change not working
Replies: 1
Views: 478

Re: [API] PasswordService->change not working

The locator inside the user seems to be the problem. try to pass as user parameter just an object like {"principal": "username"}, not an object with a locator inside. Also, you don't need to fill in all those fields. Actually, if you set the user to just a string is should work as well, same for typ...
by luis
Tue Oct 24, 2017 7:48 am
Forum: Bug - problem reporting
Topic: Swagger json do not load on swagger editor online
Replies: 1
Views: 514

Re: Swagger json do not load on swagger editor online

For me the cyclos-swagger.json is too big to fit the swagger online editor. It hangs the browser. I suggest using the swagger online generator instead: https://generator.swagger.io/ It is itself a swagger frontend, where you should first POST to either /gen/clients/{framework} or /gen/servers/{frame...