diff --git a/README.md b/README.md index c3c7679aa3..b588e0cba4 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ [![ABP Discord server](https://img.shields.io/discord/951497912645476422?label=Discord)](https://discord.gg/abp) -ABP Framework is a complete **infrastructure** based on the **ASP.NET Core** to create **modern web applications** and **APIs** by following the software development **best practices** and the **latest technologies**. Check out https://abp.io +ABP Framework is a complete **infrastructure** based on **ASP.NET Core** to create **modern web applications** and **APIs** by following the software development **best practices** and the **latest technologies**. Check out https://abp.io ## Getting Started @@ -49,7 +49,7 @@ ABP provides a **full stack developer experience**. -ABP offers a complete, **modular** and **layered** software architecture based on **[Domain Driven Design](https://docs.abp.io/en/abp/latest/Domain-Driven-Design)** principles and patterns. It also provides the necessary infrastructure and guiding to [implement this architecture](https://docs.abp.io/en/abp/latest/Domain-Driven-Design-Implementation-Guide). +ABP offers a complete, **modular** and **layered** software architecture based on **[Domain Driven Design](https://docs.abp.io/en/abp/latest/Domain-Driven-Design)** principles and patterns. It also provides the necessary infrastructure and guidance to [implement this architecture](https://docs.abp.io/en/abp/latest/Domain-Driven-Design-Implementation-Guide). ABP Framework is suitable for **[microservice solutions](https://docs.abp.io/en/abp/latest/Microservice-Architecture)** as well as monolithic applications. diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/en.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/en.json index 52d3d45039..783582d7be 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/en.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/en.json @@ -28,6 +28,7 @@ "Volo.AbpIo.Domain:030011": "You cannot delete a trial license when it is purchased!", "Volo.AbpIo.Domain:030012": "A user is entitled to have only 1 free trial period. You already used your trial license.", "Volo.AbpIo.Domain:030013": "A user with an active license cannot start a trial license.", + "Volo.AbpIo.Domain:040000": "Telemetry already exists!.", "Volo.AbpIo.Domain:070000": "The organization name can only contain latin letters, numbers, dots and hyphens!", "Volo.AbpIo.Domain:070001": "The company name can only contain latin letters, numbers, dots, space and hyphens!", "WantToLearn?": "Want to learn?", diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/tr.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/tr.json index dee01c8589..4275bb3771 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/tr.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Base/Localization/Resources/tr.json @@ -22,17 +22,13 @@ "Features": "Özellikler", "GetStarted": "Başlayın", "Documents": "Dokümanlar", - "Community": "Topluluk", "ContributionGuide": "Katkı Rehberi", "Blog": "Blog", - "Commercial": "Ticari", "MyAccount": "Hesabım", "Permission:License": "Lisans", "Permission:UserInfo": "kullanıcı bilgisi", "SeeDocuments": "Dokümanlara Göz Atın", - "Samples": "örnekler", - "Framework": "Çerçeve", - "Support": "Destek", + "Samples": "Örnekler", "FreeDDDBook": "Ücretsiz DDD Kitabı", "New": "Yeni", "Volo.AbpIo.Domain:020005": "Lisans uzatma yılı {MinExtendLicenseYear} yıldan az {MaxExtendLicenseYear} yıldan fazla olamaz.", @@ -96,7 +92,7 @@ "MySupportQuestions": "Destek Sorularım", "MyProfile": "Profilim", "Logout": "Çıkış Yap", - "Home": "Ev", + "Home": "Ana Sayfa", "Posts": "Gönderiler", "JoinTheABPCommunity": "ABP Topluluğuna Katılın", "SubmitYourPost": "Gönderinizi Gönderin", @@ -166,6 +162,12 @@ "ABPCommunityTalks": "ABP Topluluk Konuşmaları", "ABPCommunityPosts": "ABP Topluluk Gönderileri", "WelcomeFallCampaign": "Hoş Geldin Sonbahar Kampanyası!", - "GiveAwayForNewPurchases": "Yeni alımlar için Uygulama Geliştirme Sınıfı Eğitimi hediye edilecektir!" + "GiveAwayForNewPurchases": "Yeni alımlar için Uygulama Geliştirme Sınıfı Eğitimi hediye edilecektir!", + "ExploreTheContentsCreatedByTheCoreABPTeamAndTheABPCommunity": "ABP ekibi ve ABP topluluğu tarafından oluşturulan içerikleri keşfedin.", + "CheckAllCommunityTalks": "Tüm Topluluk Gönderilerine Göz Atın", + "ExploreTheBook": "Kitabı Keşfedin", + "ExploreTheEBook": "E-Kitabı Keşfedin", + "LatestVideos": "Son Videolar", + "Videos": "Videolar" } } \ No newline at end of file diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/ar.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/ar.json index fff3b72a1d..938f3f9525 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/ar.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/ar.json @@ -515,6 +515,7 @@ "Pricing_Page_Testimonial_3": "نحن نحب ABP. ليس علينا كتابة كل شيء من الصفر. نبدأ من الميزات الجاهزة ونركز فقط على ما نحتاج حقًا إلى كتابته. أيضًا ، ABP مصمم جيدًا والشفرة عالية الجودة مع عدد أقل من الأخطاء. إذا كان علينا كتابة كل ما نحتاجه بمفردنا ، فقد نضطر إلى قضاء سنوات. مرة أخرى نحب أن الإصدار الجديد ، أو إصلاح المشكلة ، أو التحسين يأتي قريبًا جدًا كل أسبوعين. نحن لا ننتظر طويلا.", "Pricing_Page_Testimonial_4": "ABP التجاري منتج رائع يوصى به. تسويق المنتجات التجارية لعملائنا في منصة واحدة قابلة للتكوين. البداية السريعة التي يوفرها إطار العمل والأدوات لأي فريق تستحق كل سنت. كانت ABP هي الأنسب لاحتياجاتنا.", "Pricing_Page_Testimonial_5": "إطار عمل ABP ليس مجرد إطار عمل ، ولكنه أيضًا دليل لتطوير / إدارة المشروع ، لأنه يوفر تدريب DDD و GenericRepository و DI و Microservice و Modularity. حتى إذا كنت لن تستخدم الإطار نفسه ، يمكنك تطوير نفسك باستخدام docs.abp.io المُعد جيدًا ومهنيًا (OpenIdict و Redis و Quartz وما إلى ذلك). نظرًا لأن العديد من الأشياء مبنية مسبقًا ، فإنها تقصر وقت تطوير المشروع بشكل كبير (مثل صفحة تسجيل الدخول ، ومعالجة الاستثناءات ، وتصفية البيانات ، والبذر ، وتسجيل التدقيق ، والترجمة ، ووحدة التحكم في واجهة برمجة التطبيقات التلقائية ، وما إلى ذلك). كمثال من تطبيقنا ، لقد استخدمت Local Event Bus للتحكم في المخزون. لذلك ، أنا قادر على إدارة حركات الأوامر عن طريق كتابة معالج الأسهم. إنه لأمر رائع ألا تضيع الوقت من أجل CreationTime ، CreatorId. يتم ملؤها تلقائيًا.", + "Pricing_Page_Testimonial_6": "إطار عمل ABP هو إطار عمل جيد ولكنه يحتاج إلى وقت لفهم الطبقات والفئات والمكتبات المختلفة التي يستخدمها (خاصة ABP). قضيت الكثير من الوقت في قراءة قاعدة الكود ، لكن ABP Commercial توفر لنا الوقت لإنشاء كيانات تخصص المشروع (AR) والمستودع المرتبط بكل منها. أعجبني أيضًا أن النهج المستخدم في ABP ناضج جدًا ، ونعلم أنه يعتمد على DDD و monolith.", "AbpBookDownloadArea_ClaimYourEBook": "احصل على كتاب إتقان إطار عمل ABP الالكتروني الخاص بك", "AddMemberModal_Warning_1": "اذا كان المستخدم الذي تحاول اضافته لا يوجد في النظام, يرجى مطالبة عضو فريقك بالتسجيل في {0} ومشاركة اسم المستخدم الخاص بحسابه معك.", "MyOrganizations_Detail_WelcomeMessage": "مرحبًا بك في مؤسستك، {0}", diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/en.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/en.json index d4b399668a..5044199698 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/en.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/en.json @@ -537,6 +537,7 @@ "Pricing_Page_Testimonial_3": "We love ABP. We don't have to write everything from scratch. We start from out-of-the-box features and just focus on what we really need to write. Also, ABP is well-architected and the code is high quality with fewer bugs. If we would have to write everything we needed on our own, we might have to spend years. Once more things we like is that the new version, or issue fixing, or improvement come out very soon every other week. We don't wait too long.", "Pricing_Page_Testimonial_4": "ABP Commercial is a fantastic product would recommend. Commercial products to market for our customers in a single configurable platform. The jump start that the framework and tooling provide any team is worth every cent. ABP Commercial was the best fit for our needs.", "Pricing_Page_Testimonial_5": "ABP Framework is not only a framework, but it is also a guide for project development/management, because it provides DDD, GenericRepository, DI, Microservice, and Modularity training. Even if you are not going to use the framework itself, you can develop yourself with docs.abp.io which is well and professionally prepared (OpenIddict, Redis, Quartz etc.). Because many things are pre-built, it shortens project development time significantly (Such as login page, exception handling, data filtering, seeding, audit logging, localization, auto API controller etc.). As an example from our application, I have used Local Event Bus for stock control. So, I am able to manage order movements by writing stock handler. It is wonderful not to lose time for CreationTime, CreatorId. They are being filled automatically.", + "Pricing_Page_Testimonial_6": "ABP Framework is a good framework but it needs time to understand the different layers, classes, and libraries it used (specially ABP). I spent a lot of time reading the code base, but ABP Commercial save us time to create the project specialty entities (AR) and the repository linked to each of them. I liked also the approach used in ABP is very mature, we know is based on DDD and monolith.", "AbpBookDownloadArea_ClaimYourEBook": "Claim your Mastering ABP Framework E-Book", "AddMemberModal_Warning_1": "If the username you are trying to add doesn't exist in the system, please ask your team member to register on {0} and share the username of his/her account with you.", "MyOrganizations_Detail_WelcomeMessage": "Welcome to your organization, {0}", @@ -759,6 +760,7 @@ "ViewLiveDemo": "View Live Theme Demo", "GetLeptonX": "Get LeptonX Now", "SeeLeptonXDocumentation": "See LeptonX Documentation", + "SeeLeptonDocumentation": "See Lepton Documentation", "SimplifiedMenu": "Simplified menu", "SimplifiedMenuDescription": "You can easily find the page you are looking for by filtering the menu", "YourFavoritePages": "Your favorite pages at your reach", @@ -825,6 +827,8 @@ "PrivacyPolicyPageTitle": "Privacy Policy - Cookie Policy", "TermsConditionsPageTitle": "Terms and Conditions", "TrainingsPageTitle": "ABP Training Packages", - "ModulesPageTitle": "ABP Pre-Built Application Modules" + "ModulesPageTitle": "ABP Pre-Built Application Modules", + "Volo.AbpIo.Commercial:040001": "API Access Key is incorrect.", + "GetLepton": "Get Lepton Now" } } diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/fi.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/fi.json index dc3c374d78..bc8bd81c8f 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/fi.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/fi.json @@ -537,6 +537,7 @@ "Pricing_Page_Testimonial_3": "Rakastamme ABP:tä. Meidän ei tarvitse kirjoittaa kaikkea tyhjästä. Aloitamme valmiista ominaisuuksista ja keskitymme vain siihen, mitä todella tarvitsemme kirjoittaa. Lisäksi ABP on hyvin suunniteltu ja koodi on korkealaatuista ja siinä on vähemmän bugeja. Jos joutuisimme kirjoittamaan kaiken tarvitsemamme itse, joudumme ehkä viettämään vuosia. Jälleen kerran pidämme siitä, että uusi versio, ongelmankorjaus tai parannus ilmestyy hyvin pian joka toinen viikko. Emme odota liian kauan.", "Pricing_Page_Testimonial_4": "ABP Commercial on loistava tuote, jota suosittelen. Kaupalliset tuotteet markkinoille asiakkaillemme yhdellä konfiguroitavalla alustalla. Kehyksen ja työkalujen tarjoama aloitus jokaiselle joukkueelle on jokaisen sentin arvoinen. ABP Commercial sopi parhaiten tarpeisiimme.", "Pricing_Page_Testimonial_5": "ABP Framework ei ole vain viitekehys, vaan se on myös opas projektin kehittämiseen/hallintaan, koska se tarjoaa DDD-, GenericRepository-, DI-, Microservice- ja Modularity-koulutusta. Vaikka et itse käyttäisikään kehystä, voit kehittää itseäsi docs.abp.io:lla, joka on hyvin ja ammattimaisesti valmisteltu (OpenIddict, Redis, Quartz jne.). Koska monet asiat on rakennettu valmiiksi, se lyhentää projektin kehitysaikaa merkittävästi (kuten kirjautumissivu, poikkeusten käsittely, tietojen suodatus, kylvö, tarkastusloki, lokalisointi, automaattinen API-ohjain jne.). Esimerkkinä sovelluksestamme olen käyttänyt paikallista tapahtumaväylää varastonhallintaan. Pystyn siis hallitsemaan tilausliikkeitä kirjoittamalla varastokäsittelijäksi. On hienoa olla hukkaamatta aikaa CreationTimelle, CreatorId:lle. Ne täytetään automaattisesti.", + "Pricing_Page_Testimonial_6": "ABP Framework on hyvä kehys, mutta sen käyttämien eri kerrosten, luokkien ja kirjastojen (erityisesti ABP:n) ymmärtäminen vaatii aikaa. Käytin paljon aikaa koodikannan lukemiseen, mutta ABP Commercial säästää aikaa projektin erityiskokonaisuuksien (AR) ja kuhunkin niistä linkitetyn arkiston luomiseen. Pidin myös ABP:ssä käytetystä lähestymistavasta, joka on hyvin kypsä, sillä se perustuu DDD:hen ja monoliittisuuteen.", "AbpBookDownloadArea_ClaimYourEBook": "Lunasta Mastering ABP Framework -e-kirja", "AddMemberModal_Warning_1": "Jos käyttäjätunnusta, jota yrität lisätä, ei ole järjestelmässä, pyydä tiimisi jäsentä rekisteröitymään osoitteessa {0} ja jakaa hänen tilinsä käyttäjätunnus kanssasi.", "MyOrganizations_Detail_WelcomeMessage": "Tervetuloa organisaatioosi, {0}", diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/hu.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/hu.json index b481c362e6..9df49a3b0a 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/hu.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/hu.json @@ -538,6 +538,7 @@ "Pricing_Page_Testimonial_3": "Szeretjük az ABP-t. Nem kell mindent a nulláról írnunk. A beépített funkciókból indulunk ki, és csak arra koncentrálunk, amit valóban meg kell írnunk. Ezenkívül az ABP jól felépített, és a kód kiváló minőségű, kevesebb hibával. Ha magunknak kellene megírnunk mindent, amire szükségünk van, akkor lehet, hogy éveket kellene töltenünk. Még egyszer, amit szeretünk, az az, hogy az új verzió, a hibajavítás vagy a fejlesztés nagyon hamar, minden második héten megjelenik. Nem várunk túl sokáig.", "Pricing_Page_Testimonial_4": "Az ABP Commercial egy fantasztikus termék, amelyet ajánlunk. Kereskedelmi termékek, amelyeket ügyfeleink számára egyetlen konfigurálható platformon értékesíthetnek. Az ugrásszerű indítás, amelyet a keret és az eszközök biztosítanak bármely csapat számára, minden centet megér. Az ABP Commercial volt a legjobban megfelelő az igényeinknek.", "Pricing_Page_Testimonial_5": "Az ABP Framework nem csak keretrendszer, hanem útmutató is a projektfejlesztéshez/menedzsmenthez, mert DDD, GenericRepository, DI, Microservice és Modularity képzést biztosít. Ha magát a keretrendszert nem is használja, fejlesztheti magát a docs.abp.io-val, amely jól és professzionálisan elkészített (OpenIddict, Redis, Quartz stb.) leírás. Mivel sok minden előre be van építve, jelentősen lerövidíti a projektfejlesztési időt (például bejelentkezési oldal, kivételkezelés, adatszűrés, aéapadatok, audit naplózás, lokalizáció, automatikus API vezérlő stb.). Alkalmazásunkból példaként a Helyi Event Bus-t használtam az állomány karbantartására. Így a rendelési mozgásokat eseményekkel tudom a készlethez igazítani. Csodálatos, hogy nem veszítünk időt a CreationTime-ra, a CreatorId-re. Automatikusan feltöltődnek.", + "Pricing_Page_Testimonial_6": "Az ABP Framework egy jó keretrendszer, de időre van szükség a különböző rétegek, osztályok és könyvtárak (különösen az ABP) megértéséhez. Sok időt töltöttem a kódbázis elolvasásával, de az ABP Commercial időt takarít meg nekünk a projekt speciális entitások (AR) és a mindegyikhez kapcsolódó tároló létrehozására. Tetszett az ABP-ben használt megközelítés is nagyon érett, tudjuk, hogy a DDD-n és a monoliton alapul.", "AbpBookDownloadArea_ClaimYourEBook": "Igényelje Mastering ABP Framework e-könyvét", "AddMemberModal_Warning_1": "Ha a hozzáadni kívánt felhasználónév nem létezik a rendszerben, kérje meg csapattagját, hogy regisztráljon a (z) {0} webhelyen, és ossza meg fiókja felhasználónevét Önnel.", "MyOrganizations_Detail_WelcomeMessage": "Üdvözöljük szervezetében, {0}", diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/tr.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/tr.json index c40b46f3c1..96375db1f6 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/tr.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/tr.json @@ -95,7 +95,7 @@ "LanguageManagement": "Dil Yönetimi", "TextTemplateManagement": "Metin Şablonu Yönetimi", "See All Modules": "SeeAllModüller", - "ABPSuite": "ABP Süiti", + "ABPSuite": "ABP Suite", "AbpSuiteShortDescription": "ABP Suite, ABP Commercial için tamamlayıcı bir araçtır.", "AbpSuiteExplanation": "Birkaç dakika içinde web sayfaları oluşturmanıza olanak tanır. Komut satırından yüklenebilen bir .NET Core Global aracıdır. Yeni bir ABP çözümü oluşturabilir, veritabanından ön uca kadar CRUD sayfaları oluşturabilir.", "Details": "Detaylar", @@ -417,7 +417,6 @@ "RenewLicenseEarly": "Lisansımı erken yenilersem, tüm yılı alacak mıyım?", "RenewLicenseEarylExplanation": "Lisansınızı lisans bitiş tarihinizden önce yenilediğinizde, lisans bitiş tarihinize 1 yıl eklenecektir. Örneğin, lisansınızın süresi {0}-06-06 tarihinde doluyorsa ve lisansınızı {0}-01-01 tarihinde yenilediyseniz, yeni lisans bitiş tarihiniz {1}-06-06 olacaktır.", "OpenSourceWebApplication": "Açık Kaynak Web Uygulaması", - "CompleteWebDevelopment": "Tam Web Geliştirme", "ABPFrameworkDescription": "ABP Framework, yazılım geliştirme ve sözleşmelerin en iyi uygulamalarını takip ederek modern web uygulamaları oluşturmak için eksiksiz bir altyapıdır.", "CommunityDescription": "ABP Çerçevesi ile ilgili deneyimlerinizi paylaşın!", "GetStarted": "Başlayın", @@ -548,6 +547,7 @@ "Pricing_Page_Testimonial_3": "ABP'yi seviyoruz. Her şeyi sıfırdan yazmak zorunda kalmıyoruz. Kullanıma hazır özelliklerden başlıyoruz ve sadece gerçekten yazmamız gerekenlere odaklanıyoruz. Ayrıca, ABP iyi tasarlanmış ve kod daha az hata ile yüksek kalitede. İhtiyaç duyduğumuz her şeyi kendi başımıza yazmak zorunda kalsaydık, yıllarımızı harcamak zorunda kalabilirdik. Hoşumuza giden bir diğer şey de yeni sürümün, sorun düzeltmenin ya da iyileştirmenin iki haftada bir çıkması. Çok uzun süre beklemiyoruz.", "Pricing_Page_Testimonial_4": "ABP Commercial harika bir ürün, tavsiye ederim. Müşterilerimiz için ticari ürünleri tek bir yapılandırılabilir platformda pazara sunuyor. Çerçeve ve araçların herhangi bir ekibe sağladığı hızlı başlangıç her kuruşa değer. ABP Commercial ihtiyaçlarımız için en uygun üründü.", "Pricing_Page_Testimonial_5": "ABP Framework sadece bir framework değil, aynı zamanda bir proje geliştirme/yönetme rehberi, çünkü DDD, GenericRepository, DI, Microservice ve Modularity eğitimleri veriyor. Framework'ün kendisini kullanmayacak olsanız bile, iyi ve profesyonelce hazırlanmış docs.abp.io ile kendinizi geliştirebilirsiniz (OpenIddict, Redis, Quartz vb.). Birçok şey önceden hazır olduğu için proje geliştirme süresini önemli ölçüde kısaltıyor (Giriş sayfası, istisna işleme, veri filtreleme, tohumlama, denetim günlüğü, yerelleştirme, otomatik API denetleyicisi vb.) Uygulamamızdan bir örnek olarak, stok kontrolü için Local Event Bus kullandım. Böylece stok işleyicisi yazarak sipariş hareketlerini yönetebiliyorum. CreationTime, CreatorId için zaman kaybetmemek harika. Bunlar otomatik olarak dolduruluyor.", + "Pricing_Page_Testimonial_6": "ABP Framework iyi bir çerçeve ancak kullandığı farklı katmanları, sınıfları ve kütüphaneleri (özellikle ABP) anlamak için zaman gerekiyor. Kod tabanını okumak için çok zaman harcadım, ancak ABP Commercial, proje özel varlıklarını (AR) ve her birine bağlı depoyu oluşturmak için bize zaman kazandırdı. ABP'de kullanılan yaklaşımın çok olgun olduğunu da beğendim, DDD ve monolith'e dayandığını biliyoruz.", "AbpBookDownloadArea_ClaimYourEBook": "Mastering ABP Framework E-Kitabınızı talep edin", "AddMemberModal_Warning_1": "Eklemeye çalıştığınız kullanıcı adı sistemde yoksa, lütfen ekip üyenizden {0} adresine kaydolmasını ve hesabının kullanıcı adını sizinle paylaşmasını isteyin.", "MyOrganizations_Detail_WelcomeMessage": "Organizasyonunuza hoş geldiniz, {0}", @@ -744,12 +744,67 @@ "ConfirmedEmailAddressRequiredToStartTrial": "Deneme lisansı başlatmak için onaylanmış bir e -posta adresiniz olmalı.", "EmailVerificationMailNotSent": "E-posta doğrulama postası gönderilemedi.", "GetConfirmationEmail": "Daha önce bir onay e-postası almadıysanız almak için buraya tıklayın.", - "WhichLicenseTypeYouAreInterestedIn": "Hangi lisans türüyle ilgileniyorsunuz?", + "WhichLicenseTypeYouAreInterestedIn": "Hangi lisans türüyle ilgileniyorsunuz?", "BlackFridayDiscount": "Kara Cuma İndirimi", "EulaPageTitle": "Son Kullanıcı Lisans Sözleşmesi (EULA)", "PrivacyPolicyPageTitle": "Gizlilik Politikası - Çerez Politikası", "TermsConditionsPageTitle": "Şartlar ve Koşullar", "TrainingsPageTitle": "ABP Eğitim Paketleri", - "ModulesPageTitle": "ABP Önceden Oluşturulmuş Uygulama Modülleri" + "ModulesPageTitle": "ABP Hazır Uygulama Modülleri", + "Testimonial_ShortDescription_1": "ABP'nin modülerliği, ekibin zamanında teslimat yapmasını mümkün kıldı.", + "Testimonial_ShortDescription_2": "Yeni özellikleri eskisinden daha hızlı oluşturun.", + "Testimonial_ShortDescription_3": "Kullanıma hazır özelliklerden başlıyoruz ve sadece yazmamız gerekenlere odaklanıyoruz.", + "Testimonial_ShortDescription_4": "ABP Commercial ihtiyaçlarımız için en uygun olanıydı.", + "DontTakeOurWordForIt": "Bizim sözümüze güvenmeyin...", + "ReadAbpCommercialUsersWantYouToKnow": "ABP Commercial kullanıcılarının bilmenizi istediklerini okuyun.", + "OnlineReviewersOnAbpCommercial": "ABP Commercial Hakkında Çevrimiçi Yorumlar", + "SeeWhatToldAboutAbpCommercial": "ABP Commercial hakkında neler söylendiğini görün ve isterseniz düşüncelerinizi yazın.", + "YouDeserveGoodUXUI": "İyi bir kullanıcı arayüzünü ve daha iyi bir kullanıcı deneyimini hak ediyorsunuz. ABP'nin LeptonX Teması size hizmet etmek için burada.", + "ViewLiveDemo": "Canlı Tema Demosunu Görüntüle", + "LeptonXThemeForDashboard": "Yönetici Kontrol Paneliniz için LeptonX Teması", + "GetLeptonX": "LeptonX'i Şimdi Alın", + "SimplifiedMenu": "Basitleştirilmiş menü", + "SimplifiedMenuDescription": "Menüyü filtreleyerek aradığınız sayfayı kolayca bulabilirsiniz", + "YourFavoritePages": "Favori sayfalarınız elinizin altında", + "YourFavoritePagesDescription": "Sayfanın sağ üst köşesindeki yıldız simgesine tıklayarak sayfayı kolayca favorilere ekleyin veya favorilerden kaldırın.", + "BreadCrumbs": "Kesintisiz geçiş için Breadcrumb", + "BreadCrumbsDescription": "Breadcrumb'ı kullanarak, sol menü kapalıyken bile tek tıklamayla aynı seviyedeki sayfalara geçebilirsiniz, üstelik tablet ve mobil uyumlu çalışır!", + "YourMenu": "Menünüz dilediğiniz gibi", + "YourMenuDescription": "Kullanıcı menüsündeki doğrudan tıklanabilir simgeleri ve açılır kutuları istediğiniz gibi özelleştirin. Kullanıcı menüsü ihtiyaçlarınıza göre tamamen özelleştirilebilir", + "RtlSupport": "Diliniz için RTL desteği", + "RtlSupportDescription": "LeptonX Teması, diliniz için RTL'yi destekler. Dili değiştirmeniz için dil seçenekleri ayarlar menüsündedir.", + "YourColors": "Yönetici kontrol paneli kullanıcı arayüzünüzdeki renkleriniz", + "YourColorsDescription": "LeptonX Tema, sistem tercihlerinize göre çalışır ve gösterge paneli açık tema, gösterge paneli koyu tema ve gösterge paneli yarı koyu tema seçeneklerine sahiptir.", + "ArrangeContentWidth": "İçerik genişliğinizi kolayca düzenleyin", + "ArrangeContentWidthDescription": "İçerik alanınızın genişliğini kolayca değiştirin.", + "LeptonXCompatibleWith": "LeptonX Teması aşağıdakilerle uyumludur", + "MobileResponsiveTemplate": "Mobil Uyumlu Şablon", + "MobileResponsiveTemplateDescription1": "LeptonX yönetici kontrol panelinize istediğiniz cihazdan erişin.", + "MobileResponsiveTemplateDescription2": "Her cihazınızda rahatlıkla kullanabilmeniz için tasarlanmıştır. Mobil cihazlara ve tablet boyutlarına duyarlıdır.", + "TopMenuLayoutOption": "Üst Menü Düzeni Seçeneği", + "TopMenuLayoutOptionDescription1": "Web sitenizi aynı yönetici kontrol paneliyle kurmak istiyorsanız, LeptonX Teması ile bunu yapmanız mümkün!", + "TopMenuLayoutOptionDescription2": "Bunu gerçekleştirmek için LeptonX üst menü düzenini deneyin!", + "EasilyCustomizable": "Marka renkleriniz için kolayca özelleştirilebilir", + "EasilyCustomizableDescription1": "LeptonX temasını sadece birkaç SCSS değişkeni kullanarak özelleştirebilirsiniz. Geçersiz kılma yok, ekstra CSS yükü yok!", + "EasilyCustomizableDescription2": "LeptonX ile yönetici panelinizi istediğiniz gibi düzenleyebilirsiniz.", + "IndependentLayout": "Bağımsız düzen ve içerik alanı", + "IndependentLayoutDescription1": "LeptonX'in yerleşim altyapısı içerikten tamamen ayrı olarak tasarlandı.", + "IndependentLayoutDescription2": "Bu, isterseniz projenizi Bootstrap dışında bir içerik yapısı ile özgürce tasarlayabileceğiniz anlamına gelir.", + "MostUsedLibraries": "LeptonX ile entegre edilmiş en çok kullanılan kütüphaneler", + "MostUsedLibrariesDescription1": "LeptonX en çok kullandığınız kütüphaneleri içerir. ApexCharts, DataTables, DropZone, FullCalender, JSTree, Select2, Toastr gibi kütüphaneleri zahmetsizce kullanmanızı sağlar.", + "MostUsedLibrariesDescription2": "LeptonX ayrıca MVC Angular ve Blazor'a özgü kütüphaneleri de destekler.", + "CreateAndCustomize": "LeptonX özel sayfaları ile ihtiyacınız olan sayfaları saniyeler içinde oluşturun ve özelleştirin", + "CreateAndCustomizeDescription": "LeptonX Temasını kullanarak önceden hazırlanmış birçok html sayfasına da erişebilirsiniz. Bunlar arasında giriş sayfası, blog, SSS, abonelik listesi, fatura, fiyatlandırma, dosya yönetimi gibi birçok sayfa bulunmaktadır.", + "LeptonThemeForAdmin": "Yönetici kontrol paneliniz için Lepton Teması", + "LeptonThemeForAdminDescription": "Lepton Teması hala kullanılabilir durumdadır ve bakımı yapılacaktır. Bir Lepton Teması kullanıcısı olarak LeptonX Temasına geçmek istiyorsanız, nasıl yapılacağını öğrenmek için belgelere bakabilirsiniz.", + "LeptonCompatibleWith": "Lepton Teması aşağıdakilerle uyumludur", + "SeeLeptonDocumentation": "Lepton Dokümantasyonuna Bakın", + "GetLepton": "Lepton'u Şimdi Alın", + "WhyUseAbpIoPlatform": "Sıfırdan yeni bir çözüm oluşturmak yerine neden ABP.IO Platformunu kullanmalıyım?", + "WhyUseAbpIoPlatformFaqExplanation": "ABP.IO Platformunu kullanmanın her şeyi kendiniz yapmaya göre neden önemli bir avantaja sahip olduğuna dair ayrıntılı bir açıklama için bu belgeye bakın.", + "SupportPolicyFaqTitle": "Destek politikanız nedir?", + "SupportPolicyFaqExplanation": "Yalnızca etkin ve önceki ana sürümü destekliyoruz. Üçüncü ve daha eski ana sürümler için bir yama sürümünü garanti etmiyoruz. Örneğin, etkin sürüm 7.0.0 ise, hem 6.x.x hem de 7.x.x için yama sürümleri yayınlayacağız. Ayrıca, yalnızca ABP Framework ve ABP Commercial ile ilgili sorunlar için destek sağlıyoruz. Bu, ABP ürünleri tarafından kullanılan 3. taraf uygulamalar, bulut hizmetleri ve diğer çevresel kütüphaneler için destek verilmediği anlamına gelir. Müşterilerimize \"Volosoft Bilişim A.Ş\"nin resmi çalışma saatleri içinde teknik destek sağlamak için ticari olarak makul çabayı göstereceğiz. Öte yandan, bir hizmet seviyesi anlaşması (SLA) yanıt süresi taahhüt etmiyoruz, ancak teknik sorunlara resmi çalışma saatlerimiz içinde mümkün olduğunca çabuk yanıt vermeye çalışacağız. Müşteri ile özel bir anlaşma yapılmadığı sürece, yalnızca https://support.abp.io adresinden destek sağlıyoruz. Ayrıca, yalnızca Kurumsal Lisans sahiplerinin kullanabildiği özel e-posta desteğimiz de bulunmaktadır.", + "BlazoriseLicense": "Blazorise lisansı satın almamız gerekiyor mu?", + "BlazoriseLicenseExplanation": "Volosoft ve Megabit arasında bir anlaşmamız var, bu anlaşma ile Blazorise lisansı ABP Ticari ürünleri ile birlikte geliyor, bu nedenle müşterilerimizin ekstra bir Blazorise lisansı satın almasına gerek kalmıyor." } } \ No newline at end of file diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/zh-Hans.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/zh-Hans.json index 06e0c6ca9e..d78d8469f8 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/zh-Hans.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Commercial/Localization/Resources/zh-Hans.json @@ -537,6 +537,7 @@ "Pricing_Page_Testimonial_3": "我们大爱 ABP。 我们不必从头开始编写所有内容。 我们从\"开箱即用\"的功能开始,只需关注我们真正需要编写的内容。 此外,ABP 架构良好,代码质量高,错误少。 如果我们需要自己来编写所需的一切,我们可能需要花费数年时间。 另一点让我们喜欢的是新版本、问题修复或改进每隔一周很快地就会出现。 我们不会等太久。", "Pricing_Page_Testimonial_4": "ABP 商业版 是一款很值得推荐的出色产品。 是在一个可配置的平台上为我们的客户推向市场的商业产品。 其框架和工具为任何团队提供的快速启动值得每一分钱。 ABP 商业版 最适合我们的需求。", "Pricing_Page_Testimonial_5": "ABP Framework 不仅是一个框架,它还是项目开发/管理的指南,因为它提供了 DDD、GenericRepository、DI、微服务和模块化培训。 即使你不打算使用框架本身,你也可以通过 docs.abp.io 进行自己的开发,该文档已经做好了专业的准备(OpenIddict、Redis、Quartz 等)。 因为很多东西都是预先构建的,它大大缩短了项目开发时间(例如登录页面、异常处理、数据过滤、种子、审计日志、本地化、自动 API 控制器等)。 作为我们应用程序的一个示例,我使用本地事件总线进行库存控制。 因此我可以通过编写库存处理程序来管理订单移动。 不为 CreationTime,CreatorId 浪费时间真是太好了。 它们正在自动填充。", + "Pricing_Page_Testimonial_6": "ABP Framework 是一个很好的框架,但它需要时间来理解它使用的不同层、类和库(特别是 ABP)。 我花了很多时间阅读代码库,但是 ABP Commercial 为我们节省了创建项目专业实体 (AR) 和链接到每个实体的存储库的时间。 我也喜欢 ABP 中使用的方法非常成熟,我们知道它基于 DDD 和单体。", "AbpBookDownloadArea_ClaimYourEBook": "领取您的掌握ABP框架电子书", "AddMemberModal_Warning_1": "如果您尝试添加的用户名在系统中不存在,请让您的团队成员在 {0} 并与您分享他/她帐户的用户名。", "MyOrganizations_Detail_WelcomeMessage": "欢迎加入您的组织,{0}", diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/tr.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/tr.json index 81c659c500..2d52d01ed2 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/tr.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Community/Localization/Resources/tr.json @@ -93,7 +93,6 @@ "NoThanks": "Hayır teşekkürler", "MaybeLater": "Belki sonra", "JoinOurPostNewsletter": "Makale bültenimize katılın", - "Community": "Toplum", "Marketing": "Pazarlama", "CommunityPrivacyPolicyConfirmation": "Şartlar ve Koşullar ile Gizlilik Politikası'nı kabul ediyorum.", "PostRequestMessageTitle": "Bu web sitesinde görmek istediğiniz bir makaleyi/eğiticiyi istemek için GitHub'da bir sorun açın.", @@ -143,7 +142,6 @@ "Volo.AbpIo.Domain:060002": "Makale İçeriği Github(\"{PostUrl}\") kaynağında mevcut değil.", "Volo.AbpIo.Domain:060003": "Makale içeriği bulunamadı!", "MemberNotPublishedPostYet": "Bu üye henüz bir gönderi yayınlamadı.", - "WelcomeToABP": "ABP'ye Hoşgeldiniz", "Browse": "Göz at", "ArticleRequestsDescription": "Burada belirli bir içerik mi görmek istiyorsunuz? Topluluktan bunu oluşturmasını isteyebilirsiniz!", "LatestContentRequests": "Son İçerik Talepleri", diff --git a/abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/tr.json b/abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/tr.json index 6834f5da0d..dcc04e9f79 100644 --- a/abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/tr.json +++ b/abp_io/AbpIoLocalization/AbpIoLocalization/Www/Localization/Resources/tr.json @@ -1,7 +1,7 @@ { "culture": "tr", "texts": { - "GetStarted": "Başlamak - Başlangıç Templateleri", + "GetStarted": "Başlangıç Şablonları", "Create": "Oluştur", "NewProject": "Yeni Proje", "DirectDownload": "Doğrudan İndir", @@ -82,7 +82,7 @@ "CLI_CommandLineInterface": "CLI (Command Line Interface)", "CLI_CommandLineInterfaceExplanation": "CLI yeni proje oluşturma ve uygulamanıza modüller ekleme işlemlerini otomatik hale getirir.", "StartupTemplates": "Başlangıç Templateler", - "StartupTemplatesExplanation": "Çeşitli başlangıç templateleri size geliştirme başlatmak için tam yapılandırılmış bir çözüm sağlar.", + "StartupTemplatesExplanation": "Çeşitli başlangıç şablonları size geliştirme başlatmak için tam yapılandırılmış bir çözüm sağlar.", "BasedOnFamiliarTools": "Bilinen Araçlara Dayalı ", "BasedOnFamiliarToolsExplanation": "Zaten bildiğiniz popüler araçlar ile geliştirilme ve egtegre edilmiştir. Düşük öğrenme eğrisi, koaly adaptasyon, rahat geliştirme.", "ORMIndependent": "ORM Bağımsız", @@ -139,8 +139,8 @@ "AggregateRootEntity": "Aggregate Root, Entity", "AutoRESTAPIsExplanation": "ABP, application servislerinizi otomatik olarak API Controller olarak kurallı bir şekilde yapılandırabilir.", "DynamicClientProxiesExplanation": "Apilerinizi, JavaScript ve C# clients tarafından kolaylıkla kullanın.", - "DistributedEventBusWithRabbitMQIntegrationExplanation": "Easily publish & consume distributed events using built-in Distributed Event Bus with RabbitMQ integration available.", - "TestInfrastructureExplanation": "The framework has been developed unit & integration testing in mind. Provides you base classes to make it easier. Startup templates come with pre-configured for testing.", + "DistributedEventBusWithRabbitMQIntegrationExplanation": "RabbitMQ entegrasyonu ile yerleşik Dağıtılmış Event Bus kullanarak dağıtılmış olayları kolayca yayınlayın ve tüketin.", + "TestInfrastructureExplanation": "Çerçeve, birim ve entegrasyon testleri göz önünde bulundurularak geliştirilmiştir. İşinizi kolaylaştırmak için size temel sınıflar sağlar. Başlangıç şablonları test için önceden yapılandırılmış olarak gelir.", "AuditLoggingEntityHistoriesExplanation": "İş açısından kritik uygulamalar için yerleşik denetim günlüğü. Özellik düzeyinde ayrıntılarla istek, hizmet, yöntem düzeyinde denetim günlüğü ve varlık geçmişleri.", "EmailSMSAbstractionsWithTemplatingSupportExplanation": "IEmailSender ve ISmsSender soyutlamaları, uygulama mantığınızı altyapıdan ayırır. Gelişmiş e-posta şablon sistemi, e-posta şablonları oluşturmanıza ve yerelleştirmenize ve gerektiğinde kolayca kullanmanıza olanak tanır.", "LocalizationExplanation": "Yerelleştirme sistemi, düz JSON dosyalarında kaynaklar oluşturmanıza ve bunları UI'nizi yerelleştirmek için kullanmanıza olanak tanır. AspNet Core'un yerelleştirme sistemi ile tam uyumlu iken kalıtım, uzantılar ve JavaScript entegrasyonu gibi gelişmiş senaryoları destekler.", @@ -163,7 +163,7 @@ "Strong": "Güçlü", "Complete": "Tamamlayınız", "BasedLayeringModel": "Tabanlı Katmanlama Modeli", - "Microservice": "mikro hizmet", + "Microservice": "Mikroservis", "Compatible": "Uyumlu", "MeeTTheABPCommunityInfo": "Misyonumuz, geliştiricilerin makaleler, öğreticiler, vaka çalışmaları vb. ile birbirlerine yardımcı olabilecekleri ve benzer düşünen insanlarla tanışabilecekleri bir ortam yaratmaktır.", "JoinTheABPCommunityInfo": "Canlı bir topluluğa katılın ve ABP Çerçevesine katkıda bulunun!", @@ -178,7 +178,7 @@ "ProgressiveWebApplication": "Progresif Web Uygulaması", "UseslatestPreVersion": "En son yayın öncesi sürümünü kullanır", "ReadTheDocumentation": "Belgeleri okuyun", - "Documentation": "belgeler", + "Documentation": "Dökümanlar", "GettingStartedTutorial": "Başlarken Eğitimi", "ApplicationDevelopmentTutorial": "Uygulama Geliştirme Eğitimi", "TheStartupTemplate": "Başlangıç Şablonu", @@ -285,7 +285,6 @@ "Database": "Veritabanı", "Saas": "Saas", "OpenSourceWebApp": " Açık kaynak
web uygulaması", - "Framework": "Çerçeve", "AuditLoggingExplanation": "Sisteminizdeki tüm işlemleri ve veri değişikliklerini otomatik olarak izleyin.", "AbpNewCommandExplanation": "ABP başlangıç şablonlarını kullanarak yeni çözümler oluşturur.", "AbpAddModuleCommandExplanation": "Çözümünüze önceden oluşturulmuş uygulama modülleri yükler", @@ -300,10 +299,8 @@ "Preview": "Önizleme", "CreateANewSolution": "Yeni bir çözüm oluşturun", "ABPFrameworkFeatures": "ABP Çerçevesi Özellikleri", - "Commercial": "Ticari", "ThirdPartyTools": "Üçüncü taraf araçlar", "Back": "Geri", - "Community": "Topluluk", "SeeMore": "Daha fazla göster", "DetailsOfTheEBook": "E-kitap detayları", "JoinOurMarketingNewsletter": "Pazarlama bültenimize katılın", @@ -377,7 +374,18 @@ "CreateSolutionFolder": "Çözüm Klasörü Oluşturun", "CreateSolutionFolderOption": "Projenin çıktı klasöründe yeni bir klasörde mi yoksa doğrudan çıktı klasöründe mi olacağını belirtir.", "SelectUITheme": "UI Temasını Seçin", - "BooksPageTitle": "ABP Kitapları" - + "BooksPageTitle": "ABP Kitapları", + "InstallAbpCliMessage": "Daha önce yüklemediyseniz, ABP CLI'yi bir komut satırı terminaline yükleyin:", + "RunTheFollowingCommand": "Aşağıdaki komutu bir komut satırı terminalinde çalıştırın:", + "ChangeSolutionOptionsBelow": "Aşağıdaki çözüm seçeneklerini değiştirebilirsiniz.", + "MultiLayerApplicationExplanation1": "Domain Driven Design uygulamalarına dayalı olarak tamamen katmanlı bir çözüm oluşturur.", + "MultiLayerApplicationExplanation2": "Sürdürülebilir ve genişletilebilir bir kod tabanına ihtiyaç duyan uzun vadeli projeler için önerilir.", + "SingleLayerApplicationExplanation1": "Tek katmanlı bir web uygulaması oluşturur.", + "SingleLayerApplicationExplanation2": "Daha basit ve anlaşılması kolay bir mimariye sahip bir uygulama oluşturmak için önerilir.", + "ApplicationModuleExplanation1": "Yeniden kullanılabilir, tamamen katmanlı bir uygulama modülü çözümü oluşturur.", + "ApplicationModuleExplanation2": "Modüler uygulamanız için modüller oluşturmak üzere bu seçeneği kullanabilirsiniz.", + "LeptonXLiteThemeInfo": " Modern ve şık bir Bootstrap UI teması. Üretime hazır bir UI temasına sahip olmak istiyorsanız idealdir. Bu en yeni temadır ve varsayılandır.", + "BasicThemeInfo": "Sade Bootstrap renkleri ve stilleri ile minimalist UI teması. Kendi UI temanızı oluşturacaksanız idealdir.", + "Details": "Detaylar" } } \ No newline at end of file diff --git a/build/common.ps1 b/build/common.ps1 index 61d9cf03d2..85f18edb21 100644 --- a/build/common.ps1 +++ b/build/common.ps1 @@ -36,7 +36,8 @@ if ($full -eq "-f") "../templates/console", "../templates/wpf", "../templates/app-nolayers/aspnet-core", - "../abp_io/AbpIoLocalization" + "../abp_io/AbpIoLocalization", + "../source-code" ) }else{ Write-host "" diff --git a/delete-bin-obj.ps1 b/delete-bin-obj.ps1 new file mode 100644 index 0000000000..e26ba4fdce --- /dev/null +++ b/delete-bin-obj.ps1 @@ -0,0 +1,15 @@ +Clear-Host + +Write-Host "Deleting all BIN and OBJ folders..." -ForegroundColor Cyan + +Get-ChildItem -Path . -Include bin,obj -Recurse -Directory | ForEach-Object { + if ($_.FullName -notmatch "\\node_modules\\") { + Write-Host "Deleting:" $_.FullName -ForegroundColor Yellow + Remove-Item $_.FullName -Recurse -Force + } else { + Write-Host "Skipping:" $_.FullName -ForegroundColor Magenta + } +} + +Write-Host "BIN and OBJ folders have been successfully deleted." -ForegroundColor Green + diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/abp-essential-features.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/abp-essential-features.png new file mode 100644 index 0000000000..287d130cb8 Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/abp-essential-features.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/abp-try-now.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/abp-try-now.png new file mode 100644 index 0000000000..c3a5ffdaec Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/abp-try-now.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/cover.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/cover.png new file mode 100644 index 0000000000..b2a7aa8595 Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/cover.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/cross-platform.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/cross-platform.png new file mode 100644 index 0000000000..5889357a42 Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/cross-platform.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/ddd-book.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/ddd-book.png new file mode 100644 index 0000000000..b18c3b716a Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/ddd-book.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/developer-focused.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/developer-focused.png new file mode 100644 index 0000000000..bfb0f15d28 Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/developer-focused.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/features.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/features.png new file mode 100644 index 0000000000..7c941289e2 Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/features.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/key-features.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/key-features.png new file mode 100644 index 0000000000..4c4b714694 Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/key-features.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/module-layers-and-packages.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/module-layers-and-packages.png new file mode 100644 index 0000000000..50d8d09f9b Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/module-layers-and-packages.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/open-source.png b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/open-source.png new file mode 100644 index 0000000000..e389e67146 Binary files /dev/null and b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/images/open-source.png differ diff --git a/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/post.md b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/post.md new file mode 100644 index 0000000000..8c6bef4b8a --- /dev/null +++ b/docs/en/Blog-Posts/2023-04-07_Ultimate_NET_Framework_ABP/post.md @@ -0,0 +1,85 @@ +Building robust web applications has become more important than ever as the world is becoming more web-focused. With the rise of new tools and frameworks, choosing the right web development framework can be challenging. Especially if you are a .NET developer, there not so many popular ASPNET Framework around. However, the ABP Framework has become popular for many developers due to its flexibility, scalability, feature set and performance. Let's mention what's ABP Framework and what it promises to .NET developers. + +## ASP.NET Core Architecture Best Practices + +![ABP Key Features](images/key-features.png) + +ABP Framework is an application design framework that provides developers with a powerful set of tools to build web applications quickly and efficiently. It is an open-source, cross-platform framework supporting monolithic and microservices architectures. ABP Framework is built on top of the ASP.NET Core architecture and incorporates best practices for developing web applications. + +## ASP.NET Platform + +The framework includes a wide range of features, such as an angular code generator with the help of [ABP Suite](https://commercial.abp.io/tools/suite), project templates, and web application themes. These features enable developers to create web applications that are both functional and visually appealing without spending much time on coding. Moreover, ABP Framework provides a common application framework that can be used for different applications, including SAAS, e-commerce, and social media platforms. + +ABP Framework also supports the domain-driven design, which means that the framework is designed to be flexible and adaptable to different business requirements. This approach allows developers to build applications aligned with business needs, ensuring that they are efficient and effective. + +## Open Source Dot Net Framework + +One of the major advantages of ABP Framework is its open-source nature. Many developers continuously improve and update the framework, making it more reliable and secure. Moreover, the ABP Framework is compatible with multiple .NET frameworks, including ASP.NET and .NET Core. When starting your project on top of a solid Microsoft web framework, the ABP Framework is one of the best choices. + +![ABP is cross platform](images\cross-platform.png) + +Another advantage of ABP Framework is that it provides rapid web application development tools that are easy to use. The framework includes project templates that developers can use as a starting point for their web applications, which can significantly reduce the development time. ABP Framework also provides a web app builder that developers can use to create web applications quickly and efficiently. + +## ASPNET Core Architecture + +ABP Framework is also compatible with Microsoft's Clean Architecture, a software design pattern that promotes separation of concerns and maintainability. This integration ensures that the applications developed using ABP Framework are well-structured, easy to maintain, and scalable. Many application marketplace reviewers commented about ABP as the best web application framework. While ABP supports multiple UI choices like MVC, Angular, Blazor Web Assembly and Blazor Server, the most downloaded one is MVC microservice architecture. If you are here to find a NET application framework for your next NET Core application, you are in the right place! + +![ABP Framework Project Hierarchy](images/module-layers-and-packages.png) + +Clean Architecture is a design pattern that emphasizes the separation of concerns, ensuring that the code is organized in independent layers. This helps developers to write code that is easy to maintain, test and refactor. ABP Framework uses this pattern to structure its application code and ensure that it is easy to manage. + +## Open Source Web Framework + +ABP Framework is an open-source web framework that is free to use and distribute. The framework is licensed under the MIT license, meaning developers can use it for commercial and non-commercial purposes without any restrictions. + +ABP Framework provides different templates, which are ASPNET Core web app compatible with various platforms, including Windows, Linux, and macOS. + +## Domain Driven Design DotNet + +The ABP Framework also implements Domain-Driven Design (DDD), a software design methodology that emphasizes the importance of the domain model. The framework provides a guide for implementing DDD through an implementing domain-driven design. It helps developers to create a domain model that is easy to understand, test, and maintain. As ABP is a C# framework, it supports most of the common application framework features for a core framework. + +![ABP Framework - Domain Driven Design e-book](images/ddd-book.png) + +There is also a free PDF e-book for Dotnet developers that explains the Domain Driven Design principle with real-world examples. You can download this e-book at https://abp.io/books/implementing-domain-driven-design + +## It's a Dotnet Web Framework + +ABP Framework is a dotnet web framework that is designed with C# and provides developers with a set of tools that makes it easy to build modern web applications. Whether you want to start a new dotnet monolithic solution or dotnet microservice solution, you can start with ABP. Creating your own dotnet framework architecture may be hard if you don't have many years of experience. The brain team of the ABP Framework specializes in ASP.NET framework architecture and ASP.NET application frameworks. + +![Developer Focused](images/developer-focused.png) + +## Essential Features of the ABP Framework: + +ASP.NET Core modularity, ASP.NET Core modular development, ASP.NET Core localization, ASP.NET Core SaaS framework, ASP.NET Core distributed, event, bus, ASP.NET Core cross-cutting concerns, ASP.NET Core blob storing, ASP.NET Core audit logging, ASP.NET Core microservice, ASP.NET Core microservice solution, ASP.NET Core microservice example, ASP.NET Core API gateway, ASP.NET Core domain, driven, design, ASP.NET Core layered architecture, ASP.NET Core layering, ASP.NET Core clean architecture, ASP.NET Core authentication, ASP.NET Core authorization, ASP.NET Core UI theme, ASP.NET Core tag helpers, ASP.NET Core identity, ASP.NET Core, identity, server, ASP.NET Core IdentityServer, ASP.NET Core payment module, ASP.NET Core best practices, ASP.NET Core design patterns, ASP.NET Core background jobs, ASP.NET Core exception handling, ASP.NET Core, background, workers, ASP.NET Core repository, ASP.NET Core repository pattern, ASP.NET Core unit of work, ASP.NET Core domain services, ASP.NET Core Swagger, ASP.NET Core content management system, ASP.NET Core CMS module, ASP.NET Core user management, ASP.NET Core Role management, ASP.NET Core permission management + +![ABP Essential Features](images/abp-essential-features.png) + +## Open Source Web Application Framework + +ABP Framework is an open-source web application development framework that is free to use and distribute. The framework is licensed under the MIT license, meaning developers can use it for commercial and non-commercial purposes without any restrictions. + +![ABP Framework is open-source](images\open-source.png) + +## C# Web Application Framework + +ABP Framework is built using C#, which is a modern programming language that is widely used in the development of web applications. C# provides developers with features that make it easy to write clean and maintainable code. ABP Framework is a web framework designed to work with C# and provides developers with tools that make it easy to build modern web applications. + +## Key Features + +The following .NET features are available in the ABP Framework: + +.NET modular development, .NET localization, .NET multi-tenancy, .NET SaaS framework, .NET distributed event bus, .NET cross-cutting concerns, .NET,microservice, .NET microservice solution, .NET microservice example, .NET domain driven design, .NET clean architecture, .NET authentication, .NET authorization, .NET best practices, .NET design,patterns, .NET exception handling, .NET background workers, .NET unit of work, .NET domain services, .NET user management, .NET role management, .NET permission management + +![ABP Framework Features](images/features.png) + +The following keywords best describe the ABP Framework; + +Open source backend framework, open source development framework, open source web app builder, open source web applications, open source web development, web application development framework, web application framework, web application framework software, web application infrastructure, web application open source, asp net framework, asp net open source, ASP.NET application, ASP.NET software, ASP.NET web app, ASP.NET web development, web app builder open source, web app framework, Dotnet framework, Dotnet UI framework, Dotnet web application themes. + + + +## Conclusion + +ABP Framework is a powerful and flexible web application framework that provides developers with the tools to build high-quality web applications quickly and efficiently. It is an open-source, cross-platform framework that supports multiple .NET frameworks, including ASP.NET and .NET Core. ABP Framework provides rapid web application development tools, project templates, and web application themes that enable developers to create visually appealing and functional applications in no time. + +![Try ABP now](images\abp-try-now.png) \ No newline at end of file diff --git a/docs/en/Community-Articles/2023-04-03-What-is-ABP-Framework/images/cover.png b/docs/en/Community-Articles/2023-04-03-What-is-ABP-Framework/images/cover.png index 4a0aaf8d4c..a926bcfca6 100644 Binary files a/docs/en/Community-Articles/2023-04-03-What-is-ABP-Framework/images/cover.png and b/docs/en/Community-Articles/2023-04-03-What-is-ABP-Framework/images/cover.png differ diff --git a/docs/en/Migration-Guides/Abp-7_1.md b/docs/en/Migration-Guides/Abp-7_1.md index 7e579af217..711f520800 100644 --- a/docs/en/Migration-Guides/Abp-7_1.md +++ b/docs/en/Migration-Guides/Abp-7_1.md @@ -2,6 +2,8 @@ This document is a guide for upgrading ABP v7.0 solutions to ABP v7.1. There are a few changes in this version that may affect your applications, please read it carefully and apply the necessary changes to your application. +> **Note**: Entity Framework developers may need to add a new code-first database migration to their projects since we made some improvements to the existing entities of some application modules. + ## Navigation Menu - `CustomData` type changed to `Dictionary` `ApplicationMenu` and `ApplicationMenuItem` classes' `CustomData` property type has been changed to `Dictionary`. So, if you use the optional `CustomData` property of these classes, change it accordingly. See [#15608](https://github.com/abpframework/abp/pull/15608) for more information. @@ -16,4 +18,4 @@ var menu = new ApplicationMenu("Home", L["Home"], "/", customData: new MyCustomD ```csharp var menu = new ApplicationMenu("Home", L["Home"], "/").WithCustomData("CustomDataKey", new MyCustomData()); -``` \ No newline at end of file +``` diff --git a/docs/en/Migration-Guides/Abp-7_2.md b/docs/en/Migration-Guides/Abp-7_2.md new file mode 100644 index 0000000000..5c99e8e604 --- /dev/null +++ b/docs/en/Migration-Guides/Abp-7_2.md @@ -0,0 +1,13 @@ +# ABP Version 7.2 Migration Guide + +This document is a guide for upgrading ABP v7.1 solutions to ABP v7.2. There are a few changes in this version that may affect your applications, please read it carefully and apply the necessary changes to your application. + +## `LastPasswordChangeTime` and `ShouldChangePasswordOnNextLogin` Properties Added to the `IdentityUser` Class + +In this version, two new properties, which are `LastPasswordChangeTime` and `ShouldChangePasswordOnNextLogin` have been added to the `IdentityUser` class and to the corresponding entity. Therefore, you may need to create a new migration and apply it to your database. + +## Renamed `OnRegistered` Method + +There was a typo in an extension method, named as `OnRegistred`. In this version, we have fixed the typo and renamed the method as `OnRegistered`. Also, we have updated the related places in our modules that use this method. + +However, if you have used this method in your projects, you need to rename it as `OnRegistered` in your code. \ No newline at end of file diff --git a/docs/en/Migration-Guides/Index.md b/docs/en/Migration-Guides/Index.md index 8a693970b2..7d85d3f46f 100644 --- a/docs/en/Migration-Guides/Index.md +++ b/docs/en/Migration-Guides/Index.md @@ -2,6 +2,7 @@ The following documents explain how to migrate your existing ABP applications. We write migration documents only if you need to take an action while upgrading your solution. Otherwise, you can easily upgrade your solution using the [abp update command](../Upgrading.md). +- [7.1 to 7.2](Abp-7_2.md) - [7.0 to 7.1](Abp-7_1.md) - [6.0 to 7.0](Abp-7_0.md) - [5.3 to 6.0](Abp-6_0.md) diff --git a/docs/en/Modules/Cms-Kit/Comments.md b/docs/en/Modules/Cms-Kit/Comments.md index 26aa7c0398..af335f1227 100644 --- a/docs/en/Modules/Cms-Kit/Comments.md +++ b/docs/en/Modules/Cms-Kit/Comments.md @@ -19,6 +19,16 @@ Configure(options => { options.EntityTypes.Add(new CommentEntityTypeDefinition("Product")); options.IsRecaptchaEnabled = true; //false by default + options.AllowedExternalUrls = new Dictionary> + { + { + "quote", + new List + { + "https://abp.io/" + } + } + }; }); ``` @@ -28,6 +38,7 @@ Configure(options => - `EntityTypes`: List of defined entity types(`CmsKitCommentOptions`) in the comment system. - `IsRecaptchaEnabled`: This flag enables or disables the reCaptcha for the comment system. You can set it as **true** if you want to use reCaptcha in your comment system. +- `AllowedExternalUrls`: Indicates the allowed external URLs by entity types, which can be included in a comment. If it's specified for a certain entity type, then only the specified external URLs are allowed in the comments. `CommentEntityTypeDefinition` properties: @@ -46,7 +57,7 @@ The comment system provides a commenting [widget](../../UI/AspNetCore/Widgets.md }) ``` -`entityType` was explained in the previous section. `entityId` should be the unique id of the product, in this example. If you have a Product entity, you can use its Id here. `referralLinks` is an optional parameter. You can use this parameter to add values (such as "nofollow", "noreferrer", or any other values) to the [rel attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/rel) of links. +`entityType` was explained in the previous section. `entityId` should be the unique id of the product, in this example. If you have a Product entity, you can use its Id here. `referralLinks` is an optional parameter. You can use this parameter to add values (such as "nofollow", "noreferrer", or any other values) to the [rel attributes](https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/rel) of links. ## User Interface diff --git a/docs/en/Themes/LeptonXLite/Angular.md b/docs/en/Themes/LeptonXLite/Angular.md index 56b003e606..3a82c77495 100644 --- a/docs/en/Themes/LeptonXLite/Angular.md +++ b/docs/en/Themes/LeptonXLite/Angular.md @@ -28,12 +28,8 @@ yarn add bootstrap-icons * [Styles - Angular UI](../../UI/Angular/Theme-Configurations.md) -Add the following style - -```json -"node_modules/bootstrap-icons/font/bootstrap-icons.css", -``` - +Note: You should remove the old theme styles from "angular.json" if you are switching from "ThemeBasic" or "Lepton." +Look at the [Theme Configurations](../../UI/Angular/Theme-Configurations) list of styles. Depending on your theme, you can alter your styles in angular.json. - Finally, remove `ThemeBasicModule` from `app.module.ts`, and import the related modules in `app.module.ts` ```js @@ -44,7 +40,7 @@ import { SideMenuLayoutModule } from "@abp/ng.theme.lepton-x/layouts"; imports: [ // ... - // do not forget to remove ThemeBasicModule + // do not forget to remove ThemeBasicModule or other old theme module // ThemeBasicModule.forRoot(), ThemeLeptonXModule.forRoot(), SideMenuLayoutModule.forRoot(), diff --git a/framework/src/Volo.Abp.AspNetCore.Components.Web/Volo/Abp/AspNetCore/Components/Web/Extensibility/TableColumns/TableColumn.cs b/framework/src/Volo.Abp.AspNetCore.Components.Web/Volo/Abp/AspNetCore/Components/Web/Extensibility/TableColumns/TableColumn.cs index 9a6a40a17a..aa48ad633b 100644 --- a/framework/src/Volo.Abp.AspNetCore.Components.Web/Volo/Abp/AspNetCore/Components/Web/Extensibility/TableColumns/TableColumn.cs +++ b/framework/src/Volo.Abp.AspNetCore.Components.Web/Volo/Abp/AspNetCore/Components/Web/Extensibility/TableColumns/TableColumn.cs @@ -10,14 +10,22 @@ public class TableColumn { public string Title { get; set; } public string Data { get; set; } + + public string PropertyName { get; set; } + [CanBeNull] public string DisplayFormat { get; set; } + public IFormatProvider DisplayFormatProvider { get; set; } = CultureInfo.CurrentCulture; + [CanBeNull] public Type Component { get; set; } + public List Actions { get; set; } + [CanBeNull] public Func ValueConverter { get; set; } + public bool Sortable { get; set; } public TableColumn() diff --git a/framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo.csproj b/framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo.csproj index cad3da097a..c576f7897d 100644 --- a/framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo.csproj +++ b/framework/src/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo/Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared.Demo.csproj @@ -30,8 +30,7 @@ - - + diff --git a/framework/src/Volo.Abp.BlazoriseUI/AbpCrudPageBase.cs b/framework/src/Volo.Abp.BlazoriseUI/AbpCrudPageBase.cs index 1e3cf13549..3bcc507e39 100644 --- a/framework/src/Volo.Abp.BlazoriseUI/AbpCrudPageBase.cs +++ b/framework/src/Volo.Abp.BlazoriseUI/AbpCrudPageBase.cs @@ -309,7 +309,7 @@ public abstract class AbpCrudPageBase< { CurrentSorting = e.Columns .Where(c => c.SortDirection != SortDirection.Default) - .Select(c => c.Field + (c.SortDirection == SortDirection.Descending ? " DESC" : "")) + .Select(c => c.SortField + (c.SortDirection == SortDirection.Descending ? " DESC" : "")) .JoinAsString(","); CurrentPage = e.Page; @@ -608,7 +608,8 @@ public abstract class AbpCrudPageBase< yield return new TableColumn { Title = lookupPropertyDefinition.GetLocalizedDisplayName(StringLocalizerFactory), - Data = $"ExtraProperties[{propertyInfo.Name}]" + Data = $"ExtraProperties[{propertyInfo.Name}]", + PropertyName = propertyInfo.Name }; } else @@ -616,7 +617,8 @@ public abstract class AbpCrudPageBase< var column = new TableColumn { Title = propertyInfo.GetLocalizedDisplayName(StringLocalizerFactory), - Data = $"ExtraProperties[{propertyInfo.Name}]" + Data = $"ExtraProperties[{propertyInfo.Name}]", + PropertyName = propertyInfo.Name }; if (propertyInfo.IsDate() || propertyInfo.IsDateTime()) diff --git a/framework/src/Volo.Abp.BlazoriseUI/Components/AbpExtensibleDataGrid.razor b/framework/src/Volo.Abp.BlazoriseUI/Components/AbpExtensibleDataGrid.razor index 0e5e76b3ec..88a0a1df4a 100644 --- a/framework/src/Volo.Abp.BlazoriseUI/Components/AbpExtensibleDataGrid.razor +++ b/framework/src/Volo.Abp.BlazoriseUI/Components/AbpExtensibleDataGrid.razor @@ -105,7 +105,7 @@ } else { - + @{ var entity = context as IHasExtraProperties; diff --git a/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor b/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor index 52369d6b46..2ea468f1f4 100644 --- a/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor +++ b/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor @@ -11,7 +11,6 @@ TValue="object" TextField="item => item?.Text" ValueField="item => item?.Value" - SelectedText="@SelectedText" SelectedValue="@SelectedValue" SelectedValueChanged="@SelectedValueChanged" SearchChanged="@SearchFilterChangedAsync" diff --git a/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor.cs b/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor.cs index c21db1352d..5da0138d9d 100644 --- a/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor.cs +++ b/framework/src/Volo.Abp.BlazoriseUI/Components/ObjectExtending/LookupExtensionProperty.razor.cs @@ -23,7 +23,7 @@ namespace Volo.Abp.BlazoriseUI.Components.ObjectExtending; public partial class LookupExtensionProperty where TEntity : IHasExtraProperties { - protected List> lookupItems; + protected List> lookupItems = new(); [Inject] public ILookupApiRequestService LookupApiService { get; set; } @@ -37,17 +37,28 @@ public partial class LookupExtensionProperty } } - public string SelectedText => Entity.GetProperty(TextPropertyName); - - public LookupExtensionProperty() + protected override void OnParametersSet() { - lookupItems = new List>(); + var value = Entity.GetProperty(PropertyInfo.Name); + var text = Entity.GetProperty(TextPropertyName); + if (value != null && text != null) + { + lookupItems.Add(new SelectItem + { + Text = Entity.GetProperty(TextPropertyName).ToString(), + Value = value + }); + } } - - protected async override Task OnInitializedAsync() + + protected async override Task OnAfterRenderAsync(bool firstRender) { - await base.OnInitializedAsync(); - await SearchFilterChangedAsync(string.Empty); + await base.OnAfterRenderAsync(firstRender); + + if (firstRender) + { + await SearchFilterChangedAsync(string.Empty); + } } protected virtual void UpdateLookupTextProperty(object value) diff --git a/framework/src/Volo.Abp.Castle.Core/Volo.Abp.Castle.Core.csproj b/framework/src/Volo.Abp.Castle.Core/Volo.Abp.Castle.Core.csproj index 5b52e2b9e4..83a3253b07 100644 --- a/framework/src/Volo.Abp.Castle.Core/Volo.Abp.Castle.Core.csproj +++ b/framework/src/Volo.Abp.Castle.Core/Volo.Abp.Castle.Core.csproj @@ -15,7 +15,7 @@ - + diff --git a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Entities/EntityHelper.cs b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Entities/EntityHelper.cs index 03b192c851..f7a4f27e5f 100644 --- a/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Entities/EntityHelper.cs +++ b/framework/src/Volo.Abp.Ddd.Domain/Volo/Abp/Domain/Entities/EntityHelper.cs @@ -123,10 +123,17 @@ public static class EntityHelper return typeof(IEntity).IsAssignableFrom(type); } + public static Func IsValueObjectPredicate = type => typeof(ValueObject).IsAssignableFrom(type); + public static bool IsValueObject([NotNull] Type type) { Check.NotNull(type, nameof(type)); - return typeof(ValueObject).IsAssignableFrom(type); + return IsValueObjectPredicate(type); + } + + public static bool IsValueObject(object obj) + { + return obj != null && IsValueObject(obj.GetType()); } public static void CheckEntity([NotNull] Type type) diff --git a/framework/src/Volo.Abp.DistributedLocking.Abstractions/Volo.Abp.DistributedLocking.Abstractions.csproj b/framework/src/Volo.Abp.DistributedLocking.Abstractions/Volo.Abp.DistributedLocking.Abstractions.csproj index c75303ad2a..85b832eefb 100644 --- a/framework/src/Volo.Abp.DistributedLocking.Abstractions/Volo.Abp.DistributedLocking.Abstractions.csproj +++ b/framework/src/Volo.Abp.DistributedLocking.Abstractions/Volo.Abp.DistributedLocking.Abstractions.csproj @@ -16,7 +16,7 @@ - + diff --git a/framework/src/Volo.Abp.EntityFrameworkCore/Volo/Abp/EntityFrameworkCore/EntityHistory/EntityHistoryHelper.cs b/framework/src/Volo.Abp.EntityFrameworkCore/Volo/Abp/EntityFrameworkCore/EntityHistory/EntityHistoryHelper.cs index c887175655..801e772e26 100644 --- a/framework/src/Volo.Abp.EntityFrameworkCore/Volo/Abp/EntityFrameworkCore/EntityHistory/EntityHistoryHelper.cs +++ b/framework/src/Volo.Abp.EntityFrameworkCore/Volo/Abp/EntityFrameworkCore/EntityHistory/EntityHistoryHelper.cs @@ -93,7 +93,7 @@ public class EntityHistoryHelper : IEntityHistoryHelper, ITransientDependency } var entityId = GetEntityId(entity); - if (entityId == null && changeType != EntityChangeType.Created && !(entity is ValueObject)) + if (entityId == null && changeType != EntityChangeType.Created && !EntityHelper.IsValueObject(entity)) { return null; } @@ -151,7 +151,7 @@ public class EntityHistoryHelper : IEntityHistoryHelper, ITransientDependency return keys.JoinAsString(","); } - if (entityAsObj is ValueObject) + if (EntityHelper.IsValueObject(entityAsObj)) { return null; } diff --git a/modules/cms-kit/host/Volo.CmsKit.Web.Unified/CmsKitWebUnifiedModule.cs b/modules/cms-kit/host/Volo.CmsKit.Web.Unified/CmsKitWebUnifiedModule.cs index 763218edc4..f4f746a61d 100644 --- a/modules/cms-kit/host/Volo.CmsKit.Web.Unified/CmsKitWebUnifiedModule.cs +++ b/modules/cms-kit/host/Volo.CmsKit.Web.Unified/CmsKitWebUnifiedModule.cs @@ -1,3 +1,4 @@ +using System.Collections.Generic; using System.IO; using Microsoft.AspNetCore.Builder; using Microsoft.Extensions.DependencyInjection; @@ -168,6 +169,16 @@ public class CmsKitWebUnifiedModule : AbpModule { options.EntityTypes.Add(new CommentEntityTypeDefinition("quote")); options.IsRecaptchaEnabled = true; + options.AllowedExternalUrls = new Dictionary> + { + { + "quote", + new List + { + "https://abp.io/" + } + } + }; }); Configure(options => diff --git a/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Comments/CmsKitCommentOptions.cs b/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Comments/CmsKitCommentOptions.cs index 94d3b785ec..1346541e69 100644 --- a/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Comments/CmsKitCommentOptions.cs +++ b/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Comments/CmsKitCommentOptions.cs @@ -13,4 +13,9 @@ public class CmsKitCommentOptions /// Default: false /// public bool IsRecaptchaEnabled { get; set; } + + /// + /// Indicates the allowed external URLs by entity types, which can be included in a comment. + /// + public Dictionary> AllowedExternalUrls { get; set; } = new(); } diff --git a/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Localization/Resources/en.json b/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Localization/Resources/en.json index 9bb8dd275c..2f7d8ce13d 100644 --- a/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Localization/Resources/en.json +++ b/modules/cms-kit/src/Volo.CmsKit.Domain.Shared/Volo/CmsKit/Localization/Resources/en.json @@ -216,6 +216,7 @@ "CaptchaCode": "Captcha code", "CommentTextRequired": "Comment is required", "CaptchaCodeErrorMessage" : "The answer you entered for the CAPTCHA was not correct. Please try again", - "CaptchaCodeMissingMessage": "The captcha code is missing!" + "CaptchaCodeMissingMessage": "The captcha code is missing!", + "UnAllowedExternalUrlMessage": "You included an unallowed external URL. Please try again without the external URL." } } \ No newline at end of file diff --git a/modules/cms-kit/src/Volo.CmsKit.Public.Application.Contracts/Volo/CmsKit/Public/Comments/CreateCommentWithParameteresInput.cs b/modules/cms-kit/src/Volo.CmsKit.Public.Application.Contracts/Volo/CmsKit/Public/Comments/CreateCommentWithParametersInput.cs similarity index 92% rename from modules/cms-kit/src/Volo.CmsKit.Public.Application.Contracts/Volo/CmsKit/Public/Comments/CreateCommentWithParameteresInput.cs rename to modules/cms-kit/src/Volo.CmsKit.Public.Application.Contracts/Volo/CmsKit/Public/Comments/CreateCommentWithParametersInput.cs index 7e156ef375..bfdbd0a95d 100644 --- a/modules/cms-kit/src/Volo.CmsKit.Public.Application.Contracts/Volo/CmsKit/Public/Comments/CreateCommentWithParameteresInput.cs +++ b/modules/cms-kit/src/Volo.CmsKit.Public.Application.Contracts/Volo/CmsKit/Public/Comments/CreateCommentWithParametersInput.cs @@ -6,7 +6,7 @@ using Volo.CmsKit.Comments; namespace Volo.CmsKit.Public.Comments; [Serializable] -public class CreateCommentWithParameteresInput +public class CreateCommentWithParametersInput { [Required] [DynamicStringLength(typeof(CommentConsts), nameof(CommentConsts.MaxTextLength))] diff --git a/modules/cms-kit/src/Volo.CmsKit.Public.Application/Volo/CmsKit/Public/Comments/CommentPublicAppService.cs b/modules/cms-kit/src/Volo.CmsKit.Public.Application/Volo/CmsKit/Public/Comments/CommentPublicAppService.cs index 05857e5db9..4a7bd8be8c 100644 --- a/modules/cms-kit/src/Volo.CmsKit.Public.Application/Volo/CmsKit/Public/Comments/CommentPublicAppService.cs +++ b/modules/cms-kit/src/Volo.CmsKit.Public.Application/Volo/CmsKit/Public/Comments/CommentPublicAppService.cs @@ -1,9 +1,11 @@ using System; using System.Collections.Generic; using System.Linq; -using System.Security; +using System.Text.RegularExpressions; using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; +using Microsoft.Extensions.Options; +using Volo.Abp; using Volo.Abp.Application.Dtos; using Volo.Abp.Authorization; using Volo.Abp.Data; @@ -23,24 +25,27 @@ namespace Volo.CmsKit.Public.Comments; [RequiresGlobalFeature(typeof(CommentsFeature))] public class CommentPublicAppService : CmsKitPublicAppServiceBase, ICommentPublicAppService { + protected string RegexMarkdownUrlPattern = @"\[[^\]]*\]\((?.*?)\)(?![^\x60]*\x60)"; + protected ICommentRepository CommentRepository { get; } protected ICmsUserLookupService CmsUserLookupService { get; } public IDistributedEventBus DistributedEventBus { get; } protected CommentManager CommentManager { get; } - protected IAuthorizationService AuthorizationService { get; } + + protected CmsKitCommentOptions CmsCommentOptions { get; } public CommentPublicAppService( ICommentRepository commentRepository, ICmsUserLookupService cmsUserLookupService, IDistributedEventBus distributedEventBus, CommentManager commentManager, - IAuthorizationService authorizationService) + IOptionsSnapshot cmsCommentOptions) { CommentRepository = commentRepository; CmsUserLookupService = cmsUserLookupService; DistributedEventBus = distributedEventBus; CommentManager = commentManager; - AuthorizationService = authorizationService; + CmsCommentOptions = cmsCommentOptions.Value; } public virtual async Task> GetListAsync(string entityType, string entityId) @@ -56,6 +61,8 @@ public class CommentPublicAppService : CmsKitPublicAppServiceBase, ICommentPubli [Authorize] public virtual async Task CreateAsync(string entityType, string entityId, CreateCommentInput input) { + CheckExternalUrls(entityType, input.Text); + var user = await CmsUserLookupService.GetByIdAsync(CurrentUser.GetId()); if (input.RepliedCommentId.HasValue) @@ -87,11 +94,12 @@ public class CommentPublicAppService : CmsKitPublicAppServiceBase, ICommentPubli public virtual async Task UpdateAsync(Guid id, UpdateCommentInput input) { var comment = await CommentRepository.GetAsync(id); - if (comment.CreatorId != CurrentUser.GetId()) { throw new AbpAuthorizationException(); } + + CheckExternalUrls(comment.EntityType, input.Text); comment.SetText(input.Text); comment.SetConcurrencyStampIfNotNull(input.ConcurrencyStamp); @@ -148,4 +156,46 @@ public class CommentPublicAppService : CmsKitPublicAppServiceBase, ICommentPubli { return ObjectMapper.Map(comments.Single(c => c.Comment.Id == commentId).Author); } + + private void CheckExternalUrls(string entityType, string text) + { + if (!CmsCommentOptions.AllowedExternalUrls.TryGetValue(entityType, out var allowedExternalUrls)) + { + return; + } + + var matches = Regex.Matches(text, RegexMarkdownUrlPattern, + RegexOptions.Compiled | RegexOptions.IgnoreCase); + + foreach (Match match in matches) + { + if (!match.Success || match.Groups.Count < 2) + { + continue; + } + + var url = NormalizeUrl(match.Groups[1].Value); + if (!IsExternalUrl(url)) + { + continue; + } + + if (!allowedExternalUrls.Any(allowedExternalUrl => + url.Contains(NormalizeUrl(allowedExternalUrl), StringComparison.OrdinalIgnoreCase))) + { + throw new UserFriendlyException(L["UnAllowedExternalUrlMessage"]); + } + } + } + + private static bool IsExternalUrl(string url) + { + return url.StartsWith("https", StringComparison.InvariantCultureIgnoreCase) || + url.StartsWith("http", StringComparison.InvariantCultureIgnoreCase); + } + + private static string NormalizeUrl(string url) + { + return url.Replace("www.", "").RemovePostFix("/"); + } } diff --git a/modules/cms-kit/src/Volo.CmsKit.Public.Web/CmsKitPublicWebAutoMapperProfile.cs b/modules/cms-kit/src/Volo.CmsKit.Public.Web/CmsKitPublicWebAutoMapperProfile.cs index 3c44f6fa1c..744d5afbad 100644 --- a/modules/cms-kit/src/Volo.CmsKit.Public.Web/CmsKitPublicWebAutoMapperProfile.cs +++ b/modules/cms-kit/src/Volo.CmsKit.Public.Web/CmsKitPublicWebAutoMapperProfile.cs @@ -8,6 +8,6 @@ public class CmsKitPublicWebAutoMapperProfile : Profile { public CmsKitPublicWebAutoMapperProfile() { - CreateMap(); + CreateMap(); } } diff --git a/modules/cms-kit/src/Volo.CmsKit.Public.Web/Controllers/CmsKitPublicCommentsController.cs b/modules/cms-kit/src/Volo.CmsKit.Public.Web/Controllers/CmsKitPublicCommentsController.cs index bb2487587b..e10a606826 100644 --- a/modules/cms-kit/src/Volo.CmsKit.Public.Web/Controllers/CmsKitPublicCommentsController.cs +++ b/modules/cms-kit/src/Volo.CmsKit.Public.Web/Controllers/CmsKitPublicCommentsController.cs @@ -29,14 +29,14 @@ public class CmsKitPublicCommentsController : AbpController } [HttpPost] - public async Task ValidateAsync([FromBody] CreateCommentWithParameteresInput input) + public async Task ValidateAsync([FromBody] CreateCommentWithParametersInput input) { if (CmsKitCommentOptions.IsRecaptchaEnabled && input.CaptchaToken.HasValue) { SimpleMathsCaptchaGenerator.Validate(input.CaptchaToken.Value, input.CaptchaAnswer); } - var dto = ObjectMapper.Map (input); + var dto = ObjectMapper.Map (input); await CommentPublicAppService.CreateAsync(input.EntityType, input.EntityId, dto); } } diff --git a/modules/cms-kit/src/Volo.CmsKit.Public.Web/Pages/CmsKit/Shared/Components/Commenting/CommentingViewComponent.cs b/modules/cms-kit/src/Volo.CmsKit.Public.Web/Pages/CmsKit/Shared/Components/Commenting/CommentingViewComponent.cs index 304cfec687..b1ea42397f 100644 --- a/modules/cms-kit/src/Volo.CmsKit.Public.Web/Pages/CmsKit/Shared/Components/Commenting/CommentingViewComponent.cs +++ b/modules/cms-kit/src/Volo.CmsKit.Public.Web/Pages/CmsKit/Shared/Components/Commenting/CommentingViewComponent.cs @@ -121,7 +121,7 @@ public class CommentingViewComponent : AbpViewComponent public string EntityType { get; set; } public string EntityId { get; set; } - + public IEnumerable ReferralLinks { get; set; } public string LoginUrl { get; set; } diff --git a/modules/cms-kit/test/Volo.CmsKit.Application.Tests/CmsKitApplicationTestModule.cs b/modules/cms-kit/test/Volo.CmsKit.Application.Tests/CmsKitApplicationTestModule.cs index e20c222a58..e0dba22140 100644 --- a/modules/cms-kit/test/Volo.CmsKit.Application.Tests/CmsKitApplicationTestModule.cs +++ b/modules/cms-kit/test/Volo.CmsKit.Application.Tests/CmsKitApplicationTestModule.cs @@ -1,4 +1,6 @@ -using Volo.Abp.Modularity; +using System.Collections.Generic; +using Volo.Abp.Modularity; +using Volo.CmsKit.Comments; namespace Volo.CmsKit; @@ -8,5 +10,20 @@ namespace Volo.CmsKit; )] public class CmsKitApplicationTestModule : AbpModule { - + public override void ConfigureServices(ServiceConfigurationContext context) + { + Configure(options => + { + options.AllowedExternalUrls = new Dictionary> + { + { + "EntityName1", + new List + { + "https://abp.io/" + } + } + }; + }); + } } diff --git a/modules/cms-kit/test/Volo.CmsKit.Application.Tests/Comments/CommentPublicAppService_Tests.cs b/modules/cms-kit/test/Volo.CmsKit.Application.Tests/Comments/CommentPublicAppService_Tests.cs index d0e698937d..ddd913a93f 100644 --- a/modules/cms-kit/test/Volo.CmsKit.Application.Tests/Comments/CommentPublicAppService_Tests.cs +++ b/modules/cms-kit/test/Volo.CmsKit.Application.Tests/Comments/CommentPublicAppService_Tests.cs @@ -3,6 +3,7 @@ using System.Threading.Tasks; using Microsoft.Extensions.DependencyInjection; using NSubstitute; using Shouldly; +using Volo.Abp; using Volo.Abp.Users; using Volo.CmsKit.Public.Comments; using Xunit; @@ -62,6 +63,23 @@ public class CommentPublicAppService_Tests : CmsKitApplicationTestBase }); } + [Fact] + public async Task CreateAsync_ShouldThrowUserFriendlyException_If_Url_UnAllowed() + { + _currentUser.Id.Returns(_cmsKitTestData.User2Id); + + await Should.ThrowAsync(async () => + await _commentAppService.CreateAsync( + _cmsKitTestData.EntityType1, + _cmsKitTestData.EntityId1, + new CreateCommentInput + { + RepliedCommentId = null, + Text = "[ABP Community](https://community.abp.io/)", //not allowed URL + } + )); + } + [Fact] public async Task UpdateAsync() { @@ -80,6 +98,21 @@ public class CommentPublicAppService_Tests : CmsKitApplicationTestBase comment.Text.ShouldBe("I'm Updated"); }); } + + [Fact] + public async Task UpdateAsync_ShouldThrowUserFriendlyException_If_Url_UnAllowed() + { + _currentUser.Id.Returns(_cmsKitTestData.User1Id); + + await Should.ThrowAsync(async () => + await _commentAppService.UpdateAsync( + _cmsKitTestData.CommentWithChildId, + new UpdateCommentInput + { + Text = "[ABP Community - Update](https://community.abp.io/)", //not allowed URL + } + )); + } [Fact] public async Task DeleteAsync() diff --git a/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.css b/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.css index 454e6eb742..cd0ee8e064 100644 --- a/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.css +++ b/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.css @@ -2,3 +2,7 @@ margin-top: 1.5em !important; background: rgba(233, 237, 241, 0.34) !important; padding: 1px !important; } + +.input-group .input-group-text{ + background-color: transparent!important; +} \ No newline at end of file diff --git a/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.min.css b/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.min.css index 86f286308a..3f6ed60f02 100644 --- a/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.min.css +++ b/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.min.css @@ -1 +1 @@ -.code-toolbar .line-highlight{margin-top:1.5em !important;background:rgba(233,237,241,.34) !important;padding:1px !important;} \ No newline at end of file +.code-toolbar .line-highlight{margin-top:1.5em !important;background:rgba(233,237,241,.34) !important;padding:1px !important;} .input-group .input-group-text{background-color: transparent!important;} \ No newline at end of file diff --git a/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.scss b/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.scss index 485c6cd881..384d025602 100644 --- a/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.scss +++ b/modules/docs/src/Volo.Docs.Web/Pages/Documents/Project/index.scss @@ -5,3 +5,9 @@ padding: 1px !important; } } + +.input-group{ + .input-group-text{ + background-color: transparent!important; + } +} \ No newline at end of file diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/IdentityErrorCodes.cs b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/IdentityErrorCodes.cs index ff808d9fbb..4e681c3ea1 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/IdentityErrorCodes.cs +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/IdentityErrorCodes.cs @@ -10,4 +10,5 @@ public static class IdentityErrorCodes public const string StaticRoleDeletion = "Volo.Abp.Identity:010006"; public const string UsersCanNotChangeTwoFactor = "Volo.Abp.Identity:010007"; public const string CanNotChangeTwoFactor = "Volo.Abp.Identity:010008"; + public const string YouCannotDelegateYourself = "Volo.Abp.Identity:010009"; } diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ar.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ar.json index 523e5c91a1..490bd611df 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ar.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ar.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "لا يمكن حذف الأدوار الثابتة.", "Volo.Abp.Identity:010007": "لا يمكنك تغيير إعداد العاملين.", "Volo.Abp.Identity:010008": "لا يجوز تغيير إعداد عاملين.", + "Volo.Abp.Identity:010009": "لا يمكنك تفويض نفسك.", "Identity.OrganizationUnit.MaxUserMembershipCount": "العدد الأقصى المسموح به لعضوية الوحدة التنظيمية للمستخدم", "ThisUserIsNotActiveMessage": "هذا المستخدم غير نشط.", "Permission:IdentityManagement": "إدارة الهوية", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/cs.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/cs.json index 43e0bb43dd..7f2ddde421 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/cs.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/cs.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Statické role nemohou být smazány.", "Volo.Abp.Identity:010007": "Nastavení dvou faktorů nemůžete změnit.", "Volo.Abp.Identity:010008": "Není povoleno měnit nastavení dvou faktorů.", + "Volo.Abp.Identity:010009": "Nemůžete delegovat své vlastní oprávnění.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maximální povolený počet členů organizační jednotky pro uživatele", "ThisUserIsNotActiveMessage": "Tento uživatel není aktivní.", "Permission:IdentityManagement": "Správa identit", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/de.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/de.json index 3e3dba7263..69f2e9e9b2 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/de.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/de.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Statische Rollen können nicht gelöscht werden.", "Volo.Abp.Identity:010007": "Sie können Ihre Zwei-Faktor-Einstellung nicht ändern.", "Volo.Abp.Identity:010008": "Die Zwei-Faktor-Einstellung dürfen nicht geändert werden.", + "Volo.Abp.Identity:010009": "Sie können sich nicht selbst delegieren.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maximal zulässige Anzahl an Mitgliedschaften in Organisationseinheiten für einen Benutzer", "ThisUserIsNotActiveMessage": "Dieser Benutzer ist nicht aktiv.", "Permission:IdentityManagement": "Identitätsverwaltung", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/el.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/el.json index 409f2710a6..765d85ce09 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/el.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/el.json @@ -70,6 +70,7 @@ "Volo.Abp.Identity:010006": "Οι στατικοί ρόλοι δεν μπορούν να διαγραφούν.", "Volo.Abp.Identity:010007": "Δεν μπορείτε να αλλάξετε τη ρύθμιση δύο παραγόντων.", "Volo.Abp.Identity:010008": "Δεν επιτρέπεται η αλλαγή της ρύθμισης δύο παραγόντων.", + "Volo.Abp.Identity:010009": "Δεν μπορείτε να αναθέσετε την εξουσιοδότησή σας σε εσάς ίδιο.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Μέγιστος επιτρεπόμενος αριθμός μελών μονάδας οργανισμού για έναν χρήστη", "ThisUserIsNotActiveMessage": "Αυτός ο χρήστης δεν είναι ενεργός.", "Permission:IdentityManagement": "Διαχείριση ταυτότητας", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en-GB.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en-GB.json index b0e8286ed8..adebfa33e8 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en-GB.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en-GB.json @@ -70,6 +70,7 @@ "Volo.Abp.Identity:010006": "Static roles cannot be deleted.", "Volo.Abp.Identity:010007": "You can't change your two factor setting.", "Volo.Abp.Identity:010008": "Changing the two factor setting is not allowed.", + "Volo.Abp.Identity:010009": "You cannot delegate yourself!", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maximum allowed organisation unit membership count for a user", "Permission:IdentityManagement": "Identity management", "Permission:RoleManagement": "Role management", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en.json index 8dadff1594..724ec04300 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/en.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Static roles can not be deleted.", "Volo.Abp.Identity:010007": "You can't change your two factor setting.", "Volo.Abp.Identity:010008": "It's not allowed to change two factor setting.", + "Volo.Abp.Identity:010009": "You can not delegate yourself.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maximum allowed organization unit membership count for a user", "ThisUserIsNotActiveMessage": "This user is not active.", "Permission:IdentityManagement": "Identity management", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/es.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/es.json index 1cbad4abce..06c279ec73 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/es.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/es.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Los roles estáticos no pueden ser borrados.", "Volo.Abp.Identity:010007": "No puedes cambiar tu configuración de autentificación de dos pasos.", "Volo.Abp.Identity:010008": "No está permitido cambiar la configuración de autenticación de dos pasos.", + "Volo.Abp.Identity:010009": "No puedes delegar tu propia cuenta!", "Identity.OrganizationUnit.MaxUserMembershipCount": "Número máximo de unidades organizativas por usuario", "ThisUserIsNotActiveMessage": "Este usuario no está activo.", "Permission:IdentityManagement": "Gestión de identidades", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fa.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fa.json index 5f82e64b46..7a89cebc87 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fa.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fa.json @@ -70,6 +70,7 @@ "Volo.Abp.Identity:010006": "نقش/وظیفه ی استاتیک را نمی توان حذف کرد.", "Volo.Abp.Identity:010007": "شما نمی توانید تنظیمات دو مرحله ای خود را تغییر دهید.", "Volo.Abp.Identity:010008": "تغییر دادن تنظیمات دو مرحله ای مجاز نمی باشد.", + "Volo.Abp.Identity:010009": "شما نمی توانید خودتان را معرفی کنید.", "Identity.OrganizationUnit.MaxUserMembershipCount": "حداکثر تعداد مجاز عضویت در یک واحد سازمان برای یک کاربر", "ThisUserIsNotActiveMessage": "این کاربر غیرفعال میباشد.", "Permission:IdentityManagement": "مدیریت هویت", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fi.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fi.json index d05f8fea0d..d74257414a 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fi.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fi.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Staattisia rooleja ei voi poistaa.", "Volo.Abp.Identity:010007": "Et voi muuttaa kahden tekijän asetusta.", "Volo.Abp.Identity:010008": "Kahden tekijän asetusta ei saa muuttaa.", + "Volo.Abp.Identity:010009": "Et voi delegoida itseäsi.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Suurin sallittu organisaatioyksikön jäsenmäärä käyttäjälle", "ThisUserIsNotActiveMessage": "Tämä käyttäjä ei ole aktiivinen.", "Permission:IdentityManagement": "Identiteetin hallinta", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fr.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fr.json index 6b35b77250..80a5f90a10 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fr.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/fr.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Les rôles statiques ne peuvent pas être supprimés.", "Volo.Abp.Identity:010007": "Vous ne pouvez pas modifier votre paramètre à deux facteurs.", "Volo.Abp.Identity:010008": "Il n’est pas permis de changer deux facteurs de réglage.", + "Volo.Abp.Identity:010009": "Vous ne pouvez pas vous déléguer vous-même.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Nombre maximal d’adhésions autorisées à l’unité d’organisation pour un utilisateur", "ThisUserIsNotActiveMessage": "Cet utilisateur n'est pas actif.", "Permission:IdentityManagement": "Gestion de l’identité", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hi.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hi.json index 30947281bb..e01e4c8e25 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hi.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hi.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "स्टेटिक भूमिकाओं को हटाया नहीं जा सकता।", "Volo.Abp.Identity:010007": "आप अपनी दो कारक सेटिंग नहीं बदल सकते।", "Volo.Abp.Identity:010008": "इसे दो कारक सेटिंग बदलने की अनुमति नहीं है।", + "Volo.Abp.Identity:010009": "आप अपने आप को अधिकृत नहीं कर सकते हैं!", "Identity.OrganizationUnit.MaxUserMembershipCount": "उपयोगकर्ता के लिए अधिकतम अनुमत संगठन इकाई सदस्यता गणना", "ThisUserIsNotActiveMessage": "यह उपयोगकर्ता सक्रिय नहीं है।", "Permission:IdentityManagement": "पहचान प्रबंधन", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hr.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hr.json index e0f706b504..a31715fc16 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hr.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hr.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Statičke uloge nije moguće izbrisati.", "Volo.Abp.Identity:010007": "Ne možete promijeniti postavku dva faktora.", "Volo.Abp.Identity:010008": "Nije dopušteno mijenjati postavke dvofaktorske autentifikacije.", + "Volo.Abp.Identity:010009": "Ne možete delegirati sami sebi.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maksimalni dopušteni broj članstva u organizacijskoj jedinici za korisnika", "ThisUserIsNotActiveMessage": "Ovaj korisnik nije aktivan.", "Permission:IdentityManagement": "Upravljanje identitetom", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hu.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hu.json index 106fa4cd3d..8c658c9e89 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hu.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/hu.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "A statikus szerepeket nem lehet törölni.", "Volo.Abp.Identity:010007": "Nem változtathatja meg a kétlépcsős bejelentkezés beállítását.", "Volo.Abp.Identity:010008": "Kétlépcsős bejelentkezés beállítás megváltoztatása nem megengedett.", + "Volo.Abp.Identity:010009": "Nem adhatja át a saját jogosultságait.", "Identity.OrganizationUnit.MaxUserMembershipCount": "A maximálisan megengedett szervezeti egység tagsági szám egy felhasználó számára", "ThisUserIsNotActiveMessage": "Ez a felhasználó nem aktív.", "Permission:IdentityManagement": "Identitáskezelés", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/is.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/is.json index dbd8914612..c0bb4af19a 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/is.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/is.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Ekki er hægt að eyða static hlutverkum.", "Volo.Abp.Identity:010007": "Þú getur ekki breytt tveggja þátta stillingu þinni.", "Volo.Abp.Identity:010008": "Það er ekki leyfilegt að breyta tvíþátta stillingu.", + "Volo.Abp.Identity:010009": "Þú getur ekki delegað þér sjálfum.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Hámarks leyfileg fjöldi aðildar að skipulagseiningu fyrir notanda", "ThisUserIsNotActiveMessage": "Þessi notandi er ekki virkur.", "Permission:IdentityManagement": "Auðkenninga umsjón", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/it.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/it.json index 5b559b039f..513def4b52 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/it.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/it.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "I ruoli statici non possono essere eliminati.", "Volo.Abp.Identity:010007": "Non puoi modificare l'impostazione dei due fattori.", "Volo.Abp.Identity:010008": "Non è consentito modificare l'impostazione a due fattori.", + "Volo.Abp.Identity:010009": "Non puoi delegare te stesso.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Numero massimo consentito di membri dell'unità organizzativa per un utente", "ThisUserIsNotActiveMessage": "Questo utente non è attivo.", "Permission:IdentityManagement": "Gestione identità", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/nl.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/nl.json index 496c65fdc8..472935418b 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/nl.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/nl.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Statische rollen kunnen niet worden verwijderd.", "Volo.Abp.Identity:010007": "U kunt uw instelling voor tweefactor authenticatie niet wijzigen.", "Volo.Abp.Identity:010008": "Het is niet toegestaan om de instelling van tweefactor authenticatie te wijzigen.", + "Volo.Abp.Identity:010009": "U kunt uzelf niet delegeren.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maximaal toegestande aantal lidmaatschappen van organisatie-eenheden voor een gebruiker", "ThisUserIsNotActiveMessage": "Deze gebruiker is niet actief.", "Permission:IdentityManagement": "Identiteitsbeheer", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pl-PL.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pl-PL.json index 59f8868c79..377c792ddf 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pl-PL.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pl-PL.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Statyczna rola nie może zostać usunięta.", "Volo.Abp.Identity:010007": "Nie możesz zmienić ustawienia dwóch czynników.", "Volo.Abp.Identity:010008": "Nie wolno zmieniać ustawienia dwuczynnikowego.", + "Volo.Abp.Identity:010009": "Nie możesz delegować swoich uprawnień.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maksymalna dozwolona liczba członków jednostki organizacyjnej dla użytkownika", "ThisUserIsNotActiveMessage": "Ten użytkownik nie jest aktywny.", "Permission:IdentityManagement": "Zarządzanie tożsamością", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pt-BR.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pt-BR.json index be6493d5f8..c8807d2792 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pt-BR.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/pt-BR.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Perfis estáticos não podem ser excluídos.", "Volo.Abp.Identity:010007": "Você não pode alterar sua configuração de dois fatores.", "Volo.Abp.Identity:010008": "Não é permitido alterar a configuração de dois fatores.", + "Volo.Abp.Identity:010009": "Você não pode delegar a si mesmo.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Contagem máxima permitida de membros da unidade organizacional para um usuário", "ThisUserIsNotActiveMessage": "Este usuário não está ativo.", "Permission:IdentityManagement": "Acessos", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ro-RO.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ro-RO.json index 789c4ededd..d86eb4f1fa 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ro-RO.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ro-RO.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Rolurile statice nu pot fi şterse.", "Volo.Abp.Identity:010007": "Nu vă puteţi schimba setările de autentificare în doi paşi.", "Volo.Abp.Identity:010008": "Nu este permisă modificarea setărilor autentificării în doi paşi.", + "Volo.Abp.Identity:010009": "Nu vă puteţi delega singur.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Numărul maxim de unităţi organizaţionale permise pentru un utilizator", "ThisUserIsNotActiveMessage": "Acest utilizator nu este activ.", "Permission:IdentityManagement": "Administrare identităţii", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ru.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ru.json index a3f1863e4f..73fd937af0 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ru.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/ru.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Статические роли не могут быть удалены.", "Volo.Abp.Identity:010007": "Вы не можете изменить настройку двух факторов.", "Volo.Abp.Identity:010008": "Изменение двухфакторной настройки не допускается.", + "Volo.Abp.Identity:010009": "Вы не можете делегировать свои собственные права.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Максимально допустимое количество членов организационного подразделения для пользователя", "ThisUserIsNotActiveMessage": "Этот пользователь не активен.", "Permission:IdentityManagement": "Управление идентификацией", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sk.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sk.json index 16b483103e..83eb3850ad 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sk.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sk.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Statické roly nie je možné zmazať.", "Volo.Abp.Identity:010007": "Dvojfaktorové nastavenie nie je možné zmeniť.", "Volo.Abp.Identity:010008": "Dvojfaktorové nastavenie nie je povolené zmeniť.", + "Volo.Abp.Identity:010009": "Nemôžete delegovať svoje vlastné oprávnenia.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Maximálny povolený počet členov organizačnej jednotky pre používateľa", "ThisUserIsNotActiveMessage": "Tento používateľ nie je aktívny.", "Permission:IdentityManagement": "Správa identít", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sl.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sl.json index 477d3ecf67..caa60a2d71 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sl.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/sl.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Statičnih vlog ni mogoče izbrisati.", "Volo.Abp.Identity:010007": "Nastavitve dveh faktorjev ne morete spremeniti.", "Volo.Abp.Identity:010008": "Ni dovoljeno spreminjati nastavitve dveh faktorjev.", + "Volo.Abp.Identity:010009": "Ne morete delegirati svojih pravic.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Največje dovoljeno število članov v organizacijski enoti za uporabnika", "ThisUserIsNotActiveMessage": "Ta uporabnik ni aktiven.", "Permission:IdentityManagement": "Upravljanje identitet", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/tr.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/tr.json index 44d2576299..c8957dc3e7 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/tr.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/tr.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Bir Sabit rol silinemez.", "Volo.Abp.Identity:010007": "İki faktörlü ayarınızı değiştiremezsiniz.", "Volo.Abp.Identity:010008": "İki faktörlü ayarın değiştirilmesine izin verilmez.", + "Volo.Abp.Identity:010009": "Kendinizi yetkilendiremezsiniz.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Bir kullanıcı için izin verilen en fazla organizasyon birimi sayısı", "ThisUserIsNotActiveMessage": "Bu kullanıcı aktif değil.", "Permission:IdentityManagement": "Kimlik yönetimi", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/vi.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/vi.json index 52b684d745..05dbe248a0 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/vi.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/vi.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "Vai trò này là cố định không được phép xóa.", "Volo.Abp.Identity:010007": "Bạn không thể thay đổi cài đặt hai yếu tố của mình.", "Volo.Abp.Identity:010008": "Không được phép thay đổi cài đặt hai yếu tố.", + "Volo.Abp.Identity:010009": "Bạn không thể ủy quyền cho chính mình.", "Identity.OrganizationUnit.MaxUserMembershipCount": "Số lượng thành viên đơn vị tổ chức tối đa được phép cho một người dùng", "ThisUserIsNotActiveMessage": "Người dùng này không hoạt động.", "Permission:IdentityManagement": "Quản lý danh tính", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hans.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hans.json index 4c63d24158..095f5cef2f 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hans.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hans.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "无法删除静态角色.", "Volo.Abp.Identity:010007": "你不能修改你的双因素身份验证设置", "Volo.Abp.Identity:010008": "不允许修改双因素身份验证设置.", + "Volo.Abp.Identity:010009": "你不能委托给自己.", "Identity.OrganizationUnit.MaxUserMembershipCount": "组织单位最大允许的成员资格计数", "ThisUserIsNotActiveMessage": "该用户不可用.", "Permission:IdentityManagement": "身份标识管理", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hant.json b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hant.json index 9767dbb3ea..936ad985f6 100644 --- a/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hant.json +++ b/modules/identity/src/Volo.Abp.Identity.Domain.Shared/Volo/Abp/Identity/Localization/zh-Hant.json @@ -71,6 +71,7 @@ "Volo.Abp.Identity:010006": "無法刪除靜態角色.", "Volo.Abp.Identity:010007": "你不能修改你的雙因素身份驗證設置", "Volo.Abp.Identity:010008": "不允許修改雙因素身份驗證設置.", + "Volo.Abp.Identity:010009": "你不能委派給自己", "Identity.OrganizationUnit.MaxUserMembershipCount": "允許一個使用者至多可隸屬在幾個組織單位", "ThisUserIsNotActiveMessage": "該用戶不可用.", "Permission:IdentityManagement": "身份識別管理", diff --git a/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IIdentityUserDelegationRepository.cs b/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IIdentityUserDelegationRepository.cs new file mode 100644 index 0000000000..360b9c494c --- /dev/null +++ b/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IIdentityUserDelegationRepository.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Threading; +using System.Threading.Tasks; +using Volo.Abp.Domain.Repositories; + +namespace Volo.Abp.Identity; + +public interface IIdentityUserDelegationRepository: IBasicRepository +{ + Task> GetListAsync( + Guid? sourceUserId, + Guid? targetUserId, + CancellationToken cancellationToken = default); + + Task> GetActiveDelegationsAsync( + Guid targetUserId, + CancellationToken cancellationToken = default); + + Task FindActiveDelegationByIdAsync( + Guid id, + CancellationToken cancellationToken = default); +} diff --git a/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityUserDelegation.cs b/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityUserDelegation.cs new file mode 100644 index 0000000000..8cab00f882 --- /dev/null +++ b/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityUserDelegation.cs @@ -0,0 +1,41 @@ +using System; +using Volo.Abp.Domain.Entities; +using Volo.Abp.MultiTenancy; + +namespace Volo.Abp.Identity; + +public class IdentityUserDelegation : BasicAggregateRoot, IMultiTenant +{ + public virtual Guid? TenantId { get; protected set; } + + public virtual Guid SourceUserId { get; protected set; } + + public virtual Guid TargetUserId { get; protected set; } + + public virtual DateTime StartTime { get; protected set; } + + public virtual DateTime EndTime { get; protected set; } + + /// + /// Initializes a new instance of . + /// + protected IdentityUserDelegation() + { + } + + public IdentityUserDelegation( + Guid id, + Guid sourceUserId, + Guid targetUserId, + DateTime startTime, + DateTime endTime, + Guid? tenantId = null) + : base(id) + { + TenantId = tenantId; + SourceUserId = sourceUserId; + TargetUserId = targetUserId; + StartTime = startTime; + EndTime = endTime; + } +} diff --git a/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityUserDelegationManager.cs b/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityUserDelegationManager.cs new file mode 100644 index 0000000000..8fd4c444f5 --- /dev/null +++ b/modules/identity/src/Volo.Abp.Identity.Domain/Volo/Abp/Identity/IdentityUserDelegationManager.cs @@ -0,0 +1,61 @@ +using System; +using System.Collections.Generic; +using System.Threading; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Volo.Abp.Identity; + +public class IdentityUserDelegationManager : DomainService +{ + protected IIdentityUserDelegationRepository IdentityUserDelegationRepository { get; } + + public IdentityUserDelegationManager(IIdentityUserDelegationRepository identityUserDelegationRepository) + { + IdentityUserDelegationRepository = identityUserDelegationRepository; + } + + public virtual async Task> GetListAsync(Guid? sourceUserId = null, Guid? targetUserId = null, CancellationToken cancellationToken = default) + { + return await IdentityUserDelegationRepository.GetListAsync(sourceUserId, targetUserId, cancellationToken: cancellationToken); + } + + public virtual async Task> GetActiveDelegationsAsync(Guid targetUseId, CancellationToken cancellationToken = default) + { + return await IdentityUserDelegationRepository.GetActiveDelegationsAsync(targetUseId, cancellationToken: cancellationToken); + } + + public virtual async Task FindActiveDelegationByIdAsync(Guid id, CancellationToken cancellationToken = default) + { + return await IdentityUserDelegationRepository.FindActiveDelegationByIdAsync(id, cancellationToken: cancellationToken); + } + + public virtual async Task DelegateNewUserAsync(Guid sourceUserId, Guid targetUserId, DateTime startTime, DateTime endTime, CancellationToken cancellationToken = default) + { + if (sourceUserId == targetUserId) + { + throw new BusinessException(IdentityErrorCodes.YouCannotDelegateYourself); + } + + await IdentityUserDelegationRepository.InsertAsync( + new IdentityUserDelegation( + GuidGenerator.Create(), + sourceUserId, + targetUserId, + startTime, + endTime + ), + cancellationToken: cancellationToken + ); + } + + public virtual async Task DeleteDelegationAsync(Guid id, Guid sourceUserId, CancellationToken cancellationToken = default) + { + var delegation = await IdentityUserDelegationRepository.FindAsync(id, cancellationToken: cancellationToken); + + if (delegation != null && delegation.SourceUserId == sourceUserId) + { + await IdentityUserDelegationRepository.DeleteAsync(delegation, cancellationToken: cancellationToken); + } + } +} diff --git a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/AbpIdentityEntityFrameworkCoreModule.cs b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/AbpIdentityEntityFrameworkCoreModule.cs index 4bfa96d253..a58a73a996 100644 --- a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/AbpIdentityEntityFrameworkCoreModule.cs +++ b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/AbpIdentityEntityFrameworkCoreModule.cs @@ -19,6 +19,7 @@ public class AbpIdentityEntityFrameworkCoreModule : AbpModule options.AddRepository(); options.AddRepository(); options.AddRepository(); + options.AddRepository(); }); } } diff --git a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/EfCoreIdentityUserDelegationRepository.cs b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/EfCoreIdentityUserDelegationRepository.cs new file mode 100644 index 0000000000..cd567ffa80 --- /dev/null +++ b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/EfCoreIdentityUserDelegationRepository.cs @@ -0,0 +1,52 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.Domain.Repositories.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Volo.Abp.Timing; + +namespace Volo.Abp.Identity.EntityFrameworkCore; + +public class EfCoreIdentityUserDelegationRepository : EfCoreRepository, IIdentityUserDelegationRepository +{ + protected IClock Clock { get; } + + public EfCoreIdentityUserDelegationRepository(IDbContextProvider dbContextProvider, IClock clock) + : base(dbContextProvider) + { + Clock = clock; + } + + public async Task> GetListAsync(Guid? sourceUserId, Guid? targetUserId, CancellationToken cancellationToken = default) + { + return await (await GetDbSetAsync()) + .AsNoTracking() + .WhereIf(sourceUserId.HasValue, x => x.SourceUserId == sourceUserId) + .WhereIf(targetUserId.HasValue, x => x.TargetUserId == targetUserId) + .ToListAsync(cancellationToken: cancellationToken); + } + + public async Task> GetActiveDelegationsAsync(Guid targetUserId, CancellationToken cancellationToken = default) + { + return await (await GetDbSetAsync()) + .AsNoTracking() + .Where(x => x.TargetUserId == targetUserId && + x.StartTime <= Clock.Now && + x.EndTime >= Clock.Now) + .ToListAsync(cancellationToken: cancellationToken); + } + + public async Task FindActiveDelegationByIdAsync(Guid id, CancellationToken cancellationToken = default) + { + return await (await GetDbSetAsync()) + .AsNoTracking() + .FirstOrDefaultAsync(x => + x.Id == id && + x.StartTime <= Clock.Now && + x.EndTime >= Clock.Now + , cancellationToken: GetCancellationToken(cancellationToken)); + } +} diff --git a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IIdentityDbContext.cs b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IIdentityDbContext.cs index e84b2811c5..2f409a61b2 100644 --- a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IIdentityDbContext.cs +++ b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IIdentityDbContext.cs @@ -18,4 +18,6 @@ public interface IIdentityDbContext : IEfCoreDbContext DbSet SecurityLogs { get; } DbSet LinkUsers { get; } + + DbSet UserDelegations { get; } } diff --git a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContext.cs b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContext.cs index bc2b4dd4b0..79adece5e1 100644 --- a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContext.cs +++ b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContext.cs @@ -22,6 +22,8 @@ public class IdentityDbContext : AbpDbContext, IIdentityDbCon public DbSet LinkUsers { get; set; } + public DbSet UserDelegations { get; set; } + public IdentityDbContext(DbContextOptions options) : base(options) { diff --git a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContextModelBuilderExtensions.cs b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContextModelBuilderExtensions.cs index 472581fdbd..f85f72e84e 100644 --- a/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContextModelBuilderExtensions.cs +++ b/modules/identity/src/Volo.Abp.Identity.EntityFrameworkCore/Volo/Abp/Identity/EntityFrameworkCore/IdentityDbContextModelBuilderExtensions.cs @@ -270,6 +270,15 @@ public static class IdentityDbContextModelBuilderExtensions }); } + builder.Entity(b => + { + b.ToTable(AbpIdentityDbProperties.DbTablePrefix + "UserDelegations", AbpIdentityDbProperties.DbSchema); + + b.ConfigureByConvention(); + + b.ApplyObjectExtensionMappings(); + }); + builder.TryConfigureObjectExtensions(); } } diff --git a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContext.cs b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContext.cs index 1acc952024..90118a534e 100644 --- a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContext.cs +++ b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContext.cs @@ -19,6 +19,8 @@ public class AbpIdentityMongoDbContext : AbpMongoDbContext, IAbpIdentityMongoDbC public IMongoCollection LinkUsers => Collection(); + public IMongoCollection UserDelegations => Collection(); + protected override void CreateModel(IMongoModelBuilder modelBuilder) { base.CreateModel(modelBuilder); diff --git a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContextExtensions.cs b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContextExtensions.cs index 4816664d68..5ee7ffc47e 100644 --- a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContextExtensions.cs +++ b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbContextExtensions.cs @@ -37,5 +37,10 @@ public static class AbpIdentityMongoDbContextExtensions { b.CollectionName = AbpIdentityDbProperties.DbTablePrefix + "LinkUsers"; }); + + builder.Entity(b => + { + b.CollectionName = AbpIdentityDbProperties.DbTablePrefix + "UserDelegations"; + }); } } diff --git a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbModule.cs b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbModule.cs index 85fc619180..35c81b25bb 100644 --- a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbModule.cs +++ b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/AbpIdentityMongoDbModule.cs @@ -20,6 +20,7 @@ public class AbpIdentityMongoDbModule : AbpModule options.AddRepository(); options.AddRepository(); options.AddRepository(); + options.AddRepository(); }); } } diff --git a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/IAbpIdentityMongoDbContext.cs b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/IAbpIdentityMongoDbContext.cs index ad2ae429e1..39bcc23b50 100644 --- a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/IAbpIdentityMongoDbContext.cs +++ b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/IAbpIdentityMongoDbContext.cs @@ -18,4 +18,6 @@ public interface IAbpIdentityMongoDbContext : IAbpMongoDbContext IMongoCollection SecurityLogs { get; } IMongoCollection LinkUsers { get; } + + IMongoCollection UserDelegations { get; } } diff --git a/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/MongoIdentityUserDelegationRepository.cs b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/MongoIdentityUserDelegationRepository.cs new file mode 100644 index 0000000000..a782dd57c9 --- /dev/null +++ b/modules/identity/src/Volo.Abp.Identity.MongoDB/Volo/Abp/Identity/MongoDB/MongoIdentityUserDelegationRepository.cs @@ -0,0 +1,52 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading; +using System.Threading.Tasks; +using MongoDB.Driver; +using MongoDB.Driver.Linq; +using Volo.Abp.Domain.Repositories.MongoDB; +using Volo.Abp.MongoDB; +using Volo.Abp.Timing; + +namespace Volo.Abp.Identity.MongoDB; + +public class MongoIdentityUserDelegationRepository : MongoDbRepository, IIdentityUserDelegationRepository +{ + protected IClock Clock { get; } + + public MongoIdentityUserDelegationRepository(IMongoDbContextProvider dbContextProvider, IClock clock) + : base(dbContextProvider) + { + Clock = clock; + } + + public async Task> GetListAsync(Guid? sourceUserId, Guid? targetUserId, + CancellationToken cancellationToken = default) + { + return await (await GetMongoQueryableAsync(cancellationToken)) + .WhereIf(sourceUserId.HasValue, x => x.SourceUserId == sourceUserId) + .WhereIf(targetUserId.HasValue, x => x.TargetUserId == targetUserId) + .As>() + .ToListAsync(cancellationToken: cancellationToken); + } + + public async Task> GetActiveDelegationsAsync(Guid targetUserId, CancellationToken cancellationToken = default) + { + return await (await GetMongoQueryableAsync(cancellationToken)) + .Where(x => x.TargetUserId == targetUserId) + .Where(x => x.StartTime <= Clock.Now && x.EndTime >= Clock.Now) + .As>() + .ToListAsync(cancellationToken: cancellationToken); + } + + public async Task FindActiveDelegationByIdAsync(Guid id, CancellationToken cancellationToken = default) + { + return await (await GetMongoQueryableAsync(cancellationToken)) + .FirstOrDefaultAsync(x => + x.Id == id && + x.StartTime <= Clock.Now && + x.EndTime >= Clock.Now + , cancellationToken: GetCancellationToken(cancellationToken)); + } +} diff --git a/modules/identity/test/Volo.Abp.Identity.Domain.Tests/Volo/Abp/Identity/IdentityUserDelegationManager_Tests.cs b/modules/identity/test/Volo.Abp.Identity.Domain.Tests/Volo/Abp/Identity/IdentityUserDelegationManager_Tests.cs new file mode 100644 index 0000000000..c85f17230f --- /dev/null +++ b/modules/identity/test/Volo.Abp.Identity.Domain.Tests/Volo/Abp/Identity/IdentityUserDelegationManager_Tests.cs @@ -0,0 +1,69 @@ +using System; +using System.Threading.Tasks; +using Shouldly; +using Xunit; + +namespace Volo.Abp.Identity; + +public class IdentityUserDelegationManager_Tests : AbpIdentityDomainTestBase +{ + protected IdentityUserDelegationManager IdentityUserDelegationManager { get; } + protected IdentityTestData TestData { get; } + + public IdentityUserDelegationManager_Tests() + { + IdentityUserDelegationManager = GetRequiredService(); + TestData = GetRequiredService(); + } + + [Fact] + public async Task GetListAsync() + { + (await IdentityUserDelegationManager.GetListAsync(Guid.NewGuid(), Guid.NewGuid())).Count.ShouldBe(0); + + (await IdentityUserDelegationManager.GetListAsync(TestData.UserJohnId, null)).Count.ShouldBe(2); + + (await IdentityUserDelegationManager.GetListAsync(null, TestData.UserDavidId)).Count.ShouldBe(3); + + (await IdentityUserDelegationManager.GetListAsync(TestData.UserNeoId, TestData.UserDavidId)).Count.ShouldBe(1); + } + + [Fact] + public async Task GetActiveDelegationsAsync() + { + var activeDelegations = await IdentityUserDelegationManager.GetActiveDelegationsAsync(TestData.UserDavidId); + activeDelegations.Count.ShouldBe(2); + activeDelegations[0].SourceUserId.ShouldBe(TestData.UserJohnId); + activeDelegations[0].TargetUserId.ShouldBe(TestData.UserDavidId); + activeDelegations[1].SourceUserId.ShouldBe(TestData.UserNeoId); + activeDelegations[1].TargetUserId.ShouldBe(TestData.UserDavidId); + } + + [Fact] + public async Task FindActiveDelegationByIdAsync() + { + var activeDelegations = await IdentityUserDelegationManager.GetActiveDelegationsAsync(TestData.UserDavidId); + var activeDelegation = await IdentityUserDelegationManager.FindActiveDelegationByIdAsync(activeDelegations[0].Id); + activeDelegation.ShouldNotBeNull(); + activeDelegation.SourceUserId.ShouldBe(TestData.UserJohnId); + activeDelegation.TargetUserId.ShouldBe(TestData.UserDavidId); + } + + [Fact] + public async Task DelegateNewUserAsync() + { + await Should.ThrowAsync(IdentityUserDelegationManager.DelegateNewUserAsync( + TestData.UserJohnId, + TestData.UserJohnId, + DateTime.Now.AddDays(-1), + DateTime.Now)); + + await IdentityUserDelegationManager.DelegateNewUserAsync( + TestData.UserJohnId, + TestData.UserBobId, + DateTime.Now.AddDays(-1), + DateTime.Now.AddDays(1)); + + (await IdentityUserDelegationManager.GetActiveDelegationsAsync(TestData.UserBobId)).Count.ShouldBe(1); + } +} \ No newline at end of file diff --git a/modules/identity/test/Volo.Abp.Identity.EntityFrameworkCore.Tests/Volo/Abp/Identity/EntityFrameworkCore/IdentityUserDelegationepository_Tests.cs b/modules/identity/test/Volo.Abp.Identity.EntityFrameworkCore.Tests/Volo/Abp/Identity/EntityFrameworkCore/IdentityUserDelegationepository_Tests.cs new file mode 100644 index 0000000000..92648defe7 --- /dev/null +++ b/modules/identity/test/Volo.Abp.Identity.EntityFrameworkCore.Tests/Volo/Abp/Identity/EntityFrameworkCore/IdentityUserDelegationepository_Tests.cs @@ -0,0 +1,6 @@ +namespace Volo.Abp.Identity.EntityFrameworkCore; + +public class IdentityUserDelegationepository_Tests : IdentityUserDelegationepository_Tests +{ + +} \ No newline at end of file diff --git a/modules/identity/test/Volo.Abp.Identity.MongoDB.Tests/Volo/Abp/Identity/MongoDB/IdentityUserDelegationepository_Tests.cs b/modules/identity/test/Volo.Abp.Identity.MongoDB.Tests/Volo/Abp/Identity/MongoDB/IdentityUserDelegationepository_Tests.cs new file mode 100644 index 0000000000..5fb94b614a --- /dev/null +++ b/modules/identity/test/Volo.Abp.Identity.MongoDB.Tests/Volo/Abp/Identity/MongoDB/IdentityUserDelegationepository_Tests.cs @@ -0,0 +1,9 @@ +using Xunit; + +namespace Volo.Abp.Identity.MongoDB; + +[Collection(MongoTestCollection.Name)] +public class IdentityUserDelegationepository_Tests: IdentityUserDelegationepository_Tests +{ + +} \ No newline at end of file diff --git a/modules/identity/test/Volo.Abp.Identity.TestBase/Volo/Abp/Identity/AbpIdentityTestDataBuilder.cs b/modules/identity/test/Volo.Abp.Identity.TestBase/Volo/Abp/Identity/AbpIdentityTestDataBuilder.cs index 788f974b5e..dc2b28690a 100644 --- a/modules/identity/test/Volo.Abp.Identity.TestBase/Volo/Abp/Identity/AbpIdentityTestDataBuilder.cs +++ b/modules/identity/test/Volo.Abp.Identity.TestBase/Volo/Abp/Identity/AbpIdentityTestDataBuilder.cs @@ -22,6 +22,7 @@ public class AbpIdentityTestDataBuilder : ITransientDependency private readonly OrganizationUnitManager _organizationUnitManager; private readonly IIdentityLinkUserRepository _identityLinkUserRepository; private readonly IdentityLinkUserManager _identityLinkUserManager; + private readonly IIdentityUserDelegationRepository _identityUserDelegationRepository; private IdentityRole _adminRole; private IdentityRole _moderatorRole; @@ -42,7 +43,8 @@ public class AbpIdentityTestDataBuilder : ITransientDependency IdentityTestData testData, OrganizationUnitManager organizationUnitManager, IIdentityLinkUserRepository identityLinkUserRepository, - IdentityLinkUserManager identityLinkUserManager) + IdentityLinkUserManager identityLinkUserManager, + IIdentityUserDelegationRepository identityUserDelegationRepository) { _guidGenerator = guidGenerator; _userRepository = userRepository; @@ -55,6 +57,7 @@ public class AbpIdentityTestDataBuilder : ITransientDependency _organizationUnitManager = organizationUnitManager; _identityLinkUserRepository = identityLinkUserRepository; _identityLinkUserManager = identityLinkUserManager; + _identityUserDelegationRepository = identityUserDelegationRepository; _identitySecurityLogRepository = identitySecurityLogRepository; } @@ -66,6 +69,7 @@ public class AbpIdentityTestDataBuilder : ITransientDependency await AddLinkUsers(); await AddClaimTypes(); await AddSecurityLogs(); + await AddUserDelegations(); } private async Task AddRoles() @@ -197,4 +201,28 @@ public class AbpIdentityTestDataBuilder : ITransientDependency CreationTime = new DateTime(2020, 01, 02, 10, 0, 0) })); } + + private async Task AddUserDelegations() + { + await _identityUserDelegationRepository.InsertAsync( + new IdentityUserDelegation(_guidGenerator.Create(), + _testData.UserJohnId, + _testData.UserDavidId, + DateTime.Now.AddDays(-2), + DateTime.Now.AddDays(-1))); + + await _identityUserDelegationRepository.InsertAsync( + new IdentityUserDelegation(_guidGenerator.Create(), + _testData.UserJohnId, + _testData.UserDavidId, + DateTime.Now.AddDays(-1), + DateTime.Now.AddDays(1))); + + await _identityUserDelegationRepository.InsertAsync( + new IdentityUserDelegation(_guidGenerator.Create(), + _testData.UserNeoId, + _testData.UserDavidId, + DateTime.Now.AddDays(-1), + DateTime.Now.AddDays(1))); + } } diff --git a/modules/identity/test/Volo.Abp.Identity.TestBase/Volo/Abp/Identity/IdentityUserDelegationepository_Tests.cs b/modules/identity/test/Volo.Abp.Identity.TestBase/Volo/Abp/Identity/IdentityUserDelegationepository_Tests.cs new file mode 100644 index 0000000000..50d5dd8a6f --- /dev/null +++ b/modules/identity/test/Volo.Abp.Identity.TestBase/Volo/Abp/Identity/IdentityUserDelegationepository_Tests.cs @@ -0,0 +1,55 @@ +using System; +using System.Threading.Tasks; +using Shouldly; +using Volo.Abp.Modularity; +using Xunit; + +namespace Volo.Abp.Identity; + +public abstract class IdentityUserDelegationepository_Tests : AbpIdentityTestBase + where TStartupModule : IAbpModule +{ + protected IIdentityUserRepository UserRepository { get; } + protected IIdentityUserDelegationRepository IdentityUserDelegationRepository { get; } + protected IdentityTestData TestData { get; } + + public IdentityUserDelegationepository_Tests() + { + UserRepository = GetRequiredService(); + IdentityUserDelegationRepository = GetRequiredService(); + TestData = GetRequiredService(); + } + + [Fact] + public async Task GetListAsync() + { + (await IdentityUserDelegationRepository.GetListAsync(Guid.NewGuid(), Guid.NewGuid())).Count.ShouldBe(0); + + (await IdentityUserDelegationRepository.GetListAsync(TestData.UserJohnId, null)).Count.ShouldBe(2); + + (await IdentityUserDelegationRepository.GetListAsync(null, TestData.UserDavidId)).Count.ShouldBe(3); + + (await IdentityUserDelegationRepository.GetListAsync(TestData.UserNeoId, TestData.UserDavidId)).Count.ShouldBe(1); + } + + [Fact] + public async Task GetActiveDelegationsAsync() + { + var activeDelegations = await IdentityUserDelegationRepository.GetActiveDelegationsAsync(TestData.UserDavidId); + activeDelegations.Count.ShouldBe(2); + activeDelegations[0].SourceUserId.ShouldBe(TestData.UserJohnId); + activeDelegations[0].TargetUserId.ShouldBe(TestData.UserDavidId); + activeDelegations[1].SourceUserId.ShouldBe(TestData.UserNeoId); + activeDelegations[1].TargetUserId.ShouldBe(TestData.UserDavidId); + } + + [Fact] + public async Task GetActiveDelegationOrNullAsync() + { + var activeDelegations = await IdentityUserDelegationRepository.GetActiveDelegationsAsync(TestData.UserDavidId); + var activeDelegation = await IdentityUserDelegationRepository.FindActiveDelegationByIdAsync(activeDelegations[0].Id); + activeDelegation.ShouldNotBeNull(); + activeDelegation.SourceUserId.ShouldBe(TestData.UserJohnId); + activeDelegation.TargetUserId.ShouldBe(TestData.UserDavidId); + } +} \ No newline at end of file diff --git a/modules/openiddict/app/OpenIddict.Demo.Client.Mvc/Pages/Index.cshtml b/modules/openiddict/app/OpenIddict.Demo.Client.Mvc/Pages/Index.cshtml index d2f8710862..ca7e62a411 100644 --- a/modules/openiddict/app/OpenIddict.Demo.Client.Mvc/Pages/Index.cshtml +++ b/modules/openiddict/app/OpenIddict.Demo.Client.Mvc/Pages/Index.cshtml @@ -9,7 +9,7 @@
Login - Loout + Logout @if (HttpContext.User.Identity != null && HttpContext.User.Identity.IsAuthenticated) { diff --git a/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230307054116_Initial.Designer.cs b/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230404033745_Initial.Designer.cs similarity index 99% rename from modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230307054116_Initial.Designer.cs rename to modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230404033745_Initial.Designer.cs index bc14c07aec..34487a75a8 100644 --- a/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230307054116_Initial.Designer.cs +++ b/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230404033745_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace OpenIddict.Demo.Server.Migrations { [DbContext(typeof(ServerDbContext))] - [Migration("20230307054116_Initial")] + [Migration("20230404033745_Initial")] partial class Initial { /// @@ -455,6 +455,9 @@ namespace OpenIddict.Demo.Server.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("LastModifierId"); + b.Property("LastPasswordChangeTime") + .HasColumnType("datetimeoffset"); + b.Property("LockoutEnabled") .ValueGeneratedOnAdd() .HasColumnType("bit") diff --git a/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230307054116_Initial.cs b/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230404033745_Initial.cs similarity index 99% rename from modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230307054116_Initial.cs rename to modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230404033745_Initial.cs index ab3646a62c..611109065a 100644 --- a/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230307054116_Initial.cs +++ b/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/20230404033745_Initial.cs @@ -283,6 +283,7 @@ namespace OpenIddict.Demo.Server.Migrations AccessFailedCount = table.Column(type: "int", nullable: false, defaultValue: 0), ShouldChangePasswordOnNextLogin = table.Column(type: "bit", nullable: false), EntityVersion = table.Column(type: "int", nullable: false), + LastPasswordChangeTime = table.Column(type: "datetimeoffset", nullable: true), ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), CreationTime = table.Column(type: "datetime2", nullable: false), diff --git a/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/ServerDbContextModelSnapshot.cs b/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/ServerDbContextModelSnapshot.cs index f5e599fe73..6dcdccdd99 100644 --- a/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/ServerDbContextModelSnapshot.cs +++ b/modules/openiddict/app/OpenIddict.Demo.Server/Migrations/ServerDbContextModelSnapshot.cs @@ -452,6 +452,9 @@ namespace OpenIddict.Demo.Server.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("LastModifierId"); + b.Property("LastPasswordChangeTime") + .HasColumnType("datetimeoffset"); + b.Property("LockoutEnabled") .ValueGeneratedOnAdd() .HasColumnType("bit") diff --git a/modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Volo/Abp/OpenIddict/AbpOpenIddictAspNetCoreModule.cs b/modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Volo/Abp/OpenIddict/AbpOpenIddictAspNetCoreModule.cs index 8a664da5c1..3ee5dbf126 100644 --- a/modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Volo/Abp/OpenIddict/AbpOpenIddictAspNetCoreModule.cs +++ b/modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Volo/Abp/OpenIddict/AbpOpenIddictAspNetCoreModule.cs @@ -5,6 +5,7 @@ using OpenIddict.Server; using Volo.Abp.AspNetCore.MultiTenancy; using Volo.Abp.AspNetCore.Mvc.UI.Theme.Shared; using Volo.Abp.Modularity; +using Volo.Abp.OpenIddict.Scopes; using Volo.Abp.OpenIddict.WildcardDomains; using Volo.Abp.Security.Claims; @@ -133,6 +134,7 @@ public class AbpOpenIddictAspNetCoreModule : AbpModule } builder.AddEventHandler(RemoveClaimsFromClientCredentialsGrantType.Descriptor); + builder.AddEventHandler(AttachScopes.Descriptor); services.ExecutePreConfiguredActions(builder); }); diff --git a/modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Volo/Abp/OpenIddict/Scopes/AttachScopes.cs b/modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Volo/Abp/OpenIddict/Scopes/AttachScopes.cs new file mode 100644 index 0000000000..75401ada2b --- /dev/null +++ b/modules/openiddict/src/Volo.Abp.OpenIddict.AspNetCore/Volo/Abp/OpenIddict/Scopes/AttachScopes.cs @@ -0,0 +1,34 @@ +using System; +using System.Linq; +using System.Threading.Tasks; +using OpenIddict.Server; + +namespace Volo.Abp.OpenIddict.Scopes; + +public class AttachScopes : IOpenIddictServerHandler +{ + public static OpenIddictServerHandlerDescriptor Descriptor { get; } + = OpenIddictServerHandlerDescriptor.CreateBuilder() + .UseSingletonHandler() + .SetOrder(OpenIddictServerHandlers.Discovery.AttachScopes.Descriptor.Order + 1) + .SetType(OpenIddictServerHandlerType.Custom) + .Build(); + + private readonly IOpenIddictScopeRepository _scopeRepository; + + public AttachScopes(IOpenIddictScopeRepository scopeRepository) + { + _scopeRepository = scopeRepository; + } + + public async ValueTask HandleAsync(OpenIddictServerEvents.HandleConfigurationRequestContext context) + { + if (context is null) + { + throw new ArgumentNullException(nameof(context)); + } + + var scopes = await _scopeRepository.GetListAsync(); + context.Scopes.UnionWith(scopes.Select(x => x.Name)); + } +} diff --git a/modules/permission-management/src/Volo.Abp.PermissionManagement.Blazor/Components/PermissionManagementModal.razor.cs b/modules/permission-management/src/Volo.Abp.PermissionManagement.Blazor/Components/PermissionManagementModal.razor.cs index aed63fb8e1..7096fa4ac8 100644 --- a/modules/permission-management/src/Volo.Abp.PermissionManagement.Blazor/Components/PermissionManagementModal.razor.cs +++ b/modules/permission-management/src/Volo.Abp.PermissionManagement.Blazor/Components/PermissionManagementModal.razor.cs @@ -260,6 +260,6 @@ public partial class PermissionManagementModal var permissions = group.Permissions; var grantedProviders = permissions.SelectMany(x => x.GrantedProviders); - return permissions.All(x => x.IsGranted) && grantedProviders.All(p => p.ProviderName != _providerName); + return permissions.All(x => x.IsGranted) && grantedProviders.Any(p => p.ProviderName != _providerName); } } diff --git a/npm/ng-packs/package.json b/npm/ng-packs/package.json index 7f1bdd633b..5d95c63991 100644 --- a/npm/ng-packs/package.json +++ b/npm/ng-packs/package.json @@ -34,8 +34,8 @@ "build:schematics": "cd scripts && yarn && yarn build:schematics && cd ..", "dev:schematics": "tsc -p packages/schematics/tsconfig.json -w", "mock:schematics": "cd scripts/mock-schematic && yarn && yarn start", - "debug:schematics": "./node_modules/.bin/ng g ./packages/schematics/src/collection.json:proxy-add --module __default --apiName __default --source __default --target __default --url https://localhost:44305 --serviceType application", - "debug:schematics-dist": "./node_modules/.bin/ng g ./dist/packages/schematics/collection.json:proxy-add --module __default --apiName __default --source __default --target __default --url http://localhost:4300 --service-type application", + "debug:schematics": "./node_modules/.bin/ng g ./packages/schematics/src/collection.json:proxy-add --module __default --apiName __default --source __default --target __default --url https://localhost:44305 --serviceType application --entryPoint __default ", + "debug:schematics-dist": "./node_modules/.bin/ng g ./dist/packages/schematics/collection.json:proxy-add --module __default --apiName __default --source __default --target __default --url http://localhost:4300 --service-type application --entryPoint __default", "ci": "yarn affected:lint && yarn affected:build && yarn affected:test", "lerna": "lerna", "migrate-nx": "yarn nx migrate --run-migrations", @@ -139,4 +139,4 @@ "npx prettier --write --config .prettierrc " ] } -} \ No newline at end of file +} diff --git a/npm/ng-packs/packages/core/src/lib/models/rest.ts b/npm/ng-packs/packages/core/src/lib/models/rest.ts index c5517ffa98..74cc3407f0 100644 --- a/npm/ng-packs/packages/core/src/lib/models/rest.ts +++ b/npm/ng-packs/packages/core/src/lib/models/rest.ts @@ -4,6 +4,7 @@ export namespace Rest { export type Config = Partial<{ apiName: string; skipHandleError: boolean; + skipAddingHeader: boolean; observe: Observe; httpParamEncoder?: HttpParameterCodec; }>; diff --git a/npm/ng-packs/packages/core/src/lib/services/rest.service.ts b/npm/ng-packs/packages/core/src/lib/services/rest.service.ts index e9a6e89851..a7ee7a491b 100644 --- a/npm/ng-packs/packages/core/src/lib/services/rest.service.ts +++ b/npm/ng-packs/packages/core/src/lib/services/rest.service.ts @@ -2,6 +2,7 @@ import { HttpClient, HttpParameterCodec, HttpParams, HttpRequest } from '@angula import { Inject, Injectable } from '@angular/core'; import { Observable, throwError } from 'rxjs'; import { catchError } from 'rxjs/operators'; +import { ExternalHttpClient } from '../clients/http.client'; import { ABP } from '../models/common'; import { Rest } from '../models/rest'; import { CORE_OPTIONS } from '../tokens/options.token'; @@ -16,6 +17,7 @@ export class RestService { constructor( @Inject(CORE_OPTIONS) protected options: ABP.Root, protected http: HttpClient, + protected externalHttp: ExternalHttpClient, protected environment: EnvironmentService, protected httpErrorReporter: HttpErrorReporterService, ) {} @@ -39,7 +41,9 @@ export class RestService { const { method, params, ...options } = request; const { observe = Rest.Observe.Body, skipHandleError } = config; const url = this.removeDuplicateSlashes(api + request.url); - return this.http + + const httpClient: HttpClient = this.getHttpClient(config.skipAddingHeader); + return httpClient .request(method, url, { observe, ...(params && { @@ -49,6 +53,9 @@ export class RestService { } as any) .pipe(catchError(err => (skipHandleError ? throwError(err) : this.handleError(err)))); } + private getHttpClient(isExternal: boolean) { + return isExternal ? this.externalHttp : this.http; + } private getParams(params: Rest.Params, encoder?: HttpParameterCodec): HttpParams { const filteredParams = Object.entries(params).reduce((acc, [key, value]) => { diff --git a/npm/ng-packs/packages/core/src/lib/tests/safe-html.pipe.spec.ts b/npm/ng-packs/packages/core/src/lib/tests/safe-html.pipe.spec.ts index 840cf614db..34d372ebbb 100644 --- a/npm/ng-packs/packages/core/src/lib/tests/safe-html.pipe.spec.ts +++ b/npm/ng-packs/packages/core/src/lib/tests/safe-html.pipe.spec.ts @@ -29,6 +29,6 @@ describe('SafeHtmlPipe', () => { it('should sanitize unsafe HTML content', () => { const input = `

Click here!

`; const result = pipe.transform(input); - expect(result).toBe(`

Click here!

`); + expect(result).toBe(`

Click here!

`); }); }); diff --git a/npm/ng-packs/packages/core/testing/src/lib/services/mock-rest.service.ts b/npm/ng-packs/packages/core/testing/src/lib/services/mock-rest.service.ts index 65e1763817..7fd171c1d4 100644 --- a/npm/ng-packs/packages/core/testing/src/lib/services/mock-rest.service.ts +++ b/npm/ng-packs/packages/core/testing/src/lib/services/mock-rest.service.ts @@ -2,6 +2,7 @@ import { ABP, CORE_OPTIONS, EnvironmentService, + ExternalHttpClient, HttpErrorReporterService, RestService, } from '@abp/ng.core'; @@ -16,9 +17,10 @@ export class MockRestService extends RestService { constructor( @Inject(CORE_OPTIONS) protected options: ABP.Root, protected http: HttpClient, + protected externalhttp: ExternalHttpClient, protected environment: EnvironmentService, ) { - super(options, http, environment, null as unknown as HttpErrorReporterService); + super(options, http,externalhttp, environment, null as unknown as HttpErrorReporterService); } handleError(err: any): Observable { diff --git a/npm/ng-packs/packages/schematics/src/commands/api/files-service/proxy/__namespace@dir__/__name@kebab__.service.ts.template b/npm/ng-packs/packages/schematics/src/commands/api/files-service/proxy/__namespace@dir__/__name@kebab__.service.ts.template index 1e1cc4564a..aae3b43471 100644 --- a/npm/ng-packs/packages/schematics/src/commands/api/files-service/proxy/__namespace@dir__/__name@kebab__.service.ts.template +++ b/npm/ng-packs/packages/schematics/src/commands/api/files-service/proxy/__namespace@dir__/__name@kebab__.service.ts.template @@ -25,7 +25,7 @@ export class <%= name %>Service { if (body.body) { %> body: <%= body.body %>,<% } %> }, - { apiName: this.apiName });<% } %> + { apiName: this.apiName,...config });<% } %> constructor(private restService: RestService) {} } diff --git a/npm/ng-packs/packages/schematics/src/utils/service.ts b/npm/ng-packs/packages/schematics/src/utils/service.ts index 28ce82e3f7..0b633a8dd5 100644 --- a/npm/ng-packs/packages/schematics/src/utils/service.ts +++ b/npm/ng-packs/packages/schematics/src/utils/service.ts @@ -22,7 +22,7 @@ import { } from './type'; import { eBindingSourceId } from '../enums'; import { camelizeHyphen } from './text'; -import {VOLO_REMOTE_STREAM_CONTENT} from "../constants"; +import { VOLO_REMOTE_STREAM_CONTENT } from '../constants'; export function serializeParameters(parameters: Property[]) { return parameters.map(p => p.name + p.optional + ': ' + p.type + p.default, '').join(', '); @@ -39,9 +39,12 @@ export function createControllerToServiceMapper({ const name = controller.controllerName; const namespace = parseNamespace(solution, controller.type); const actions = Object.values(controller.actions); - const typeWithoutIRemoteStreamContent = getTypesWithoutIRemoteStreamContent(types) - const imports = actions.reduce(createActionToImportsReducer(solution, typeWithoutIRemoteStreamContent, namespace), []); - imports.push(new Import({ path: '@abp/ng.core', specifiers: ['RestService'] })); + const typeWithoutIRemoteStreamContent = getTypesWithoutIRemoteStreamContent(types); + const imports = actions.reduce( + createActionToImportsReducer(solution, typeWithoutIRemoteStreamContent, namespace), + [], + ); + imports.push(new Import({ path: '@abp/ng.core', specifiers: ['RestService', 'Rest'] })); imports.push(new Import({ path: '@angular/core', specifiers: ['Injectable'] })); sortImports(imports); const methods = actions.map(mapActionToMethod); @@ -51,9 +54,9 @@ export function createControllerToServiceMapper({ } function getTypesWithoutIRemoteStreamContent(types: Record) { - const newType = {...types} - delete newType[VOLO_REMOTE_STREAM_CONTENT] - return newType + const newType = { ...types }; + delete newType[VOLO_REMOTE_STREAM_CONTENT]; + return newType; } function sortMethods(methods: Method[]) { methods.sort((a, b) => (a.signature.name > b.signature.name ? 1 : -1)); @@ -76,7 +79,7 @@ export function createActionToBodyMapper() { return ({ httpMethod, parameters, returnValue, url }: Action) => { const responseType = adaptType(returnValue.typeSimple); const responseTypeWithNamespace = returnValue.typeSimple; - const body = new Body({ method: httpMethod, responseType, url ,responseTypeWithNamespace}); + const body = new Body({ method: httpMethod, responseType, url, responseTypeWithNamespace }); parameters.forEach(body.registerActionParameter); @@ -90,6 +93,8 @@ export function createActionToSignatureMapper() { return (action: Action) => { const signature = new Signature({ name: getMethodNameFromAction(action) }); const versionParameter = getVersionParameter(action); + const restConfig = new Property({ name: 'config', type: 'Partial' }); + restConfig.setOptional(true); const parameters = [ ...action.parametersOnMethod, ...(versionParameter ? [versionParameter] : []), @@ -101,6 +106,7 @@ export function createActionToSignatureMapper() { parameter.setOptional(p.isOptional); return parameter; }); + signature.parameters.push(restConfig); return signature; }; diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-body.component.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-body.component.ts index 4f6d8a9b73..e983083a88 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-body.component.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-body.component.ts @@ -1,16 +1,13 @@ -import { Component, Input } from '@angular/core'; +import { Component, HostBinding, Input } from '@angular/core'; @Component({ selector: 'abp-card-body', - template: ` -
- -
`, - host: { - class: 'card-body', - } + template: `
+ +
`, }) export class CardBodyComponent { + @HostBinding('class') componentClass = 'card-body'; @Input() cardBodyClass: string; @Input() cardBodyStyle: string; } diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-footer.component.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-footer.component.ts index ed5f0c64f3..d82a8725c1 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-footer.component.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-footer.component.ts @@ -1,19 +1,16 @@ -import { Component, Input } from '@angular/core'; +import { Component, HostBinding, Input } from '@angular/core'; @Component({ selector: 'abp-card-footer', template: ` -
- +
+
`, styles: [], - host: { - class: 'card-footer', - } }) export class CardFooterComponent { + @HostBinding('class') componentClass = 'card-footer'; @Input() cardFooterStyle: string; @Input() cardFooterClass: string; - } diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.component.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.component.ts index 1ec374757c..7dfb75b2d9 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.component.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.component.ts @@ -1,18 +1,16 @@ -import { Component, Input } from '@angular/core'; +import { Component, HostBinding, Input } from '@angular/core'; @Component({ selector: 'abp-card-header', template: `
- +
`, styles: [], - host: { - class: 'card-header', - } }) export class CardHeaderComponent { + @HostBinding('class') componentClass = 'card-header'; @Input() cardHeaderClass: string; @Input() cardHeaderStyle: string; } diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.directive.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.directive.ts index e7ecbfd881..44b8ff0eb5 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.directive.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-header.directive.ts @@ -1,9 +1,8 @@ -import { Directive } from "@angular/core"; +import { Directive, HostBinding } from '@angular/core'; @Directive({ selector: `abp-card-header, [abp-card-header], [abpCardHeader]`, - host: { - class: 'card-header', - }, }) -export class CardHeader {} +export class CardHeaderDirective { + @HostBinding('class') directiveClass = 'card-header'; +} diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-img-top.directive.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-img-top.directive.ts index 384f9f3989..405ea1bb24 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-img-top.directive.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-img-top.directive.ts @@ -1,9 +1,8 @@ -import { Directive } from "@angular/core"; +import { Directive, HostBinding } from '@angular/core'; @Directive({ selector: `abp-card-img-top, [abp-card-img-top], [abpCardImgTop]`, - host: { - class: 'card-img-top', - }, }) -export class CardImgTop {} +export class CardImgTopDirective { + @HostBinding('class') directiveClass = 'card-img-top'; +} diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-subtitle.directive.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-subtitle.directive.ts index 862a439ea8..57ba722500 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-subtitle.directive.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-subtitle.directive.ts @@ -1,9 +1,8 @@ -import { Directive } from "@angular/core"; +import { Directive, HostBinding } from '@angular/core'; @Directive({ selector: `abp-card-subtitle, [abp-card-subtitle], [abpCardSubtitle]`, - host: { - class: 'card-subtitle', - }, }) -export class CardSubtitle {} +export class CardSubtitleDirective { + @HostBinding('class') directiveClass = 'card-subtitle'; +} diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-title.directive.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-title.directive.ts index 143a868b64..0bb92d9263 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-title.directive.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card-title.directive.ts @@ -1,9 +1,8 @@ -import { Directive } from "@angular/core"; +import { Directive, HostBinding } from '@angular/core'; @Directive({ selector: `abp-card-title, [abp-card-title], [abpCardTitle]`, - host: { - class: 'card-title', - }, }) -export class CardTitle {} \ No newline at end of file +export class CardTitleDirective { + @HostBinding('class') directiveClass = 'card-title'; +} diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.component.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.component.ts index 149866bff0..fc5279be66 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.component.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.component.ts @@ -1,5 +1,4 @@ -import { Component, Directive, Input } from '@angular/core'; - +import { Component, Input } from '@angular/core'; @Component({ selector: 'abp-card', diff --git a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.module.ts b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.module.ts index 1a3e62113c..ac7e28e568 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.module.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/components/card/card.module.ts @@ -4,20 +4,20 @@ import { CardBodyComponent } from './card-body.component'; import { CardComponent } from './card.component'; import { CardHeaderComponent } from './card-header.component'; import { CardFooterComponent } from './card-footer.component'; -import { CardTitle } from './card-title.directive'; -import { CardSubtitle } from './card-subtitle.directive'; -import { CardImgTop } from './card-img-top.directive'; -import { CardHeader } from './card-header.directive'; +import { CardTitleDirective } from './card-title.directive'; +import { CardSubtitleDirective } from './card-subtitle.directive'; +import { CardImgTopDirective } from './card-img-top.directive'; +import { CardHeaderDirective } from './card-header.directive'; const declarationsWithExports = [ CardComponent, CardBodyComponent, CardHeaderComponent, CardFooterComponent, - CardTitle, - CardSubtitle, - CardImgTop, - CardHeader, + CardTitleDirective, + CardSubtitleDirective, + CardImgTopDirective, + CardHeaderDirective, ]; @NgModule({ @@ -25,4 +25,4 @@ const declarationsWithExports = [ imports: [CommonModule], exports: [...declarationsWithExports], }) -export class CardModule { } +export class CardModule {} diff --git a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-header.directive.spec.ts b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-header.directive.spec.ts index d811014447..122de05ed8 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-header.directive.spec.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-header.directive.spec.ts @@ -1,10 +1,10 @@ import { createHostFactory, SpectatorHost } from '@ngneat/spectator'; -import { CardHeader } from '../components'; +import { CardHeaderDirective } from '../components'; describe('AbpCardHeaderDirective', () => { - let spectator: SpectatorHost; + let spectator: SpectatorHost; - const createHost = createHostFactory(CardHeader); + const createHost = createHostFactory(CardHeaderDirective); beforeEach( () => diff --git a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-img-top.directive.spec.ts b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-img-top.directive.spec.ts index 2a1ee9cff3..008d9a4528 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-img-top.directive.spec.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-img-top.directive.spec.ts @@ -1,10 +1,10 @@ import { createHostFactory, SpectatorHost } from '@ngneat/spectator'; -import { CardImgTop } from '../components'; +import { CardImgTopDirective } from '../components'; describe('AbpCardImgTopDirective', () => { - let spectator: SpectatorHost; + let spectator: SpectatorHost; - const createHost = createHostFactory(CardImgTop); + const createHost = createHostFactory(CardImgTopDirective); beforeEach( () => diff --git a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-subtitle.directive.spec.ts b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-subtitle.directive.spec.ts index 4995067635..004beaecae 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-subtitle.directive.spec.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-subtitle.directive.spec.ts @@ -1,10 +1,10 @@ import { createHostFactory, SpectatorHost } from '@ngneat/spectator'; -import { CardSubtitle } from '../components'; +import { CardSubtitleDirective } from '../components'; describe('AbpCardSubtitleDirective', () => { - let spectator: SpectatorHost; + let spectator: SpectatorHost; - const createHost = createHostFactory(CardSubtitle); + const createHost = createHostFactory(CardSubtitleDirective); beforeEach(() => (spectator = createHost(`

CardSubtitle

`))); diff --git a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-title.directive.spec.ts b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-title.directive.spec.ts index 10360e23aa..9b9688f9e0 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/tests/card-title.directive.spec.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/tests/card-title.directive.spec.ts @@ -1,10 +1,10 @@ import { createHostFactory, SpectatorHost } from '@ngneat/spectator'; -import { CardTitle } from '../components'; +import { CardTitleDirective } from '../components'; describe('AbpCardTitleDirective', () => { - let spectator: SpectatorHost; + let spectator: SpectatorHost; - const createHost = createHostFactory(CardTitle); + const createHost = createHostFactory(CardTitleDirective); beforeEach(() => (spectator = createHost(`
CardTitle
`))); diff --git a/npm/ng-packs/packages/theme-shared/src/lib/tests/card.component.spec.ts b/npm/ng-packs/packages/theme-shared/src/lib/tests/card.component.spec.ts index 3dbc2156f1..a5c8a5c43b 100644 --- a/npm/ng-packs/packages/theme-shared/src/lib/tests/card.component.spec.ts +++ b/npm/ng-packs/packages/theme-shared/src/lib/tests/card.component.spec.ts @@ -4,10 +4,10 @@ import { CardBodyComponent, CardFooterComponent, CardHeaderComponent, - CardHeader, - CardTitle, - CardImgTop, - CardSubtitle, + CardHeaderDirective, + CardTitleDirective, + CardImgTopDirective, + CardSubtitleDirective, } from '../components/card'; describe('CardComponent', () => { @@ -17,10 +17,10 @@ describe('CardComponent', () => { component: CardComponent, declarations: [ CardHeaderComponent, - CardTitle, - CardSubtitle, + CardTitleDirective, + CardSubtitleDirective, CardBodyComponent, - CardImgTop, + CardImgTopDirective, CardFooterComponent, ], }); diff --git a/npm/packs/qrcode/abp.resourcemapping.js b/npm/packs/qrcode/abp.resourcemapping.js new file mode 100644 index 0000000000..3758875205 --- /dev/null +++ b/npm/packs/qrcode/abp.resourcemapping.js @@ -0,0 +1,5 @@ +module.exports = { + mappings: { + "@node_modules/@abp/qrcode/src/*.*": "@libs/qrcode/" + } +} \ No newline at end of file diff --git a/npm/packs/qrcode/package.json b/npm/packs/qrcode/package.json new file mode 100644 index 0000000000..b6ad870641 --- /dev/null +++ b/npm/packs/qrcode/package.json @@ -0,0 +1,16 @@ +{ + "version": "7.1.1", + "name": "@abp/qrcode", + "repository": { + "type": "git", + "url": "https://github.com/abpframework/abp.git", + "directory": "npm/packs/qrcode" + }, + "publishConfig": { + "access": "public" + }, + "dependencies": { + "@abp/core": "~7.1.1" + }, + "gitHead": "bb4ea17d5996f01889134c138d00b6c8f858a431" +} diff --git a/npm/packs/qrcode/src/qrcode.js b/npm/packs/qrcode/src/qrcode.js new file mode 100644 index 0000000000..5507c154ff --- /dev/null +++ b/npm/packs/qrcode/src/qrcode.js @@ -0,0 +1,614 @@ +/** + * @fileoverview + * - Using the 'QRCode for Javascript library' + * - Fixed dataset of 'QRCode for Javascript library' for support full-spec. + * - this library has no dependencies. + * + * @author davidshimjs + * @see http://www.d-project.com/ + * @see http://jeromeetienne.github.com/jquery-qrcode/ + */ +var QRCode; + +(function () { + //--------------------------------------------------------------------- + // QRCode for JavaScript + // + // Copyright (c) 2009 Kazuhiko Arase + // + // URL: http://www.d-project.com/ + // + // Licensed under the MIT license: + // http://www.opensource.org/licenses/mit-license.php + // + // The word "QR Code" is registered trademark of + // DENSO WAVE INCORPORATED + // http://www.denso-wave.com/qrcode/faqpatent-e.html + // + //--------------------------------------------------------------------- + function QR8bitByte(data) { + this.mode = QRMode.MODE_8BIT_BYTE; + this.data = data; + this.parsedData = []; + + // Added to support UTF-8 Characters + for (var i = 0, l = this.data.length; i < l; i++) { + var byteArray = []; + var code = this.data.charCodeAt(i); + + if (code > 0x10000) { + byteArray[0] = 0xF0 | ((code & 0x1C0000) >>> 18); + byteArray[1] = 0x80 | ((code & 0x3F000) >>> 12); + byteArray[2] = 0x80 | ((code & 0xFC0) >>> 6); + byteArray[3] = 0x80 | (code & 0x3F); + } else if (code > 0x800) { + byteArray[0] = 0xE0 | ((code & 0xF000) >>> 12); + byteArray[1] = 0x80 | ((code & 0xFC0) >>> 6); + byteArray[2] = 0x80 | (code & 0x3F); + } else if (code > 0x80) { + byteArray[0] = 0xC0 | ((code & 0x7C0) >>> 6); + byteArray[1] = 0x80 | (code & 0x3F); + } else { + byteArray[0] = code; + } + + this.parsedData.push(byteArray); + } + + this.parsedData = Array.prototype.concat.apply([], this.parsedData); + + if (this.parsedData.length != this.data.length) { + this.parsedData.unshift(191); + this.parsedData.unshift(187); + this.parsedData.unshift(239); + } + } + + QR8bitByte.prototype = { + getLength: function (buffer) { + return this.parsedData.length; + }, + write: function (buffer) { + for (var i = 0, l = this.parsedData.length; i < l; i++) { + buffer.put(this.parsedData[i], 8); + } + } + }; + + function QRCodeModel(typeNumber, errorCorrectLevel) { + this.typeNumber = typeNumber; + this.errorCorrectLevel = errorCorrectLevel; + this.modules = null; + this.moduleCount = 0; + this.dataCache = null; + this.dataList = []; + } + + QRCodeModel.prototype={addData:function(data){var newData=new QR8bitByte(data);this.dataList.push(newData);this.dataCache=null;},isDark:function(row,col){if(row<0||this.moduleCount<=row||col<0||this.moduleCount<=col){throw new Error(row+","+col);} + return this.modules[row][col];},getModuleCount:function(){return this.moduleCount;},make:function(){this.makeImpl(false,this.getBestMaskPattern());},makeImpl:function(test,maskPattern){this.moduleCount=this.typeNumber*4+17;this.modules=new Array(this.moduleCount);for(var row=0;row=7){this.setupTypeNumber(test);} + if(this.dataCache==null){this.dataCache=QRCodeModel.createData(this.typeNumber,this.errorCorrectLevel,this.dataList);} + this.mapData(this.dataCache,maskPattern);},setupPositionProbePattern:function(row,col){for(var r=-1;r<=7;r++){if(row+r<=-1||this.moduleCount<=row+r)continue;for(var c=-1;c<=7;c++){if(col+c<=-1||this.moduleCount<=col+c)continue;if((0<=r&&r<=6&&(c==0||c==6))||(0<=c&&c<=6&&(r==0||r==6))||(2<=r&&r<=4&&2<=c&&c<=4)){this.modules[row+r][col+c]=true;}else{this.modules[row+r][col+c]=false;}}}},getBestMaskPattern:function(){var minLostPoint=0;var pattern=0;for(var i=0;i<8;i++){this.makeImpl(true,i);var lostPoint=QRUtil.getLostPoint(this);if(i==0||minLostPoint>lostPoint){minLostPoint=lostPoint;pattern=i;}} + return pattern;},createMovieClip:function(target_mc,instance_name,depth){var qr_mc=target_mc.createEmptyMovieClip(instance_name,depth);var cs=1;this.make();for(var row=0;row>i)&1)==1);this.modules[Math.floor(i/3)][i%3+this.moduleCount-8-3]=mod;} + for(var i=0;i<18;i++){var mod=(!test&&((bits>>i)&1)==1);this.modules[i%3+this.moduleCount-8-3][Math.floor(i/3)]=mod;}},setupTypeInfo:function(test,maskPattern){var data=(this.errorCorrectLevel<<3)|maskPattern;var bits=QRUtil.getBCHTypeInfo(data);for(var i=0;i<15;i++){var mod=(!test&&((bits>>i)&1)==1);if(i<6){this.modules[i][8]=mod;}else if(i<8){this.modules[i+1][8]=mod;}else{this.modules[this.moduleCount-15+i][8]=mod;}} + for(var i=0;i<15;i++){var mod=(!test&&((bits>>i)&1)==1);if(i<8){this.modules[8][this.moduleCount-i-1]=mod;}else if(i<9){this.modules[8][15-i-1+1]=mod;}else{this.modules[8][15-i-1]=mod;}} + this.modules[this.moduleCount-8][8]=(!test);},mapData:function(data,maskPattern){var inc=-1;var row=this.moduleCount-1;var bitIndex=7;var byteIndex=0;for(var col=this.moduleCount-1;col>0;col-=2){if(col==6)col--;while(true){for(var c=0;c<2;c++){if(this.modules[row][col-c]==null){var dark=false;if(byteIndex>>bitIndex)&1)==1);} + var mask=QRUtil.getMask(maskPattern,row,col-c);if(mask){dark=!dark;} + this.modules[row][col-c]=dark;bitIndex--;if(bitIndex==-1){byteIndex++;bitIndex=7;}}} + row+=inc;if(row<0||this.moduleCount<=row){row-=inc;inc=-inc;break;}}}}};QRCodeModel.PAD0=0xEC;QRCodeModel.PAD1=0x11;QRCodeModel.createData=function(typeNumber,errorCorrectLevel,dataList){var rsBlocks=QRRSBlock.getRSBlocks(typeNumber,errorCorrectLevel);var buffer=new QRBitBuffer();for(var i=0;itotalDataCount*8){throw new Error("code length overflow. (" + +buffer.getLengthInBits() + +">" + +totalDataCount*8 + +")");} + if(buffer.getLengthInBits()+4<=totalDataCount*8){buffer.put(0,4);} + while(buffer.getLengthInBits()%8!=0){buffer.putBit(false);} + while(true){if(buffer.getLengthInBits()>=totalDataCount*8){break;} + buffer.put(QRCodeModel.PAD0,8);if(buffer.getLengthInBits()>=totalDataCount*8){break;} + buffer.put(QRCodeModel.PAD1,8);} + return QRCodeModel.createBytes(buffer,rsBlocks);};QRCodeModel.createBytes=function(buffer,rsBlocks){var offset=0;var maxDcCount=0;var maxEcCount=0;var dcdata=new Array(rsBlocks.length);var ecdata=new Array(rsBlocks.length);for(var r=0;r=0)?modPoly.get(modIndex):0;}} + var totalCodeCount=0;for(var i=0;i=0){d^=(QRUtil.G15<<(QRUtil.getBCHDigit(d)-QRUtil.getBCHDigit(QRUtil.G15)));} + return((data<<10)|d)^QRUtil.G15_MASK;},getBCHTypeNumber:function(data){var d=data<<12;while(QRUtil.getBCHDigit(d)-QRUtil.getBCHDigit(QRUtil.G18)>=0){d^=(QRUtil.G18<<(QRUtil.getBCHDigit(d)-QRUtil.getBCHDigit(QRUtil.G18)));} + return(data<<12)|d;},getBCHDigit:function(data){var digit=0;while(data!=0){digit++;data>>>=1;} + return digit;},getPatternPosition:function(typeNumber){return QRUtil.PATTERN_POSITION_TABLE[typeNumber-1];},getMask:function(maskPattern,i,j){switch(maskPattern){case QRMaskPattern.PATTERN000:return(i+j)%2==0;case QRMaskPattern.PATTERN001:return i%2==0;case QRMaskPattern.PATTERN010:return j%3==0;case QRMaskPattern.PATTERN011:return(i+j)%3==0;case QRMaskPattern.PATTERN100:return(Math.floor(i/2)+Math.floor(j/3))%2==0;case QRMaskPattern.PATTERN101:return(i*j)%2+(i*j)%3==0;case QRMaskPattern.PATTERN110:return((i*j)%2+(i*j)%3)%2==0;case QRMaskPattern.PATTERN111:return((i*j)%3+(i+j)%2)%2==0;default:throw new Error("bad maskPattern:"+maskPattern);}},getErrorCorrectPolynomial:function(errorCorrectLength){var a=new QRPolynomial([1],0);for(var i=0;i5){lostPoint+=(3+sameCount-5);}}} + for(var row=0;row=256){n-=255;} + return QRMath.EXP_TABLE[n];},EXP_TABLE:new Array(256),LOG_TABLE:new Array(256)};for(var i=0;i<8;i++){QRMath.EXP_TABLE[i]=1<>>(7-index%8))&1)==1;},put:function(num,length){for(var i=0;i>>(length-i-1))&1)==1);}},getLengthInBits:function(){return this.length;},putBit:function(bit){var bufIndex=Math.floor(this.length/8);if(this.buffer.length<=bufIndex){this.buffer.push(0);} + if(bit){this.buffer[bufIndex]|=(0x80>>>(this.length%8));} + this.length++;}};var QRCodeLimitLength=[[17,14,11,7],[32,26,20,14],[53,42,32,24],[78,62,46,34],[106,84,60,44],[134,106,74,58],[154,122,86,64],[192,152,108,84],[230,180,130,98],[271,213,151,119],[321,251,177,137],[367,287,203,155],[425,331,241,177],[458,362,258,194],[520,412,292,220],[586,450,322,250],[644,504,364,280],[718,560,394,310],[792,624,442,338],[858,666,482,382],[929,711,509,403],[1003,779,565,439],[1091,857,611,461],[1171,911,661,511],[1273,997,715,535],[1367,1059,751,593],[1465,1125,805,625],[1528,1190,868,658],[1628,1264,908,698],[1732,1370,982,742],[1840,1452,1030,790],[1952,1538,1112,842],[2068,1628,1168,898],[2188,1722,1228,958],[2303,1809,1283,983],[2431,1911,1351,1051],[2563,1989,1423,1093],[2699,2099,1499,1139],[2809,2213,1579,1219],[2953,2331,1663,1273]]; + + function _isSupportCanvas() { + return typeof CanvasRenderingContext2D != "undefined"; + } + + // android 2.x doesn't support Data-URI spec + function _getAndroid() { + var android = false; + var sAgent = navigator.userAgent; + + if (/android/i.test(sAgent)) { // android + android = true; + var aMat = sAgent.toString().match(/android ([0-9]\.[0-9])/i); + + if (aMat && aMat[1]) { + android = parseFloat(aMat[1]); + } + } + + return android; + } + + var svgDrawer = (function() { + + var Drawing = function (el, htOption) { + this._el = el; + this._htOption = htOption; + }; + + Drawing.prototype.draw = function (oQRCode) { + var _htOption = this._htOption; + var _el = this._el; + var nCount = oQRCode.getModuleCount(); + var nWidth = Math.floor(_htOption.width / nCount); + var nHeight = Math.floor(_htOption.height / nCount); + + this.clear(); + + function makeSVG(tag, attrs) { + var el = document.createElementNS('http://www.w3.org/2000/svg', tag); + for (var k in attrs) + if (attrs.hasOwnProperty(k)) el.setAttribute(k, attrs[k]); + return el; + } + + var svg = makeSVG("svg" , {'viewBox': '0 0 ' + String(nCount) + " " + String(nCount), 'width': '100%', 'height': '100%', 'fill': _htOption.colorLight}); + svg.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:xlink", "http://www.w3.org/1999/xlink"); + _el.appendChild(svg); + + svg.appendChild(makeSVG("rect", {"fill": _htOption.colorLight, "width": "100%", "height": "100%"})); + svg.appendChild(makeSVG("rect", {"fill": _htOption.colorDark, "width": "1", "height": "1", "id": "template"})); + + for (var row = 0; row < nCount; row++) { + for (var col = 0; col < nCount; col++) { + if (oQRCode.isDark(row, col)) { + var child = makeSVG("use", {"x": String(col), "y": String(row)}); + child.setAttributeNS("http://www.w3.org/1999/xlink", "href", "#template") + svg.appendChild(child); + } + } + } + }; + Drawing.prototype.clear = function () { + while (this._el.hasChildNodes()) + this._el.removeChild(this._el.lastChild); + }; + return Drawing; + })(); + + var useSVG = document.documentElement.tagName.toLowerCase() === "svg"; + + // Drawing in DOM by using Table tag + var Drawing = useSVG ? svgDrawer : !_isSupportCanvas() ? (function () { + var Drawing = function (el, htOption) { + this._el = el; + this._htOption = htOption; + }; + + /** + * Draw the QRCode + * + * @param {QRCode} oQRCode + */ + Drawing.prototype.draw = function (oQRCode) { + var _htOption = this._htOption; + var _el = this._el; + var nCount = oQRCode.getModuleCount(); + var nWidth = Math.floor(_htOption.width / nCount); + var nHeight = Math.floor(_htOption.height / nCount); + var aHTML = ['']; + + for (var row = 0; row < nCount; row++) { + aHTML.push(''); + + for (var col = 0; col < nCount; col++) { + aHTML.push(''); + } + + aHTML.push(''); + } + + aHTML.push('
'); + _el.innerHTML = aHTML.join(''); + + // Fix the margin values as real size. + var elTable = _el.childNodes[0]; + var nLeftMarginTable = (_htOption.width - elTable.offsetWidth) / 2; + var nTopMarginTable = (_htOption.height - elTable.offsetHeight) / 2; + + if (nLeftMarginTable > 0 && nTopMarginTable > 0) { + elTable.style.margin = nTopMarginTable + "px " + nLeftMarginTable + "px"; + } + }; + + /** + * Clear the QRCode + */ + Drawing.prototype.clear = function () { + this._el.innerHTML = ''; + }; + + return Drawing; + })() : (function () { // Drawing in Canvas + function _onMakeImage() { + this._elImage.src = this._elCanvas.toDataURL("image/png"); + this._elImage.style.display = "block"; + this._elCanvas.style.display = "none"; + } + + // Android 2.1 bug workaround + // http://code.google.com/p/android/issues/detail?id=5141 + if (this._android && this._android <= 2.1) { + var factor = 1 / window.devicePixelRatio; + var drawImage = CanvasRenderingContext2D.prototype.drawImage; + CanvasRenderingContext2D.prototype.drawImage = function (image, sx, sy, sw, sh, dx, dy, dw, dh) { + if (("nodeName" in image) && /img/i.test(image.nodeName)) { + for (var i = arguments.length - 1; i >= 1; i--) { + arguments[i] = arguments[i] * factor; + } + } else if (typeof dw == "undefined") { + arguments[1] *= factor; + arguments[2] *= factor; + arguments[3] *= factor; + arguments[4] *= factor; + } + + drawImage.apply(this, arguments); + }; + } + + /** + * Check whether the user's browser supports Data URI or not + * + * @private + * @param {Function} fSuccess Occurs if it supports Data URI + * @param {Function} fFail Occurs if it doesn't support Data URI + */ + function _safeSetDataURI(fSuccess, fFail) { + var self = this; + self._fFail = fFail; + self._fSuccess = fSuccess; + + // Check it just once + if (self._bSupportDataURI === null) { + var el = document.createElement("img"); + var fOnError = function() { + self._bSupportDataURI = false; + + if (self._fFail) { + self._fFail.call(self); + } + }; + var fOnSuccess = function() { + self._bSupportDataURI = true; + + if (self._fSuccess) { + self._fSuccess.call(self); + } + }; + + el.onabort = fOnError; + el.onerror = fOnError; + el.onload = fOnSuccess; + el.src = "data:image/gif;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg=="; // the Image contains 1px data. + return; + } else if (self._bSupportDataURI === true && self._fSuccess) { + self._fSuccess.call(self); + } else if (self._bSupportDataURI === false && self._fFail) { + self._fFail.call(self); + } + }; + + /** + * Drawing QRCode by using canvas + * + * @constructor + * @param {HTMLElement} el + * @param {Object} htOption QRCode Options + */ + var Drawing = function (el, htOption) { + this._bIsPainted = false; + this._android = _getAndroid(); + + this._htOption = htOption; + this._elCanvas = document.createElement("canvas"); + this._elCanvas.width = htOption.width; + this._elCanvas.height = htOption.height; + el.appendChild(this._elCanvas); + this._el = el; + this._oContext = this._elCanvas.getContext("2d"); + this._bIsPainted = false; + this._elImage = document.createElement("img"); + this._elImage.alt = "Scan me!"; + this._elImage.style.display = "none"; + this._el.appendChild(this._elImage); + this._bSupportDataURI = null; + }; + + /** + * Draw the QRCode + * + * @param {QRCode} oQRCode + */ + Drawing.prototype.draw = function (oQRCode) { + var _elImage = this._elImage; + var _oContext = this._oContext; + var _htOption = this._htOption; + + var nCount = oQRCode.getModuleCount(); + var nWidth = _htOption.width / nCount; + var nHeight = _htOption.height / nCount; + var nRoundedWidth = Math.round(nWidth); + var nRoundedHeight = Math.round(nHeight); + + _elImage.style.display = "none"; + this.clear(); + + for (var row = 0; row < nCount; row++) { + for (var col = 0; col < nCount; col++) { + var bIsDark = oQRCode.isDark(row, col); + var nLeft = col * nWidth; + var nTop = row * nHeight; + _oContext.strokeStyle = bIsDark ? _htOption.colorDark : _htOption.colorLight; + _oContext.lineWidth = 1; + _oContext.fillStyle = bIsDark ? _htOption.colorDark : _htOption.colorLight; + _oContext.fillRect(nLeft, nTop, nWidth, nHeight); + + // 안티 앨리어싱 방지 처리 + _oContext.strokeRect( + Math.floor(nLeft) + 0.5, + Math.floor(nTop) + 0.5, + nRoundedWidth, + nRoundedHeight + ); + + _oContext.strokeRect( + Math.ceil(nLeft) - 0.5, + Math.ceil(nTop) - 0.5, + nRoundedWidth, + nRoundedHeight + ); + } + } + + this._bIsPainted = true; + }; + + /** + * Make the image from Canvas if the browser supports Data URI. + */ + Drawing.prototype.makeImage = function () { + if (this._bIsPainted) { + _safeSetDataURI.call(this, _onMakeImage); + } + }; + + /** + * Return whether the QRCode is painted or not + * + * @return {Boolean} + */ + Drawing.prototype.isPainted = function () { + return this._bIsPainted; + }; + + /** + * Clear the QRCode + */ + Drawing.prototype.clear = function () { + this._oContext.clearRect(0, 0, this._elCanvas.width, this._elCanvas.height); + this._bIsPainted = false; + }; + + /** + * @private + * @param {Number} nNumber + */ + Drawing.prototype.round = function (nNumber) { + if (!nNumber) { + return nNumber; + } + + return Math.floor(nNumber * 1000) / 1000; + }; + + return Drawing; + })(); + + /** + * Get the type by string length + * + * @private + * @param {String} sText + * @param {Number} nCorrectLevel + * @return {Number} type + */ + function _getTypeNumber(sText, nCorrectLevel) { + var nType = 1; + var length = _getUTF8Length(sText); + + for (var i = 0, len = QRCodeLimitLength.length; i <= len; i++) { + var nLimit = 0; + + switch (nCorrectLevel) { + case QRErrorCorrectLevel.L : + nLimit = QRCodeLimitLength[i][0]; + break; + case QRErrorCorrectLevel.M : + nLimit = QRCodeLimitLength[i][1]; + break; + case QRErrorCorrectLevel.Q : + nLimit = QRCodeLimitLength[i][2]; + break; + case QRErrorCorrectLevel.H : + nLimit = QRCodeLimitLength[i][3]; + break; + } + + if (length <= nLimit) { + break; + } else { + nType++; + } + } + + if (nType > QRCodeLimitLength.length) { + throw new Error("Too long data"); + } + + return nType; + } + + function _getUTF8Length(sText) { + var replacedText = encodeURI(sText).toString().replace(/\%[0-9a-fA-F]{2}/g, 'a'); + return replacedText.length + (replacedText.length != sText ? 3 : 0); + } + + /** + * @class QRCode + * @constructor + * @example + * new QRCode(document.getElementById("test"), "http://jindo.dev.naver.com/collie"); + * + * @example + * var oQRCode = new QRCode("test", { + * text : "http://naver.com", + * width : 128, + * height : 128 + * }); + * + * oQRCode.clear(); // Clear the QRCode. + * oQRCode.makeCode("http://map.naver.com"); // Re-create the QRCode. + * + * @param {HTMLElement|String} el target element or 'id' attribute of element. + * @param {Object|String} vOption + * @param {String} vOption.text QRCode link data + * @param {Number} [vOption.width=256] + * @param {Number} [vOption.height=256] + * @param {String} [vOption.colorDark="#000000"] + * @param {String} [vOption.colorLight="#ffffff"] + * @param {QRCode.CorrectLevel} [vOption.correctLevel=QRCode.CorrectLevel.H] [L|M|Q|H] + */ + QRCode = function (el, vOption) { + this._htOption = { + width : 256, + height : 256, + typeNumber : 4, + colorDark : "#000000", + colorLight : "#ffffff", + correctLevel : QRErrorCorrectLevel.H + }; + + if (typeof vOption === 'string') { + vOption = { + text : vOption + }; + } + + // Overwrites options + if (vOption) { + for (var i in vOption) { + this._htOption[i] = vOption[i]; + } + } + + if (typeof el == "string") { + el = document.getElementById(el); + } + + if (this._htOption.useSVG) { + Drawing = svgDrawer; + } + + this._android = _getAndroid(); + this._el = el; + this._oQRCode = null; + this._oDrawing = new Drawing(this._el, this._htOption); + + if (this._htOption.text) { + this.makeCode(this._htOption.text); + } + }; + + /** + * Make the QRCode + * + * @param {String} sText link data + */ + QRCode.prototype.makeCode = function (sText) { + this._oQRCode = new QRCodeModel(_getTypeNumber(sText, this._htOption.correctLevel), this._htOption.correctLevel); + this._oQRCode.addData(sText); + this._oQRCode.make(); + this._el.title = sText; + this._oDrawing.draw(this._oQRCode); + this.makeImage(); + }; + + /** + * Make the Image from Canvas element + * - It occurs automatically + * - Android below 3 doesn't support Data-URI spec. + * + * @private + */ + QRCode.prototype.makeImage = function () { + if (typeof this._oDrawing.makeImage == "function" && (!this._android || this._android >= 3)) { + this._oDrawing.makeImage(); + } + }; + + /** + * Clear the QRCode + */ + QRCode.prototype.clear = function () { + this._oDrawing.clear(); + }; + + /** + * @name QRCode.CorrectLevel + */ + QRCode.CorrectLevel = QRErrorCorrectLevel; +})(); diff --git a/npm/packs/qrcode/src/qrcode.min.js b/npm/packs/qrcode/src/qrcode.min.js new file mode 100644 index 0000000000..993e88f396 --- /dev/null +++ b/npm/packs/qrcode/src/qrcode.min.js @@ -0,0 +1 @@ +var QRCode;!function(){function a(a){this.mode=c.MODE_8BIT_BYTE,this.data=a,this.parsedData=[];for(var b=[],d=0,e=this.data.length;e>d;d++){var f=this.data.charCodeAt(d);f>65536?(b[0]=240|(1835008&f)>>>18,b[1]=128|(258048&f)>>>12,b[2]=128|(4032&f)>>>6,b[3]=128|63&f):f>2048?(b[0]=224|(61440&f)>>>12,b[1]=128|(4032&f)>>>6,b[2]=128|63&f):f>128?(b[0]=192|(1984&f)>>>6,b[1]=128|63&f):b[0]=f,this.parsedData=this.parsedData.concat(b)}this.parsedData.length!=this.data.length&&(this.parsedData.unshift(191),this.parsedData.unshift(187),this.parsedData.unshift(239))}function b(a,b){this.typeNumber=a,this.errorCorrectLevel=b,this.modules=null,this.moduleCount=0,this.dataCache=null,this.dataList=[]}function i(a,b){if(void 0==a.length)throw new Error(a.length+"/"+b);for(var c=0;c=f;f++){var h=0;switch(b){case d.L:h=l[f][0];break;case d.M:h=l[f][1];break;case d.Q:h=l[f][2];break;case d.H:h=l[f][3]}if(h>=e)break;c++}if(c>l.length)throw new Error("Too long data");return c}function s(a){var b=encodeURI(a).toString().replace(/\%[0-9a-fA-F]{2}/g,"a");return b.length+(b.length!=a?3:0)}a.prototype={getLength:function(){return this.parsedData.length},write:function(a){for(var b=0,c=this.parsedData.length;c>b;b++)a.put(this.parsedData[b],8)}},b.prototype={addData:function(b){var c=new a(b);this.dataList.push(c),this.dataCache=null},isDark:function(a,b){if(0>a||this.moduleCount<=a||0>b||this.moduleCount<=b)throw new Error(a+","+b);return this.modules[a][b]},getModuleCount:function(){return this.moduleCount},make:function(){this.makeImpl(!1,this.getBestMaskPattern())},makeImpl:function(a,c){this.moduleCount=4*this.typeNumber+17,this.modules=new Array(this.moduleCount);for(var d=0;d=7&&this.setupTypeNumber(a),null==this.dataCache&&(this.dataCache=b.createData(this.typeNumber,this.errorCorrectLevel,this.dataList)),this.mapData(this.dataCache,c)},setupPositionProbePattern:function(a,b){for(var c=-1;7>=c;c++)if(!(-1>=a+c||this.moduleCount<=a+c))for(var d=-1;7>=d;d++)-1>=b+d||this.moduleCount<=b+d||(this.modules[a+c][b+d]=c>=0&&6>=c&&(0==d||6==d)||d>=0&&6>=d&&(0==c||6==c)||c>=2&&4>=c&&d>=2&&4>=d?!0:!1)},getBestMaskPattern:function(){for(var a=0,b=0,c=0;8>c;c++){this.makeImpl(!0,c);var d=f.getLostPoint(this);(0==c||a>d)&&(a=d,b=c)}return b},createMovieClip:function(a,b,c){var d=a.createEmptyMovieClip(b,c),e=1;this.make();for(var f=0;f=g;g++)for(var h=-2;2>=h;h++)this.modules[d+g][e+h]=-2==g||2==g||-2==h||2==h||0==g&&0==h?!0:!1}},setupTypeNumber:function(a){for(var b=f.getBCHTypeNumber(this.typeNumber),c=0;18>c;c++){var d=!a&&1==(1&b>>c);this.modules[Math.floor(c/3)][c%3+this.moduleCount-8-3]=d}for(var c=0;18>c;c++){var d=!a&&1==(1&b>>c);this.modules[c%3+this.moduleCount-8-3][Math.floor(c/3)]=d}},setupTypeInfo:function(a,b){for(var c=this.errorCorrectLevel<<3|b,d=f.getBCHTypeInfo(c),e=0;15>e;e++){var g=!a&&1==(1&d>>e);6>e?this.modules[e][8]=g:8>e?this.modules[e+1][8]=g:this.modules[this.moduleCount-15+e][8]=g}for(var e=0;15>e;e++){var g=!a&&1==(1&d>>e);8>e?this.modules[8][this.moduleCount-e-1]=g:9>e?this.modules[8][15-e-1+1]=g:this.modules[8][15-e-1]=g}this.modules[this.moduleCount-8][8]=!a},mapData:function(a,b){for(var c=-1,d=this.moduleCount-1,e=7,g=0,h=this.moduleCount-1;h>0;h-=2)for(6==h&&h--;;){for(var i=0;2>i;i++)if(null==this.modules[d][h-i]){var j=!1;g>>e));var k=f.getMask(b,d,h-i);k&&(j=!j),this.modules[d][h-i]=j,e--,-1==e&&(g++,e=7)}if(d+=c,0>d||this.moduleCount<=d){d-=c,c=-c;break}}}},b.PAD0=236,b.PAD1=17,b.createData=function(a,c,d){for(var e=j.getRSBlocks(a,c),g=new k,h=0;h8*l)throw new Error("code length overflow. ("+g.getLengthInBits()+">"+8*l+")");for(g.getLengthInBits()+4<=8*l&&g.put(0,4);0!=g.getLengthInBits()%8;)g.putBit(!1);for(;;){if(g.getLengthInBits()>=8*l)break;if(g.put(b.PAD0,8),g.getLengthInBits()>=8*l)break;g.put(b.PAD1,8)}return b.createBytes(g,e)},b.createBytes=function(a,b){for(var c=0,d=0,e=0,g=new Array(b.length),h=new Array(b.length),j=0;j=0?p.get(q):0}}for(var r=0,m=0;mm;m++)for(var j=0;jm;m++)for(var j=0;j=0;)b^=f.G15<=0;)b^=f.G18<>>=1;return b},getPatternPosition:function(a){return f.PATTERN_POSITION_TABLE[a-1]},getMask:function(a,b,c){switch(a){case e.PATTERN000:return 0==(b+c)%2;case e.PATTERN001:return 0==b%2;case e.PATTERN010:return 0==c%3;case e.PATTERN011:return 0==(b+c)%3;case e.PATTERN100:return 0==(Math.floor(b/2)+Math.floor(c/3))%2;case e.PATTERN101:return 0==b*c%2+b*c%3;case e.PATTERN110:return 0==(b*c%2+b*c%3)%2;case e.PATTERN111:return 0==(b*c%3+(b+c)%2)%2;default:throw new Error("bad maskPattern:"+a)}},getErrorCorrectPolynomial:function(a){for(var b=new i([1],0),c=0;a>c;c++)b=b.multiply(new i([1,g.gexp(c)],0));return b},getLengthInBits:function(a,b){if(b>=1&&10>b)switch(a){case c.MODE_NUMBER:return 10;case c.MODE_ALPHA_NUM:return 9;case c.MODE_8BIT_BYTE:return 8;case c.MODE_KANJI:return 8;default:throw new Error("mode:"+a)}else if(27>b)switch(a){case c.MODE_NUMBER:return 12;case c.MODE_ALPHA_NUM:return 11;case c.MODE_8BIT_BYTE:return 16;case c.MODE_KANJI:return 10;default:throw new Error("mode:"+a)}else{if(!(41>b))throw new Error("type:"+b);switch(a){case c.MODE_NUMBER:return 14;case c.MODE_ALPHA_NUM:return 13;case c.MODE_8BIT_BYTE:return 16;case c.MODE_KANJI:return 12;default:throw new Error("mode:"+a)}}},getLostPoint:function(a){for(var b=a.getModuleCount(),c=0,d=0;b>d;d++)for(var e=0;b>e;e++){for(var f=0,g=a.isDark(d,e),h=-1;1>=h;h++)if(!(0>d+h||d+h>=b))for(var i=-1;1>=i;i++)0>e+i||e+i>=b||(0!=h||0!=i)&&g==a.isDark(d+h,e+i)&&f++;f>5&&(c+=3+f-5)}for(var d=0;b-1>d;d++)for(var e=0;b-1>e;e++){var j=0;a.isDark(d,e)&&j++,a.isDark(d+1,e)&&j++,a.isDark(d,e+1)&&j++,a.isDark(d+1,e+1)&&j++,(0==j||4==j)&&(c+=3)}for(var d=0;b>d;d++)for(var e=0;b-6>e;e++)a.isDark(d,e)&&!a.isDark(d,e+1)&&a.isDark(d,e+2)&&a.isDark(d,e+3)&&a.isDark(d,e+4)&&!a.isDark(d,e+5)&&a.isDark(d,e+6)&&(c+=40);for(var e=0;b>e;e++)for(var d=0;b-6>d;d++)a.isDark(d,e)&&!a.isDark(d+1,e)&&a.isDark(d+2,e)&&a.isDark(d+3,e)&&a.isDark(d+4,e)&&!a.isDark(d+5,e)&&a.isDark(d+6,e)&&(c+=40);for(var k=0,e=0;b>e;e++)for(var d=0;b>d;d++)a.isDark(d,e)&&k++;var l=Math.abs(100*k/b/b-50)/5;return c+=10*l}},g={glog:function(a){if(1>a)throw new Error("glog("+a+")");return g.LOG_TABLE[a]},gexp:function(a){for(;0>a;)a+=255;for(;a>=256;)a-=255;return g.EXP_TABLE[a]},EXP_TABLE:new Array(256),LOG_TABLE:new Array(256)},h=0;8>h;h++)g.EXP_TABLE[h]=1<h;h++)g.EXP_TABLE[h]=g.EXP_TABLE[h-4]^g.EXP_TABLE[h-5]^g.EXP_TABLE[h-6]^g.EXP_TABLE[h-8];for(var h=0;255>h;h++)g.LOG_TABLE[g.EXP_TABLE[h]]=h;i.prototype={get:function(a){return this.num[a]},getLength:function(){return this.num.length},multiply:function(a){for(var b=new Array(this.getLength()+a.getLength()-1),c=0;cf;f++)for(var g=c[3*f+0],h=c[3*f+1],i=c[3*f+2],k=0;g>k;k++)e.push(new j(h,i));return e},j.getRsBlockTable=function(a,b){switch(b){case d.L:return j.RS_BLOCK_TABLE[4*(a-1)+0];case d.M:return j.RS_BLOCK_TABLE[4*(a-1)+1];case d.Q:return j.RS_BLOCK_TABLE[4*(a-1)+2];case d.H:return j.RS_BLOCK_TABLE[4*(a-1)+3];default:return void 0}},k.prototype={get:function(a){var b=Math.floor(a/8);return 1==(1&this.buffer[b]>>>7-a%8)},put:function(a,b){for(var c=0;b>c;c++)this.putBit(1==(1&a>>>b-c-1))},getLengthInBits:function(){return this.length},putBit:function(a){var b=Math.floor(this.length/8);this.buffer.length<=b&&this.buffer.push(0),a&&(this.buffer[b]|=128>>>this.length%8),this.length++}};var l=[[17,14,11,7],[32,26,20,14],[53,42,32,24],[78,62,46,34],[106,84,60,44],[134,106,74,58],[154,122,86,64],[192,152,108,84],[230,180,130,98],[271,213,151,119],[321,251,177,137],[367,287,203,155],[425,331,241,177],[458,362,258,194],[520,412,292,220],[586,450,322,250],[644,504,364,280],[718,560,394,310],[792,624,442,338],[858,666,482,382],[929,711,509,403],[1003,779,565,439],[1091,857,611,461],[1171,911,661,511],[1273,997,715,535],[1367,1059,751,593],[1465,1125,805,625],[1528,1190,868,658],[1628,1264,908,698],[1732,1370,982,742],[1840,1452,1030,790],[1952,1538,1112,842],[2068,1628,1168,898],[2188,1722,1228,958],[2303,1809,1283,983],[2431,1911,1351,1051],[2563,1989,1423,1093],[2699,2099,1499,1139],[2809,2213,1579,1219],[2953,2331,1663,1273]],o=function(){var a=function(a,b){this._el=a,this._htOption=b};return a.prototype.draw=function(a){function g(a,b){var c=document.createElementNS("http://www.w3.org/2000/svg",a);for(var d in b)b.hasOwnProperty(d)&&c.setAttribute(d,b[d]);return c}var b=this._htOption,c=this._el,d=a.getModuleCount();Math.floor(b.width/d),Math.floor(b.height/d),this.clear();var h=g("svg",{viewBox:"0 0 "+String(d)+" "+String(d),width:"100%",height:"100%",fill:b.colorLight});h.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink","http://www.w3.org/1999/xlink"),c.appendChild(h),h.appendChild(g("rect",{fill:b.colorDark,width:"1",height:"1",id:"template"}));for(var i=0;d>i;i++)for(var j=0;d>j;j++)if(a.isDark(i,j)){var k=g("use",{x:String(i),y:String(j)});k.setAttributeNS("http://www.w3.org/1999/xlink","href","#template"),h.appendChild(k)}},a.prototype.clear=function(){for(;this._el.hasChildNodes();)this._el.removeChild(this._el.lastChild)},a}(),p="svg"===document.documentElement.tagName.toLowerCase(),q=p?o:m()?function(){function a(){this._elImage.src=this._elCanvas.toDataURL("image/png"),this._elImage.style.display="block",this._elCanvas.style.display="none"}function d(a,b){var c=this;if(c._fFail=b,c._fSuccess=a,null===c._bSupportDataURI){var d=document.createElement("img"),e=function(){c._bSupportDataURI=!1,c._fFail&&_fFail.call(c)},f=function(){c._bSupportDataURI=!0,c._fSuccess&&c._fSuccess.call(c)};return d.onabort=e,d.onerror=e,d.onload=f,d.src="data:image/gif;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==",void 0}c._bSupportDataURI===!0&&c._fSuccess?c._fSuccess.call(c):c._bSupportDataURI===!1&&c._fFail&&c._fFail.call(c)}if(this._android&&this._android<=2.1){var b=1/window.devicePixelRatio,c=CanvasRenderingContext2D.prototype.drawImage;CanvasRenderingContext2D.prototype.drawImage=function(a,d,e,f,g,h,i,j){if("nodeName"in a&&/img/i.test(a.nodeName))for(var l=arguments.length-1;l>=1;l--)arguments[l]=arguments[l]*b;else"undefined"==typeof j&&(arguments[1]*=b,arguments[2]*=b,arguments[3]*=b,arguments[4]*=b);c.apply(this,arguments)}}var e=function(a,b){this._bIsPainted=!1,this._android=n(),this._htOption=b,this._elCanvas=document.createElement("canvas"),this._elCanvas.width=b.width,this._elCanvas.height=b.height,a.appendChild(this._elCanvas),this._el=a,this._oContext=this._elCanvas.getContext("2d"),this._bIsPainted=!1,this._elImage=document.createElement("img"),this._elImage.style.display="none",this._el.appendChild(this._elImage),this._bSupportDataURI=null};return e.prototype.draw=function(a){var b=this._elImage,c=this._oContext,d=this._htOption,e=a.getModuleCount(),f=d.width/e,g=d.height/e,h=Math.round(f),i=Math.round(g);b.style.display="none",this.clear();for(var j=0;e>j;j++)for(var k=0;e>k;k++){var l=a.isDark(j,k),m=k*f,n=j*g;c.strokeStyle=l?d.colorDark:d.colorLight,c.lineWidth=1,c.fillStyle=l?d.colorDark:d.colorLight,c.fillRect(m,n,f,g),c.strokeRect(Math.floor(m)+.5,Math.floor(n)+.5,h,i),c.strokeRect(Math.ceil(m)-.5,Math.ceil(n)-.5,h,i)}this._bIsPainted=!0},e.prototype.makeImage=function(){this._bIsPainted&&d.call(this,a)},e.prototype.isPainted=function(){return this._bIsPainted},e.prototype.clear=function(){this._oContext.clearRect(0,0,this._elCanvas.width,this._elCanvas.height),this._bIsPainted=!1},e.prototype.round=function(a){return a?Math.floor(1e3*a)/1e3:a},e}():function(){var a=function(a,b){this._el=a,this._htOption=b};return a.prototype.draw=function(a){for(var b=this._htOption,c=this._el,d=a.getModuleCount(),e=Math.floor(b.width/d),f=Math.floor(b.height/d),g=[''],h=0;d>h;h++){g.push("");for(var i=0;d>i;i++)g.push('');g.push("")}g.push("
"),c.innerHTML=g.join("");var j=c.childNodes[0],k=(b.width-j.offsetWidth)/2,l=(b.height-j.offsetHeight)/2;k>0&&l>0&&(j.style.margin=l+"px "+k+"px")},a.prototype.clear=function(){this._el.innerHTML=""},a}();QRCode=function(a,b){if(this._htOption={width:256,height:256,typeNumber:4,colorDark:"#000000",colorLight:"#ffffff",correctLevel:d.H},"string"==typeof b&&(b={text:b}),b)for(var c in b)this._htOption[c]=b[c];"string"==typeof a&&(a=document.getElementById(a)),this._android=n(),this._el=a,this._oQRCode=null,this._oDrawing=new q(this._el,this._htOption),this._htOption.text&&this.makeCode(this._htOption.text)},QRCode.prototype.makeCode=function(a){this._oQRCode=new b(r(a,this._htOption.correctLevel),this._htOption.correctLevel),this._oQRCode.addData(a),this._oQRCode.make(),this._el.title=a,this._oDrawing.draw(this._oQRCode),this.makeImage()},QRCode.prototype.makeImage=function(){"function"==typeof this._oDrawing.makeImage&&(!this._android||this._android>=3)&&this._oDrawing.makeImage()},QRCode.prototype.clear=function(){this._oDrawing.clear()},QRCode.CorrectLevel=d}(); \ No newline at end of file diff --git a/nupkg/pack.ps1 b/nupkg/pack.ps1 index f72936c69c..4c45e9e8c3 100644 --- a/nupkg/pack.ps1 +++ b/nupkg/pack.ps1 @@ -1,4 +1,6 @@ . ".\common.ps1" +# Delete existing nupkg files +del *.nupkg # Rebuild all solutions foreach($solution in $solutions) { @@ -7,9 +9,6 @@ foreach($solution in $solutions) { dotnet restore } -# Delete old packages -del *.nupkg - # Create all packages $i = 0 $projectsCount = $projects.length @@ -25,7 +24,7 @@ foreach($project in $projects) { Set-Location $projectFolder #dotnet clean - dotnet pack -c Release --no-build -- /maxcpucount + dotnet pack -c Release --no-build -- /maxcpucount if (-Not $?) { Write-Error "Packaging failed for the project: $projectName" diff --git a/source-code/SourceCodes.sln b/source-code/SourceCodes.sln new file mode 100644 index 0000000000..c905fd2676 --- /dev/null +++ b/source-code/SourceCodes.sln @@ -0,0 +1,124 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.0.31903.59 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.Account.SourceCode", "Volo.Abp.Account.SourceCode\Volo.Abp.Account.SourceCode.csproj", "{7EE7031D-8CE1-4AFA-8DA0-67B77971482F}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.AuditLogging.SourceCode", "Volo.Abp.AuditLogging.SourceCode\Volo.Abp.AuditLogging.SourceCode.csproj", "{58A1422A-68D6-4320-839E-2C29F5D57CF8}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.BackgroundJobs.SourceCode", "Volo.Abp.BackgroundJobs.SourceCode\Volo.Abp.BackgroundJobs.SourceCode.csproj", "{1A207FF1-CD9D-4D1C-9C60-B897DD3FF636}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.BasicTheme.SourceCode", "Volo.Abp.BasicTheme.SourceCode\Volo.Abp.BasicTheme.SourceCode.csproj", "{DBA1E8B8-8889-4F45-9A0E-241DCF113829}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.BlobStoring.Database.SourceCode", "Volo.Abp.BlobStoring.Database.SourceCode\Volo.Abp.BlobStoring.Database.SourceCode.csproj", "{52BD49B3-D2D8-4591-8248-72984481E99D}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.FeatureManagement.SourceCode", "Volo.Abp.FeatureManagement.SourceCode\Volo.Abp.FeatureManagement.SourceCode.csproj", "{06A55C62-1C96-4255-9D70-BDDE0C96BC82}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.Identity.SourceCode", "Volo.Abp.Identity.SourceCode\Volo.Abp.Identity.SourceCode.csproj", "{896527D7-EB6F-4792-94FA-B1DDF29BEA2F}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.IdentityServer.SourceCode", "Volo.Abp.IdentityServer.SourceCode\Volo.Abp.IdentityServer.SourceCode.csproj", "{41A27F5D-5338-4D51-BDE7-4F8A1268F040}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.OpenIddict.SourceCode", "Volo.Abp.OpenIddict.SourceCode\Volo.Abp.OpenIddict.SourceCode.csproj", "{2D6CCDEF-8FBA-4183-B86B-AFE5FD150AB7}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.PermissionManagement.SourceCode", "Volo.Abp.PermissionManagement.SourceCode\Volo.Abp.PermissionManagement.SourceCode.csproj", "{9B180F22-C11E-4CA8-9588-E12E79761CDC}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.SettingManagement.SourceCode", "Volo.Abp.SettingManagement.SourceCode\Volo.Abp.SettingManagement.SourceCode.csproj", "{2AA05D3A-A47C-460C-B5EA-C4C1942AC06F}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.TenantManagement.SourceCode", "Volo.Abp.TenantManagement.SourceCode\Volo.Abp.TenantManagement.SourceCode.csproj", "{4816262C-D0D3-4B90-9FEB-B79FB5C250E5}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.Users.SourceCode", "Volo.Abp.Users.SourceCode\Volo.Abp.Users.SourceCode.csproj", "{ED42139F-94DB-445D-BDC5-390E0478DF02}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Abp.VirtualFileExplorer.SourceCode", "Volo.Abp.VirtualFileExplorer.SourceCode\Volo.Abp.VirtualFileExplorer.SourceCode.csproj", "{7652CFDF-9581-46E3-B74B-19CC4E2B50BE}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Blogging.SourceCode", "Volo.Blogging.SourceCode\Volo.Blogging.SourceCode.csproj", "{0FA2B096-963D-4DD7-BF30-E5382229C515}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.ClientSimulation.SourceCode", "Volo.ClientSimulation.SourceCode\Volo.ClientSimulation.SourceCode.csproj", "{C3FCB192-F270-498E-8738-BE40308E7510}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.CmsKit.SourceCode", "Volo.CmsKit.SourceCode\Volo.CmsKit.SourceCode.csproj", "{7A088623-8A15-425D-A562-9400882E6FB3}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Volo.Docs.SourceCode", "Volo.Docs.SourceCode\Volo.Docs.SourceCode.csproj", "{E7D2575E-8002-4C4A-A86C-BFFF6439329A}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {7EE7031D-8CE1-4AFA-8DA0-67B77971482F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7EE7031D-8CE1-4AFA-8DA0-67B77971482F}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7EE7031D-8CE1-4AFA-8DA0-67B77971482F}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7EE7031D-8CE1-4AFA-8DA0-67B77971482F}.Release|Any CPU.Build.0 = Release|Any CPU + {58A1422A-68D6-4320-839E-2C29F5D57CF8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {58A1422A-68D6-4320-839E-2C29F5D57CF8}.Debug|Any CPU.Build.0 = Debug|Any CPU + {58A1422A-68D6-4320-839E-2C29F5D57CF8}.Release|Any CPU.ActiveCfg = Release|Any CPU + {58A1422A-68D6-4320-839E-2C29F5D57CF8}.Release|Any CPU.Build.0 = Release|Any CPU + {1A207FF1-CD9D-4D1C-9C60-B897DD3FF636}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {1A207FF1-CD9D-4D1C-9C60-B897DD3FF636}.Debug|Any CPU.Build.0 = Debug|Any CPU + {1A207FF1-CD9D-4D1C-9C60-B897DD3FF636}.Release|Any CPU.ActiveCfg = Release|Any CPU + {1A207FF1-CD9D-4D1C-9C60-B897DD3FF636}.Release|Any CPU.Build.0 = Release|Any CPU + {DBA1E8B8-8889-4F45-9A0E-241DCF113829}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {DBA1E8B8-8889-4F45-9A0E-241DCF113829}.Debug|Any CPU.Build.0 = Debug|Any CPU + {DBA1E8B8-8889-4F45-9A0E-241DCF113829}.Release|Any CPU.ActiveCfg = Release|Any CPU + {DBA1E8B8-8889-4F45-9A0E-241DCF113829}.Release|Any CPU.Build.0 = Release|Any CPU + {52BD49B3-D2D8-4591-8248-72984481E99D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {52BD49B3-D2D8-4591-8248-72984481E99D}.Debug|Any CPU.Build.0 = Debug|Any CPU + {52BD49B3-D2D8-4591-8248-72984481E99D}.Release|Any CPU.ActiveCfg = Release|Any CPU + {52BD49B3-D2D8-4591-8248-72984481E99D}.Release|Any CPU.Build.0 = Release|Any CPU + {06A55C62-1C96-4255-9D70-BDDE0C96BC82}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {06A55C62-1C96-4255-9D70-BDDE0C96BC82}.Debug|Any CPU.Build.0 = Debug|Any CPU + {06A55C62-1C96-4255-9D70-BDDE0C96BC82}.Release|Any CPU.ActiveCfg = Release|Any CPU + {06A55C62-1C96-4255-9D70-BDDE0C96BC82}.Release|Any CPU.Build.0 = Release|Any CPU + {896527D7-EB6F-4792-94FA-B1DDF29BEA2F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {896527D7-EB6F-4792-94FA-B1DDF29BEA2F}.Debug|Any CPU.Build.0 = Debug|Any CPU + {896527D7-EB6F-4792-94FA-B1DDF29BEA2F}.Release|Any CPU.ActiveCfg = Release|Any CPU + {896527D7-EB6F-4792-94FA-B1DDF29BEA2F}.Release|Any CPU.Build.0 = Release|Any CPU + {41A27F5D-5338-4D51-BDE7-4F8A1268F040}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {41A27F5D-5338-4D51-BDE7-4F8A1268F040}.Debug|Any CPU.Build.0 = Debug|Any CPU + {41A27F5D-5338-4D51-BDE7-4F8A1268F040}.Release|Any CPU.ActiveCfg = Release|Any CPU + {41A27F5D-5338-4D51-BDE7-4F8A1268F040}.Release|Any CPU.Build.0 = Release|Any CPU + {2D6CCDEF-8FBA-4183-B86B-AFE5FD150AB7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {2D6CCDEF-8FBA-4183-B86B-AFE5FD150AB7}.Debug|Any CPU.Build.0 = Debug|Any CPU + {2D6CCDEF-8FBA-4183-B86B-AFE5FD150AB7}.Release|Any CPU.ActiveCfg = Release|Any CPU + {2D6CCDEF-8FBA-4183-B86B-AFE5FD150AB7}.Release|Any CPU.Build.0 = Release|Any CPU + {9B180F22-C11E-4CA8-9588-E12E79761CDC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {9B180F22-C11E-4CA8-9588-E12E79761CDC}.Debug|Any CPU.Build.0 = Debug|Any CPU + {9B180F22-C11E-4CA8-9588-E12E79761CDC}.Release|Any CPU.ActiveCfg = Release|Any CPU + {9B180F22-C11E-4CA8-9588-E12E79761CDC}.Release|Any CPU.Build.0 = Release|Any CPU + {2AA05D3A-A47C-460C-B5EA-C4C1942AC06F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {2AA05D3A-A47C-460C-B5EA-C4C1942AC06F}.Debug|Any CPU.Build.0 = Debug|Any CPU + {2AA05D3A-A47C-460C-B5EA-C4C1942AC06F}.Release|Any CPU.ActiveCfg = Release|Any CPU + {2AA05D3A-A47C-460C-B5EA-C4C1942AC06F}.Release|Any CPU.Build.0 = Release|Any CPU + {4816262C-D0D3-4B90-9FEB-B79FB5C250E5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {4816262C-D0D3-4B90-9FEB-B79FB5C250E5}.Debug|Any CPU.Build.0 = Debug|Any CPU + {4816262C-D0D3-4B90-9FEB-B79FB5C250E5}.Release|Any CPU.ActiveCfg = Release|Any CPU + {4816262C-D0D3-4B90-9FEB-B79FB5C250E5}.Release|Any CPU.Build.0 = Release|Any CPU + {ED42139F-94DB-445D-BDC5-390E0478DF02}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {ED42139F-94DB-445D-BDC5-390E0478DF02}.Debug|Any CPU.Build.0 = Debug|Any CPU + {ED42139F-94DB-445D-BDC5-390E0478DF02}.Release|Any CPU.ActiveCfg = Release|Any CPU + {ED42139F-94DB-445D-BDC5-390E0478DF02}.Release|Any CPU.Build.0 = Release|Any CPU + {7652CFDF-9581-46E3-B74B-19CC4E2B50BE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7652CFDF-9581-46E3-B74B-19CC4E2B50BE}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7652CFDF-9581-46E3-B74B-19CC4E2B50BE}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7652CFDF-9581-46E3-B74B-19CC4E2B50BE}.Release|Any CPU.Build.0 = Release|Any CPU + {0FA2B096-963D-4DD7-BF30-E5382229C515}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {0FA2B096-963D-4DD7-BF30-E5382229C515}.Debug|Any CPU.Build.0 = Debug|Any CPU + {0FA2B096-963D-4DD7-BF30-E5382229C515}.Release|Any CPU.ActiveCfg = Release|Any CPU + {0FA2B096-963D-4DD7-BF30-E5382229C515}.Release|Any CPU.Build.0 = Release|Any CPU + {C3FCB192-F270-498E-8738-BE40308E7510}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {C3FCB192-F270-498E-8738-BE40308E7510}.Debug|Any CPU.Build.0 = Debug|Any CPU + {C3FCB192-F270-498E-8738-BE40308E7510}.Release|Any CPU.ActiveCfg = Release|Any CPU + {C3FCB192-F270-498E-8738-BE40308E7510}.Release|Any CPU.Build.0 = Release|Any CPU + {7A088623-8A15-425D-A562-9400882E6FB3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {7A088623-8A15-425D-A562-9400882E6FB3}.Debug|Any CPU.Build.0 = Debug|Any CPU + {7A088623-8A15-425D-A562-9400882E6FB3}.Release|Any CPU.ActiveCfg = Release|Any CPU + {7A088623-8A15-425D-A562-9400882E6FB3}.Release|Any CPU.Build.0 = Release|Any CPU + {E7D2575E-8002-4C4A-A86C-BFFF6439329A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {E7D2575E-8002-4C4A-A86C-BFFF6439329A}.Debug|Any CPU.Build.0 = Debug|Any CPU + {E7D2575E-8002-4C4A-A86C-BFFF6439329A}.Release|Any CPU.ActiveCfg = Release|Any CPU + {E7D2575E-8002-4C4A-A86C-BFFF6439329A}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection +EndGlobal diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230314024329_Initial.Designer.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230324070018_Initial.Designer.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230314024329_Initial.Designer.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230324070018_Initial.Designer.cs index 64b3b7ecca..6baa1f955f 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230314024329_Initial.Designer.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230324070018_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Blazor.Server.Migrations { [DbContext(typeof(MyProjectNameDbContext))] - [Migration("20230314024329_Initial")] + [Migration("20230324070018_Initial")] partial class Initial { /// @@ -833,6 +833,33 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230314024329_Initial.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230324070018_Initial.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230314024329_Initial.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230324070018_Initial.cs index f2525f617b..f8e92f9d6b 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230314024329_Initial.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/20230324070018_Initial.cs @@ -292,6 +292,22 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -990,6 +1006,9 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/MyProjectNameDbContextModelSnapshot.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/MyProjectNameDbContextModelSnapshot.cs index e0b0b2f686..3115f987ef 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/MyProjectNameDbContextModelSnapshot.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.Server/Migrations/MyProjectNameDbContextModelSnapshot.cs @@ -830,6 +830,33 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230314024404_Initial.Designer.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230324070058_Initial.Designer.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230314024404_Initial.Designer.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230324070058_Initial.Designer.cs index 2a5f430902..0eba223650 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230314024404_Initial.Designer.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230324070058_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Migrations { [DbContext(typeof(MyProjectNameDbContext))] - [Migration("20230314024404_Initial")] + [Migration("20230324070058_Initial")] partial class Initial { /// @@ -833,6 +833,33 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230314024642_Initial.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230324070058_Initial.cs similarity index 98% rename from templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230314024642_Initial.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230324070058_Initial.cs index e4e66c791a..3c62b40bf4 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230314024642_Initial.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230324070058_Initial.cs @@ -292,6 +292,22 @@ namespace MyCompanyName.MyProjectName.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -990,6 +1006,9 @@ namespace MyCompanyName.MyProjectName.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/MyProjectNameDbContextModelSnapshot.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/MyProjectNameDbContextModelSnapshot.cs index 6ba91d04bd..60afa4e2c9 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/MyProjectNameDbContextModelSnapshot.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/MyProjectNameDbContextModelSnapshot.cs @@ -830,6 +830,33 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230314024402_Initial.Designer.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230324070125_Initial.Designer.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230314024402_Initial.Designer.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230324070125_Initial.Designer.cs index 6a16d3f459..fe2d18ec1e 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230314024402_Initial.Designer.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230324070125_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Host.Migrations { [DbContext(typeof(MyProjectNameDbContext))] - [Migration("20230314024402_Initial")] + [Migration("20230324070125_Initial")] partial class Initial { /// @@ -833,6 +833,33 @@ namespace MyCompanyName.MyProjectName.Host.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230314024402_Initial.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230324070125_Initial.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230314024402_Initial.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230324070125_Initial.cs index 8355eaab06..7af7c9a871 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230314024402_Initial.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/20230324070125_Initial.cs @@ -292,6 +292,22 @@ namespace MyCompanyName.MyProjectName.Host.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -990,6 +1006,9 @@ namespace MyCompanyName.MyProjectName.Host.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/MyProjectNameDbContextModelSnapshot.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/MyProjectNameDbContextModelSnapshot.cs index 0dc839a24f..3d693cc761 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/MyProjectNameDbContextModelSnapshot.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Host/Migrations/MyProjectNameDbContextModelSnapshot.cs @@ -830,6 +830,33 @@ namespace MyCompanyName.MyProjectName.Host.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230314024433_Initial.Designer.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230324070202_Initial.Designer.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230314024433_Initial.Designer.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230324070202_Initial.Designer.cs index e2cab42a1f..1f2dc7a5fb 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230314024433_Initial.Designer.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230324070202_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Mvc.Migrations { [DbContext(typeof(MyProjectNameDbContext))] - [Migration("20230314024433_Initial")] + [Migration("20230324070202_Initial")] partial class Initial { /// @@ -833,6 +833,33 @@ namespace MyCompanyName.MyProjectName.Mvc.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230314024433_Initial.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230324070202_Initial.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230314024433_Initial.cs rename to templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230324070202_Initial.cs index 64f21c71e9..1bb1b884bd 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230314024433_Initial.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/20230324070202_Initial.cs @@ -292,6 +292,22 @@ namespace MyCompanyName.MyProjectName.Mvc.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -990,6 +1006,9 @@ namespace MyCompanyName.MyProjectName.Mvc.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/MyProjectNameDbContextModelSnapshot.cs b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/MyProjectNameDbContextModelSnapshot.cs index bad5296c0c..835bdad6be 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/MyProjectNameDbContextModelSnapshot.cs +++ b/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Mvc/Migrations/MyProjectNameDbContextModelSnapshot.cs @@ -830,6 +830,33 @@ namespace MyCompanyName.MyProjectName.Mvc.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/EntityFrameworkCore/MyProjectNameDbContext.cs b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/EntityFrameworkCore/MyProjectNameDbContext.cs index 46f1217ffa..e1afd1a339 100644 --- a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/EntityFrameworkCore/MyProjectNameDbContext.cs +++ b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/EntityFrameworkCore/MyProjectNameDbContext.cs @@ -45,6 +45,7 @@ public class MyProjectNameDbContext : public DbSet OrganizationUnits { get; set; } public DbSet SecurityLogs { get; set; } public DbSet LinkUsers { get; set; } + public DbSet UserDelegations { get; set; } // Tenant Management public DbSet Tenants { get; set; } diff --git a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230314023936_Initial.Designer.cs b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230324065930_Initial.Designer.cs similarity index 98% rename from templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230314023936_Initial.Designer.cs rename to templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230324065930_Initial.Designer.cs index 44019ac4ca..effdc6d3ee 100644 --- a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230314023936_Initial.Designer.cs +++ b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230324065930_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Migrations { [DbContext(typeof(MyProjectNameDbContext))] - [Migration("20230314023936_Initial")] + [Migration("20230324065930_Initial")] partial class Initial { /// @@ -886,6 +886,32 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230314023936_Initial.cs b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230324065930_Initial.cs similarity index 98% rename from templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230314023936_Initial.cs rename to templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230324065930_Initial.cs index f594ae7458..ccf3e9776c 100644 --- a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230314023936_Initial.cs +++ b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/20230324065930_Initial.cs @@ -313,6 +313,22 @@ namespace MyCompanyName.MyProjectName.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -1019,6 +1035,9 @@ namespace MyCompanyName.MyProjectName.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/MyProjectNameDbContextModelSnapshot.cs b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/MyProjectNameDbContextModelSnapshot.cs index db36717434..3805a9ee89 100644 --- a/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/MyProjectNameDbContextModelSnapshot.cs +++ b/templates/app/aspnet-core/src/MyCompanyName.MyProjectName.EntityFrameworkCore/Migrations/MyProjectNameDbContextModelSnapshot.cs @@ -883,6 +883,32 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230314024642_Initial.Designer.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230324070230_Initial.Designer.cs similarity index 98% rename from templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230314024642_Initial.Designer.cs rename to templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230324070230_Initial.Designer.cs index 5d2f29ad1d..4c20a44d53 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230314024642_Initial.Designer.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230324070230_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Migrations { [DbContext(typeof(AuthServerDbContext))] - [Migration("20230314024642_Initial")] + [Migration("20230324070230_Initial")] partial class Initial { /// @@ -833,6 +833,33 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230314024404_Initial.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230324070230_Initial.cs similarity index 98% rename from templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230314024404_Initial.cs rename to templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230324070230_Initial.cs index e4e66c791a..3c62b40bf4 100644 --- a/templates/app-nolayers/aspnet-core/MyCompanyName.MyProjectName.Blazor.WebAssembly/Server/Migrations/20230314024404_Initial.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/20230324070230_Initial.cs @@ -292,6 +292,22 @@ namespace MyCompanyName.MyProjectName.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -990,6 +1006,9 @@ namespace MyCompanyName.MyProjectName.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/AuthServerDbContextModelSnapshot.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/AuthServerDbContextModelSnapshot.cs index db9401d3a9..931645fcd4 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/AuthServerDbContextModelSnapshot.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.AuthServer/Migrations/AuthServerDbContextModelSnapshot.cs @@ -830,6 +830,33 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230314024129_Initial.Designer.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230324070306_Initial.Designer.cs similarity index 98% rename from templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230314024129_Initial.Designer.cs rename to templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230324070306_Initial.Designer.cs index 26b508fa35..ec67c21814 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230314024129_Initial.Designer.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230324070306_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Blazor.Server.Host.Migrations { [DbContext(typeof(UnifiedDbContext))] - [Migration("20230314024129_Initial")] + [Migration("20230324070306_Initial")] partial class Initial { /// @@ -833,6 +833,33 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Host.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230314024129_Initial.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230324070306_Initial.cs similarity index 97% rename from templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230314024129_Initial.cs rename to templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230324070306_Initial.cs index efc30c3e7a..bb45390890 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230314024129_Initial.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/20230324070306_Initial.cs @@ -292,6 +292,22 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Host.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -827,6 +843,9 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Host.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/UnifiedDbContextModelSnapshot.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/UnifiedDbContextModelSnapshot.cs index 2b067dbd97..82640002ba 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/UnifiedDbContextModelSnapshot.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Blazor.Server.Host/Migrations/UnifiedDbContextModelSnapshot.cs @@ -830,6 +830,33 @@ namespace MyCompanyName.MyProjectName.Blazor.Server.Host.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230314024104_Initial.Designer.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230324070335_Initial.Designer.cs similarity index 98% rename from templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230314024104_Initial.Designer.cs rename to templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230324070335_Initial.Designer.cs index 60700e19ff..4f740ff8a5 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230314024104_Initial.Designer.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230324070335_Initial.Designer.cs @@ -13,7 +13,7 @@ using Volo.Abp.EntityFrameworkCore; namespace MyCompanyName.MyProjectName.Migrations { [DbContext(typeof(UnifiedDbContext))] - [Migration("20230314024104_Initial")] + [Migration("20230324070335_Initial")] partial class Initial { /// @@ -833,6 +833,33 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId") diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230314024104_Initial.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230324070335_Initial.cs similarity index 97% rename from templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230314024104_Initial.cs rename to templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230324070335_Initial.cs index 172f52146e..fddce44b7d 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230314024104_Initial.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/20230324070335_Initial.cs @@ -292,6 +292,22 @@ namespace MyCompanyName.MyProjectName.Migrations table.PrimaryKey("PK_AbpTenants", x => x.Id); }); + migrationBuilder.CreateTable( + name: "AbpUserDelegations", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + SourceUserId = table.Column(type: "uniqueidentifier", nullable: false), + TargetUserId = table.Column(type: "uniqueidentifier", nullable: false), + StartTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_AbpUserDelegations", x => x.Id); + }); + migrationBuilder.CreateTable( name: "AbpUsers", columns: table => new @@ -827,6 +843,9 @@ namespace MyCompanyName.MyProjectName.Migrations migrationBuilder.DropTable( name: "AbpUserClaims"); + migrationBuilder.DropTable( + name: "AbpUserDelegations"); + migrationBuilder.DropTable( name: "AbpUserLogins"); diff --git a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/UnifiedDbContextModelSnapshot.cs b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/UnifiedDbContextModelSnapshot.cs index 72be56741e..02398bbd56 100644 --- a/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/UnifiedDbContextModelSnapshot.cs +++ b/templates/module/aspnet-core/host/MyCompanyName.MyProjectName.Web.Unified/Migrations/UnifiedDbContextModelSnapshot.cs @@ -830,6 +830,33 @@ namespace MyCompanyName.MyProjectName.Migrations b.ToTable("AbpUserClaims", (string)null); }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserDelegation", b => + { + b.Property("Id") + .ValueGeneratedOnAdd() + .HasColumnType("uniqueidentifier"); + + b.Property("EndTime") + .HasColumnType("datetime2"); + + b.Property("SourceUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("StartTime") + .HasColumnType("datetime2"); + + b.Property("TargetUserId") + .HasColumnType("uniqueidentifier"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.HasKey("Id"); + + b.ToTable("AbpUserDelegations", (string)null); + }); + modelBuilder.Entity("Volo.Abp.Identity.IdentityUserLogin", b => { b.Property("UserId")