Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
EShop
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
tsai
EShop
Commits
f1a00bac
Commit
f1a00bac
authored
Apr 27, 2020
by
gdlcf88
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make storeId required. close #7
parent
89055787
Changes
16
Hide whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
22 additions
and
24 deletions
+22
-24
Order.cs
...op.Orders/src/EasyAbp.EShop.Orders.Domain/Orders/Order.cs
+1
-1
PaymentRecordOrder.cs
....Payment.Domain/PaymentRecordOrders/PaymentRecordOrder.cs
+1
-1
RefundRecord.cs
...asyAbp.EShop.Payment.Domain/RefundRecords/RefundRecord.cs
+1
-1
CreateUpdateProductCategoryDto.cs
.../ProductCategories/Dtos/CreateUpdateProductCategoryDto.cs
+1
-1
ProductCategoryDto.cs
...hop/Products/ProductCategories/Dtos/ProductCategoryDto.cs
+1
-1
CreateUpdateProductDto.cs
...bp/EShop/Products/Products/Dtos/CreateUpdateProductDto.cs
+1
-1
GetProductListDto.cs
...EasyAbp/EShop/Products/Products/Dtos/GetProductListDto.cs
+1
-1
ProductDto.cs
...tracts/EasyAbp/EShop/Products/Products/Dtos/ProductDto.cs
+1
-1
ProductAppService.cs
...tion/EasyAbp/EShop/Products/Products/ProductAppService.cs
+3
-5
IProductCategoryRepository.cs
.../Products/ProductCategories/IProductCategoryRepository.cs
+2
-2
ProductCategory.cs
...syAbp/EShop/Products/ProductCategories/ProductCategory.cs
+2
-2
Product.cs
...roducts.Domain/EasyAbp/EShop/Products/Products/Product.cs
+2
-2
ProductCategoryRepository.cs
...p/Products/ProductCategories/ProductCategoryRepository.cs
+2
-2
CreateModal.cshtml.cs
...ges/EShop/Products/Products/Product/CreateModal.cshtml.cs
+1
-1
CreateUpdateProductViewModel.cs
...oducts/Product/ViewModels/CreateUpdateProductViewModel.cs
+1
-1
IMultiStore.cs
.../EasyAbp.EShop.Stores.Domain.Shared/Stores/IMultiStore.cs
+1
-1
No files found.
modules/EasyAbp.EShop.Orders/src/EasyAbp.EShop.Orders.Domain/Orders/Order.cs
View file @
f1a00bac
...
...
@@ -10,7 +10,7 @@ namespace EasyAbp.EShop.Orders.Orders
{
public
virtual
Guid
?
TenantId
{
get
;
protected
set
;
}
public
virtual
Guid
?
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
CustomerUserId
{
get
;
protected
set
;
}
...
...
modules/EasyAbp.EShop.Payment/src/EasyAbp.EShop.Payment.Domain/PaymentRecordOrders/PaymentRecordOrder.cs
View file @
f1a00bac
...
...
@@ -10,7 +10,7 @@ namespace EasyAbp.EShop.Payment.PaymentRecordOrders
{
public
virtual
Guid
?
TenantId
{
get
;
protected
set
;
}
public
virtual
Guid
?
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
OrderId
{
get
;
protected
set
;
}
...
...
modules/EasyAbp.EShop.Payment/src/EasyAbp.EShop.Payment.Domain/RefundRecords/RefundRecord.cs
View file @
f1a00bac
...
...
@@ -10,7 +10,7 @@ namespace EasyAbp.EShop.Payment.RefundRecords
{
public
virtual
Guid
?
TenantId
{
get
;
protected
set
;
}
public
virtual
Guid
?
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
OrderId
{
get
;
protected
set
;
}
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Application.Contracts/EasyAbp/EShop/Products/ProductCategories/Dtos/CreateUpdateProductCategoryDto.cs
View file @
f1a00bac
...
...
@@ -7,7 +7,7 @@ namespace EasyAbp.EShop.Products.ProductCategories.Dtos
public
class
CreateUpdateProductCategoryDto
{
[
DisplayName
(
"ProductCategoryStoreId"
)]
public
Guid
?
StoreId
{
get
;
set
;
}
public
Guid
StoreId
{
get
;
set
;
}
[
Required
]
[
DisplayName
(
"ProductCategoryCategoryId"
)]
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Application.Contracts/EasyAbp/EShop/Products/ProductCategories/Dtos/ProductCategoryDto.cs
View file @
f1a00bac
...
...
@@ -5,7 +5,7 @@ namespace EasyAbp.EShop.Products.ProductCategories.Dtos
{
public
class
ProductCategoryDto
:
AuditedEntityDto
<
Guid
>
{
public
Guid
?
StoreId
{
get
;
set
;
}
public
Guid
StoreId
{
get
;
set
;
}
public
Guid
CategoryId
{
get
;
set
;
}
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Application.Contracts/EasyAbp/EShop/Products/Products/Dtos/CreateUpdateProductDto.cs
View file @
f1a00bac
...
...
@@ -9,7 +9,7 @@ namespace EasyAbp.EShop.Products.Products.Dtos
public
class
CreateUpdateProductDto
:
IValidatableObject
{
[
DisplayName
(
"ProductStoreId"
)]
public
Guid
?
StoreId
{
get
;
set
;
}
public
Guid
StoreId
{
get
;
set
;
}
[
Required
]
[
DisplayName
(
"ProductProductTypeId"
)]
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Application.Contracts/EasyAbp/EShop/Products/Products/Dtos/GetProductListDto.cs
View file @
f1a00bac
...
...
@@ -5,7 +5,7 @@ namespace EasyAbp.EShop.Products.Products.Dtos
{
public
class
GetProductListDto
:
PagedAndSortedResultRequestDto
{
public
Guid
?
StoreId
{
get
;
set
;
}
public
Guid
StoreId
{
get
;
set
;
}
public
Guid
?
CategoryId
{
get
;
set
;
}
}
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Application.Contracts/EasyAbp/EShop/Products/Products/Dtos/ProductDto.cs
View file @
f1a00bac
...
...
@@ -6,7 +6,7 @@ namespace EasyAbp.EShop.Products.Products.Dtos
{
public
class
ProductDto
:
FullAuditedEntityDto
<
Guid
>
{
public
Guid
?
StoreId
{
get
;
set
;
}
public
Guid
StoreId
{
get
;
set
;
}
public
Guid
ProductTypeId
{
get
;
set
;
}
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Application/EasyAbp/EShop/Products/Products/ProductAppService.cs
View file @
f1a00bac
...
...
@@ -43,10 +43,8 @@ namespace EasyAbp.EShop.Products.Products
query
=
query
.
Where
(
p
=>
productIds
.
Contains
(
p
.
Id
));
}
else
if
(
input
.
StoreId
.
HasValue
)
{
query
=
query
.
Where
(
p
=>
p
.
StoreId
==
input
.
StoreId
);
}
query
=
query
.
Where
(
p
=>
p
.
StoreId
==
input
.
StoreId
);
return
query
;
}
...
...
@@ -141,7 +139,7 @@ namespace EasyAbp.EShop.Products.Products
return
dto
;
}
protected
virtual
async
Task
UpdateProductCategoriesAsync
(
Guid
productId
,
Guid
?
storeId
,
IEnumerable
<
Guid
>
categoryIds
)
protected
virtual
async
Task
UpdateProductCategoriesAsync
(
Guid
productId
,
Guid
storeId
,
IEnumerable
<
Guid
>
categoryIds
)
{
await
_productCategoryRepository
.
DeleteAsync
(
x
=>
x
.
ProductId
.
Equals
(
productId
));
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Domain/EasyAbp/EShop/Products/ProductCategories/IProductCategoryRepository.cs
View file @
f1a00bac
...
...
@@ -8,8 +8,8 @@ namespace EasyAbp.EShop.Products.ProductCategories
{
public
interface
IProductCategoryRepository
:
IRepository
<
ProductCategory
,
Guid
>
{
Task
<
List
<
ProductCategory
>>
GetListByCategoryId
(
Guid
categoryId
,
Guid
?
storeId
,
CancellationToken
cancellationToken
=
default
);
Task
<
List
<
ProductCategory
>>
GetListByCategoryId
(
Guid
categoryId
,
Guid
storeId
,
CancellationToken
cancellationToken
=
default
);
Task
<
List
<
ProductCategory
>>
GetListByProductId
(
Guid
productId
,
Guid
?
storeId
,
CancellationToken
cancellationToken
=
default
);
Task
<
List
<
ProductCategory
>>
GetListByProductId
(
Guid
productId
,
Guid
storeId
,
CancellationToken
cancellationToken
=
default
);
}
}
\ No newline at end of file
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Domain/EasyAbp/EShop/Products/ProductCategories/ProductCategory.cs
View file @
f1a00bac
...
...
@@ -9,7 +9,7 @@ namespace EasyAbp.EShop.Products.ProductCategories
{
public
virtual
Guid
?
TenantId
{
get
;
protected
set
;
}
public
virtual
Guid
?
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
CategoryId
{
get
;
protected
set
;
}
...
...
@@ -24,7 +24,7 @@ namespace EasyAbp.EShop.Products.ProductCategories
public
ProductCategory
(
Guid
id
,
Guid
?
tenantId
,
Guid
?
storeId
,
Guid
storeId
,
Guid
categoryId
,
Guid
productId
,
int
displayOrder
=
0
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Domain/EasyAbp/EShop/Products/Products/Product.cs
View file @
f1a00bac
...
...
@@ -11,7 +11,7 @@ namespace EasyAbp.EShop.Products.Products
{
public
virtual
Guid
?
TenantId
{
get
;
protected
set
;
}
public
virtual
Guid
?
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
StoreId
{
get
;
protected
set
;
}
public
virtual
Guid
ProductTypeId
{
get
;
protected
set
;
}
...
...
@@ -42,7 +42,7 @@ namespace EasyAbp.EShop.Products.Products
public
Product
(
Guid
id
,
Guid
?
tenantId
,
Guid
?
storeId
,
Guid
storeId
,
Guid
productTypeId
,
string
displayName
,
InventoryStrategy
inventoryStrategy
,
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.EntityFrameworkCore/EasyAbp/EShop/Products/ProductCategories/ProductCategoryRepository.cs
View file @
f1a00bac
...
...
@@ -16,14 +16,14 @@ namespace EasyAbp.EShop.Products.ProductCategories
{
}
public
virtual
async
Task
<
List
<
ProductCategory
>>
GetListByCategoryId
(
Guid
categoryId
,
Guid
?
storeId
,
public
virtual
async
Task
<
List
<
ProductCategory
>>
GetListByCategoryId
(
Guid
categoryId
,
Guid
storeId
,
CancellationToken
cancellationToken
=
default
)
{
return
await
GetQueryable
().
Where
(
pc
=>
pc
.
CategoryId
==
categoryId
&&
pc
.
StoreId
==
storeId
)
.
ToListAsync
(
cancellationToken
);
}
public
virtual
async
Task
<
List
<
ProductCategory
>>
GetListByProductId
(
Guid
productId
,
Guid
?
storeId
,
public
virtual
async
Task
<
List
<
ProductCategory
>>
GetListByProductId
(
Guid
productId
,
Guid
storeId
,
CancellationToken
cancellationToken
=
default
)
{
return
await
GetQueryable
().
Where
(
pc
=>
pc
.
ProductId
==
productId
&&
pc
.
StoreId
==
storeId
)
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Web/Pages/EShop/Products/Products/Product/CreateModal.cshtml.cs
View file @
f1a00bac
...
...
@@ -37,7 +37,7 @@ namespace EasyAbp.EShop.Products.Web.Pages.EShop.Products.Products.Product
_service
=
service
;
}
public
async
Task
OnGetAsync
(
Guid
?
storeId
)
public
async
Task
OnGetAsync
(
Guid
storeId
)
{
ProductTypes
=
(
await
_productTypeAppService
.
GetListAsync
(
new
PagedAndSortedResultRequestDto
...
...
modules/EasyAbp.EShop.Products/src/EasyAbp.EShop.Products.Web/Pages/EShop/Products/Products/Product/ViewModels/CreateUpdateProductViewModel.cs
View file @
f1a00bac
...
...
@@ -13,7 +13,7 @@ namespace EasyAbp.EShop.Products.Web.Pages.EShop.Products.Products.Product.ViewM
{
[
HiddenInput
]
[
Display
(
Name
=
"ProductStore"
)]
public
Guid
?
StoreId
{
get
;
set
;
}
public
Guid
StoreId
{
get
;
set
;
}
[
Required
]
[
SelectItems
(
"ProductTypes"
)]
...
...
modules/EasyAbp.EShop.Stores/src/EasyAbp.EShop.Stores.Domain.Shared/Stores/IMultiStore.cs
View file @
f1a00bac
...
...
@@ -4,6 +4,6 @@ namespace EasyAbp.EShop.Stores.Stores
{
public
interface
IMultiStore
{
Guid
?
StoreId
{
get
;
}
Guid
StoreId
{
get
;
}
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment