Commit 566cc104f1463c03e2ee46f7f4fd643df6ea875f
1 parent
759f9f27
提交一个代码。
Showing
27 changed files
with
3286 additions
and
1261 deletions
add_first_upgrade_performance_fields.sql deleted
| 1 | --- 为个人业绩统计表添加首单业绩和升单业绩字段 | |
| 2 | -ALTER TABLE lq_statistics_personal_performance | |
| 3 | -ADD COLUMN F_FirstOrderPerformance decimal(18,2) DEFAULT '0.00' COMMENT '首单业绩' AFTER F_UpgradeOrderCount, | |
| 4 | -ADD COLUMN F_UpgradeOrderPerformance decimal(18,2) DEFAULT '0.00' COMMENT '升单业绩' AFTER F_FirstOrderPerformance; | |
| 5 | - | |
| 6 | --- 为门店总业绩统计表添加首单业绩和升单业绩字段 | |
| 7 | -ALTER TABLE lq_statistics_store_total_performance | |
| 8 | -ADD COLUMN F_FirstOrderPerformance decimal(18,2) DEFAULT '0.00' COMMENT '首单业绩' AFTER F_UpgradeOrderCount, | |
| 9 | -ADD COLUMN F_UpgradeOrderPerformance decimal(18,2) DEFAULT '0.00' COMMENT '升单业绩' AFTER F_FirstOrderPerformance; | |
| 10 | - | |
| 11 | --- 为工资统计表添加首单业绩和升单业绩字段 | |
| 12 | -ALTER TABLE lq_salary_statistics | |
| 13 | -ADD COLUMN F_FirstOrderPerformance decimal(18,2) DEFAULT '0.00' COMMENT '首单业绩' AFTER F_UpgradePerformance, | |
| 14 | -ADD COLUMN F_UpgradeOrderPerformance decimal(18,2) DEFAULT '0.00' COMMENT '升单业绩' AFTER F_FirstOrderPerformance; |
antis-ncc-admin/src/api/extend/statistics.js
0 → 100644
| 1 | +import request from '@/utils/request' | |
| 2 | + | |
| 3 | +// 金三角开卡业绩统计列表 | |
| 4 | +export function getGoldTriangleStatisticsList(params) { | |
| 5 | + return request({ | |
| 6 | + url: '/api/Extend/LqStatistics/get-gold-triangle-statistics-list', | |
| 7 | + method: 'post', | |
| 8 | + data: params | |
| 9 | + }) | |
| 10 | +} | |
| 11 | + | |
| 12 | +// 健康师个人开单业绩统计列表 | |
| 13 | +export function getPersonalPerformanceStatisticsList(params) { | |
| 14 | + return request({ | |
| 15 | + url: '/api/Extend/LqStatistics/get-personal-performance-statistics-list', | |
| 16 | + method: 'post', | |
| 17 | + data: params | |
| 18 | + }) | |
| 19 | +} | |
| 20 | + | |
| 21 | +// 科技部开单业绩统计列表 | |
| 22 | +export function getTechPerformanceStatisticsList(params) { | |
| 23 | + return request({ | |
| 24 | + url: '/api/Extend/LqStatistics/get-tech-performance-statistics-list', | |
| 25 | + method: 'post', | |
| 26 | + data: params | |
| 27 | + }) | |
| 28 | +} | |
| 29 | + | |
| 30 | +// 门店耗卡业绩统计列表 (暂时不可用) | |
| 31 | +export function getStoreConsumePerformanceStatisticsList(params) { | |
| 32 | + return request({ | |
| 33 | + url: '/api/Extend/LqStatistics/get-store-consume-performance-statistics-list', | |
| 34 | + method: 'post', | |
| 35 | + data: params | |
| 36 | + }) | |
| 37 | +} | |
| 38 | + | |
| 39 | +// 个人消耗业绩统计列表 (暂时不可用) | |
| 40 | +export function getDepartmentConsumePerformanceStatisticsList(params) { | |
| 41 | + return request({ | |
| 42 | + url: '/api/Extend/LqStatistics/get-department-consume-performance-statistics-list', | |
| 43 | + method: 'post', | |
| 44 | + data: params | |
| 45 | + }) | |
| 46 | +} | |
| 47 | + | |
| 48 | +// 门店总业绩统计列表 (暂时不可用) | |
| 49 | +export function getStoreTotalPerformanceStatisticsList(params) { | |
| 50 | + return request({ | |
| 51 | + url: '/api/Extend/LqStatistics/get-store-total-performance-statistics-list', | |
| 52 | + method: 'post', | |
| 53 | + data: params | |
| 54 | + }) | |
| 55 | +} | |
| 56 | + | |
| 57 | +// 健康师工资统计列表 | |
| 58 | +export function getSalaryStatisticsList(params) { | |
| 59 | + return request({ | |
| 60 | + url: '/api/Extend/LqStatistics/get-salary-statistics-list', | |
| 61 | + method: 'post', | |
| 62 | + data: params | |
| 63 | + }) | |
| 64 | +} | ... | ... |
antis-ncc-admin/src/router/modules/base.js
| ... | ... | @@ -97,6 +97,72 @@ const baseRouter = [{ |
| 97 | 97 | zhTitle: '工资统计', |
| 98 | 98 | icon: 'icon-ym icon-ym-s-data', |
| 99 | 99 | } |
| 100 | + }, | |
| 101 | + { | |
| 102 | + path: '/goldTriangleStatistics', | |
| 103 | + component: (resolve) => require(['@/views/goldTriangleStatistics/index'], resolve), | |
| 104 | + name: 'goldTriangleStatistics', | |
| 105 | + meta: { | |
| 106 | + title: 'goldTriangleStatistics', | |
| 107 | + affix: false, | |
| 108 | + zhTitle: '金三角开卡业绩统计', | |
| 109 | + icon: 'icon-ym icon-ym-s-data', | |
| 110 | + } | |
| 111 | + }, | |
| 112 | + { | |
| 113 | + path: '/personalPerformanceStatistics', | |
| 114 | + component: (resolve) => require(['@/views/personalPerformanceStatistics/index'], resolve), | |
| 115 | + name: 'personalPerformanceStatistics', | |
| 116 | + meta: { | |
| 117 | + title: 'personalPerformanceStatistics', | |
| 118 | + affix: false, | |
| 119 | + zhTitle: '健康师个人开单业绩统计', | |
| 120 | + icon: 'icon-ym icon-ym-user', | |
| 121 | + } | |
| 122 | + }, | |
| 123 | + { | |
| 124 | + path: '/techPerformanceStatistics', | |
| 125 | + component: (resolve) => require(['@/views/techPerformanceStatistics/index'], resolve), | |
| 126 | + name: 'techPerformanceStatistics', | |
| 127 | + meta: { | |
| 128 | + title: 'techPerformanceStatistics', | |
| 129 | + affix: false, | |
| 130 | + zhTitle: '科技部开单业绩统计', | |
| 131 | + icon: 'icon-ym icon-ym-s-promotion', | |
| 132 | + } | |
| 133 | + }, | |
| 134 | + { | |
| 135 | + path: '/storeConsumePerformanceStatistics', | |
| 136 | + component: (resolve) => require(['@/views/storeConsumePerformanceStatistics/index'], resolve), | |
| 137 | + name: 'storeConsumePerformanceStatistics', | |
| 138 | + meta: { | |
| 139 | + title: 'storeConsumePerformanceStatistics', | |
| 140 | + affix: false, | |
| 141 | + zhTitle: '门店耗卡业绩统计', | |
| 142 | + icon: 'icon-ym icon-ym-s-shop', | |
| 143 | + } | |
| 144 | + }, | |
| 145 | + { | |
| 146 | + path: '/departmentConsumePerformanceStatistics', | |
| 147 | + component: (resolve) => require(['@/views/departmentConsumePerformanceStatistics/index'], resolve), | |
| 148 | + name: 'departmentConsumePerformanceStatistics', | |
| 149 | + meta: { | |
| 150 | + title: 'departmentConsumePerformanceStatistics', | |
| 151 | + affix: false, | |
| 152 | + zhTitle: '个人消耗业绩统计', | |
| 153 | + icon: 'icon-ym icon-ym-user-solid', | |
| 154 | + } | |
| 155 | + }, | |
| 156 | + { | |
| 157 | + path: '/storeTotalPerformanceStatistics', | |
| 158 | + component: (resolve) => require(['@/views/storeTotalPerformanceStatistics/index'], resolve), | |
| 159 | + name: 'storeTotalPerformanceStatistics', | |
| 160 | + meta: { | |
| 161 | + title: 'storeTotalPerformanceStatistics', | |
| 162 | + affix: false, | |
| 163 | + zhTitle: '门店总业绩统计', | |
| 164 | + icon: 'icon-ym icon-ym-s-finance', | |
| 165 | + } | |
| 100 | 166 | } |
| 101 | 167 | ] |
| 102 | 168 | export default baseRouter |
| 103 | 169 | \ No newline at end of file | ... | ... |
antis-ncc-admin/src/views/departmentConsumePerformanceStatistics/index.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="department-consume-performance-statistics-container"> | |
| 3 | + <!-- 搜索卡片 --> | |
| 4 | + <el-card class="search-card"> | |
| 5 | + <div slot="header" class="clearfix"> | |
| 6 | + <span><i class="el-icon-user-solid"></i> 个人消耗业绩统计</span> | |
| 7 | + </div> | |
| 8 | + <div class="search-form"> | |
| 9 | + <el-form :inline="true" :model="searchForm" class="demo-form-inline"> | |
| 10 | + <el-form-item label="统计月份"> | |
| 11 | + <el-date-picker v-model="searchForm.statisticsMonth" type="month" placeholder="选择月份" | |
| 12 | + format="yyyy年MM月" value-format="yyyyMM" :clearable="false" @change="handleSearch"> | |
| 13 | + </el-date-picker> | |
| 14 | + </el-form-item> | |
| 15 | + <el-form-item label="员工姓名"> | |
| 16 | + <el-input v-model="searchForm.employeeName" placeholder="请输入员工姓名" clearable | |
| 17 | + @keyup.enter.native="handleSearch"> | |
| 18 | + </el-input> | |
| 19 | + </el-form-item> | |
| 20 | + <el-form-item label="门店名称"> | |
| 21 | + <el-input v-model="searchForm.storeName" placeholder="请输入门店名称" clearable | |
| 22 | + @keyup.enter.native="handleSearch"> | |
| 23 | + </el-input> | |
| 24 | + </el-form-item> | |
| 25 | + <el-form-item label="岗位"> | |
| 26 | + <el-input v-model="searchForm.position" placeholder="请输入岗位" clearable | |
| 27 | + @keyup.enter.native="handleSearch"> | |
| 28 | + </el-input> | |
| 29 | + </el-form-item> | |
| 30 | + <el-form-item> | |
| 31 | + <el-button type="primary" @click="handleSearch" :loading="loading"> | |
| 32 | + <i class="el-icon-search"></i> 查询 | |
| 33 | + </el-button> | |
| 34 | + <el-button @click="handleReset"> | |
| 35 | + <i class="el-icon-refresh"></i> 重置 | |
| 36 | + </el-button> | |
| 37 | + </el-form-item> | |
| 38 | + </el-form> | |
| 39 | + </div> | |
| 40 | + </el-card> | |
| 41 | + | |
| 42 | + <!-- 表格卡片 --> | |
| 43 | + <el-card class="table-card"> | |
| 44 | + <div slot="header" class="clearfix"> | |
| 45 | + <span><i class="el-icon-s-grid"></i> 个人消耗业绩列表</span> | |
| 46 | + </div> | |
| 47 | + <div class="table-container"> | |
| 48 | + <el-table :data="tableData" v-loading="loading" element-loading-text="加载中..." :height="tableHeight" | |
| 49 | + border stripe style="width: 100%"> | |
| 50 | + <el-table-column prop="EmployeeName" label="员工姓名" width="120" fixed="left"></el-table-column> | |
| 51 | + <el-table-column prop="StoreName" label="门店名称" width="150" fixed="left"></el-table-column> | |
| 52 | + <el-table-column prop="Position" label="岗位" width="100" fixed="left"></el-table-column> | |
| 53 | + <el-table-column prop="TotalPerformance" label="总业绩" width="100" align="right"> | |
| 54 | + <template slot-scope="scope"> | |
| 55 | + {{ formatMoney(scope.row.TotalPerformance) }} | |
| 56 | + </template> | |
| 57 | + </el-table-column> | |
| 58 | + <el-table-column prop="ConsumePerformance" label="消耗业绩" width="100" align="right"> | |
| 59 | + <template slot-scope="scope"> | |
| 60 | + {{ formatMoney(scope.row.ConsumePerformance) }} | |
| 61 | + </template> | |
| 62 | + </el-table-column> | |
| 63 | + <el-table-column prop="OrderCount" label="订单数量" width="100" align="right"></el-table-column> | |
| 64 | + <el-table-column prop="CreateTime" label="创建时间" width="150" align="center"> | |
| 65 | + <template slot-scope="scope"> | |
| 66 | + {{ formatDateTime(scope.row.CreateTime) }} | |
| 67 | + </template> | |
| 68 | + </el-table-column> | |
| 69 | + </el-table> | |
| 70 | + | |
| 71 | + <!-- 分页 --> | |
| 72 | + <div class="pagination-container"> | |
| 73 | + <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 74 | + :current-page="pagination.pageIndex" :page-sizes="[10, 20, 50, 100]" | |
| 75 | + :page-size="pagination.pageSize" :total="pagination.total" | |
| 76 | + layout="total, sizes, prev, pager, next, jumper"> | |
| 77 | + </el-pagination> | |
| 78 | + </div> | |
| 79 | + </div> | |
| 80 | + </el-card> | |
| 81 | + </div> | |
| 82 | +</template> | |
| 83 | + | |
| 84 | +<script> | |
| 85 | +import { getDepartmentConsumePerformanceStatisticsList } from '@/api/extend/statistics' | |
| 86 | + | |
| 87 | +export default { | |
| 88 | + name: 'DepartmentConsumePerformanceStatistics', | |
| 89 | + data() { | |
| 90 | + return { | |
| 91 | + loading: false, | |
| 92 | + tableData: [], | |
| 93 | + tableHeight: 400, | |
| 94 | + searchForm: { | |
| 95 | + statisticsMonth: this.getCurrentMonth(), | |
| 96 | + employeeName: '', | |
| 97 | + storeName: '', | |
| 98 | + position: '' | |
| 99 | + }, | |
| 100 | + pagination: { | |
| 101 | + pageIndex: 1, | |
| 102 | + pageSize: 20, | |
| 103 | + total: 0 | |
| 104 | + } | |
| 105 | + } | |
| 106 | + }, | |
| 107 | + mounted() { | |
| 108 | + this.calculateTableHeight() | |
| 109 | + this.handleSearch() | |
| 110 | + window.addEventListener('resize', this.calculateTableHeight) | |
| 111 | + }, | |
| 112 | + beforeDestroy() { | |
| 113 | + window.removeEventListener('resize', this.calculateTableHeight) | |
| 114 | + }, | |
| 115 | + methods: { | |
| 116 | + getCurrentMonth() { | |
| 117 | + const now = new Date() | |
| 118 | + const year = now.getFullYear() | |
| 119 | + const month = String(now.getMonth() + 1).padStart(2, '0') | |
| 120 | + return `${year}${month}` | |
| 121 | + }, | |
| 122 | + calculateTableHeight() { | |
| 123 | + this.$nextTick(() => { | |
| 124 | + const container = this.$el | |
| 125 | + if (!container) return | |
| 126 | + | |
| 127 | + const containerHeight = container.clientHeight | |
| 128 | + const searchCard = container.querySelector('.search-card') | |
| 129 | + const tableCard = container.querySelector('.table-card') | |
| 130 | + | |
| 131 | + let searchCardHeight = 0 | |
| 132 | + if (searchCard) { | |
| 133 | + searchCardHeight = searchCard.offsetHeight + 20 | |
| 134 | + } | |
| 135 | + | |
| 136 | + const tableCardAvailableHeight = containerHeight - searchCardHeight - 100 | |
| 137 | + const tableCardHeight = Math.max(250, tableCardAvailableHeight) | |
| 138 | + | |
| 139 | + if (tableCard) { | |
| 140 | + tableCard.style.height = tableCardHeight + 'px' | |
| 141 | + } | |
| 142 | + | |
| 143 | + const tableContainer = container.querySelector('.table-container') | |
| 144 | + if (tableContainer) { | |
| 145 | + const cardHeaderHeight = 50 | |
| 146 | + const cardPadding = 30 | |
| 147 | + const tableContainerHeight = tableCardHeight - cardHeaderHeight - cardPadding | |
| 148 | + tableContainer.style.height = tableContainerHeight + 'px' | |
| 149 | + | |
| 150 | + const paginationHeight = 50 | |
| 151 | + const paginationMargin = 10 | |
| 152 | + this.tableHeight = Math.max(100, tableContainerHeight - paginationHeight - paginationMargin) | |
| 153 | + } | |
| 154 | + }) | |
| 155 | + }, | |
| 156 | + async handleSearch() { | |
| 157 | + this.loading = true | |
| 158 | + try { | |
| 159 | + const params = { | |
| 160 | + pageIndex: this.pagination.pageIndex, | |
| 161 | + pageSize: this.pagination.pageSize, | |
| 162 | + statisticsMonth: this.searchForm.statisticsMonth, | |
| 163 | + employeeName: this.searchForm.employeeName, | |
| 164 | + storeName: this.searchForm.storeName, | |
| 165 | + position: this.searchForm.position | |
| 166 | + } | |
| 167 | + | |
| 168 | + const response = await getDepartmentConsumePerformanceStatisticsList(params) | |
| 169 | + this.tableData = response.data.list || [] | |
| 170 | + this.pagination.total = response.data.pagination.total || 0 | |
| 171 | + } catch (error) { | |
| 172 | + this.$message.error('查询失败: ' + error.message) | |
| 173 | + } finally { | |
| 174 | + this.loading = false | |
| 175 | + } | |
| 176 | + }, | |
| 177 | + handleReset() { | |
| 178 | + this.searchForm = { | |
| 179 | + statisticsMonth: this.getCurrentMonth(), | |
| 180 | + employeeName: '', | |
| 181 | + storeName: '', | |
| 182 | + position: '' | |
| 183 | + } | |
| 184 | + this.pagination.pageIndex = 1 | |
| 185 | + this.handleSearch() | |
| 186 | + }, | |
| 187 | + handleSizeChange(val) { | |
| 188 | + this.pagination.pageSize = val | |
| 189 | + this.pagination.pageIndex = 1 | |
| 190 | + this.handleSearch() | |
| 191 | + }, | |
| 192 | + handleCurrentChange(val) { | |
| 193 | + this.pagination.pageIndex = val | |
| 194 | + this.handleSearch() | |
| 195 | + }, | |
| 196 | + formatMoney(value) { | |
| 197 | + if (value === null || value === undefined) return '0.00' | |
| 198 | + return Number(value).toLocaleString('zh-CN', { | |
| 199 | + minimumFractionDigits: 2, | |
| 200 | + maximumFractionDigits: 2 | |
| 201 | + }) | |
| 202 | + }, | |
| 203 | + formatDateTime(value) { | |
| 204 | + if (!value) return '-' | |
| 205 | + return new Date(value).toLocaleString('zh-CN') | |
| 206 | + } | |
| 207 | + } | |
| 208 | +} | |
| 209 | +</script> | |
| 210 | + | |
| 211 | +<style lang="scss" scoped> | |
| 212 | +.department-consume-performance-statistics-container { | |
| 213 | + height: calc(100vh - 60px); | |
| 214 | + display: flex; | |
| 215 | + flex-direction: column; | |
| 216 | + overflow: hidden; | |
| 217 | + padding: 20px; | |
| 218 | + background-color: #f0f2f5; | |
| 219 | + | |
| 220 | + .search-card { | |
| 221 | + flex-shrink: 0; | |
| 222 | + margin-bottom: 20px; | |
| 223 | + border-radius: 8px; | |
| 224 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 225 | + | |
| 226 | + .search-form { | |
| 227 | + .el-form-item { | |
| 228 | + margin-bottom: 10px; | |
| 229 | + } | |
| 230 | + } | |
| 231 | + } | |
| 232 | + | |
| 233 | + .table-card { | |
| 234 | + flex: 1; | |
| 235 | + display: flex; | |
| 236 | + flex-direction: column; | |
| 237 | + overflow: hidden; | |
| 238 | + min-height: 0; | |
| 239 | + border-radius: 8px; | |
| 240 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 241 | + | |
| 242 | + .table-container { | |
| 243 | + height: 100%; | |
| 244 | + display: flex; | |
| 245 | + flex-direction: column; | |
| 246 | + overflow: hidden; | |
| 247 | + position: relative; | |
| 248 | + | |
| 249 | + .el-table { | |
| 250 | + flex: 1; | |
| 251 | + min-height: 0; | |
| 252 | + overflow: auto; | |
| 253 | + } | |
| 254 | + | |
| 255 | + .pagination-container { | |
| 256 | + margin-top: 10px; | |
| 257 | + padding: 5px 0; | |
| 258 | + height: 50px; | |
| 259 | + display: flex; | |
| 260 | + align-items: center; | |
| 261 | + justify-content: flex-end; | |
| 262 | + flex-shrink: 0; | |
| 263 | + } | |
| 264 | + } | |
| 265 | + } | |
| 266 | +} | |
| 267 | +</style> | ... | ... |
antis-ncc-admin/src/views/goldTriangleStatistics/index.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="gold-triangle-statistics-container"> | |
| 3 | + <!-- 搜索卡片 --> | |
| 4 | + <el-card class="search-card"> | |
| 5 | + <div slot="header" class="clearfix"> | |
| 6 | + <span><i class="el-icon-s-data"></i> 金三角开卡业绩统计</span> | |
| 7 | + </div> | |
| 8 | + <div class="search-form"> | |
| 9 | + <el-form :inline="true" :model="searchForm" class="demo-form-inline"> | |
| 10 | + <el-form-item label="统计月份"> | |
| 11 | + <el-date-picker v-model="searchForm.statisticsMonth" type="month" placeholder="选择月份" | |
| 12 | + format="yyyy年MM月" value-format="yyyyMM" :clearable="false" @change="handleSearch"> | |
| 13 | + </el-date-picker> | |
| 14 | + </el-form-item> | |
| 15 | + <el-form-item label="金三角战队"> | |
| 16 | + <el-input v-model="searchForm.goldTriangleName" placeholder="请输入金三角战队名称" clearable | |
| 17 | + @keyup.enter.native="handleSearch"> | |
| 18 | + </el-input> | |
| 19 | + </el-form-item> | |
| 20 | + <el-form-item label="门店名称"> | |
| 21 | + <el-input v-model="searchForm.storeName" placeholder="请输入门店名称" clearable | |
| 22 | + @keyup.enter.native="handleSearch"> | |
| 23 | + </el-input> | |
| 24 | + </el-form-item> | |
| 25 | + <el-form-item> | |
| 26 | + <el-button type="primary" @click="handleSearch" :loading="loading"> | |
| 27 | + <i class="el-icon-search"></i> 查询 | |
| 28 | + </el-button> | |
| 29 | + <el-button @click="handleReset"> | |
| 30 | + <i class="el-icon-refresh"></i> 重置 | |
| 31 | + </el-button> | |
| 32 | + </el-form-item> | |
| 33 | + </el-form> | |
| 34 | + </div> | |
| 35 | + </el-card> | |
| 36 | + | |
| 37 | + <!-- 表格卡片 --> | |
| 38 | + <el-card class="table-card"> | |
| 39 | + <div slot="header" class="clearfix"> | |
| 40 | + <span><i class="el-icon-s-grid"></i> 金三角开卡业绩列表</span> | |
| 41 | + </div> | |
| 42 | + <div class="table-container"> | |
| 43 | + <el-table :data="tableData" v-loading="loading" element-loading-text="加载中..." :height="tableHeight" | |
| 44 | + border stripe style="width: 100%"> | |
| 45 | + <el-table-column prop="GoldTriangleName" label="金三角战队" width="150" fixed="left"></el-table-column> | |
| 46 | + <el-table-column prop="StoreName" label="门店名称" width="150" fixed="left"></el-table-column> | |
| 47 | + <el-table-column prop="OrderCount" label="订单数量" width="100" align="right"></el-table-column> | |
| 48 | + <el-table-column prop="TotalPerformance" label="总业绩金额" width="120" align="right"> | |
| 49 | + <template slot-scope="scope"> | |
| 50 | + {{ formatMoney(scope.row.TotalPerformance) }} | |
| 51 | + </template> | |
| 52 | + </el-table-column> | |
| 53 | + <el-table-column prop="FirstOrderDate" label="首次订单日期" width="120" align="center"> | |
| 54 | + <template slot-scope="scope"> | |
| 55 | + {{ formatDate(scope.row.FirstOrderDate) }} | |
| 56 | + </template> | |
| 57 | + </el-table-column> | |
| 58 | + <el-table-column prop="LastOrderDate" label="最后订单日期" width="120" align="center"> | |
| 59 | + <template slot-scope="scope"> | |
| 60 | + {{ formatDate(scope.row.LastOrderDate) }} | |
| 61 | + </template> | |
| 62 | + </el-table-column> | |
| 63 | + <el-table-column prop="CreateTime" label="创建时间" width="150" align="center"> | |
| 64 | + <template slot-scope="scope"> | |
| 65 | + {{ formatDateTime(scope.row.CreateTime) }} | |
| 66 | + </template> | |
| 67 | + </el-table-column> | |
| 68 | + </el-table> | |
| 69 | + | |
| 70 | + <!-- 分页 --> | |
| 71 | + <div class="pagination-container"> | |
| 72 | + <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 73 | + :current-page="pagination.pageIndex" :page-sizes="[10, 20, 50, 100]" | |
| 74 | + :page-size="pagination.pageSize" :total="pagination.total" | |
| 75 | + layout="total, sizes, prev, pager, next, jumper"> | |
| 76 | + </el-pagination> | |
| 77 | + </div> | |
| 78 | + </div> | |
| 79 | + </el-card> | |
| 80 | + </div> | |
| 81 | +</template> | |
| 82 | + | |
| 83 | +<script> | |
| 84 | +import { getGoldTriangleStatisticsList } from '@/api/extend/statistics' | |
| 85 | + | |
| 86 | +export default { | |
| 87 | + name: 'GoldTriangleStatistics', | |
| 88 | + data() { | |
| 89 | + return { | |
| 90 | + loading: false, | |
| 91 | + tableData: [], | |
| 92 | + tableHeight: 400, | |
| 93 | + searchForm: { | |
| 94 | + statisticsMonth: this.getCurrentMonth(), | |
| 95 | + goldTriangleName: '', | |
| 96 | + storeName: '' | |
| 97 | + }, | |
| 98 | + pagination: { | |
| 99 | + pageIndex: 1, | |
| 100 | + pageSize: 20, | |
| 101 | + total: 0 | |
| 102 | + } | |
| 103 | + } | |
| 104 | + }, | |
| 105 | + mounted() { | |
| 106 | + this.calculateTableHeight() | |
| 107 | + this.handleSearch() | |
| 108 | + window.addEventListener('resize', this.calculateTableHeight) | |
| 109 | + }, | |
| 110 | + beforeDestroy() { | |
| 111 | + window.removeEventListener('resize', this.calculateTableHeight) | |
| 112 | + }, | |
| 113 | + methods: { | |
| 114 | + getCurrentMonth() { | |
| 115 | + const now = new Date() | |
| 116 | + const year = now.getFullYear() | |
| 117 | + const month = String(now.getMonth() + 1).padStart(2, '0') | |
| 118 | + return `${year}${month}` | |
| 119 | + }, | |
| 120 | + calculateTableHeight() { | |
| 121 | + this.$nextTick(() => { | |
| 122 | + const container = this.$el | |
| 123 | + if (!container) return | |
| 124 | + | |
| 125 | + const containerHeight = container.clientHeight | |
| 126 | + const searchCard = container.querySelector('.search-card') | |
| 127 | + const tableCard = container.querySelector('.table-card') | |
| 128 | + | |
| 129 | + let searchCardHeight = 0 | |
| 130 | + if (searchCard) { | |
| 131 | + searchCardHeight = searchCard.offsetHeight + 20 | |
| 132 | + } | |
| 133 | + | |
| 134 | + const tableCardAvailableHeight = containerHeight - searchCardHeight - 100 | |
| 135 | + const tableCardHeight = Math.max(250, tableCardAvailableHeight) | |
| 136 | + | |
| 137 | + if (tableCard) { | |
| 138 | + tableCard.style.height = tableCardHeight + 'px' | |
| 139 | + } | |
| 140 | + | |
| 141 | + const tableContainer = container.querySelector('.table-container') | |
| 142 | + if (tableContainer) { | |
| 143 | + const cardHeaderHeight = 50 | |
| 144 | + const cardPadding = 30 | |
| 145 | + const tableContainerHeight = tableCardHeight - cardHeaderHeight - cardPadding | |
| 146 | + tableContainer.style.height = tableContainerHeight + 'px' | |
| 147 | + | |
| 148 | + const paginationHeight = 50 | |
| 149 | + const paginationMargin = 10 | |
| 150 | + this.tableHeight = Math.max(100, tableContainerHeight - paginationHeight - paginationMargin) | |
| 151 | + } | |
| 152 | + }) | |
| 153 | + }, | |
| 154 | + async handleSearch() { | |
| 155 | + this.loading = true | |
| 156 | + try { | |
| 157 | + const params = { | |
| 158 | + pageIndex: this.pagination.pageIndex, | |
| 159 | + pageSize: this.pagination.pageSize, | |
| 160 | + statisticsMonth: this.searchForm.statisticsMonth, | |
| 161 | + goldTriangleName: this.searchForm.goldTriangleName, | |
| 162 | + storeName: this.searchForm.storeName | |
| 163 | + } | |
| 164 | + | |
| 165 | + const response = await getGoldTriangleStatisticsList(params) | |
| 166 | + this.tableData = response.data.list || [] | |
| 167 | + this.pagination.total = response.data.pagination.total || 0 | |
| 168 | + } catch (error) { | |
| 169 | + this.$message.error('查询失败: ' + error.message) | |
| 170 | + } finally { | |
| 171 | + this.loading = false | |
| 172 | + } | |
| 173 | + }, | |
| 174 | + handleReset() { | |
| 175 | + this.searchForm = { | |
| 176 | + statisticsMonth: this.getCurrentMonth(), | |
| 177 | + goldTriangleName: '', | |
| 178 | + storeName: '' | |
| 179 | + } | |
| 180 | + this.pagination.pageIndex = 1 | |
| 181 | + this.handleSearch() | |
| 182 | + }, | |
| 183 | + handleSizeChange(val) { | |
| 184 | + this.pagination.pageSize = val | |
| 185 | + this.pagination.pageIndex = 1 | |
| 186 | + this.handleSearch() | |
| 187 | + }, | |
| 188 | + handleCurrentChange(val) { | |
| 189 | + this.pagination.pageIndex = val | |
| 190 | + this.handleSearch() | |
| 191 | + }, | |
| 192 | + formatMoney(value) { | |
| 193 | + if (value === null || value === undefined) return '0.00' | |
| 194 | + return Number(value).toLocaleString('zh-CN', { | |
| 195 | + minimumFractionDigits: 2, | |
| 196 | + maximumFractionDigits: 2 | |
| 197 | + }) | |
| 198 | + }, | |
| 199 | + formatDate(value) { | |
| 200 | + if (!value) return '-' | |
| 201 | + return new Date(value).toLocaleDateString('zh-CN') | |
| 202 | + }, | |
| 203 | + formatDateTime(value) { | |
| 204 | + if (!value) return '-' | |
| 205 | + return new Date(value).toLocaleString('zh-CN') | |
| 206 | + } | |
| 207 | + } | |
| 208 | +} | |
| 209 | +</script> | |
| 210 | + | |
| 211 | +<style lang="scss" scoped> | |
| 212 | +.gold-triangle-statistics-container { | |
| 213 | + height: calc(100vh - 60px); | |
| 214 | + display: flex; | |
| 215 | + flex-direction: column; | |
| 216 | + overflow: hidden; | |
| 217 | + padding: 20px; | |
| 218 | + background-color: #f0f2f5; | |
| 219 | + | |
| 220 | + .search-card { | |
| 221 | + flex-shrink: 0; | |
| 222 | + margin-bottom: 20px; | |
| 223 | + border-radius: 8px; | |
| 224 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 225 | + | |
| 226 | + .search-form { | |
| 227 | + .el-form-item { | |
| 228 | + margin-bottom: 10px; | |
| 229 | + } | |
| 230 | + } | |
| 231 | + } | |
| 232 | + | |
| 233 | + .table-card { | |
| 234 | + flex: 1; | |
| 235 | + display: flex; | |
| 236 | + flex-direction: column; | |
| 237 | + overflow: hidden; | |
| 238 | + min-height: 0; | |
| 239 | + border-radius: 8px; | |
| 240 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 241 | + | |
| 242 | + .table-container { | |
| 243 | + height: 100%; | |
| 244 | + display: flex; | |
| 245 | + flex-direction: column; | |
| 246 | + overflow: hidden; | |
| 247 | + position: relative; | |
| 248 | + | |
| 249 | + .el-table { | |
| 250 | + flex: 1; | |
| 251 | + min-height: 0; | |
| 252 | + overflow: auto; | |
| 253 | + } | |
| 254 | + | |
| 255 | + .pagination-container { | |
| 256 | + margin-top: 10px; | |
| 257 | + padding: 5px 0; | |
| 258 | + height: 50px; | |
| 259 | + display: flex; | |
| 260 | + align-items: center; | |
| 261 | + justify-content: flex-end; | |
| 262 | + flex-shrink: 0; | |
| 263 | + } | |
| 264 | + } | |
| 265 | + } | |
| 266 | +} | |
| 267 | +</style> | ... | ... |
antis-ncc-admin/src/views/personalPerformanceStatistics/index.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="personal-performance-statistics-container"> | |
| 3 | + <!-- 搜索卡片 --> | |
| 4 | + <el-card class="search-card"> | |
| 5 | + <div slot="header" class="clearfix"> | |
| 6 | + <span><i class="el-icon-user"></i> 健康师个人开单业绩统计</span> | |
| 7 | + </div> | |
| 8 | + <div class="search-form"> | |
| 9 | + <el-form :inline="true" :model="searchForm" class="demo-form-inline"> | |
| 10 | + <el-form-item label="统计月份"> | |
| 11 | + <el-date-picker v-model="searchForm.statisticsMonth" type="month" placeholder="选择月份" | |
| 12 | + format="yyyy年MM月" value-format="yyyyMM" :clearable="false" @change="handleSearch"> | |
| 13 | + </el-date-picker> | |
| 14 | + </el-form-item> | |
| 15 | + <el-form-item label="员工姓名"> | |
| 16 | + <el-input v-model="searchForm.employeeName" placeholder="请输入员工姓名" clearable | |
| 17 | + @keyup.enter.native="handleSearch"> | |
| 18 | + </el-input> | |
| 19 | + </el-form-item> | |
| 20 | + <el-form-item label="门店名称"> | |
| 21 | + <el-input v-model="searchForm.storeName" placeholder="请输入门店名称" clearable | |
| 22 | + @keyup.enter.native="handleSearch"> | |
| 23 | + </el-input> | |
| 24 | + </el-form-item> | |
| 25 | + <el-form-item label="岗位"> | |
| 26 | + <el-input v-model="searchForm.position" placeholder="请输入岗位" clearable | |
| 27 | + @keyup.enter.native="handleSearch"> | |
| 28 | + </el-input> | |
| 29 | + </el-form-item> | |
| 30 | + <el-form-item> | |
| 31 | + <el-button type="primary" @click="handleSearch" :loading="loading"> | |
| 32 | + <i class="el-icon-search"></i> 查询 | |
| 33 | + </el-button> | |
| 34 | + <el-button @click="handleReset"> | |
| 35 | + <i class="el-icon-refresh"></i> 重置 | |
| 36 | + </el-button> | |
| 37 | + </el-form-item> | |
| 38 | + </el-form> | |
| 39 | + </div> | |
| 40 | + </el-card> | |
| 41 | + | |
| 42 | + <!-- 表格卡片 --> | |
| 43 | + <el-card class="table-card"> | |
| 44 | + <div slot="header" class="clearfix"> | |
| 45 | + <span><i class="el-icon-s-grid"></i> 健康师个人开单业绩列表</span> | |
| 46 | + </div> | |
| 47 | + <div class="table-container"> | |
| 48 | + <el-table :data="tableData" v-loading="loading" element-loading-text="加载中..." :height="tableHeight" | |
| 49 | + border stripe style="width: 100%"> | |
| 50 | + <el-table-column prop="EmployeeName" label="员工姓名" width="120" fixed="left"></el-table-column> | |
| 51 | + <el-table-column prop="StoreName" label="门店名称" width="150" fixed="left"></el-table-column> | |
| 52 | + <el-table-column prop="Position" label="岗位" width="100" fixed="left"></el-table-column> | |
| 53 | + <el-table-column prop="GoldTriangleTeam" label="金三角战队" width="120" fixed="left"></el-table-column> | |
| 54 | + <el-table-column prop="TotalPerformance" label="总业绩" width="100" align="right"> | |
| 55 | + <template slot-scope="scope"> | |
| 56 | + {{ formatMoney(scope.row.TotalPerformance) }} | |
| 57 | + </template> | |
| 58 | + </el-table-column> | |
| 59 | + <el-table-column prop="FirstOrderPerformance" label="首单业绩" width="100" align="right"> | |
| 60 | + <template slot-scope="scope"> | |
| 61 | + {{ formatMoney(scope.row.FirstOrderPerformance) }} | |
| 62 | + </template> | |
| 63 | + </el-table-column> | |
| 64 | + <el-table-column prop="UpgradeOrderPerformance" label="升单业绩" width="100" align="right"> | |
| 65 | + <template slot-scope="scope"> | |
| 66 | + {{ formatMoney(scope.row.UpgradeOrderPerformance) }} | |
| 67 | + </template> | |
| 68 | + </el-table-column> | |
| 69 | + <el-table-column prop="FirstOrderCount" label="首开单数量" width="100" align="right"></el-table-column> | |
| 70 | + <el-table-column prop="UpgradeOrderCount" label="升单数量" width="100" align="right"></el-table-column> | |
| 71 | + <el-table-column prop="OrderCount" label="订单总数" width="100" align="right"></el-table-column> | |
| 72 | + <el-table-column prop="CreateTime" label="创建时间" width="150" align="center"> | |
| 73 | + <template slot-scope="scope"> | |
| 74 | + {{ formatDateTime(scope.row.CreateTime) }} | |
| 75 | + </template> | |
| 76 | + </el-table-column> | |
| 77 | + </el-table> | |
| 78 | + | |
| 79 | + <!-- 分页 --> | |
| 80 | + <div class="pagination-container"> | |
| 81 | + <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 82 | + :current-page="pagination.pageIndex" :page-sizes="[10, 20, 50, 100]" | |
| 83 | + :page-size="pagination.pageSize" :total="pagination.total" | |
| 84 | + layout="total, sizes, prev, pager, next, jumper"> | |
| 85 | + </el-pagination> | |
| 86 | + </div> | |
| 87 | + </div> | |
| 88 | + </el-card> | |
| 89 | + </div> | |
| 90 | +</template> | |
| 91 | + | |
| 92 | +<script> | |
| 93 | +import { getPersonalPerformanceStatisticsList } from '@/api/extend/statistics' | |
| 94 | + | |
| 95 | +export default { | |
| 96 | + name: 'PersonalPerformanceStatistics', | |
| 97 | + data() { | |
| 98 | + return { | |
| 99 | + loading: false, | |
| 100 | + tableData: [], | |
| 101 | + tableHeight: 400, | |
| 102 | + searchForm: { | |
| 103 | + statisticsMonth: this.getCurrentMonth(), | |
| 104 | + employeeName: '', | |
| 105 | + storeName: '', | |
| 106 | + position: '' | |
| 107 | + }, | |
| 108 | + pagination: { | |
| 109 | + pageIndex: 1, | |
| 110 | + pageSize: 20, | |
| 111 | + total: 0 | |
| 112 | + } | |
| 113 | + } | |
| 114 | + }, | |
| 115 | + mounted() { | |
| 116 | + this.calculateTableHeight() | |
| 117 | + this.handleSearch() | |
| 118 | + window.addEventListener('resize', this.calculateTableHeight) | |
| 119 | + }, | |
| 120 | + beforeDestroy() { | |
| 121 | + window.removeEventListener('resize', this.calculateTableHeight) | |
| 122 | + }, | |
| 123 | + methods: { | |
| 124 | + getCurrentMonth() { | |
| 125 | + const now = new Date() | |
| 126 | + const year = now.getFullYear() | |
| 127 | + const month = String(now.getMonth() + 1).padStart(2, '0') | |
| 128 | + return `${year}${month}` | |
| 129 | + }, | |
| 130 | + calculateTableHeight() { | |
| 131 | + this.$nextTick(() => { | |
| 132 | + const container = this.$el | |
| 133 | + if (!container) return | |
| 134 | + | |
| 135 | + const containerHeight = container.clientHeight | |
| 136 | + const searchCard = container.querySelector('.search-card') | |
| 137 | + const tableCard = container.querySelector('.table-card') | |
| 138 | + | |
| 139 | + let searchCardHeight = 0 | |
| 140 | + if (searchCard) { | |
| 141 | + searchCardHeight = searchCard.offsetHeight + 20 | |
| 142 | + } | |
| 143 | + | |
| 144 | + const tableCardAvailableHeight = containerHeight - searchCardHeight - 100 | |
| 145 | + const tableCardHeight = Math.max(250, tableCardAvailableHeight) | |
| 146 | + | |
| 147 | + if (tableCard) { | |
| 148 | + tableCard.style.height = tableCardHeight + 'px' | |
| 149 | + } | |
| 150 | + | |
| 151 | + const tableContainer = container.querySelector('.table-container') | |
| 152 | + if (tableContainer) { | |
| 153 | + const cardHeaderHeight = 50 | |
| 154 | + const cardPadding = 30 | |
| 155 | + const tableContainerHeight = tableCardHeight - cardHeaderHeight - cardPadding | |
| 156 | + tableContainer.style.height = tableContainerHeight + 'px' | |
| 157 | + | |
| 158 | + const paginationHeight = 50 | |
| 159 | + const paginationMargin = 10 | |
| 160 | + this.tableHeight = Math.max(100, tableContainerHeight - paginationHeight - paginationMargin) | |
| 161 | + } | |
| 162 | + }) | |
| 163 | + }, | |
| 164 | + async handleSearch() { | |
| 165 | + this.loading = true | |
| 166 | + try { | |
| 167 | + const params = { | |
| 168 | + pageIndex: this.pagination.pageIndex, | |
| 169 | + pageSize: this.pagination.pageSize, | |
| 170 | + statisticsMonth: this.searchForm.statisticsMonth, | |
| 171 | + employeeName: this.searchForm.employeeName, | |
| 172 | + storeName: this.searchForm.storeName, | |
| 173 | + position: this.searchForm.position | |
| 174 | + } | |
| 175 | + | |
| 176 | + const response = await getPersonalPerformanceStatisticsList(params) | |
| 177 | + this.tableData = response.data.list || [] | |
| 178 | + this.pagination.total = response.data.pagination.total || 0 | |
| 179 | + } catch (error) { | |
| 180 | + this.$message.error('查询失败: ' + error.message) | |
| 181 | + } finally { | |
| 182 | + this.loading = false | |
| 183 | + } | |
| 184 | + }, | |
| 185 | + handleReset() { | |
| 186 | + this.searchForm = { | |
| 187 | + statisticsMonth: this.getCurrentMonth(), | |
| 188 | + employeeName: '', | |
| 189 | + storeName: '', | |
| 190 | + position: '' | |
| 191 | + } | |
| 192 | + this.pagination.pageIndex = 1 | |
| 193 | + this.handleSearch() | |
| 194 | + }, | |
| 195 | + handleSizeChange(val) { | |
| 196 | + this.pagination.pageSize = val | |
| 197 | + this.pagination.pageIndex = 1 | |
| 198 | + this.handleSearch() | |
| 199 | + }, | |
| 200 | + handleCurrentChange(val) { | |
| 201 | + this.pagination.pageIndex = val | |
| 202 | + this.handleSearch() | |
| 203 | + }, | |
| 204 | + formatMoney(value) { | |
| 205 | + if (value === null || value === undefined) return '0.00' | |
| 206 | + return Number(value).toLocaleString('zh-CN', { | |
| 207 | + minimumFractionDigits: 2, | |
| 208 | + maximumFractionDigits: 2 | |
| 209 | + }) | |
| 210 | + }, | |
| 211 | + formatDateTime(value) { | |
| 212 | + if (!value) return '-' | |
| 213 | + return new Date(value).toLocaleString('zh-CN') | |
| 214 | + } | |
| 215 | + } | |
| 216 | +} | |
| 217 | +</script> | |
| 218 | + | |
| 219 | +<style lang="scss" scoped> | |
| 220 | +.personal-performance-statistics-container { | |
| 221 | + height: calc(100vh - 60px); | |
| 222 | + display: flex; | |
| 223 | + flex-direction: column; | |
| 224 | + overflow: hidden; | |
| 225 | + padding: 20px; | |
| 226 | + background-color: #f0f2f5; | |
| 227 | + | |
| 228 | + .search-card { | |
| 229 | + flex-shrink: 0; | |
| 230 | + margin-bottom: 20px; | |
| 231 | + border-radius: 8px; | |
| 232 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 233 | + | |
| 234 | + .search-form { | |
| 235 | + .el-form-item { | |
| 236 | + margin-bottom: 10px; | |
| 237 | + } | |
| 238 | + } | |
| 239 | + } | |
| 240 | + | |
| 241 | + .table-card { | |
| 242 | + flex: 1; | |
| 243 | + display: flex; | |
| 244 | + flex-direction: column; | |
| 245 | + overflow: hidden; | |
| 246 | + min-height: 0; | |
| 247 | + border-radius: 8px; | |
| 248 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 249 | + | |
| 250 | + .table-container { | |
| 251 | + height: 100%; | |
| 252 | + display: flex; | |
| 253 | + flex-direction: column; | |
| 254 | + overflow: hidden; | |
| 255 | + position: relative; | |
| 256 | + | |
| 257 | + .el-table { | |
| 258 | + flex: 1; | |
| 259 | + min-height: 0; | |
| 260 | + overflow: auto; | |
| 261 | + } | |
| 262 | + | |
| 263 | + .pagination-container { | |
| 264 | + margin-top: 10px; | |
| 265 | + padding: 5px 0; | |
| 266 | + height: 50px; | |
| 267 | + display: flex; | |
| 268 | + align-items: center; | |
| 269 | + justify-content: flex-end; | |
| 270 | + flex-shrink: 0; | |
| 271 | + } | |
| 272 | + } | |
| 273 | + } | |
| 274 | +} | |
| 275 | +</style> | ... | ... |
antis-ncc-admin/src/views/salaryCalculation/index.vue
| ... | ... | @@ -13,15 +13,8 @@ |
| 13 | 13 | <el-button style="float: right; padding: 3px 0" type="text" @click="resetMonth">重置</el-button> |
| 14 | 14 | </div> |
| 15 | 15 | <div class="month-picker-wrapper"> |
| 16 | - <el-date-picker | |
| 17 | - v-model="statisticsMonth" | |
| 18 | - type="month" | |
| 19 | - placeholder="选择月份" | |
| 20 | - format="yyyy年MM月" | |
| 21 | - value-format="yyyyMM" | |
| 22 | - :clearable="false" | |
| 23 | - class="month-picker" | |
| 24 | - > | |
| 16 | + <el-date-picker v-model="statisticsMonth" type="month" placeholder="选择月份" format="yyyy年MM月" | |
| 17 | + value-format="yyyyMM" :clearable="false" class="month-picker"> | |
| 25 | 18 | </el-date-picker> |
| 26 | 19 | </div> |
| 27 | 20 | </el-card> |
| ... | ... | @@ -33,15 +26,9 @@ |
| 33 | 26 | </div> |
| 34 | 27 | <div class="calculate-content"> |
| 35 | 28 | <p class="calculate-desc">按顺序执行所有统计方法,生成完整的工资数据</p> |
| 36 | - <el-button | |
| 37 | - type="primary" | |
| 38 | - size="large" | |
| 39 | - :loading="isCalculating" | |
| 40 | - @click="handleCalculateSalary" | |
| 41 | - class="calculate-button" | |
| 42 | - :disabled="!statisticsMonth" | |
| 43 | - > | |
| 44 | - <i class="el-icon-magic-stick"></i> | |
| 29 | + <el-button type="primary" size="large" :loading="isCalculating" @click="handleCalculateSalary" | |
| 30 | + class="calculate-button" :disabled="!statisticsMonth"> | |
| 31 | + <i class="el-icon-magic-stick"></i> | |
| 45 | 32 | {{ isCalculating ? '计算中...' : '一键计算工资' }} |
| 46 | 33 | </el-button> |
| 47 | 34 | </div> |
| ... | ... | @@ -59,15 +46,16 @@ |
| 59 | 46 | <i class="el-icon-s-data"></i> |
| 60 | 47 | <span>金三角开卡业绩</span> |
| 61 | 48 | </div> |
| 62 | - <el-button | |
| 63 | - type="primary" | |
| 64 | - :loading="loadingStates.goldTriangle" | |
| 65 | - @click="handleGoldTriangleStatistics" | |
| 66 | - class="stat-button" | |
| 67 | - :disabled="!statisticsMonth" | |
| 68 | - > | |
| 69 | - 立即统计 | |
| 70 | - </el-button> | |
| 49 | + <div class="stat-actions"> | |
| 50 | + <el-button type="primary" :loading="loadingStates.goldTriangle" @click="handleGoldTriangleStatistics" | |
| 51 | + class="stat-button" :disabled="!statisticsMonth"> | |
| 52 | + 立即统计 | |
| 53 | + </el-button> | |
| 54 | + <el-button type="default" @click="goToGoldTrianglePage" class="view-button" | |
| 55 | + :disabled="!statisticsMonth"> | |
| 56 | + <i class="el-icon-view"></i> 查看 | |
| 57 | + </el-button> | |
| 58 | + </div> | |
| 71 | 59 | </div> |
| 72 | 60 | |
| 73 | 61 | <div class="stat-item green-item"> |
| ... | ... | @@ -75,15 +63,16 @@ |
| 75 | 63 | <i class="el-icon-user"></i> |
| 76 | 64 | <span>健康师个人开单业绩</span> |
| 77 | 65 | </div> |
| 78 | - <el-button | |
| 79 | - type="success" | |
| 80 | - :loading="loadingStates.personalPerformance" | |
| 81 | - @click="handlePersonalPerformanceStatistics" | |
| 82 | - class="stat-button" | |
| 83 | - :disabled="!statisticsMonth" | |
| 84 | - > | |
| 85 | - 立即统计 | |
| 86 | - </el-button> | |
| 66 | + <div class="stat-actions"> | |
| 67 | + <el-button type="success" :loading="loadingStates.personalPerformance" | |
| 68 | + @click="handlePersonalPerformanceStatistics" class="stat-button" :disabled="!statisticsMonth"> | |
| 69 | + 立即统计 | |
| 70 | + </el-button> | |
| 71 | + <el-button type="default" @click="goToPersonalPerformancePage" class="view-button" | |
| 72 | + :disabled="!statisticsMonth"> | |
| 73 | + <i class="el-icon-view"></i> 查看 | |
| 74 | + </el-button> | |
| 75 | + </div> | |
| 87 | 76 | </div> |
| 88 | 77 | |
| 89 | 78 | <div class="stat-item orange-item"> |
| ... | ... | @@ -91,15 +80,16 @@ |
| 91 | 80 | <i class="el-icon-s-promotion"></i> |
| 92 | 81 | <span>科技部开单业绩</span> |
| 93 | 82 | </div> |
| 94 | - <el-button | |
| 95 | - type="warning" | |
| 96 | - :loading="loadingStates.techPerformance" | |
| 97 | - @click="handleTechPerformanceStatistics" | |
| 98 | - class="stat-button" | |
| 99 | - :disabled="!statisticsMonth" | |
| 100 | - > | |
| 101 | - 立即统计 | |
| 102 | - </el-button> | |
| 83 | + <div class="stat-actions"> | |
| 84 | + <el-button type="warning" :loading="loadingStates.techPerformance" | |
| 85 | + @click="handleTechPerformanceStatistics" class="stat-button" :disabled="!statisticsMonth"> | |
| 86 | + 立即统计 | |
| 87 | + </el-button> | |
| 88 | + <el-button type="default" @click="goToTechPerformancePage" class="view-button" | |
| 89 | + :disabled="!statisticsMonth"> | |
| 90 | + <i class="el-icon-view"></i> 查看 | |
| 91 | + </el-button> | |
| 92 | + </div> | |
| 103 | 93 | </div> |
| 104 | 94 | |
| 105 | 95 | <div class="stat-item purple-item"> |
| ... | ... | @@ -107,15 +97,16 @@ |
| 107 | 97 | <i class="el-icon-s-shop"></i> |
| 108 | 98 | <span>门店耗卡业绩</span> |
| 109 | 99 | </div> |
| 110 | - <el-button | |
| 111 | - type="info" | |
| 112 | - :loading="loadingStates.storeConsumePerformance" | |
| 113 | - @click="handleStoreConsumePerformanceStatistics" | |
| 114 | - class="stat-button" | |
| 115 | - :disabled="!statisticsMonth" | |
| 116 | - > | |
| 117 | - 立即统计 | |
| 118 | - </el-button> | |
| 100 | + <div class="stat-actions"> | |
| 101 | + <el-button type="info" :loading="loadingStates.storeConsumePerformance" | |
| 102 | + @click="handleStoreConsumePerformanceStatistics" class="stat-button" :disabled="!statisticsMonth"> | |
| 103 | + 立即统计 | |
| 104 | + </el-button> | |
| 105 | + <el-button type="default" @click="goToStoreConsumePerformancePage" class="view-button" | |
| 106 | + :disabled="!statisticsMonth"> | |
| 107 | + <i class="el-icon-view"></i> 查看 | |
| 108 | + </el-button> | |
| 109 | + </div> | |
| 119 | 110 | </div> |
| 120 | 111 | |
| 121 | 112 | <div class="stat-item teal-item"> |
| ... | ... | @@ -123,15 +114,17 @@ |
| 123 | 114 | <i class="el-icon-user-solid"></i> |
| 124 | 115 | <span>个人消耗业绩</span> |
| 125 | 116 | </div> |
| 126 | - <el-button | |
| 127 | - type="primary" | |
| 128 | - :loading="loadingStates.departmentConsumePerformance" | |
| 129 | - @click="handleDepartmentConsumePerformanceStatistics" | |
| 130 | - class="stat-button" | |
| 131 | - :disabled="!statisticsMonth" | |
| 132 | - > | |
| 133 | - 立即统计 | |
| 134 | - </el-button> | |
| 117 | + <div class="stat-actions"> | |
| 118 | + <el-button type="primary" :loading="loadingStates.departmentConsumePerformance" | |
| 119 | + @click="handleDepartmentConsumePerformanceStatistics" class="stat-button" | |
| 120 | + :disabled="!statisticsMonth"> | |
| 121 | + 立即统计 | |
| 122 | + </el-button> | |
| 123 | + <el-button type="default" @click="goToDepartmentConsumePerformancePage" class="view-button" | |
| 124 | + :disabled="!statisticsMonth"> | |
| 125 | + <i class="el-icon-view"></i> 查看 | |
| 126 | + </el-button> | |
| 127 | + </div> | |
| 135 | 128 | </div> |
| 136 | 129 | |
| 137 | 130 | <div class="stat-item red-item"> |
| ... | ... | @@ -139,15 +132,16 @@ |
| 139 | 132 | <i class="el-icon-s-finance"></i> |
| 140 | 133 | <span>门店总业绩</span> |
| 141 | 134 | </div> |
| 142 | - <el-button | |
| 143 | - type="danger" | |
| 144 | - :loading="loadingStates.storeTotalPerformance" | |
| 145 | - @click="handleStoreTotalPerformanceStatistics" | |
| 146 | - class="stat-button" | |
| 147 | - :disabled="!statisticsMonth" | |
| 148 | - > | |
| 149 | - 立即统计 | |
| 150 | - </el-button> | |
| 135 | + <div class="stat-actions"> | |
| 136 | + <el-button type="danger" :loading="loadingStates.storeTotalPerformance" | |
| 137 | + @click="handleStoreTotalPerformanceStatistics" class="stat-button" :disabled="!statisticsMonth"> | |
| 138 | + 立即统计 | |
| 139 | + </el-button> | |
| 140 | + <el-button type="default" @click="goToStoreTotalPerformancePage" class="view-button" | |
| 141 | + :disabled="!statisticsMonth"> | |
| 142 | + <i class="el-icon-view"></i> 查看 | |
| 143 | + </el-button> | |
| 144 | + </div> | |
| 151 | 145 | </div> |
| 152 | 146 | |
| 153 | 147 | <div class="stat-item gold-item"> |
| ... | ... | @@ -155,15 +149,15 @@ |
| 155 | 149 | <i class="el-icon-money"></i> |
| 156 | 150 | <span>工资统计</span> |
| 157 | 151 | </div> |
| 158 | - <el-button | |
| 159 | - type="warning" | |
| 160 | - :loading="loadingStates.salaryStatistics" | |
| 161 | - @click="handleSalaryStatistics" | |
| 162 | - class="stat-button" | |
| 163 | - :disabled="!statisticsMonth" | |
| 164 | - > | |
| 165 | - 立即统计 | |
| 166 | - </el-button> | |
| 152 | + <div class="stat-actions"> | |
| 153 | + <el-button type="warning" :loading="loadingStates.salaryStatistics" @click="handleSalaryStatistics" | |
| 154 | + class="stat-button" :disabled="!statisticsMonth"> | |
| 155 | + 立即统计 | |
| 156 | + </el-button> | |
| 157 | + <el-button type="default" @click="goToSalaryPage" class="view-button" :disabled="!statisticsMonth"> | |
| 158 | + <i class="el-icon-view"></i> 查看 | |
| 159 | + </el-button> | |
| 160 | + </div> | |
| 167 | 161 | </div> |
| 168 | 162 | |
| 169 | 163 | <!-- 预留位置,用于未来添加更多统计方法 --> |
| ... | ... | @@ -172,11 +166,7 @@ |
| 172 | 166 | <i class="el-icon-plus"></i> |
| 173 | 167 | <span>更多统计方法</span> |
| 174 | 168 | </div> |
| 175 | - <el-button | |
| 176 | - type="info" | |
| 177 | - disabled | |
| 178 | - class="stat-button" | |
| 179 | - > | |
| 169 | + <el-button type="info" disabled class="stat-button"> | |
| 180 | 170 | 敬请期待 |
| 181 | 171 | </el-button> |
| 182 | 172 | </div> |
| ... | ... | @@ -205,9 +195,6 @@ |
| 205 | 195 | <div slot="header" class="clearfix"> |
| 206 | 196 | <span><i class="el-icon-document"></i> 统计结果</span> |
| 207 | 197 | <div> |
| 208 | - <el-button type="success" size="mini" @click="goToSalaryPage"> | |
| 209 | - <i class="el-icon-view"></i> 查看工资统计 | |
| 210 | - </el-button> | |
| 211 | 198 | <el-button type="text" @click="clearResults"> |
| 212 | 199 | <i class="el-icon-delete"></i> 清空 |
| 213 | 200 | </el-button> |
| ... | ... | @@ -219,7 +206,8 @@ |
| 219 | 206 | <p>暂无统计结果</p> |
| 220 | 207 | <p class="no-results-desc">请选择月份并点击上方按钮进行统计</p> |
| 221 | 208 | </div> |
| 222 | - <div v-for="(result, index) in results" :key="index" :class="['result-item', result.success ? 'success-item' : 'error-item']"> | |
| 209 | + <div v-for="(result, index) in results" :key="index" | |
| 210 | + :class="['result-item', result.success ? 'success-item' : 'error-item']"> | |
| 223 | 211 | <div class="result-header"> |
| 224 | 212 | <i :class="[result.success ? 'el-icon-success' : 'el-icon-error', 'result-icon']"></i> |
| 225 | 213 | <span class="result-title">{{ result.title }}</span> |
| ... | ... | @@ -350,7 +338,7 @@ export default { |
| 350 | 338 | // 按顺序执行每个统计步骤 |
| 351 | 339 | for (let i = 0; i < steps.length; i++) { |
| 352 | 340 | const step = steps[i] |
| 353 | - | |
| 341 | + | |
| 354 | 342 | // 更新进度状态 |
| 355 | 343 | this.calculationProgress.push({ |
| 356 | 344 | name: step.name, |
| ... | ... | @@ -360,10 +348,10 @@ export default { |
| 360 | 348 | try { |
| 361 | 349 | // 调用对应的统计方法 |
| 362 | 350 | await this[step.method]() |
| 363 | - | |
| 351 | + | |
| 364 | 352 | // 标记为完成 |
| 365 | 353 | this.calculationProgress[i].status = 'completed' |
| 366 | - | |
| 354 | + | |
| 367 | 355 | // 等待一秒再执行下一步 |
| 368 | 356 | if (i < steps.length - 1) { |
| 369 | 357 | await new Promise(resolve => setTimeout(resolve, 1000)) |
| ... | ... | @@ -372,7 +360,7 @@ export default { |
| 372 | 360 | // 标记为失败 |
| 373 | 361 | this.calculationProgress[i].status = 'failed' |
| 374 | 362 | this.$message.error(`${step.name}失败: ${error.message}`) |
| 375 | - | |
| 363 | + | |
| 376 | 364 | // 如果某个步骤失败,询问是否继续 |
| 377 | 365 | const continueCalc = await this.$confirm( |
| 378 | 366 | `${step.name}执行失败,是否继续执行后续统计?`, |
| ... | ... | @@ -383,7 +371,7 @@ export default { |
| 383 | 371 | type: 'warning' |
| 384 | 372 | } |
| 385 | 373 | ).catch(() => false) |
| 386 | - | |
| 374 | + | |
| 387 | 375 | if (!continueCalc) { |
| 388 | 376 | break |
| 389 | 377 | } |
| ... | ... | @@ -637,6 +625,66 @@ export default { |
| 637 | 625 | month: this.statisticsMonth |
| 638 | 626 | } |
| 639 | 627 | }) |
| 628 | + }, | |
| 629 | + | |
| 630 | + // 跳转到金三角开卡业绩页面 | |
| 631 | + goToGoldTrianglePage() { | |
| 632 | + this.$router.push({ | |
| 633 | + path: '/goldTriangleStatistics', | |
| 634 | + query: { | |
| 635 | + month: this.statisticsMonth | |
| 636 | + } | |
| 637 | + }) | |
| 638 | + }, | |
| 639 | + | |
| 640 | + // 跳转到健康师个人开单业绩页面 | |
| 641 | + goToPersonalPerformancePage() { | |
| 642 | + this.$router.push({ | |
| 643 | + path: '/personalPerformanceStatistics', | |
| 644 | + query: { | |
| 645 | + month: this.statisticsMonth | |
| 646 | + } | |
| 647 | + }) | |
| 648 | + }, | |
| 649 | + | |
| 650 | + // 跳转到科技部开单业绩页面 | |
| 651 | + goToTechPerformancePage() { | |
| 652 | + this.$router.push({ | |
| 653 | + path: '/techPerformanceStatistics', | |
| 654 | + query: { | |
| 655 | + month: this.statisticsMonth | |
| 656 | + } | |
| 657 | + }) | |
| 658 | + }, | |
| 659 | + | |
| 660 | + // 跳转到门店耗卡业绩页面 | |
| 661 | + goToStoreConsumePerformancePage() { | |
| 662 | + this.$router.push({ | |
| 663 | + path: '/storeConsumePerformanceStatistics', | |
| 664 | + query: { | |
| 665 | + month: this.statisticsMonth | |
| 666 | + } | |
| 667 | + }) | |
| 668 | + }, | |
| 669 | + | |
| 670 | + // 跳转到个人消耗业绩页面 | |
| 671 | + goToDepartmentConsumePerformancePage() { | |
| 672 | + this.$router.push({ | |
| 673 | + path: '/departmentConsumePerformanceStatistics', | |
| 674 | + query: { | |
| 675 | + month: this.statisticsMonth | |
| 676 | + } | |
| 677 | + }) | |
| 678 | + }, | |
| 679 | + | |
| 680 | + // 跳转到门店总业绩页面 | |
| 681 | + goToStoreTotalPerformancePage() { | |
| 682 | + this.$router.push({ | |
| 683 | + path: '/storeTotalPerformanceStatistics', | |
| 684 | + query: { | |
| 685 | + month: this.statisticsMonth | |
| 686 | + } | |
| 687 | + }) | |
| 640 | 688 | } |
| 641 | 689 | } |
| 642 | 690 | } |
| ... | ... | @@ -674,7 +722,8 @@ export default { |
| 674 | 722 | gap: 20px; |
| 675 | 723 | margin-bottom: 20px; |
| 676 | 724 | |
| 677 | - .month-selector-card, .calculate-card { | |
| 725 | + .month-selector-card, | |
| 726 | + .calculate-card { | |
| 678 | 727 | flex: 1; |
| 679 | 728 | min-width: 0; |
| 680 | 729 | } |
| ... | ... | @@ -685,6 +734,7 @@ export default { |
| 685 | 734 | justify-content: flex-start; |
| 686 | 735 | align-items: center; |
| 687 | 736 | } |
| 737 | + | |
| 688 | 738 | .month-picker { |
| 689 | 739 | width: 100%; |
| 690 | 740 | max-width: 200px; |
| ... | ... | @@ -768,6 +818,9 @@ export default { |
| 768 | 818 | text-align: center; |
| 769 | 819 | transition: all 0.3s ease; |
| 770 | 820 | border: 2px solid transparent; |
| 821 | + display: flex; | |
| 822 | + flex-direction: column; | |
| 823 | + height: 100%; | |
| 771 | 824 | |
| 772 | 825 | &:hover { |
| 773 | 826 | transform: translateY(-2px); |
| ... | ... | @@ -776,6 +829,7 @@ export default { |
| 776 | 829 | |
| 777 | 830 | .stat-header { |
| 778 | 831 | margin-bottom: 15px; |
| 832 | + flex-shrink: 0; | |
| 779 | 833 | |
| 780 | 834 | i { |
| 781 | 835 | font-size: 1.5em; |
| ... | ... | @@ -790,53 +844,124 @@ export default { |
| 790 | 844 | } |
| 791 | 845 | } |
| 792 | 846 | |
| 793 | - .stat-button { | |
| 847 | + .stat-actions { | |
| 848 | + display: flex; | |
| 849 | + flex-direction: column; | |
| 850 | + gap: 8px; | |
| 794 | 851 | width: 100%; |
| 795 | - height: 40px; | |
| 852 | + flex: 1; | |
| 853 | + justify-content: flex-end; | |
| 854 | + } | |
| 855 | + | |
| 856 | + .stat-button { | |
| 857 | + width: 100% !important; | |
| 858 | + height: 40px !important; | |
| 796 | 859 | font-size: 0.9em; |
| 797 | 860 | border-radius: 6px; |
| 861 | + font-weight: 500; | |
| 862 | + margin: 0 !important; | |
| 863 | + padding: 0 !important; | |
| 864 | + box-sizing: border-box; | |
| 865 | + display: flex !important; | |
| 866 | + align-items: center !important; | |
| 867 | + justify-content: center !important; | |
| 868 | + line-height: 1 !important; | |
| 869 | + } | |
| 870 | + | |
| 871 | + .view-button { | |
| 872 | + width: 100% !important; | |
| 873 | + height: 40px !important; | |
| 874 | + font-size: 0.9em; | |
| 875 | + border-radius: 6px; | |
| 876 | + font-weight: 400; | |
| 877 | + border: 1px solid #dcdfe6; | |
| 878 | + background-color: #f5f7fa; | |
| 879 | + color: #606266; | |
| 880 | + margin: 0 !important; | |
| 881 | + padding: 0 !important; | |
| 882 | + box-sizing: border-box; | |
| 883 | + display: flex !important; | |
| 884 | + align-items: center !important; | |
| 885 | + justify-content: center !important; | |
| 886 | + line-height: 1 !important; | |
| 887 | + | |
| 888 | + &:hover { | |
| 889 | + background-color: #ecf5ff; | |
| 890 | + border-color: #c6e2ff; | |
| 891 | + color: #409eff; | |
| 892 | + } | |
| 893 | + | |
| 894 | + &:disabled { | |
| 895 | + background-color: #f5f7fa; | |
| 896 | + border-color: #e4e7ed; | |
| 897 | + color: #c0c4cc; | |
| 898 | + } | |
| 798 | 899 | } |
| 799 | 900 | |
| 800 | 901 | // 不同主题色 |
| 801 | 902 | &.blue-item { |
| 802 | 903 | border-color: #409EFF; |
| 803 | - .stat-header i { color: #409EFF; } | |
| 904 | + | |
| 905 | + .stat-header i { | |
| 906 | + color: #409EFF; | |
| 907 | + } | |
| 804 | 908 | } |
| 805 | 909 | |
| 806 | 910 | &.green-item { |
| 807 | 911 | border-color: #67C23A; |
| 808 | - .stat-header i { color: #67C23A; } | |
| 912 | + | |
| 913 | + .stat-header i { | |
| 914 | + color: #67C23A; | |
| 915 | + } | |
| 809 | 916 | } |
| 810 | 917 | |
| 811 | 918 | &.orange-item { |
| 812 | 919 | border-color: #E6A23C; |
| 813 | - .stat-header i { color: #E6A23C; } | |
| 920 | + | |
| 921 | + .stat-header i { | |
| 922 | + color: #E6A23C; | |
| 923 | + } | |
| 814 | 924 | } |
| 815 | 925 | |
| 816 | 926 | &.purple-item { |
| 817 | 927 | border-color: #909399; |
| 818 | - .stat-header i { color: #909399; } | |
| 928 | + | |
| 929 | + .stat-header i { | |
| 930 | + color: #909399; | |
| 931 | + } | |
| 819 | 932 | } |
| 820 | 933 | |
| 821 | 934 | &.teal-item { |
| 822 | 935 | border-color: #17A2B8; |
| 823 | - .stat-header i { color: #17A2B8; } | |
| 936 | + | |
| 937 | + .stat-header i { | |
| 938 | + color: #17A2B8; | |
| 939 | + } | |
| 824 | 940 | } |
| 825 | 941 | |
| 826 | 942 | &.red-item { |
| 827 | 943 | border-color: #F56C6C; |
| 828 | - .stat-header i { color: #F56C6C; } | |
| 944 | + | |
| 945 | + .stat-header i { | |
| 946 | + color: #F56C6C; | |
| 947 | + } | |
| 829 | 948 | } |
| 830 | 949 | |
| 831 | 950 | &.gold-item { |
| 832 | 951 | border-color: #E6A23C; |
| 833 | - .stat-header i { color: #E6A23C; } | |
| 952 | + | |
| 953 | + .stat-header i { | |
| 954 | + color: #E6A23C; | |
| 955 | + } | |
| 834 | 956 | } |
| 835 | 957 | |
| 836 | 958 | &.placeholder-item { |
| 837 | 959 | border-color: #C0C4CC; |
| 838 | 960 | background: #f5f7fa; |
| 839 | - .stat-header i { color: #C0C4CC; } | |
| 961 | + | |
| 962 | + .stat-header i { | |
| 963 | + color: #C0C4CC; | |
| 964 | + } | |
| 840 | 965 | } |
| 841 | 966 | } |
| 842 | 967 | } |
| ... | ... | @@ -940,6 +1065,7 @@ export default { |
| 940 | 1065 | &.success-item { |
| 941 | 1066 | border-color: #67C23A; |
| 942 | 1067 | } |
| 1068 | + | |
| 943 | 1069 | &.error-item { |
| 944 | 1070 | border-color: #F56C6C; |
| 945 | 1071 | } |
| ... | ... | @@ -954,9 +1080,11 @@ export default { |
| 954 | 1080 | .result-icon { |
| 955 | 1081 | font-size: 1.2em; |
| 956 | 1082 | margin-right: 8px; |
| 1083 | + | |
| 957 | 1084 | &.el-icon-success { |
| 958 | 1085 | color: #67C23A; |
| 959 | 1086 | } |
| 1087 | + | |
| 960 | 1088 | &.el-icon-error { |
| 961 | 1089 | color: #F56C6C; |
| 962 | 1090 | } |
| ... | ... | @@ -999,20 +1127,21 @@ export default { |
| 999 | 1127 | .salary-calculation-container { |
| 1000 | 1128 | padding: 10px; |
| 1001 | 1129 | } |
| 1002 | - | |
| 1130 | + | |
| 1003 | 1131 | .top-controls-row { |
| 1004 | 1132 | flex-direction: column; |
| 1005 | 1133 | gap: 15px; |
| 1006 | 1134 | } |
| 1007 | 1135 | |
| 1008 | - .month-selector-card, .calculate-card { | |
| 1136 | + .month-selector-card, | |
| 1137 | + .calculate-card { | |
| 1009 | 1138 | width: 100%; |
| 1010 | 1139 | } |
| 1011 | - | |
| 1140 | + | |
| 1012 | 1141 | .statistics-grid { |
| 1013 | 1142 | grid-template-columns: 1fr !important; |
| 1014 | 1143 | } |
| 1015 | - | |
| 1144 | + | |
| 1016 | 1145 | .calculate-button { |
| 1017 | 1146 | height: 50px !important; |
| 1018 | 1147 | font-size: 1.1em !important; | ... | ... |
antis-ncc-admin/src/views/salaryStatistics/index.vue
| 1 | 1 | <template> |
| 2 | - <div class="salary-statistics-container"> | |
| 3 | - <!-- 查询条件 --> | |
| 4 | - <el-card class="box-card search-card"> | |
| 5 | - <div slot="header" class="clearfix"> | |
| 6 | - <span><i class="el-icon-search"></i> 查询条件</span> | |
| 7 | - </div> | |
| 8 | - <el-form :model="queryForm" :inline="true" size="small"> | |
| 9 | - <el-form-item label="统计月份"> | |
| 10 | - <el-date-picker v-model="queryForm.statisticsMonth" type="month" placeholder="选择月份" format="yyyy年MM月" | |
| 11 | - value-format="yyyyMM" clearable> | |
| 12 | - </el-date-picker> | |
| 13 | - </el-form-item> | |
| 14 | - <el-form-item label="门店名称"> | |
| 15 | - <el-input v-model="queryForm.storeName" placeholder="请输入门店名称" clearable> | |
| 16 | - </el-input> | |
| 17 | - </el-form-item> | |
| 18 | - <el-form-item label="员工姓名"> | |
| 19 | - <el-input v-model="queryForm.employeeName" placeholder="请输入员工姓名" clearable> | |
| 20 | - </el-input> | |
| 21 | - </el-form-item> | |
| 22 | - <el-form-item label="核算岗位"> | |
| 23 | - <el-select v-model="queryForm.position" placeholder="请选择岗位" clearable> | |
| 24 | - <el-option label="健康师" value="健康师"></el-option> | |
| 25 | - <el-option label="店助" value="店助"></el-option> | |
| 26 | - <el-option label="店长" value="店长"></el-option> | |
| 27 | - <el-option label="主任" value="主任"></el-option> | |
| 28 | - <el-option label="总经理" value="总经理"></el-option> | |
| 29 | - <el-option label="经理" value="经理"></el-option> | |
| 30 | - <el-option label="科技部老师" value="科技部老师"></el-option> | |
| 31 | - <el-option label="顾问" value="顾问"></el-option> | |
| 32 | - </el-select> | |
| 33 | - </el-form-item> | |
| 34 | - <el-form-item label="是否锁定"> | |
| 35 | - <el-select v-model="queryForm.isLocked" placeholder="请选择锁定状态" clearable> | |
| 36 | - <el-option label="未锁定" :value="0"></el-option> | |
| 37 | - <el-option label="已锁定" :value="1"></el-option> | |
| 38 | - </el-select> | |
| 39 | - </el-form-item> | |
| 40 | - <el-form-item> | |
| 41 | - <el-button type="primary" @click="handleSearch" :loading="loading"> | |
| 42 | - <i class="el-icon-search"></i> 查询 | |
| 43 | - </el-button> | |
| 44 | - <el-button @click="handleReset"> | |
| 45 | - <i class="el-icon-refresh"></i> 重置 | |
| 46 | - </el-button> | |
| 47 | - </el-form-item> | |
| 48 | - </el-form> | |
| 49 | - </el-card> | |
| 50 | - | |
| 51 | - <!-- 数据表格 --> | |
| 52 | - <el-card class="box-card table-card"> | |
| 53 | - <div slot="header" class="clearfix"> | |
| 54 | - <span><i class="el-icon-s-data"></i> 工资统计列表</span> | |
| 55 | - </div> | |
| 56 | - | |
| 57 | - <el-table :data="tableData" v-loading="loading" stripe border height="600" :summary-method="getSummaries" | |
| 58 | - show-summary> | |
| 59 | - <el-table-column prop="EmployeeName" label="员工姓名" width="100" fixed="left"></el-table-column> | |
| 60 | - <el-table-column prop="StoreName" label="门店名称" width="120" fixed="left"></el-table-column> | |
| 61 | - <el-table-column prop="Position" label="岗位" width="100"></el-table-column> | |
| 62 | - <el-table-column prop="GoldTriangleTeam" label="金三角战队" width="120"></el-table-column> | |
| 63 | - | |
| 64 | - <!-- 业绩相关 --> | |
| 65 | - <el-table-column prop="TotalPerformance" label="总业绩" width="100" align="right"> | |
| 66 | - <template slot-scope="scope"> | |
| 67 | - {{ formatMoney(scope.row.TotalPerformance) }} | |
| 68 | - </template> | |
| 69 | - </el-table-column> | |
| 70 | - <el-table-column prop="BasePerformance" label="基础业绩" width="100" align="right"> | |
| 71 | - <template slot-scope="scope"> | |
| 72 | - {{ formatMoney(scope.row.BasePerformance) }} | |
| 73 | - </template> | |
| 74 | - </el-table-column> | |
| 75 | - <el-table-column prop="CooperationPerformance" label="合作业绩" width="100" align="right"> | |
| 76 | - <template slot-scope="scope"> | |
| 77 | - {{ formatMoney(scope.row.CooperationPerformance) }} | |
| 78 | - </template> | |
| 79 | - </el-table-column> | |
| 80 | - <el-table-column prop="NewCustomerPerformance" label="新客业绩" width="100" align="right"> | |
| 81 | - <template slot-scope="scope"> | |
| 82 | - {{ formatMoney(scope.row.NewCustomerPerformance) }} | |
| 83 | - </template> | |
| 84 | - </el-table-column> | |
| 85 | - <el-table-column prop="UpgradePerformance" label="升单业绩" width="100" align="right"> | |
| 86 | - <template slot-scope="scope"> | |
| 87 | - {{ formatMoney(scope.row.UpgradePerformance) }} | |
| 88 | - </template> | |
| 89 | - </el-table-column> | |
| 90 | - <el-table-column prop="ProjectCount" label="项目数" width="80" align="right"></el-table-column> | |
| 91 | - <el-table-column prop="StoreTotalPerformance" label="门店总业绩" width="120" align="right"> | |
| 92 | - <template slot-scope="scope"> | |
| 93 | - {{ formatMoney(scope.row.StoreTotalPerformance) }} | |
| 94 | - </template> | |
| 95 | - </el-table-column> | |
| 96 | - <el-table-column prop="TeamPerformance" label="队伍业绩" width="100" align="right"> | |
| 97 | - <template slot-scope="scope"> | |
| 98 | - {{ formatMoney(scope.row.TeamPerformance) }} | |
| 99 | - </template> | |
| 100 | - </el-table-column> | |
| 101 | - <el-table-column prop="PerformanceRatio" label="占比" width="80" align="right"> | |
| 102 | - <template slot-scope="scope"> | |
| 103 | - {{ formatPercent(scope.row.PerformanceRatio) }} | |
| 104 | - </template> | |
| 105 | - </el-table-column> | |
| 106 | - <el-table-column prop="NewCustomerConversionRate" label="新客成交率" width="100" align="right"> | |
| 107 | - <template slot-scope="scope"> | |
| 108 | - {{ formatPercent(scope.row.NewCustomerConversionRate) }} | |
| 109 | - </template> | |
| 110 | - </el-table-column> | |
| 111 | - <el-table-column prop="NewCustomerPoint" label="新客提点" width="100" align="right"> | |
| 112 | - <template slot-scope="scope"> | |
| 113 | - {{ formatPercent(scope.row.NewCustomerPoint) }} | |
| 114 | - </template> | |
| 115 | - </el-table-column> | |
| 116 | - <el-table-column prop="UpgradePoint" label="升单提点" width="100" align="right"> | |
| 117 | - <template slot-scope="scope"> | |
| 118 | - {{ formatPercent(scope.row.UpgradePoint) }} | |
| 119 | - </template> | |
| 120 | - </el-table-column> | |
| 121 | - <el-table-column prop="TraceabilityPerformance" label="溯源业绩" width="100" align="right"> | |
| 122 | - <template slot-scope="scope"> | |
| 123 | - {{ formatMoney(scope.row.TraceabilityPerformance) }} | |
| 124 | - </template> | |
| 125 | - </el-table-column> | |
| 126 | - <el-table-column prop="CellPerformance" label="cell业绩" width="100" align="right"> | |
| 127 | - <template slot-scope="scope"> | |
| 128 | - {{ formatMoney(scope.row.CellPerformance) }} | |
| 129 | - </template> | |
| 130 | - </el-table-column> | |
| 131 | - <el-table-column prop="ProjectOnePerformance" label="大项目一部业绩" width="120" align="right"> | |
| 132 | - <template slot-scope="scope"> | |
| 133 | - {{ formatMoney(scope.row.ProjectOnePerformance) }} | |
| 134 | - </template> | |
| 135 | - </el-table-column> | |
| 136 | - <el-table-column prop="ProjectTwoPerformance" label="大项目二部业绩" width="120" align="right"> | |
| 137 | - <template slot-scope="scope"> | |
| 138 | - {{ formatMoney(scope.row.ProjectTwoPerformance) }} | |
| 139 | - </template> | |
| 140 | - </el-table-column> | |
| 141 | - <el-table-column prop="MonthlyPerformance" label="当月业绩" width="100" align="right"> | |
| 142 | - <template slot-scope="scope"> | |
| 143 | - {{ formatMoney(scope.row.MonthlyPerformance) }} | |
| 144 | - </template> | |
| 145 | - </el-table-column> | |
| 146 | - | |
| 147 | - <!-- 成本相关 --> | |
| 148 | - <el-table-column prop="PropertyWaterElectricity" label="物业水电" width="100" align="right"> | |
| 149 | - <template slot-scope="scope"> | |
| 150 | - {{ formatMoney(scope.row.PropertyWaterElectricity) }} | |
| 151 | - </template> | |
| 152 | - </el-table-column> | |
| 153 | - <el-table-column prop="StoreExpense" label="门店支出" width="100" align="right"> | |
| 154 | - <template slot-scope="scope"> | |
| 155 | - {{ formatMoney(scope.row.StoreExpense) }} | |
| 156 | - </template> | |
| 157 | - </el-table-column> | |
| 158 | - <el-table-column prop="ProductMaterial" label="产品物料" width="100" align="right"> | |
| 159 | - <template slot-scope="scope"> | |
| 160 | - {{ formatMoney(scope.row.ProductMaterial) }} | |
| 161 | - </template> | |
| 162 | - </el-table-column> | |
| 163 | - <el-table-column prop="MicroSculptureCost" label="微雕成本" width="100" align="right"> | |
| 164 | - <template slot-scope="scope"> | |
| 165 | - {{ formatMoney(scope.row.MicroSculptureCost) }} | |
| 166 | - </template> | |
| 167 | - </el-table-column> | |
| 168 | - <el-table-column prop="OtherCooperationCost" label="其它合作成本" width="120" align="right"> | |
| 169 | - <template slot-scope="scope"> | |
| 170 | - {{ formatMoney(scope.row.OtherCooperationCost) }} | |
| 171 | - </template> | |
| 172 | - </el-table-column> | |
| 173 | - <el-table-column prop="TowelWashing" label="洗毛巾" width="100" align="right"> | |
| 174 | - <template slot-scope="scope"> | |
| 175 | - {{ formatMoney(scope.row.TowelWashing) }} | |
| 176 | - </template> | |
| 177 | - </el-table-column> | |
| 178 | - <el-table-column prop="GrossProfit" label="毛利" width="100" align="right"> | |
| 179 | - <template slot-scope="scope"> | |
| 180 | - {{ formatMoney(scope.row.GrossProfit) }} | |
| 181 | - </template> | |
| 182 | - </el-table-column> | |
| 183 | - | |
| 184 | - <!-- 提成相关 --> | |
| 185 | - <el-table-column prop="GeneralManagerCommission" label="总经理提成额" width="120" align="right"> | |
| 186 | - <template slot-scope="scope"> | |
| 187 | - {{ formatMoney(scope.row.GeneralManagerCommission) }} | |
| 188 | - </template> | |
| 189 | - </el-table-column> | |
| 190 | - <el-table-column prop="ManagerCommission" label="经理提成额" width="100" align="right"> | |
| 191 | - <template slot-scope="scope"> | |
| 192 | - {{ formatMoney(scope.row.ManagerCommission) }} | |
| 193 | - </template> | |
| 194 | - </el-table-column> | |
| 195 | - <el-table-column prop="Consumption" label="消耗" width="100" align="right"> | |
| 196 | - <template slot-scope="scope"> | |
| 197 | - {{ formatMoney(scope.row.Consumption) }} | |
| 198 | - </template> | |
| 199 | - </el-table-column> | |
| 200 | - <el-table-column prop="AttendanceDays" label="到店人头" width="100" align="right"></el-table-column> | |
| 201 | - <el-table-column prop="StoreDays" label="在店天数" width="100" align="right"></el-table-column> | |
| 202 | - <el-table-column prop="LeaveDays" label="请假天数" width="100" align="right"></el-table-column> | |
| 203 | - <el-table-column prop="CommissionPoint" label="提点" width="80" align="right"> | |
| 204 | - <template slot-scope="scope"> | |
| 205 | - {{ formatPercent(scope.row.CommissionPoint) }} | |
| 206 | - </template> | |
| 207 | - </el-table-column> | |
| 208 | - <el-table-column prop="BasePerformanceCommission" label="基础业绩提成" width="120" align="right"> | |
| 209 | - <template slot-scope="scope"> | |
| 210 | - {{ formatMoney(scope.row.BasePerformanceCommission) }} | |
| 211 | - </template> | |
| 212 | - </el-table-column> | |
| 213 | - <el-table-column prop="CooperationPerformanceCommission" label="合作业绩提成" width="120" align="right"> | |
| 214 | - <template slot-scope="scope"> | |
| 215 | - {{ formatMoney(scope.row.CooperationPerformanceCommission) }} | |
| 216 | - </template> | |
| 217 | - </el-table-column> | |
| 218 | - <el-table-column prop="ConsultantCommission" label="顾问提成" width="100" align="right"> | |
| 219 | - <template slot-scope="scope"> | |
| 220 | - {{ formatMoney(scope.row.ConsultantCommission) }} | |
| 221 | - </template> | |
| 222 | - </el-table-column> | |
| 223 | - <el-table-column prop="StoreTAreaCommission" label="门店T区提成" width="120" align="right"> | |
| 224 | - <template slot-scope="scope"> | |
| 225 | - {{ formatMoney(scope.row.StoreTAreaCommission) }} | |
| 226 | - </template> | |
| 227 | - </el-table-column> | |
| 228 | - <el-table-column prop="AssistantCommission1" label="店助提成" width="100" align="right"> | |
| 229 | - <template slot-scope="scope"> | |
| 230 | - {{ formatMoney(scope.row.AssistantCommission1) }} | |
| 231 | - </template> | |
| 232 | - </el-table-column> | |
| 233 | - <el-table-column prop="AssistantDirectorCommission" label="店助主任提成" width="120" align="right"> | |
| 234 | - <template slot-scope="scope"> | |
| 235 | - {{ formatMoney(scope.row.AssistantDirectorCommission) }} | |
| 236 | - </template> | |
| 237 | - </el-table-column> | |
| 238 | - <el-table-column prop="DirectorCommission" label="主任提成" width="100" align="right"> | |
| 239 | - <template slot-scope="scope"> | |
| 240 | - {{ formatMoney(scope.row.DirectorCommission) }} | |
| 241 | - </template> | |
| 242 | - </el-table-column> | |
| 243 | - <el-table-column prop="AssistantCommission2" label="店长提成" width="100" align="right"> | |
| 244 | - <template slot-scope="scope"> | |
| 245 | - {{ formatMoney(scope.row.AssistantCommission2) }} | |
| 246 | - </template> | |
| 247 | - </el-table-column> | |
| 248 | - <el-table-column prop="GeneralManagerCommissionAmount" label="总经理提成" width="120" align="right"> | |
| 249 | - <template slot-scope="scope"> | |
| 250 | - {{ formatMoney(scope.row.GeneralManagerCommissionAmount) }} | |
| 251 | - </template> | |
| 252 | - </el-table-column> | |
| 253 | - <el-table-column prop="ManagerCommissionAmount" label="经理提成" width="100" align="right"> | |
| 254 | - <template slot-scope="scope"> | |
| 255 | - {{ formatMoney(scope.row.ManagerCommissionAmount) }} | |
| 256 | - </template> | |
| 257 | - </el-table-column> | |
| 258 | - <el-table-column prop="PerformanceCommission" label="业绩提成" width="100" align="right"> | |
| 259 | - <template slot-scope="scope"> | |
| 260 | - {{ formatMoney(scope.row.PerformanceCommission) }} | |
| 261 | - </template> | |
| 262 | - </el-table-column> | |
| 263 | - <el-table-column prop="ConsumptionCommission" label="消耗提成" width="100" align="right"> | |
| 264 | - <template slot-scope="scope"> | |
| 265 | - {{ formatMoney(scope.row.ConsumptionCommission) }} | |
| 266 | - </template> | |
| 267 | - </el-table-column> | |
| 268 | - <el-table-column prop="TechGroupLeaderCommission" label="科技部组长提成" width="120" align="right"> | |
| 269 | - <template slot-scope="scope"> | |
| 270 | - {{ formatMoney(scope.row.TechGroupLeaderCommission) }} | |
| 271 | - </template> | |
| 272 | - </el-table-column> | |
| 273 | - <el-table-column prop="TraceabilityCommission" label="溯源提成" width="100" align="right"> | |
| 274 | - <template slot-scope="scope"> | |
| 275 | - {{ formatMoney(scope.row.TraceabilityCommission) }} | |
| 276 | - </template> | |
| 277 | - </el-table-column> | |
| 278 | - <el-table-column prop="CellCommission" label="cell提成" width="100" align="right"> | |
| 279 | - <template slot-scope="scope"> | |
| 280 | - {{ formatMoney(scope.row.CellCommission) }} | |
| 281 | - </template> | |
| 282 | - </el-table-column> | |
| 283 | - <el-table-column prop="ProjectCommission" label="大项目部提成" width="120" align="right"> | |
| 284 | - <template slot-scope="scope"> | |
| 285 | - {{ formatMoney(scope.row.ProjectCommission) }} | |
| 286 | - </template> | |
| 287 | - </el-table-column> | |
| 288 | - <el-table-column prop="CommissionTotal" label="提成合计" width="100" align="right"> | |
| 289 | - <template slot-scope="scope"> | |
| 290 | - {{ formatMoney(scope.row.CommissionTotal) }} | |
| 291 | - </template> | |
| 292 | - </el-table-column> | |
| 293 | - | |
| 294 | - <!-- 底薪相关 --> | |
| 295 | - <el-table-column prop="HealthCoachBaseSalary" label="健康师底薪" width="120" align="right"> | |
| 296 | - <template slot-scope="scope"> | |
| 297 | - {{ formatMoney(scope.row.HealthCoachBaseSalary) }} | |
| 298 | - </template> | |
| 299 | - </el-table-column> | |
| 300 | - <el-table-column prop="AssistantBaseSalary" label="店助底薪" width="100" align="right"> | |
| 301 | - <template slot-scope="scope"> | |
| 302 | - {{ formatMoney(scope.row.AssistantBaseSalary) }} | |
| 303 | - </template> | |
| 304 | - </el-table-column> | |
| 305 | - <el-table-column prop="ManagerBaseSalary" label="店长底薪" width="100" align="right"> | |
| 306 | - <template slot-scope="scope"> | |
| 307 | - {{ formatMoney(scope.row.ManagerBaseSalary) }} | |
| 308 | - </template> | |
| 309 | - </el-table-column> | |
| 310 | - <el-table-column prop="DirectorBaseSalary" label="主任底薪" width="100" align="right"> | |
| 311 | - <template slot-scope="scope"> | |
| 312 | - {{ formatMoney(scope.row.DirectorBaseSalary) }} | |
| 313 | - </template> | |
| 314 | - </el-table-column> | |
| 315 | - <el-table-column prop="AssistantDirectorBaseSalary" label="店助主任底薪" width="120" align="right"> | |
| 316 | - <template slot-scope="scope"> | |
| 317 | - {{ formatMoney(scope.row.AssistantDirectorBaseSalary) }} | |
| 318 | - </template> | |
| 319 | - </el-table-column> | |
| 320 | - <el-table-column prop="GeneralManagerBaseSalary" label="总经理底薪" width="120" align="right"> | |
| 321 | - <template slot-scope="scope"> | |
| 322 | - {{ formatMoney(scope.row.GeneralManagerBaseSalary) }} | |
| 323 | - </template> | |
| 324 | - </el-table-column> | |
| 325 | - <el-table-column prop="ManagerBaseSalaryAmount" label="经理底薪" width="100" align="right"> | |
| 326 | - <template slot-scope="scope"> | |
| 327 | - {{ formatMoney(scope.row.ManagerBaseSalaryAmount) }} | |
| 328 | - </template> | |
| 329 | - </el-table-column> | |
| 330 | - <el-table-column prop="TechTeacherBaseSalary" label="科技部老师底薪" width="120" align="right"> | |
| 331 | - <template slot-scope="scope"> | |
| 332 | - {{ formatMoney(scope.row.TechTeacherBaseSalary) }} | |
| 333 | - </template> | |
| 334 | - </el-table-column> | |
| 335 | - <el-table-column prop="ProjectBaseSalary" label="大项目部底薪" width="120" align="right"> | |
| 336 | - <template slot-scope="scope"> | |
| 337 | - {{ formatMoney(scope.row.ProjectBaseSalary) }} | |
| 338 | - </template> | |
| 339 | - </el-table-column> | |
| 340 | - <el-table-column prop="BaseSalaryTotal" label="底薪合计" width="100" align="right"> | |
| 341 | - <template slot-scope="scope"> | |
| 342 | - {{ formatMoney(scope.row.BaseSalaryTotal) }} | |
| 343 | - </template> | |
| 344 | - </el-table-column> | |
| 345 | - | |
| 346 | - <!-- 其他收入 --> | |
| 347 | - <el-table-column prop="ManualWork" label="手工" width="100" align="right"> | |
| 348 | - <template slot-scope="scope"> | |
| 349 | - {{ formatMoney(scope.row.ManualWork) }} | |
| 350 | - </template> | |
| 351 | - </el-table-column> | |
| 352 | - <el-table-column prop="HeadCountReward" label="人头奖励" width="100" align="right"> | |
| 353 | - <template slot-scope="scope"> | |
| 354 | - {{ formatMoney(scope.row.HeadCountReward) }} | |
| 355 | - </template> | |
| 356 | - </el-table-column> | |
| 357 | - <el-table-column prop="PhoneManagement" label="手机管理" width="100" align="right"> | |
| 358 | - <template slot-scope="scope"> | |
| 359 | - {{ formatMoney(scope.row.PhoneManagement) }} | |
| 360 | - </template> | |
| 361 | - </el-table-column> | |
| 362 | - <el-table-column prop="CarAllowance" label="车补" width="100" align="right"> | |
| 363 | - <template slot-scope="scope"> | |
| 364 | - {{ formatMoney(scope.row.CarAllowance) }} | |
| 365 | - </template> | |
| 366 | - </el-table-column> | |
| 367 | - <el-table-column prop="LessRest" label="少休" width="100" align="right"> | |
| 368 | - <template slot-scope="scope"> | |
| 369 | - {{ formatMoney(scope.row.LessRest) }} | |
| 370 | - </template> | |
| 371 | - </el-table-column> | |
| 372 | - <el-table-column prop="FullAttendance" label="全勤" width="100" align="right"> | |
| 373 | - <template slot-scope="scope"> | |
| 374 | - {{ formatMoney(scope.row.FullAttendance) }} | |
| 375 | - </template> | |
| 376 | - </el-table-column> | |
| 377 | - <el-table-column prop="CalculatedGrossSalary" label="核算应发工资" width="120" align="right"> | |
| 378 | - <template slot-scope="scope"> | |
| 379 | - {{ formatMoney(scope.row.CalculatedGrossSalary) }} | |
| 380 | - </template> | |
| 381 | - </el-table-column> | |
| 382 | - | |
| 383 | - <!-- 保底相关 --> | |
| 384 | - <el-table-column prop="Guarantee" label="保底" width="100" align="right"> | |
| 385 | - <template slot-scope="scope"> | |
| 386 | - {{ formatMoney(scope.row.Guarantee) }} | |
| 387 | - </template> | |
| 388 | - </el-table-column> | |
| 389 | - <el-table-column prop="GuaranteeLeave" label="保底请假" width="100" align="right"> | |
| 390 | - <template slot-scope="scope"> | |
| 391 | - {{ formatMoney(scope.row.GuaranteeLeave) }} | |
| 392 | - </template> | |
| 393 | - </el-table-column> | |
| 394 | - <el-table-column prop="GuaranteeBaseSalary" label="保底底薪" width="100" align="right"> | |
| 395 | - <template slot-scope="scope"> | |
| 396 | - {{ formatMoney(scope.row.GuaranteeBaseSalary) }} | |
| 397 | - </template> | |
| 398 | - </el-table-column> | |
| 399 | - <el-table-column prop="GuaranteeSupplement" label="保底补差" width="100" align="right"> | |
| 400 | - <template slot-scope="scope"> | |
| 401 | - {{ formatMoney(scope.row.GuaranteeSupplement) }} | |
| 402 | - </template> | |
| 403 | - </el-table-column> | |
| 404 | - <el-table-column prop="FinalGrossSalary" label="最终应发工资" width="120" align="right"> | |
| 405 | - <template slot-scope="scope"> | |
| 406 | - {{ formatMoney(scope.row.FinalGrossSalary) }} | |
| 407 | - </template> | |
| 408 | - </el-table-column> | |
| 409 | - | |
| 410 | - <!-- 补贴相关 --> | |
| 411 | - <el-table-column prop="MonthlyTrainingSubsidy" label="当月培训补贴" width="120" align="right"> | |
| 412 | - <template slot-scope="scope"> | |
| 413 | - {{ formatMoney(scope.row.MonthlyTrainingSubsidy) }} | |
| 414 | - </template> | |
| 415 | - </el-table-column> | |
| 416 | - <el-table-column prop="MonthlyTransportSubsidy" label="当月交通补贴" width="120" align="right"> | |
| 417 | - <template slot-scope="scope"> | |
| 418 | - {{ formatMoney(scope.row.MonthlyTransportSubsidy) }} | |
| 419 | - </template> | |
| 420 | - </el-table-column> | |
| 421 | - <el-table-column prop="LastMonthTrainingSubsidy" label="上月培训补贴" width="120" align="right"> | |
| 422 | - <template slot-scope="scope"> | |
| 423 | - {{ formatMoney(scope.row.LastMonthTrainingSubsidy) }} | |
| 424 | - </template> | |
| 425 | - </el-table-column> | |
| 426 | - <el-table-column prop="LastMonthTransportSubsidy" label="上月交通补贴" width="120" align="right"> | |
| 427 | - <template slot-scope="scope"> | |
| 428 | - {{ formatMoney(scope.row.LastMonthTransportSubsidy) }} | |
| 429 | - </template> | |
| 430 | - </el-table-column> | |
| 431 | - <el-table-column prop="SubsidyTotal" label="补贴合计" width="100" align="right"> | |
| 432 | - <template slot-scope="scope"> | |
| 433 | - {{ formatMoney(scope.row.SubsidyTotal) }} | |
| 434 | - </template> | |
| 435 | - </el-table-column> | |
| 2 | + <div class="salary-statistics-page"> | |
| 3 | + <!-- 搜索区域 --> | |
| 4 | + <div class="search-section"> | |
| 5 | + <el-card class="search-card"> | |
| 6 | + <div slot="header" class="search-header"> | |
| 7 | + <span><i class="el-icon-search"></i> 健康师工资统计查询</span> | |
| 8 | + </div> | |
| 9 | + <el-form :model="queryParams" :inline="true" class="search-form"> | |
| 10 | + <el-form-item label="统计月份"> | |
| 11 | + <el-date-picker v-model="queryParams.statisticsMonth" type="month" placeholder="选择月份" format="yyyyMM" | |
| 12 | + value-format="yyyyMM" size="small"></el-date-picker> | |
| 13 | + </el-form-item> | |
| 14 | + <el-form-item label="门店名称"> | |
| 15 | + <el-input v-model="queryParams.storeName" placeholder="请输入门店名称" size="small" clearable></el-input> | |
| 16 | + </el-form-item> | |
| 17 | + <el-form-item label="员工姓名"> | |
| 18 | + <el-input v-model="queryParams.employeeName" placeholder="请输入员工姓名" size="small" clearable></el-input> | |
| 19 | + </el-form-item> | |
| 20 | + <el-form-item label="岗位"> | |
| 21 | + <el-select v-model="queryParams.position" placeholder="请选择岗位" size="small" clearable> | |
| 22 | + <el-option label="健康师" value="健康师"></el-option> | |
| 23 | + <el-option label="店长" value="店长"></el-option> | |
| 24 | + <el-option label="主任" value="主任"></el-option> | |
| 25 | + </el-select> | |
| 26 | + </el-form-item> | |
| 27 | + <el-form-item label="金三角战队"> | |
| 28 | + <el-input v-model="queryParams.goldTriangleTeam" placeholder="请输入金三角战队" size="small" clearable></el-input> | |
| 29 | + </el-form-item> | |
| 30 | + <el-form-item label="是否锁定"> | |
| 31 | + <el-select v-model="queryParams.isLocked" placeholder="请选择锁定状态" size="small" clearable> | |
| 32 | + <el-option label="未锁定" :value="0"></el-option> | |
| 33 | + <el-option label="已锁定" :value="1"></el-option> | |
| 34 | + </el-select> | |
| 35 | + </el-form-item> | |
| 36 | + <el-form-item> | |
| 37 | + <el-button type="primary" size="small" @click="handleSearch"> | |
| 38 | + <i class="el-icon-search"></i> 搜索 | |
| 39 | + </el-button> | |
| 40 | + <el-button size="small" @click="handleReset"> | |
| 41 | + <i class="el-icon-refresh"></i> 重置 | |
| 42 | + </el-button> | |
| 43 | + </el-form-item> | |
| 44 | + </el-form> | |
| 45 | + </el-card> | |
| 46 | + </div> | |
| 47 | + | |
| 48 | + <!-- 表格区域 --> | |
| 49 | + <div class="table-section"> | |
| 50 | + <el-card class="table-card"> | |
| 51 | + <div slot="header" class="table-header"> | |
| 52 | + <span><i class="el-icon-s-data"></i> 健康师工资统计列表</span> | |
| 53 | + </div> | |
| 54 | + <el-table :data="tableData" v-loading="loading" border stripe style="width: 100%" :height="tableHeight"> | |
| 55 | + <!-- 基本信息 --> | |
| 56 | + <el-table-column prop="StatisticsMonth" label="统计月份" width="100" fixed="left"></el-table-column> | |
| 57 | + <el-table-column prop="StoreName" label="门店名称" width="120" fixed="left"></el-table-column> | |
| 58 | + <el-table-column prop="EmployeeName" label="员工姓名" width="100" fixed="left"></el-table-column> | |
| 59 | + <el-table-column prop="Position" label="岗位" width="100" fixed="left"></el-table-column> | |
| 60 | + <el-table-column prop="GoldTriangleTeam" label="金三角战队" width="120"></el-table-column> | |
| 61 | + | |
| 62 | + <!-- 业绩相关 --> | |
| 63 | + <el-table-column prop="TotalPerformance" label="总业绩" width="100" align="right"> | |
| 64 | + <template slot-scope="scope"> | |
| 65 | + {{ formatMoney(scope.row.TotalPerformance) }} | |
| 66 | + </template> | |
| 67 | + </el-table-column> | |
| 68 | + <el-table-column prop="BasePerformance" label="基础业绩" width="100" align="right"> | |
| 69 | + <template slot-scope="scope"> | |
| 70 | + {{ formatMoney(scope.row.BasePerformance) }} | |
| 71 | + </template> | |
| 72 | + </el-table-column> | |
| 73 | + <el-table-column prop="CooperationPerformance" label="合作业绩" width="100" align="right"> | |
| 74 | + <template slot-scope="scope"> | |
| 75 | + {{ formatMoney(scope.row.CooperationPerformance) }} | |
| 76 | + </template> | |
| 77 | + </el-table-column> | |
| 78 | + <el-table-column prop="RewardPerformance" label="奖励业绩" width="100" align="right"> | |
| 79 | + <template slot-scope="scope"> | |
| 80 | + {{ formatMoney(scope.row.RewardPerformance) }} | |
| 81 | + </template> | |
| 82 | + </el-table-column> | |
| 436 | 83 | |
| 437 | - <!-- 扣款相关 --> | |
| 438 | - <el-table-column prop="MissingCard" label="缺卡" width="100" align="right"> | |
| 439 | - <template slot-scope="scope"> | |
| 440 | - {{ formatMoney(scope.row.MissingCard) }} | |
| 441 | - </template> | |
| 442 | - </el-table-column> | |
| 443 | - <el-table-column prop="Late" label="迟到" width="100" align="right"> | |
| 444 | - <template slot-scope="scope"> | |
| 445 | - {{ formatMoney(scope.row.Late) }} | |
| 446 | - </template> | |
| 447 | - </el-table-column> | |
| 448 | - <el-table-column prop="Leave" label="请假" width="100" align="right"> | |
| 449 | - <template slot-scope="scope"> | |
| 450 | - {{ formatMoney(scope.row.Leave) }} | |
| 451 | - </template> | |
| 452 | - </el-table-column> | |
| 453 | - <el-table-column prop="SocialSecurityDeduction" label="扣社保" width="100" align="right"> | |
| 454 | - <template slot-scope="scope"> | |
| 455 | - {{ formatMoney(scope.row.SocialSecurityDeduction) }} | |
| 456 | - </template> | |
| 457 | - </el-table-column> | |
| 458 | - <el-table-column prop="RewardDeduction" label="扣除奖励" width="100" align="right"> | |
| 459 | - <template slot-scope="scope"> | |
| 460 | - {{ formatMoney(scope.row.RewardDeduction) }} | |
| 461 | - </template> | |
| 462 | - </el-table-column> | |
| 463 | - <el-table-column prop="AccommodationDeduction" label="扣住宿" width="100" align="right"> | |
| 464 | - <template slot-scope="scope"> | |
| 465 | - {{ formatMoney(scope.row.AccommodationDeduction) }} | |
| 466 | - </template> | |
| 467 | - </el-table-column> | |
| 468 | - <el-table-column prop="StudyPeriodDeduction" label="扣学习期" width="100" align="right"> | |
| 469 | - <template slot-scope="scope"> | |
| 470 | - {{ formatMoney(scope.row.StudyPeriodDeduction) }} | |
| 471 | - </template> | |
| 472 | - </el-table-column> | |
| 473 | - <el-table-column prop="WorkClothesDeduction" label="扣工作服" width="100" align="right"> | |
| 474 | - <template slot-scope="scope"> | |
| 475 | - {{ formatMoney(scope.row.WorkClothesDeduction) }} | |
| 476 | - </template> | |
| 477 | - </el-table-column> | |
| 478 | - <el-table-column prop="DeductionTotal" label="扣款合计" width="100" align="right"> | |
| 479 | - <template slot-scope="scope"> | |
| 480 | - {{ formatMoney(scope.row.DeductionTotal) }} | |
| 481 | - </template> | |
| 482 | - </el-table-column> | |
| 84 | + <!-- 新客数据 --> | |
| 85 | + <el-table-column label="新客数据" align="center"> | |
| 86 | + <el-table-column prop="NewCustomerPerformance" label="新客业绩" width="100" align="right"> | |
| 87 | + <template slot-scope="scope"> | |
| 88 | + {{ formatMoney(scope.row.NewCustomerPerformance) }} | |
| 89 | + </template> | |
| 90 | + </el-table-column> | |
| 91 | + <el-table-column prop="NewCustomerConversionRate" label="新客成交率" width="100" align="right"> | |
| 92 | + <template slot-scope="scope"> | |
| 93 | + {{ formatPercent(scope.row.NewCustomerConversionRate) }} | |
| 94 | + </template> | |
| 95 | + </el-table-column> | |
| 96 | + <el-table-column prop="NewCustomerPoint" label="新客提点" width="100" align="right"> | |
| 97 | + <template slot-scope="scope"> | |
| 98 | + {{ formatPercent(scope.row.NewCustomerPoint) }} | |
| 99 | + </template> | |
| 100 | + </el-table-column> | |
| 101 | + </el-table-column> | |
| 483 | 102 | |
| 484 | - <!-- 其他 --> | |
| 485 | - <el-table-column prop="Bonus" label="发奖金" width="100" align="right"> | |
| 486 | - <template slot-scope="scope"> | |
| 487 | - {{ formatMoney(scope.row.Bonus) }} | |
| 488 | - </template> | |
| 489 | - </el-table-column> | |
| 490 | - <el-table-column prop="PhoneDepositReturn" label="退手机押金" width="120" align="right"> | |
| 491 | - <template slot-scope="scope"> | |
| 492 | - {{ formatMoney(scope.row.PhoneDepositReturn) }} | |
| 493 | - </template> | |
| 494 | - </el-table-column> | |
| 495 | - <el-table-column prop="AccommodationDepositReturn" label="退住宿押金" width="120" align="right"> | |
| 496 | - <template slot-scope="scope"> | |
| 497 | - {{ formatMoney(scope.row.AccommodationDepositReturn) }} | |
| 498 | - </template> | |
| 499 | - </el-table-column> | |
| 500 | - <el-table-column prop="ActualGrossSalary" label="实发工资" width="100" align="right"> | |
| 501 | - <template slot-scope="scope"> | |
| 502 | - {{ formatMoney(scope.row.ActualGrossSalary) }} | |
| 503 | - </template> | |
| 504 | - </el-table-column> | |
| 505 | - <el-table-column prop="MonthlyPaymentStatus" label="当月是否发放" width="120" align="center"></el-table-column> | |
| 506 | - <el-table-column prop="PaymentAmount" label="支付金额" width="100" align="right"> | |
| 507 | - <template slot-scope="scope"> | |
| 508 | - {{ formatMoney(scope.row.PaymentAmount) }} | |
| 509 | - </template> | |
| 510 | - </el-table-column> | |
| 511 | - <el-table-column prop="PendingPaymentAmount" label="待支付金额" width="120" align="right"> | |
| 512 | - <template slot-scope="scope"> | |
| 513 | - {{ formatMoney(scope.row.PendingPaymentAmount) }} | |
| 514 | - </template> | |
| 515 | - </el-table-column> | |
| 516 | - <el-table-column prop="LastMonthSupplement" label="补发上月" width="100" align="right"> | |
| 517 | - <template slot-scope="scope"> | |
| 518 | - {{ formatMoney(scope.row.LastMonthSupplement) }} | |
| 519 | - </template> | |
| 520 | - </el-table-column> | |
| 521 | - <el-table-column prop="MonthlyPaymentTotal" label="当月支付总额" width="120" align="right"> | |
| 522 | - <template slot-scope="scope"> | |
| 523 | - {{ formatMoney(scope.row.MonthlyPaymentTotal) }} | |
| 524 | - </template> | |
| 525 | - </el-table-column> | |
| 526 | - <el-table-column prop="IsLocked" label="是否锁定" width="100" align="center"> | |
| 527 | - <template slot-scope="scope"> | |
| 528 | - <el-tag :type="scope.row.IsLocked ? 'danger' : 'success'"> | |
| 529 | - {{ scope.row.IsLocked ? '是' : '否' }} | |
| 530 | - </el-tag> | |
| 531 | - </template> | |
| 532 | - </el-table-column> | |
| 103 | + <!-- 升单数据 --> | |
| 104 | + <el-table-column label="升单数据" align="center"> | |
| 105 | + <el-table-column prop="UpgradePerformance" label="升单业绩" width="100" align="right"> | |
| 106 | + <template slot-scope="scope"> | |
| 107 | + {{ formatMoney(scope.row.UpgradePerformance) }} | |
| 108 | + </template> | |
| 109 | + </el-table-column> | |
| 110 | + <el-table-column prop="UpgradePoint" label="升单提点" width="100" align="right"> | |
| 111 | + <template slot-scope="scope"> | |
| 112 | + {{ formatPercent(scope.row.UpgradePoint) }} | |
| 113 | + </template> | |
| 114 | + </el-table-column> | |
| 115 | + </el-table-column> | |
| 533 | 116 | |
| 534 | - <!-- 工资相关 --> | |
| 535 | - <el-table-column label="工资数据" align="center"> | |
| 117 | + <!-- 其他数据 --> | |
| 118 | + <el-table-column prop="Consumption" label="消耗" width="100" align="right"> | |
| 119 | + <template slot-scope="scope"> | |
| 120 | + {{ formatMoney(scope.row.Consumption) }} | |
| 121 | + </template> | |
| 122 | + </el-table-column> | |
| 123 | + <el-table-column prop="ProjectCount" label="项目数" width="80" align="right"></el-table-column> | |
| 124 | + <el-table-column prop="StoreTotalPerformance" label="门店总业绩" width="120" align="right"> | |
| 125 | + <template slot-scope="scope"> | |
| 126 | + {{ formatMoney(scope.row.StoreTotalPerformance) }} | |
| 127 | + </template> | |
| 128 | + </el-table-column> | |
| 129 | + <el-table-column prop="TeamPerformance" label="队伍业绩" width="120" align="right"> | |
| 130 | + <template slot-scope="scope"> | |
| 131 | + {{ formatMoney(scope.row.TeamPerformance) }} | |
| 132 | + </template> | |
| 133 | + </el-table-column> | |
| 134 | + <el-table-column prop="Percentage" label="占比" width="100" align="right"> | |
| 135 | + <template slot-scope="scope"> | |
| 136 | + {{ formatPercent(scope.row.Percentage) }} | |
| 137 | + </template> | |
| 138 | + </el-table-column> | |
| 139 | + <el-table-column prop="CustomerCount" label="到店人头" width="100" align="right"></el-table-column> | |
| 140 | + <el-table-column prop="WorkingDays" label="在店天数" width="100" align="right"></el-table-column> | |
| 141 | + <el-table-column prop="LeaveDays" label="请假天数" width="100" align="right"></el-table-column> | |
| 142 | + <el-table-column prop="CommissionPoint" label="提点" width="100" align="right"> | |
| 143 | + <template slot-scope="scope"> | |
| 144 | + {{ formatPercent(scope.row.CommissionPoint) }} | |
| 145 | + </template> | |
| 146 | + </el-table-column> | |
| 147 | + <el-table-column prop="BasePerformanceCommission" label="基础业绩提成" width="120" align="right"> | |
| 148 | + <template slot-scope="scope"> | |
| 149 | + {{ formatMoney(scope.row.BasePerformanceCommission) }} | |
| 150 | + </template> | |
| 151 | + </el-table-column> | |
| 152 | + <el-table-column prop="CooperationPerformanceCommission" label="合作业绩提成" width="120" align="right"> | |
| 153 | + <template slot-scope="scope"> | |
| 154 | + {{ formatMoney(scope.row.CooperationPerformanceCommission) }} | |
| 155 | + </template> | |
| 156 | + </el-table-column> | |
| 157 | + <el-table-column prop="ConsultantCommission" label="顾问提成" width="100" align="right"> | |
| 158 | + <template slot-scope="scope"> | |
| 159 | + {{ formatMoney(scope.row.ConsultantCommission) }} | |
| 160 | + </template> | |
| 161 | + </el-table-column> | |
| 162 | + <el-table-column prop="StoreTZoneCommission" label="门店T区提成" width="120" align="right"> | |
| 163 | + <template slot-scope="scope"> | |
| 164 | + {{ formatMoney(scope.row.StoreTZoneCommission) }} | |
| 165 | + </template> | |
| 166 | + </el-table-column> | |
| 167 | + <el-table-column prop="TotalCommission" label="提成合计" width="120" align="right"> | |
| 168 | + <template slot-scope="scope"> | |
| 169 | + {{ formatMoney(scope.row.TotalCommission) }} | |
| 170 | + </template> | |
| 171 | + </el-table-column> | |
| 172 | + <el-table-column prop="HealthCoachBaseSalary" label="健康师底薪" width="120" align="right"> | |
| 173 | + <template slot-scope="scope"> | |
| 174 | + {{ formatMoney(scope.row.HealthCoachBaseSalary) }} | |
| 175 | + </template> | |
| 176 | + </el-table-column> | |
| 177 | + <el-table-column prop="HandworkFee" label="手工费" width="100" align="right"> | |
| 178 | + <template slot-scope="scope"> | |
| 179 | + {{ formatMoney(scope.row.HandworkFee) }} | |
| 180 | + </template> | |
| 181 | + </el-table-column> | |
| 182 | + <el-table-column prop="OutherHandworkFee" label="额外手工费" width="120" align="right"> | |
| 183 | + <template slot-scope="scope"> | |
| 184 | + {{ formatMoney(scope.row.OutherHandworkFee) }} | |
| 185 | + </template> | |
| 186 | + </el-table-column> | |
| 187 | + <el-table-column prop="TransportationAllowance" label="车补" width="100" align="right"> | |
| 188 | + <template slot-scope="scope"> | |
| 189 | + {{ formatMoney(scope.row.TransportationAllowance) }} | |
| 190 | + </template> | |
| 191 | + </el-table-column> | |
| 192 | + <el-table-column prop="LessRest" label="少休费" width="100" align="right"> | |
| 193 | + <template slot-scope="scope"> | |
| 194 | + {{ formatMoney(scope.row.LessRest) }} | |
| 195 | + </template> | |
| 196 | + </el-table-column> | |
| 197 | + <el-table-column prop="FullAttendance" label="全勤奖" width="100" align="right"> | |
| 198 | + <template slot-scope="scope"> | |
| 199 | + {{ formatMoney(scope.row.FullAttendance) }} | |
| 200 | + </template> | |
| 201 | + </el-table-column> | |
| 202 | + <el-table-column prop="CalculatedGrossSalary" label="核算应发工资" width="120" align="right"> | |
| 203 | + <template slot-scope="scope"> | |
| 204 | + {{ formatMoney(scope.row.CalculatedGrossSalary) }} | |
| 205 | + </template> | |
| 206 | + </el-table-column> | |
| 207 | + <el-table-column prop="GuaranteedSalary" label="保底工资" width="120" align="right"> | |
| 208 | + <template slot-scope="scope"> | |
| 209 | + {{ formatMoney(scope.row.GuaranteedSalary) }} | |
| 210 | + </template> | |
| 211 | + </el-table-column> | |
| 212 | + <el-table-column prop="GuaranteedLeaveDeduction" label="保底请假扣款" width="120" align="right"> | |
| 213 | + <template slot-scope="scope"> | |
| 214 | + {{ formatMoney(scope.row.GuaranteedLeaveDeduction) }} | |
| 215 | + </template> | |
| 216 | + </el-table-column> | |
| 217 | + <el-table-column prop="GuaranteedBaseSalary" label="保底底薪" width="120" align="right"> | |
| 218 | + <template slot-scope="scope"> | |
| 219 | + {{ formatMoney(scope.row.GuaranteedBaseSalary) }} | |
| 220 | + </template> | |
| 221 | + </el-table-column> | |
| 222 | + <el-table-column prop="GuaranteedSupplement" label="保底补差" width="120" align="right"> | |
| 223 | + <template slot-scope="scope"> | |
| 224 | + {{ formatMoney(scope.row.GuaranteedSupplement) }} | |
| 225 | + </template> | |
| 226 | + </el-table-column> | |
| 536 | 227 | <el-table-column prop="FinalGrossSalary" label="最终应发工资" width="120" align="right"> |
| 537 | 228 | <template slot-scope="scope"> |
| 538 | 229 | {{ formatMoney(scope.row.FinalGrossSalary) }} |
| 539 | 230 | </template> |
| 540 | 231 | </el-table-column> |
| 541 | - <el-table-column prop="actualSalary" label="实发工资" width="100" align="right"> | |
| 232 | + <el-table-column prop="MonthlyTrainingSubsidy" label="当月培训补贴" width="120" align="right"> | |
| 542 | 233 | <template slot-scope="scope"> |
| 543 | - {{ formatMoney(scope.row.actualSalary) }} | |
| 234 | + {{ formatMoney(scope.row.MonthlyTrainingSubsidy) }} | |
| 544 | 235 | </template> |
| 545 | 236 | </el-table-column> |
| 546 | - <el-table-column prop="totalDeduction" label="扣款合计" width="100" align="right"> | |
| 237 | + <el-table-column prop="MonthlyTransportSubsidy" label="当月交通补贴" width="120" align="right"> | |
| 547 | 238 | <template slot-scope="scope"> |
| 548 | - {{ formatMoney(scope.row.totalDeduction) }} | |
| 239 | + {{ formatMoney(scope.row.MonthlyTransportSubsidy) }} | |
| 549 | 240 | </template> |
| 550 | 241 | </el-table-column> |
| 551 | - </el-table-column> | |
| 552 | - | |
| 553 | - <!-- 其他数据 --> | |
| 554 | - <el-table-column prop="projectCount" label="项目数" width="80" align="center"></el-table-column> | |
| 555 | - <el-table-column prop="workingDays" label="在店天数" width="100" align="center"></el-table-column> | |
| 556 | - <el-table-column prop="leaveDays" label="请假天数" width="100" align="center"></el-table-column> | |
| 557 | - | |
| 558 | - <!-- 状态 --> | |
| 559 | - <el-table-column prop="IsLocked" label="锁定状态" width="100" align="center"> | |
| 560 | - <template slot-scope="scope"> | |
| 561 | - <el-tag :type="scope.row.IsLocked === 1 ? 'danger' : 'success'"> | |
| 562 | - {{ scope.row.IsLocked === 1 ? '已锁定' : '未锁定' }} | |
| 563 | - </el-tag> | |
| 564 | - </template> | |
| 565 | - </el-table-column> | |
| 566 | - | |
| 567 | - <!-- 操作 --> | |
| 568 | - <el-table-column label="操作" width="120" fixed="right" align="center"> | |
| 569 | - <template slot-scope="scope"> | |
| 570 | - <el-button type="text" size="mini" @click="handleView(scope.row)"> | |
| 571 | - <i class="el-icon-view"></i> 查看 | |
| 572 | - </el-button> | |
| 573 | - <el-button type="text" size="mini" @click="handleLock(scope.row)" :disabled="scope.row.IsLocked === 1"> | |
| 574 | - <i class="el-icon-lock"></i> 锁定 | |
| 575 | - </el-button> | |
| 576 | - </template> | |
| 577 | - </el-table-column> | |
| 578 | - </el-table> | |
| 579 | - | |
| 580 | - <!-- 分页 --> | |
| 581 | - <div class="pagination-container"> | |
| 582 | - <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 583 | - :current-page="pagination.currentPage" :page-sizes="[10, 20, 50, 100]" :page-size="pagination.pageSize" | |
| 584 | - :total="pagination.total" layout="total, sizes, prev, pager, next, jumper"> | |
| 585 | - </el-pagination> | |
| 586 | - </div> | |
| 587 | - </el-card> | |
| 242 | + <el-table-column prop="LastMonthTrainingSubsidy" label="上月培训补贴" width="120" align="right"> | |
| 243 | + <template slot-scope="scope"> | |
| 244 | + {{ formatMoney(scope.row.LastMonthTrainingSubsidy) }} | |
| 245 | + </template> | |
| 246 | + </el-table-column> | |
| 247 | + <el-table-column prop="LastMonthTransportSubsidy" label="上月交通补贴" width="120" align="right"> | |
| 248 | + <template slot-scope="scope"> | |
| 249 | + {{ formatMoney(scope.row.LastMonthTransportSubsidy) }} | |
| 250 | + </template> | |
| 251 | + </el-table-column> | |
| 252 | + <el-table-column prop="TotalSubsidy" label="补贴合计" width="120" align="right"> | |
| 253 | + <template slot-scope="scope"> | |
| 254 | + {{ formatMoney(scope.row.TotalSubsidy) }} | |
| 255 | + </template> | |
| 256 | + </el-table-column> | |
| 257 | + <el-table-column prop="MissingCard" label="缺卡扣款" width="120" align="right"> | |
| 258 | + <template slot-scope="scope"> | |
| 259 | + {{ formatMoney(scope.row.MissingCard) }} | |
| 260 | + </template> | |
| 261 | + </el-table-column> | |
| 262 | + <el-table-column prop="LateArrival" label="迟到扣款" width="120" align="right"> | |
| 263 | + <template slot-scope="scope"> | |
| 264 | + {{ formatMoney(scope.row.LateArrival) }} | |
| 265 | + </template> | |
| 266 | + </el-table-column> | |
| 267 | + <el-table-column prop="LeaveDeduction" label="请假扣款" width="120" align="right"> | |
| 268 | + <template slot-scope="scope"> | |
| 269 | + {{ formatMoney(scope.row.LeaveDeduction) }} | |
| 270 | + </template> | |
| 271 | + </el-table-column> | |
| 272 | + <el-table-column prop="SocialInsuranceDeduction" label="扣社保" width="120" align="right"> | |
| 273 | + <template slot-scope="scope"> | |
| 274 | + {{ formatMoney(scope.row.SocialInsuranceDeduction) }} | |
| 275 | + </template> | |
| 276 | + </el-table-column> | |
| 277 | + <el-table-column prop="RewardDeduction" label="扣除奖励" width="120" align="right"> | |
| 278 | + <template slot-scope="scope"> | |
| 279 | + {{ formatMoney(scope.row.RewardDeduction) }} | |
| 280 | + </template> | |
| 281 | + </el-table-column> | |
| 282 | + <el-table-column prop="AccommodationDeduction" label="扣住宿费" width="120" align="right"> | |
| 283 | + <template slot-scope="scope"> | |
| 284 | + {{ formatMoney(scope.row.AccommodationDeduction) }} | |
| 285 | + </template> | |
| 286 | + </el-table-column> | |
| 287 | + <el-table-column prop="StudyPeriodDeduction" label="扣学习期费用" width="120" align="right"> | |
| 288 | + <template slot-scope="scope"> | |
| 289 | + {{ formatMoney(scope.row.StudyPeriodDeduction) }} | |
| 290 | + </template> | |
| 291 | + </el-table-column> | |
| 292 | + <el-table-column prop="WorkClothesDeduction" label="扣工作服费用" width="120" align="right"> | |
| 293 | + <template slot-scope="scope"> | |
| 294 | + {{ formatMoney(scope.row.WorkClothesDeduction) }} | |
| 295 | + </template> | |
| 296 | + </el-table-column> | |
| 297 | + <el-table-column prop="TotalDeduction" label="扣款合计" width="120" align="right"> | |
| 298 | + <template slot-scope="scope"> | |
| 299 | + {{ formatMoney(scope.row.TotalDeduction) }} | |
| 300 | + </template> | |
| 301 | + </el-table-column> | |
| 302 | + <el-table-column prop="Bonus" label="发奖金" width="100" align="right"> | |
| 303 | + <template slot-scope="scope"> | |
| 304 | + {{ formatMoney(scope.row.Bonus) }} | |
| 305 | + </template> | |
| 306 | + </el-table-column> | |
| 307 | + <el-table-column prop="ReturnPhoneDeposit" label="退手机押金" width="120" align="right"> | |
| 308 | + <template slot-scope="scope"> | |
| 309 | + {{ formatMoney(scope.row.ReturnPhoneDeposit) }} | |
| 310 | + </template> | |
| 311 | + </el-table-column> | |
| 312 | + <el-table-column prop="ReturnAccommodationDeposit" label="退住宿押金" width="120" align="right"> | |
| 313 | + <template slot-scope="scope"> | |
| 314 | + {{ formatMoney(scope.row.ReturnAccommodationDeposit) }} | |
| 315 | + </template> | |
| 316 | + </el-table-column> | |
| 317 | + <el-table-column prop="ActualSalary" label="实发工资" width="120" align="right"> | |
| 318 | + <template slot-scope="scope"> | |
| 319 | + {{ formatMoney(scope.row.ActualSalary) }} | |
| 320 | + </template> | |
| 321 | + </el-table-column> | |
| 322 | + <el-table-column prop="MonthlyPaymentStatus" label="当月是否发放" width="120" align="center"></el-table-column> | |
| 323 | + <el-table-column prop="PaidAmount" label="支付金额" width="120" align="right"> | |
| 324 | + <template slot-scope="scope"> | |
| 325 | + {{ formatMoney(scope.row.PaidAmount) }} | |
| 326 | + </template> | |
| 327 | + </el-table-column> | |
| 328 | + <el-table-column prop="PendingAmount" label="待支付金额" width="120" align="right"> | |
| 329 | + <template slot-scope="scope"> | |
| 330 | + {{ formatMoney(scope.row.PendingAmount) }} | |
| 331 | + </template> | |
| 332 | + </el-table-column> | |
| 333 | + <el-table-column prop="LastMonthSupplement" label="补发上月" width="120" align="right"> | |
| 334 | + <template slot-scope="scope"> | |
| 335 | + {{ formatMoney(scope.row.LastMonthSupplement) }} | |
| 336 | + </template> | |
| 337 | + </el-table-column> | |
| 338 | + <el-table-column prop="MonthlyTotalPayment" label="当月支付总额" width="120" align="right"> | |
| 339 | + <template slot-scope="scope"> | |
| 340 | + {{ formatMoney(scope.row.MonthlyTotalPayment) }} | |
| 341 | + </template> | |
| 342 | + </el-table-column> | |
| 343 | + <el-table-column prop="IsLocked" label="锁定状态" width="100" align="center"> | |
| 344 | + <template slot-scope="scope"> | |
| 345 | + <el-tag :type="scope.row.IsLocked === 1 ? 'danger' : 'success'" size="mini"> | |
| 346 | + {{ scope.row.IsLocked === 1 ? '已锁定' : '未锁定' }} | |
| 347 | + </el-tag> | |
| 348 | + </template> | |
| 349 | + </el-table-column> | |
| 350 | + </el-table> | |
| 351 | + <div class="pagination-section"> | |
| 352 | + <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 353 | + :current-page="pagination.pageIndex" :page-sizes="[10, 20, 50, 100]" :page-size="pagination.pageSize" | |
| 354 | + layout="total, sizes, prev, pager, next, jumper" :total="pagination.total"></el-pagination> | |
| 355 | + </div> | |
| 356 | + </el-card> | |
| 357 | + | |
| 358 | + </div> | |
| 588 | 359 | </div> |
| 589 | 360 | </template> |
| 590 | 361 | |
| 591 | 362 | <script> |
| 592 | -import { getSalaryStatisticsList } from '@/api/extend/salaryCalculation' | |
| 363 | +import { getSalaryStatisticsList } from '@/api/extend/statistics' | |
| 593 | 364 | |
| 594 | 365 | export default { |
| 595 | 366 | name: 'SalaryStatistics', |
| 596 | 367 | data() { |
| 597 | 368 | return { |
| 598 | 369 | loading: false, |
| 599 | - queryForm: { | |
| 600 | - statisticsMonth: this.$route.query.month || this.getCurrentMonth(), | |
| 370 | + tableData: [], | |
| 371 | + tableHeight: 500, | |
| 372 | + queryParams: { | |
| 373 | + statisticsMonth: '', | |
| 601 | 374 | storeName: '', |
| 602 | 375 | employeeName: '', |
| 603 | 376 | position: '', |
| 377 | + goldTriangleTeam: '', | |
| 604 | 378 | isLocked: null |
| 605 | 379 | }, |
| 606 | - tableData: [], | |
| 607 | 380 | pagination: { |
| 608 | - currentPage: 1, | |
| 381 | + pageIndex: 1, | |
| 609 | 382 | pageSize: 20, |
| 610 | 383 | total: 0 |
| 611 | 384 | } |
| 612 | 385 | } |
| 613 | 386 | }, |
| 614 | - mounted() { | |
| 615 | - this.handleSearch() | |
| 387 | + created() { | |
| 388 | + this.getList() | |
| 616 | 389 | }, |
| 617 | 390 | methods: { |
| 618 | - // 获取当前月份 | |
| 619 | - getCurrentMonth() { | |
| 620 | - const now = new Date() | |
| 621 | - const year = now.getFullYear() | |
| 622 | - const month = String(now.getMonth() + 1).padStart(2, '0') | |
| 623 | - return `${year}${month}` | |
| 624 | - }, | |
| 625 | 391 | |
| 626 | - // 查询数据 | |
| 627 | - async handleSearch() { | |
| 392 | + // 获取列表数据 | |
| 393 | + async getList() { | |
| 628 | 394 | this.loading = true |
| 629 | 395 | try { |
| 630 | 396 | const params = { |
| 631 | - ...this.queryForm, | |
| 632 | - currentPage: this.pagination.currentPage, | |
| 633 | - pageSize: this.pagination.pageSize | |
| 397 | + currentPage: this.pagination.pageIndex, | |
| 398 | + pageSize: this.pagination.pageSize, | |
| 399 | + ...this.queryParams | |
| 634 | 400 | } |
| 635 | 401 | |
| 636 | 402 | const response = await getSalaryStatisticsList(params) |
| 637 | - console.log(response) | |
| 638 | - this.tableData = response.data.list || [] | |
| 639 | - this.pagination.total = response.data.pagination.total || 0 | |
| 403 | + | |
| 404 | + if (response.code === 200) { | |
| 405 | + this.tableData = response.data.list || [] | |
| 406 | + this.pagination.total = response.data.pagination.total || 0 | |
| 407 | + } else { | |
| 408 | + this.$message.error(response.msg || '获取数据失败') | |
| 409 | + } | |
| 640 | 410 | } catch (error) { |
| 641 | - this.$message.error('查询失败:' + error.message) | |
| 411 | + console.error('获取工资统计数据失败:', error) | |
| 412 | + this.$message.error('获取数据失败') | |
| 642 | 413 | } finally { |
| 643 | 414 | this.loading = false |
| 644 | 415 | } |
| 645 | 416 | }, |
| 646 | 417 | |
| 647 | - // 重置查询条件 | |
| 418 | + // 搜索 | |
| 419 | + handleSearch() { | |
| 420 | + this.pagination.pageIndex = 1 | |
| 421 | + this.getList() | |
| 422 | + }, | |
| 423 | + | |
| 424 | + // 重置 | |
| 648 | 425 | handleReset() { |
| 649 | - this.queryForm = { | |
| 650 | - statisticsMonth: this.getCurrentMonth(), | |
| 426 | + this.queryParams = { | |
| 427 | + statisticsMonth: '', | |
| 651 | 428 | storeName: '', |
| 652 | 429 | employeeName: '', |
| 653 | 430 | position: '', |
| 431 | + goldTriangleTeam: '', | |
| 654 | 432 | isLocked: null |
| 655 | 433 | } |
| 656 | - this.pagination.currentPage = 1 | |
| 657 | - this.handleSearch() | |
| 434 | + this.pagination.pageIndex = 1 | |
| 435 | + this.getList() | |
| 658 | 436 | }, |
| 659 | 437 | |
| 660 | 438 | // 分页大小改变 |
| 661 | 439 | handleSizeChange(val) { |
| 662 | 440 | this.pagination.pageSize = val |
| 663 | - this.pagination.currentPage = 1 | |
| 664 | - this.handleSearch() | |
| 441 | + this.pagination.pageIndex = 1 | |
| 442 | + this.getList() | |
| 665 | 443 | }, |
| 666 | 444 | |
| 667 | 445 | // 当前页改变 |
| 668 | 446 | handleCurrentChange(val) { |
| 669 | - this.pagination.currentPage = val | |
| 670 | - this.handleSearch() | |
| 671 | - }, | |
| 672 | - | |
| 673 | - // 查看详情 | |
| 674 | - handleView(row) { | |
| 675 | - this.$message.info('查看详情功能待开发') | |
| 676 | - }, | |
| 677 | - | |
| 678 | - // 锁定记录 | |
| 679 | - handleLock(row) { | |
| 680 | - this.$confirm('确定要锁定这条记录吗?锁定后将无法修改。', '确认锁定', { | |
| 681 | - confirmButtonText: '确定', | |
| 682 | - cancelButtonText: '取消', | |
| 683 | - type: 'warning' | |
| 684 | - }).then(() => { | |
| 685 | - this.$message.success('锁定功能待开发') | |
| 686 | - }).catch(() => { | |
| 687 | - this.$message.info('已取消锁定') | |
| 688 | - }) | |
| 447 | + this.pagination.pageIndex = val | |
| 448 | + this.getList() | |
| 689 | 449 | }, |
| 690 | 450 | |
| 691 | - | |
| 692 | - | |
| 693 | 451 | // 格式化金额 |
| 694 | 452 | formatMoney(value) { |
| 695 | - if (value === null || value === undefined) return '0.00' | |
| 696 | - return Number(value).toFixed(2) | |
| 697 | - }, | |
| 698 | - formatPercent(value) { | |
| 699 | - if (value === null || value === undefined) return '0.00' | |
| 453 | + if (value === null || value === undefined || value === '') { | |
| 454 | + return '0.00' | |
| 455 | + } | |
| 700 | 456 | return Number(value).toFixed(2) |
| 701 | 457 | }, |
| 702 | 458 | |
| 703 | - // 表格合计 | |
| 704 | - getSummaries(param) { | |
| 705 | - const { columns, data } = param | |
| 706 | - const sums = [] | |
| 707 | - columns.forEach((column, index) => { | |
| 708 | - if (index === 0) { | |
| 709 | - sums[index] = '合计' | |
| 710 | - return | |
| 711 | - } | |
| 712 | - | |
| 713 | - const values = data.map(item => Number(item[column.property])) | |
| 714 | - if (column.property && this.isMoneyColumn(column.property)) { | |
| 715 | - if (!values.every(value => isNaN(value))) { | |
| 716 | - sums[index] = values.reduce((prev, curr) => { | |
| 717 | - const value = Number(curr) | |
| 718 | - if (!isNaN(value)) { | |
| 719 | - return prev + curr | |
| 720 | - } else { | |
| 721 | - return prev | |
| 722 | - } | |
| 723 | - }, 0).toFixed(2) | |
| 724 | - } else { | |
| 725 | - sums[index] = '' | |
| 726 | - } | |
| 727 | - } else { | |
| 728 | - sums[index] = '' | |
| 729 | - } | |
| 730 | - }) | |
| 731 | - return sums | |
| 732 | - }, | |
| 733 | - | |
| 734 | - // 判断是否为金额列 | |
| 735 | - isMoneyColumn(property) { | |
| 736 | - const moneyColumns = [ | |
| 737 | - 'TotalPerformance', 'BasePerformance', 'CooperationPerformance', 'StoreTotalPerformance', | |
| 738 | - 'CommissionTotal', 'BasePerformanceCommission', 'CooperationPerformanceCommission', | |
| 739 | - 'BaseSalaryTotal', 'HealthCoachBaseSalary', 'StoreManagerBaseSalary', | |
| 740 | - 'FinalGrossSalary', 'ActualGrossSalary', 'DeductionTotal' | |
| 741 | - ] | |
| 742 | - return moneyColumns.includes(property) | |
| 459 | + // 格式化百分比 | |
| 460 | + formatPercent(value) { | |
| 461 | + if (value === null || value === undefined || value === '') { | |
| 462 | + return '0.00%' | |
| 463 | + } | |
| 464 | + return (Number(value) * 100).toFixed(2) + '%' | |
| 743 | 465 | } |
| 744 | 466 | } |
| 745 | 467 | } |
| 746 | 468 | </script> |
| 747 | 469 | |
| 748 | 470 | <style lang="scss" scoped> |
| 749 | -.salary-statistics-container { | |
| 471 | +.salary-statistics-page { | |
| 750 | 472 | padding: 20px; |
| 751 | - background-color: #f0f2f5; | |
| 473 | + height: calc(100vh - 150px); | |
| 474 | + display: flex; | |
| 475 | + flex-direction: column; | |
| 476 | + overflow: hidden; | |
| 477 | +} | |
| 752 | 478 | |
| 753 | - .search-card { | |
| 754 | - margin-bottom: 20px; | |
| 479 | +.search-section { | |
| 480 | + flex-shrink: 0; | |
| 481 | + margin-bottom: 20px; | |
| 482 | +} | |
| 483 | + | |
| 484 | +.search-card { | |
| 485 | + .search-header { | |
| 486 | + font-weight: 600; | |
| 487 | + color: #303133; | |
| 755 | 488 | } |
| 756 | 489 | |
| 757 | - .table-card { | |
| 758 | - .header-actions { | |
| 759 | - float: right; | |
| 490 | + .search-form { | |
| 491 | + .el-form-item { | |
| 492 | + margin-bottom: 18px; | |
| 760 | 493 | } |
| 761 | 494 | } |
| 495 | +} | |
| 762 | 496 | |
| 763 | - .pagination-container { | |
| 764 | - margin-top: 20px; | |
| 765 | - text-align: right; | |
| 497 | +.table-section { | |
| 498 | + flex: 1; | |
| 499 | + min-height: 0; | |
| 500 | + display: flex; | |
| 501 | + flex-direction: column; | |
| 502 | +} | |
| 503 | + | |
| 504 | +.table-card { | |
| 505 | + height: 100%; | |
| 506 | + | |
| 507 | + .table-header { | |
| 508 | + font-weight: 600; | |
| 509 | + color: #303133; | |
| 510 | + } | |
| 511 | + | |
| 512 | + .el-card__body { | |
| 513 | + padding: 20px; | |
| 766 | 514 | } |
| 767 | 515 | } |
| 768 | 516 | |
| 769 | -.box-card { | |
| 770 | - border-radius: 8px; | |
| 771 | - box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1); | |
| 517 | +.pagination-section { | |
| 518 | + flex-shrink: 0; | |
| 519 | + margin-top: 20px; | |
| 520 | + text-align: right; | |
| 521 | + padding-top: 20px; | |
| 522 | + border-top: 1px solid #ebeef5; | |
| 523 | +} | |
| 524 | + | |
| 525 | +// 表格样式优化 | |
| 526 | +.el-table { | |
| 527 | + overflow: auto; | |
| 528 | + | |
| 529 | + .el-table__header-wrapper { | |
| 530 | + th { | |
| 531 | + background-color: #f5f7fa; | |
| 532 | + color: #606266; | |
| 533 | + font-weight: 600; | |
| 534 | + } | |
| 535 | + } | |
| 536 | + | |
| 537 | + .el-table__body-wrapper { | |
| 538 | + .el-table__row { | |
| 539 | + &:hover { | |
| 540 | + background-color: #f5f7fa; | |
| 541 | + } | |
| 542 | + } | |
| 543 | + } | |
| 544 | +} | |
| 545 | + | |
| 546 | +// 搜索表单样式 | |
| 547 | +.search-form { | |
| 548 | + .el-form-item { | |
| 549 | + margin-right: 20px; | |
| 550 | + | |
| 551 | + &:last-child { | |
| 552 | + margin-right: 0; | |
| 553 | + } | |
| 554 | + } | |
| 772 | 555 | } |
| 773 | 556 | -</style> |
| 557 | +</style> | |
| 774 | 558 | \ No newline at end of file | ... | ... |
antis-ncc-admin/src/views/storeConsumePerformanceStatistics/index.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="store-consume-performance-statistics-container"> | |
| 3 | + <!-- 搜索卡片 --> | |
| 4 | + <el-card class="search-card"> | |
| 5 | + <div slot="header" class="clearfix"> | |
| 6 | + <span><i class="el-icon-s-shop"></i> 门店耗卡业绩统计</span> | |
| 7 | + </div> | |
| 8 | + <div class="search-form"> | |
| 9 | + <el-form :inline="true" :model="searchForm" class="demo-form-inline"> | |
| 10 | + <el-form-item label="统计月份"> | |
| 11 | + <el-date-picker v-model="searchForm.statisticsMonth" type="month" placeholder="选择月份" | |
| 12 | + format="yyyy年MM月" value-format="yyyyMM" :clearable="false" @change="handleSearch"> | |
| 13 | + </el-date-picker> | |
| 14 | + </el-form-item> | |
| 15 | + <el-form-item label="门店名称"> | |
| 16 | + <el-input v-model="searchForm.storeName" placeholder="请输入门店名称" clearable | |
| 17 | + @keyup.enter.native="handleSearch"> | |
| 18 | + </el-input> | |
| 19 | + </el-form-item> | |
| 20 | + <el-form-item> | |
| 21 | + <el-button type="primary" @click="handleSearch" :loading="loading"> | |
| 22 | + <i class="el-icon-search"></i> 查询 | |
| 23 | + </el-button> | |
| 24 | + <el-button @click="handleReset"> | |
| 25 | + <i class="el-icon-refresh"></i> 重置 | |
| 26 | + </el-button> | |
| 27 | + </el-form-item> | |
| 28 | + </el-form> | |
| 29 | + </div> | |
| 30 | + </el-card> | |
| 31 | + | |
| 32 | + <!-- 表格卡片 --> | |
| 33 | + <el-card class="table-card"> | |
| 34 | + <div slot="header" class="clearfix"> | |
| 35 | + <span><i class="el-icon-s-grid"></i> 门店耗卡业绩列表</span> | |
| 36 | + </div> | |
| 37 | + <div class="table-container"> | |
| 38 | + <el-table :data="tableData" v-loading="loading" element-loading-text="加载中..." :height="tableHeight" | |
| 39 | + border stripe style="width: 100%"> | |
| 40 | + <el-table-column prop="StoreName" label="门店名称" width="200" fixed="left"></el-table-column> | |
| 41 | + <el-table-column prop="TotalPerformance" label="总业绩" width="120" align="right"> | |
| 42 | + <template slot-scope="scope"> | |
| 43 | + {{ formatMoney(scope.row.TotalPerformance) }} | |
| 44 | + </template> | |
| 45 | + </el-table-column> | |
| 46 | + <el-table-column prop="ConsumePerformance" label="耗卡业绩" width="120" align="right"> | |
| 47 | + <template slot-scope="scope"> | |
| 48 | + {{ formatMoney(scope.row.ConsumePerformance) }} | |
| 49 | + </template> | |
| 50 | + </el-table-column> | |
| 51 | + <el-table-column prop="OrderCount" label="订单数量" width="100" align="right"></el-table-column> | |
| 52 | + <el-table-column prop="IsNewStore" label="是否新店" width="100" align="center"> | |
| 53 | + <template slot-scope="scope"> | |
| 54 | + <el-tag :type="scope.row.IsNewStore ? 'success' : 'info'"> | |
| 55 | + {{ scope.row.IsNewStore ? '是' : '否' }} | |
| 56 | + </el-tag> | |
| 57 | + </template> | |
| 58 | + </el-table-column> | |
| 59 | + <el-table-column prop="CreateTime" label="创建时间" width="150" align="center"> | |
| 60 | + <template slot-scope="scope"> | |
| 61 | + {{ formatDateTime(scope.row.CreateTime) }} | |
| 62 | + </template> | |
| 63 | + </el-table-column> | |
| 64 | + </el-table> | |
| 65 | + | |
| 66 | + <!-- 分页 --> | |
| 67 | + <div class="pagination-container"> | |
| 68 | + <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 69 | + :current-page="pagination.pageIndex" :page-sizes="[10, 20, 50, 100]" | |
| 70 | + :page-size="pagination.pageSize" :total="pagination.total" | |
| 71 | + layout="total, sizes, prev, pager, next, jumper"> | |
| 72 | + </el-pagination> | |
| 73 | + </div> | |
| 74 | + </div> | |
| 75 | + </el-card> | |
| 76 | + </div> | |
| 77 | +</template> | |
| 78 | + | |
| 79 | +<script> | |
| 80 | +import { getStoreConsumePerformanceStatisticsList } from '@/api/extend/statistics' | |
| 81 | + | |
| 82 | +export default { | |
| 83 | + name: 'StoreConsumePerformanceStatistics', | |
| 84 | + data() { | |
| 85 | + return { | |
| 86 | + loading: false, | |
| 87 | + tableData: [], | |
| 88 | + tableHeight: 400, | |
| 89 | + searchForm: { | |
| 90 | + statisticsMonth: this.getCurrentMonth(), | |
| 91 | + storeName: '' | |
| 92 | + }, | |
| 93 | + pagination: { | |
| 94 | + pageIndex: 1, | |
| 95 | + pageSize: 20, | |
| 96 | + total: 0 | |
| 97 | + } | |
| 98 | + } | |
| 99 | + }, | |
| 100 | + mounted() { | |
| 101 | + this.calculateTableHeight() | |
| 102 | + this.handleSearch() | |
| 103 | + window.addEventListener('resize', this.calculateTableHeight) | |
| 104 | + }, | |
| 105 | + beforeDestroy() { | |
| 106 | + window.removeEventListener('resize', this.calculateTableHeight) | |
| 107 | + }, | |
| 108 | + methods: { | |
| 109 | + getCurrentMonth() { | |
| 110 | + const now = new Date() | |
| 111 | + const year = now.getFullYear() | |
| 112 | + const month = String(now.getMonth() + 1).padStart(2, '0') | |
| 113 | + return `${year}${month}` | |
| 114 | + }, | |
| 115 | + calculateTableHeight() { | |
| 116 | + this.$nextTick(() => { | |
| 117 | + const container = this.$el | |
| 118 | + if (!container) return | |
| 119 | + | |
| 120 | + const containerHeight = container.clientHeight | |
| 121 | + const searchCard = container.querySelector('.search-card') | |
| 122 | + const tableCard = container.querySelector('.table-card') | |
| 123 | + | |
| 124 | + let searchCardHeight = 0 | |
| 125 | + if (searchCard) { | |
| 126 | + searchCardHeight = searchCard.offsetHeight + 20 | |
| 127 | + } | |
| 128 | + | |
| 129 | + const tableCardAvailableHeight = containerHeight - searchCardHeight - 100 | |
| 130 | + const tableCardHeight = Math.max(250, tableCardAvailableHeight) | |
| 131 | + | |
| 132 | + if (tableCard) { | |
| 133 | + tableCard.style.height = tableCardHeight + 'px' | |
| 134 | + } | |
| 135 | + | |
| 136 | + const tableContainer = container.querySelector('.table-container') | |
| 137 | + if (tableContainer) { | |
| 138 | + const cardHeaderHeight = 50 | |
| 139 | + const cardPadding = 30 | |
| 140 | + const tableContainerHeight = tableCardHeight - cardHeaderHeight - cardPadding | |
| 141 | + tableContainer.style.height = tableContainerHeight + 'px' | |
| 142 | + | |
| 143 | + const paginationHeight = 50 | |
| 144 | + const paginationMargin = 10 | |
| 145 | + this.tableHeight = Math.max(100, tableContainerHeight - paginationHeight - paginationMargin) | |
| 146 | + } | |
| 147 | + }) | |
| 148 | + }, | |
| 149 | + async handleSearch() { | |
| 150 | + this.loading = true | |
| 151 | + try { | |
| 152 | + const params = { | |
| 153 | + pageIndex: this.pagination.pageIndex, | |
| 154 | + pageSize: this.pagination.pageSize, | |
| 155 | + statisticsMonth: this.searchForm.statisticsMonth, | |
| 156 | + storeName: this.searchForm.storeName | |
| 157 | + } | |
| 158 | + | |
| 159 | + const response = await getStoreConsumePerformanceStatisticsList(params) | |
| 160 | + this.tableData = response.data.list || [] | |
| 161 | + this.pagination.total = response.data.pagination.total || 0 | |
| 162 | + } catch (error) { | |
| 163 | + this.$message.error('查询失败: ' + error.message) | |
| 164 | + } finally { | |
| 165 | + this.loading = false | |
| 166 | + } | |
| 167 | + }, | |
| 168 | + handleReset() { | |
| 169 | + this.searchForm = { | |
| 170 | + statisticsMonth: this.getCurrentMonth(), | |
| 171 | + storeName: '' | |
| 172 | + } | |
| 173 | + this.pagination.pageIndex = 1 | |
| 174 | + this.handleSearch() | |
| 175 | + }, | |
| 176 | + handleSizeChange(val) { | |
| 177 | + this.pagination.pageSize = val | |
| 178 | + this.pagination.pageIndex = 1 | |
| 179 | + this.handleSearch() | |
| 180 | + }, | |
| 181 | + handleCurrentChange(val) { | |
| 182 | + this.pagination.pageIndex = val | |
| 183 | + this.handleSearch() | |
| 184 | + }, | |
| 185 | + formatMoney(value) { | |
| 186 | + if (value === null || value === undefined) return '0.00' | |
| 187 | + return Number(value).toLocaleString('zh-CN', { | |
| 188 | + minimumFractionDigits: 2, | |
| 189 | + maximumFractionDigits: 2 | |
| 190 | + }) | |
| 191 | + }, | |
| 192 | + formatDateTime(value) { | |
| 193 | + if (!value) return '-' | |
| 194 | + return new Date(value).toLocaleString('zh-CN') | |
| 195 | + } | |
| 196 | + } | |
| 197 | +} | |
| 198 | +</script> | |
| 199 | + | |
| 200 | +<style lang="scss" scoped> | |
| 201 | +.store-consume-performance-statistics-container { | |
| 202 | + height: calc(100vh - 60px); | |
| 203 | + display: flex; | |
| 204 | + flex-direction: column; | |
| 205 | + overflow: hidden; | |
| 206 | + padding: 20px; | |
| 207 | + background-color: #f0f2f5; | |
| 208 | + | |
| 209 | + .search-card { | |
| 210 | + flex-shrink: 0; | |
| 211 | + margin-bottom: 20px; | |
| 212 | + border-radius: 8px; | |
| 213 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 214 | + | |
| 215 | + .search-form { | |
| 216 | + .el-form-item { | |
| 217 | + margin-bottom: 10px; | |
| 218 | + } | |
| 219 | + } | |
| 220 | + } | |
| 221 | + | |
| 222 | + .table-card { | |
| 223 | + flex: 1; | |
| 224 | + display: flex; | |
| 225 | + flex-direction: column; | |
| 226 | + overflow: hidden; | |
| 227 | + min-height: 0; | |
| 228 | + border-radius: 8px; | |
| 229 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 230 | + | |
| 231 | + .table-container { | |
| 232 | + height: 100%; | |
| 233 | + display: flex; | |
| 234 | + flex-direction: column; | |
| 235 | + overflow: hidden; | |
| 236 | + position: relative; | |
| 237 | + | |
| 238 | + .el-table { | |
| 239 | + flex: 1; | |
| 240 | + min-height: 0; | |
| 241 | + overflow: auto; | |
| 242 | + } | |
| 243 | + | |
| 244 | + .pagination-container { | |
| 245 | + margin-top: 10px; | |
| 246 | + padding: 5px 0; | |
| 247 | + height: 50px; | |
| 248 | + display: flex; | |
| 249 | + align-items: center; | |
| 250 | + justify-content: flex-end; | |
| 251 | + flex-shrink: 0; | |
| 252 | + } | |
| 253 | + } | |
| 254 | + } | |
| 255 | +} | |
| 256 | +</style> | ... | ... |
antis-ncc-admin/src/views/storeTotalPerformanceStatistics/index.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="store-total-performance-statistics-container"> | |
| 3 | + <!-- 搜索卡片 --> | |
| 4 | + <el-card class="search-card"> | |
| 5 | + <div slot="header" class="clearfix"> | |
| 6 | + <span><i class="el-icon-s-finance"></i> 门店总业绩统计</span> | |
| 7 | + </div> | |
| 8 | + <div class="search-form"> | |
| 9 | + <el-form :inline="true" :model="searchForm" class="demo-form-inline"> | |
| 10 | + <el-form-item label="统计月份"> | |
| 11 | + <el-date-picker v-model="searchForm.statisticsMonth" type="month" placeholder="选择月份" | |
| 12 | + format="yyyy年MM月" value-format="yyyyMM" :clearable="false" @change="handleSearch"> | |
| 13 | + </el-date-picker> | |
| 14 | + </el-form-item> | |
| 15 | + <el-form-item label="门店名称"> | |
| 16 | + <el-input v-model="searchForm.storeName" placeholder="请输入门店名称" clearable | |
| 17 | + @keyup.enter.native="handleSearch"> | |
| 18 | + </el-input> | |
| 19 | + </el-form-item> | |
| 20 | + <el-form-item> | |
| 21 | + <el-button type="primary" @click="handleSearch" :loading="loading"> | |
| 22 | + <i class="el-icon-search"></i> 查询 | |
| 23 | + </el-button> | |
| 24 | + <el-button @click="handleReset"> | |
| 25 | + <i class="el-icon-refresh"></i> 重置 | |
| 26 | + </el-button> | |
| 27 | + </el-form-item> | |
| 28 | + </el-form> | |
| 29 | + </div> | |
| 30 | + </el-card> | |
| 31 | + | |
| 32 | + <!-- 表格卡片 --> | |
| 33 | + <el-card class="table-card"> | |
| 34 | + <div slot="header" class="clearfix"> | |
| 35 | + <span><i class="el-icon-s-grid"></i> 门店总业绩列表</span> | |
| 36 | + </div> | |
| 37 | + <div class="table-container"> | |
| 38 | + <el-table :data="tableData" v-loading="loading" element-loading-text="加载中..." :height="tableHeight" | |
| 39 | + border stripe style="width: 100%"> | |
| 40 | + <el-table-column prop="StoreName" label="门店名称" width="200" fixed="left"></el-table-column> | |
| 41 | + <el-table-column prop="TotalPerformance" label="总业绩" width="120" align="right"> | |
| 42 | + <template slot-scope="scope"> | |
| 43 | + {{ formatMoney(scope.row.TotalPerformance) }} | |
| 44 | + </template> | |
| 45 | + </el-table-column> | |
| 46 | + <el-table-column prop="DebtAmount" label="欠款金额" width="120" align="right"> | |
| 47 | + <template slot-scope="scope"> | |
| 48 | + {{ formatMoney(scope.row.DebtAmount) }} | |
| 49 | + </template> | |
| 50 | + </el-table-column> | |
| 51 | + <el-table-column prop="TotalOrderPerformance" label="总单业绩" width="120" align="right"> | |
| 52 | + <template slot-scope="scope"> | |
| 53 | + {{ formatMoney(scope.row.TotalOrderPerformance) }} | |
| 54 | + </template> | |
| 55 | + </el-table-column> | |
| 56 | + <el-table-column prop="StorageDeductionAmount" label="储扣总金额" width="120" align="right"> | |
| 57 | + <template slot-scope="scope"> | |
| 58 | + {{ formatMoney(scope.row.StorageDeductionAmount) }} | |
| 59 | + </template> | |
| 60 | + </el-table-column> | |
| 61 | + <el-table-column prop="ItemQuantity" label="品项数量" width="100" align="right"></el-table-column> | |
| 62 | + <el-table-column prop="FirstOrderCount" label="首开单数量" width="100" align="right"></el-table-column> | |
| 63 | + <el-table-column prop="UpgradeOrderCount" label="升单数量" width="100" align="right"></el-table-column> | |
| 64 | + <el-table-column prop="CreateTime" label="创建时间" width="150" align="center"> | |
| 65 | + <template slot-scope="scope"> | |
| 66 | + {{ formatDateTime(scope.row.CreateTime) }} | |
| 67 | + </template> | |
| 68 | + </el-table-column> | |
| 69 | + </el-table> | |
| 70 | + | |
| 71 | + <!-- 分页 --> | |
| 72 | + <div class="pagination-container"> | |
| 73 | + <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 74 | + :current-page="pagination.pageIndex" :page-sizes="[10, 20, 50, 100]" | |
| 75 | + :page-size="pagination.pageSize" :total="pagination.total" | |
| 76 | + layout="total, sizes, prev, pager, next, jumper"> | |
| 77 | + </el-pagination> | |
| 78 | + </div> | |
| 79 | + </div> | |
| 80 | + </el-card> | |
| 81 | + </div> | |
| 82 | +</template> | |
| 83 | + | |
| 84 | +<script> | |
| 85 | +import { getStoreTotalPerformanceStatisticsList } from '@/api/extend/statistics' | |
| 86 | + | |
| 87 | +export default { | |
| 88 | + name: 'StoreTotalPerformanceStatistics', | |
| 89 | + data() { | |
| 90 | + return { | |
| 91 | + loading: false, | |
| 92 | + tableData: [], | |
| 93 | + tableHeight: 400, | |
| 94 | + searchForm: { | |
| 95 | + statisticsMonth: this.getCurrentMonth(), | |
| 96 | + storeName: '' | |
| 97 | + }, | |
| 98 | + pagination: { | |
| 99 | + pageIndex: 1, | |
| 100 | + pageSize: 20, | |
| 101 | + total: 0 | |
| 102 | + } | |
| 103 | + } | |
| 104 | + }, | |
| 105 | + mounted() { | |
| 106 | + this.calculateTableHeight() | |
| 107 | + this.handleSearch() | |
| 108 | + window.addEventListener('resize', this.calculateTableHeight) | |
| 109 | + }, | |
| 110 | + beforeDestroy() { | |
| 111 | + window.removeEventListener('resize', this.calculateTableHeight) | |
| 112 | + }, | |
| 113 | + methods: { | |
| 114 | + getCurrentMonth() { | |
| 115 | + const now = new Date() | |
| 116 | + const year = now.getFullYear() | |
| 117 | + const month = String(now.getMonth() + 1).padStart(2, '0') | |
| 118 | + return `${year}${month}` | |
| 119 | + }, | |
| 120 | + calculateTableHeight() { | |
| 121 | + this.$nextTick(() => { | |
| 122 | + const container = this.$el | |
| 123 | + if (!container) return | |
| 124 | + | |
| 125 | + const containerHeight = container.clientHeight | |
| 126 | + const searchCard = container.querySelector('.search-card') | |
| 127 | + const tableCard = container.querySelector('.table-card') | |
| 128 | + | |
| 129 | + let searchCardHeight = 0 | |
| 130 | + if (searchCard) { | |
| 131 | + searchCardHeight = searchCard.offsetHeight + 20 | |
| 132 | + } | |
| 133 | + | |
| 134 | + const tableCardAvailableHeight = containerHeight - searchCardHeight - 100 | |
| 135 | + const tableCardHeight = Math.max(250, tableCardAvailableHeight) | |
| 136 | + | |
| 137 | + if (tableCard) { | |
| 138 | + tableCard.style.height = tableCardHeight + 'px' | |
| 139 | + } | |
| 140 | + | |
| 141 | + const tableContainer = container.querySelector('.table-container') | |
| 142 | + if (tableContainer) { | |
| 143 | + const cardHeaderHeight = 50 | |
| 144 | + const cardPadding = 30 | |
| 145 | + const tableContainerHeight = tableCardHeight - cardHeaderHeight - cardPadding | |
| 146 | + tableContainer.style.height = tableContainerHeight + 'px' | |
| 147 | + | |
| 148 | + const paginationHeight = 50 | |
| 149 | + const paginationMargin = 10 | |
| 150 | + this.tableHeight = Math.max(100, tableContainerHeight - paginationHeight - paginationMargin) | |
| 151 | + } | |
| 152 | + }) | |
| 153 | + }, | |
| 154 | + async handleSearch() { | |
| 155 | + this.loading = true | |
| 156 | + try { | |
| 157 | + const params = { | |
| 158 | + pageIndex: this.pagination.pageIndex, | |
| 159 | + pageSize: this.pagination.pageSize, | |
| 160 | + statisticsMonth: this.searchForm.statisticsMonth, | |
| 161 | + storeName: this.searchForm.storeName | |
| 162 | + } | |
| 163 | + | |
| 164 | + const response = await getStoreTotalPerformanceStatisticsList(params) | |
| 165 | + this.tableData = response.data.list || [] | |
| 166 | + this.pagination.total = response.data.pagination.total || 0 | |
| 167 | + } catch (error) { | |
| 168 | + this.$message.error('查询失败: ' + error.message) | |
| 169 | + } finally { | |
| 170 | + this.loading = false | |
| 171 | + } | |
| 172 | + }, | |
| 173 | + handleReset() { | |
| 174 | + this.searchForm = { | |
| 175 | + statisticsMonth: this.getCurrentMonth(), | |
| 176 | + storeName: '' | |
| 177 | + } | |
| 178 | + this.pagination.pageIndex = 1 | |
| 179 | + this.handleSearch() | |
| 180 | + }, | |
| 181 | + handleSizeChange(val) { | |
| 182 | + this.pagination.pageSize = val | |
| 183 | + this.pagination.pageIndex = 1 | |
| 184 | + this.handleSearch() | |
| 185 | + }, | |
| 186 | + handleCurrentChange(val) { | |
| 187 | + this.pagination.pageIndex = val | |
| 188 | + this.handleSearch() | |
| 189 | + }, | |
| 190 | + formatMoney(value) { | |
| 191 | + if (value === null || value === undefined) return '0.00' | |
| 192 | + return Number(value).toLocaleString('zh-CN', { | |
| 193 | + minimumFractionDigits: 2, | |
| 194 | + maximumFractionDigits: 2 | |
| 195 | + }) | |
| 196 | + }, | |
| 197 | + formatDateTime(value) { | |
| 198 | + if (!value) return '-' | |
| 199 | + return new Date(value).toLocaleString('zh-CN') | |
| 200 | + } | |
| 201 | + } | |
| 202 | +} | |
| 203 | +</script> | |
| 204 | + | |
| 205 | +<style lang="scss" scoped> | |
| 206 | +.store-total-performance-statistics-container { | |
| 207 | + height: calc(100vh - 60px); | |
| 208 | + display: flex; | |
| 209 | + flex-direction: column; | |
| 210 | + overflow: hidden; | |
| 211 | + padding: 20px; | |
| 212 | + background-color: #f0f2f5; | |
| 213 | + | |
| 214 | + .search-card { | |
| 215 | + flex-shrink: 0; | |
| 216 | + margin-bottom: 20px; | |
| 217 | + border-radius: 8px; | |
| 218 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 219 | + | |
| 220 | + .search-form { | |
| 221 | + .el-form-item { | |
| 222 | + margin-bottom: 10px; | |
| 223 | + } | |
| 224 | + } | |
| 225 | + } | |
| 226 | + | |
| 227 | + .table-card { | |
| 228 | + flex: 1; | |
| 229 | + display: flex; | |
| 230 | + flex-direction: column; | |
| 231 | + overflow: hidden; | |
| 232 | + min-height: 0; | |
| 233 | + border-radius: 8px; | |
| 234 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 235 | + | |
| 236 | + .table-container { | |
| 237 | + height: 100%; | |
| 238 | + display: flex; | |
| 239 | + flex-direction: column; | |
| 240 | + overflow: hidden; | |
| 241 | + position: relative; | |
| 242 | + | |
| 243 | + .el-table { | |
| 244 | + flex: 1; | |
| 245 | + min-height: 0; | |
| 246 | + overflow: auto; | |
| 247 | + } | |
| 248 | + | |
| 249 | + .pagination-container { | |
| 250 | + margin-top: 10px; | |
| 251 | + padding: 5px 0; | |
| 252 | + height: 50px; | |
| 253 | + display: flex; | |
| 254 | + align-items: center; | |
| 255 | + justify-content: flex-end; | |
| 256 | + flex-shrink: 0; | |
| 257 | + } | |
| 258 | + } | |
| 259 | + } | |
| 260 | +} | |
| 261 | +</style> | ... | ... |
antis-ncc-admin/src/views/techPerformanceStatistics/index.vue
0 → 100644
| 1 | +<template> | |
| 2 | + <div class="tech-performance-statistics-container"> | |
| 3 | + <!-- 搜索卡片 --> | |
| 4 | + <el-card class="search-card"> | |
| 5 | + <div slot="header" class="clearfix"> | |
| 6 | + <span><i class="el-icon-s-promotion"></i> 科技部开单业绩统计</span> | |
| 7 | + </div> | |
| 8 | + <div class="search-form"> | |
| 9 | + <el-form :inline="true" :model="searchForm" class="demo-form-inline"> | |
| 10 | + <el-form-item label="统计月份"> | |
| 11 | + <el-date-picker v-model="searchForm.statisticsMonth" type="month" placeholder="选择月份" | |
| 12 | + format="yyyy年MM月" value-format="yyyyMM" :clearable="false" @change="handleSearch"> | |
| 13 | + </el-date-picker> | |
| 14 | + </el-form-item> | |
| 15 | + <el-form-item label="老师姓名"> | |
| 16 | + <el-input v-model="searchForm.teacherName" placeholder="请输入老师姓名" clearable | |
| 17 | + @keyup.enter.native="handleSearch"> | |
| 18 | + </el-input> | |
| 19 | + </el-form-item> | |
| 20 | + <el-form-item label="门店名称"> | |
| 21 | + <el-input v-model="searchForm.storeName" placeholder="请输入门店名称" clearable | |
| 22 | + @keyup.enter.native="handleSearch"> | |
| 23 | + </el-input> | |
| 24 | + </el-form-item> | |
| 25 | + <el-form-item> | |
| 26 | + <el-button type="primary" @click="handleSearch" :loading="loading"> | |
| 27 | + <i class="el-icon-search"></i> 查询 | |
| 28 | + </el-button> | |
| 29 | + <el-button @click="handleReset"> | |
| 30 | + <i class="el-icon-refresh"></i> 重置 | |
| 31 | + </el-button> | |
| 32 | + </el-form-item> | |
| 33 | + </el-form> | |
| 34 | + </div> | |
| 35 | + </el-card> | |
| 36 | + | |
| 37 | + <!-- 表格卡片 --> | |
| 38 | + <el-card class="table-card"> | |
| 39 | + <div slot="header" class="clearfix"> | |
| 40 | + <span><i class="el-icon-s-grid"></i> 科技部开单业绩列表</span> | |
| 41 | + </div> | |
| 42 | + <div class="table-container"> | |
| 43 | + <el-table :data="tableData" v-loading="loading" element-loading-text="加载中..." :height="tableHeight" | |
| 44 | + border stripe style="width: 100%"> | |
| 45 | + <el-table-column prop="TeacherName" label="老师姓名" width="120" fixed="left"></el-table-column> | |
| 46 | + <el-table-column prop="StoreName" label="门店名称" width="150" fixed="left"></el-table-column> | |
| 47 | + <el-table-column prop="TotalPerformance" label="总业绩" width="100" align="right"> | |
| 48 | + <template slot-scope="scope"> | |
| 49 | + {{ formatMoney(scope.row.TotalPerformance) }} | |
| 50 | + </template> | |
| 51 | + </el-table-column> | |
| 52 | + <el-table-column prop="OrderCount" label="订单数量" width="100" align="right"></el-table-column> | |
| 53 | + <el-table-column prop="CreateTime" label="创建时间" width="150" align="center"> | |
| 54 | + <template slot-scope="scope"> | |
| 55 | + {{ formatDateTime(scope.row.CreateTime) }} | |
| 56 | + </template> | |
| 57 | + </el-table-column> | |
| 58 | + </el-table> | |
| 59 | + | |
| 60 | + <!-- 分页 --> | |
| 61 | + <div class="pagination-container"> | |
| 62 | + <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" | |
| 63 | + :current-page="pagination.pageIndex" :page-sizes="[10, 20, 50, 100]" | |
| 64 | + :page-size="pagination.pageSize" :total="pagination.total" | |
| 65 | + layout="total, sizes, prev, pager, next, jumper"> | |
| 66 | + </el-pagination> | |
| 67 | + </div> | |
| 68 | + </div> | |
| 69 | + </el-card> | |
| 70 | + </div> | |
| 71 | +</template> | |
| 72 | + | |
| 73 | +<script> | |
| 74 | +import { getTechPerformanceStatisticsList } from '@/api/extend/statistics' | |
| 75 | + | |
| 76 | +export default { | |
| 77 | + name: 'TechPerformanceStatistics', | |
| 78 | + data() { | |
| 79 | + return { | |
| 80 | + loading: false, | |
| 81 | + tableData: [], | |
| 82 | + tableHeight: 400, | |
| 83 | + searchForm: { | |
| 84 | + statisticsMonth: this.getCurrentMonth(), | |
| 85 | + teacherName: '', | |
| 86 | + storeName: '' | |
| 87 | + }, | |
| 88 | + pagination: { | |
| 89 | + pageIndex: 1, | |
| 90 | + pageSize: 20, | |
| 91 | + total: 0 | |
| 92 | + } | |
| 93 | + } | |
| 94 | + }, | |
| 95 | + mounted() { | |
| 96 | + this.calculateTableHeight() | |
| 97 | + this.handleSearch() | |
| 98 | + window.addEventListener('resize', this.calculateTableHeight) | |
| 99 | + }, | |
| 100 | + beforeDestroy() { | |
| 101 | + window.removeEventListener('resize', this.calculateTableHeight) | |
| 102 | + }, | |
| 103 | + methods: { | |
| 104 | + getCurrentMonth() { | |
| 105 | + const now = new Date() | |
| 106 | + const year = now.getFullYear() | |
| 107 | + const month = String(now.getMonth() + 1).padStart(2, '0') | |
| 108 | + return `${year}${month}` | |
| 109 | + }, | |
| 110 | + calculateTableHeight() { | |
| 111 | + this.$nextTick(() => { | |
| 112 | + const container = this.$el | |
| 113 | + if (!container) return | |
| 114 | + | |
| 115 | + const containerHeight = container.clientHeight | |
| 116 | + const searchCard = container.querySelector('.search-card') | |
| 117 | + const tableCard = container.querySelector('.table-card') | |
| 118 | + | |
| 119 | + let searchCardHeight = 0 | |
| 120 | + if (searchCard) { | |
| 121 | + searchCardHeight = searchCard.offsetHeight + 20 | |
| 122 | + } | |
| 123 | + | |
| 124 | + const tableCardAvailableHeight = containerHeight - searchCardHeight - 100 | |
| 125 | + const tableCardHeight = Math.max(250, tableCardAvailableHeight) | |
| 126 | + | |
| 127 | + if (tableCard) { | |
| 128 | + tableCard.style.height = tableCardHeight + 'px' | |
| 129 | + } | |
| 130 | + | |
| 131 | + const tableContainer = container.querySelector('.table-container') | |
| 132 | + if (tableContainer) { | |
| 133 | + const cardHeaderHeight = 50 | |
| 134 | + const cardPadding = 30 | |
| 135 | + const tableContainerHeight = tableCardHeight - cardHeaderHeight - cardPadding | |
| 136 | + tableContainer.style.height = tableContainerHeight + 'px' | |
| 137 | + | |
| 138 | + const paginationHeight = 50 | |
| 139 | + const paginationMargin = 10 | |
| 140 | + this.tableHeight = Math.max(100, tableContainerHeight - paginationHeight - paginationMargin) | |
| 141 | + } | |
| 142 | + }) | |
| 143 | + }, | |
| 144 | + async handleSearch() { | |
| 145 | + this.loading = true | |
| 146 | + try { | |
| 147 | + const params = { | |
| 148 | + pageIndex: this.pagination.pageIndex, | |
| 149 | + pageSize: this.pagination.pageSize, | |
| 150 | + statisticsMonth: this.searchForm.statisticsMonth, | |
| 151 | + teacherName: this.searchForm.teacherName, | |
| 152 | + storeName: this.searchForm.storeName | |
| 153 | + } | |
| 154 | + | |
| 155 | + const response = await getTechPerformanceStatisticsList(params) | |
| 156 | + this.tableData = response.data.list || [] | |
| 157 | + this.pagination.total = response.data.pagination.total || 0 | |
| 158 | + } catch (error) { | |
| 159 | + this.$message.error('查询失败: ' + error.message) | |
| 160 | + } finally { | |
| 161 | + this.loading = false | |
| 162 | + } | |
| 163 | + }, | |
| 164 | + handleReset() { | |
| 165 | + this.searchForm = { | |
| 166 | + statisticsMonth: this.getCurrentMonth(), | |
| 167 | + teacherName: '', | |
| 168 | + storeName: '' | |
| 169 | + } | |
| 170 | + this.pagination.pageIndex = 1 | |
| 171 | + this.handleSearch() | |
| 172 | + }, | |
| 173 | + handleSizeChange(val) { | |
| 174 | + this.pagination.pageSize = val | |
| 175 | + this.pagination.pageIndex = 1 | |
| 176 | + this.handleSearch() | |
| 177 | + }, | |
| 178 | + handleCurrentChange(val) { | |
| 179 | + this.pagination.pageIndex = val | |
| 180 | + this.handleSearch() | |
| 181 | + }, | |
| 182 | + formatMoney(value) { | |
| 183 | + if (value === null || value === undefined) return '0.00' | |
| 184 | + return Number(value).toLocaleString('zh-CN', { | |
| 185 | + minimumFractionDigits: 2, | |
| 186 | + maximumFractionDigits: 2 | |
| 187 | + }) | |
| 188 | + }, | |
| 189 | + formatDateTime(value) { | |
| 190 | + if (!value) return '-' | |
| 191 | + return new Date(value).toLocaleString('zh-CN') | |
| 192 | + } | |
| 193 | + } | |
| 194 | +} | |
| 195 | +</script> | |
| 196 | + | |
| 197 | +<style lang="scss" scoped> | |
| 198 | +.tech-performance-statistics-container { | |
| 199 | + height: calc(100vh - 60px); | |
| 200 | + display: flex; | |
| 201 | + flex-direction: column; | |
| 202 | + overflow: hidden; | |
| 203 | + padding: 20px; | |
| 204 | + background-color: #f0f2f5; | |
| 205 | + | |
| 206 | + .search-card { | |
| 207 | + flex-shrink: 0; | |
| 208 | + margin-bottom: 20px; | |
| 209 | + border-radius: 8px; | |
| 210 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 211 | + | |
| 212 | + .search-form { | |
| 213 | + .el-form-item { | |
| 214 | + margin-bottom: 10px; | |
| 215 | + } | |
| 216 | + } | |
| 217 | + } | |
| 218 | + | |
| 219 | + .table-card { | |
| 220 | + flex: 1; | |
| 221 | + display: flex; | |
| 222 | + flex-direction: column; | |
| 223 | + overflow: hidden; | |
| 224 | + min-height: 0; | |
| 225 | + border-radius: 8px; | |
| 226 | + box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); | |
| 227 | + | |
| 228 | + .table-container { | |
| 229 | + height: 100%; | |
| 230 | + display: flex; | |
| 231 | + flex-direction: column; | |
| 232 | + overflow: hidden; | |
| 233 | + position: relative; | |
| 234 | + | |
| 235 | + .el-table { | |
| 236 | + flex: 1; | |
| 237 | + min-height: 0; | |
| 238 | + overflow: auto; | |
| 239 | + } | |
| 240 | + | |
| 241 | + .pagination-container { | |
| 242 | + margin-top: 10px; | |
| 243 | + padding: 5px 0; | |
| 244 | + height: 50px; | |
| 245 | + display: flex; | |
| 246 | + align-items: center; | |
| 247 | + justify-content: flex-end; | |
| 248 | + flex-shrink: 0; | |
| 249 | + } | |
| 250 | + } | |
| 251 | + } | |
| 252 | +} | |
| 253 | +</style> | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqSalaryStatistics/LqSalaryStatisticsListOutput.cs
| ... | ... | @@ -3,7 +3,7 @@ using System; |
| 3 | 3 | namespace NCC.Extend.Entitys.Dto.LqSalaryStatistics |
| 4 | 4 | { |
| 5 | 5 | /// <summary> |
| 6 | - /// 工资统计列表输出参数 | |
| 6 | + /// 健康师工资统计列表输出参数 | |
| 7 | 7 | /// </summary> |
| 8 | 8 | public class LqSalaryStatisticsListOutput |
| 9 | 9 | { |
| ... | ... | @@ -48,6 +48,11 @@ namespace NCC.Extend.Entitys.Dto.LqSalaryStatistics |
| 48 | 48 | public string GoldTriangleTeam { get; set; } |
| 49 | 49 | |
| 50 | 50 | /// <summary> |
| 51 | + /// 金三角ID | |
| 52 | + /// </summary> | |
| 53 | + public string GoldTriangleId { get; set; } | |
| 54 | + | |
| 55 | + /// <summary> | |
| 51 | 56 | /// 总业绩 |
| 52 | 57 | /// </summary> |
| 53 | 58 | public decimal TotalPerformance { get; set; } |
| ... | ... | @@ -113,76 +118,6 @@ namespace NCC.Extend.Entitys.Dto.LqSalaryStatistics |
| 113 | 118 | public decimal UpgradePoint { get; set; } |
| 114 | 119 | |
| 115 | 120 | /// <summary> |
| 116 | - /// 溯源业绩 | |
| 117 | - /// </summary> | |
| 118 | - public decimal TraceabilityPerformance { get; set; } | |
| 119 | - | |
| 120 | - /// <summary> | |
| 121 | - /// Cell业绩 | |
| 122 | - /// </summary> | |
| 123 | - public decimal CellPerformance { get; set; } | |
| 124 | - | |
| 125 | - /// <summary> | |
| 126 | - /// 大项目一部业绩 | |
| 127 | - /// </summary> | |
| 128 | - public decimal ProjectOnePerformance { get; set; } | |
| 129 | - | |
| 130 | - /// <summary> | |
| 131 | - /// 大项目二部业绩 | |
| 132 | - /// </summary> | |
| 133 | - public decimal ProjectTwoPerformance { get; set; } | |
| 134 | - | |
| 135 | - /// <summary> | |
| 136 | - /// 当月业绩 | |
| 137 | - /// </summary> | |
| 138 | - public decimal MonthlyPerformance { get; set; } | |
| 139 | - | |
| 140 | - /// <summary> | |
| 141 | - /// 物业水电 | |
| 142 | - /// </summary> | |
| 143 | - public decimal PropertyWaterElectricity { get; set; } | |
| 144 | - | |
| 145 | - /// <summary> | |
| 146 | - /// 门店支出 | |
| 147 | - /// </summary> | |
| 148 | - public decimal StoreExpense { get; set; } | |
| 149 | - | |
| 150 | - /// <summary> | |
| 151 | - /// 产品物料 | |
| 152 | - /// </summary> | |
| 153 | - public decimal ProductMaterial { get; set; } | |
| 154 | - | |
| 155 | - /// <summary> | |
| 156 | - /// 微雕成本 | |
| 157 | - /// </summary> | |
| 158 | - public decimal MicroSculptureCost { get; set; } | |
| 159 | - | |
| 160 | - /// <summary> | |
| 161 | - /// 其它合作成本 | |
| 162 | - /// </summary> | |
| 163 | - public decimal OtherCooperationCost { get; set; } | |
| 164 | - | |
| 165 | - /// <summary> | |
| 166 | - /// 洗毛巾 | |
| 167 | - /// </summary> | |
| 168 | - public decimal TowelWashing { get; set; } | |
| 169 | - | |
| 170 | - /// <summary> | |
| 171 | - /// 毛利 | |
| 172 | - /// </summary> | |
| 173 | - public decimal GrossProfit { get; set; } | |
| 174 | - | |
| 175 | - /// <summary> | |
| 176 | - /// 总经理提成额 | |
| 177 | - /// </summary> | |
| 178 | - public decimal GeneralManagerCommission { get; set; } | |
| 179 | - | |
| 180 | - /// <summary> | |
| 181 | - /// 经理提成额 | |
| 182 | - /// </summary> | |
| 183 | - public decimal ManagerCommission { get; set; } | |
| 184 | - | |
| 185 | - /// <summary> | |
| 186 | 121 | /// 消耗 |
| 187 | 122 | /// </summary> |
| 188 | 123 | public decimal Consumption { get; set; } |
| ... | ... | @@ -228,66 +163,6 @@ namespace NCC.Extend.Entitys.Dto.LqSalaryStatistics |
| 228 | 163 | public decimal StoreTAreaCommission { get; set; } |
| 229 | 164 | |
| 230 | 165 | /// <summary> |
| 231 | - /// 店助提成 | |
| 232 | - /// </summary> | |
| 233 | - public decimal AssistantCommission1 { get; set; } | |
| 234 | - | |
| 235 | - /// <summary> | |
| 236 | - /// 店助主任提成 | |
| 237 | - /// </summary> | |
| 238 | - public decimal AssistantDirectorCommission { get; set; } | |
| 239 | - | |
| 240 | - /// <summary> | |
| 241 | - /// 主任提成 | |
| 242 | - /// </summary> | |
| 243 | - public decimal DirectorCommission { get; set; } | |
| 244 | - | |
| 245 | - /// <summary> | |
| 246 | - /// 店长提成 | |
| 247 | - /// </summary> | |
| 248 | - public decimal AssistantCommission2 { get; set; } | |
| 249 | - | |
| 250 | - /// <summary> | |
| 251 | - /// 总经理提成 | |
| 252 | - /// </summary> | |
| 253 | - public decimal GeneralManagerCommissionAmount { get; set; } | |
| 254 | - | |
| 255 | - /// <summary> | |
| 256 | - /// 经理提成 | |
| 257 | - /// </summary> | |
| 258 | - public decimal ManagerCommissionAmount { get; set; } | |
| 259 | - | |
| 260 | - /// <summary> | |
| 261 | - /// 业绩提成 | |
| 262 | - /// </summary> | |
| 263 | - public decimal PerformanceCommission { get; set; } | |
| 264 | - | |
| 265 | - /// <summary> | |
| 266 | - /// 消耗提成 | |
| 267 | - /// </summary> | |
| 268 | - public decimal ConsumptionCommission { get; set; } | |
| 269 | - | |
| 270 | - /// <summary> | |
| 271 | - /// 科技部组长提成 | |
| 272 | - /// </summary> | |
| 273 | - public decimal TechGroupLeaderCommission { get; set; } | |
| 274 | - | |
| 275 | - /// <summary> | |
| 276 | - /// 溯源提成 | |
| 277 | - /// </summary> | |
| 278 | - public decimal TraceabilityCommission { get; set; } | |
| 279 | - | |
| 280 | - /// <summary> | |
| 281 | - /// Cell提成 | |
| 282 | - /// </summary> | |
| 283 | - public decimal CellCommission { get; set; } | |
| 284 | - | |
| 285 | - /// <summary> | |
| 286 | - /// 大项目部提成 | |
| 287 | - /// </summary> | |
| 288 | - public decimal ProjectCommission { get; set; } | |
| 289 | - | |
| 290 | - /// <summary> | |
| 291 | 166 | /// 提成合计 |
| 292 | 167 | /// </summary> |
| 293 | 168 | public decimal CommissionTotal { get; set; } |
| ... | ... | @@ -298,64 +173,14 @@ namespace NCC.Extend.Entitys.Dto.LqSalaryStatistics |
| 298 | 173 | public decimal HealthCoachBaseSalary { get; set; } |
| 299 | 174 | |
| 300 | 175 | /// <summary> |
| 301 | - /// 店助底薪 | |
| 302 | - /// </summary> | |
| 303 | - public decimal AssistantBaseSalary { get; set; } | |
| 304 | - | |
| 305 | - /// <summary> | |
| 306 | - /// 店长底薪 | |
| 307 | - /// </summary> | |
| 308 | - public decimal ManagerBaseSalary { get; set; } | |
| 309 | - | |
| 310 | - /// <summary> | |
| 311 | - /// 主任底薪 | |
| 312 | - /// </summary> | |
| 313 | - public decimal DirectorBaseSalary { get; set; } | |
| 314 | - | |
| 315 | - /// <summary> | |
| 316 | - /// 店助主任底薪 | |
| 317 | - /// </summary> | |
| 318 | - public decimal AssistantDirectorBaseSalary { get; set; } | |
| 319 | - | |
| 320 | - /// <summary> | |
| 321 | - /// 总经理底薪 | |
| 322 | - /// </summary> | |
| 323 | - public decimal GeneralManagerBaseSalary { get; set; } | |
| 324 | - | |
| 325 | - /// <summary> | |
| 326 | - /// 经理底薪 | |
| 327 | - /// </summary> | |
| 328 | - public decimal ManagerBaseSalaryAmount { get; set; } | |
| 329 | - | |
| 330 | - /// <summary> | |
| 331 | - /// 科技部老师底薪 | |
| 332 | - /// </summary> | |
| 333 | - public decimal TechTeacherBaseSalary { get; set; } | |
| 334 | - | |
| 335 | - /// <summary> | |
| 336 | - /// 大项目部底薪 | |
| 337 | - /// </summary> | |
| 338 | - public decimal ProjectBaseSalary { get; set; } | |
| 339 | - | |
| 340 | - /// <summary> | |
| 341 | - /// 底薪合计 | |
| 342 | - /// </summary> | |
| 343 | - public decimal BaseSalaryTotal { get; set; } | |
| 344 | - | |
| 345 | - /// <summary> | |
| 346 | - /// 手工 | |
| 176 | + /// 手工费 | |
| 347 | 177 | /// </summary> |
| 348 | 178 | public decimal ManualWork { get; set; } |
| 349 | 179 | |
| 350 | 180 | /// <summary> |
| 351 | - /// 人头奖励 | |
| 181 | + /// 额外手工费 | |
| 352 | 182 | /// </summary> |
| 353 | - public decimal HeadCountReward { get; set; } | |
| 354 | - | |
| 355 | - /// <summary> | |
| 356 | - /// 手机管理 | |
| 357 | - /// </summary> | |
| 358 | - public decimal PhoneManagement { get; set; } | |
| 183 | + public decimal OutherHandworkFee { get; set; } | |
| 359 | 184 | |
| 360 | 185 | /// <summary> |
| 361 | 186 | /// 车补 |
| ... | ... | @@ -531,9 +356,5 @@ namespace NCC.Extend.Entitys.Dto.LqSalaryStatistics |
| 531 | 356 | /// 更新时间 |
| 532 | 357 | /// </summary> |
| 533 | 358 | public DateTime UpdateTime { get; set; } |
| 534 | - | |
| 535 | - | |
| 536 | - | |
| 537 | - | |
| 538 | 359 | } |
| 539 | 360 | } |
| 540 | 361 | \ No newline at end of file | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqDepartmentConsumePerformanceStatisticsListOutput.cs
0 → 100644
| 1 | +using System; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 个人消耗业绩统计列表输出 | |
| 7 | + /// </summary> | |
| 8 | + public class LqDepartmentConsumePerformanceStatisticsListOutput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 主键ID | |
| 12 | + /// </summary> | |
| 13 | + public string Id { get; set; } | |
| 14 | + | |
| 15 | + /// <summary> | |
| 16 | + /// 统计月份 | |
| 17 | + /// </summary> | |
| 18 | + public string StatisticsMonth { get; set; } | |
| 19 | + | |
| 20 | + /// <summary> | |
| 21 | + /// 员工ID | |
| 22 | + /// </summary> | |
| 23 | + public string EmployeeId { get; set; } | |
| 24 | + | |
| 25 | + /// <summary> | |
| 26 | + /// 员工姓名 | |
| 27 | + /// </summary> | |
| 28 | + public string EmployeeName { get; set; } | |
| 29 | + | |
| 30 | + /// <summary> | |
| 31 | + /// 门店ID | |
| 32 | + /// </summary> | |
| 33 | + public string StoreId { get; set; } | |
| 34 | + | |
| 35 | + /// <summary> | |
| 36 | + /// 门店名称 | |
| 37 | + /// </summary> | |
| 38 | + public string StoreName { get; set; } | |
| 39 | + | |
| 40 | + /// <summary> | |
| 41 | + /// 岗位 | |
| 42 | + /// </summary> | |
| 43 | + public string Position { get; set; } | |
| 44 | + | |
| 45 | + /// <summary> | |
| 46 | + /// 总业绩金额 | |
| 47 | + /// </summary> | |
| 48 | + public decimal TotalPerformance { get; set; } | |
| 49 | + | |
| 50 | + /// <summary> | |
| 51 | + /// 消耗业绩金额 | |
| 52 | + /// </summary> | |
| 53 | + public decimal ConsumePerformance { get; set; } | |
| 54 | + | |
| 55 | + /// <summary> | |
| 56 | + /// 订单数量 | |
| 57 | + /// </summary> | |
| 58 | + public int OrderCount { get; set; } | |
| 59 | + | |
| 60 | + /// <summary> | |
| 61 | + /// 创建时间 | |
| 62 | + /// </summary> | |
| 63 | + public DateTime CreateTime { get; set; } | |
| 64 | + } | |
| 65 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqDepartmentConsumePerformanceStatisticsListQueryInput.cs
0 → 100644
| 1 | +using System.ComponentModel.DataAnnotations; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 个人消耗业绩统计列表查询输入 | |
| 7 | + /// </summary> | |
| 8 | + public class LqDepartmentConsumePerformanceStatisticsListQueryInput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 页码 | |
| 12 | + /// </summary> | |
| 13 | + [Required] | |
| 14 | + public int PageIndex { get; set; } = 1; | |
| 15 | + | |
| 16 | + /// <summary> | |
| 17 | + /// 页大小 | |
| 18 | + /// </summary> | |
| 19 | + [Required] | |
| 20 | + public int PageSize { get; set; } = 20; | |
| 21 | + | |
| 22 | + /// <summary> | |
| 23 | + /// 统计月份 | |
| 24 | + /// </summary> | |
| 25 | + public string StatisticsMonth { get; set; } | |
| 26 | + | |
| 27 | + /// <summary> | |
| 28 | + /// 员工姓名 | |
| 29 | + /// </summary> | |
| 30 | + public string EmployeeName { get; set; } | |
| 31 | + | |
| 32 | + /// <summary> | |
| 33 | + /// 门店名称 | |
| 34 | + /// </summary> | |
| 35 | + public string StoreName { get; set; } | |
| 36 | + | |
| 37 | + /// <summary> | |
| 38 | + /// 岗位 | |
| 39 | + /// </summary> | |
| 40 | + public string Position { get; set; } | |
| 41 | + } | |
| 42 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqGoldTriangleStatisticsListOutput.cs
0 → 100644
| 1 | +using System; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 金三角开卡业绩统计列表输出 | |
| 7 | + /// </summary> | |
| 8 | + public class LqGoldTriangleStatisticsListOutput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 主键ID | |
| 12 | + /// </summary> | |
| 13 | + public string Id { get; set; } | |
| 14 | + | |
| 15 | + /// <summary> | |
| 16 | + /// 金三角ID | |
| 17 | + /// </summary> | |
| 18 | + public string GoldTriangleId { get; set; } | |
| 19 | + | |
| 20 | + /// <summary> | |
| 21 | + /// 金三角战队名称 | |
| 22 | + /// </summary> | |
| 23 | + public string GoldTriangleName { get; set; } | |
| 24 | + | |
| 25 | + /// <summary> | |
| 26 | + /// 统计月份 | |
| 27 | + /// </summary> | |
| 28 | + public string StatisticsMonth { get; set; } | |
| 29 | + | |
| 30 | + /// <summary> | |
| 31 | + /// 门店ID | |
| 32 | + /// </summary> | |
| 33 | + public string StoreId { get; set; } | |
| 34 | + | |
| 35 | + /// <summary> | |
| 36 | + /// 门店名称 | |
| 37 | + /// </summary> | |
| 38 | + public string StoreName { get; set; } | |
| 39 | + | |
| 40 | + /// <summary> | |
| 41 | + /// 订单数量 | |
| 42 | + /// </summary> | |
| 43 | + public int OrderCount { get; set; } | |
| 44 | + | |
| 45 | + /// <summary> | |
| 46 | + /// 总业绩金额 | |
| 47 | + /// </summary> | |
| 48 | + public decimal TotalPerformance { get; set; } | |
| 49 | + | |
| 50 | + /// <summary> | |
| 51 | + /// 首次订单日期 | |
| 52 | + /// </summary> | |
| 53 | + public DateTime? FirstOrderDate { get; set; } | |
| 54 | + | |
| 55 | + /// <summary> | |
| 56 | + /// 最后订单日期 | |
| 57 | + /// </summary> | |
| 58 | + public DateTime? LastOrderDate { get; set; } | |
| 59 | + | |
| 60 | + /// <summary> | |
| 61 | + /// 创建时间 | |
| 62 | + /// </summary> | |
| 63 | + public DateTime CreateTime { get; set; } | |
| 64 | + } | |
| 65 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqGoldTriangleStatisticsListQueryInput.cs
0 → 100644
| 1 | +using System.ComponentModel.DataAnnotations; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 金三角开卡业绩统计列表查询输入 | |
| 7 | + /// </summary> | |
| 8 | + public class LqGoldTriangleStatisticsListQueryInput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 页码 | |
| 12 | + /// </summary> | |
| 13 | + [Required] | |
| 14 | + public int PageIndex { get; set; } = 1; | |
| 15 | + | |
| 16 | + /// <summary> | |
| 17 | + /// 页大小 | |
| 18 | + /// </summary> | |
| 19 | + [Required] | |
| 20 | + public int PageSize { get; set; } = 20; | |
| 21 | + | |
| 22 | + /// <summary> | |
| 23 | + /// 统计月份 | |
| 24 | + /// </summary> | |
| 25 | + public string StatisticsMonth { get; set; } | |
| 26 | + | |
| 27 | + /// <summary> | |
| 28 | + /// 金三角战队名称 | |
| 29 | + /// </summary> | |
| 30 | + public string GoldTriangleName { get; set; } | |
| 31 | + | |
| 32 | + /// <summary> | |
| 33 | + /// 门店名称 | |
| 34 | + /// </summary> | |
| 35 | + public string StoreName { get; set; } | |
| 36 | + } | |
| 37 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqPersonalPerformanceStatisticsListQueryInput.cs
0 → 100644
| 1 | +using System.ComponentModel.DataAnnotations; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 健康师个人开单业绩统计列表查询输入 | |
| 7 | + /// </summary> | |
| 8 | + public class LqPersonalPerformanceStatisticsListQueryInput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 页码 | |
| 12 | + /// </summary> | |
| 13 | + [Required] | |
| 14 | + public int PageIndex { get; set; } = 1; | |
| 15 | + | |
| 16 | + /// <summary> | |
| 17 | + /// 页大小 | |
| 18 | + /// </summary> | |
| 19 | + [Required] | |
| 20 | + public int PageSize { get; set; } = 20; | |
| 21 | + | |
| 22 | + /// <summary> | |
| 23 | + /// 统计月份 | |
| 24 | + /// </summary> | |
| 25 | + public string StatisticsMonth { get; set; } | |
| 26 | + | |
| 27 | + /// <summary> | |
| 28 | + /// 员工姓名 | |
| 29 | + /// </summary> | |
| 30 | + public string EmployeeName { get; set; } | |
| 31 | + | |
| 32 | + /// <summary> | |
| 33 | + /// 门店名称 | |
| 34 | + /// </summary> | |
| 35 | + public string StoreName { get; set; } | |
| 36 | + | |
| 37 | + /// <summary> | |
| 38 | + /// 岗位 | |
| 39 | + /// </summary> | |
| 40 | + public string Position { get; set; } | |
| 41 | + } | |
| 42 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqStoreConsumePerformanceStatisticsListOutput.cs
0 → 100644
| 1 | +using System; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 门店耗卡业绩统计列表输出 | |
| 7 | + /// </summary> | |
| 8 | + public class LqStoreConsumePerformanceStatisticsListOutput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 主键ID | |
| 12 | + /// </summary> | |
| 13 | + public string Id { get; set; } | |
| 14 | + | |
| 15 | + /// <summary> | |
| 16 | + /// 统计月份 | |
| 17 | + /// </summary> | |
| 18 | + public string StatisticsMonth { get; set; } | |
| 19 | + | |
| 20 | + /// <summary> | |
| 21 | + /// 门店ID | |
| 22 | + /// </summary> | |
| 23 | + public string StoreId { get; set; } | |
| 24 | + | |
| 25 | + /// <summary> | |
| 26 | + /// 门店名称 | |
| 27 | + /// </summary> | |
| 28 | + public string StoreName { get; set; } | |
| 29 | + | |
| 30 | + /// <summary> | |
| 31 | + /// 总业绩金额 | |
| 32 | + /// </summary> | |
| 33 | + public decimal TotalPerformance { get; set; } | |
| 34 | + | |
| 35 | + /// <summary> | |
| 36 | + /// 耗卡业绩金额 | |
| 37 | + /// </summary> | |
| 38 | + public decimal ConsumePerformance { get; set; } | |
| 39 | + | |
| 40 | + /// <summary> | |
| 41 | + /// 订单数量 | |
| 42 | + /// </summary> | |
| 43 | + public int OrderCount { get; set; } | |
| 44 | + | |
| 45 | + /// <summary> | |
| 46 | + /// 是否新店 | |
| 47 | + /// </summary> | |
| 48 | + public bool IsNewStore { get; set; } | |
| 49 | + | |
| 50 | + /// <summary> | |
| 51 | + /// 创建时间 | |
| 52 | + /// </summary> | |
| 53 | + public DateTime CreateTime { get; set; } | |
| 54 | + } | |
| 55 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqStoreConsumePerformanceStatisticsListQueryInput.cs
0 → 100644
| 1 | +using System.ComponentModel.DataAnnotations; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 门店耗卡业绩统计列表查询输入 | |
| 7 | + /// </summary> | |
| 8 | + public class LqStoreConsumePerformanceStatisticsListQueryInput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 页码 | |
| 12 | + /// </summary> | |
| 13 | + [Required] | |
| 14 | + public int PageIndex { get; set; } = 1; | |
| 15 | + | |
| 16 | + /// <summary> | |
| 17 | + /// 页大小 | |
| 18 | + /// </summary> | |
| 19 | + [Required] | |
| 20 | + public int PageSize { get; set; } = 20; | |
| 21 | + | |
| 22 | + /// <summary> | |
| 23 | + /// 统计月份 | |
| 24 | + /// </summary> | |
| 25 | + public string StatisticsMonth { get; set; } | |
| 26 | + | |
| 27 | + /// <summary> | |
| 28 | + /// 门店名称 | |
| 29 | + /// </summary> | |
| 30 | + public string StoreName { get; set; } | |
| 31 | + } | |
| 32 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqStoreTotalPerformanceStatisticsListOutput.cs
0 → 100644
| 1 | +using System; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 门店总业绩统计列表输出 | |
| 7 | + /// </summary> | |
| 8 | + public class LqStoreTotalPerformanceStatisticsListOutput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 主键ID | |
| 12 | + /// </summary> | |
| 13 | + public string Id { get; set; } | |
| 14 | + | |
| 15 | + /// <summary> | |
| 16 | + /// 统计月份 | |
| 17 | + /// </summary> | |
| 18 | + public string StatisticsMonth { get; set; } | |
| 19 | + | |
| 20 | + /// <summary> | |
| 21 | + /// 门店ID | |
| 22 | + /// </summary> | |
| 23 | + public string StoreId { get; set; } | |
| 24 | + | |
| 25 | + /// <summary> | |
| 26 | + /// 门店名称 | |
| 27 | + /// </summary> | |
| 28 | + public string StoreName { get; set; } | |
| 29 | + | |
| 30 | + /// <summary> | |
| 31 | + /// 总业绩金额 | |
| 32 | + /// </summary> | |
| 33 | + public decimal TotalPerformance { get; set; } | |
| 34 | + | |
| 35 | + /// <summary> | |
| 36 | + /// 欠款金额 | |
| 37 | + /// </summary> | |
| 38 | + public decimal DebtAmount { get; set; } | |
| 39 | + | |
| 40 | + /// <summary> | |
| 41 | + /// 总单业绩金额 | |
| 42 | + /// </summary> | |
| 43 | + public decimal TotalOrderPerformance { get; set; } | |
| 44 | + | |
| 45 | + /// <summary> | |
| 46 | + /// 储扣总金额 | |
| 47 | + /// </summary> | |
| 48 | + public decimal StorageDeductionAmount { get; set; } | |
| 49 | + | |
| 50 | + /// <summary> | |
| 51 | + /// 品项数量 | |
| 52 | + /// </summary> | |
| 53 | + public int ItemQuantity { get; set; } | |
| 54 | + | |
| 55 | + /// <summary> | |
| 56 | + /// 首开单数量 | |
| 57 | + /// </summary> | |
| 58 | + public int FirstOrderCount { get; set; } | |
| 59 | + | |
| 60 | + /// <summary> | |
| 61 | + /// 升单数量 | |
| 62 | + /// </summary> | |
| 63 | + public int UpgradeOrderCount { get; set; } | |
| 64 | + | |
| 65 | + /// <summary> | |
| 66 | + /// 创建时间 | |
| 67 | + /// </summary> | |
| 68 | + public DateTime CreateTime { get; set; } | |
| 69 | + } | |
| 70 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqStoreTotalPerformanceStatisticsListQueryInput.cs
0 → 100644
| 1 | +using System.ComponentModel.DataAnnotations; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 门店总业绩统计列表查询输入 | |
| 7 | + /// </summary> | |
| 8 | + public class LqStoreTotalPerformanceStatisticsListQueryInput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 页码 | |
| 12 | + /// </summary> | |
| 13 | + [Required] | |
| 14 | + public int PageIndex { get; set; } = 1; | |
| 15 | + | |
| 16 | + /// <summary> | |
| 17 | + /// 页大小 | |
| 18 | + /// </summary> | |
| 19 | + [Required] | |
| 20 | + public int PageSize { get; set; } = 20; | |
| 21 | + | |
| 22 | + /// <summary> | |
| 23 | + /// 统计月份 | |
| 24 | + /// </summary> | |
| 25 | + public string StatisticsMonth { get; set; } | |
| 26 | + | |
| 27 | + /// <summary> | |
| 28 | + /// 门店名称 | |
| 29 | + /// </summary> | |
| 30 | + public string StoreName { get; set; } | |
| 31 | + } | |
| 32 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqTechPerformanceStatisticsListOutput.cs
0 → 100644
| 1 | +using System; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 科技部开单业绩统计列表输出 | |
| 7 | + /// </summary> | |
| 8 | + public class LqTechPerformanceStatisticsListOutput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 主键ID | |
| 12 | + /// </summary> | |
| 13 | + public string Id { get; set; } | |
| 14 | + | |
| 15 | + /// <summary> | |
| 16 | + /// 统计月份 | |
| 17 | + /// </summary> | |
| 18 | + public string StatisticsMonth { get; set; } | |
| 19 | + | |
| 20 | + /// <summary> | |
| 21 | + /// 老师ID | |
| 22 | + /// </summary> | |
| 23 | + public string TeacherId { get; set; } | |
| 24 | + | |
| 25 | + /// <summary> | |
| 26 | + /// 老师姓名 | |
| 27 | + /// </summary> | |
| 28 | + public string TeacherName { get; set; } | |
| 29 | + | |
| 30 | + /// <summary> | |
| 31 | + /// 门店ID | |
| 32 | + /// </summary> | |
| 33 | + public string StoreId { get; set; } | |
| 34 | + | |
| 35 | + /// <summary> | |
| 36 | + /// 门店名称 | |
| 37 | + /// </summary> | |
| 38 | + public string StoreName { get; set; } | |
| 39 | + | |
| 40 | + /// <summary> | |
| 41 | + /// 总业绩金额 | |
| 42 | + /// </summary> | |
| 43 | + public decimal TotalPerformance { get; set; } | |
| 44 | + | |
| 45 | + /// <summary> | |
| 46 | + /// 订单数量 | |
| 47 | + /// </summary> | |
| 48 | + public int OrderCount { get; set; } | |
| 49 | + | |
| 50 | + /// <summary> | |
| 51 | + /// 创建时间 | |
| 52 | + /// </summary> | |
| 53 | + public DateTime CreateTime { get; set; } | |
| 54 | + } | |
| 55 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Dto/LqStatistics/LqTechPerformanceStatisticsListQueryInput.cs
0 → 100644
| 1 | +using System.ComponentModel.DataAnnotations; | |
| 2 | + | |
| 3 | +namespace NCC.Extend.Entitys.Dto.LqStatistics | |
| 4 | +{ | |
| 5 | + /// <summary> | |
| 6 | + /// 科技部开单业绩统计列表查询输入 | |
| 7 | + /// </summary> | |
| 8 | + public class LqTechPerformanceStatisticsListQueryInput | |
| 9 | + { | |
| 10 | + /// <summary> | |
| 11 | + /// 页码 | |
| 12 | + /// </summary> | |
| 13 | + [Required] | |
| 14 | + public int PageIndex { get; set; } = 1; | |
| 15 | + | |
| 16 | + /// <summary> | |
| 17 | + /// 页大小 | |
| 18 | + /// </summary> | |
| 19 | + [Required] | |
| 20 | + public int PageSize { get; set; } = 20; | |
| 21 | + | |
| 22 | + /// <summary> | |
| 23 | + /// 统计月份 | |
| 24 | + /// </summary> | |
| 25 | + public string StatisticsMonth { get; set; } | |
| 26 | + | |
| 27 | + /// <summary> | |
| 28 | + /// 老师姓名 | |
| 29 | + /// </summary> | |
| 30 | + public string TeacherName { get; set; } | |
| 31 | + | |
| 32 | + /// <summary> | |
| 33 | + /// 门店名称 | |
| 34 | + /// </summary> | |
| 35 | + public string StoreName { get; set; } | |
| 36 | + } | |
| 37 | +} | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend.Entitys/Entity/lq_salary_statistics/LqSalaryStatisticsEntity.cs
| ... | ... | @@ -5,7 +5,7 @@ using SqlSugar; |
| 5 | 5 | namespace NCC.Extend.Entitys.lq_salary_statistics |
| 6 | 6 | { |
| 7 | 7 | /// <summary> |
| 8 | - /// 工资统计表 | |
| 8 | + /// 健康师工资统计表 | |
| 9 | 9 | /// </summary> |
| 10 | 10 | [SugarTable("lq_salary_statistics")] |
| 11 | 11 | [Tenant(ClaimConst.TENANT_ID)] |
| ... | ... | @@ -54,6 +54,12 @@ namespace NCC.Extend.Entitys.lq_salary_statistics |
| 54 | 54 | public string GoldTriangleTeam { get; set; } |
| 55 | 55 | |
| 56 | 56 | /// <summary> |
| 57 | + /// 金三角ID | |
| 58 | + /// </summary> | |
| 59 | + [SugarColumn(ColumnName = "F_GoldTriangleId")] | |
| 60 | + public string GoldTriangleId { get; set; } | |
| 61 | + | |
| 62 | + /// <summary> | |
| 57 | 63 | /// 总业绩 |
| 58 | 64 | /// </summary> |
| 59 | 65 | [SugarColumn(ColumnName = "F_TotalPerformance")] |
| ... | ... | @@ -126,90 +132,6 @@ namespace NCC.Extend.Entitys.lq_salary_statistics |
| 126 | 132 | public decimal UpgradePoint { get; set; } |
| 127 | 133 | |
| 128 | 134 | /// <summary> |
| 129 | - /// 溯源业绩 | |
| 130 | - /// </summary> | |
| 131 | - [SugarColumn(ColumnName = "F_TraceabilityPerformance")] | |
| 132 | - public decimal TraceabilityPerformance { get; set; } | |
| 133 | - | |
| 134 | - /// <summary> | |
| 135 | - /// Cell业绩 | |
| 136 | - /// </summary> | |
| 137 | - [SugarColumn(ColumnName = "F_CellPerformance")] | |
| 138 | - public decimal CellPerformance { get; set; } | |
| 139 | - | |
| 140 | - /// <summary> | |
| 141 | - /// 大项目一部业绩 | |
| 142 | - /// </summary> | |
| 143 | - [SugarColumn(ColumnName = "F_MajorProject1Performance")] | |
| 144 | - public decimal MajorProject1Performance { get; set; } | |
| 145 | - | |
| 146 | - /// <summary> | |
| 147 | - /// 大项目二部业绩 | |
| 148 | - /// </summary> | |
| 149 | - [SugarColumn(ColumnName = "F_MajorProject2Performance")] | |
| 150 | - public decimal MajorProject2Performance { get; set; } | |
| 151 | - | |
| 152 | - /// <summary> | |
| 153 | - /// 当月业绩 | |
| 154 | - /// </summary> | |
| 155 | - [SugarColumn(ColumnName = "F_MonthlyPerformance")] | |
| 156 | - public decimal MonthlyPerformance { get; set; } | |
| 157 | - | |
| 158 | - /// <summary> | |
| 159 | - /// 物业水电 | |
| 160 | - /// </summary> | |
| 161 | - [SugarColumn(ColumnName = "F_PropertyWaterElectricity")] | |
| 162 | - public decimal PropertyWaterElectricity { get; set; } | |
| 163 | - | |
| 164 | - /// <summary> | |
| 165 | - /// 门店支出 | |
| 166 | - /// </summary> | |
| 167 | - [SugarColumn(ColumnName = "F_StoreExpense")] | |
| 168 | - public decimal StoreExpense { get; set; } | |
| 169 | - | |
| 170 | - /// <summary> | |
| 171 | - /// 产品物料 | |
| 172 | - /// </summary> | |
| 173 | - [SugarColumn(ColumnName = "F_ProductMaterial")] | |
| 174 | - public decimal ProductMaterial { get; set; } | |
| 175 | - | |
| 176 | - /// <summary> | |
| 177 | - /// 微雕成本 | |
| 178 | - /// </summary> | |
| 179 | - [SugarColumn(ColumnName = "F_MicroSculptureCost")] | |
| 180 | - public decimal MicroSculptureCost { get; set; } | |
| 181 | - | |
| 182 | - /// <summary> | |
| 183 | - /// 其它合作成本 | |
| 184 | - /// </summary> | |
| 185 | - [SugarColumn(ColumnName = "F_OtherCooperationCost")] | |
| 186 | - public decimal OtherCooperationCost { get; set; } | |
| 187 | - | |
| 188 | - /// <summary> | |
| 189 | - /// 洗毛巾 | |
| 190 | - /// </summary> | |
| 191 | - [SugarColumn(ColumnName = "F_TowelWashing")] | |
| 192 | - public decimal TowelWashing { get; set; } | |
| 193 | - | |
| 194 | - /// <summary> | |
| 195 | - /// 毛利 | |
| 196 | - /// </summary> | |
| 197 | - [SugarColumn(ColumnName = "F_GrossProfit")] | |
| 198 | - public decimal GrossProfit { get; set; } | |
| 199 | - | |
| 200 | - /// <summary> | |
| 201 | - /// 总经理提成额 | |
| 202 | - /// </summary> | |
| 203 | - [SugarColumn(ColumnName = "F_GeneralManagerCommission")] | |
| 204 | - public decimal GeneralManagerCommission { get; set; } | |
| 205 | - | |
| 206 | - /// <summary> | |
| 207 | - /// 经理提成额 | |
| 208 | - /// </summary> | |
| 209 | - [SugarColumn(ColumnName = "F_ManagerCommission")] | |
| 210 | - public decimal ManagerCommission { get; set; } | |
| 211 | - | |
| 212 | - /// <summary> | |
| 213 | 135 | /// 消耗 |
| 214 | 136 | /// </summary> |
| 215 | 137 | [SugarColumn(ColumnName = "F_Consumption")] |
| ... | ... | @@ -270,78 +192,6 @@ namespace NCC.Extend.Entitys.lq_salary_statistics |
| 270 | 192 | public decimal StoreTZoneCommission { get; set; } |
| 271 | 193 | |
| 272 | 194 | /// <summary> |
| 273 | - /// 店助提成 | |
| 274 | - /// </summary> | |
| 275 | - [SugarColumn(ColumnName = "F_AssistantCommission")] | |
| 276 | - public decimal AssistantCommission { get; set; } | |
| 277 | - | |
| 278 | - /// <summary> | |
| 279 | - /// 店助主任提成 | |
| 280 | - /// </summary> | |
| 281 | - [SugarColumn(ColumnName = "F_AssistantDirectorCommission")] | |
| 282 | - public decimal AssistantDirectorCommission { get; set; } | |
| 283 | - | |
| 284 | - /// <summary> | |
| 285 | - /// 主任提成 | |
| 286 | - /// </summary> | |
| 287 | - [SugarColumn(ColumnName = "F_DirectorCommission")] | |
| 288 | - public decimal DirectorCommission { get; set; } | |
| 289 | - | |
| 290 | - /// <summary> | |
| 291 | - /// 店长提成 | |
| 292 | - /// </summary> | |
| 293 | - [SugarColumn(ColumnName = "F_StoreManagerCommission")] | |
| 294 | - public decimal StoreManagerCommission { get; set; } | |
| 295 | - | |
| 296 | - /// <summary> | |
| 297 | - /// 总经理提成 | |
| 298 | - /// </summary> | |
| 299 | - [SugarColumn(ColumnName = "F_GeneralManagerCommissionTotal")] | |
| 300 | - public decimal GeneralManagerCommissionTotal { get; set; } | |
| 301 | - | |
| 302 | - /// <summary> | |
| 303 | - /// 经理提成 | |
| 304 | - /// </summary> | |
| 305 | - [SugarColumn(ColumnName = "F_ManagerCommissionTotal")] | |
| 306 | - public decimal ManagerCommissionTotal { get; set; } | |
| 307 | - | |
| 308 | - /// <summary> | |
| 309 | - /// 业绩提成 | |
| 310 | - /// </summary> | |
| 311 | - [SugarColumn(ColumnName = "F_PerformanceCommission")] | |
| 312 | - public decimal PerformanceCommission { get; set; } | |
| 313 | - | |
| 314 | - /// <summary> | |
| 315 | - /// 消耗提成 | |
| 316 | - /// </summary> | |
| 317 | - [SugarColumn(ColumnName = "F_ConsumptionCommission")] | |
| 318 | - public decimal ConsumptionCommission { get; set; } | |
| 319 | - | |
| 320 | - /// <summary> | |
| 321 | - /// 科技部组长提成 | |
| 322 | - /// </summary> | |
| 323 | - [SugarColumn(ColumnName = "F_TechGroupLeaderCommission")] | |
| 324 | - public decimal TechGroupLeaderCommission { get; set; } | |
| 325 | - | |
| 326 | - /// <summary> | |
| 327 | - /// 溯源提成 | |
| 328 | - /// </summary> | |
| 329 | - [SugarColumn(ColumnName = "F_TraceabilityCommission")] | |
| 330 | - public decimal TraceabilityCommission { get; set; } | |
| 331 | - | |
| 332 | - /// <summary> | |
| 333 | - /// Cell提成 | |
| 334 | - /// </summary> | |
| 335 | - [SugarColumn(ColumnName = "F_CellCommission")] | |
| 336 | - public decimal CellCommission { get; set; } | |
| 337 | - | |
| 338 | - /// <summary> | |
| 339 | - /// 大项目部提成 | |
| 340 | - /// </summary> | |
| 341 | - [SugarColumn(ColumnName = "F_MajorProjectCommission")] | |
| 342 | - public decimal MajorProjectCommission { get; set; } | |
| 343 | - | |
| 344 | - /// <summary> | |
| 345 | 195 | /// 提成合计 |
| 346 | 196 | /// </summary> |
| 347 | 197 | [SugarColumn(ColumnName = "F_TotalCommission")] |
| ... | ... | @@ -354,76 +204,16 @@ namespace NCC.Extend.Entitys.lq_salary_statistics |
| 354 | 204 | public decimal HealthCoachBaseSalary { get; set; } |
| 355 | 205 | |
| 356 | 206 | /// <summary> |
| 357 | - /// 店助底薪 | |
| 358 | - /// </summary> | |
| 359 | - [SugarColumn(ColumnName = "F_AssistantBaseSalary")] | |
| 360 | - public decimal AssistantBaseSalary { get; set; } | |
| 361 | - | |
| 362 | - /// <summary> | |
| 363 | - /// 店长底薪 | |
| 364 | - /// </summary> | |
| 365 | - [SugarColumn(ColumnName = "F_StoreManagerBaseSalary")] | |
| 366 | - public decimal StoreManagerBaseSalary { get; set; } | |
| 367 | - | |
| 368 | - /// <summary> | |
| 369 | - /// 主任底薪 | |
| 370 | - /// </summary> | |
| 371 | - [SugarColumn(ColumnName = "F_DirectorBaseSalary")] | |
| 372 | - public decimal DirectorBaseSalary { get; set; } | |
| 373 | - | |
| 374 | - /// <summary> | |
| 375 | - /// 店助主任底薪 | |
| 376 | - /// </summary> | |
| 377 | - [SugarColumn(ColumnName = "F_AssistantDirectorBaseSalary")] | |
| 378 | - public decimal AssistantDirectorBaseSalary { get; set; } | |
| 379 | - | |
| 380 | - /// <summary> | |
| 381 | - /// 总经理底薪 | |
| 382 | - /// </summary> | |
| 383 | - [SugarColumn(ColumnName = "F_GeneralManagerBaseSalary")] | |
| 384 | - public decimal GeneralManagerBaseSalary { get; set; } | |
| 385 | - | |
| 386 | - /// <summary> | |
| 387 | - /// 经理底薪 | |
| 388 | - /// </summary> | |
| 389 | - [SugarColumn(ColumnName = "F_ManagerBaseSalary")] | |
| 390 | - public decimal ManagerBaseSalary { get; set; } | |
| 391 | - | |
| 392 | - /// <summary> | |
| 393 | - /// 科技部老师底薪 | |
| 394 | - /// </summary> | |
| 395 | - [SugarColumn(ColumnName = "F_TechTeacherBaseSalary")] | |
| 396 | - public decimal TechTeacherBaseSalary { get; set; } | |
| 397 | - | |
| 398 | - /// <summary> | |
| 399 | - /// 大项目部底薪 | |
| 400 | - /// </summary> | |
| 401 | - [SugarColumn(ColumnName = "F_MajorProjectBaseSalary")] | |
| 402 | - public decimal MajorProjectBaseSalary { get; set; } | |
| 403 | - | |
| 404 | - /// <summary> | |
| 405 | - /// 底薪合计 | |
| 406 | - /// </summary> | |
| 407 | - [SugarColumn(ColumnName = "F_TotalBaseSalary")] | |
| 408 | - public decimal TotalBaseSalary { get; set; } | |
| 409 | - | |
| 410 | - /// <summary> | |
| 411 | 207 | /// 手工费 |
| 412 | 208 | /// </summary> |
| 413 | 209 | [SugarColumn(ColumnName = "F_HandworkFee")] |
| 414 | 210 | public decimal HandworkFee { get; set; } |
| 415 | 211 | |
| 416 | 212 | /// <summary> |
| 417 | - /// 人头奖励 | |
| 418 | - /// </summary> | |
| 419 | - [SugarColumn(ColumnName = "F_PersonnelReward")] | |
| 420 | - public decimal PersonnelReward { get; set; } | |
| 421 | - | |
| 422 | - /// <summary> | |
| 423 | - /// 手机管理费 | |
| 213 | + /// 额外手工费 | |
| 424 | 214 | /// </summary> |
| 425 | - [SugarColumn(ColumnName = "F_PhoneManagement")] | |
| 426 | - public decimal PhoneManagement { get; set; } | |
| 215 | + [SugarColumn(ColumnName = "F_OutherHandworkFee")] | |
| 216 | + public decimal OutherHandworkFee { get; set; } | |
| 427 | 217 | |
| 428 | 218 | /// <summary> |
| 429 | 219 | /// 车补 |
| ... | ... | @@ -653,4 +443,4 @@ namespace NCC.Extend.Entitys.lq_salary_statistics |
| 653 | 443 | [SugarColumn(ColumnName = "F_UpdateUser")] |
| 654 | 444 | public string UpdateUser { get; set; } |
| 655 | 445 | } |
| 656 | 446 | -} |
| 447 | +} | |
| 657 | 448 | \ No newline at end of file | ... | ... |
netcore/src/Modularity/Extend/NCC.Extend/LqStatisticsService.cs
| ... | ... | @@ -1668,10 +1668,13 @@ namespace NCC.Extend.LqStatistics |
| 1668 | 1668 | |
| 1669 | 1669 | return new |
| 1670 | 1670 | { |
| 1671 | - Records = result.list, | |
| 1672 | - Total = result.pagination.Total, | |
| 1673 | - PageIndex = input.currentPage, | |
| 1674 | - PageSize = input.pageSize | |
| 1671 | + list = result.list, | |
| 1672 | + pagination = new | |
| 1673 | + { | |
| 1674 | + pageIndex = input.currentPage, | |
| 1675 | + pageSize = input.pageSize, | |
| 1676 | + total = result.pagination.Total | |
| 1677 | + } | |
| 1675 | 1678 | }; |
| 1676 | 1679 | } |
| 1677 | 1680 | catch (Exception ex) |
| ... | ... | @@ -2646,6 +2649,7 @@ namespace NCC.Extend.LqStatistics |
| 2646 | 2649 | EmployeeName = x.EmployeeName, |
| 2647 | 2650 | Position = x.Position, |
| 2648 | 2651 | GoldTriangleTeam = x.GoldTriangleTeam, |
| 2652 | + GoldTriangleId = x.GoldTriangleId, | |
| 2649 | 2653 | TotalPerformance = x.TotalPerformance, |
| 2650 | 2654 | BasePerformance = x.BasePerformance, |
| 2651 | 2655 | CooperationPerformance = x.CooperationPerformance, |
| ... | ... | @@ -2658,20 +2662,6 @@ namespace NCC.Extend.LqStatistics |
| 2658 | 2662 | NewCustomerPoint = x.NewCustomerPoint, |
| 2659 | 2663 | UpgradePerformance = x.UpgradePerformance, |
| 2660 | 2664 | UpgradePoint = x.UpgradePoint, |
| 2661 | - TraceabilityPerformance = x.TraceabilityPerformance, | |
| 2662 | - CellPerformance = x.CellPerformance, | |
| 2663 | - ProjectOnePerformance = x.MajorProject1Performance, | |
| 2664 | - ProjectTwoPerformance = x.MajorProject2Performance, | |
| 2665 | - MonthlyPerformance = x.MonthlyPerformance, | |
| 2666 | - PropertyWaterElectricity = x.PropertyWaterElectricity, | |
| 2667 | - StoreExpense = x.StoreExpense, | |
| 2668 | - ProductMaterial = x.ProductMaterial, | |
| 2669 | - MicroSculptureCost = x.MicroSculptureCost, | |
| 2670 | - OtherCooperationCost = x.OtherCooperationCost, | |
| 2671 | - TowelWashing = x.TowelWashing, | |
| 2672 | - GrossProfit = x.GrossProfit, | |
| 2673 | - GeneralManagerCommission = x.GeneralManagerCommission, | |
| 2674 | - ManagerCommission = x.ManagerCommission, | |
| 2675 | 2665 | Consumption = x.Consumption, |
| 2676 | 2666 | ProjectCount = x.ProjectCount, |
| 2677 | 2667 | AttendanceDays = x.CustomerCount, |
| ... | ... | @@ -2682,32 +2672,10 @@ namespace NCC.Extend.LqStatistics |
| 2682 | 2672 | CooperationPerformanceCommission = x.CooperationPerformanceCommission, |
| 2683 | 2673 | ConsultantCommission = x.ConsultantCommission, |
| 2684 | 2674 | StoreTAreaCommission = x.StoreTZoneCommission, |
| 2685 | - AssistantCommission1 = x.AssistantCommission, | |
| 2686 | - AssistantDirectorCommission = x.AssistantDirectorCommission, | |
| 2687 | - DirectorCommission = x.DirectorCommission, | |
| 2688 | - AssistantCommission2 = x.StoreManagerCommission, | |
| 2689 | - GeneralManagerCommissionAmount = x.GeneralManagerCommissionTotal, | |
| 2690 | - ManagerCommissionAmount = x.ManagerCommissionTotal, | |
| 2691 | - PerformanceCommission = x.PerformanceCommission, | |
| 2692 | - ConsumptionCommission = x.ConsumptionCommission, | |
| 2693 | - TechGroupLeaderCommission = x.TechGroupLeaderCommission, | |
| 2694 | - TraceabilityCommission = x.TraceabilityCommission, | |
| 2695 | - CellCommission = x.CellCommission, | |
| 2696 | - ProjectCommission = x.MajorProjectCommission, | |
| 2697 | 2675 | CommissionTotal = x.TotalCommission, |
| 2698 | 2676 | HealthCoachBaseSalary = x.HealthCoachBaseSalary, |
| 2699 | - AssistantBaseSalary = x.AssistantBaseSalary, | |
| 2700 | - ManagerBaseSalary = x.StoreManagerBaseSalary, | |
| 2701 | - DirectorBaseSalary = x.DirectorBaseSalary, | |
| 2702 | - AssistantDirectorBaseSalary = x.AssistantDirectorBaseSalary, | |
| 2703 | - GeneralManagerBaseSalary = x.GeneralManagerBaseSalary, | |
| 2704 | - ManagerBaseSalaryAmount = x.ManagerBaseSalary, | |
| 2705 | - TechTeacherBaseSalary = x.TechTeacherBaseSalary, | |
| 2706 | - ProjectBaseSalary = x.MajorProjectBaseSalary, | |
| 2707 | - BaseSalaryTotal = x.TotalBaseSalary, | |
| 2708 | 2677 | ManualWork = x.HandworkFee, |
| 2709 | - HeadCountReward = x.PersonnelReward, | |
| 2710 | - PhoneManagement = x.PhoneManagement, | |
| 2678 | + OutherHandworkFee = x.OutherHandworkFee, | |
| 2711 | 2679 | CarAllowance = x.TransportationAllowance, |
| 2712 | 2680 | LessRest = x.LessRest, |
| 2713 | 2681 | FullAttendance = x.FullAttendance, |
| ... | ... | @@ -2769,11 +2737,23 @@ namespace NCC.Extend.LqStatistics |
| 2769 | 2737 | u.F_MDID as StoreId, |
| 2770 | 2738 | COALESCE(md.dm, '') as StoreName, |
| 2771 | 2739 | COALESCE(u.F_GW, '') as Position, |
| 2772 | - COALESCE(jsj.jsj, '') as GoldTriangleTeam | |
| 2740 | + COALESCE(jsj.jsj, '') as GoldTriangleTeam, | |
| 2741 | + COALESCE(jsj.jsj_id, '') as GoldTriangleId | |
| 2773 | 2742 | FROM BASE_USER u |
| 2774 | - LEFT JOIN lq_mdxx md ON u.F_MDID COLLATE utf8mb4_unicode_ci = md.F_Id COLLATE utf8mb4_unicode_ci | |
| 2775 | - LEFT JOIN lq_ycsd_jsj jsj ON u.F_MDID COLLATE utf8mb4_unicode_ci = jsj.md COLLATE utf8mb4_unicode_ci AND jsj.yf = @statisticsMonth | |
| 2776 | - WHERE u.F_EnabledMark = 1 | |
| 2743 | + LEFT JOIN lq_mdxx md ON u.F_MDID COLLATE utf8mb4_general_ci = md.F_Id COLLATE utf8mb4_general_ci | |
| 2744 | + LEFT JOIN ( | |
| 2745 | + SELECT | |
| 2746 | + jsu.user_id, | |
| 2747 | + jsj.jsj, | |
| 2748 | + jsj.F_Id as jsj_id | |
| 2749 | + FROM lq_jinsanjiao_user jsu | |
| 2750 | + INNER JOIN lq_ycsd_jsj jsj ON jsu.jsj_id COLLATE utf8mb4_general_ci = jsj.F_Id COLLATE utf8mb4_general_ci | |
| 2751 | + WHERE jsu.F_Month = @statisticsMonth | |
| 2752 | + AND jsu.status = 'ACTIVE' | |
| 2753 | + AND (jsu.F_DeleteMark IS NULL OR jsu.F_DeleteMark = 0) | |
| 2754 | + AND jsj.yf = @statisticsMonth | |
| 2755 | + ) jsj ON u.F_Id COLLATE utf8mb4_general_ci = jsj.user_id COLLATE utf8mb4_general_ci | |
| 2756 | + WHERE u.F_EnabledMark = 1 AND u.F_GW = '健康师' | |
| 2777 | 2757 | AND (u.F_DeleteMark IS NULL OR u.F_DeleteMark = 0)"; |
| 2778 | 2758 | |
| 2779 | 2759 | var employees = await _db.Ado.SqlQueryAsync<dynamic>(employeesSql, new { statisticsMonth }); |
| ... | ... | @@ -2787,6 +2767,7 @@ namespace NCC.Extend.LqStatistics |
| 2787 | 2767 | EmployeeName = emp.EmployeeName?.ToString() ?? "", |
| 2788 | 2768 | EmployeeId = emp.EmployeeId?.ToString() ?? "", |
| 2789 | 2769 | GoldTriangleTeam = emp.GoldTriangleTeam?.ToString() ?? "", |
| 2770 | + GoldTriangleId = emp.GoldTriangleId?.ToString() ?? "", | |
| 2790 | 2771 | StatisticsMonth = statisticsMonth, |
| 2791 | 2772 | IsLocked = 0, |
| 2792 | 2773 | CreateTime = DateTime.Now, |
| ... | ... | @@ -2855,10 +2836,304 @@ namespace NCC.Extend.LqStatistics |
| 2855 | 2836 | userId = _userManager.UserId |
| 2856 | 2837 | }); |
| 2857 | 2838 | |
| 2839 | + // 从金三角统计表更新队伍业绩 | |
| 2840 | + var teamPerformanceSql = @" | |
| 2841 | + UPDATE lq_salary_statistics s | |
| 2842 | + INNER JOIN lq_statistics_gold_triangle gt | |
| 2843 | + ON s.F_GoldTriangleId COLLATE utf8mb4_unicode_ci = gt.F_GoldTriangleId COLLATE utf8mb4_unicode_ci | |
| 2844 | + AND s.F_StatisticsMonth = gt.F_StatisticsMonth | |
| 2845 | + SET | |
| 2846 | + s.F_TeamPerformance = gt.F_TotalPerformance | |
| 2847 | + WHERE s.F_StatisticsMonth = @statisticsMonth | |
| 2848 | + AND s.F_GoldTriangleId IS NOT NULL | |
| 2849 | + AND s.F_GoldTriangleId != ''"; | |
| 2850 | + | |
| 2851 | + await _db.Ado.ExecuteCommandAsync(teamPerformanceSql, new | |
| 2852 | + { | |
| 2853 | + statisticsMonth, | |
| 2854 | + userId = _userManager.UserId | |
| 2855 | + }); | |
| 2856 | + | |
| 2858 | 2857 | _logger.LogInformation($"从其他统计表更新工资数据完成 - 月份: {statisticsMonth}"); |
| 2859 | 2858 | } |
| 2860 | 2859 | |
| 2861 | 2860 | #endregion |
| 2862 | 2861 | |
| 2862 | + #region 其他统计模块列表查询接口 | |
| 2863 | + | |
| 2864 | + /// <summary> | |
| 2865 | + /// 获取金三角开卡业绩统计列表 | |
| 2866 | + /// </summary> | |
| 2867 | + /// <param name="input">查询参数</param> | |
| 2868 | + /// <returns>分页结果</returns> | |
| 2869 | + [HttpPost("get-gold-triangle-statistics-list")] | |
| 2870 | + public async Task<dynamic> GetGoldTriangleStatisticsList([FromBody] LqGoldTriangleStatisticsListQueryInput input) | |
| 2871 | + { | |
| 2872 | + try | |
| 2873 | + { | |
| 2874 | + var query = _db.Queryable<LqStatisticsGoldTriangleEntity>(); | |
| 2875 | + | |
| 2876 | + // 添加查询条件 | |
| 2877 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StatisticsMonth), x => x.StatisticsMonth == input.StatisticsMonth); | |
| 2878 | + query = query.WhereIF(!string.IsNullOrEmpty(input.GoldTriangleName), x => x.GoldTriangleName.Contains(input.GoldTriangleName)); | |
| 2879 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StoreName), x => x.StoreName.Contains(input.StoreName)); | |
| 2880 | + | |
| 2881 | + // 按创建时间降序排序 | |
| 2882 | + query = query.OrderBy(x => x.CreateTime, OrderByType.Desc); | |
| 2883 | + | |
| 2884 | + // 分页查询并映射到DTO | |
| 2885 | + var result = await query.Select(it => new LqGoldTriangleStatisticsListOutput | |
| 2886 | + { | |
| 2887 | + Id = it.Id, | |
| 2888 | + GoldTriangleId = it.GoldTriangleId, | |
| 2889 | + GoldTriangleName = it.GoldTriangleName, | |
| 2890 | + StatisticsMonth = it.StatisticsMonth, | |
| 2891 | + StoreId = it.StoreId, | |
| 2892 | + StoreName = it.StoreName, | |
| 2893 | + OrderCount = it.OrderCount, | |
| 2894 | + TotalPerformance = it.TotalPerformance, | |
| 2895 | + FirstOrderDate = it.FirstOrderDate, | |
| 2896 | + LastOrderDate = it.LastOrderDate, | |
| 2897 | + CreateTime = it.CreateTime | |
| 2898 | + }).ToPagedListAsync(input.PageIndex, input.PageSize); | |
| 2899 | + | |
| 2900 | + return new | |
| 2901 | + { | |
| 2902 | + list = result.list, | |
| 2903 | + pagination = new | |
| 2904 | + { | |
| 2905 | + pageIndex = input.PageIndex, | |
| 2906 | + pageSize = input.PageSize, | |
| 2907 | + total = result.pagination.Total | |
| 2908 | + } | |
| 2909 | + }; | |
| 2910 | + } | |
| 2911 | + catch (Exception ex) | |
| 2912 | + { | |
| 2913 | + _logger.LogError(ex, "查询金三角开卡业绩统计列表失败"); | |
| 2914 | + throw NCCException.Oh($"查询金三角开卡业绩统计列表失败: {ex.Message}"); | |
| 2915 | + } | |
| 2916 | + } | |
| 2917 | + | |
| 2918 | + /// <summary> | |
| 2919 | + /// 获取科技部开单业绩统计列表 | |
| 2920 | + /// </summary> | |
| 2921 | + /// <param name="input">查询参数</param> | |
| 2922 | + /// <returns>分页结果</returns> | |
| 2923 | + [HttpPost("get-tech-performance-statistics-list")] | |
| 2924 | + public async Task<dynamic> GetTechPerformanceStatisticsList([FromBody] LqTechPerformanceStatisticsListQueryInput input) | |
| 2925 | + { | |
| 2926 | + try | |
| 2927 | + { | |
| 2928 | + var query = _db.Queryable<LqStatisticsTechPerformanceEntity>(); | |
| 2929 | + | |
| 2930 | + // 添加查询条件 | |
| 2931 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StatisticsMonth), x => x.StatisticsMonth == input.StatisticsMonth); | |
| 2932 | + query = query.WhereIF(!string.IsNullOrEmpty(input.TeacherName), x => x.TeacherName.Contains(input.TeacherName)); | |
| 2933 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StoreName), x => x.StoreName.Contains(input.StoreName)); | |
| 2934 | + | |
| 2935 | + // 按创建时间降序排序 | |
| 2936 | + query = query.OrderBy(x => x.CreateTime, OrderByType.Desc); | |
| 2937 | + | |
| 2938 | + // 分页查询并映射到DTO | |
| 2939 | + var result = await query.Select(it => new LqTechPerformanceStatisticsListOutput | |
| 2940 | + { | |
| 2941 | + Id = it.Id, | |
| 2942 | + StatisticsMonth = it.StatisticsMonth, | |
| 2943 | + TeacherId = it.TeacherId, | |
| 2944 | + TeacherName = it.TeacherName, | |
| 2945 | + StoreId = it.StoreId, | |
| 2946 | + StoreName = it.StoreName, | |
| 2947 | + TotalPerformance = it.TotalPerformance, | |
| 2948 | + OrderCount = it.OrderCount, | |
| 2949 | + CreateTime = it.CreateTime | |
| 2950 | + }).ToPagedListAsync(input.PageIndex, input.PageSize); | |
| 2951 | + | |
| 2952 | + return new | |
| 2953 | + { | |
| 2954 | + list = result.list, | |
| 2955 | + pagination = new | |
| 2956 | + { | |
| 2957 | + pageIndex = input.PageIndex, | |
| 2958 | + pageSize = input.PageSize, | |
| 2959 | + total = result.pagination.Total | |
| 2960 | + } | |
| 2961 | + }; | |
| 2962 | + } | |
| 2963 | + catch (Exception ex) | |
| 2964 | + { | |
| 2965 | + _logger.LogError(ex, "查询科技部开单业绩统计列表失败"); | |
| 2966 | + throw NCCException.Oh($"查询科技部开单业绩统计列表失败: {ex.Message}"); | |
| 2967 | + } | |
| 2968 | + } | |
| 2969 | + | |
| 2970 | + /// <summary> | |
| 2971 | + /// 获取门店耗卡业绩统计列表 | |
| 2972 | + /// </summary> | |
| 2973 | + /// <param name="input">查询参数</param> | |
| 2974 | + /// <returns>分页结果</returns> | |
| 2975 | + [HttpPost("get-store-consume-performance-statistics-list")] | |
| 2976 | + public async Task<dynamic> GetStoreConsumePerformanceStatisticsList([FromBody] LqStoreConsumePerformanceStatisticsListQueryInput input) | |
| 2977 | + { | |
| 2978 | + try | |
| 2979 | + { | |
| 2980 | + var query = _db.Queryable<LqStatisticsStoreConsumePerformanceEntity>(); | |
| 2981 | + | |
| 2982 | + // 添加查询条件 | |
| 2983 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StatisticsMonth), x => x.StatisticsMonth == input.StatisticsMonth); | |
| 2984 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StoreName), x => x.StoreName.Contains(input.StoreName)); | |
| 2985 | + | |
| 2986 | + // 按创建时间降序排序 | |
| 2987 | + query = query.OrderBy(x => x.CreateTime, OrderByType.Desc); | |
| 2988 | + | |
| 2989 | + // 分页查询并映射到DTO | |
| 2990 | + var pagedResult = await query.ToPagedListAsync(input.PageIndex, input.PageSize); | |
| 2991 | + | |
| 2992 | + var outputList = pagedResult.list.Select(it => new LqStoreConsumePerformanceStatisticsListOutput | |
| 2993 | + { | |
| 2994 | + Id = it.Id, | |
| 2995 | + StatisticsMonth = it.StatisticsMonth, | |
| 2996 | + StoreId = it.StoreId, | |
| 2997 | + StoreName = it.StoreName, | |
| 2998 | + TotalPerformance = it.ConsumePerformance, // 使用ConsumePerformance作为总业绩 | |
| 2999 | + ConsumePerformance = it.ConsumePerformance, | |
| 3000 | + OrderCount = (int)it.ConsumeQuantity, // 使用ConsumeQuantity作为订单数量 | |
| 3001 | + IsNewStore = false, // 暂时设为false,因为Entity中没有这个字段 | |
| 3002 | + CreateTime = it.CreateTime.HasValue ? it.CreateTime.Value : DateTime.Now | |
| 3003 | + }).ToList(); | |
| 3004 | + | |
| 3005 | + return new | |
| 3006 | + { | |
| 3007 | + list = outputList, | |
| 3008 | + pagination = new | |
| 3009 | + { | |
| 3010 | + pageIndex = input.PageIndex, | |
| 3011 | + pageSize = input.PageSize, | |
| 3012 | + total = pagedResult.pagination.Total | |
| 3013 | + } | |
| 3014 | + }; | |
| 3015 | + } | |
| 3016 | + catch (Exception ex) | |
| 3017 | + { | |
| 3018 | + _logger.LogError(ex, "查询门店耗卡业绩统计列表失败"); | |
| 3019 | + throw NCCException.Oh($"查询门店耗卡业绩统计列表失败: {ex.Message}"); | |
| 3020 | + } | |
| 3021 | + } | |
| 3022 | + | |
| 3023 | + /// <summary> | |
| 3024 | + /// 获取个人消耗业绩统计列表 | |
| 3025 | + /// </summary> | |
| 3026 | + /// <param name="input">查询参数</param> | |
| 3027 | + /// <returns>分页结果</returns> | |
| 3028 | + [HttpPost("get-department-consume-performance-statistics-list")] | |
| 3029 | + public async Task<dynamic> GetDepartmentConsumePerformanceStatisticsList([FromBody] LqDepartmentConsumePerformanceStatisticsListQueryInput input) | |
| 3030 | + { | |
| 3031 | + try | |
| 3032 | + { | |
| 3033 | + var query = _db.Queryable<LqStatisticsDepartmentConsumePerformanceEntity>(); | |
| 3034 | + | |
| 3035 | + // 添加查询条件 | |
| 3036 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StatisticsMonth), x => x.StatisticsMonth == input.StatisticsMonth); | |
| 3037 | + query = query.WhereIF(!string.IsNullOrEmpty(input.EmployeeName), x => x.UserName.Contains(input.EmployeeName)); | |
| 3038 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StoreName), x => x.StoreName.Contains(input.StoreName)); | |
| 3039 | + query = query.WhereIF(!string.IsNullOrEmpty(input.Position), x => x.DepartmentType.Contains(input.Position)); | |
| 3040 | + | |
| 3041 | + // 按创建时间降序排序 | |
| 3042 | + query = query.OrderBy(x => x.CreateTime, OrderByType.Desc); | |
| 3043 | + | |
| 3044 | + // 分页查询并映射到DTO | |
| 3045 | + var pagedResult = await query.ToPagedListAsync(input.PageIndex, input.PageSize); | |
| 3046 | + | |
| 3047 | + var outputList = pagedResult.list.Select(it => new LqDepartmentConsumePerformanceStatisticsListOutput | |
| 3048 | + { | |
| 3049 | + Id = it.Id, | |
| 3050 | + StatisticsMonth = it.StatisticsMonth, | |
| 3051 | + EmployeeId = it.UserId, | |
| 3052 | + EmployeeName = it.UserName, | |
| 3053 | + StoreId = it.StoreId, | |
| 3054 | + StoreName = it.StoreName, | |
| 3055 | + Position = it.DepartmentType, | |
| 3056 | + TotalPerformance = it.ConsumePerformance, // 使用ConsumePerformance作为总业绩 | |
| 3057 | + ConsumePerformance = it.ConsumePerformance, | |
| 3058 | + OrderCount = (int)it.ConsumeQuantity, // 使用ConsumeQuantity作为订单数量 | |
| 3059 | + CreateTime = it.CreateTime.HasValue ? it.CreateTime.Value : DateTime.Now | |
| 3060 | + }).ToList(); | |
| 3061 | + | |
| 3062 | + return new | |
| 3063 | + { | |
| 3064 | + list = outputList, | |
| 3065 | + pagination = new | |
| 3066 | + { | |
| 3067 | + pageIndex = input.PageIndex, | |
| 3068 | + pageSize = input.PageSize, | |
| 3069 | + total = pagedResult.pagination.Total | |
| 3070 | + } | |
| 3071 | + }; | |
| 3072 | + } | |
| 3073 | + catch (Exception ex) | |
| 3074 | + { | |
| 3075 | + _logger.LogError(ex, "查询个人消耗业绩统计列表失败"); | |
| 3076 | + throw NCCException.Oh($"查询个人消耗业绩统计列表失败: {ex.Message}"); | |
| 3077 | + } | |
| 3078 | + } | |
| 3079 | + | |
| 3080 | + /// <summary> | |
| 3081 | + /// 获取门店总业绩统计列表 | |
| 3082 | + /// </summary> | |
| 3083 | + /// <param name="input">查询参数</param> | |
| 3084 | + /// <returns>分页结果</returns> | |
| 3085 | + [HttpPost("get-store-total-performance-statistics-list")] | |
| 3086 | + public async Task<dynamic> GetStoreTotalPerformanceStatisticsList([FromBody] LqStoreTotalPerformanceStatisticsListQueryInput input) | |
| 3087 | + { | |
| 3088 | + try | |
| 3089 | + { | |
| 3090 | + var query = _db.Queryable<LqStatisticsStoreTotalPerformanceEntity>(); | |
| 3091 | + | |
| 3092 | + // 添加查询条件 | |
| 3093 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StatisticsMonth), x => x.StatisticsMonth == input.StatisticsMonth); | |
| 3094 | + query = query.WhereIF(!string.IsNullOrEmpty(input.StoreName), x => x.StoreName.Contains(input.StoreName)); | |
| 3095 | + | |
| 3096 | + // 按创建时间降序排序 | |
| 3097 | + query = query.OrderBy(x => x.CreateTime, OrderByType.Desc); | |
| 3098 | + | |
| 3099 | + // 分页查询并映射到DTO | |
| 3100 | + var pagedResult = await query.ToPagedListAsync(input.PageIndex, input.PageSize); | |
| 3101 | + | |
| 3102 | + var outputList = pagedResult.list.Select(it => new LqStoreTotalPerformanceStatisticsListOutput | |
| 3103 | + { | |
| 3104 | + Id = it.Id, | |
| 3105 | + StatisticsMonth = it.StatisticsMonth, | |
| 3106 | + StoreId = it.StoreId, | |
| 3107 | + StoreName = it.StoreName, | |
| 3108 | + TotalPerformance = it.TotalPerformance, | |
| 3109 | + DebtAmount = it.DebtAmount, | |
| 3110 | + TotalOrderPerformance = it.TotalOrderPerformance, | |
| 3111 | + StorageDeductionAmount = it.StorageDeductionAmount, | |
| 3112 | + ItemQuantity = it.ItemQuantity, | |
| 3113 | + FirstOrderCount = it.FirstOrderCount, | |
| 3114 | + UpgradeOrderCount = it.UpgradeOrderCount, | |
| 3115 | + CreateTime = it.CreateTime.HasValue ? it.CreateTime.Value : DateTime.Now | |
| 3116 | + }).ToList(); | |
| 3117 | + | |
| 3118 | + return new | |
| 3119 | + { | |
| 3120 | + list = outputList, | |
| 3121 | + pagination = new | |
| 3122 | + { | |
| 3123 | + pageIndex = input.PageIndex, | |
| 3124 | + pageSize = input.PageSize, | |
| 3125 | + total = pagedResult.pagination.Total | |
| 3126 | + } | |
| 3127 | + }; | |
| 3128 | + } | |
| 3129 | + catch (Exception ex) | |
| 3130 | + { | |
| 3131 | + _logger.LogError(ex, "查询门店总业绩统计列表失败"); | |
| 3132 | + throw NCCException.Oh($"查询门店总业绩统计列表失败: {ex.Message}"); | |
| 3133 | + } | |
| 3134 | + } | |
| 3135 | + | |
| 3136 | + #endregion | |
| 3137 | + | |
| 2863 | 3138 | } |
| 2864 | 3139 | } | ... | ... |
参考资料/工资(全字段).xlsx
0 → 100644
No preview for this file type
参考资料/工资(全字段)_副本.xlsx
0 → 100644
No preview for this file type