GithubHelp home page GithubHelp logo

Comments (8)

emillod avatar emillod commented on September 25, 2024

@kboykov thanks. I'll adjust this extension to the newest version of EspoCRM :) I'll try to do this even today.

from ext-template-helper.

emillod avatar emillod commented on September 25, 2024

@kboykov fixed :)
https://github.com/dubas-pro/ext-template-helper/releases/tag/1.0.0

from ext-template-helper.

kboykov avatar kboykov commented on September 25, 2024

Thank you very much, Emilio. The word speller is a nice addition too!

from ext-template-helper.

kboykov avatar kboykov commented on September 25, 2024

Unfortunately it is still not working as it was working before...

Errors:
[2022-04-08 10:41:15] WARNING: E_WARNING: Undefined variable $field {"code":2,"message":"Undefined variable $field","file":"/home/xxxxxxxxxxxxxx/public_html/custom/Espo/Modules/DubasTemplateHelper/TemplateHelpers/DubasTranslateOption.php","line":48} [] [2022-04-08 10:41:15] ERROR: Uncaught Exception TypeError: "Espo\Core\Htmlizer\Helper\Result::createSafeString(): Argument #1 ($value) must be of type string, null given, called in /home/xxxxxxxxxxxxxx/public_html/custom/Espo/Modules/DubasTemplateHelper/TemplateHelpers/DubasTranslateOption.php on line 56" at /home/xxxxxxxxxxxxxx/public_html/application/Espo/Core/Htmlizer/Helper/Result.php line 38 {"exception":"[object] (TypeError(code: 0): Espo\\Core\\Htmlizer\\Helper\\Result::createSafeString(): Argument #1 ($value) must be of type string, null given, called in /home/xxxxxxxxxxxxxx/public_html/custom/Espo/Modules/DubasTemplateHelper/TemplateHelpers/DubasTranslateOption.php on line 56 at /home/xxxxxxxxxxxxxx/public_html/application/Espo/Core/Htmlizer/Helper/Result.php:38)"} []

It returns these errors in both cases...

  1. When trying to get an option value from a field from the current entity
  2. When trying to get an option value from a field from a related entity

Current entity is InsurancePolicy and the related entity is Account!
{{dubasTranslateOption scope='Account' field='legalentity' value='Company' language='en_US'}} - Not working (was working before)
{{dubasTranslateOption scope='InsurancePolicy' field='account.legalentity' value='Company' language='en_US'}} - not working
{{dubasTranslateOption scope='InsurancePolicy' field='status' value='Active' language='en_US'}} - not working (was working before)
{{dubasTranslateValue account.id scope='InsurancePolicy' field='account.industry' language='en_US'}} - not working
{{dubasTranslateValue accountId scope='InsurancePolicy' field='industry' language='en_US'}} - not working
{{dubasTranslateValue id scope='InsurancePolicy' field='status' language='en_US'}} - not working

from ext-template-helper.

emillod avatar emillod commented on September 25, 2024

I'll check this.

from ext-template-helper.

kboykov avatar kboykov commented on September 25, 2024

For some really odd reason these 2 have different behaviour:

PDF template for entity InsurancePolicy which has Many-to-One with Account.

{{dubasTranslateValue account.id scope='Account' field='legalentity' language='en_US'}}
{{dubasTranslateValue accountId scope='Account' field='industry' language='en_US'}}

In 0.0.3 version they are working and in 1.0.0 they are not, giving the errors I posted above.

from ext-template-helper.

kboykov avatar kboykov commented on September 25, 2024

Did you have time to debug this, Emilio?

from ext-template-helper.

emillod avatar emillod commented on September 25, 2024

@kboykov please check again
https://github.com/dubas-pro/ext-template-helper/releases/tag/1.0.1

from ext-template-helper.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.