-
1 去除DEFINER子句:
检 查 SQL 文件,去除下面类似的子句。
DEFINER=`root`@`%`
2。在 Linux 平台下,可以尝试使用下面的语句去除。
sed -e 's/DEFINER[ ]*=[ ]*[^*]*\*/\*/ ' your.sql > your_revised.sql3. 错这个错误 Storage engine MEMORY is disabled (Table creation is disallowed)
需要将 MEMORY 表类型转成InNodb
-
Magento2 价格,优惠格式bug, 当货币为中文,或日本,在设置优惠价格时,价格为几十时会显示:0,50或0,05的问题,改小数位置(vendor\magento\zendframework1\library\Zend\Locale\Data)对应的语言
这里去掉 小数位数 vendor\magento\module-catalog\view\base\web\js\
-
#开启维护模式 (teddy整理)
php bin/magento maintenance:enable
#关闭维护模式
php bin/magento maintenance:disable
#删除所有生成的静态文件
rm -rf pub/static/*
#删除前台生成的静态文件
rm -rf pub/static/frontend/Teddy/default/css
#删除后台生成的静态文件
rm -rf pub/static/adminhtml
#只删除后台生成的静态文件样式(css)
rm -rf pub/static/frontend/Teddy/default/en_US/css/*
rm -rf var/view_preprocessed/pub/static/frontend/Teddy/default/en_US/css/*
#删除缓存var后台生成的静态文件(和pub目录下一起操作)
rm -rf var/view_preprocessed
#只生成前台
php -dmemory_limit=1G bin/magento setup:static-content:deploy -f -t Teddy/default -a frontend
#只生后成台
php -dmemory_limit=1G bin/magento setup:static-content:deploy -f -a adminhtml
#带众多参数
php -dmemory_limit=5G bin/magento setup:static-content:deploy -f -t Teddy/default --content-version 1222216 --no-css --no-less
#清除缓存
php bin/magento cache:flush
#权限配置
chmod -R -
以前没注意这个情况,就是商品页面无故消失,后台 会员列表消失,等相关问题,这衫没注意索引,在索引时,发现了这个异常
说明提示这个 skipping 问题出现在数据表锁表的情况,正确的方式进行 bin/magento indexer reset 修复一下,即可
-
为了简化顾客在注册,操作下剤时的步骤,试着去掉lastname ,这里,首先跟据Magento 1.x 方式要去掉lastname 验证,在数据库中进行
UPDATE eav_attribute SET is_required = 0 WHERE attribute_code = ‘lastname’ 这个表有两条lastname 数据,这里要把 is_required 字段改为0
另外在Magento2 中找到vendor\magento\module-customer\Model\Customer.php 与 vendor\magento\module-customer\Model\Address\AbstractAddress.php
去掉相关lastname相关字段的判断即可,测试可以进行本站注册与下单
-
Magento2 后台添加商品报"theme_dir"错误(同时也有保存图片路径错误)
这里可以尝试
vendor/magento/framework/View/Design/Fallback/Rule/Simple.php.将这个段注释掉改为 return [];
//throw new \InvalidArgumentException("Required parameter '{$placeholder}' was not passed"); -
报错内容:Something went wrong while saving this configuration: Area is already set
修改
vendor/magento/module-email/Model/AbstractTemplate.phppublic function setForcedArea($templateId)
{
if ($this->area) {
throw new \LogicException(__('Area is already set'));
}
$this->area = $this->emailConfig->getTemplateArea($templateId);
return $this;}
to -
You did not sign in correctly or your account is temporarily disabled.
您没有正确登录,或者您的帐户暂时被禁用。 大概是这个意思,很无语,解决方式可以通过Magento2命令来新建一个管理员sudo php bin/magento admin:user:create --admin-user="teddy" --admin-password="magentoucd" --admin-email="[email protected]" --admin-firstname="Admin" --admin-lastname="Admin"
用户名为teddy密码magentoucd,这样用新的管理员登录即可
-
相关Magento 问题可以提交给我 QQ:4767850 我们会有Magento 2 ASK 问答视频中给大家进行统一回复 , 目录Magento 2 ASK 经过了10期,欢迎大家提问,我们尽可能帮助到每一个对Magento 感兴趣的朋友