Pārlūkot izejas kodu

调整运营会议

Zimo 6 dienas atpakaļ
vecāks
revīzija
e6662595f7

+ 43 - 0
src/views/pms/operation-meeting/components/operation-meeting-content.vue

@@ -206,6 +206,17 @@ const getMeetingTableCellStyle: any = ({
   return undefined
 }
 
+const getMeetingTableRowStyle = (): CSSProperties => ({
+  height: 'auto',
+  minHeight: '40px'
+})
+
+const getMeetingTableCellClassName = ({ column }: MeetingTableCellStyleProps) => {
+  const property = column.property as keyof DetailItem | undefined
+
+  return property ? 'meeting-table__cell' : ''
+}
+
 const visible = ref(false)
 </script>
 
@@ -315,6 +326,8 @@ const visible = ref(false)
           align="left"
           :show-overflow-tooltip="false"
           :cell-style="getMeetingTableCellStyle"
+          :row-style="getMeetingTableRowStyle"
+          :cell-class-name="getMeetingTableCellClassName"
         >
           <zm-table-column min-width="8%" align="center" label="项目名称" prop="projectName" />
           <zm-table-column min-width="27%" label="本期生产运行情况">
@@ -622,6 +635,36 @@ const visible = ref(false)
       text-align: center;
     }
   }
+
+  :deep(.el-table__body .el-table__cell) {
+    height: auto;
+    padding-top: 7px;
+    padding-bottom: 7px;
+    vertical-align: middle;
+
+    .cell {
+      line-height: 1.5;
+      word-break: break-word;
+      white-space: pre-wrap;
+      overflow-wrap: anywhere;
+    }
+  }
+
+  :deep(.el-table__body .el-table__row) {
+    height: auto;
+  }
+
+  :deep(.el-table__body .el-table__row > .el-table__cell) {
+    min-height: 40px;
+  }
+
+  :deep(.meeting-table__cell) {
+    .cell {
+      word-break: break-word;
+      white-space: pre-wrap;
+      overflow-wrap: anywhere;
+    }
+  }
 }
 
 .meeting-table__actions {

+ 81 - 7
src/views/pms/operation-meeting/summary-form.vue

@@ -206,22 +206,24 @@ const parseMeetingSeries = (value: unknown) => {
   return matched ? Number(matched[0]) : undefined
 }
 
+const normalizeTextValue = (value: unknown) => String(value ?? '').replace(/\\r\\n|\\n/g, '\n')
+
 const normalizeDetailItem = (data?: Record<string, unknown>): DetailItem => ({
   raw: data || {},
-  projectName: String(data?.projectName || ''),
+  projectName: normalizeTextValue(data?.projectName),
   currentRevenue: parseNumberValue(data?.currentRevenue),
   cumulativeRevenue: parseNumberValue(data?.cumulativeRevenue),
   currentOnAccount: parseNumberValue(data?.currentOnAccount),
   cumulativeOnAccount: parseNumberValue(data?.cumulativeOnAccount),
   currentPayment: parseNumberValue(data?.currentPayment),
   cumulativePayment: parseNumberValue(data?.cumulativePayment),
-  plannedWorkload: String(data?.plannedWorkload || ''),
-  actualCompletion: String(data?.actualCompletion || ''),
+  plannedWorkload: normalizeTextValue(data?.plannedWorkload),
+  actualCompletion: normalizeTextValue(data?.actualCompletion),
   equipmentUtilizationRate: parseNumberValue(data?.equipmentUtilizationRate),
-  keyWorkCompletion: String(data?.keyWorkCompletion || ''),
-  problemsAnalysis: String(data?.problemsAnalysis || ''),
-  nextPlannedWorkload: String(data?.nextPlannedWorkload || ''),
-  priorityTasks: String(data?.priorityTasks || '')
+  keyWorkCompletion: normalizeTextValue(data?.keyWorkCompletion),
+  problemsAnalysis: normalizeTextValue(data?.problemsAnalysis),
+  nextPlannedWorkload: normalizeTextValue(data?.nextPlannedWorkload),
+  priorityTasks: normalizeTextValue(data?.priorityTasks)
 })
 
 const normalizeSummaryMeeting = (
@@ -314,6 +316,16 @@ const currentSummaryScopeName = computed(
     '全部公司'
 )
 
+const currentSummarySupport = computed(() => {
+  if (!filterForm.companyFilterValue) return ''
+
+  return (
+    summaryMeetings.value.find(
+      (item, index) => getCompanyFilterValue(item.meeting, index) === filterForm.companyFilterValue
+    )?.meeting.support || ''
+  )
+})
+
 const formatSummaryNumber = (value: number) =>
   value.toLocaleString('zh-CN', {
     maximumFractionDigits: 2,
@@ -372,6 +384,17 @@ const getMeetingTableCellStyle: any = ({
   return undefined
 }
 
+const getMeetingTableRowStyle = (): CSSProperties => ({
+  height: 'auto',
+  minHeight: '40px'
+})
+
+const getMeetingTableCellClassName = ({ column }: MeetingTableCellStyleProps) => {
+  const property = column.property as keyof DetailItem | undefined
+
+  return property ? 'meeting-table__cell' : ''
+}
+
 const resetForm = () => {
   summaryMeetings.value = []
   filterForm.companyFilterValue = ''
@@ -539,6 +562,8 @@ watch(
                 align="left"
                 :show-overflow-tooltip="false"
                 :cell-style="getMeetingTableCellStyle"
+                :row-style="getMeetingTableRowStyle"
+                :cell-class-name="getMeetingTableCellClassName"
               >
                 <zm-table-column
                   min-width="6%"
@@ -587,6 +612,15 @@ watch(
               </ZmTable>
             </div>
 
+            <section v-if="currentSummarySupport" class="meeting-support-panel">
+              <el-form-item
+                label="其他重点事项及需要集团协调事项"
+                class="meeting-support-panel__item"
+              >
+                <el-input :model-value="currentSummarySupport" type="textarea" :rows="4" disabled />
+              </el-form-item>
+            </section>
+
             <div v-loading="loading" class="meeting-detail-card-view">
               <template v-if="filteredDetailRows.length">
                 <article
@@ -825,6 +859,16 @@ watch(
   border-top: 1px solid var(--el-border-color-lighter);
 }
 
+.meeting-support-panel {
+  padding-top: 12px;
+  margin-top: 12px;
+  border-top: 1px solid var(--el-border-color-lighter);
+}
+
+.meeting-support-panel__item {
+  margin-bottom: 0;
+}
+
 .meeting-detail-panel__header {
   display: flex;
   align-items: center;
@@ -854,6 +898,36 @@ watch(
       text-align: center;
     }
   }
+
+  :deep(.el-table__body .el-table__cell) {
+    height: auto;
+    padding-top: 7px;
+    padding-bottom: 7px;
+    vertical-align: middle;
+
+    .cell {
+      line-height: 1.5;
+      word-break: break-word;
+      white-space: pre-wrap;
+      overflow-wrap: anywhere;
+    }
+  }
+
+  :deep(.el-table__body .el-table__row) {
+    height: auto;
+  }
+
+  :deep(.el-table__body .el-table__row > .el-table__cell) {
+    min-height: 40px;
+  }
+
+  :deep(.meeting-table__cell) {
+    .cell {
+      word-break: break-word;
+      white-space: pre-wrap;
+      overflow-wrap: anywhere;
+    }
+  }
 }
 
 .meeting-table__actions {