From dc8331340fad874460c814af12c16c9b5617e4ae Mon Sep 17 00:00:00 2001 From: jsasg <735273025@qq.com> Date: Wed, 14 May 2025 14:29:18 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E6=96=B0=E5=93=81=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=98=AF=E5=90=A6=E6=96=B0=E5=93=81=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/index/controller/Product.php | 2 +- app/index/lang/en-us.php | 3 +++ app/index/lang/zh-cn.php | 3 +++ app/index/view/product/newpro.html | 6 +++--- 4 files changed, 10 insertions(+), 4 deletions(-) diff --git a/app/index/controller/Product.php b/app/index/controller/Product.php index f18ad2d8..12d914d2 100644 --- a/app/index/controller/Product.php +++ b/app/index/controller/Product.php @@ -367,7 +367,7 @@ class Product extends Common $newpros = []; // 获取新品上市产品 - $products = ProductModel::field(['id', 'category_id', 'name', 'spu', 'cover_image']) + $products = ProductModel::field(['id', 'category_id', 'name', 'spu', 'cover_image', 'is_new']) ->language($this->lang_id) ->enabled(true) ->onSale(true) diff --git a/app/index/lang/en-us.php b/app/index/lang/en-us.php index b3f5e7bd..e0452af2 100644 --- a/app/index/lang/en-us.php +++ b/app/index/lang/en-us.php @@ -164,6 +164,9 @@ return [ 'send_success' => 'Add Success!', 'send_fail' => 'Add Fail!', ], + 'product_newpro' => [ + 'view_all' => 'View all' + ], 'product_detail' => [ 'detail_section_title' => 'Product Description', 'related_products' => 'Related Products', diff --git a/app/index/lang/zh-cn.php b/app/index/lang/zh-cn.php index 4b3ae45d..a0f867e1 100644 --- a/app/index/lang/zh-cn.php +++ b/app/index/lang/zh-cn.php @@ -164,6 +164,9 @@ return [ 'send_success' => '信息已成功提交', 'send_fail' => '信息提交失败', ], + 'product_newpro' => [ + 'view_all' => '查看全部' + ], 'product_detail' => [ 'detail_section_title' => '产品详情', 'related_products' => '相关产品', diff --git a/app/index/view/product/newpro.html b/app/index/view/product/newpro.html index 6c75dc8a..23234747 100644 --- a/app/index/view/product/newpro.html +++ b/app/index/view/product/newpro.html @@ -17,25 +17,25 @@