大屏样式完成
This commit is contained in:
		| @@ -192,6 +192,19 @@ export default { | ||||
|             const item = tableData[k.substring(1) || 0] || {} | ||||
|             item[prop] = v | ||||
|             tableData[k.substring(1) || 0] = item | ||||
|           }else if (k != columnProp) { | ||||
|             const index = columns.findIndex(e => k == e) | ||||
|             if (index > -1) { | ||||
|               const item = tableData[index] || {} | ||||
|               item[prop] = v | ||||
|               tableData[index] = item | ||||
|             } else { | ||||
|               columns.push(k) | ||||
|               const newIndex = columns.length - 1 | ||||
|               const item = tableData[newIndex] || {} | ||||
|               item[prop] = v | ||||
|               tableData[newIndex] = item | ||||
|             } | ||||
|           } | ||||
|         }) | ||||
|       }) | ||||
|   | ||||
| @@ -4,11 +4,11 @@ | ||||
|       <template v-if="$slots.title" #title> | ||||
|         <slot name="title"/> | ||||
|       </template> | ||||
|       <div :style="{padding}"> | ||||
|       <div :style="{padding}" class="content"> | ||||
|         <slot/> | ||||
|       </div> | ||||
|     </component> | ||||
|     <div v-else :style="{padding}"> | ||||
|     <div v-else :style="{padding}" class="content"> | ||||
|       <slot style="width: 100%; height: 100%;"/> | ||||
|     </div> | ||||
|   </section> | ||||
| @@ -74,5 +74,9 @@ export default { | ||||
|   * { | ||||
|     box-sizing: border-box; | ||||
|   } | ||||
|  | ||||
|   .content { | ||||
|     height: 100%; | ||||
|   } | ||||
| } | ||||
| </style> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user