fix(frontend): knoppen ownLearningContent pagina bovenaan
This commit is contained in:
		
							parent
							
								
									f6c2f71edb
								
							
						
					
					
						commit
						4d20e223e5
					
				
					 1 changed files with 50 additions and 28 deletions
				
			
		|  | @ -104,23 +104,17 @@ | ||||||
| </script> | </script> | ||||||
| 
 | 
 | ||||||
| <template> | <template> | ||||||
|     <v-card :title="props.selectedLearningPath ? t('editLearningPath') : t('newLearningPath')"> |     <v-card> | ||||||
|         <template v-slot:text> |         <template v-slot:title> | ||||||
|             <json-editor-vue v-model="learningPath"></json-editor-vue> |             <div class="title-container"> | ||||||
|             <v-alert |                 <span class="title">{{ props.selectedLearningPath ? t('editLearningPath') : t('newLearningPath') }}</span> | ||||||
|                 v-if="postError || putError || deleteError || isIdModified" |                 <span class="actions"> | ||||||
|                 icon="mdi mdi-alert-circle" |  | ||||||
|                 type="error" |  | ||||||
|                 :title="t('error')" |  | ||||||
|                 :text="getErrorMessage()!" |  | ||||||
|             ></v-alert> |  | ||||||
|         </template> |  | ||||||
|         <template v-slot:actions> |  | ||||||
|                     <v-btn |                     <v-btn | ||||||
|                         @click="uploadLearningPath" |                         @click="uploadLearningPath" | ||||||
|                         prependIcon="mdi mdi-check" |                         prependIcon="mdi mdi-check" | ||||||
|                         :loading="isPostPending || isPutPending" |                         :loading="isPostPending || isPutPending" | ||||||
|                         :disabled="parsedLearningPath.hruid === DEFAULT_LEARNING_PATH.hruid || isIdModified" |                         :disabled="parsedLearningPath.hruid === DEFAULT_LEARNING_PATH.hruid || isIdModified" | ||||||
|  |                         variant="text" | ||||||
|                     > |                     > | ||||||
|                         {{ props.selectedLearningPath ? t("saveChanges") : t("create") }} |                         {{ props.selectedLearningPath ? t("saveChanges") : t("create") }} | ||||||
|                     </v-btn> |                     </v-btn> | ||||||
|  | @ -131,17 +125,45 @@ | ||||||
|                         color="red" |                         color="red" | ||||||
|                         prependIcon="mdi mdi-delete" |                         prependIcon="mdi mdi-delete" | ||||||
|                         :confirmQueryText="t('learningPathDeleteQuery')" |                         :confirmQueryText="t('learningPathDeleteQuery')" | ||||||
|  |                         variant="text" | ||||||
|                     /> |                     /> | ||||||
|                     <v-btn |                     <v-btn | ||||||
|                         :href="`/learningPath/${props.selectedLearningPath?.hruid}/${props.selectedLearningPath?.language}/start`" |                         :href="`/learningPath/${props.selectedLearningPath?.hruid}/${props.selectedLearningPath?.language}/start`" | ||||||
|                         target="_blank" |                         target="_blank" | ||||||
|                         prepend-icon="mdi mdi-open-in-new" |                         prepend-icon="mdi mdi-open-in-new" | ||||||
|                         :disabled="!props.selectedLearningPath" |                         :disabled="!props.selectedLearningPath" | ||||||
|  |                         variant="text" | ||||||
|                     > |                     > | ||||||
|                         {{ t("open") }} |                         {{ t("open") }} | ||||||
|                     </v-btn> |                     </v-btn> | ||||||
|  |                 </span> | ||||||
|  |             </div> | ||||||
|  |         </template> | ||||||
|  |         <template v-slot:text> | ||||||
|  |             <json-editor-vue v-model="learningPath"></json-editor-vue> | ||||||
|  |             <v-alert | ||||||
|  |                 v-if="postError || putError || deleteError || isIdModified" | ||||||
|  |                 icon="mdi mdi-alert-circle" | ||||||
|  |                 type="error" | ||||||
|  |                 :title="t('error')" | ||||||
|  |                 :text="getErrorMessage()!" | ||||||
|  |             ></v-alert> | ||||||
|         </template> |         </template> | ||||||
|     </v-card> |     </v-card> | ||||||
| </template> | </template> | ||||||
| 
 | 
 | ||||||
| <style scoped></style> | <style scoped> | ||||||
|  |     .title-container { | ||||||
|  |         display: flex; | ||||||
|  |         flex-direction: row; | ||||||
|  |         flex-wrap: wrap; | ||||||
|  |     } | ||||||
|  |     .title { | ||||||
|  |         flex: 1; | ||||||
|  |     } | ||||||
|  |     .actions { | ||||||
|  |         display: flex; | ||||||
|  |         flex-wrap: wrap; | ||||||
|  |         gap: 10px; | ||||||
|  |     } | ||||||
|  | </style> | ||||||
|  |  | ||||||
		Reference in a new issue
	
	 Gerald Schmittinger
						Gerald Schmittinger