Modified several files for spelling and grammar mistakes

This commit is contained in:
Adrian 2021-11-10 23:53:21 +02:00
parent 90f2af0d39
commit b669d3e879
13 changed files with 227 additions and 227 deletions

View File

@ -885,7 +885,7 @@ class REST_Items_Controller extends REST_Controller {
} }
private function submission_item_metadada ( \Tainacan\Entities\Item_Metadata_Entity &$item_metadata, $request) { private function submission_item_metadata ( \Tainacan\Entities\Item_Metadata_Entity &$item_metadata, $request) {
$collection_id = $item_metadata->get_item()->get_collection_id(); $collection_id = $item_metadata->get_item()->get_collection_id();
$item = $item_metadata->get_item(); $item = $item_metadata->get_item();
$collection = $this->collections_repository->fetch($collection_id); $collection = $this->collections_repository->fetch($collection_id);
@ -1002,7 +1002,7 @@ class REST_Items_Controller extends REST_Controller {
$metadatum_child = $this->metadatum_repository->fetch( $child['metadatum_id'] ); $metadatum_child = $this->metadatum_repository->fetch( $child['metadatum_id'] );
$item_metadata_child = new Entities\Item_Metadata_Entity($item, $metadatum_child, null, $parent_meta_id); $item_metadata_child = new Entities\Item_Metadata_Entity($item, $metadatum_child, null, $parent_meta_id);
$item_metadata_child->set_value($child_value); $item_metadata_child->set_value($child_value);
$item_metadata_child = $this->submission_item_metadada($item_metadata_child, $request); $item_metadata_child = $this->submission_item_metadata($item_metadata_child, $request);
if ($item_metadata_child instanceof \WP_REST_Response) { if ($item_metadata_child instanceof \WP_REST_Response) {
return $item_metadata_child; return $item_metadata_child;
} }
@ -1024,7 +1024,7 @@ class REST_Items_Controller extends REST_Controller {
$metadatum_child = $this->metadatum_repository->fetch( $child['metadatum_id'] ); $metadatum_child = $this->metadatum_repository->fetch( $child['metadatum_id'] );
$item_metadata_child = new Entities\Item_Metadata_Entity($item, $metadatum_child, null, $parent_meta_id); $item_metadata_child = new Entities\Item_Metadata_Entity($item, $metadatum_child, null, $parent_meta_id);
$item_metadata_child->set_value($child_value); $item_metadata_child->set_value($child_value);
$item_metadata_child = $this->submission_item_metadada($item_metadata_child, $request); $item_metadata_child = $this->submission_item_metadata($item_metadata_child, $request);
if ($item_metadata_child instanceof \WP_REST_Response) { if ($item_metadata_child instanceof \WP_REST_Response) {
return $item_metadata_child; return $item_metadata_child;
} }
@ -1046,7 +1046,7 @@ class REST_Items_Controller extends REST_Controller {
} else { } else {
$item_metadata->set_value( is_array($value) ? implode(' ', $value) : $value); $item_metadata->set_value( is_array($value) ? implode(' ', $value) : $value);
} }
$item_metadata = $this->submission_item_metadada($item_metadata, $request); $item_metadata = $this->submission_item_metadata($item_metadata, $request);
if ($item_metadata instanceof \WP_REST_Response) { if ($item_metadata instanceof \WP_REST_Response) {
return $item_metadata; return $item_metadata;
} }
@ -1061,7 +1061,7 @@ class REST_Items_Controller extends REST_Controller {
} else { } else {
$item_metadata->set_value( is_array($value) ? implode(' ', $value) : $value); $item_metadata->set_value( is_array($value) ? implode(' ', $value) : $value);
} }
$item_metadata = $this->submission_item_metadada($item_metadata, $request); $item_metadata = $this->submission_item_metadata($item_metadata, $request);
if ($item_metadata instanceof \WP_REST_Response) { if ($item_metadata instanceof \WP_REST_Response) {
return $item_metadata; return $item_metadata;
} }

View File

@ -23,8 +23,8 @@ class Bulk_Edit_Process extends Generic_Process {
$this->item_metadata_repository = \Tainacan\Repositories\Item_Metadata::get_instance(); $this->item_metadata_repository = \Tainacan\Repositories\Item_Metadata::get_instance();
$this->steps = [ $this->steps = [
[ [
'name' => __('Bulk edit control metadada', 'tainacan'), 'name' => __('Bulk edit control metadata', 'tainacan'),
'progress_label' => __('Creating bulk edit control metadada', 'tainacan'), 'progress_label' => __('Creating bulk edit control metadata', 'tainacan'),
'callback' => 'add_control_metadata' 'callback' => 'add_control_metadata'
],[ ],[
'name' => __('Bulk edit', 'tainacan'), 'name' => __('Bulk edit', 'tainacan'),

View File

@ -61,8 +61,8 @@ class Importer_Handler {
]); ]);
$this->register_importer([ $this->register_importer([
'name' => 'Youtube (Experimental)', 'name' => 'YouTube (Experimental)',
'description' => __('Import items from an Youtube URL', 'tainacan'), 'description' => __('Import items from an YouTube URL', 'tainacan'),
'slug' => 'youtube_importer', 'slug' => 'youtube_importer',
'class_name' => '\Tainacan\Importer\Youtube_Importer', 'class_name' => '\Tainacan\Importer\Youtube_Importer',
'manual_collection' => true, 'manual_collection' => true,
@ -71,7 +71,7 @@ class Importer_Handler {
$this->register_importer([ $this->register_importer([
'name' => 'Flickr (Experimental)', 'name' => 'Flickr (Experimental)',
'description' => __('Import items from an Flickr URL', 'tainacan'), 'description' => __('Import items from a Flickr URL', 'tainacan'),
'slug' => 'flickr_importer', 'slug' => 'flickr_importer',
'class_name' => '\Tainacan\Importer\Flickr_Importer', 'class_name' => '\Tainacan\Importer\Flickr_Importer',
'manual_collection' => true, 'manual_collection' => true,

View File

@ -63,7 +63,7 @@ You can also have metadata as taxonomies, which you can configure with a set of
= Add links to your menu = = Add links to your menu =
Edit your menu and links directly to your collections. Click "Screen options" at the top of the Menu edition page and enable "Collections". Edit your menu and links directly to your collections. Click "Screen options" at the top of the Edit Menu page and enable "Collections".
If you want to add a link to the list of collections, click "View all" tab on the Collections box on the left, and then add the first item named "Collections" to the menu. If you want to add a link to the list of collections, click "View all" tab on the Collections box on the left, and then add the first item named "Collections" to the menu.

View File

@ -12,7 +12,7 @@
:is="isModal ? 'header' : 'div'" :is="isModal ? 'header' : 'div'"
class="tainacan-page-title" class="tainacan-page-title"
:class="{ 'tainacan-modal-title': isModal }"> :class="{ 'tainacan-modal-title': isModal }">
<h2>{{ editForm & editForm.id && editForm.id != 'new' ? $i18n.get("title_term_edition") : $i18n.get("title_term_creation") }}</h2> <h2>{{ editForm & editForm.id && editForm.id != 'new' ? $i18n.get("title_term_edit") : $i18n.get("title_term_creation") }}</h2>
<a <a
v-if="editForm && editForm.url != undefined && editForm.url!= ''" v-if="editForm && editForm.url != undefined && editForm.url!= ''"
target="_blank" target="_blank"

View File

@ -59,7 +59,7 @@
:edit-form="{ id: 'new', name: newTermName ? newTermName : '' }" :edit-form="{ id: 'new', name: newTermName ? newTermName : '' }"
:is-modal="true" :is-modal="true"
@onEditionFinished="($event) => addRecentlyCreatedTerm($event.term)" @onEditionFinished="($event) => addRecentlyCreatedTerm($event.term)"
@onEditionCanceled="() => $console.log('Edition canceled')" @onEditionCanceled="() => $console.log('Editing canceled')"
@onErrorFound="($event) => $console.log('Form with errors: ' + $event)" /> @onErrorFound="($event) => $console.log('Form with errors: ' + $event)" />
</b-modal> </b-modal>

View File

@ -219,7 +219,7 @@
class="button is-white is-pulled-right"> class="button is-white is-pulled-right">
<span <span
v-tooltip="{ v-tooltip="{
content: $i18n.get('remove_bulk_edition'), content: $i18n.get('remove_bulk_edit'),
autoHide: true, autoHide: true,
placement: 'auto-end' placement: 'auto-end'
}" }"
@ -239,7 +239,7 @@
size="is-small" size="is-small"
position="is-left" position="is-left"
animated animated
:label="$i18n.get('info_bulk_edition_process_added')"> :label="$i18n.get('info_bulk_edit_process_added')">
<span class="icon"> <span class="icon">
<i class="has-text-success tainacan-icon tainacan-icon-1-25em tainacan-icon-approvedcircle"/> <i class="has-text-success tainacan-icon tainacan-icon-1-25em tainacan-icon-approvedcircle"/>
</span> </span>
@ -279,7 +279,7 @@
<span class="icon is-small"> <span class="icon is-small">
<i class="tainacan-icon has-text-secondary tainacan-icon-add"/> <i class="tainacan-icon has-text-secondary tainacan-icon-add"/>
</span> </span>
&nbsp;{{ $i18n.get('new_bulk_edition_criterion') }} &nbsp;{{ $i18n.get('new_bulk_edit_criterion') }}
</a> </a>
</div> </div>

View File

@ -16,7 +16,7 @@ import AvailableExportersPage from '../pages/lists/available-exporters-page.vue'
import AvailableImportersPage from '../pages/lists/available-importers-page.vue' import AvailableImportersPage from '../pages/lists/available-importers-page.vue'
import CapabilitiesPage from '../pages/lists/capabilities-page.vue' import CapabilitiesPage from '../pages/lists/capabilities-page.vue'
// Edition Form Components // Edit Form Components
import CollectionEditionForm from '../components/edition/collection-edition-form.vue' import CollectionEditionForm from '../components/edition/collection-edition-form.vue'
import ImporterEditionForm from '../components/edition/importer-edition-form.vue' import ImporterEditionForm from '../components/edition/importer-edition-form.vue'
import ImporterMappingForm from '../components/edition/importer-mapping-form.vue' import ImporterMappingForm from '../components/edition/importer-mapping-form.vue'
@ -49,8 +49,8 @@ const routes = [
{ path: 'items/:itemId', name: 'ItemPage', component: ItemPage, meta: {title: i18nGet('title_item_page') } }, { path: 'items/:itemId', name: 'ItemPage', component: ItemPage, meta: {title: i18nGet('title_item_page') } },
{ path: 'bulk-add', name: 'CollectionItemBulkAddPage', component: ItemBulkEditionForm, meta: {title: i18nGet('title_item_bulk_add') } }, { path: 'bulk-add', name: 'CollectionItemBulkAddPage', component: ItemBulkEditionForm, meta: {title: i18nGet('title_item_bulk_add') } },
{ path: 'settings', component: CollectionEditionForm, name: 'CollectionEditionForm', meta: {title: i18nGet('title_collection_settings') } }, { path: 'settings', component: CollectionEditionForm, name: 'CollectionEditionForm', meta: {title: i18nGet('title_collection_settings') } },
{ path: 'metadata', component: MetadataPage, name: 'CollectionMetadataPage', meta: {title: i18nGet('title_collection_metadata_edition') } }, { path: 'metadata', component: MetadataPage, name: 'CollectionMetadataPage', meta: {title: i18nGet('title_collection_metadata_edit') } },
{ path: 'filters', component: FiltersPage, name: 'CollectionFiltersPage', meta: {title: i18nGet('title_collection_filters_edition') } }, { path: 'filters', component: FiltersPage, name: 'CollectionFiltersPage', meta: {title: i18nGet('title_collection_filters_edit') } },
{ path: 'activities', component: ActivitiesPage, name: 'CollectionActivitiesPage', meta: {title: i18nGet('title_collection_activities') } }, { path: 'activities', component: ActivitiesPage, name: 'CollectionActivitiesPage', meta: {title: i18nGet('title_collection_activities') } },
{ path: 'capabilities', component: CapabilitiesPage, name: 'CollectionCapabilitiesPage', meta: {title: i18nGet('title_collection_capabilities') } }, { path: 'capabilities', component: CapabilitiesPage, name: 'CollectionCapabilitiesPage', meta: {title: i18nGet('title_collection_capabilities') } },
{ path: 'sequence/:sequenceId', name: 'SavedSequenceEditionForm', component: ItemEditionForm, meta: {title: i18nGet('title_edit_item') } }, { path: 'sequence/:sequenceId', name: 'SavedSequenceEditionForm', component: ItemEditionForm, meta: {title: i18nGet('title_edit_item') } },
@ -67,7 +67,7 @@ const routes = [
{ path: '/taxonomies', name: 'TaxonomyPage', component: TaxonomyPage, meta: {title: i18nGet('title_taxonomies_page') } }, { path: '/taxonomies', name: 'TaxonomyPage', component: TaxonomyPage, meta: {title: i18nGet('title_taxonomies_page') } },
{ path: '/taxonomies/new', name: 'TaxonomyCreationForm', component: TaxonomyEditionForm, meta: {title: i18nGet('title_create_taxonomy_page') } }, { path: '/taxonomies/new', name: 'TaxonomyCreationForm', component: TaxonomyEditionForm, meta: {title: i18nGet('title_create_taxonomy_page') } },
{ path: '/taxonomies/:taxonomyId/edit', name: 'TaxonomyEditionForm', component: TaxonomyEditionForm, meta: {title: i18nGet('title_taxonomy_edition_page') } }, { path: '/taxonomies/:taxonomyId/edit', name: 'TaxonomyEditionForm', component: TaxonomyEditionForm, meta: {title: i18nGet('title_taxonomy_edit_page') } },
{ path: '/taxonomies/:taxonomyId', redirect: '/taxonomies/:taxonomyId/edit' }, { path: '/taxonomies/:taxonomyId', redirect: '/taxonomies/:taxonomyId/edit' },
{ path: '/activities', name: 'ActivitiesPage', component: ActivitiesPage, meta: {title: i18nGet('title_repository_activities_page') } }, { path: '/activities', name: 'ActivitiesPage', component: ActivitiesPage, meta: {title: i18nGet('title_repository_activities_page') } },

View File

@ -305,7 +305,7 @@ export const clearTerms = ({ commit }) => {
commit('clearTerms'); commit('clearTerms');
}; };
// Used only on Term Edition form, for autocomplete search for parents // Used only on Term Edit form, for autocomplete search for parents
export const fetchPossibleParentTerms = ({ commit }, { taxonomyId, termId, search, offset } ) => { export const fetchPossibleParentTerms = ({ commit }, { taxonomyId, termId, search, offset } ) => {
let endpoint = '/taxonomy/' + taxonomyId + '/terms?searchterm=' + search + '&hierarchical=1&exclude_tree=' + termId + "&hideempty=0&offset=0&number=20&order=asc"; let endpoint = '/taxonomy/' + taxonomyId + '/terms?searchterm=' + search + '&hierarchical=1&exclude_tree=' + termId + "&hideempty=0&offset=0&number=20&order=asc";

View File

@ -8,7 +8,7 @@
class="tainacan-form term-creation-panel" class="tainacan-form term-creation-panel"
@submit.prevent="saveEdition(editForm)"> @submit.prevent="saveEdition(editForm)">
<h4>{{ editForm & editForm.id && editForm.id != 'new' ? $i18n.get("title_term_edition") : $i18n.get("title_term_creation") }}</h4> <h4>{{ editForm & editForm.id && editForm.id != 'new' ? $i18n.get("title_term_edit") : $i18n.get("title_term_creation") }}</h4>
<div> <div>
<b-loading <b-loading

View File

@ -688,7 +688,7 @@ export default {
]), ]),
onSubmit() { onSubmit() {
// Puts loading on Item edition // Puts loading on Item edit
this.isSubmitting = true; this.isSubmitting = true;
let data = this.form; let data = this.form;

View File

@ -80,15 +80,15 @@ return apply_filters( 'tainacan-i18n', [
'run' => __( 'Run', 'tainacan' ), 'run' => __( 'Run', 'tainacan' ),
'edit_search' => __( 'Edit search', 'tainacan' ), 'edit_search' => __( 'Edit search', 'tainacan' ),
'apply' => __( 'Apply', 'tainacan' ), 'apply' => __( 'Apply', 'tainacan' ),
'add_another_bulk_edition' => __( 'Add another bulk edition criterion', 'tainacan' ), 'add_another_bulk_edit' => __( 'Add another bulk edit criterion', 'tainacan' ),
'add_one_bulk_edition' => __( 'Add one bulk edition criterion', 'tainacan' ), 'add_one_bulk_edit' => __( 'Add one bulk edit criterion', 'tainacan' ),
'remove_bulk_edition' => __( 'Remove bulk edition criterion', 'tainacan' ), 'remove_bulk_edit' => __( 'Remove bulk edit criterion', 'tainacan' ),
'set_new_value' => __( 'Set new value', 'tainacan' ), 'set_new_value' => __( 'Set new value', 'tainacan' ),
'replace_value' => __( 'Replace value', 'tainacan' ), 'replace_value' => __( 'Replace value', 'tainacan' ),
'copy_value' => __( 'Copy value from', 'tainacan' ), 'copy_value' => __( 'Copy value from', 'tainacan' ),
'finish' => __( 'Finish', 'tainacan' ), 'finish' => __( 'Finish', 'tainacan' ),
'select_to_create' => __( 'select to create', 'tainacan' ), 'select_to_create' => __( 'select to create', 'tainacan' ),
'new_bulk_edition_criterion' => __( 'New bulk edition criterion', 'tainacan' ), 'new_bulk_edit_criterion' => __( 'New bulk edit criterion', 'tainacan' ),
'undo' => __( 'Undo', 'tainacan' ), 'undo' => __( 'Undo', 'tainacan' ),
'delete' => __( 'Delete', 'tainacan' ), 'delete' => __( 'Delete', 'tainacan' ),
'skip' => __( 'Skip', 'tainacan' ), 'skip' => __( 'Skip', 'tainacan' ),
@ -126,7 +126,7 @@ return apply_filters( 'tainacan-i18n', [
'title_collection_activities' => __( 'Collection Activities', 'tainacan' ), 'title_collection_activities' => __( 'Collection Activities', 'tainacan' ),
'title_filter_page' => __( 'Filter', 'tainacan' ), 'title_filter_page' => __( 'Filter', 'tainacan' ),
'title_taxonomy_page' => __( 'Taxonomy', 'tainacan' ), 'title_taxonomy_page' => __( 'Taxonomy', 'tainacan' ),
'title_term_edition' => __( 'Term edition', 'tainacan' ), 'title_term_edit' => __( 'Term edit', 'tainacan' ),
'title_term_creation' => __( 'Create a new term', 'tainacan' ), 'title_term_creation' => __( 'Create a new term', 'tainacan' ),
'title_activity_page' => __( 'Activity', 'tainacan' ), 'title_activity_page' => __( 'Activity', 'tainacan' ),
'title_create_collection' => __( 'Collection Creation', 'tainacan' ), 'title_create_collection' => __( 'Collection Creation', 'tainacan' ),
@ -135,11 +135,11 @@ return apply_filters( 'tainacan-i18n', [
'title_create_filter' => __( 'Filter Creation', 'tainacan' ), 'title_create_filter' => __( 'Filter Creation', 'tainacan' ),
'title_collection_settings' => __( 'Settings of Collection', 'tainacan' ), 'title_collection_settings' => __( 'Settings of Collection', 'tainacan' ),
'title_edit_item' => __( 'Edit Item', 'tainacan' ), 'title_edit_item' => __( 'Edit Item', 'tainacan' ),
'title_taxonomy_edition_page' => __( 'Taxonomy Edition', 'tainacan' ), 'title_taxonomy_edit_page' => __( 'Edit Taxonomy', 'tainacan' ),
'title_filter_edition' => __( 'Filter Edition', 'tainacan' ), 'title_filter_edit' => __( 'Edit Filter', 'tainacan' ),
'title_metadatum_edition' => __( 'Metadata Edition', 'tainacan' ), 'title_metadatum_edit' => __( 'Edit Metadata', 'tainacan' ),
'title_collection_metadata_edition' => __( 'Edit Metadata of', 'tainacan' ), 'title_collection_metadata_edit' => __( 'Edit Metadata of', 'tainacan' ),
'title_collection_filters_edition' => __( 'Edit Filters of', 'tainacan' ), 'title_collection_filters_edit' => __( 'Edit Filters of', 'tainacan' ),
'title_importer_page' => __( 'Importer', 'tainacan' ), 'title_importer_page' => __( 'Importer', 'tainacan' ),
'title_importer_mapping_page' => __( "Metadata Mapping", 'tainacan' ), 'title_importer_mapping_page' => __( "Metadata Mapping", 'tainacan' ),
'title_importers_page' => __( 'Importers', 'tainacan' ), 'title_importers_page' => __( 'Importers', 'tainacan' ),
@ -824,7 +824,7 @@ return apply_filters( 'tainacan-i18n', [
'info_bulk_add_items' => __( 'Bulk add documents from your computer as items.', 'tainacan' ), 'info_bulk_add_items' => __( 'Bulk add documents from your computer as items.', 'tainacan' ),
'info_editing_items_in_bulk' => __( 'Bulk edit items', 'tainacan' ), 'info_editing_items_in_bulk' => __( 'Bulk edit items', 'tainacan' ),
'info_by_inner' => __( 'by', 'tainacan' ), 'info_by_inner' => __( 'by', 'tainacan' ),
'info_bulk_edition_process_added' => __( 'Bulk edition added to process queue.', 'tainacan' ), 'info_bulk_edit_process_added' => __( 'Bulk edit added to process queue.', 'tainacan' ),
'info_no_parent_term_found' => __( 'No valid parent term was found with this name.', 'tainacan' ), 'info_no_parent_term_found' => __( 'No valid parent term was found with this name.', 'tainacan' ),
'info_warning_changing_parent_term' => __( 'Warning! Changing parent term will reload the terms list, thus unchecking any selection.', 'tainacan' ), 'info_warning_changing_parent_term' => __( 'Warning! Changing parent term will reload the terms list, thus unchecking any selection.', 'tainacan' ),
'info_warning_selected_items_remove_from_trash' => __( 'Do you really want to remove from trash the selected items?', 'tainacan' ), 'info_warning_selected_items_remove_from_trash' => __( 'Do you really want to remove from trash the selected items?', 'tainacan' ),
@ -834,7 +834,7 @@ return apply_filters( 'tainacan-i18n', [
'info_there_are_%s_items_being_edited' => __( 'There are %s items being edited;', 'tainacan' ), 'info_there_are_%s_items_being_edited' => __( 'There are %s items being edited;', 'tainacan' ),
'info_there_is_one_item_being_edited' => __( 'There is one item being edited.', 'tainacan' ), 'info_there_is_one_item_being_edited' => __( 'There is one item being edited.', 'tainacan' ),
'info_no_preview_found' => __( 'No preview was found.', 'tainacan' ), 'info_no_preview_found' => __( 'No preview was found.', 'tainacan' ),
'info_leaving_bulk_edition' => __( 'You are leaving the bulk edition now.', 'tainacan' ), 'info_leaving_bulk_edit' => __( 'You are leaving the bulk edit now.', 'tainacan' ),
'info_current_view_mode_metadata_not_allowed' => __( 'Current view mode does not allow displayed metadata selection.', 'tainacan' ), 'info_current_view_mode_metadata_not_allowed' => __( 'Current view mode does not allow displayed metadata selection.', 'tainacan' ),
'info_cant_select_metadata_without_items' => __( 'Can not select displayed metadata without items on list.', 'tainacan' ), 'info_cant_select_metadata_without_items' => __( 'Can not select displayed metadata without items on list.', 'tainacan' ),
'info_process_status_finished' => __( 'Finished', 'tainacan'), 'info_process_status_finished' => __( 'Finished', 'tainacan'),

View File

@ -327,7 +327,7 @@ class CompoundMetadatumTypes extends TAINACAN_UnitTestCase {
$this->assertTrue($newMetadatum->validate()); $this->assertTrue($newMetadatum->validate());
} }
function test_validations_metadada_order() { function test_validations_metadata_order() {
$Tainacan_Collections = \Tainacan\Repositories\Collections::get_instance(); $Tainacan_Collections = \Tainacan\Repositories\Collections::get_instance();
$collection = $this->tainacan_entity_factory->create_entity( $collection = $this->tainacan_entity_factory->create_entity(