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

Multi lingual entities #1754

Closed
SVronskiy opened this issue Sep 15, 2019 · 28 comments · Fixed by #5265
Closed

Multi lingual entities #1754

SVronskiy opened this issue Sep 15, 2019 · 28 comments · Fixed by #5265

Comments

@SVronskiy
Copy link

Hello!

Multi lingual entities were realized recently in ASP.NET Boilerplate Entites.

It supports IMultiLingualEntity, IEntityTranslation, Translations, MultiLingualMap, MultiLingual CRUD operation.

Please, realize, multi-lingual entities in Abp.Io Entites.

Regards, Sergey

@a-patel
Copy link

a-patel commented Jun 16, 2020

Any update on this?

@maliming
Copy link
Member

There are currently no plans to implement it, it is still backlog.

@yozzozo
Copy link

yozzozo commented Jun 28, 2020

+1 for this feature!

@tntwist
Copy link
Contributor

tntwist commented Aug 3, 2020

Hi there,

I would like to contribute to this feature, since I need this feature for my projects and I already have some of the Components(Generic MultiLinuaglEntity/AggregateRootTypes, a MultiLingualManager Service and the MultiLingualMap).

@maliming Would it be ok for you, if I work on it?

@maliming
Copy link
Member

maliming commented Aug 4, 2020

Hi @tntwist We always welcome contributions.

@tntwist
Copy link
Contributor

tntwist commented Aug 4, 2020

Great. I forked the repo and started the implementation. Just got the base types and interfaces today.

Everyone interested can track the progess here: tntwist/feat/multilingual-entities. Open for any kind of feedback and help.

@realLiangshiwei
Copy link
Member

@tntwist Hi, Are you still working on this? I will implement this feature, if you don't have time.

@tntwist
Copy link
Contributor

tntwist commented Aug 28, 2020

@tntwist Hi, Are you still working on this? I will implement this feature, if you don't have time.

@realLiangshiwei I was pretty busy the last two weeks and wont have time to work on it till mid of september. So you can implement it.

@realLiangshiwei realLiangshiwei self-assigned this Aug 31, 2020
@realLiangshiwei realLiangshiwei modified the milestones: backlog, 3.2 Sep 2, 2020
@hikalkan hikalkan modified the milestones: 3.2, 3.3 Sep 16, 2020
@hikalkan hikalkan modified the milestones: 3.3-preview, 4.0-preview Oct 10, 2020
@hikalkan hikalkan modified the milestones: 4.0-preview, 4.2-preview Oct 25, 2020
@kion-admin
Copy link

abp boilerplate was filter current language row in memory after get all rows from db, we'd better offer this as an option

@MooazHammam
Copy link

any updates regard this issue, is it planned to be released soon

@muratyuceer
Copy link
Contributor

we are waiting

@yozzozo
Copy link

yozzozo commented Apr 24, 2021

Hi @maliming, @realLiangshiwei and @hikalkan, just wondering what the current status of this feature is. This issue and #5265 are closed, but according to the latest Roadmap, it’s still on the backlog (as of 4.3 final). Can you please clarify?

Thanks!

@maliming
Copy link
Member

@yozzozo This feature has been canceled.

@yozzozo
Copy link

yozzozo commented Apr 25, 2021

@maliming May I ask why? I think this feature is very important for a lot of people (including myself). I see some commits were made for this, I’d like to understand what happened and offer assistance if I can.

Thanks!

@maliming
Copy link
Member

hi @yozzozo

Object mapping methods are sync now, but the feature needs to use Repository, we don't want async over sync.

@yozzozo
Copy link

yozzozo commented Apr 25, 2021

@hikalkan Any context you can provide here? Is there a way the feature can be redesigned so it can work in the current state of the system? I think many of us would appreciate being able to have multi-lingual entities on ABP, the feature was really useful on aspboilerplate.

@mtozlu
Copy link
Contributor

mtozlu commented Apr 26, 2021

I actually implemented this system in a private project.
I would like to share it however i am not sure it will be 100% compliant with abp's design guidelines. That's why i didn't create a PR until now.
How can i help about this @maliming / @hikalkan ?
Maybe you can check my codes and make some reviews to make it ready for abp codebase?

@maliming
Copy link
Member

@mtozlu

Did you encounter async over sync problems when you tried to use Repository?

@mtozlu
Copy link
Contributor

mtozlu commented Apr 26, 2021

@maliming
Copy link
Member

We don't want to use AsyncHelper.

@mtozlu
Copy link
Contributor

mtozlu commented Apr 26, 2021

Oh i remember now... I walked the same path. That's why I don't use any async call in GetTranslations method.
Actually the only async call needed is SettingProvider.GetOrNullAsync call, which is needed in case no translations can be found from CurrentCulture and CurrentCulture's parent cultures.
That's why I always use sync version GetTranslations method of MultiLingualObjectManager
I found two solutions (which you may not like as I mentioned in my comment about guidelines):
1- GetTranslations method should include a default culture property which you can get from SettingProvider before calling the method and pass.
2- Create a default language as a constant property and use it in GetTranslations method. (I use this. In case of changing the default language, a new deployment is needed which I never came across however in some scenarios, this may be unacceptable):
Here is that portion of my implementation:

// Can't make async calls, disable this:
//var defaultLanguage = await SettingProvider.GetOrNullAsync(LocalizationSettingNames.DefaultLanguage);
// Use this:
var defaultLanguage = PortalConsts.DefaultLanguage;

@muratyuceer
Copy link
Contributor

soo because of async willl you cancel it ?

@jfmeyers
Copy link

+1 for this feature!

@okains
Copy link

okains commented Jun 22, 2021

+1 for this feature also. I have been waiting on this implementation for a while now. Is there no workaround for the mapping issue? How about @mtozlu implementation?

hi @yozzozo

Object mapping methods are sync now, but the feature needs to use Repository, we don't want async over sync.

@ghost
Copy link

ghost commented Jun 25, 2021

+1 for this feature

@hitaspdotnet
Copy link
Contributor

My suggestion is using string DefaultLanguage property in MultiLingual class, or a solution around my issue with using a key value dictionary.
For who looking for a workaround for integrate multi lingual entities, I was shared a module
https://github.com/hitaspdotnet/Volo.Abp.MultiLingualObjects

@sel-carlitos
Copy link

+1 for this feature!

@abdullahsalem
Copy link

@yozzozo This feature has been canceled.

Do those PRs (#5265 & #8156) mean Multi-lingual entity feature will be shipped soon?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.