修复codefirst
This commit is contained in:
@@ -159,9 +159,6 @@ ServiceLocator.Instance = app.Services;
|
||||
//<2F><><EFBFBD><EFBFBD>ҳ<EFBFBD><D2B3>ע<EFBFBD><D7A2>
|
||||
#endregion
|
||||
app.UseDeveloperExceptionPage();
|
||||
#region
|
||||
//Swagger<65><72><EFBFBD><EFBFBD>ע<EFBFBD><D7A2>
|
||||
#endregion
|
||||
app.UseSwaggerService();
|
||||
}
|
||||
#region
|
||||
|
||||
Binary file not shown.
@@ -8,6 +8,6 @@ namespace Yi.Framework.Model.Models
|
||||
public partial class ArticleEntity:IBaseModelEntity
|
||||
{
|
||||
[Navigate(NavigateType.OneToOne,nameof(UserId))]
|
||||
public UserEntity User { get; set; }
|
||||
public UserEntity? User { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,10 +11,10 @@ namespace Yi.Framework.Model.Models
|
||||
public partial class CategoryEntity:IBaseModelEntity
|
||||
{
|
||||
[SugarColumn(IsIgnore = true)]
|
||||
public List<CategoryEntity> Children { get; set; }
|
||||
public List<CategoryEntity>? Children { get; set; }
|
||||
|
||||
|
||||
[Navigate(NavigateType.OneToMany,nameof(SpecsGroupEntity.CategoryId))]
|
||||
public List<SpecsGroupEntity> SpecsGroups { get; set; }
|
||||
public List<SpecsGroupEntity>? SpecsGroups { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -25,14 +25,14 @@ namespace Yi.Framework.Model.Models
|
||||
|
||||
var r = new VueRouterModel();
|
||||
r.OrderNum = m.OrderNum ?? 0;
|
||||
var routerName = m.Router.Split("/").LastOrDefault();
|
||||
var routerName = m.Router?.Split("/").LastOrDefault();
|
||||
r.Id = m.Id;
|
||||
r.ParentId = (long)m.ParentId;
|
||||
r.ParentId = m.ParentId??-1;
|
||||
|
||||
//开头大写
|
||||
r.Name = routerName.First().ToString().ToUpper() + routerName.Substring(1);
|
||||
r.Name = routerName?.First().ToString().ToUpper() + routerName?.Substring(1);
|
||||
r.Path = m.Router;
|
||||
r.Hidden = (bool)!m.IsShow;
|
||||
r.Hidden =!m.IsShow??false;
|
||||
|
||||
|
||||
if (m.MenuType == MenuTypeEnum.Catalogue.GetHashCode())
|
||||
@@ -62,9 +62,9 @@ namespace Yi.Framework.Model.Models
|
||||
{
|
||||
Title = m.MenuName,
|
||||
Icon = m.MenuIcon,
|
||||
NoCache = (bool)!m.IsCache
|
||||
NoCache = !m.IsCache??true
|
||||
};
|
||||
if ((bool)m.IsLink)
|
||||
if (m.IsLink??false)
|
||||
{
|
||||
r.Meta.link = m.Router;
|
||||
r.AlwaysShow = false;
|
||||
|
||||
@@ -77,6 +77,6 @@ namespace Yi.Framework.Model.Models
|
||||
/// 图片列表
|
||||
///</summary>
|
||||
[SugarColumn(ColumnName="Images",IsJson = true)]
|
||||
public List<string> Images { get; set; }
|
||||
public List<string>? Images { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,9 +10,9 @@ namespace Yi.Framework.Model.Models
|
||||
{
|
||||
|
||||
[Navigate(typeof(RoleMenuEntity),nameof(RoleMenuEntity.RoleId),nameof(RoleMenuEntity.MenuId))]
|
||||
public List<MenuEntity> Menus { get; set; }
|
||||
public List<MenuEntity>? Menus { get; set; }
|
||||
|
||||
[Navigate(typeof(RoleDeptEntity), nameof(RoleDeptEntity.RoleId), nameof(RoleDeptEntity.DeptId))]
|
||||
public List<DeptEntity> Depts { get; set; }
|
||||
public List<DeptEntity>? Depts { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,12 +14,12 @@ namespace Yi.Framework.Model.Models
|
||||
/// 规格sku信息
|
||||
///</summary>
|
||||
[SugarColumn(ColumnName = "SpecsSkuInfo", IsJson = true)]
|
||||
public List<SpecsSkuInfoModel> SpecsSkuInfo { get; set; }
|
||||
public List<SpecsSkuInfoModel>? SpecsSkuInfo { get; set; }
|
||||
/// <summary>
|
||||
/// 规格sku完整信息
|
||||
///</summary>
|
||||
[SugarColumn(ColumnName = "SpecsSkuAllInfo", IsJson = true)]
|
||||
public List<SpecsSkuAllInfoModel> SpecsSkuAllInfo { get; set; }
|
||||
public List<SpecsSkuAllInfoModel>? SpecsSkuAllInfo { get; set; }
|
||||
}
|
||||
|
||||
public class SpecsSkuAllInfoModel
|
||||
|
||||
@@ -11,6 +11,6 @@ namespace Yi.Framework.Model.Models
|
||||
public partial class SpecsGroupEntity:IBaseModelEntity
|
||||
{
|
||||
[Navigate(NavigateType.OneToMany, nameof(SpecsEntity.SpecsGroupId))]
|
||||
public List<SpecsEntity> Specses { get; set; }
|
||||
public List<SpecsEntity>? Specses { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,15 +12,15 @@ namespace Yi.Framework.Model.Models
|
||||
/// 规格Spu完整信息
|
||||
///</summary>
|
||||
[SugarColumn(ColumnName = "SpecsAllInfo", IsJson = true)]
|
||||
public List<SpecsSpuAllInfoModel> SpecsSpuAllInfo { get; set; }
|
||||
public List<SpecsSpuAllInfoModel>? SpecsSpuAllInfo { get; set; }
|
||||
/// <summary>
|
||||
/// 规格Spu信息
|
||||
///</summary>
|
||||
[SugarColumn(ColumnName = "SpecsInfo", IsJson = true)]
|
||||
public List<SpecsSpuInfoModel> SpecsSpuInfo { get; set; }
|
||||
public List<SpecsSpuInfoModel>? SpecsSpuInfo { get; set; }
|
||||
|
||||
[Navigate(NavigateType.OneToMany, nameof(SkuEntity.SpuId))]
|
||||
public List<SpuEntity> Spus { get; set; }
|
||||
public List<SpuEntity>? Spus { get; set; }
|
||||
}
|
||||
|
||||
public class SpecsSpuAllInfoModel
|
||||
|
||||
@@ -12,13 +12,13 @@ namespace Yi.Framework.Model.Models
|
||||
/// 看好啦!ORM精髓,导航属性
|
||||
///</summary>
|
||||
[Navigate(typeof(UserRoleEntity), nameof(UserRoleEntity.UserId), nameof(UserRoleEntity.RoleId))]
|
||||
public List<RoleEntity> Roles { get; set; }
|
||||
public List<RoleEntity>? Roles { get; set; }
|
||||
|
||||
[Navigate(typeof(UserPostEntity), nameof(UserPostEntity.UserId), nameof(UserPostEntity.PostId))]
|
||||
public List<PostEntity> Posts { get; set; }
|
||||
public List<PostEntity>? Posts { get; set; }
|
||||
|
||||
[Navigate( NavigateType.OneToOne,nameof(DeptId))]
|
||||
public DeptEntity Dept { get; set; }
|
||||
public DeptEntity? Dept { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 构建密码,MD5盐值加密
|
||||
|
||||
2
Yi.Vue3.x.Vant/components.d.ts
vendored
2
Yi.Vue3.x.Vant/components.d.ts
vendored
@@ -15,7 +15,6 @@ declare module '@vue/runtime-core' {
|
||||
RouterView: typeof import('vue-router')['RouterView']
|
||||
VanActionSheet: typeof import('vant/es')['ActionSheet']
|
||||
VanButton: typeof import('vant/es')['Button']
|
||||
VanCell: typeof import('vant/es')['Cell']
|
||||
VanCellGroup: typeof import('vant/es')['CellGroup']
|
||||
VanCol: typeof import('vant/es')['Col']
|
||||
VanDivider: typeof import('vant/es')['Divider']
|
||||
@@ -27,7 +26,6 @@ declare module '@vue/runtime-core' {
|
||||
VanList: typeof import('vant/es')['List']
|
||||
VanLoading: typeof import('vant/es')['Loading']
|
||||
VanNavBar: typeof import('vant/es')['NavBar']
|
||||
VanPopup: typeof import('vant/es')['Popup']
|
||||
VanPullRefresh: typeof import('vant/es')['PullRefresh']
|
||||
VanRow: typeof import('vant/es')['Row']
|
||||
VanSticky: typeof import('vant/es')['Sticky']
|
||||
|
||||
@@ -3,7 +3,6 @@ import { ArticleEntity } from '@/type/interface/ArticleEntity'
|
||||
|
||||
export default {
|
||||
add(data:any) {
|
||||
console.log(data)
|
||||
return myaxios({
|
||||
url: `/article/add`,
|
||||
method: 'post',
|
||||
|
||||
@@ -35,8 +35,8 @@ let tabbar=ref([
|
||||
{icon:"wap-home",to:"/",title:"主页"},
|
||||
{icon:"location-o",to:"",title:"发现"},
|
||||
{icon:"",to:"",title:""},
|
||||
// {icon:"friends-o",to:"/shopIndex",title:"商城"},
|
||||
{icon:"friends-o",to:"",title:"商城"},
|
||||
{icon:"friends-o",to:"/shopIndex",title:"商城"},
|
||||
// {icon:"friends-o",to:"",title:"商城"},
|
||||
{icon:"setting-o",to:"/my",title:"我的"},
|
||||
])
|
||||
const onChange=(index:number)=>{
|
||||
@@ -44,8 +44,8 @@ const onChange=(index:number)=>{
|
||||
{icon:"wap-home-o",to:"/",title:"主页"},
|
||||
{icon:"location-o",to:"",title:"发现"},
|
||||
{icon:"",to:"",title:""},
|
||||
// {icon:"friends-o",to:"/shopIndex",title:"商城"},
|
||||
{icon:"friends-o",to:"",title:"商城"},
|
||||
{icon:"friends-o",to:"/shopIndex",title:"商城"},
|
||||
// {icon:"friends-o",to:"",title:"商城"},
|
||||
{icon:"setting-o",to:"/my",title:"我的"},
|
||||
];
|
||||
tabbar.value[index].icon=tabbar.value[index].icon.replace("-o","")
|
||||
|
||||
@@ -42,7 +42,15 @@ myaxios.interceptors.request.use(function(config:any) {
|
||||
myaxios.interceptors.response.use(async function(response) {
|
||||
//成功
|
||||
const resp = response.data
|
||||
|
||||
if(resp.code==401)
|
||||
{
|
||||
Notify({ type: 'warning', message: '登录过期' });
|
||||
//登出
|
||||
useUserStore().logOut().then(() => {
|
||||
location.href = '/';
|
||||
})
|
||||
isRelogin.show = false;
|
||||
}
|
||||
// store.dispatch("closeLoad");
|
||||
return resp;
|
||||
}, async function(error) {
|
||||
|
||||
Reference in New Issue
Block a user