imeik-bizui 2.8.7 → 2.8.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -117,3 +117,16 @@ export function getPersonBudgetPerformancePage(data) {
117
117
  data
118
118
  })
119
119
  }
120
+
121
+ /**
122
+ * 个人预算-预算调整明细独立分页
123
+ * POST /mms/admin/custom/getPersonBudgetAdjustPage
124
+ * 实时:costBearEmployeeNo(+ budgetDate);查看已保存:applyNumber(走快照)
125
+ */
126
+ export function getPersonBudgetAdjustPage(data) {
127
+ return request({
128
+ url: '/mms/admin/custom/getPersonBudgetAdjustPage',
129
+ method: 'post',
130
+ data
131
+ })
132
+ }
@@ -74,10 +74,14 @@ bizui: scene 选接口 → Dashboard 拉数 → Overview / Detail
74
74
 
75
75
  | 域 | scene | 接口 |
76
76
  | --- | --- | --- |
77
- | 物资 | `supplies` | `mms.getPersonBudgetOverview` / `UsagePage` / `PerformancePage` |
77
+ | 物资 | `supplies` | `mms.getPersonBudgetOverview` / `UsagePage` / `PerformancePage` / `AdjustPage` |
78
78
  | 会议 | `meeting` | `meeting` `personBudget/overview\|usagePage\|performancePage` |
79
79
  | 申请中心 | `apply` / `applyCenter` | `applycenter` `openApi/personBudget/overview\|usagePage\|performancePage` |
80
80
 
81
+ **预算调整明细**(`getPersonBudgetAdjustPage`)仅物资域提供(其余域接口待接入),与「使用明细」「业绩明细」并排为三列(不再整行独占);只展示单号 / 金额(元)/ 日期三列,金额为千分位 + 两位小数(单位由表头承担,正数补 `+`、负数保留 `-`),日期统一走 `formatDateOnly`(只到年月日,与另两表一致)。表底合计当前为占位值(`0.00`),后端返回 `data.totalAmount` 后自动生效。首屏返回空列表时整块隐藏,退化为原有的「使用明细 + 业绩明细」双表布局,弹窗宽度也随之从 1560(1360 + 200)回到 1360。
82
+
83
+ **列宽与自适应**:三表并排时单表宽度有限,各列统一用 `min-width`(使用明细含申请人列,合计约 454),并监听栅格宽度变化后调用 `el-table.doLayout()` 重排——弹窗宽度随表数变化(1360 ↔ 1560)或被视口夹住时,不会残留旧列宽、不会出现多余的横向滚动条。
84
+
81
85
  ---
82
86
 
83
87
  ## 五、业务侧薄封装示例
@@ -24,6 +24,7 @@
24
24
  :request-payload="requestPayload"
25
25
  :fetch-usage-page="fetchUsagePage"
26
26
  :fetch-performance-page="fetchPerformancePage"
27
+ :fetch-adjust-page="fetchAdjustPage"
27
28
  :tableEmptyText="tableEmptyText"
28
29
  @collapse="collapseInline"
29
30
  />
@@ -33,6 +34,7 @@
33
34
  :request-payload="requestPayload"
34
35
  :fetch-usage-page="fetchUsagePage"
35
36
  :fetch-performance-page="fetchPerformancePage"
37
+ :fetch-adjust-page="fetchAdjustPage"
36
38
  />
37
39
  </div>
38
40
  </template>
@@ -123,6 +125,11 @@ export default {
123
125
  type: Function,
124
126
  default: null
125
127
  },
128
+ /** 预算调整明细分页;为空时明细面板不展示该表(非物资域无此接口) */
129
+ fetchAdjustPage: {
130
+ type: Function,
131
+ default: null
132
+ },
126
133
  /** true 时不调接口,展示演示概述(配置态) */
127
134
  useDemo: {
128
135
  type: Boolean,
@@ -22,6 +22,8 @@
22
22
  :request-payload="requestPayload"
23
23
  :fetch-usage-page="fetchUsagePage"
24
24
  :fetch-performance-page="fetchPerformancePage"
25
+ :fetch-adjust-page="fetchAdjustPage"
26
+ @adjust-visible-change="onAdjustVisibleChange"
25
27
  />
26
28
  </ImDialog>
27
29
  </template>
@@ -29,6 +31,11 @@
29
31
  <script>
30
32
  import PersonBudgetDetailPanel from './PersonBudgetDetailPanel.vue'
31
33
 
34
+ /** 弹窗基准最大宽度 */
35
+ const DETAIL_MAX_WIDTH = 1360
36
+ /** 出现第三张表(预算调整明细)时的加宽量 */
37
+ const DETAIL_TRIPLE_EXTRA = 200
38
+
32
39
  export default {
33
40
  name: 'PersonBudgetDetailDialog',
34
41
  components: {
@@ -39,11 +46,15 @@ export default {
39
46
  overview: { type: Object, default: null },
40
47
  requestPayload: { type: Object, default: null },
41
48
  fetchUsagePage: { type: Function, required: true },
42
- fetchPerformancePage: { type: Function, required: true }
49
+ fetchPerformancePage: { type: Function, required: true },
50
+ /** 预算调整明细;无此接口的场景传 null,面板会整块隐藏 */
51
+ fetchAdjustPage: { type: Function, default: null }
43
52
  },
44
53
  data() {
45
54
  return {
46
- viewportWidth: typeof window !== 'undefined' ? window.innerWidth : 1360
55
+ viewportWidth: typeof window !== 'undefined' ? window.innerWidth : 1360,
56
+ /** 面板出现「预算调整明细」→ 三表,弹窗加宽 */
57
+ hasAdjust: false
47
58
  }
48
59
  },
49
60
  computed: {
@@ -57,7 +68,15 @@ export default {
57
68
  },
58
69
  dialogWidth() {
59
70
  const w = this.viewportWidth || 1360
60
- return `${Math.min(1360, Math.max(w - 48, 720))}px`
71
+ // 三表并排时 +200;两表保持原宽度
72
+ const maxWidth = DETAIL_MAX_WIDTH + (this.hasAdjust ? DETAIL_TRIPLE_EXTRA : 0)
73
+ return `${Math.min(maxWidth, Math.max(w - 48, 720))}px`
74
+ }
75
+ },
76
+ watch: {
77
+ visible(val) {
78
+ // 关闭后复位,下次打开按实际表数重新计算
79
+ if (!val) this.hasAdjust = false
61
80
  }
62
81
  },
63
82
  mounted() {
@@ -72,6 +91,10 @@ export default {
72
91
  methods: {
73
92
  onClosed() {
74
93
  this.$emit('update:visible', false)
94
+ },
95
+ /** 只认「有调整明细」,避免面板 bootstrap 重置时来回抖动 */
96
+ onAdjustVisibleChange(visible) {
97
+ if (visible) this.hasAdjust = true
75
98
  }
76
99
  }
77
100
  }