LibNetCore 1.1.1
See the version list below for details.
dotnet add package LibNetCore --version 1.1.1
NuGet\Install-Package LibNetCore -Version 1.1.1
<PackageReference Include="LibNetCore" Version="1.1.1" />
<PackageVersion Include="LibNetCore" Version="1.1.1" />
<PackageReference Include="LibNetCore" />
paket add LibNetCore --version 1.1.1
#r "nuget: LibNetCore, 1.1.1"
#:package LibNetCore@1.1.1
#addin nuget:?package=LibNetCore&version=1.1.1
#tool nuget:?package=LibNetCore&version=1.1.1
Ver contains.
- Common ( Class untilities support processed table, convert type etc)
- Constants contains define constants
- Core Contains class Dependency and Register auto -Data use DBhelper to help query databse, default SQL. -Excel help export data to excel. use template as xml or xls, xlsx to export data
- Filter use filter data input -Resource Lib javascript, ( vuejs)
- Session : use to processed session
- Web : contains Report (rdlc) and register js and css to webform (cshtml)
Detail.
- Required: If you wanna used componet wrote for design form contains: grid, textbox, drop (select2) , You must register Resource LibNetCore . Note. sys required Jquery.
In your project, file programe you config in service as follows.
builder.Services.AddConfigService(); and app.UseConfig();
Next in file _layout.cshtml , you can add 2 code to register javascript and css library. @Html.RegisterCssFromResource() AND @Html.RegisterJsFromResource().
If you use connect db, in file config json you add source code.
"Conect": { "DB_NAME": "dbname", "IPSERVER": "localhost", "USERSQL": "sa", "PWSQL": "sa" },
Okie done, so we can use Lib c# and js
- Report. used report rdlc.
to used it, you can download rdlc for vs on visual studio market or used Report build, save file *.rdl. OKie, to used it, you must using namepase: LibNetCore.Web.
In controller a write as follows
string rdlc = "Report/Benhnhan_Mau".rdlc"; ( Define file report)
ReportHelper rpt = new ReportHelper(rdlc); ( Classs helper processed report)
-List<ReportParameter> paramaters = new List<ReportParameter>(); ( Define report paramater if you have)
and then add paramater and datasource to report if you have
rpt.DataSouce =DataSouce ; rpt.paramaters = paramaters;
next call method export.
var kq = rpt.Export("PDF"); --Call export pdf, we can change to other paramater as excel ( xls) word, html... return byte array, web convert byte array to file save or return to views.
- DATA. to used query database ( defaul SQL server), we used namepace : LibNetCore.Data, when web register config in step 1 then class Session, DbHelper Auto register DI. to used i define.
private IDbHelper _dbHelper; public DanhMucService(IDbHelper dbHelper) { _dbHelper = dbHelper; }
Lib used dapper to query so you can used it as dapper.
var parameters = new DynamicParameters(); -- Define Dynamic db
and call mothod
await _dbHelper.ExecuteNoneQueryAsyn(StoreProcedure, parameters); -- await _dbHelper.ExecuteQueryAsyn(b_sql); -- Execute query SQL await _dbHelper.ExecuteProcedureAsyn<T1>(storeProcedure); -- Execute procedure and return T1 class ( T 1model define), to return more class you can use T1,T2,T3... return Ienumable<T1>...
Link Git demo:
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net6.0
- Dapper (>= 2.0.123)
- Microsoft.Extensions.DependencyInjection (>= 6.0.0)
- Newtonsoft.Json (>= 13.0.1)
- ReportViewerCore.NETCore (>= 15.1.15)
- Serilog.Extensions.Logging.File (>= 1.1.0)
- System.Data.SqlClient (>= 4.8.3)
- System.Drawing.Common (>= 6.0.0)
- System.IdentityModel.Tokens.Jwt (>= 6.15.1)
- System.IO.FileSystem.Primitives (>= 4.3.0)
- System.Text.Encoding.Extensions (>= 4.3.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.