Skip to content

Commit

Permalink
add carbon, rearrange seeder
Browse files Browse the repository at this point in the history
  • Loading branch information
AleksandraKozubal committed Aug 30, 2024
1 parent 6868d9a commit 8f24609
Show file tree
Hide file tree
Showing 10 changed files with 399 additions and 66 deletions.
67 changes: 1 addition & 66 deletions database/seeders/LocalEnvironmentSeeder.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@

use Blumilk\Website\Models\ContactForm;
use Blumilk\Website\Models\News;
use Blumilk\Website\Models\Project;
use Blumilk\Website\Models\Reference;
use Blumilk\Website\Models\Tag;
use Illuminate\Database\Seeder;
Expand All @@ -20,75 +19,11 @@ public function run(): void
}

$this->call(UsersSeeder::class);
$this->call(ProjectsSeeder::class);

Tag::factory()->count(12)->create();
News::factory()->count(12)->create();
$this->createSpecificProjects();
Project::factory()->count(12)->create();
ContactForm::factory()->count(12)->create();
Reference::factory()->count(12)->create();
}

private function createSpecificProjects(): void
{
Project::factory()->create([
"name_first_part" => [
"pl" => "Aplikacja do",
"en" => "Application for",
],
"name_second_part" => [
"pl" => "zamawiania usług medycznych",
"en" => "ordering medical services",
],
"name_third_part" => [
"pl" => "z przychodni Vita+",
"en" => "from the Vita+ clinic",
],
"color" => "#9676F9",
"photo" => "factory/case_study.jpg",
"published" => true,
"slug" => "vita",
"template" => "vita",
]);

Project::factory()->create([
"name_first_part" => [
"pl" => "Aplikacja shared economy do",
"en" => "Shared economy application for",
],
"name_second_part" => [
"pl" => "przewozów przesyłek",
"en" => "the transport of parcels",
],
"name_third_part" => [
"pl" => null,
"en" => null,
],
"color" => "#FAD12A",
"photo" => "factory/case_study.jpg",
"published" => true,
"slug" => "getthebox",
"template" => "getthebox",
]);

Project::factory()->create([
"name_first_part" => [
"pl" => "System",
"en" => "System for",
],
"name_second_part" => [
"pl" => "zarządzania licencjami i dystrybucji",
"en" => "managing licenses and distributing",
],
"name_third_part" => [
"pl" => "oprogramowania",
"en" => "Software",
],
"color" => "#FF5555",
"photo" => "factory/case_study.jpg",
"published" => true,
"slug" => "k1",
"template" => "k1",
]);
}
}
113 changes: 113 additions & 0 deletions database/seeders/ProjectsSeeder.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
<?php

declare(strict_types=1);

namespace Database\Seeders;

use Blumilk\Website\Models\Project;
use Illuminate\Database\Seeder;

class ProjectsSeeder extends Seeder
{
public function run(): void
{
$this->seedVita();
$this->seedGetTheBox();
$this->seedK1();
$this->seedCarbon();

Project::factory()->count(12)->create();
}

private function seedVita(): void
{
Project::factory()->create([
"name_first_part" => [
"pl" => "Aplikacja do",
"en" => "Application for",
],
"name_second_part" => [
"pl" => "zamawiania usług medycznych",
"en" => "ordering medical services",
],
"name_third_part" => [
"pl" => "z przychodni Vita+",
"en" => "from the Vita+ clinic",
],
"color" => "#9676F9",
"photo" => "factory/case_study.jpg",
"published" => true,
"slug" => "vita",
"template" => "vita",
]);
}

private function seedGetTheBox(): void
{
Project::factory()->create([
"name_first_part" => [
"pl" => "Aplikacja shared economy do",
"en" => "Shared economy application for",
],
"name_second_part" => [
"pl" => "przewozów przesyłek",
"en" => "the transport of parcels",
],
"name_third_part" => [
"pl" => null,
"en" => null,
],
"color" => "#FAD12A",
"photo" => "factory/case_study.jpg",
"published" => true,
"slug" => "getthebox",
"template" => "getthebox",
]);
}

private function seedK1(): void
{
Project::factory()->create([
"name_first_part" => [
"pl" => "System",
"en" => "System for",
],
"name_second_part" => [
"pl" => "zarządzania licencjami i dystrybucji",
"en" => "managing licenses and distributing",
],
"name_third_part" => [
"pl" => "oprogramowania",
"en" => "Software",
],
"color" => "#FF5555",
"photo" => "factory/case_study.jpg",
"published" => true,
"slug" => "k1",
"template" => "k1",
]);
}

private function seedCarbon(): void
{
Project::factory()->create([
"name_first_part" => [
"pl" => "Aplikacja do zbierania danych i generowania raportów",
"en" => "Application for collecting data and generating reports",
],
"name_second_part" => [
"pl" => "dotyczących śladu węglowego",
"en" => "regarding carbon footprint",
],
"name_third_part" => [
"pl" => null,
"en" => null,
],
"color" => "#F39200",
"photo" => "factory/case_study.jpg",
"published" => true,
"slug" => "carbon",
"template" => "carbon",
]);
}
}
52 changes: 52 additions & 0 deletions lang/en/projects.php
Original file line number Diff line number Diff line change
Expand Up @@ -205,4 +205,56 @@
"mobile" => "phone with the application",
],
],
"carbon" => [
"title_1" => "Application for collecting data and generating reports",
"title_2" => "regarding carbon footprint",
"project_description" => "The tool allows users to independently calculate CO2 emissions, providing a large set of indicators that are the basis for calculations.",
"challenges" => [
"challenge_1" => [
"title" => "Advanced Role System",
"description" => "enabling work in the system on many levels",
],
"challenge_2" => [
"title" => "Implementation of CO2 counting algorithms",
"description" => "understanding the complexity of calculations",
],
"challenge_3" => [
"title" => "Data security",
"description" => "in terms of access control",
],
],
"functionalities" => [
"functionality_1" => [
"title" => "Application management",
"description" => "in the context of users, locations, processes and products",
],
"functionality_2" => [
"title" => "Indicator database",
"description" => "global and individual user list",
],
"functionality_3" => [
"title" => "CO2 Emissions Calculator",
"description" => "for the whole process",
],
"functionality_4" => [
"title" => "Generating a report",
"description" => "for the selected year and location",
],
"functionality_5" => [
"title" => "Controlled access to the system",
"description" => "managed from the administrator level",
],
],
"testimonial" => [
"name" => "Dominika Pasternak",
"company" => "Deputy Chief Accountant",
"description" => "The created application significantly improved the processes within the company. The team demonstrated experience, great flexibility and understanding of our specific needs. Thanks to free communication, we were able to participate in the development of the software on an ongoing basis and submit our suggestions.",
],
"alt" => [
"laptop_1" => "laptop with application page",
"laptop_2" => "laptop standing on a desk with an open application",
"sitemap" => "sitemap",
"monitor" => "monitor on yellow background with application",
],
],
];
52 changes: 52 additions & 0 deletions lang/pl/projects.php
Original file line number Diff line number Diff line change
Expand Up @@ -205,4 +205,56 @@
"mobile" => "telefon z aplikacją",
],
],
"carbon" => [
"title_1" => "Aplikacja do zbierania danych i generowania raportów",
"title_2" => "dotyczących śladu węglowego",
"project_description" => "Narzędzie pozwala użytkownikom na samodzielne wyliczenie emisyjności CO2, dostarczając duży zasób wskaźników będących podstawą wyliczeń.",
"challenges" => [
"challenge_1" => [
"title" => "Zaawansowany system ról",
"description" => "umożliwiający pracę w systemie na wielu poziomach",
],
"challenge_2" => [
"title" => "Implementacja algorytmów do liczenia CO2",
"description" => "zrozumienie złożoności wyliczeń",
],
"challenge_3" => [
"title" => "Bezpieczeństwo danych",
"description" => "w zakresie kontroli dostępu",
],
],
"functionalities" => [
"functionality_1" => [
"title" => "Zarządzanie aplikacją",
"description" => "w kontekście użytkowników, lokalizacji, procesów i produktów",
],
"functionality_2" => [
"title" => "Baza wskaźników",
"description" => "globalna oraz indywidualna lista użytkownika",
],
"functionality_3" => [
"title" => "Kalkulator emisji CO2",
"description" => "dla całego procesu",
],
"functionality_4" => [
"title" => "Generowanie raportu",
"description" => "dla wybranego roku i lokalizacji",
],
"functionality_5" => [
"title" => "Kontrolowany dostęp do systemu",
"description" => "zarządzany z poziomu administratora",
],
],
"testimonial" => [
"name" => "Dominika Pasternak",
"company" => "Deputy Chief Accountant",
"description" => "Stworzona aplikacja znacznie usprawniła procesy wewnątrz firmy. Zespół wykazał się doświadczeniem, dużą elastycznością i zrozumieniem naszych specyficznych potrzeb. Dzięki swobodnej komunikacji mogliśmy na bieżąco uczestniczyć w tworzeniu oprogramowania i zgłaszać swoje sugestie.",
],
"alt" => [
"laptop_1" => "laptop ze stroną aplikacji",
"laptop_2" => "laptop stojący na biurku z otwartą aplikacją",
"sitemap" => "mapa aplikacji",
"monitor" => "monitor na żółtym tle z aplikacją",
],
],
];
Binary file added public/images/projects/carbon/desktop.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/projects/carbon/laptop_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/images/projects/carbon/laptop_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
94 changes: 94 additions & 0 deletions public/images/projects/carbon/pl/sitemap.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
86 changes: 86 additions & 0 deletions resources/views/projects/carbon.blade.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
@extends("layout.public")

@section("title", $project->name_first_part . " " . $project->name_second_part . " " . $project->name_third_part)
@section("description", $project->description)

@section("content")
<x-projects.title>
<span class="mt-4"> {{ __("projects.carbon.title_1") }} </span>
<span class="text-carbon"> {{ __("projects.carbon.title_2") }}</span>
</x-projects.title>

<x-projects.main-image src="{{ asset('images/projects/carbon/laptop_1.png') }}" alt="{{ __('projects.carbon.alt.laptop_1') }}" shift="object-[25%_50%]"/>

<div class="mt-20 sm:mt-0">
<x-projects.description>{{ __("projects.carbon.project_description") }}</x-projects.description>
</div>
<section class="mx-[10%] lg:mx-[15%] 2xl:max-w-7xl 2xl:mx-auto space-y-10 py-10 md:py-20 text-center">
<h2 class="text-3xl md:text-4xl lg:text-5xl font-semibold md:pb-8">{{ __("projects.challenges") }}</h2>
<div class="flex place-content-center flex-wrap gap-4 2xl:gap-10">
<x-tile title="{{ __('projects.carbon.challenges.challenge_1.title') }}"
description="{{ __('projects.carbon.challenges.challenge_1.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.app-window accent="stroke-carbon"/>
</x-tile>

<x-tile title="{{ __('projects.carbon.challenges.challenge_2.title') }}"
description="{{ __('projects.carbon.challenges.challenge_2.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.category accent="stroke-carbon"/>
</x-tile>

<x-tile title="{{ __('projects.carbon.challenges.challenge_3.title') }}"
description="{{ __('projects.carbon.challenges.challenge_3.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.credit-card accent="stroke-carbon"/>
</x-tile>
</div>
</section>

<x-projects.image src="{{ asset('images/projects/carbon/laptop_2.png') }}" alt="{{ __('projects.carbon.alt.laptop_2') }}" />

<div class="py-20 md:py-40">
<x-projects.title>{{ __("projects.sitemap") }}</x-projects.title>
<x-projects.image src="{{ asset('images/projects/carbon/'.$locale.'/sitemap.svg') }}" alt="{{ __('projects.carbon.alt.sitemap') }}" margin="true" />
</div>

<section class="mx-[10%] lg:mx-[15%] 2xl:max-w-7xl 2xl:mx-auto space-y-10 py-10 md:py-20 text-center">
<h2 class="text-3xl md:text-4xl lg:text-5xl font-semibold pb-8">{{ __("projects.key_functionalities") }}</h2>
<div class="flex place-content-center flex-wrap gap-4 2xl:gap-10">
<x-tile title="{{ __('projects.carbon.functionalities.functionality_1.title') }}"
description="{{ __('projects.carbon.functionalities.functionality_1.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.chart-infographic accent="stroke-carbon" />
</x-tile>
<x-tile title="{{ __('projects.carbon.functionalities.functionality_2.title') }}"
description="{{ __('projects.carbon.functionalities.functionality_2.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.box accent="stroke-carbon" />
</x-tile>
<x-tile title="{{ __('projects.carbon.functionalities.functionality_3.title') }}"
description="{{ __('projects.carbon.functionalities.functionality_3.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.packages accent="stroke-carbon" />
</x-tile>
<x-tile title="{{ __('projects.carbon.functionalities.functionality_4.title') }}"
description="{{ __('projects.carbon.functionalities.functionality_4.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.key accent="stroke-carbon" />
</x-tile>
<x-tile title="{{ __('projects.carbon.functionalities.functionality_5.title') }}"
description="{{ __('projects.carbon.functionalities.functionality_5.description') }}"
class="max-w-[350px] 2xl:place-items-start">
<x-icons.shield-check accent="stroke-carbon" />
</x-tile>
</div>
</section>

<x-projects.image src="{{ asset('images/projects/carbon/desktop.png') }}" alt="{{ __('projects.carbon.alt.desktop') }}" />

<x-projects.reference name="{{ __('projects.carbon.testimonial.name') }}"
company="{{ __('projects.carbon.testimonial.company') }}"
description="{{ __('projects.carbon.testimonial.description') }}"
photo="graphics/placeholders/male.svg"/>

<x-text-us-section/>
@endsection
Loading

0 comments on commit 8f24609

Please sign in to comment.