Merge branch 'main' of https://framagit.org/isUnknown/pdc-b2b-project-management-platform
* 'main' of https://framagit.org/isUnknown/pdc-b2b-project-management-platform: clientBriefPdf => pdf clientBriefImages => moodboard # Conflicts: # public/content/projects/1_miss-dior-blooming-bouquet/1_client-brief/client-brief.txt
This commit is contained in:
commit
9d6ee634fb
10 changed files with 17 additions and 17 deletions
|
|
@ -22,4 +22,4 @@ Uuid: 6yh1yt2Sk45Y2sOl
|
|||
|
||||
----
|
||||
|
||||
Clientbriefpdf: home/927346290_au-commencement-du-college-chloe-avait-donc-fait-la-connaissance-dun-garcon.-il-etait-plus-vieux.pdf
|
||||
Pdf: home/927346290_au-commencement-du-college-chloe-avait-donc-fait-la-connaissance-dun-garcon.-il-etait-plus-vieux.pdf
|
||||
|
|
@ -6,7 +6,7 @@ Stepname: clientBrief
|
|||
|
||||
----
|
||||
|
||||
Clientbriefpdf:
|
||||
Pdf:
|
||||
|
||||
----
|
||||
|
||||
|
|
@ -14,7 +14,7 @@ Description:
|
|||
|
||||
----
|
||||
|
||||
Clientbriefimages:
|
||||
Moodboard:
|
||||
|
||||
----
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ Uuid: 5NGq8baScF9pCeK9
|
|||
|
||||
----
|
||||
|
||||
Clientbriefpdf:
|
||||
Pdf:
|
||||
|
||||
----
|
||||
|
||||
|
|
@ -22,4 +22,4 @@ Description:
|
|||
|
||||
----
|
||||
|
||||
Clientbriefimages:
|
||||
Moodboard:
|
||||
|
|
@ -2,4 +2,4 @@ Title: Nom du service
|
|||
|
||||
----
|
||||
|
||||
Clientbriefimagestags: Parachèvements, Forme & design, Matériaux & textures, Coloris & nuances, Bouchon, Bouton poussoir, DA globale
|
||||
Moodboardtags: Parachèvements, Forme & design, Matériaux & textures, Coloris & nuances, Bouchon, Bouton poussoir, DA globale
|
||||
|
|
@ -24,7 +24,7 @@ tabs:
|
|||
stepName:
|
||||
type: hidden
|
||||
value: test
|
||||
clientBriefPdf:
|
||||
pdf:
|
||||
label: PDF
|
||||
type: files
|
||||
multiple: false
|
||||
|
|
@ -34,7 +34,7 @@ tabs:
|
|||
size: tiny
|
||||
buttons: false
|
||||
maxlength: 700
|
||||
clientBriefImages:
|
||||
moodboard:
|
||||
label: Images
|
||||
type: files
|
||||
uploads: image
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ tabs:
|
|||
label: Paramètres
|
||||
type: fields
|
||||
fields:
|
||||
clientBriefImagesTags:
|
||||
moodboardTags:
|
||||
label: Tags des images de Brief client
|
||||
help: Ensemble des tags d’images disponibles lors de la création du Brief client
|
||||
type: tags
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ return [
|
|||
|
||||
|
||||
$page = page($pageUri);
|
||||
$allFiles = $page->clientBriefImages()->isNotEmpty() ? $page->clientBriefImages()->toFiles()->pluck('uuid', ',') : [];
|
||||
$allFiles = $page->moodboard()->isNotEmpty() ? $page->moodboard()->toFiles()->pluck('uuid', ',') : [];
|
||||
$alerts = [];
|
||||
$success = [];
|
||||
|
||||
|
|
@ -125,13 +125,13 @@ return [
|
|||
$newPage = $page->update([]);
|
||||
if (!empty($allFiles)) {
|
||||
$newPage = $page->update([
|
||||
'clientBriefImages' => $allFiles
|
||||
'moodboard' => $allFiles
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
$images = [];
|
||||
foreach ($newPage->clientBriefImages()->toFiles() as $image) {
|
||||
foreach ($newPage->moodboard()->toFiles() as $image) {
|
||||
$images[] = [
|
||||
'url' => $image->url(),
|
||||
'uuid' => (string) $image->uuid(),
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ return [
|
|||
try {
|
||||
$name = crc32($upload['name'] . microtime()) . '_' . $upload['name'];
|
||||
|
||||
$existingFileId = $page->clientBriefPdf()->id() ?? null;
|
||||
$existingFileId = $page->pdf()->id() ?? null;
|
||||
|
||||
if ($existingFileId) {
|
||||
$existingFile = $kirby->file($existingFileId);
|
||||
|
|
@ -43,7 +43,7 @@ return [
|
|||
]);
|
||||
|
||||
$newPage = $page->update([
|
||||
"clientBriefPdf" => $newFile->id()
|
||||
"pdf" => $newFile->id()
|
||||
]);
|
||||
|
||||
return $newPage->toArray();
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
$images = [];
|
||||
|
||||
foreach ($page->clientBriefImages()->toFiles() as $image) {
|
||||
foreach ($page->moodboard()->toFiles() as $image) {
|
||||
$images[] = [
|
||||
'url' => $image->url(),
|
||||
'uuid' => (string) $image->uuid(),
|
||||
|
|
|
|||
|
|
@ -34,9 +34,9 @@ function changeStep(stepName) {
|
|||
}
|
||||
|
||||
function setInitialStep() {
|
||||
const hasPDF = page.value.content.clientbriefpdf.length !== 0;
|
||||
const hasPDF = page.value.content.pdf.length !== 0;
|
||||
const hasImages =
|
||||
page.value.content.clientbriefimages.length !== 0 ||
|
||||
page.value.content.moodboard.length !== 0 ||
|
||||
page.value.content.description.length !== 0;
|
||||
const isEmpty = !hasPDF && !hasImages;
|
||||
if (isEmpty) return "Intro";
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue