mirror of https://github.com/abpframework/abp.git
82 changed files with 891 additions and 150 deletions
|
After Width: | Height: | Size: 541 KiB |
|
Before Width: | Height: | Size: 56 KiB |
|
After Width: | Height: | Size: 179 KiB |
@ -0,0 +1,82 @@ |
|||
# Alerts |
|||
|
|||
## Introduction |
|||
|
|||
`abp-alert` is a main element to create an alert. |
|||
|
|||
Basic usage: |
|||
|
|||
````xml |
|||
<abp-alert alert-type="Primary"> |
|||
A simple primary alert—check it out! |
|||
</abp-alert> |
|||
```` |
|||
|
|||
|
|||
|
|||
## Demo |
|||
|
|||
See the [alerts demo page](https://bootstrap-taghelpers.abp.io/Components/Alerts) to see it in action. |
|||
|
|||
## Attributes |
|||
|
|||
### alert-type |
|||
|
|||
A value indicates the type of the alert. Should be one of the following values: |
|||
|
|||
* `Default` (default value) |
|||
* `Primary` |
|||
* `Secondary` |
|||
* `Success` |
|||
* `Danger` |
|||
* `Warning` |
|||
* `Info` |
|||
* `Light` |
|||
* `Dark` |
|||
|
|||
Example: |
|||
|
|||
````xml |
|||
<abp-alert alert-type="Warning"> |
|||
A simple warning alert—check it out! |
|||
</abp-alert> |
|||
```` |
|||
|
|||
### alert-link |
|||
|
|||
A value provides matching colored links within any alert. |
|||
|
|||
Example: |
|||
|
|||
````xml |
|||
<abp-alert alert-type="Danger"> |
|||
A simple danger alert with <a abp-alert-link href="#">an example link</a>. Give it a click if you like. |
|||
</abp-alert> |
|||
```` |
|||
|
|||
### dismissible |
|||
|
|||
A value to make the alert dismissible. |
|||
|
|||
Example: |
|||
|
|||
````xml |
|||
<abp-alert alert-type="Warning" dismissible="true"> |
|||
Holy guacamole! You should check in on some of those fields below. |
|||
</abp-alert> |
|||
```` |
|||
|
|||
### Additional content |
|||
|
|||
`abp-alert` can also contain additional HTML elements like headings, paragraphs and dividers. |
|||
|
|||
Example: |
|||
|
|||
````xml |
|||
<abp-alert alert-type="Success"> |
|||
<h4>Well done!</h4> |
|||
<p>Aww yeah, you successfully read this important alert message. This example text is going to run a bit longer so that you can see how spacing within an alert works with this kind of content.</p> |
|||
<hr> |
|||
<p class="mb-0">Whenever you need to, be sure to use margin utilities to keep things nice and tidy.</p> |
|||
</abp-alert> |
|||
```` |
|||
@ -0,0 +1,286 @@ |
|||
# Grids |
|||
|
|||
## Introduction |
|||
|
|||
Abp tag helpers for bootstrap based grid system. |
|||
|
|||
|
|||
|
|||
## Demo |
|||
|
|||
See the [grids demo page](https://bootstrap-taghelpers.abp.io/Components/Grids) to see it in action. |
|||
|
|||
|
|||
|
|||
### Sizing |
|||
|
|||
**Equal Width:** Creates columns with equal width. |
|||
|
|||
Sample: |
|||
|
|||
````xml |
|||
<abp-container> |
|||
<abp-row> |
|||
<abp-column abp-border="Info">1 of 2</abp-column> |
|||
<abp-column abp-border="Danger">2 of 2</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column abp-border="Primary">1 of 3</abp-column> |
|||
<abp-column abp-border="Secondary">2 of 3</abp-column> |
|||
<abp-column abp-border="Dark">3 of 3</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
```` |
|||
|
|||
**Column Breaker:** `abp-column-breaker` is used for breaking the automatic width of placement of the current row and starting in a new row afterwards. |
|||
|
|||
Sample: |
|||
|
|||
````xml |
|||
<abp-container> |
|||
<abp-row> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
<abp-column-breaker/> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
```` |
|||
|
|||
**Setting one column width:** size attribute is used for setting the width for a specific column. |
|||
|
|||
Sample: |
|||
|
|||
```xml |
|||
<abp-container> |
|||
<abp-row> |
|||
<abp-column>1 of 3</abp-column> |
|||
<abp-column size="_6">2 of 3 (wider)</abp-column> |
|||
<abp-column>3 of 3</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column>1 of 3</abp-column> |
|||
<abp-column size="_5">2 of 3 (wider)</abp-column> |
|||
<abp-column>3 of 3</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
``` |
|||
|
|||
**Variable width content:** Auto resizing column based on content. |
|||
|
|||
```xml |
|||
<abp-container> |
|||
<abp-row h-align="Center"> |
|||
<abp-column size-lg="_2" abp-border="Info">1 of 3</abp-column> |
|||
<abp-column size-md="Auto" abp-border="Danger">Contrary to popular belief, Lorem Ipsum is not simply random text.</abp-column> |
|||
<abp-column size-lg="_2" abp-border="Warning">3 of 3</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column>1 of 3</abp-column> |
|||
<abp-column size-md="Auto">Variable width content</abp-column> |
|||
<abp-column size-lg="_2">3 of 3</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
``` |
|||
|
|||
|
|||
|
|||
### Responsive Classes |
|||
|
|||
Responsive classes can be used strongly typed within abp tags. |
|||
|
|||
```xml |
|||
<abp-row> |
|||
<abp-column size-sm="_8">col-sm-8</abp-column> |
|||
<abp-column size-sm="_4">col-sm-4</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column size-sm="_">col-sm</abp-column> |
|||
<abp-column size-sm="_">col-sm</abp-column> |
|||
<abp-column size-sm="_">col-sm</abp-column> |
|||
<abp-column size-sm="_">col-sm</abp-column> |
|||
</abp-row> |
|||
<!-- Stack the columns on mobile by making one full-width and the other half-width --> |
|||
<abp-row> |
|||
<abp-column size="_12" size-md="_8">.col-12 .col-md-8</abp-column> |
|||
<abp-column size="_6" size-md="_4">.col-6 .col-md-4</abp-column> |
|||
</abp-row> |
|||
|
|||
<!-- Columns start at 50% wide on mobile and bump up to 33.3% wide on desktop --> |
|||
<abp-row> |
|||
<abp-column size="_6" size-md="_4">.col-6 .col-md-4</abp-column> |
|||
<abp-column size="_6" size-md="_4">.col-6 .col-md-4</abp-column> |
|||
<abp-column size="_6" size-md="_4">.col-6 .col-md-4</abp-column> |
|||
</abp-row> |
|||
|
|||
<!-- Columns are always 50% wide, on mobile and desktop --> |
|||
<abp-row> |
|||
<abp-column size="_6">.col-6</abp-column> |
|||
<abp-column size="_6">.col-6</abp-column> |
|||
</abp-row> |
|||
``` |
|||
|
|||
|
|||
|
|||
### Alignment |
|||
|
|||
Column alignments can be done strongly typed in abp tags with both vertically and horizontally. |
|||
|
|||
**Vertical-alignment**: `v-align` attribute value is used to align the columns vertically. |
|||
|
|||
Sample: |
|||
|
|||
```xml |
|||
<abp-container> |
|||
<abp-row v-align="Start"> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
</abp-row> |
|||
<abp-row v-align="Center"> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
</abp-row> |
|||
<abp-row v-align="End"> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
<abp-column>column</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
``` |
|||
|
|||
**Horizontal-alignment**: `h-align` attribute value is used to align the columns horizontally. |
|||
|
|||
Sample: |
|||
|
|||
```xml |
|||
<abp-container> |
|||
<abp-row h-align="Start"> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
</abp-row> |
|||
<abp-row h-align="Center"> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
</abp-row> |
|||
<abp-row h-align="End"> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
</abp-row> |
|||
<abp-row h-align="Around"> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
</abp-row> |
|||
<abp-row h-align="Between"> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
``` |
|||
|
|||
**No gutters**: The gutters between columns in predefined grid classes can be removed with `gutters="false"`. This removes the negative `margin`s from `abp-row` and the horizontal `padding` from all immediate children columns. |
|||
|
|||
Sample: |
|||
|
|||
```xml |
|||
<abp-row gutters="false"> |
|||
<abp-column size="_8">One of two columns</abp-column> |
|||
<abp-column size="_4">One of two columns</abp-column> |
|||
</abp-row> |
|||
``` |
|||
|
|||
**Column wrapping**: If more than 12 columns are placed within a single row, each group of extra columns will, as one unit, wrap onto a new line. |
|||
|
|||
Sample: |
|||
|
|||
```xml |
|||
<abp-row> |
|||
<abp-column size="_9">.col-9</abp-column> |
|||
<abp-column size="_4">.col-4<br>Since 9 + 4 = 13 > 12, this 4-column-wide div gets wrapped onto a new line as one contiguous unit.</abp-column> |
|||
<abp-column size="_6">.col-6<br>Subsequent columns continue along the new line.s</abp-column> |
|||
</abp-row> |
|||
``` |
|||
|
|||
|
|||
|
|||
### Reordering |
|||
|
|||
**Order Classes**: `order` attribute is used for controlling the visual order of the content. |
|||
|
|||
Sample: |
|||
|
|||
```xml |
|||
<abp-container> |
|||
<abp-row> |
|||
<abp-column order="_12">First, but Last</abp-column> |
|||
<abp-column>Second, but unordered</abp-column> |
|||
<abp-column order="_6">Third, but Second</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
``` |
|||
|
|||
**Offsetting columns**: `offset` attribute is used for setting the offset of the grid columns. |
|||
|
|||
Sample: |
|||
|
|||
```xml |
|||
<abp-container> |
|||
<abp-row> |
|||
<abp-column size-md="_4">.col-md-4</abp-column> |
|||
<abp-column size-md="_4" offset-md="_4">.col-md-4 .offset-md-4</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column size-md="_3" offset-md="_3">.col-md-3 .offset-md-3</abp-column> |
|||
<abp-column size-md="_3" offset-md="_3">.col-md-3 .offset-md-3</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column size-md="_6" offset-md="_3">.col-md-6 .offset-md-3</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column size-sm="_5" size-md="_6">.col-sm-5 .col-md-6</abp-column> |
|||
<abp-column size-sm="_5" offset-sm="_2" size-md="_6" offset-md="_">.col-sm-5 .offset-sm-2 .col-md-6 .offset-md-0</abp-column> |
|||
</abp-row> |
|||
<abp-row> |
|||
<abp-column size-sm="_6" size-md="_5" size-lg="_6">col-sm-6 .col-md-5 .col-lg-6</abp-column> |
|||
<abp-column size-sm="_6" size-md="_5" offset-md="_2" size-lg="_6" offset-lg="_">.col-sm-6 .col-md-5 .offset-md-2 .col-lg-6 .offset-lg-0</abp-column> |
|||
</abp-row> |
|||
</abp-container> |
|||
``` |
|||
|
|||
|
|||
|
|||
## abp-row Attributes |
|||
|
|||
- **v-align:** A value indicates the vertical positioning of the containing columns. Should be one of the following values: |
|||
* `Default` (default value) |
|||
* `Start` |
|||
* `Center` |
|||
* `End` |
|||
|
|||
- **h-align**: A value indicates the horizontal positioning of the containing columns. Should be one of the following values: |
|||
* `Default` (default value) |
|||
* `Start` |
|||
* `Center` |
|||
* `Around` |
|||
* `Between` |
|||
* `End` |
|||
- **gutter**: A value indicates if the negative `margin` and horizontal `padding` will be removed from all children columns. Will act as `true` value if this attribute is not set. Should be one of the following values: |
|||
* `true` |
|||
* `false` |
|||
|
|||
## abp-column Attributes |
|||
|
|||
- **size:** A value indicates the width of the column from `_`, `Undefined`, `_1`..`_12`, `Auto`. Or can be used with predefined values like: |
|||
- `size-sm` |
|||
- `size-md` |
|||
- `size-lg` |
|||
- `size-xl` |
|||
- **order**: A value indicates the order of column from `Undefined`, `_1`..`_12`, `First` and `Last`. |
|||
- **offset:** A value indicates offset of the column from `_`, `Undefined`, `_1`..`_12`, `Auto`. Or can be used with predefined values like: |
|||
- `offset-sm` |
|||
- `offset-md` |
|||
- `offset-lg` |
|||
- `offset-xl` |
|||
|
|||
@ -0,0 +1,93 @@ |
|||
# Tabs |
|||
|
|||
## Introduction |
|||
|
|||
`abp-tab` is the basic tab navigation content container derived from bootstrap tab element. |
|||
|
|||
Basic usage: |
|||
|
|||
````xml |
|||
<abp-tabs> |
|||
<abp-tab title="Home"> |
|||
Content_Home |
|||
</abp-tab> |
|||
<abp-tab-link title="Link" href="#" /> |
|||
<abp-tab title="profile"> |
|||
Content_Profile |
|||
</abp-tab> |
|||
<abp-tab-dropdown title="Contact" name="ContactDropdown"> |
|||
<abp-tab title="Contact 1" parent-dropdown-name="ContactDropdown"> |
|||
Content_1_Content |
|||
</abp-tab> |
|||
<abp-tab title="Contact 2" parent-dropdown-name="ContactDropdown"> |
|||
Content_2_Content |
|||
</abp-tab> |
|||
</abp-tab-dropdown> |
|||
</abp-tabs> |
|||
```` |
|||
|
|||
|
|||
|
|||
## Demo |
|||
|
|||
See the [cards demo page](https://bootstrap-taghelpers.abp.io/Components/Cards) to see it in action. |
|||
|
|||
## abp-tab Attributes |
|||
|
|||
- **title**: Sets the text of the tab menu. |
|||
- **name:** Sets "id" attribute of generated elements. Default value is a Guid. Not needed unless tabs are changed or modified with Jquery. |
|||
- **active**: Sets the active tab. |
|||
|
|||
Example: |
|||
|
|||
````xml |
|||
<abp-tabs name="TabId"> |
|||
<abp-tab name="nav-home" title="Home"> |
|||
Content_Home |
|||
</abp-tab> |
|||
<abp-tab name="nav-profile" active="true" title="profile"> |
|||
Content_Profile |
|||
</abp-tab> |
|||
<abp-tab name="nav-contact" title="Contact"> |
|||
Content_Contact |
|||
</abp-tab> |
|||
</abp-tabs> |
|||
```` |
|||
|
|||
### Pills |
|||
|
|||
Example: |
|||
|
|||
````xml |
|||
<abp-tabs tab-style="Pill"> |
|||
<abp-tab title="Home"> |
|||
Content_Home |
|||
</abp-tab> |
|||
<abp-tab title="profile"> |
|||
Content_Profile |
|||
</abp-tab> |
|||
<abp-tab title="Contact"> |
|||
Content_Contact |
|||
</abp-tab> |
|||
</abp-tabs> |
|||
```` |
|||
|
|||
### Vertical |
|||
|
|||
**vertical-header-size**: Sets the column width of tab headers. |
|||
|
|||
Example: |
|||
|
|||
````xml |
|||
<abp-tabs tab-style="PillVertical" vertical-header-size="_2" > |
|||
<abp-tab active="true" title="Home"> |
|||
Content_Home |
|||
</abp-tab> |
|||
<abp-tab title="profile"> |
|||
Content_Profile |
|||
</abp-tab> |
|||
<abp-tab title="Contact"> |
|||
Content_Contact |
|||
</abp-tab> |
|||
</abp-tabs> |
|||
```` |
|||
@ -0,0 +1,142 @@ |
|||
# ABP框架v2.3.0已经发布! |
|||
|
|||
在**新冠病毒**的日子里,我们发布了**ABP框架v2.3**, 这篇文章将说明本次发布**新增内容**和过去的两周**我们做了什么**. |
|||
|
|||
## 关于新冠病毒和我们的团队 |
|||
|
|||
关于冠状病毒的状况**我们很难过**.在[Volosoft](https://volosoft.com/)的团队,我们有不同国家的**远程工作者**在自己家里工作.从上周开始,我们已经**完全开始在家远程工作**,包括我们的主要办公室的员工. |
|||
|
|||
我们相信并祈祷人类会在很短的时间内克服这个问题. |
|||
|
|||
## 关于发布周期 |
|||
|
|||
从ABP v2.1.0开始,我们开始**每两周**的周四发布功能版本.本次是该决定后的第3次发布,我们看到这种方式目前运转良好,并提高了我们的灵活性. |
|||
|
|||
我们将继续每两周发布**功能版本**(如v2.4,v2.5).另外,如果需要我们会随时发布**热修复版本**(如v2.3.1,v2.3.2). |
|||
|
|||
## ABP框架v2.3.0新增内容 |
|||
|
|||
我们已在这两周的开发周期内通过**393次提交**完成和合并了 **[104](https://github.com/abpframework/abp/milestone/30?closed=1)个issue和pull request**. |
|||
|
|||
我将介绍这个版本加入的一些新功能和改善. |
|||
|
|||
### React Native移动应用程序 |
|||
|
|||
我们终于完成了**react native移动应用程序**.目前,它可以让你**登录**,管理**用户**和**租户**.它利用ABP框架相同的设置,授权和本地化系统. |
|||
|
|||
应用程序的一些截图: |
|||
|
|||
 |
|||
|
|||
它没有太多的功能,但它是你的移动应用程序一个**完美的起点**,因为它是完全集成到后端并支持多租户. |
|||
|
|||
### Angular TypeScript代理生成器 |
|||
|
|||
从我们的Angular应用程序中调用服务器中的REST端点是很常见的.这种情况下,我们一般创建**服务**(在服务器上包含各个服务的方法)和**模型对象**(对应服务器上的[DTO](https://docs.abp.io/en/abp/latest/Data-Transfer-Objects)). |
|||
|
|||
除了手动创建这样的与服务器交互的服务外,我们可以使用像[NSWAG](https://github.com/RicoSuter/NSwag)工具来为我们生成服务代理.但是NSWAG有以下几个我们遇到的问题: |
|||
|
|||
* 它产生一个**大,单一**的.ts文件; |
|||
* 当你的应用程序增长时,它变得**太大**了. |
|||
* 它不适合ABP框架的 **[模块化](https://docs.abp.io/en/abp/latest/Module-Development-Basics)方式**. |
|||
* 它创建了有点**丑陋的代码**.我们希望有一个干净的代码(就像我们手写的). |
|||
* 它不能生成服务器端声明的相同的**方法签名**(因为swagger.json不能准确地反映后端服务的方法签名).我们已创建了公开服务器端方法约定的端点,来允许客户端生成更好的客户端代理. |
|||
|
|||
因此,我们决定创建一个ABP CLI命令来自动生成typescript客户端代理([#2222](https://github.com/abpframework/abp/issues/2222)),用于在ABP框架中开发REST API. |
|||
|
|||
它用起来很简单.只需要在你Angular应用程序的**根文件夹**运行以下命令 |
|||
|
|||
````bash |
|||
abp generate-proxy |
|||
```` |
|||
|
|||
它只会为你自己的应用程序的服务创建代理.它(默认)不会为你使用的应用程序模块创建代理.有几个选项.参见[CLI文档](https://docs.abp.io/en/abp/latest/CLI). |
|||
|
|||
### 复合主键的CRUD应用服务 |
|||
|
|||
` CrudAppService `是一个很有用的基类,用来为你的实体创建CRUD应用服务.不过,它不支持**复合主键**的实体. `AbstractKeyCrudAppService`是新开发的基类以支持复合主键的实体.更多信息请浏览[文档](https://docs.abp.io/en/abp/latest/Application-Services#abstractkeycrudappservice). |
|||
|
|||
### 添加模块的源代码 |
|||
|
|||
应用程序启动模板带有一些[应用模块](https://docs.abp.io/en/abp/latest/Modules/Index), 以**Nuget和NPM包**的方式**预先安装了** .这样做有几个重要的优点: |
|||
|
|||
* 当新版本可用时, 你可以 **轻松地[升级](https://docs.abp.io/en/abp/latest/CLI#update)** 这些模块. |
|||
* 你的解决方案**更干净**,这样你就可以专注于自己的代码. |
|||
|
|||
但是,当你需要对一个依赖的模块**大量定制**时,就不如它的代码在你的应用程序中那么容易.为了解决这个问题,我们引入了一个[ABP CLI](https://docs.abp.io/en/abp/latest/CLI)的新命令, 在你的解决方案中用代码**替换**Nuget包.用法很简单: |
|||
|
|||
````bash |
|||
abp add-module --with-source-code |
|||
```` |
|||
|
|||
该命令以源代码方式添加模块, 或者如果模块已经以包引用方式添加了, 则替换为源代码,. |
|||
|
|||
> 建议在使用此命令前**保存你的更改**到源代码控制系统, 因为它会修改很多你的代码. |
|||
|
|||
此外,我们也创建了文档来说明如何定制依赖的模块而不改变它们的源代码(见下面的部分).仍然建议以包的方式使用模块,以便在以后可以轻松升级. |
|||
|
|||
> 免费模块的源代码是**MIT**许可,所以你可以自由更改它们并添加到您的解决方案中. |
|||
|
|||
### 切换到预览版 |
|||
|
|||
ABP框架正在迅速发展,我们经常发布新版本.不过,如果你想更紧密地追随它,你可以使用**每日预览包**. |
|||
|
|||
我们创建了一个ABP CLI命令来轻松地为你的解决方案**更新到最新的预览包**.在你的解决方案的根文件夹中运行以下命令: |
|||
|
|||
````bash |
|||
abp switch-to-preview |
|||
```` |
|||
|
|||
它会修改所有ABP相关的NuGet和NPM包的版本.当你需要时你也可以**切换回最新稳定版**: |
|||
|
|||
````bash |
|||
abp switch-to-stable |
|||
```` |
|||
|
|||
更多信息请浏览[ABP CLI文档](https://docs.abp.io/en/abp/latest/CLI#switch-to-preview). |
|||
|
|||
### 文档改进 |
|||
|
|||
#### 扩展/定制依赖应用模块 |
|||
|
|||
我们创建了一个巨大的文档来说明如何定制模块依赖而不改变其源代码.参见[文档](https://docs.abp.io/en/abp/latest/Customizing-Application-Modules-Guide). |
|||
|
|||
除了文档以外,我们已经修订了所有模块([#3166](https://github.com/abpframework/abp/issues/3166)),来使他们的服务更容易扩展和定制. |
|||
|
|||
#### EF Core迁移指南 |
|||
|
|||
最近,我们创建了一个指南,说明ABP启动模板所使用的迁移系统. [该指南](https://docs.abp.io/en/abp/latest/Entity-Framework-Core-Migrations)还介绍了如何定制迁移结构,拆分你的模块跨多个数据库,复用一个模块的表,等等. |
|||
|
|||
#### 从 ASP.NET Boilerplate迁移 |
|||
|
|||
如果你有建立在 ASP.NET Boilerplate的解决方案,我们[创建了一个指南](https://docs.abp.io/en/abp/latest/AspNet-Boilerplate-Migration-Guide),试着帮助迁移你的解决方案到新的ABP框架上. |
|||
|
|||
### 其他一些功能 |
|||
|
|||
#### 框架 |
|||
|
|||
* 添加`IRepository.GetAsync`和`IRepository.FindAsync`方法([#3184](https://github.com/abpframework/abp/issues/3148)). |
|||
|
|||
#### 模块 |
|||
|
|||
* 当创建新租户时获取管理员的密码和电子邮件地址,租户管理模块([#3088](https://github.com/abpframework/abp/issues/3088)). |
|||
* 集成Elastic全文检索, 文档模块([#2901](https://github.com/abpframework/abp/pull/2901)). |
|||
* 新的Quartz后台工作者模块([#2762](https://github.com/abpframework/abp/issues/2762)) |
|||
|
|||
#### 示例 |
|||
|
|||
* 微服务演示添加多租户支持([#3032](https://github.com/abpframework/abp/pull/3032)). |
|||
|
|||
所有的功能, 改善和BUG修复, 请浏览[发布说明](https://github.com/abpframework/abp/releases/tag/2.3.0). |
|||
|
|||
## 下一步? |
|||
|
|||
我们未来几个月的目标如下: |
|||
|
|||
* 完成**文档和示例**,写更多的教程. |
|||
* 使框架和现有模块的更加**可定制和可扩展**. |
|||
* 集成**gRPC**和为所有预置模块实现gRPC端点([#2882](https://github.com/abpframework/abp/issues/2882)). |
|||
* 为ABP框架创建**Blazor UI**, 并在所有模块和启动模板中实现它([#394](https://github.com/abpframework/abp/issues/394)). |
|||
* 为预置模块**添加新功能**,并为[ABP商业版](https://commercial.abp.io/)创建新模块. |
|||
|
|||
更多细节请浏览[GitHub里程碑](https://github.com/abpframework/abp/milestones). |
|||
|
After Width: | Height: | Size: 541 KiB |
|
After Width: | Height: | Size: 179 KiB |
@ -0,0 +1,12 @@ |
|||
namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Modal |
|||
{ |
|||
public enum ButtonsAlign |
|||
{ |
|||
Default, |
|||
Start, |
|||
Center, |
|||
Around, |
|||
Between, |
|||
End |
|||
} |
|||
} |
|||
@ -0,0 +1,18 @@ |
|||
import { Injectable, TrackByFunction } from '@angular/core'; |
|||
|
|||
@Injectable({ |
|||
providedIn: 'root', |
|||
}) |
|||
export class TrackByService<ItemType = any> { |
|||
by<T = ItemType>(key: keyof T): TrackByFunction<T> { |
|||
return ({}, item) => item[key]; |
|||
} |
|||
|
|||
byDeep<T = ItemType>(...keys: (string | number)[]): TrackByFunction<T> { |
|||
return ({}, item) => keys.reduce((acc, key) => acc[key], item); |
|||
} |
|||
|
|||
bySelf<T = ItemType>(): TrackByFunction<T> { |
|||
return ({}, item) => item; |
|||
} |
|||
} |
|||
@ -0,0 +1,33 @@ |
|||
import { TrackByService } from '../services/track-by.service'; |
|||
|
|||
describe('TrackByService', () => { |
|||
const service = new TrackByService(); |
|||
|
|||
describe('#by', () => { |
|||
it('should return a function which tracks a property', () => { |
|||
expect(service.by('x')(284, { x: 1036 })).toBe(1036); |
|||
}); |
|||
}); |
|||
|
|||
describe('#byDeep', () => { |
|||
it('should return a function which tracks a deeply-nested property', () => { |
|||
expect( |
|||
service.byDeep( |
|||
'a', |
|||
'b', |
|||
'c', |
|||
1, |
|||
'x', |
|||
)(284, { |
|||
a: { b: { c: [{ x: 1035 }, { x: 1036 }, { x: 1037 }] } }, |
|||
}), |
|||
).toBe(1036); |
|||
}); |
|||
}); |
|||
|
|||
describe('#bySelf', () => { |
|||
it('should return a function which tracks the item', () => { |
|||
expect(service.bySelf()(284, 'X')).toBe('X'); |
|||
}); |
|||
}); |
|||
}); |
|||
Loading…
Reference in new issue