Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mall.oytour.com
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
黄奎
mall.oytour.com
Commits
379a692f
Commit
379a692f
authored
May 11, 2026
by
吴春
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
分类调整
parent
47b7dbe5
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
33 additions
and
18 deletions
+33
-18
RB_BrandClass.cs
Mall.Model/Entity/TradePavilion/RB_BrandClass.cs
+5
-0
CarrierModule.cs
Mall.Module.TradePavilion/CarrierModule.cs
+15
-6
RB_BrandClassRepository.cs
Mall.Repository/TradePavilion/RB_BrandClassRepository.cs
+5
-9
TradeController.cs
Mall.WebApi/Controllers/TradePavilion/TradeController.cs
+8
-3
No files found.
Mall.Model/Entity/TradePavilion/RB_BrandClass.cs
View file @
379a692f
...
...
@@ -65,5 +65,10 @@ namespace Mall.Model.Entity.TradePavilion
/// 父级分类Id
/// </summary>
public
int
ParentId
{
get
;
set
;
}
/// <summary>
/// 排序
/// </summary>
public
int
SortNum
{
get
;
set
;
}
}
}
Mall.Module.TradePavilion/CarrierModule.cs
View file @
379a692f
...
...
@@ -1213,6 +1213,8 @@ namespace Mall.Module.TradePavilion
{
nameof
(
RB_BrandClass_Extend
.
BrandCategory
),
model
.
BrandCategory
},
{
nameof
(
RB_BrandClass_Extend
.
Status
),
model
.
Status
},
{
nameof
(
RB_BrandClass_Extend
.
UpdateDate
),
model
.
UpdateDate
},
{
nameof
(
RB_BrandClass_Extend
.
ParentId
),
model
.
ParentId
},
{
nameof
(
RB_BrandClass_Extend
.
SortNum
),
model
.
SortNum
},
};
flag
=
brandClassRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_BrandClass_Extend
.
ID
),
model
.
ID
));
}
...
...
@@ -1226,19 +1228,26 @@ namespace Mall.Module.TradePavilion
}
/// <summary>
///删除品牌
状态
///删除品牌
分类
/// </summary>
/// <param name="CompanyId"></param>
/// <param name="Status"></param>
/// <param name="ID"></param>
/// <returns></returns>
public
bool
RemoveBrandClassModule
(
int
CarrierId
)
public
bool
RemoveBrandClassModule
(
int
ID
)
{
var
oldModel
=
GetBrandClassModule
(
ID
);
Dictionary
<
string
,
object
>
fileds
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_BrandClass_Extend
.
Status
),
1
},
};
bool
flag
=
brandClassRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_BrandClass_Extend
.
ID
),
CarrierId
));
bool
flag
=
brandClassRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_BrandClass_Extend
.
ID
),
ID
));
var
childList
=
GetBrandClassListModule
(
new
RB_BrandClass_Extend
()
{
ParentId
=
ID
,
BrandCategory
=
oldModel
.
BrandCategory
});
if
(
childList
!=
null
&&
childList
.
Count
>
0
)
{
foreach
(
var
item
in
childList
)
{
flag
=
brandClassRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_BrandClass_Extend
.
ID
),
item
.
ID
));
}
}
return
flag
;
}
...
...
Mall.Repository/TradePavilion/RB_BrandClassRepository.cs
View file @
379a692f
...
...
@@ -77,14 +77,6 @@ WHERE 1=1
}
else
{
//if (query.TenantId > 0)
//{
// builder.AppendFormat(" AND {0}={1} ", nameof(RB_BrandClass_Extend.TenantId), query.TenantId);
//}
//if (query.MallBaseId > 0)
//{
// builder.AppendFormat(" AND {0}={1} ", nameof(RB_BrandClass_Extend.MallBaseId), query.MallBaseId);
//}
if
(!
string
.
IsNullOrEmpty
(
query
.
ClassName
))
{
builder
.
AppendFormat
(
" AND {0} LIKE @Name "
,
nameof
(
RB_BrandClass_Extend
.
ClassName
));
...
...
@@ -98,8 +90,12 @@ WHERE 1=1
{
builder
.
AppendFormat
(
" AND {0}={1} "
,
nameof
(
RB_BrandClass_Extend
.
ID
),
query
.
ID
);
}
if
(
query
.
ParentId
>
0
)
{
builder
.
AppendFormat
(
" AND {0}={1} "
,
nameof
(
RB_BrandClass_Extend
.
ParentId
),
query
.
ParentId
);
}
}
builder
.
AppendFormat
(
" ORDER BY {0} ASC "
,
nameof
(
RB_BrandClass_Extend
.
SortNum
));
return
Get
<
RB_BrandClass_Extend
>(
builder
.
ToString
(),
parameters
).
ToList
();
}
}
...
...
Mall.WebApi/Controllers/TradePavilion/TradeController.cs
View file @
379a692f
...
...
@@ -1834,6 +1834,7 @@ namespace Mall.WebApi.Controllers.TradePavilion
MallBaseId
=
RequestParm
.
MallBaseId
,
TenantId
=
RequestParm
.
TenantId
,
BrandCategory
=
(
BrandCategoryEnum
)
parms
.
GetInt
(
"BrandCategory"
),
ParentId
=
parms
.
GetInt
(
"ParentId"
)
};
List
<
object
>
list
=
new
List
<
object
>();
var
dataList
=
carrierModule
.
GetBrandClassListModule
(
query
);
...
...
@@ -1846,6 +1847,8 @@ namespace Mall.WebApi.Controllers.TradePavilion
item
.
Logo
,
item
.
BrandCategory
,
BrandCategoryName
=
item
.
BrandCategory
.
GetEnumName
(),
item
.
ParentId
,
item
.
SortNum
,
});
}
return
ApiResult
.
Success
(
data
:
list
);
...
...
@@ -1883,6 +1886,8 @@ namespace Mall.WebApi.Controllers.TradePavilion
Logo
=
parms
.
GetStringValue
(
"Logo"
),
ClassName
=
parms
.
GetStringValue
(
"ClassName"
),
BrandCategory
=
(
BrandCategoryEnum
)
parms
.
GetInt
(
"BrandCategory"
),
ParentId
=
parms
.
GetInt
(
"ParentId"
),
SortNum
=
parms
.
GetInt
(
"SortNum"
),
};
if
(
string
.
IsNullOrWhiteSpace
(
query
.
ClassName
))
{
...
...
@@ -1901,14 +1906,14 @@ namespace Mall.WebApi.Controllers.TradePavilion
}
/// <summary>
/// 删除品牌
信息
/// 删除品牌
分类
/// </summary>
/// <returns></returns>
public
ApiResult
RemoveBrandClass
()
{
JObject
parms
=
JObject
.
Parse
(
RequestParm
.
msg
.
ToString
());
var
Carrier
Id
=
parms
.
GetInt
(
"Id"
,
0
);
var
flag
=
carrierModule
.
RemoveBrandClassModule
(
Carrier
Id
);
var
Id
=
parms
.
GetInt
(
"Id"
,
0
);
var
flag
=
carrierModule
.
RemoveBrandClassModule
(
Id
);
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
...
...
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