diff --git a/src/20260330145422_131_70.jpg b/src/20260330145422_131_70.jpg new file mode 100644 index 00000000..4619e8bd Binary files /dev/null and b/src/20260330145422_131_70.jpg differ diff --git a/src/api/dashboard.ts b/src/api/dashboard.ts new file mode 100644 index 00000000..b9cce1b5 --- /dev/null +++ b/src/api/dashboard.ts @@ -0,0 +1,58 @@ +import request from '@/utils/request' +const v = "1.0" + +export function getDashboardData(method: string, data: any) { + return request({ + url: '/system', + method: 'post', + params: { + method, + v, + timestamp: new Date().getTime() + }, + data: data, + isSystemApi: true + } as any) +} + +/** + * 获取仓库基础统计数据 + */ +export function getWarehouseStats(data: any = {}) { + return getDashboardData('dashboard.warehouseStats', data) +} + +/** + * 获取门店基础统计数据 + */ +export function getStoreStats(data: any = {}) { + return getDashboardData('dashboard.storeStats', data) +} + +/** + * 获取订单趋势数据 + */ +export function getOrderTrend(data: any = {}) { + return getDashboardData('dashboard.orderTrend', data) +} + +/** + * 获取平台分布数据 + */ +export function getPlatformDist(data: any = {}) { + return getDashboardData('dashboard.platformDist', data) +} + +/** + * 获取商品排行数据 + */ +export function getHotOrderRank(data: any = {}) { + return getDashboardData('dashboard.hotOrderRank', data) +} + +/** + * 获取快递占比数据 + */ +export function getExpressRatio(data: any = {}) { + return getDashboardData('dashboard.expressRatio', data) +} diff --git a/src/api/setting/role.ts b/src/api/setting/role.ts new file mode 100644 index 00000000..0d25b6a4 --- /dev/null +++ b/src/api/setting/role.ts @@ -0,0 +1,67 @@ +import request from '@/utils/request' + +const v = "1.0"; + +/** + * 查询当前主体可分配角色列表,可选返回指定工号已选角色 + */ +export function roleList(data: { employee_id?: number, includeDisabled?: boolean, includeSystem?: boolean }) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'setting.role.list', + v, + timestamp: new Date().getTime(), + }, + data + }) +} + +/** + * 给工号新增单个角色绑定 + */ +export function roleAdd(data: { employee_id: number, role_id: number }) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'setting.role.add', + v, + timestamp: new Date().getTime() + }, + data + }) +} + +/** + * 删除工号单个角色绑定 + */ +export function roleDelete(data: { employee_id: number, role_id: number }) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'setting.role.delete', + v, + timestamp: new Date().getTime() + }, + data + }) +} + +/** + * 批量重置工号角色绑定 + */ +export function roleUpdate(data: { employee_id: number, role_ids: number[] }) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'setting.role.update', + v, + timestamp: new Date().getTime() + }, + data + }) +} diff --git a/src/layout/component/TaskView/ScrollPane.vue b/src/layout/component/TaskView/ScrollPane.vue index 3252a843..9e8452c0 100644 --- a/src/layout/component/TaskView/ScrollPane.vue +++ b/src/layout/component/TaskView/ScrollPane.vue @@ -45,11 +45,23 @@ defineExpose({ position: relative; overflow: hidden; width: 100%; + height: 100%; + :deep(.el-scrollbar__bar) { bottom: 0px; + height: 4px; } + :deep(.el-scrollbar__wrap) { - height: 55px; + height: 30px; + overflow-x: auto; + overflow-y: hidden; + } + + :deep(.el-scrollbar__view) { + height: 30px; + display: flex; + align-items: center; } } diff --git a/src/layout/component/TaskView/index.vue b/src/layout/component/TaskView/index.vue index 4d52cc1a..53b98d11 100644 --- a/src/layout/component/TaskView/index.vue +++ b/src/layout/component/TaskView/index.vue @@ -272,72 +272,81 @@ onMounted(() => { display: flex; justify-content: center; align-items: center; - // background: #fafafa; - // border-top: 1px solid #eee; - border-bottom: 1px solid #eee; + background: #fff; + border-bottom: 1px solid #f0f2f5; cursor: pointer; - font-size: 12px; - color: #000000; + font-size: 14px; + color: #909399; + transition: all 0.3s; &:hover { - // background: #f0f2f5; - // color: #409EFF; + background: #f5f7fa; + color: #409EFF; } } .tags-view-wrapper { - height: 32px; - // border-bottom: 1px solid #d8dce5; - // background-color: #e0dbdb; + height: 35px; + width: 100%; + background: #f0f2f5; + border-bottom: 1px solid #d8dce5; + .tags-view-item { display: inline-block; position: relative; cursor: pointer; height: 26px; line-height: 26px; - // border: 1px solid #d8dce5; + border: 1px solid #d8dce5; color: #495060; - background: #b8b5b5; - padding: 0 10px; + background: #fff; + padding: 0 12px; font-size: 12px; - margin-left: 5px; - margin-top: 3px; + margin-left: 6px; + // margin-top: 5px; // 移除 margin-top,改用 flex 居中 + border-radius: 3px; text-decoration: none; + transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1); + &:first-of-type { margin-left: 15px; } &:last-of-type { margin-right: 15px; } + + &:hover { + background-color: #f6f6f6; + border-color: #b4bccc; + } + &.active { background-color: #42b983; color: #fff; - // border-color: #42b983; + border-color: #42b983; &::before { - content: ''; + content: ""; background: #fff; display: inline-block; width: 8px; height: 8px; border-radius: 50%; position: relative; - margin-right: 2px; + margin-right: 4px; } } .close-icon { width: 16px; height: 16px; - vertical-align: 2px; + line-height: 14px; + vertical-align: middle; border-radius: 50%; text-align: center; - transition: all .3s cubic-bezier(.645, .045, .355, 1); + transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1); transform-origin: 100% 50%; margin-left: 5px; - &:before { - transform: scale(.6); - display: inline-block; - vertical-align: -3px; - } + font-size: 12px; + &:hover { background-color: #b4bccc; color: #fff; diff --git a/src/views/dashboard/components/HotOrderRank.vue b/src/views/dashboard/components/HotOrderRank.vue index 38df1616..7c0f9535 100644 --- a/src/views/dashboard/components/HotOrderRank.vue +++ b/src/views/dashboard/components/HotOrderRank.vue @@ -4,24 +4,14 @@