fix: Rename 'Product' to 'Item'
diff --git a/erpnext/public/js/hub/PageContainer.vue b/erpnext/public/js/hub/PageContainer.vue
index ab270b9..cec4c8d 100644
--- a/erpnext/public/js/hub/PageContainer.vue
+++ b/erpnext/public/js/hub/PageContainer.vue
@@ -9,8 +9,8 @@
import Home from './pages/Home.vue';
import Search from './pages/Search.vue';
import Category from './pages/Category.vue';
-import SavedProducts from './pages/SavedProducts.vue';
-import PublishedProducts from './pages/PublishedProducts.vue';
+import SavedItems from './pages/SavedItems.vue';
+import PublishedItems from './pages/PublishedItems.vue';
import Item from './pages/Item.vue';
import Seller from './pages/Seller.vue';
import Publish from './pages/Publish.vue';
@@ -30,9 +30,9 @@
// Registered seller routes
'marketplace/profile': Profile,
- 'marketplace/saved-products': SavedProducts,
+ 'marketplace/saved-items': SavedItems,
'marketplace/publish': Publish,
- 'marketplace/my-products': PublishedProducts,
+ 'marketplace/published-items': PublishedItems,
'marketplace/buying': Buying,
'marketplace/buying/:item': Messages,
'marketplace/selling': Selling,
diff --git a/erpnext/public/js/hub/Sidebar.vue b/erpnext/public/js/hub/Sidebar.vue
index 7cb436e..cff580e 100644
--- a/erpnext/public/js/hub/Sidebar.vue
+++ b/erpnext/public/js/hub/Sidebar.vue
@@ -26,8 +26,8 @@
route: 'marketplace/home'
},
{
- label: __('Saved Products'),
- route: 'marketplace/saved-products',
+ label: __('Saved Items'),
+ route: 'marketplace/saved-items',
condition: () => this.hub_registered
},
{
@@ -36,12 +36,12 @@
condition: () => this.hub_registered
},
{
- label: __('Your Products'),
- route: 'marketplace/my-products',
+ label: __('Your Items'),
+ route: 'marketplace/published-items',
condition: () => this.hub_registered
},
{
- label: __('Publish Products'),
+ label: __('Publish Items'),
route: 'marketplace/publish',
condition: () => this.hub_registered
},
diff --git a/erpnext/public/js/hub/components/TimelineItem.vue b/erpnext/public/js/hub/components/TimelineItem.vue
index 97b5a0d..d13c842 100644
--- a/erpnext/public/js/hub/components/TimelineItem.vue
+++ b/erpnext/public/js/hub/components/TimelineItem.vue
@@ -3,7 +3,7 @@
<div class="media timeline-item notification-content">
<div class="small">
<i class="octicon octicon-bookmark fa-fw"></i>
- <span title="Administrator"><b>4 weeks ago</b> Published 1 product to Marketplace</span>
+ <span title="Administrator"><b>4 weeks ago</b> Published 1 item to Marketplace</span>
</div>
</div>
</template>
diff --git a/erpnext/public/js/hub/components/detail_view.js b/erpnext/public/js/hub/components/detail_view.js
index fca6a56..d80720c 100644
--- a/erpnext/public/js/hub/components/detail_view.js
+++ b/erpnext/public/js/hub/components/detail_view.js
@@ -94,7 +94,7 @@
</div>
<div class="row hub-item-description">
<h6 class="col-md-12 margin-top">
- <b class="text-muted">Product Description</b>
+ <b class="text-muted">Item Description</b>
</h6>
<p class="col-md-12">
${description ? description : __('No details')}
diff --git a/erpnext/public/js/hub/pages/Category.vue b/erpnext/public/js/hub/pages/Category.vue
index 2ffbcf3..3a0e6bf 100644
--- a/erpnext/public/js/hub/pages/Category.vue
+++ b/erpnext/public/js/hub/pages/Category.vue
@@ -18,7 +18,6 @@
<script>
export default {
- name: 'saved-products-page',
data() {
return {
page_name: frappe.get_route()[1],
@@ -27,7 +26,7 @@
item_id_fieldname: 'name',
// Constants
- empty_state_message: __(`No products in this category yet.`)
+ empty_state_message: __(`No items in this category yet.`)
};
},
computed: {
diff --git a/erpnext/public/js/hub/pages/Item.vue b/erpnext/public/js/hub/pages/Item.vue
index 5ce0bcf..d8e397d 100644
--- a/erpnext/public/js/hub/pages/Item.vue
+++ b/erpnext/public/js/hub/pages/Item.vue
@@ -60,7 +60,7 @@
action: this.add_to_saved_items
},
{
- label: __('Report this Product'),
+ label: __('Report this Item'),
condition: !this.is_own_item,
action: this.report_item
},
@@ -70,7 +70,7 @@
action: this.report_item
},
{
- label: __('Unpublish Product'),
+ label: __('Unpublish Item'),
condition: this.is_own_item,
action: this.report_item
}
@@ -170,7 +170,7 @@
this.sections = [
{
- title: __('Product Description'),
+ title: __('Item Description'),
content: this.item.description
? __(this.item.description)
: __('No description')
@@ -192,7 +192,7 @@
hub_seller: hub.settings.company_email
})
.then(() => {
- const saved_items_link = `<b><a href="#marketplace/saved-products">${__('Saved')}</a></b>`
+ const saved_items_link = `<b><a href="#marketplace/saved-items">${__('Saved')}</a></b>`
frappe.show_alert(saved_items_link);
erpnext.hub.trigger('action:item_save');
})
diff --git a/erpnext/public/js/hub/pages/Publish.vue b/erpnext/public/js/hub/pages/Publish.vue
index 0219fc9..b05f12a 100644
--- a/erpnext/public/js/hub/pages/Publish.vue
+++ b/erpnext/public/js/hub/pages/Publish.vue
@@ -34,7 +34,7 @@
>
</item-cards-container>
- <p class="text-muted">{{ valid_products_instruction }}</p>
+ <p class="text-muted">{{ valid_items_instruction }}</p>
<search-input
:placeholder="search_placeholder"
@@ -73,16 +73,16 @@
// Constants
// TODO: multiline translations don't work
- page_title: __('Publish Products'),
+ page_title: __('Publish Items'),
search_placeholder: __('Search Items ...'),
- empty_state_message: __(`No Items selected yet. Browse and click on products below to publish.`),
- valid_products_instruction: __(`Only products with an image and description can be published. Please update them if an item in your inventory does not appear.`),
+ empty_state_message: __(`No Items selected yet. Browse and click on items below to publish.`),
+ valid_items_instruction: __(`Only items with an image and description can be published. Please update them if an item in your inventory does not appear.`),
last_sync_message: (hub.settings.last_sync_datetime)
? __(`Last sync was
<a href="#marketplace/profile">
${comment_when(hub.settings.last_sync_datetime)}</a>.
- <a href="#marketplace/my-products">
- See your Published Products</a>.`)
+ <a href="#marketplace/published-items">
+ See your Published Items</a>.`)
: ''
};
},
@@ -93,14 +93,14 @@
publish_button_text() {
const number = this.selected_items.length;
- let text = 'Publish';
+ let text = __('Publish');
if(number === 1) {
- text = 'Publish 1 Product';
+ text = __('Publish 1 Item');
}
if(number > 1) {
- text = `Publish ${number} Products`;
+ text = __('Publish {0} Items', [number]);
}
- return __(text);
+ return text;
},
items_dict() {
@@ -150,8 +150,8 @@
this.last_sync_message = __(`Last sync was
<a href="#marketplace/profile">
${comment_when(hub.settings.last_sync_datetime)}</a>.
- <a href="#marketplace/my-products">
- See your Published Products</a>.`);
+ <a href="#marketplace/published-items">
+ See your Published Items</a>.`);
},
clear_last_sync_message() {
diff --git a/erpnext/public/js/hub/pages/PublishedProducts.vue b/erpnext/public/js/hub/pages/PublishedItems.vue
similarity index 93%
rename from erpnext/public/js/hub/pages/PublishedProducts.vue
rename to erpnext/public/js/hub/pages/PublishedItems.vue
index 1da5ffb..114259b 100644
--- a/erpnext/public/js/hub/pages/PublishedProducts.vue
+++ b/erpnext/public/js/hub/pages/PublishedItems.vue
@@ -35,7 +35,6 @@
<script>
export default {
- name: 'saved-products-page',
data() {
return {
page_name: frappe.get_route()[1],
@@ -54,7 +53,7 @@
publish_button_text: __('Publish More Items'),
published_items_message: __('You can publish upto 200 items.'),
// TODO: Add empty state action
- empty_state_message: __(`You haven't published any products yet. Publish.`)
+ empty_state_message: __('You haven\'t published any items yet.')
};
},
created() {
diff --git a/erpnext/public/js/hub/pages/SavedProducts.vue b/erpnext/public/js/hub/pages/SavedItems.vue
similarity index 88%
rename from erpnext/public/js/hub/pages/SavedProducts.vue
rename to erpnext/public/js/hub/pages/SavedItems.vue
index ddcbcdc..e5d21cd 100644
--- a/erpnext/public/js/hub/pages/SavedProducts.vue
+++ b/erpnext/public/js/hub/pages/SavedItems.vue
@@ -20,7 +20,7 @@
<script>
export default {
- name: 'saved-products-page',
+ name: 'saved-items-page',
data() {
return {
page_name: frappe.get_route()[1],
@@ -28,8 +28,8 @@
item_id_fieldname: 'name',
// Constants
- page_title: __('Saved Products'),
- empty_state_message: __(`You haven't favourited any items yet.`)
+ page_title: __('Saved Items'),
+ empty_state_message: __(`You haven't saved any items yet.`)
};
},
created() {
@@ -76,12 +76,12 @@
setTimeout(() => {
if(!reverted) {
- this.remove_item_from_saved_products(hub_item_name);
+ this.remove_item_from_saved_items(hub_item_name);
}
}, grace_period);
},
- remove_item_from_saved_products(hub_item_name) {
+ remove_item_from_saved_items(hub_item_name) {
erpnext.hub.trigger('action:item_save');
hub.call('remove_item_from_seller_saved_items', {
hub_item_name,
diff --git a/erpnext/public/js/hub/pages/Search.vue b/erpnext/public/js/hub/pages/Search.vue
index 809f8c2..5118a81 100644
--- a/erpnext/public/js/hub/pages/Search.vue
+++ b/erpnext/public/js/hub/pages/Search.vue
@@ -25,7 +25,6 @@
<script>
export default {
- name: 'saved-products-page',
data() {
return {
page_name: frappe.get_route()[1],
@@ -42,7 +41,7 @@
page_title() {
return this.items.length
? __(`Results for "${this.search_value}"`)
- : __(`No Products found.`);
+ : __('No Items found.');
}
},
created() {
diff --git a/erpnext/public/js/hub/pages/Seller.vue b/erpnext/public/js/hub/pages/Seller.vue
index 86d75b8..c80865b 100644
--- a/erpnext/public/js/hub/pages/Seller.vue
+++ b/erpnext/public/js/hub/pages/Seller.vue
@@ -61,7 +61,7 @@
},
computed: {
item_container_heading() {
- return __('Products by ' + this.seller_company);
+ return __('Items by ' + this.seller_company);
}
},
methods: {
diff --git a/erpnext/public/js/hub/pages/item.js b/erpnext/public/js/hub/pages/item.js
index cbbdfcf..50b04b8 100644
--- a/erpnext/public/js/hub/pages/item.js
+++ b/erpnext/public/js/hub/pages/item.js
@@ -48,7 +48,7 @@
edit_details() {
if (!this.edit_dialog) {
this.edit_dialog = new frappe.ui.Dialog({
- title: "Edit Your Product",
+ title: "Edit Your Item",
fields: []
});
}
@@ -59,7 +59,7 @@
unpublish_item() {
if (!this.unpublish_dialog) {
this.unpublish_dialog = new frappe.ui.Dialog({
- title: "Edit Your Product",
+ title: "Edit Your Item",
fields: []
});
}