refactor: restructure dashboard UX and migrate logos to provider level
- Move job submission form to separate view (?action=new_job) - Replace inline form with prominent green button on main dashboard - Migrate logos from per-job (post thumbnail) to per-provider (user meta) - Add logo upload/removal functionality to provider dashboard - Display provider logo on single job pages instead of per-job logo - Add back link to archive on single job pages - Remove logo handling from form submission/edit processors - Improve button styling with proper CSS specificity Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -40,7 +40,8 @@ class DDHH_JM_Template {
|
||||
$job_type = get_post_meta( $post->ID, 'job_type', true );
|
||||
$job_deadline = get_post_meta( $post->ID, 'job_deadline', true );
|
||||
$job_contact_email = get_post_meta( $post->ID, 'job_contact_email', true );
|
||||
$job_logo = get_the_post_thumbnail( $post->ID, 'job-logo' );
|
||||
$provider_logo_id = get_user_meta( $post->post_author, 'ddhh_provider_logo', true );
|
||||
$job_logo = $provider_logo_id ? wp_get_attachment_image( absint( $provider_logo_id ), 'job-logo' ) : '';
|
||||
|
||||
// Get author/organization info
|
||||
$author = get_userdata( $post->post_author );
|
||||
@@ -50,6 +51,9 @@ class DDHH_JM_Template {
|
||||
// Build job details HTML
|
||||
ob_start();
|
||||
?>
|
||||
<div class="ddhh-back-to-archive">
|
||||
<a href="<?php echo esc_url( get_post_type_archive_link( 'job_offer' ) ); ?>">← Alle Jobangebote</a>
|
||||
</div>
|
||||
<div class="ddhh-job-offer-details">
|
||||
<?php if ( $job_logo ) : ?>
|
||||
<div class="job-logo">
|
||||
@@ -118,6 +122,18 @@ class DDHH_JM_Template {
|
||||
<?php endif; ?>
|
||||
|
||||
<style>
|
||||
.ddhh-back-to-archive {
|
||||
margin-bottom: 1.5rem;
|
||||
}
|
||||
.ddhh-back-to-archive a {
|
||||
color: #3b82f6;
|
||||
text-decoration: none;
|
||||
font-weight: 500;
|
||||
}
|
||||
.ddhh-back-to-archive a:hover {
|
||||
color: #2563eb;
|
||||
text-decoration: underline;
|
||||
}
|
||||
.ddhh-job-offer-details {
|
||||
margin: 2em 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user