style: 全局代码格式化

Former-commit-id: bb50c8419b8fcdeb48c93fce9f399d901e8f5a52
This commit is contained in:
郝先瑞
2022-05-04 15:02:33 +08:00
parent e563bc340c
commit 11f02c0254
136 changed files with 11147 additions and 9780 deletions

View File

@@ -1,11 +1,9 @@
export interface PageQueryParam {
pageNum: number,
pageSize: number
pageNum: number;
pageSize: number;
}
export interface PageResult<T> {
list: T,
total: number
list: T;
total: number;
}

View File

@@ -2,8 +2,8 @@
* Seata表单类型声明
*/
export interface SeataFormData {
openTx: boolean;
stockEx: boolean;
accountEx: boolean;
orderEx: boolean;
}
openTx: boolean;
stockEx: boolean;
accountEx: boolean;
orderEx: boolean;
}

View File

@@ -1,4 +1,4 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 订单查询参数类型声明
@@ -38,7 +38,7 @@ export interface OrderItem {
/**
* 订单分页项类型声明
*/
export type OrderPageResult = PageResult<Order[]>
export type OrderPageResult = PageResult<Order[]>;
/**
* 订单表单类型声明
@@ -53,4 +53,4 @@ export interface OrderDetail {
sort: number;
url: string;
remark: string;
}
}

View File

@@ -1,34 +1,33 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 品牌查询参数类型声明
*/
export interface BrandQueryParam extends PageQueryParam {
name?: string
name?: string;
}
/**
* 品牌分页列表项声明
*/
export interface BrandItem {
id: string;
name: string;
logoUrl: string;
sort: number;
id: string;
name: string;
logoUrl: string;
sort: number;
}
/**
* 品牌分页项类型声明
*/
export type BrandPageResult = PageResult<BrandItem[]>
export type BrandPageResult = PageResult<BrandItem[]>;
/**
* 品牌表单类型声明
*/
export interface BrandFormData {
id: number | undefined,
name: string,
logoUrl: string,
sort: number
}
id: number | undefined;
name: string;
logoUrl: string;
sort: number;
}

View File

@@ -1,11 +1,11 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 商品查询参数类型声明
*/
export interface GoodsQueryParam extends PageQueryParam {
name?: stirng,
categoryId?: number
name?: stirng;
categoryId?: number;
}
/**
@@ -48,25 +48,23 @@ export interface SkuItem {
/**
* 商品分页项类型声明
*/
export type GoodsPageResult = PageResult<GoodsItem[]>
export type GoodsPageResult = PageResult<GoodsItem[]>;
/**
* 商品表单数据类型声明
*/
export interface GoodsDetail {
id?: string,
name?: string,
categoryId?: string,
brandId?: string,
originPrice?: number,
price?: number,
picUrl?: string,
album: string[],
description?: string,
detail?: string,
attrList: any[],
specList: any[],
skuList: any[]
id?: string;
name?: string;
categoryId?: string;
brandId?: string;
originPrice?: number;
price?: number;
picUrl?: string;
album: string[];
description?: string;
detail?: string;
attrList: any[];
specList: any[];
skuList: any[];
}

View File

@@ -1,38 +1,38 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 广告查询参数类型声明
*/
export interface AdvertQueryParam extends PageQueryParam {
title?: string
title?: string;
}
/**
* 广告分页列表项声明
*/
export interface AdvertItem {
id: string;
name: string;
logoUrl: string;
sort: number;
id: string;
name: string;
logoUrl: string;
sort: number;
}
/**
* 广告分页项类型声明
*/
export type AdvertPageResult = PageResult<AdvertItem[]>
export type AdvertPageResult = PageResult<AdvertItem[]>;
/**
* 广告表单类型声明
*/
export interface AdvertFormData {
id?: number;
title: string;
picUrl: string;
beginTime: string;
endTime: string;
status: number;
sort: number;
url: string;
remark: string;
}
id?: number;
title: string;
picUrl: string;
beginTime: string;
endTime: string;
status: number;
sort: number;
url: string;
remark: string;
}

View File

@@ -1,21 +1,20 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 客户端查询参数类型声明
*/
export interface ClientQueryParam extends PageQueryParam {
/**
* 客户端名称
*/
clientId: string | undefined
/**
* 客户端名称
*/
clientId: string | undefined;
}
/**
* 客户端分页列表项声明
*/
export interface ClientItem {
clientId: string;
clientId: string;
clientSecret: string;
resourceIds: string;
scope: string;
@@ -31,20 +30,20 @@ export interface ClientItem {
/**
* 客户端分页项类型声明
*/
export type ClientPageResult = PageResult<ClientItem[]>
export type ClientPageResult = PageResult<ClientItem[]>;
/**
* 客户端表单类型声明
*/
export interface ClientFormData {
authorizedGrantTypes: string;
clientId: string;
clientSecret: string;
accessTokenValidity: string;
refreshTokenValidity: string;
webServerRedirectUri: string;
authorities: string;
additionalInformation: string;
autoapprove: string;
scope:string;
}
authorizedGrantTypes: string;
clientId: string;
clientSecret: string;
accessTokenValidity: string;
refreshTokenValidity: string;
webServerRedirectUri: string;
authorities: string;
additionalInformation: string;
autoapprove: string;
scope: string;
}

View File

@@ -1,10 +1,9 @@
/**
* 部门查询参数类型声明
*/
export interface DeptQueryParam {
name: string | undefined,
status: number | undefined
name: string | undefined;
status: number | undefined;
}
/**
@@ -12,25 +11,25 @@ export interface DeptQueryParam {
*/
export interface DeptItem {
id: string;
name: string;
parentId: string;
treePath: string;
sort: number;
status: number;
leader?: string;
mobile?: string;
email?: string;
children: DeptItem[];
id: string;
name: string;
parentId: string;
treePath: string;
sort: number;
status: number;
leader?: string;
mobile?: string;
email?: string;
children: DeptItem[];
}
/**
* 部门表单类型声明
*/
export interface DeptFormData {
id?: string,
parentId: string,
name: string,
sort: number,
status: number
}
id?: string;
parentId: string;
name: string;
sort: number;
status: number;
}

View File

@@ -1,87 +1,86 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 字典查询参数类型声明
*/
export interface DictQueryParam extends PageQueryParam {
/**
* 字典名称
*/
name: string | undefined
/**
* 字典名称
*/
name: string | undefined;
}
/**
* 字典分页列表项声明
*/
export interface Dict {
id: number;
code: string;
name: string;
status: number;
remark: string;
id: number;
code: string;
name: string;
status: number;
remark: string;
}
/**
* 字典分页项类型声明
*/
export type DictPageResult = PageResult<Dict[]>
export type DictPageResult = PageResult<Dict[]>;
/**
* 字典表单类型声明
*/
export interface DictFormData {
id: number | undefined,
name: string,
code: string,
status: number,
remark: string
id: number | undefined;
name: string;
code: string;
status: number;
remark: string;
}
/**
* 字典项查询参数类型声明
*/
export interface DictItemQueryParam extends PageQueryParam {
/**
* 字典项名称
*/
name: string | undefined;
/**
* 字典编码
*/
dictCode: string | undefined;
/**
* 字典项名称
*/
name: string | undefined;
/**
* 字典编码
*/
dictCode: string | undefined;
}
/**
* 字典分页列表项声明
*/
export interface DictItem {
id: number;
name: string;
value: string;
dictCode: string;
sort: number;
status: number;
defaulted: number;
remark?: string;
id: number;
name: string;
value: string;
dictCode: string;
sort: number;
status: number;
defaulted: number;
remark?: string;
}
/**
* 字典分页项类型声明
*/
export type DictItemPageResult = PageResult<DictItem[]>
export type DictItemPageResult = PageResult<DictItem[]>;
/**
* 字典表单类型声明
*/
export interface DictItemFormData {
id?: number;
dictCode?:string,
dictName?:string;
name: string;
code: string;
value: string;
status: number;
sort: number;
remark: string;
}
id?: number;
dictCode?: string;
dictName?: string;
name: string;
code: string;
value: string;
status: number;
sort: number;
remark: string;
}

View File

@@ -2,26 +2,25 @@
* 登录表单类型声明
*/
export interface LoginFormData {
username: string,
password: string,
grant_type: string,
code: string,
uuid: string,
username: string;
password: string;
grant_type: string;
code: string;
uuid: string;
}
/**
* 登录响应类型声明
*/
export interface LoginResponseData {
access_token: string,
token_type: string
access_token: string;
token_type: string;
}
/**
* 验证码类型声明
*/
export interface Captcha {
img: string,
uuid: string
img: string;
uuid: string;
}

View File

@@ -1,9 +1,8 @@
/**
* 菜单查询参数类型声明
*/
export interface MenuQueryParam {
name?: string
name?: string;
}
/**
@@ -11,58 +10,58 @@ export interface MenuQueryParam {
*/
export interface MenuItem {
id: number;
parentId: number;
gmtCreate: string;
gmtModified: string;
name: string;
icon: string;
component: string;
sort: number;
visible: number;
children: MenuItem[];
id: number;
parentId: number;
gmtCreate: string;
gmtModified: string;
name: string;
icon: string;
component: string;
sort: number;
visible: number;
children: MenuItem[];
}
/**
* 菜单表单类型声明
*/
export interface MenuFormData {
/**
* 菜单ID
*/
id?: string,
/**
* 父菜单ID
*/
parentId: string,
/**
* 菜单名称
*/
name: string,
/**
* 菜单是否可见(1:是;0:否;)
*/
visible: number,
icon?: string,
/**
* 排序
*/
sort: number,
/**
* 组件路径
*/
component?: string,
/**
* 路由路径
*/
path: string,
/**
* 跳转路由路径
*/
redirect?: string,
/**
* 菜单ID
*/
id?: string;
/**
* 父菜单ID
*/
parentId: string;
/**
* 菜单名称
*/
name: string;
/**
* 菜单是否可见(1:是;0:否;)
*/
visible: number;
icon?: string;
/**
* 排序
*/
sort: number;
/**
* 组件路径
*/
component?: string;
/**
* 路由路径
*/
path: string;
/**
* 跳转路由路径
*/
redirect?: string;
/**
* 菜单类型(1:菜单2目录3外链)
*/
type: string
}
/**
* 菜单类型(1:菜单2目录3外链)
*/
type: string;
}

View File

@@ -1,37 +1,37 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 权限查询参数类型声明
*/
export interface PermQueryParam extends PageQueryParam {
menuId: any;
name: string | undefined;
menuId: any;
name: string | undefined;
}
/**
* 权限分页列表项声明
*/
export interface PermItem {
id: number;
name: string;
menuId: string;
urlPerm: string;
btnPerm: string;
roles?: string[];
id: number;
name: string;
menuId: string;
urlPerm: string;
btnPerm: string;
roles?: string[];
}
/**
* 权限分页项类型声明
*/
export type PermPageResult = PageResult<PermItem[]>
export type PermPageResult = PageResult<PermItem[]>;
/**
* 权限表单类型声明
*/
export interface PermFormData {
id: number|undefined,
name: string,
urlPerm: string,
btnPerm: string,
menuId: string
}
id: number | undefined;
name: string;
urlPerm: string;
btnPerm: string;
menuId: string;
}

View File

@@ -1,17 +1,17 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 角色查询参数类型声明
*/
export interface RoleQueryParam extends PageQueryParam {
name?: string
name?: string;
}
/**
* 角色分页列表项声明
*/
export interface RoleItem {
id: string;
id: string;
name: string;
code: string;
sort: number;
@@ -21,19 +21,18 @@ export interface RoleItem {
permissionIds?: any;
}
/**
* 角色分页项类型声明
*/
export type RolePageResult = PageResult<RoleItem[]>
export type RolePageResult = PageResult<RoleItem[]>;
/**
* 角色表单类型声明
*/
export interface RoleFormData {
id: number|undefined,
name: string,
code: string,
sort: number,
status: number
}
id: number | undefined;
name: string;
code: string;
sort: number;
status: number;
}

View File

@@ -1,67 +1,67 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 登录用户类型声明
*/
export interface UserInfo {
nickname: string,
avatar: string,
roles: string[],
perms: string[]
nickname: string;
avatar: string;
roles: string[];
perms: string[];
}
/**
* 用户查询参数类型声明
*/
export interface UserQueryParam extends PageQueryParam {
keywords: string,
status: number,
deptId: number
keywords: string;
status: number;
deptId: number;
}
/**
* 用户分页列表项声明
*/
export interface UserItem {
id: string;
username: string;
nickname: string;
mobile: string;
gender: number;
avatar: string;
email: string;
status: number;
deptName: string;
roleNames: string;
gmtCreate: string;
id: string;
username: string;
nickname: string;
mobile: string;
gender: number;
avatar: string;
email: string;
status: number;
deptName: string;
roleNames: string;
gmtCreate: string;
}
/**
* 用户分页项类型声明
*/
export type UserPageResult = PageResult<UserItem[]>
export type UserPageResult = PageResult<UserItem[]>;
/**
* 用户表单类型声明
*/
export interface UserFormData {
id: number | undefined,
deptId: number,
username: string,
nickname: string,
password: string,
mobile: string,
email: string,
gender: number,
status: number,
remark: string,
roleIds: number[]
id: number | undefined;
deptId: number;
username: string;
nickname: string;
password: string;
mobile: string;
email: string;
gender: number;
status: number;
remark: string;
roleIds: number[];
}
/**
* 用户导入表单类型声明
* 用户导入表单类型声明
*/
export interface UserImportFormData {
deptId: number,
roleIds: number[]
}
deptId: number;
roleIds: number[];
}

View File

@@ -1,10 +1,10 @@
import { PageQueryParam, PageResult } from "../base"
import { PageQueryParam, PageResult } from '../base';
/**
* 会员查询参数类型声明
*/
export interface MemberQueryParam extends PageQueryParam {
nickName?: string
nickName?: string;
}
/**
@@ -46,19 +46,19 @@ export interface AddressItem {
/**
* 会员分页项类型声明
*/
export type MemberPageResult = PageResult<MemberItem[]>
export type MemberPageResult = PageResult<MemberItem[]>;
/**
* 会员表单类型声明
*/
export interface MemberFormData {
id: number | undefined;
title: string;
picUrl: string;
beginTime: string;
endTime: string;
status: number;
sort: number;
url: string;
remark: string;
}
id: number | undefined;
title: string;
picUrl: string;
beginTime: string;
endTime: string;
status: number;
sort: number;
url: string;
remark: string;
}

11
src/types/common.d.ts vendored
View File

@@ -6,16 +6,15 @@
* 弹窗属性类型声明
*/
export interface Dialog {
title: string,
visible: boolean
title: string;
visible: boolean;
}
/**
* 通用组件选择项类型声明
*/
export interface Option {
value: string,
label: string
children?: Option[]
value: string;
label: string;
children?: Option[];
}

35
src/types/index.d.ts vendored
View File

@@ -1,22 +1,19 @@
export * from './api/system/login';
export * from './api/system/user';
export * from './api/system/role';
export * from './api/system/menu';
export * from './api/system/dept';
export * from './api/system/dict';
export * from './api/system/perm';
export * from './api/system/client';
export * from './api/system/login'
export * from './api/system/user'
export * from './api/system/role'
export * from './api/system/menu'
export * from './api/system/dept'
export * from './api/system/dict'
export * from './api/system/perm'
export * from './api/system/client'
export * from './api/pms/goods';
export * from './api/pms/brand';
export * from './api/sms/advert';
export * from './api/oms/order';
export * from './api/ums/member';
export * from './api/lab/seata';
export * from './store';
export * from './api/pms/goods'
export * from './api/pms/brand'
export * from './api/sms/advert'
export * from './api/oms/order'
export * from './api/ums/member'
export * from './api/lab/seata'
export * from './store'
export * from './common'
export * from './common';

48
src/types/store.d.ts vendored
View File

@@ -1,57 +1,55 @@
import { RouteRecordRaw, RouteLocationNormalized } from "vue-router";
import { RouteRecordRaw, RouteLocationNormalized } from 'vue-router';
/**
* 用户状态类型声明
*/
export interface AppState {
device: string,
sidebar: {
opened: boolean,
withoutAnimation: boolean
},
language: string,
size: string
device: string;
sidebar: {
opened: boolean;
withoutAnimation: boolean;
};
language: string;
size: string;
}
/**
* 权限类型声明
*/
export interface PermissionState {
routes: RouteRecordRaw[]
addRoutes: RouteRecordRaw[]
routes: RouteRecordRaw[];
addRoutes: RouteRecordRaw[];
}
/**
* 设置状态类型声明
*/
export interface SettingState {
theme: string,
tagsView: boolean,
fixedHeader: boolean,
showSettings: boolean,
sidebarLogo: boolean
theme: string;
tagsView: boolean;
fixedHeader: boolean;
showSettings: boolean;
sidebarLogo: boolean;
}
/**
* 标签状态类型声明
*/
export interface TagView extends Partial<RouteLocationNormalized> {
title?: string
title?: string;
}
export interface TagsViewState {
visitedViews: TagView[],
cachedViews: string[]
visitedViews: TagView[];
cachedViews: string[];
}
/**
* 用户状态类型声明
*/
export interface UserState {
token: string,
nickname: string,
avatar: string,
roles: string[],
perms: string[]
token: string;
nickname: string;
avatar: string;
roles: string[];
perms: string[];
}