Skip to content

Releases: JJConsulting/JJMasterData

4.1.0

06 Mar 16:12
9dceeda
Compare
Choose a tag to compare

version

A small release to represent our stabilization milestone for public APIs and elements with relationships. This release also contains a new functionality and a critical fix at modals and relationships.

  • SqlDataDictionaryRepository
    Now it caches the FormElement, making operations such as pagination, actions and search much faster.
  • JJDataPanel
    It is now responsible for storing the PageState in a hidden input instead of the JJFormView, making it much easier to work with relationships and modals.
  • Better UI layout at JJMasterData.Web

v4.0.0

09 Jan 14:02
4223c38
Compare
Choose a tag to compare

version

Release Notes ☀️

Relationships

  • The largest feature from this version
  • Now working with 1xn and 1x1 relationships
  • Added FormElementRelationship class
  • You can now define the layout of your relationships
  • You can use any FormElementPanel for your dictionaries

Form Toolbar Actions

  • Added a new category of actions, rendered at the form.
  • If in a relationship, you can use the FormToolbarActionLocation enum to define the location of your action

Removed Metadata class

  • Removed Metadata and related classes
  • The data dictionary is stored at a single JSON using FormElement

Browser tab names

  • You can now tell the difference between your tabs at your browser

Asynchronous programming

  • Added support to async methods at IEntityRepository and IDataDictionaryRepository
  • Added AsyncEventHandler and async overloads to all events

Events

  • Added IGridEventHandler, works like IFormEventHandler but for JJGridView events

Dependency Injection

  • Is now fully used in the entire project
  • Removed the static service locator, you no longer need app.UseJJMasterData at your Program.cs
  • If you want to use a service from JJMasterData, you can inject this following classes:
    UrlRedirectService
    UploadAreaService
    LookupService
    FormValuesService
    FormService
    FieldValuesService
    FieldValidationService
    FieldsService
    FieldFormattingService
    ExpressionsService
    DataItemService
    AuditLogService

DataItemService for example, can be used to retrieve Combobox or Searchbox values without the component.

Expressions

  • Added IAsyncExpressionProvider and IBooleanExpressionProvider, implement your own class to parse expressions

Generated Scripts

  • You can now generate Alter Table scripts for non-existing Data Dictionary fields

Logging

  • File: Added Default, Compact and JSON formatting
  • File & Db: Now run as a HostedService without locking the application

Factories

  • Added IFormElementComponentFactory<T>,IControlFactory<T> and IComponentFactory<T>

Data Dictionaries list

  • New UI at the home
  • Now have a filter for everything filter
  • Info column is now a tooltip when the element info is not null

Expressions

  • Now have a editor
  • You can now implement IAsyncExpressionProvider and IBooleanExpressionProvider

FormElement

  • Added BIT DataType support (true or false )
  • Added Time DataType support
  • Stored Procedures are now optional

Components

  • Added Color Picker component
  • Added switch option to Checkbox

Custom Bootstrap support

  • You can now use the default JJMasterData layout with custom Bootstrap using the JJMasterData:CustomBootstrapPath configuration key

Breaking Changes 💣

Infrastructure

  • Removed Metadata class
  • The DataDictionary table now only contains the F type by now
  • All older FormElement JSON objects from older versions need to be updated by our CLI tool
  • .NET 6/7 projects no longer support SystemWebAdapters and Response.End calls to improve performance

FormElementDataItem

  • Removed ReplaceTextOnGrid please use GridBehavior enum

Log

  • Removed static Log please use ILogger

Cryptography

  • Removed static Cript please use IEncryptionService or JJMasterDataEncryptionService
  • Beware Cript.64 uses DES instead of AES and is unsafe.

DataAccess

  • .NET 6/7: DataAccess without dependency injection no longer supported
  • DataAccess SQLServer provider now uses Microsoft.Data.SqlClient instead of System.Data.SqlClient

Components

  • Renamed JJBaseView and JJBaseControl to ComponentBase and ControlBase respectically
  • Removed components constructors, for example, instead of new JJFormView("MyElement") use await IFormElementComponentFactory<JJFormView>.CreateAsync("MyElement")
  • JJFormView no longer inherits from JJGridView, compatibility methods and properties added, but they are obsolete.
  • JJFormLog renamed to JJAuditLogView
  • JJFormUpload renamed to JJUploadView
  • Many database and IO operations are now async and return a Task instead of void

Events

  • Removed Action from ActionEventArgs please use ActionName
  • Renamed IFormEvent to IFormEventHandler
  • Removed IFormEventAttribute please use IFormEventHandler.ElementName to allow dynamic event handlin

Component Rendering

  • Removed GetHtml please use GetResultAsync and SendResult

IDataDictionaryRepository

  • GetMetadata to GetFormElementAsync

Namespaces

  • JJMasterData.ReceitaFederal* to JJMasterData.Brasil*
  • JJMasterData.Commons.Criptography.* to JJMasterData.Commons.Security.*
  • JJMasterData.Core.Web.Components.* to JJMasterData.Core.UI.Components.*
  • JJMasterData.Core.FormEvents.* to JJMasterData.Core.Events*
  • JJMasterData.Core.DataDictionary.* to JJMasterData.Core.DataDictionary.Models and JJMasterData.Core.DataDictionary.Repository

v3.1.0

19 Jan 20:00
8a19ee4
Compare
Choose a tag to compare

version

Release Notes 🪐

HTML Rendering

  • JJMasterData.Core no longer contains hard-coded HTML Strings
  • Added HtmlBuilder class, responsible to render a node in the HTML tree

Development

  • Removed JJMasterData.Web.Bootstraper, now JJMasterData.Web.Example is used at development
  • Added a single appsettings.json for every project

.NET

  • .NET 7 is officially supported with C# 11.

DataAccess

  • Added IDataDictionary and IEntityRepository

    image

TagHelpers

  • Added TagHelpers to some JJMasterData components like <jj-formview element-name="YourDictionary"\>

Application Options

  • Now have a web UI
  • You can also test your connection at this view
  • appsettings.json now can be saved at runtime
  • Implement IWritableOptions if you want to write your settings somewhere

L10N

  • You no longer need to truncate your resources table after every update
  • Now uses IStringLocalizer internally

WebApi

  • Now have a File manipulation route

First time setup

  • Automatically creates everything now

Example Project

  • Now have new examples
  • Added validation if the example dictionary does not exist
  • Bootstrap agnostic layout

Data Dictionary

Home

  • Now showcase the dictionary info
  • You can now Render your dictionary from the grid without clicking on edit (finally 🙏)
  • If you export only a single dictionary, a .json exported instead of a .zip

Repository Support

  • MongoDB support 🍃
    You can now store your metadata at MongoDB! Just install JJMasterData.MongoDB
  • File System
    Just use with FileSystemDataDictionaryRepository

Validations

  • Only fields of type VarChar or Text can have a filter of the type Contains.

FormEvents

  • Now support FormEventAttribute to have any class name
  • Python events now support debugging on VSCode
  • Created IFormEventResolver to any custom implementation
  • WebApi can now have FormElement customizations using OnMetadataLoad

Logger

  • Removed Console, EventViewer and Trace from JJMasterData.Commons, just use Microsoft Loggers enabling at your IConfiguration source
  • Splitted file and database into DbLogger and FileLogger
  • New log levels following Microsoft conventions
  • Better log messages using ILogger formatter

Added support to DateTime2

  • A recommended SQLServer DateTime type with milliseconds support

Breaking Changes

DataAccess

  • Removed methods ValueExists, ValueExistsAsync, GetValue, GetValueAsync
  • Removed KeepConnAlive Property

JJBaseView

  • Removed RenderHtml, please use RenderHtmlElement

JJUploadFile

  • The event OnPostFile parameter JJFormFile was changed to another class called FormFileContent

JJDataImp

  • OnAfterImport is removed, please use OnAfterUpdate, OnAfterInsert and OnAfterDelete

The events:

  • OnBeforeDelete
  • OnAfterDelete
  • OnBeforeInsert
  • OnAfterInsert
  • OnBeforeUpdate
  • OnAfterUpdate
  • OnBeforeImport

are now fired on JJFormView, JJDataImp and WebApi via FormService.

JJDataPanel

  • JJDataPanel UI related properties moved to UISettings class

JJComboBox

  • Renamed Itens to Items on JJComboBox

JJGridView

  • Renamed SizeTitle to TitleSize
  • Renamed TotalReg to TotalRecords
  • Renamed Erros to Errors
  • Moved DoSqlCommand to ActionManager.ExecuteSqlCommand
  • Moved DoPythonScriptAction to ActionManager.ExecutePythonScriptAction
  • Padronized all public HTML methods to suffix with Html (correct english convention).
  • GridConfigSorting renamed to GridSortingConfig

JJLinkButton

  • Removed property IsSubmit please use LinkButtonType
public enum LinkButtonType
{
    Link = 0,
    Button = 1,
    Submit = 2
}

EventArgs Classes

  • Renamed ResultHtml to HtmlResult 💣

FormEvents

  • Removed OnInstanceCreated please use OnMetadataLoad

WebApi

  • Renamed masterApi/{elementName}/{id}/file/{fieldName}/ route to masterApi/{elementName}/{id}/{fieldName}/file (IMPORTANT @🐍) 💣

Logger

Important ⚠️

  • Default constructors of the components maybe removed in the next version, give a preference to TagHelpers 💣
  • This change will be made to remove the service locator anti-pattern.
  • Using TagHelpers with the Fluent configuration methods, you will see that your code quality will improve without instantiating a JJFormView.

Miscellaneous

  • Removed JJDate,JJDateTime and JJHour, please add the needed attributes to JJTextBox 💣
  • Removed IDataAccess, please use DataAccess
  • Removed ISettings please use IOptions<JJMasterDataOptions>
  • Removed ITranslator please use ILocalizationProvider
  • Renamed JJUploadFile to JJUploadArea
  • Removed TripAdvisor icon ( they were angry with FontAwesome)
  • Moved XUnit Test from FromElement to Metadata
  • Renamed DicParser and related classes to Metadata
  • Renamed method StringManager.NoAccents to StringManager.GetStringWithoutAccents
  • Renamed DataDictionaryManager to FormService
  • Renamed DataDictionaryManagerResult to FormLetter
  • Renamed Factory to EntityRepository 💣
  • Renamed DictionaryDao to DatabaseDataDictionaryRepository 💣