Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
remcotolsma committed Mar 8, 2024
1 parent 077cbeb commit f13ec97
Show file tree
Hide file tree
Showing 4 changed files with 73 additions and 20 deletions.
Binary file modified languages/orbis-projects-nl_NL.mo
Binary file not shown.
29 changes: 19 additions & 10 deletions languages/orbis-projects-nl_NL.po
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ msgid ""
msgstr ""
"Project-Id-Version: Orbis Projects\n"
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/orbis-projects\n"
"POT-Creation-Date: 2024-03-08T08:17:30+00:00\n"
"PO-Revision-Date: 2024-03-08 09:18+0100\n"
"POT-Creation-Date: 2024-03-08T08:34:05+00:00\n"
"PO-Revision-Date: 2024-03-08 09:34+0100\n"
"Last-Translator: Remco Tolsma <[email protected]>\n"
"Language-Team: Pronamic <[email protected]>\n"
"Language: nl_NL\n"
Expand Down Expand Up @@ -115,7 +115,7 @@ msgstr "Afgerond"
msgid "Project is finished"
msgstr "Project is afgerond"

#: admin/meta-box-project-details.php:151 templates/projects-table-view.php:45
#: admin/meta-box-project-details.php:151 templates/projects-table-view.php:46
msgid "Invoicable"
msgstr "Factureerbaar"

Expand All @@ -131,7 +131,7 @@ msgstr "Gefactureerd"
msgid "Project is invoiced"
msgstr "Project is gefactureerd"

#: admin/meta-box-project-details.php:182 templates/projects-table-view.php:105
#: admin/meta-box-project-details.php:182 templates/projects-table-view.php:106
msgid "Invoice reference"
msgstr "Factuurreferentie"

Expand Down Expand Up @@ -554,31 +554,40 @@ msgid "Comment"
msgstr "Reactie"

#: templates/projects-table-view.php:44
msgid "Period"
msgstr "Periode"

#: templates/projects-table-view.php:45
msgid "Budget"
msgstr "Budget"

#: templates/projects-table-view.php:110
#: templates/projects-table-view.php:111
msgid "Line Description"
msgstr "Regelbeschrijving"

#. translators: 1st placeholder is the comment author, 2nd is the date
#: templates/projects-table-view.php:137
#: templates/projects-table-view.php:138
msgid "%1$s says on %2$s:"
msgstr "%1$s zegt op %2$s:"

#: templates/projects-table-view.php:172
#: templates/projects-table-view.php:173
msgid "Add status"
msgstr "Voeg status toe"

#: templates/projects-table-view.php:221
#. translators: 1: Period start date, 2: Period end date.
#: templates/projects-table-view.php:224
msgid "%1$s - %2$s"
msgstr "%1$s - %2$s"

#: templates/projects-table-view.php:256
msgid "Yes"
msgstr "Ja"

#: templates/projects-table-view.php:232
#: templates/projects-table-view.php:267
msgid "No"
msgstr "Nee"

#: templates/projects-table-view.php:244
#: templates/projects-table-view.php:279
#: templates/projects-without-agreement.php:71
msgid "Edit"
msgstr "Bewerken"
Expand Down
27 changes: 18 additions & 9 deletions languages/orbis-projects.pot
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"POT-Creation-Date: 2024-03-08T08:17:30+00:00\n"
"POT-Creation-Date: 2024-03-08T08:34:05+00:00\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"X-Generator: WP-CLI 2.10.0\n"
"X-Domain: orbis-projects\n"
Expand Down Expand Up @@ -109,7 +109,7 @@ msgid "Project is finished"
msgstr ""

#: admin/meta-box-project-details.php:151
#: templates/projects-table-view.php:45
#: templates/projects-table-view.php:46
msgid "Invoicable"
msgstr ""

Expand All @@ -126,7 +126,7 @@ msgid "Project is invoiced"
msgstr ""

#: admin/meta-box-project-details.php:182
#: templates/projects-table-view.php:105
#: templates/projects-table-view.php:106
msgid "Invoice reference"
msgstr ""

Expand Down Expand Up @@ -569,31 +569,40 @@ msgid "Comment"
msgstr ""

#: templates/projects-table-view.php:44
msgid "Period"
msgstr ""

#: templates/projects-table-view.php:45
msgid "Budget"
msgstr ""

#: templates/projects-table-view.php:110
#: templates/projects-table-view.php:111
msgid "Line Description"
msgstr ""

#. translators: 1st placeholder is the comment author, 2nd is the date
#: templates/projects-table-view.php:137
#: templates/projects-table-view.php:138
msgid "%1$s says on %2$s:"
msgstr ""

#: templates/projects-table-view.php:172
#: templates/projects-table-view.php:173
msgid "Add status"
msgstr ""

#: templates/projects-table-view.php:221
#. translators: 1: Period start date, 2: Period end date.
#: templates/projects-table-view.php:224
msgid "%1$s - %2$s"
msgstr ""

#: templates/projects-table-view.php:256
msgid "Yes"
msgstr ""

#: templates/projects-table-view.php:232
#: templates/projects-table-view.php:267
msgid "No"
msgstr ""

#: templates/projects-table-view.php:244
#: templates/projects-table-view.php:279
#: templates/projects-without-agreement.php:71
msgid "Edit"
msgstr ""
Expand Down
37 changes: 36 additions & 1 deletion templates/projects-table-view.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@

<th scope="col"><?php esc_html_e( 'Date', 'orbis-projects' ); ?></th>
<th scope="col"><?php esc_html_e( 'Comment', 'orbis-projects' ); ?></th>
<th scope="col"><?php esc_html_e( 'Period', 'orbis-projects' ); ?></th>
<th scope="col"><?php esc_html_e( 'Budget', 'orbis-projects' ); ?></th>
<th scope="col"><?php esc_html_e( 'Invoicable', 'orbis-projects' ); ?></th>
<th></th>
Expand Down Expand Up @@ -117,7 +118,7 @@
<?php endif; ?>

<td style="white-space: nowrap;">
<?php echo esc_html( get_the_time( 'j M Y', $project->project_post_id ) ); ?>
<?php echo esc_html( get_the_time( 'D j M Y', $project->project_post_id ) ); ?>
</td>
<td style="white-space: nowrap;">
<?php
Expand Down Expand Up @@ -194,6 +195,40 @@
<?php endif; ?>

</td>
<td style="white-space: nowrap;">
<?php

$start_date = null;

$start_date_string = \get_post_meta( $project->project_post_id, '_orbis_project_start_date', true );

if ( '' !== $start_date_string ) {
$value = DateTimeImmutable::createFromFormat( 'Y-m-d', $start_date_string );

$start_date = ( false === $value ) ? null : $value->setTime( 0, 0 );
}

$end_date = null;

$end_date_string = \get_post_meta( $project->project_post_id, '_orbis_project_end_date', true );

if ( '' !== $end_date_string ) {
$value = DateTimeImmutable::createFromFormat( 'Y-m-d', $end_date_string );

$end_date = ( false === $value ) ? null : $value->setTime( 0, 0 );
}

if ( null !== $start_date && null !== $end_date ) {
printf(
/* translators: 1: Period start date, 2: Period end date. */
\__( '%1$s - %2$s', 'orbis-projects' ),
( null === $start_date ) ? '?' : \esc_html( \date_i18n( 'D j M Y', $start_date->getTimestamp() ) ),
( null === $end_date ) ? '?' : \esc_html( \date_i18n( 'D j M Y', $end_date->getTimestamp() ) )
);
}

?>
</td>
<td style="white-space: nowrap;">
<span style="color: <?php echo esc_attr( $project->failed ? 'Red' : 'Green' ); ?>;">
<?php
Expand Down

0 comments on commit f13ec97

Please sign in to comment.