From c56611a6ee4dc4ed409206c7420a1865c72f0502 Mon Sep 17 00:00:00 2001 From: liuyi Date: Mon, 1 Jun 2020 22:26:04 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E5=8F=91=E9=80=81=E7=9F=AD=E4=BF=A1?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E8=85=BE=E8=AE=AF=E4=BA=91=E7=9F=AD=E4=BF=A1?= =?UTF-8?q?=E6=9C=8D=E5=8A=A1=E5=92=8C=E9=98=BF=E9=87=8C=E4=BA=91=E7=9F=AD?= =?UTF-8?q?=E4=BF=A1=E6=9C=8D=E5=8A=A1=EF=BC=9B=20=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E5=BA=93=E9=85=8D=E7=BD=AE=E6=96=87=E4=BB=B6=E5=90=8C=E6=97=B6?= =?UTF-8?q?=E5=8A=A0=E5=85=A52=E4=B8=AA=E5=AD=97=E6=AE=B5=EF=BC=8C?= =?UTF-8?q?=E4=BB=A5=E6=94=AF=E6=8C=81=E6=9C=AC=E6=AC=A1=E4=BF=AE=E6=94=B9?= =?UTF-8?q?=EF=BC=9A=20(160,=20'aliyun',=20'=E7=9F=AD=E4=BF=A1=E5=B9=B3?= =?UTF-8?q?=E5=8F=B0',=20'=E9=80=89=E6=8B=A9=E4=BD=BF=E7=94=A8=E7=9A=84?= =?UTF-8?q?=E7=9F=AD=E4=BF=A1=E5=B9=B3=E5=8F=B0',=20'=E8=AF=B7=E7=A1=AE?= =?UTF-8?q?=E8=AE=A4=E4=BD=BF=E7=94=A8=E7=9A=84=E9=85=8D=E7=BD=AE=E6=98=AF?= =?UTF-8?q?=E9=80=82=E5=90=88=E5=BD=93=E5=89=8D=E6=89=80=E9=80=89=E7=9F=AD?= =?UTF-8?q?=E4=BF=A1=E5=B9=B3=E5=8F=B0=E7=9A=84=E3=80=82',=20'common',=20'?= =?UTF-8?q?common=5Fsms=5Fplatform',=201590335998),=20(161,=20'',=20'?= =?UTF-8?q?=E7=9F=AD=E4=BF=A1=E5=B9=B3=E5=8F=B0APP=5FID',=20'=E8=85=BE?= =?UTF-8?q?=E8=AE=AF=E4=BA=91=E5=BF=85=E5=A1=AB=E5=AD=97=E6=AE=B5=EF=BC=8C?= =?UTF-8?q?=E5=8F=AF=E4=BB=A5=E5=9C=A8=E8=85=BE=E8=AE=AF=E4=BA=91/?= =?UTF-8?q?=E7=9F=AD=E4=BF=A1/=E5=BA=94=E7=94=A8=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E6=89=BE=E5=88=B0',=20'=E8=85=BE=E8=AE=AF=E4=BA=91=E5=BF=85?= =?UTF-8?q?=E9=A1=BB=E5=A1=AB=E5=86=99=E6=AD=A4=E5=AD=97=E6=AE=B5',=20'com?= =?UTF-8?q?mon',=20'common=5Fsms=5Fsdk=5Fappid',=201590335998)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/admin/controller/Sms.php | 2 + application/admin/lang/zh-cn.php | 7 + application/admin/view/default/sms/index.html | 18 ++ config/shopxo.sql | 2 +- extend/base/AliyunSms.php | 190 +++++++++++++ extend/base/Sms.php | 148 ++-------- extend/base/TencentSms.php | 267 ++++++++++++++++++ 7 files changed, 511 insertions(+), 123 deletions(-) create mode 100755 extend/base/AliyunSms.php create mode 100755 extend/base/TencentSms.php diff --git a/application/admin/controller/Sms.php b/application/admin/controller/Sms.php index 504243979..afcf32793 100755 --- a/application/admin/controller/Sms.php +++ b/application/admin/controller/Sms.php @@ -55,6 +55,8 @@ class Sms extends Common // 导航 $type = input('type', 'sms'); $this->assign('nav_type', $type); + $this->assign('sms_platform_list', lang('sms_platform_list')); + if($type == 'sms') { return $this->fetch('index'); diff --git a/application/admin/lang/zh-cn.php b/application/admin/lang/zh-cn.php index 919b80ac3..01106cc15 100755 --- a/application/admin/lang/zh-cn.php +++ b/application/admin/lang/zh-cn.php @@ -126,5 +126,12 @@ return array( 'type' => 'string', ], ], + + // 短信平台列表 + 'sms_platform_list' => array( + 0 => array('value' => '', 'name' => '请选择短信平台', 'checked' => true), + 1 => array('value' => 'aliyun', 'name' => '阿里云短信服务'), + 2 => array('value' => 'tencent', 'name' => '腾讯云短信服务'), + ), ); ?> \ No newline at end of file diff --git a/application/admin/view/default/sms/index.html b/application/admin/view/default/sms/index.html index 896958daf..a5e4e97df 100755 --- a/application/admin/view/default/sms/index.html +++ b/application/admin/view/default/sms/index.html @@ -21,6 +21,24 @@ + + +
+ + +
+ +
+ + +
+ + +
diff --git a/config/shopxo.sql b/config/shopxo.sql index c37839f96..ddf3c6822 100644 --- a/config/shopxo.sql +++ b/config/shopxo.sql @@ -317,7 +317,7 @@ CREATE TABLE `s_config` ( -- Records of `s_config` -- ---------------------------- BEGIN; -INSERT INTO `s_config` VALUES ('15', '10', '分页数量', '分页显示数量', '分页不能超过3位数', 'admin', 'admin_page_number', '1587366387'), ('59', '1', '扣减库存规则', '需扣减库存开启方可有效,默认订单支付成功', '', 'common', 'common_deduction_inventory_rules', '1589032774'), ('60', '1', '是否扣减库存', '建议不要随意修改,以免造成库存数据错乱,关闭不影响库存回滚', '', 'common', 'common_is_deduction_inventory', '1589032774'), ('11', '0', 'Excel编码', 'excel模块编码选择', '请选择编码', 'admin', 'admin_excel_charset', '1587366387'), ('16', 'ShopXO企业级B2C电商系统提供商 - 演示站点', '站点标题', '浏览器标题,一般不超过80个字符', '站点标题不能为空', 'home', 'home_seo_site_title', '1585733314'), ('17', '商城系统,开源电商系统,免费电商系统,PHP电商系统,商城系统,B2C电商系统,B2B2C电商系统', '站点关键字', '一般不超过100个字符,多个关键字以半圆角逗号 [ , ] 隔开', '站点关键字不能为空', 'home', 'home_seo_site_keywords', '1585733314'), ('18', 'ShopXO是国内领先的商城系统提供商,为企业提供php商城系统、微信商城、小程序。', '站点描述', '站点描述,一般不超过200个字符', '站点描述不能为空', 'home', 'home_seo_site_description', '1585733314'), ('19', '', 'ICP证书号', 'ICP域名备案号', '', 'home', 'home_site_icp', '1572944120'), ('20', '', '底部统计代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_statistics_code', '0'), ('21', '1', '站点状态', '可暂时将站点关闭,其他人无法访问,但不影响管理员访问后台', '请选择站点状态', 'home', 'home_site_state', '1581399671'), ('22', '升级中...', '关闭原因', '支持html,当网站处于关闭状态时,关闭原因将显示在前台', '', 'home', 'home_site_close_reason', '1581399671'), ('23', 'Australia/Eucla', '默认时区', '默认 亚洲/上海 [标准时+8]', '请选择默认时区', 'common', 'common_timezone', '1581399671'), ('24', '', '底部代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_footer_info', '1581399671'), ('28', 'ShopXO', '站点名称', '', '站点名称不能为空', 'home', 'home_site_name', '1581399671'), ('29', '0', '链接模式', '详情ThinkPHP官网5.1版本文档 [http://www.thinkphp.cn/]', '请选择url模式', 'home', 'home_seo_url_model', '1585733314'), ('25', '2048000', '图片最大限制', '单位B [上传图片还受到服务器空间PHP配置最大上传 20M 限制]', '请填写图片上传最大限制', 'home', 'home_max_limit_image', '1558074966'), ('26', '51200000', '文件最大限制', '单位B [上传文件还受到服务器空间PHP配置最大上传 20M 限制]', '请填写文件上传最大限制', 'home', 'home_max_limit_file', '1558074966'), ('27', '102400000', '视频最大限制', '单位B [上传视频还受到服务器空间PHP配置最大上传 20M 限制]', '请填写视频上传最大限制', 'home', 'home_max_limit_video', '1558074966'), ('30', 'html', '伪静态后缀', '链接后面的后缀别名,默认 [ html ]', '小写字母,不能超过8个字符', 'home', 'home_seo_url_html_suffix', '1585733314'), ('31', '0', '用户注册开启审核', '开启后用户注册需要审核通过方可登录', '请选择用户注册开启审核', 'common', 'common_register_is_enable_audit', '1566227415'), ('32', '/static/upload/images/common/2019/01/14/1547448748316693.png', '手机端logo', '支持 [jpg, png, gif]', '请上传手机端网站logo', 'home', 'home_site_logo_wap', '1581399671'), ('33', '/static/upload/images/common/2019/01/14/1547448705165706.png', '电脑端logo', '支持 [jpg, png, gif]', '请上传电脑端网站logo', 'home', 'home_site_logo', '1581399671'), ('34', '1200', '页面最大宽度', '页面最大宽度,单位px,0则100%', '请上传桌面图标', 'home', 'home_content_max_width', '1581399671'), ('35', '/static/upload/images/common/2019/01/14/1547448728921121.jpg', '桌面图标', '建议使用png格式', '图片比例值格式有误 0~100 之间,小数点后面最大两位', 'common', 'home_site_desktop_icon', '1581399671'), ('36', 'sms,email,username', '是否开启注册', '关闭注册后,前端站点将无法注册,可选择 [ 短信, 邮箱, 用户名 ]', '请选择是否开启注册状态', 'home', 'home_user_reg_state', '1566227415'), ('37', '1', '是否开启登录', '关闭后,前端站点将无法登录', '请选择是否开启登录状态', 'home', 'home_user_login_state', '1558084931'), ('38', '1', '获取验证码-开启图片验证码', '防止短信轰炸', '请选择是否开启强制图片验证码', 'home', 'home_img_verify_state', '1558085166'), ('39', '60', '获取验证码时间间隔', '防止频繁获取验证码,一般在 30~120 秒之间,单位 [秒]', '请填写获取验证码时间间隔', 'home', 'common_verify_time_interval', '1558085166'), ('40', '', '用户注册-短信模板ID', '验证码code', '请填写用户注册短信模板内容', 'home', 'home_sms_user_reg', '1587366205'), ('41', '', '短信签名', '发送短信包含的签名', '短信签名 3~8 个的中英文字符', 'common', 'common_sms_sign', '1587366196'), ('42', '', '短信KeyID', 'Access Key ID', '请填写Access Key ID', 'common', 'common_sms_apikey', '1587366196'), ('43', '', '密码找回-短信模板ID', '验证码code', '请填写密码找回短信模板内容', 'home', 'home_sms_user_forget_pwd', '1587366205'), ('44', '600', '验证码有效时间', '验证码过期时间,一般10分钟左右,单位 [秒]', '请填写验证码有效时间', 'home', 'common_verify_expire_time', '1558085166'), ('45', '', 'SMTP服务器', '设置SMTP服务器的地址,如 smtp.163.com', '请填写SMTP服务器', 'common', 'common_email_smtp_host', '1580643917'), ('46', '', 'SMTP端口', '设置SMTP服务器的端口,默认为 25', '请填写SMTP端口号', 'common', 'common_email_smtp_port', '1580643917'), ('47', '', '发信人邮件地址', '发信人邮件地址,使用SMTP协议发送的邮件地址,如 shopxo@163.com', '请填写发信人邮件地址', 'common', 'common_email_smtp_account', '1580643917'), ('48', '', 'SMTP身份验证用户名', '如 shopxo@163.com', '请填写SMTP身份验证用户名', 'common', 'common_email_smtp_name', '1580643917'), ('49', '', 'SMTP身份验证密码', 'shopxo@163.com邮件的密码或授权码', '请填写SMTP身份验证密码', 'common', 'common_email_smtp_pwd', '1580643917'), ('50', '', '发件人显示名称', '如 ShopXO', '', 'common', 'common_email_smtp_send_name', '1580643917'), ('51', '', '通用-短信模板ID', '验证码code', '请填写通用短信模板内容', 'common', 'common_sms_currency_template', '1587366205'), ('58', '', '短信KeySecret', 'Access Key Secret', '请填写Access Key Secret', 'common', 'common_sms_apisecret', '1587366196'), ('53', '021-88888888', '商店电话', '空则不显示', '', 'common', 'common_customer_store_tel', '1587138005'), ('56', '

通用模板,你的验证码是  #code#

', '通用-邮件模板', '验证码变量标识符 [ #code# ]', '', 'common', 'common_email_currency_template', '1557728601'), ('57', 'default', '默认模板', '前台默认模板', '请填写默认模板', 'common', 'common_default_theme', '1550113393'), ('62', '', '百度地图api密钥', '百度地图api密钥', '请填写百度地图api密钥', 'common', 'common_baidu_map_ak', '1587366387'), ('63', '

用户注册,你的验证码是  #code#

', '用户注册-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_reg', '1557728601'), ('64', '

密码找回,你的验证码是  #code#

', '密码找回-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_forget_pwd', '1557728601'), ('65', '

邮箱绑定,你的验证码是  #code#

', '邮箱绑定-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_email_binding', '1557728601'), ('66', '20200202', 'css/js版本标记', '用于css/js浏览器缓存版本识别', '', 'home', 'home_static_cache_version', '1581399671'), ('67', '', '手机号码绑定-短信模板ID', '验证码code', '请填写手机号码绑定短信模板内容', 'home', 'home_sms_user_mobile_binding', '1587366205'), ('68', '连衣裙,帐篷,iphone,包包', '搜索关键字', '搜索框下热门关键字(输入回车)', '请填写关键字', 'home', 'home_search_keywords', '1566227458'), ('69', '2', '搜索关键字类型', '自定义需要配置以下关键字', '请选择关键字类型', 'home', 'home_search_keywords_type', '1566227458'), ('70', '0', '订单预约模式', '开启后用户提交订单需要管理员确认', '请选择是否开启预约模式', 'common', 'common_order_is_booking', '1589032774'), ('71', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_alipay_title', '1586248646'), ('72', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_alipay_describe', '1586248646'), ('73', '021-88888888', '客服电话', '空则不显示', '请填写客服电话', 'common', 'common_app_customer_service_tel', '1580643961'), ('74', '2019081966311589', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_alipay_appid', '1586248646'), ('75', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuxAXbZitfaALDaevrWVITveMu2fh3L8t3p/5WGPNEVOqCnL3v8EeYZWOLSuBHhpJaLb7Q3HrPWynzpcJ2C17+DxCVS3Js8J/iAgiJGJB4f8wZuPBwqKncGXdrAtN6EYp3H9K1IQeCmGN9di4Ht7igDDREnVWrUIc1Q6O64KDg8YLhWaTf2FMFvdPKiH9tijIZuvtYxxOUkHmgG6N7+IIvKPLdYde0dt/eTy6L1wbXSWoStfmFYd38vywt51N6AlChh/XAQmUGYTq1sW+PFXg2MrDyyWIEZxGb1dINhlMgXMqxTropo31kXa09vUffNvPWVmR38iT9lY+n6ZWSVzH3QIDAQAB', '应用公钥', '', '请填写应用公钥', 'common', 'common_app_mini_alipay_rsa_public', '1586248646'), ('76', 'MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQC7EBdtmK19oAsNp6+tZUhO94y7Z+Hcvy3en/lYY80RU6oKcve/wR5hlY4tK4EeGklotvtDces9bKfOlwnYLXv4PEJVLcmzwn+ICCIkYkHh/zBm48HCoqdwZd2sC03oRincf0rUhB4KYY312Lge3uKAMNESdVatQhzVDo7rgoODxguFZpN/YUwW908qIf22KMhm6+1jHE5SQeaAbo3v4gi8o8t1h17R2395PLovXBtdJahK1+YVh3fy/LC3nU3oCUKGH9cBCZQZhOrWxb48VeDYysPLJYgRnEZvV0g2GUyBcyrFOuimjfWRdrT29R98289ZWZHfyJP2Vj6fplZJXMfdAgMBAAECggEAXXHCYkscj169ZsrXZUTtBBWBRbS1DTKrVUSQqGjibb9fd+zKeg2cgZ7V8RaEX2c+OIL/rUdg/cQjZ33nuwetn+lqMWa4FYYZcvitJYO36Y8yvJMVnYbnIayhOWpENr2l97HWzaZZ41GsOp1SDInGl8bLCe93pwEZqgyltFv0GoSfNu3trFFxPZgZJalV0t5M7+RchutkHskwrwI9BdnCJs38lh08jHHppQdkgcpyCiCdu/b4f+n9z97Op5Va8WY1M+wwqRk76Ias8mqwJXT/+t/sXhqkMv1ylAb89+b3rgiOU7KlZMpIAercW/ZRojnDjpY9ViaCxwWPwb/VkPrDgQKBgQDkDuie0DAIDP5C74dPj/Z0mapsU9bKlcgC+nowEUaEO7A9cwMVFal0x9p7BKIJsV2b6d1qJGP7rM9YtRMldJQmuxPcHOKPcZR8pGLqFYT2QGKGurohb/o+btGda/SGwJfi6jwQUF0AE+1k+Dj9P3hDxHgkj6ZMkHEBtqUj520VTQKBgQDR+1rPPex8zTQgl9uSY0hlXPyYEhpXicNhzyet1Su+TV8wdGNUr2YeuDHEu6oiRocBaT8DEwpy9EToe56EK3Ht2AQ76NBSUp9EOl1twocebM42etJSJZGpB1AgP+R/hmUbcBPXEwXdy5XeYnYmpVUcoizzKrnRDxg3TRF3kIX00QKBgGc49EMFmefa8a6cOdNiJrvp3YBAhkSVfL0UX/+nohIx7fgyOV/uuQ9ZceMiWrEmbWcneAcVx4dfVU4iTzMxy+in3jpPfKBOWVX9FaQ77z2CMNYoaBzAUTS29ftZpIjlXRngySTdKurhGh8MVscRVj7eCz8JIc0fx3ZuE9rnYbE1AoGAJoqJL3LBPmL3x2e4IJVii2BW6J6iASFDIGfCc7Cl18chyqYCOV/8UXUjhWWgo6voScUEkM7k4xacs0NFZCMJRUuZ81kXK5UIsKA519SVsmrsKqm+gt9sbebuuQyhJxsG4dNfgOF3+S7N8kSGRS+hgKDvuS5Fbu7jVfsqUpTPUZECgYAcbq3mqWwExY2Kn0I660OqOFk620pGsSY7gECUQintCZioYemzC1TN9pM6fKnOIYriV4Ou7iswhEfVX+5bwMjH2ujmu8KDdpkpdhRoFCw3GUn/PDelQrptaKkKXnOIJe/R8m+TUxYCtECTlKlYS4hTst7YhTDz5sQHcXRtveATZQ==', '应用私钥', '', '请填写应用私钥', 'common', 'common_app_mini_alipay_rsa_private', '1586248646'), ('78', '0', '是否启用搜索', '默认否', '', 'common', 'common_app_is_enable_search', '1580559058'), ('77', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAkwpOGFOJ0GF6vN9k2dih7Up4+0qecYGtGeZMLdkArDMQ3vgvZFyjAM8c6uFRCHfVoUF5mflVVskLaXMH9C3VY80fxE40WM3VXVW+z0M+WFdihmfB6m/xKpN0QkMVEce7yb7AyXAdNA20KKyjVKXAnDGU3nGc6grQ6uzNIp/Eb8jMPv91GOjzY8KYOxgSiVVM9p5Y1NedGBTQGeMWcRH5vi9ys2Ia0KDYtxuXDhIxMDAqrCNy5sODh0DUpTL+Di09jQRmdI9JNN79ibVmrBoU7ud8YbL/lR4iVT+zF848+OmJiK56yTLcxY8vrU2kGlGO2K8jKWDsOK93H0GF/+lA+wIDAQAB', '支付宝公钥', '', '请填写支付宝公钥', 'common', 'common_app_mini_alipay_out_rsa_public', '1586248646'), ('79', '0', '是否启用留言', '默认否', '', 'common', 'common_app_is_enable_answer', '1580559058'), ('80', '3', '商品可添加规格最大数量', '建议不超过3个规格', '请填写谷歌最大数', 'common', 'common_spec_add_max_number', '1587366387'), ('81', '-', '路由分隔符', '建议填写 [ - ] 默认 [ - ] ,仅PATHINFO模式+短地址模式下有效', '请填写路由分隔符', 'common', 'common_route_separator', '1585733314'), ('82', 'wx0a2012ebad94beff', 'AppID', '小程序ID', '请填写appid', 'common', 'common_app_mini_weixin_appid', '1581478933'), ('83', 'd0e4e81180ea59b8fcc4299f6b05b362', 'AppSecret ', '小程序密钥', '请填写appsecret', 'common', 'common_app_mini_weixin_appsecret', '1581478933'), ('84', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_weixin_title', '1581478933'), ('85', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_weixin_describe', '1581478933'), ('61', '用户中心公告文字,后台配置修改。', '用户中心公告', '空则不显示公告', '', 'common', 'common_user_center_notice', '1580643961'), ('8', '公告内容', '商城公告', '空则不显示公告', '', 'common', 'common_shop_notice', '1580643961'), ('86', 'test@qq.com', '商店邮箱', '空则不显示', '客服邮箱格式有误', 'common', 'common_customer_store_email', '1587138005'), ('87', '', '商店二维码', '空则不展示', '', 'common', 'common_customer_store_qrcode', '1587366387'), ('152', '[{\"alias\":\"总部\",\"name\":\"devil\",\"tel\":\"13222333333\",\"lng\":\"121.594278\",\"lat\":\"31.207917\",\"address\":\"张江高科\",\"province\":\"9\",\"city\":\"155\",\"county\":\"1937\",\"province_name\":\"上海市\",\"city_name\":\"浦东新区\",\"county_name\":\"张江镇\",\"id\":0}]', '自提点地址', '', '请填写自提点地址', 'common', 'common_self_extraction_address', '1589032774'), ('88', '上海市 浦东新区', '商店地址', '空则不展示', '', 'common', 'common_customer_store_address', '1587138005'), ('89', '

用户注册协议


', '用户注册协议', '最多 105000 个字符', '用户注册协议最多 105000 个字符', 'common', 'common_agreement_userregister', '1566227622'), ('90', '/static/upload/images/common/2019/05/17/1558025141249118.png', '用户注册背景图片', '', '请上传用户注册背景图片', 'home', 'home_site_user_register_bg_images', '1566227415'), ('91', '/static/upload/images/common/2019/05/17/1558062481107570.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad1_images', '1558084931'), ('92', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad2_images', '1558084931'), ('93', '/static/upload/images/common/2019/05/17/1558073623385520.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad3_images', '1558084931'), ('94', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad1_url', '1558084931'), ('95', 'https://ask.shopxo.net/', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad2_url', '1558084931'), ('96', 'https://shopxo.net/vip.html', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad3_url', '1558084931'), ('97', '', '背景色', '背景色1', '', 'home', 'home_site_user_login_ad1_bg_color', '1558084931'), ('98', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_login_ad2_bg_color', '1558084931'), ('99', '#FAFAFA', '背景色', '背景色3', '', 'home', 'home_site_user_login_ad3_bg_color', '1558084931'), ('100', '1', '登录图片验证码', '可以防止非法登录', '请选择是否开启登录图片验证码', 'home', 'home_user_login_img_verify_state', '1558084931'), ('101', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad1_images', '1558084915'), ('102', '/static/upload/images/common/2019/05/17/1558073623641199.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad2_images', '1558084915'), ('103', '', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad3_images', '1558084915'), ('104', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad1_url', '1558084915'), ('105', '', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad2_url', '1558084915'), ('106', '', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad3_url', '1558084915'), ('107', '#FAFAFA', '背景色', '背景色1', '', 'home', 'home_site_user_forgetpwd_ad1_bg_color', '1558084915'), ('108', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_forgetpwd_ad2_bg_color', '1558084915'), ('109', '', '背景色', '背景色3', '', 'home', 'home_site_user_forgetpwd_ad3_bg_color', '1558084915'), ('110', '1', '用户注册图片验证码', '可以防止非法注册', '请选择是否开启用户注册图片验证码', 'home', 'home_user_register_img_verify_state', '1566227415'), ('111', '', '图片验证码规则', '默认白底黑字,可根据需求i加大验证码识别难度', '', 'common', 'common_images_verify_rules', '1558085166'), ('112', '0', 'SSL方式加密', '', '请选择是否使用SSL方式加密', 'common', 'common_email_is_use_ssl', '1580643917'), ('113', '活动/优惠未生效\n空包裹\n包裹丢失\n配送超时\n未按约定时间发货\n未送货上门\n物流显示签收但实际未收到货\n不喜欢/不想要', '仅退款原因', '可换行,一行一个', '请填写仅退款原因', 'home', 'home_order_aftersale_return_only_money_reason', '1570193301'), ('114', '7天无理由退换货\n配送超时\n未按约定时间发货\n未送货上门\n卖家发错货\n少件/漏发\n包装/商品破损/污渍\n商品信息描述不符\n使用后过敏\n已过/临近保质期\n无法溶解/结块/有异物', '退货退款原因', '可换行,一行一个', '请填写退货退款原因', 'home', 'home_order_aftersale_return_money_goods_reason', '1570193301'), ('115', '1', '用户注册协议', '', '请选择是否启用用户注册协议', 'home', 'home_is_enable_userregister_agreement', '1566227415'), ('116', '上海市 浦东新区', '退货地址', '用户退货货物收货地址', '请填写退货地址', 'home', 'home_order_aftersale_return_goods_address', '1570193301'), ('117', '0', '使用独立手机详情', '默认使用web详情', '请选择使用独立手机详情', 'common', 'common_app_is_use_mobile_detail', '1580559058'), ('118', '0', '强制绑定手机', '默认否', '请选择是否强制绑定手机', 'common', 'common_user_is_mandatory_bind_mobile', '1580559058'), ('121', '0', '固定顶部导航', '默认否', '请选择是否固定顶部导航', 'common', 'common_app_is_header_nav_fixed', '1580559058'), ('122', '0', '开启在线客服', '默认否', '请选择是否开启在线客服', 'common', 'common_app_is_online_service', '1580559058'), ('123', '0', '启用限时秒杀', '默认否', '请选择是否启用限时秒杀', 'common', 'common_app_is_limitedtimediscount', '1580559058'), ('124', '0', '启用好物推荐', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用好物推荐', 'common', 'common_app_is_good_thing', '1587445586'), ('125', '16634987', 'AppID', '智能小程序ID', '请填写AppID', 'common', 'common_app_mini_baidu_appid', '1586249578'), ('126', 'C9Gg744cBqQ3zvbC5uOPMg9yWpmuQ8O7', 'AppKey', '智能小程序KEY', '请填写AppKey', 'common', 'common_app_mini_baidu_appkey', '1586249578'), ('127', 'KmdPEyuSAXcbiouKVq6LOSUjctZpxmNb', 'AppSecret', '智能小程序密匙', '请填写AppSecret', 'common', 'common_app_mini_baidu_appsecret', '1586249578'), ('128', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_baidu_title', '1586249578'), ('129', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_baidu_describe', '1586249578'), ('130', '0', '留言需要登录', '默认否', '请选择是否留言需要登录', 'common', 'common_is_login_answer', '1566124965'), ('131', '0', '启用海报分享', '默认否\n', '请选择是否启用海报分享\n', 'common', 'common_app_is_poster_share', '1587445586'), ('132', '30', '订单关闭脚本时长', '单位 分钟,默认30分钟', '请填写订单关闭脚本时长', 'common', 'common_order_close_limit_time', '1566124965'), ('133', '21600', '订单自动收货脚本时长', '单位 分钟,默认21600分钟/15天', '请填写订单自动收货脚本时长', 'common', 'common_order_success_limit_time', '1566124965'), ('134', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_toutiao_appid', '1580644065'), ('135', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_toutiao_appsecret', '1580644065'), ('136', '', 'PayMerchantID', '支付商户号', '请填写支付商户号', 'common', 'common_app_mini_toutiao_pay_merchant_id', '1580644065'), ('137', '', 'PayAppID', '支付AppID', '请填写AppID', 'common', 'common_app_mini_toutiao_pay_appid', '1580644065'), ('138', '', 'PaySecret', '支付Secret', '请填写支付Secret', 'common', 'common_app_mini_toutiao_pay_secret', '1580644065'), ('139', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_toutiao_title', '1580644065'), ('140', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_toutiao_describe', '1580644065'), ('141', '', '公安备案号', '如:京公网安备xxx号', '请填写公安备案号', 'home', 'home_site_security_record_name', '1572944120'), ('142', '', '公安备案地址', '备案展示页面的url地址', '请填写公安备案地址', 'home', 'home_site_security_record_url', '1572944120'), ('143', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_qq_appid', '1580644073'), ('144', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_qq_appsecret', '1580644073'), ('145', '', 'AppToken', '小程序Token', '请填写AppToken', 'common', 'common_app_mini_qq_apptoken', '1580644073'), ('146', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_qq_title', '1580644073'), ('147', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_qq_describe', '1580644073'), ('148', '0', '是否启用用户中心头部小导航', '默认否', '请选择是否启用用户中心头部小导航', 'common', 'common_app_is_head_vice_nav', '1580559058'), ('151', '4', '站点类型', '默认销售型', '请选择站点类型', 'common', 'common_site_type', '1589032774'), ('150', '', '展示型操作名称', '默认 立即咨询', '请填写展示型操作名称', 'common', 'common_is_exhibition_mode_btn_text', '1589032774'), ('153', '', '虚拟信息标题', '默认密钥信息', '请填写虚拟信息标题', 'common', 'common_site_fictitious_return_title', '1589032774'), ('154', '', '提示信息', '', '请填写提示信息', 'common', 'common_site_fictitious_return_tips', '1589032774'), ('155', '', '在线客服-企业编码', '空则不显示在线客服', '请填写在线客服-企业编码', 'common', 'common_app_mini_alipay_tnt_inst_id', '1580643970'), ('156', '', '在线客服-聊天窗编码', '空则不显示在线客服', '请填写在线客服-聊天窗编码', 'common', 'common_app_mini_alipay_scene', '1580643970'), ('157', '0', '商品详情页展示相册', '默认否', '请选择是否商品详情页展示相册', 'common', 'common_is_goods_detail_show_photo', '1575273956'), ('158', '0', '手机简洁模式', '默认否', '请选择是否手机简洁模式', 'common', 'common_is_mobile_concise_model', '1580643961'), ('159', '0', '启用直播', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用直播', 'common', 'common_app_weixin_liveplayer', '1587445586'); +INSERT INTO `s_config` VALUES ('15', '10', '分页数量', '分页显示数量', '分页不能超过3位数', 'admin', 'admin_page_number', '1587366387'), ('59', '1', '扣减库存规则', '需扣减库存开启方可有效,默认订单支付成功', '', 'common', 'common_deduction_inventory_rules', '1589032774'), ('60', '1', '是否扣减库存', '建议不要随意修改,以免造成库存数据错乱,关闭不影响库存回滚', '', 'common', 'common_is_deduction_inventory', '1589032774'), ('11', '0', 'Excel编码', 'excel模块编码选择', '请选择编码', 'admin', 'admin_excel_charset', '1587366387'), ('16', 'ShopXO企业级B2C电商系统提供商 - 演示站点', '站点标题', '浏览器标题,一般不超过80个字符', '站点标题不能为空', 'home', 'home_seo_site_title', '1585733314'), ('17', '商城系统,开源电商系统,免费电商系统,PHP电商系统,商城系统,B2C电商系统,B2B2C电商系统', '站点关键字', '一般不超过100个字符,多个关键字以半圆角逗号 [ , ] 隔开', '站点关键字不能为空', 'home', 'home_seo_site_keywords', '1585733314'), ('18', 'ShopXO是国内领先的商城系统提供商,为企业提供php商城系统、微信商城、小程序。', '站点描述', '站点描述,一般不超过200个字符', '站点描述不能为空', 'home', 'home_seo_site_description', '1585733314'), ('19', '', 'ICP证书号', 'ICP域名备案号', '', 'home', 'home_site_icp', '1572944120'), ('20', '', '底部统计代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_statistics_code', '0'), ('21', '1', '站点状态', '可暂时将站点关闭,其他人无法访问,但不影响管理员访问后台', '请选择站点状态', 'home', 'home_site_state', '1581399671'), ('22', '升级中...', '关闭原因', '支持html,当网站处于关闭状态时,关闭原因将显示在前台', '', 'home', 'home_site_close_reason', '1581399671'), ('23', 'Australia/Eucla', '默认时区', '默认 亚洲/上海 [标准时+8]', '请选择默认时区', 'common', 'common_timezone', '1581399671'), ('24', '', '底部代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_footer_info', '1581399671'), ('28', 'ShopXO', '站点名称', '', '站点名称不能为空', 'home', 'home_site_name', '1581399671'), ('29', '0', '链接模式', '详情ThinkPHP官网5.1版本文档 [http://www.thinkphp.cn/]', '请选择url模式', 'home', 'home_seo_url_model', '1585733314'), ('25', '2048000', '图片最大限制', '单位B [上传图片还受到服务器空间PHP配置最大上传 20M 限制]', '请填写图片上传最大限制', 'home', 'home_max_limit_image', '1558074966'), ('26', '51200000', '文件最大限制', '单位B [上传文件还受到服务器空间PHP配置最大上传 20M 限制]', '请填写文件上传最大限制', 'home', 'home_max_limit_file', '1558074966'), ('27', '102400000', '视频最大限制', '单位B [上传视频还受到服务器空间PHP配置最大上传 20M 限制]', '请填写视频上传最大限制', 'home', 'home_max_limit_video', '1558074966'), ('30', 'html', '伪静态后缀', '链接后面的后缀别名,默认 [ html ]', '小写字母,不能超过8个字符', 'home', 'home_seo_url_html_suffix', '1585733314'), ('31', '0', '用户注册开启审核', '开启后用户注册需要审核通过方可登录', '请选择用户注册开启审核', 'common', 'common_register_is_enable_audit', '1566227415'), ('32', '/static/upload/images/common/2019/01/14/1547448748316693.png', '手机端logo', '支持 [jpg, png, gif]', '请上传手机端网站logo', 'home', 'home_site_logo_wap', '1581399671'), ('33', '/static/upload/images/common/2019/01/14/1547448705165706.png', '电脑端logo', '支持 [jpg, png, gif]', '请上传电脑端网站logo', 'home', 'home_site_logo', '1581399671'), ('34', '1200', '页面最大宽度', '页面最大宽度,单位px,0则100%', '请上传桌面图标', 'home', 'home_content_max_width', '1581399671'), ('35', '/static/upload/images/common/2019/01/14/1547448728921121.jpg', '桌面图标', '建议使用png格式', '图片比例值格式有误 0~100 之间,小数点后面最大两位', 'common', 'home_site_desktop_icon', '1581399671'), ('36', 'sms,email,username', '是否开启注册', '关闭注册后,前端站点将无法注册,可选择 [ 短信, 邮箱, 用户名 ]', '请选择是否开启注册状态', 'home', 'home_user_reg_state', '1566227415'), ('37', '1', '是否开启登录', '关闭后,前端站点将无法登录', '请选择是否开启登录状态', 'home', 'home_user_login_state', '1558084931'), ('38', '1', '获取验证码-开启图片验证码', '防止短信轰炸', '请选择是否开启强制图片验证码', 'home', 'home_img_verify_state', '1558085166'), ('39', '60', '获取验证码时间间隔', '防止频繁获取验证码,一般在 30~120 秒之间,单位 [秒]', '请填写获取验证码时间间隔', 'home', 'common_verify_time_interval', '1558085166'), ('40', '', '用户注册-短信模板ID', '验证码code', '请填写用户注册短信模板内容', 'home', 'home_sms_user_reg', '1587366205'), ('41', '', '短信签名', '发送短信包含的签名', '短信签名 3~8 个的中英文字符', 'common', 'common_sms_sign', '1587366196'), ('42', '', '短信KeyID', 'Access Key ID', '请填写Access Key ID', 'common', 'common_sms_apikey', '1587366196'), ('43', '', '密码找回-短信模板ID', '验证码code', '请填写密码找回短信模板内容', 'home', 'home_sms_user_forget_pwd', '1587366205'), ('44', '600', '验证码有效时间', '验证码过期时间,一般10分钟左右,单位 [秒]', '请填写验证码有效时间', 'home', 'common_verify_expire_time', '1558085166'), ('45', '', 'SMTP服务器', '设置SMTP服务器的地址,如 smtp.163.com', '请填写SMTP服务器', 'common', 'common_email_smtp_host', '1580643917'), ('46', '', 'SMTP端口', '设置SMTP服务器的端口,默认为 25', '请填写SMTP端口号', 'common', 'common_email_smtp_port', '1580643917'), ('47', '', '发信人邮件地址', '发信人邮件地址,使用SMTP协议发送的邮件地址,如 shopxo@163.com', '请填写发信人邮件地址', 'common', 'common_email_smtp_account', '1580643917'), ('48', '', 'SMTP身份验证用户名', '如 shopxo@163.com', '请填写SMTP身份验证用户名', 'common', 'common_email_smtp_name', '1580643917'), ('49', '', 'SMTP身份验证密码', 'shopxo@163.com邮件的密码或授权码', '请填写SMTP身份验证密码', 'common', 'common_email_smtp_pwd', '1580643917'), ('50', '', '发件人显示名称', '如 ShopXO', '', 'common', 'common_email_smtp_send_name', '1580643917'), ('51', '', '通用-短信模板ID', '验证码code', '请填写通用短信模板内容', 'common', 'common_sms_currency_template', '1587366205'), ('58', '', '短信KeySecret', 'Access Key Secret', '请填写Access Key Secret', 'common', 'common_sms_apisecret', '1587366196'), ('53', '021-88888888', '商店电话', '空则不显示', '', 'common', 'common_customer_store_tel', '1587138005'), ('56', '

通用模板,你的验证码是  #code#

', '通用-邮件模板', '验证码变量标识符 [ #code# ]', '', 'common', 'common_email_currency_template', '1557728601'), ('57', 'default', '默认模板', '前台默认模板', '请填写默认模板', 'common', 'common_default_theme', '1550113393'), ('62', '', '百度地图api密钥', '百度地图api密钥', '请填写百度地图api密钥', 'common', 'common_baidu_map_ak', '1587366387'), ('63', '

用户注册,你的验证码是  #code#

', '用户注册-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_reg', '1557728601'), ('64', '

密码找回,你的验证码是  #code#

', '密码找回-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_forget_pwd', '1557728601'), ('65', '

邮箱绑定,你的验证码是  #code#

', '邮箱绑定-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_email_binding', '1557728601'), ('66', '20200202', 'css/js版本标记', '用于css/js浏览器缓存版本识别', '', 'home', 'home_static_cache_version', '1581399671'), ('67', '', '手机号码绑定-短信模板ID', '验证码code', '请填写手机号码绑定短信模板内容', 'home', 'home_sms_user_mobile_binding', '1587366205'), ('68', '连衣裙,帐篷,iphone,包包', '搜索关键字', '搜索框下热门关键字(输入回车)', '请填写关键字', 'home', 'home_search_keywords', '1566227458'), ('69', '2', '搜索关键字类型', '自定义需要配置以下关键字', '请选择关键字类型', 'home', 'home_search_keywords_type', '1566227458'), ('70', '0', '订单预约模式', '开启后用户提交订单需要管理员确认', '请选择是否开启预约模式', 'common', 'common_order_is_booking', '1589032774'), ('71', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_alipay_title', '1586248646'), ('72', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_alipay_describe', '1586248646'), ('73', '021-88888888', '客服电话', '空则不显示', '请填写客服电话', 'common', 'common_app_customer_service_tel', '1580643961'), ('74', '2019081966311589', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_alipay_appid', '1586248646'), ('75', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuxAXbZitfaALDaevrWVITveMu2fh3L8t3p/5WGPNEVOqCnL3v8EeYZWOLSuBHhpJaLb7Q3HrPWynzpcJ2C17+DxCVS3Js8J/iAgiJGJB4f8wZuPBwqKncGXdrAtN6EYp3H9K1IQeCmGN9di4Ht7igDDREnVWrUIc1Q6O64KDg8YLhWaTf2FMFvdPKiH9tijIZuvtYxxOUkHmgG6N7+IIvKPLdYde0dt/eTy6L1wbXSWoStfmFYd38vywt51N6AlChh/XAQmUGYTq1sW+PFXg2MrDyyWIEZxGb1dINhlMgXMqxTropo31kXa09vUffNvPWVmR38iT9lY+n6ZWSVzH3QIDAQAB', '应用公钥', '', '请填写应用公钥', 'common', 'common_app_mini_alipay_rsa_public', '1586248646'), ('76', 'MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQC7EBdtmK19oAsNp6+tZUhO94y7Z+Hcvy3en/lYY80RU6oKcve/wR5hlY4tK4EeGklotvtDces9bKfOlwnYLXv4PEJVLcmzwn+ICCIkYkHh/zBm48HCoqdwZd2sC03oRincf0rUhB4KYY312Lge3uKAMNESdVatQhzVDo7rgoODxguFZpN/YUwW908qIf22KMhm6+1jHE5SQeaAbo3v4gi8o8t1h17R2395PLovXBtdJahK1+YVh3fy/LC3nU3oCUKGH9cBCZQZhOrWxb48VeDYysPLJYgRnEZvV0g2GUyBcyrFOuimjfWRdrT29R98289ZWZHfyJP2Vj6fplZJXMfdAgMBAAECggEAXXHCYkscj169ZsrXZUTtBBWBRbS1DTKrVUSQqGjibb9fd+zKeg2cgZ7V8RaEX2c+OIL/rUdg/cQjZ33nuwetn+lqMWa4FYYZcvitJYO36Y8yvJMVnYbnIayhOWpENr2l97HWzaZZ41GsOp1SDInGl8bLCe93pwEZqgyltFv0GoSfNu3trFFxPZgZJalV0t5M7+RchutkHskwrwI9BdnCJs38lh08jHHppQdkgcpyCiCdu/b4f+n9z97Op5Va8WY1M+wwqRk76Ias8mqwJXT/+t/sXhqkMv1ylAb89+b3rgiOU7KlZMpIAercW/ZRojnDjpY9ViaCxwWPwb/VkPrDgQKBgQDkDuie0DAIDP5C74dPj/Z0mapsU9bKlcgC+nowEUaEO7A9cwMVFal0x9p7BKIJsV2b6d1qJGP7rM9YtRMldJQmuxPcHOKPcZR8pGLqFYT2QGKGurohb/o+btGda/SGwJfi6jwQUF0AE+1k+Dj9P3hDxHgkj6ZMkHEBtqUj520VTQKBgQDR+1rPPex8zTQgl9uSY0hlXPyYEhpXicNhzyet1Su+TV8wdGNUr2YeuDHEu6oiRocBaT8DEwpy9EToe56EK3Ht2AQ76NBSUp9EOl1twocebM42etJSJZGpB1AgP+R/hmUbcBPXEwXdy5XeYnYmpVUcoizzKrnRDxg3TRF3kIX00QKBgGc49EMFmefa8a6cOdNiJrvp3YBAhkSVfL0UX/+nohIx7fgyOV/uuQ9ZceMiWrEmbWcneAcVx4dfVU4iTzMxy+in3jpPfKBOWVX9FaQ77z2CMNYoaBzAUTS29ftZpIjlXRngySTdKurhGh8MVscRVj7eCz8JIc0fx3ZuE9rnYbE1AoGAJoqJL3LBPmL3x2e4IJVii2BW6J6iASFDIGfCc7Cl18chyqYCOV/8UXUjhWWgo6voScUEkM7k4xacs0NFZCMJRUuZ81kXK5UIsKA519SVsmrsKqm+gt9sbebuuQyhJxsG4dNfgOF3+S7N8kSGRS+hgKDvuS5Fbu7jVfsqUpTPUZECgYAcbq3mqWwExY2Kn0I660OqOFk620pGsSY7gECUQintCZioYemzC1TN9pM6fKnOIYriV4Ou7iswhEfVX+5bwMjH2ujmu8KDdpkpdhRoFCw3GUn/PDelQrptaKkKXnOIJe/R8m+TUxYCtECTlKlYS4hTst7YhTDz5sQHcXRtveATZQ==', '应用私钥', '', '请填写应用私钥', 'common', 'common_app_mini_alipay_rsa_private', '1586248646'), ('78', '0', '是否启用搜索', '默认否', '', 'common', 'common_app_is_enable_search', '1580559058'), ('77', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAkwpOGFOJ0GF6vN9k2dih7Up4+0qecYGtGeZMLdkArDMQ3vgvZFyjAM8c6uFRCHfVoUF5mflVVskLaXMH9C3VY80fxE40WM3VXVW+z0M+WFdihmfB6m/xKpN0QkMVEce7yb7AyXAdNA20KKyjVKXAnDGU3nGc6grQ6uzNIp/Eb8jMPv91GOjzY8KYOxgSiVVM9p5Y1NedGBTQGeMWcRH5vi9ys2Ia0KDYtxuXDhIxMDAqrCNy5sODh0DUpTL+Di09jQRmdI9JNN79ibVmrBoU7ud8YbL/lR4iVT+zF848+OmJiK56yTLcxY8vrU2kGlGO2K8jKWDsOK93H0GF/+lA+wIDAQAB', '支付宝公钥', '', '请填写支付宝公钥', 'common', 'common_app_mini_alipay_out_rsa_public', '1586248646'), ('79', '0', '是否启用留言', '默认否', '', 'common', 'common_app_is_enable_answer', '1580559058'), ('80', '3', '商品可添加规格最大数量', '建议不超过3个规格', '请填写谷歌最大数', 'common', 'common_spec_add_max_number', '1587366387'), ('81', '-', '路由分隔符', '建议填写 [ - ] 默认 [ - ] ,仅PATHINFO模式+短地址模式下有效', '请填写路由分隔符', 'common', 'common_route_separator', '1585733314'), ('82', 'wx0a2012ebad94beff', 'AppID', '小程序ID', '请填写appid', 'common', 'common_app_mini_weixin_appid', '1581478933'), ('83', 'd0e4e81180ea59b8fcc4299f6b05b362', 'AppSecret ', '小程序密钥', '请填写appsecret', 'common', 'common_app_mini_weixin_appsecret', '1581478933'), ('84', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_weixin_title', '1581478933'), ('85', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_weixin_describe', '1581478933'), ('61', '用户中心公告文字,后台配置修改。', '用户中心公告', '空则不显示公告', '', 'common', 'common_user_center_notice', '1580643961'), ('8', '公告内容', '商城公告', '空则不显示公告', '', 'common', 'common_shop_notice', '1580643961'), ('86', 'test@qq.com', '商店邮箱', '空则不显示', '客服邮箱格式有误', 'common', 'common_customer_store_email', '1587138005'), ('87', '', '商店二维码', '空则不展示', '', 'common', 'common_customer_store_qrcode', '1587366387'), ('152', '[{\"alias\":\"总部\",\"name\":\"devil\",\"tel\":\"13222333333\",\"lng\":\"121.594278\",\"lat\":\"31.207917\",\"address\":\"张江高科\",\"province\":\"9\",\"city\":\"155\",\"county\":\"1937\",\"province_name\":\"上海市\",\"city_name\":\"浦东新区\",\"county_name\":\"张江镇\",\"id\":0}]', '自提点地址', '', '请填写自提点地址', 'common', 'common_self_extraction_address', '1589032774'), ('88', '上海市 浦东新区', '商店地址', '空则不展示', '', 'common', 'common_customer_store_address', '1587138005'), ('89', '

用户注册协议


', '用户注册协议', '最多 105000 个字符', '用户注册协议最多 105000 个字符', 'common', 'common_agreement_userregister', '1566227622'), ('90', '/static/upload/images/common/2019/05/17/1558025141249118.png', '用户注册背景图片', '', '请上传用户注册背景图片', 'home', 'home_site_user_register_bg_images', '1566227415'), ('91', '/static/upload/images/common/2019/05/17/1558062481107570.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad1_images', '1558084931'), ('92', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad2_images', '1558084931'), ('93', '/static/upload/images/common/2019/05/17/1558073623385520.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad3_images', '1558084931'), ('94', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad1_url', '1558084931'), ('95', 'https://ask.shopxo.net/', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad2_url', '1558084931'), ('96', 'https://shopxo.net/vip.html', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad3_url', '1558084931'), ('97', '', '背景色', '背景色1', '', 'home', 'home_site_user_login_ad1_bg_color', '1558084931'), ('98', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_login_ad2_bg_color', '1558084931'), ('99', '#FAFAFA', '背景色', '背景色3', '', 'home', 'home_site_user_login_ad3_bg_color', '1558084931'), ('100', '1', '登录图片验证码', '可以防止非法登录', '请选择是否开启登录图片验证码', 'home', 'home_user_login_img_verify_state', '1558084931'), ('101', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad1_images', '1558084915'), ('102', '/static/upload/images/common/2019/05/17/1558073623641199.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad2_images', '1558084915'), ('103', '', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad3_images', '1558084915'), ('104', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad1_url', '1558084915'), ('105', '', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad2_url', '1558084915'), ('106', '', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad3_url', '1558084915'), ('107', '#FAFAFA', '背景色', '背景色1', '', 'home', 'home_site_user_forgetpwd_ad1_bg_color', '1558084915'), ('108', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_forgetpwd_ad2_bg_color', '1558084915'), ('109', '', '背景色', '背景色3', '', 'home', 'home_site_user_forgetpwd_ad3_bg_color', '1558084915'), ('110', '1', '用户注册图片验证码', '可以防止非法注册', '请选择是否开启用户注册图片验证码', 'home', 'home_user_register_img_verify_state', '1566227415'), ('111', '', '图片验证码规则', '默认白底黑字,可根据需求i加大验证码识别难度', '', 'common', 'common_images_verify_rules', '1558085166'), ('112', '0', 'SSL方式加密', '', '请选择是否使用SSL方式加密', 'common', 'common_email_is_use_ssl', '1580643917'), ('113', '活动/优惠未生效\n空包裹\n包裹丢失\n配送超时\n未按约定时间发货\n未送货上门\n物流显示签收但实际未收到货\n不喜欢/不想要', '仅退款原因', '可换行,一行一个', '请填写仅退款原因', 'home', 'home_order_aftersale_return_only_money_reason', '1570193301'), ('114', '7天无理由退换货\n配送超时\n未按约定时间发货\n未送货上门\n卖家发错货\n少件/漏发\n包装/商品破损/污渍\n商品信息描述不符\n使用后过敏\n已过/临近保质期\n无法溶解/结块/有异物', '退货退款原因', '可换行,一行一个', '请填写退货退款原因', 'home', 'home_order_aftersale_return_money_goods_reason', '1570193301'), ('115', '1', '用户注册协议', '', '请选择是否启用用户注册协议', 'home', 'home_is_enable_userregister_agreement', '1566227415'), ('116', '上海市 浦东新区', '退货地址', '用户退货货物收货地址', '请填写退货地址', 'home', 'home_order_aftersale_return_goods_address', '1570193301'), ('117', '0', '使用独立手机详情', '默认使用web详情', '请选择使用独立手机详情', 'common', 'common_app_is_use_mobile_detail', '1580559058'), ('118', '0', '强制绑定手机', '默认否', '请选择是否强制绑定手机', 'common', 'common_user_is_mandatory_bind_mobile', '1580559058'), ('121', '0', '固定顶部导航', '默认否', '请选择是否固定顶部导航', 'common', 'common_app_is_header_nav_fixed', '1580559058'), ('122', '0', '开启在线客服', '默认否', '请选择是否开启在线客服', 'common', 'common_app_is_online_service', '1580559058'), ('123', '0', '启用限时秒杀', '默认否', '请选择是否启用限时秒杀', 'common', 'common_app_is_limitedtimediscount', '1580559058'), ('124', '0', '启用好物推荐', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用好物推荐', 'common', 'common_app_is_good_thing', '1587445586'), ('125', '16634987', 'AppID', '智能小程序ID', '请填写AppID', 'common', 'common_app_mini_baidu_appid', '1586249578'), ('126', 'C9Gg744cBqQ3zvbC5uOPMg9yWpmuQ8O7', 'AppKey', '智能小程序KEY', '请填写AppKey', 'common', 'common_app_mini_baidu_appkey', '1586249578'), ('127', 'KmdPEyuSAXcbiouKVq6LOSUjctZpxmNb', 'AppSecret', '智能小程序密匙', '请填写AppSecret', 'common', 'common_app_mini_baidu_appsecret', '1586249578'), ('128', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_baidu_title', '1586249578'), ('129', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_baidu_describe', '1586249578'), ('130', '0', '留言需要登录', '默认否', '请选择是否留言需要登录', 'common', 'common_is_login_answer', '1566124965'), ('131', '0', '启用海报分享', '默认否\n', '请选择是否启用海报分享\n', 'common', 'common_app_is_poster_share', '1587445586'), ('132', '30', '订单关闭脚本时长', '单位 分钟,默认30分钟', '请填写订单关闭脚本时长', 'common', 'common_order_close_limit_time', '1566124965'), ('133', '21600', '订单自动收货脚本时长', '单位 分钟,默认21600分钟/15天', '请填写订单自动收货脚本时长', 'common', 'common_order_success_limit_time', '1566124965'), ('134', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_toutiao_appid', '1580644065'), ('135', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_toutiao_appsecret', '1580644065'), ('136', '', 'PayMerchantID', '支付商户号', '请填写支付商户号', 'common', 'common_app_mini_toutiao_pay_merchant_id', '1580644065'), ('137', '', 'PayAppID', '支付AppID', '请填写AppID', 'common', 'common_app_mini_toutiao_pay_appid', '1580644065'), ('138', '', 'PaySecret', '支付Secret', '请填写支付Secret', 'common', 'common_app_mini_toutiao_pay_secret', '1580644065'), ('139', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_toutiao_title', '1580644065'), ('140', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_toutiao_describe', '1580644065'), ('141', '', '公安备案号', '如:京公网安备xxx号', '请填写公安备案号', 'home', 'home_site_security_record_name', '1572944120'), ('142', '', '公安备案地址', '备案展示页面的url地址', '请填写公安备案地址', 'home', 'home_site_security_record_url', '1572944120'), ('143', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_qq_appid', '1580644073'), ('144', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_qq_appsecret', '1580644073'), ('145', '', 'AppToken', '小程序Token', '请填写AppToken', 'common', 'common_app_mini_qq_apptoken', '1580644073'), ('146', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_qq_title', '1580644073'), ('147', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_qq_describe', '1580644073'), ('148', '0', '是否启用用户中心头部小导航', '默认否', '请选择是否启用用户中心头部小导航', 'common', 'common_app_is_head_vice_nav', '1580559058'), ('151', '4', '站点类型', '默认销售型', '请选择站点类型', 'common', 'common_site_type', '1589032774'), ('150', '', '展示型操作名称', '默认 立即咨询', '请填写展示型操作名称', 'common', 'common_is_exhibition_mode_btn_text', '1589032774'), ('153', '', '虚拟信息标题', '默认密钥信息', '请填写虚拟信息标题', 'common', 'common_site_fictitious_return_title', '1589032774'), ('154', '', '提示信息', '', '请填写提示信息', 'common', 'common_site_fictitious_return_tips', '1589032774'), ('155', '', '在线客服-企业编码', '空则不显示在线客服', '请填写在线客服-企业编码', 'common', 'common_app_mini_alipay_tnt_inst_id', '1580643970'), ('156', '', '在线客服-聊天窗编码', '空则不显示在线客服', '请填写在线客服-聊天窗编码', 'common', 'common_app_mini_alipay_scene', '1580643970'), ('157', '0', '商品详情页展示相册', '默认否', '请选择是否商品详情页展示相册', 'common', 'common_is_goods_detail_show_photo', '1575273956'), ('158', '0', '手机简洁模式', '默认否', '请选择是否手机简洁模式', 'common', 'common_is_mobile_concise_model', '1580643961'), ('159', '0', '启用直播', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用直播', 'common', 'common_app_weixin_liveplayer', '1587445586'),(160, 'tencent', '短信平台', '选择使用的短信平台', '请确认使用的配置是适合当前所选短信平台的。', 'common', 'common_sms_platform', 1590335998),(161, '1400368404', '短信平台APP_ID', '腾讯云必填字段,可以在腾讯云/短信/应用管理找到', '腾讯云必须填写此字段', 'common', 'common_sms_sdk_appid', 1590335998); COMMIT; -- ---------------------------- diff --git a/extend/base/AliyunSms.php b/extend/base/AliyunSms.php new file mode 100755 index 000000000..37706e26d --- /dev/null +++ b/extend/base/AliyunSms.php @@ -0,0 +1,190 @@ +signName = MyC('common_sms_sign'); + $this->accessKeyId = MyC('common_sms_apikey'); + $this->accessKeySecret = MyC('common_sms_apisecret'); + } + + private function percentEncode($string) { + $string = urlencode ( $string ); + $string = preg_replace ( '/\+/', '%20', $string ); + $string = preg_replace ( '/\*/', '%2A', $string ); + $string = preg_replace ( '/%7E/', '~', $string ); + return $string; + } + /** + * 签名 + * + * @param unknown $parameters + * @param unknown $accessKeySecret + * @return string + */ + private function computeSignature($parameters, $accessKeySecret) { + ksort ( $parameters ); + $canonicalizedQueryString = ''; + foreach ( $parameters as $key => $value ) { + $canonicalizedQueryString .= '&' . $this->percentEncode ( $key ) . '=' . $this->percentEncode ( $value ); + } + $stringToSign = 'GET&%2F&' . $this->percentencode ( substr ( $canonicalizedQueryString, 1 ) ); + $signature = base64_encode ( hash_hmac ( 'sha1', $stringToSign, $accessKeySecret . '&', true ) ); + return $signature; + } + + /** + * 短信发送 + * @author Devil + * @blog http://gong.gg/ + * @version 1.0.0 + * @date 2020-04-02 + * @desc description + * @param [string] $mobile [手机号码,多个以 英文逗号 , 分割] + * @param [string|array] $code [变量code(单个直接传入 code 即可,多个传入数组)] + * @param [string] $template_code [模板 id] + * @param [boolean] $sign_name [自定义签名,默认使用基础配置的签名] + */ + public function SendCode($mobile, $code, $template_code, $sign_name = '') + { + // 单个验证码需要校验是否频繁 + if(is_string($code)) + { + + $codes = ['code'=>$code]; + } else { + $codes = $code; + } + + // 签名 + $SignName = empty($sign_name) ? $this->signName : $sign_name; + + // 请求参数 + $params = array ( //此处作了修改 + 'SignName' => $SignName, + 'Format' => 'JSON', + 'Version' => '2017-05-25', + 'AccessKeyId' => $this->accessKeyId, + 'SignatureVersion' => '1.0', + 'SignatureMethod' => 'HMAC-SHA1', + 'SignatureNonce' => uniqid (), + 'Timestamp' => gmdate ( 'Y-m-d\TH:i:s\Z' ), + 'Action' => 'SendSms', + 'TemplateCode' => $template_code, + 'PhoneNumbers' => $mobile, + 'TemplateParam' => json_encode($codes, JSON_UNESCAPED_UNICODE), + ); + //print_r($params);die; + // 计算签名并把签名结果加入请求参数 + $params ['Signature'] = $this->computeSignature ( $params, $this->accessKeySecret ); + // 发送请求(此处作了修改) + //$url = 'https://sms.aliyuncs.com/?' . http_build_query ( $params ); + $url = 'http://dysmsapi.aliyuncs.com/?' . http_build_query ( $params ); + + $ch = curl_init (); + curl_setopt ( $ch, CURLOPT_URL, $url ); + curl_setopt ( $ch, CURLOPT_SSL_VERIFYPEER, FALSE ); + curl_setopt ( $ch, CURLOPT_SSL_VERIFYHOST, FALSE ); + curl_setopt ( $ch, CURLOPT_RETURNTRANSFER, 1 ); + curl_setopt ( $ch, CURLOPT_TIMEOUT, 10 ); + $result = curl_exec ( $ch ); + curl_close ( $ch ); + $result = json_decode ( $result, true ); + //print_r($result);//die; + if (isset ( $result ['Code'] ) && $result['Code'] != 'OK') { + $this->error = $this->getErrorMessage ( $result ['Code'] ); + return false; + } + + + return true; + } + /** + * 获取详细错误信息 + * + * @param unknown $status + */ + public function getErrorMessage($status) { + // 阿里云的短信 乱八七糟的(其实是用的阿里大于) + // https://api.alidayu.com/doc2/apiDetail?spm=a3142.7629140.1.19.SmdYoA&apiId=25450 + $message = array ( + 'InvalidDayuStatus.Malformed' => '账户短信开通状态不正确', + 'InvalidSignName.Malformed' => '短信签名不正确或签名状态不正确', + 'InvalidTemplateCode.MalFormed' => '短信模板Code不正确或者模板状态不正确', + 'InvalidRecNum.Malformed' => '目标手机号不正确,单次发送数量不能超过100', + 'InvalidParamString.MalFormed' => '短信模板中变量不是json格式', + 'InvalidParamStringTemplate.Malformed' => '短信模板中变量与模板内容不匹配', + 'InvalidSendSms' => '触发业务流控', + 'InvalidDayu.Malformed' => '变量不能是url,可以将变量固化在模板中', + 'isv.RAM_PERMISSION_DENY' => 'RAM权限DENY', + 'isv.OUT_OF_SERVICE' => '业务停机', + 'isv.PRODUCT_UN_SUBSCRIPT' => '未开通云通信产品的阿里云客户', + 'isv.PRODUCT_UNSUBSCRIBE' => '产品未开通', + 'isv.ACCOUNT_NOT_EXISTS' => '账户不存在', + 'isv.ACCOUNT_ABNORMAL' => '账户异常', + 'isv.SMS_TEMPLATE_ILLEGAL' => '短信模板不合法', + 'isv.SMS_SIGNATURE_ILLEGAL' => '短信签名不合法', + 'isv.INVALID_PARAMETERS' => '参数异常', + 'isv.SYSTEM_ERROR' => '系统错误', + 'isv.MOBILE_NUMBER_ILLEGAL' => '非法手机号', + 'isv.MOBILE_COUNT_OVER_LIMIT' => '手机号码数量超过限制', + 'isv.TEMPLATE_MISSING_PARAMETERS' => '模板缺少变量', + 'isv.BUSINESS_LIMIT_CONTROL' => '业务限流', + 'isv.INVALID_JSON_PARAM' => 'JSON参数不合法,只接受字符串值', + 'isv.BLACK_KEY_CONTROL_LIMIT' => '黑名单管控', + 'isv.PARAM_LENGTH_LIMIT' => '参数超出长度限制', + 'isv.PARAM_NOT_SUPPORT_URL' => '不支持URL', + 'isv.AMOUNT_NOT_ENOUGH' => '账户余额不足', + ); + if (isset ( $message [$status] )) { + return $message [$status]; + } + return $status; + } + +} +?> \ No newline at end of file diff --git a/extend/base/Sms.php b/extend/base/Sms.php index fc02710d0..859b452e3 100755 --- a/extend/base/Sms.php +++ b/extend/base/Sms.php @@ -9,6 +9,8 @@ // | Author: Devil // +---------------------------------------------------------------------- namespace base; +use base\AliyunSms; +use base\TencentSms; /** * 短信驱动 @@ -21,21 +23,13 @@ class Sms { // 保存错误信息 public $error; + public $rawData;//错误的时候,方便查看原始数据。 - // Access Key ID - private $accessKeyId = ''; - - // Access Access Key Secret - private $accessKeySecret = ''; - - // 签名 - private $signName = ''; - - // 模版ID - private $templateCode = ''; private $expire_time; private $key_code; + private $sms_platform=''; + private $sms_instance;//具体的SMS服务支持实例 /** * [__construct 构造方法] @@ -44,44 +38,24 @@ class Sms * @version 0.0.1 * @datetime 2017-03-07T14:03:02+0800 * @param [int] $param['interval_time'] [间隔时间(默认30)单位(秒)] - * @param [int] $param['expire_time'] [到期时间(默认30)单位(秒)] + * @param [int] $param['expire_time'] [到期时间(默认30)单位(秒),请使用60的整数倍] * @param [string] $param['key_prefix'] [验证码种存储前缀key(默认 空)] */ public function __construct($param = array()) { $this->interval_time = isset($param['interval_time']) ? intval($param['interval_time']) : 30; - $this->expire_time = isset($param['expire_time']) ? intval($param['expire_time']) : 30; + $this->expire_time = isset($param['expire_time']) ? intval($param['expire_time']) : 60; $this->key_code = isset($param['key_prefix']) ? trim($param['key_prefix']).'_sms_code' : '_sms_code'; - $this->signName = MyC('common_sms_sign'); - $this->accessKeyId = MyC('common_sms_apikey'); - $this->accessKeySecret = MyC('common_sms_apisecret'); - } + $this->sms_platform = MyC('common_sms_platform'); - private function percentEncode($string) { - $string = urlencode ( $string ); - $string = preg_replace ( '/\+/', '%20', $string ); - $string = preg_replace ( '/\*/', '%2A', $string ); - $string = preg_replace ( '/%7E/', '~', $string ); - return $string; - } - /** - * 签名 - * - * @param unknown $parameters - * @param unknown $accessKeySecret - * @return string - */ - private function computeSignature($parameters, $accessKeySecret) { - ksort ( $parameters ); - $canonicalizedQueryString = ''; - foreach ( $parameters as $key => $value ) { - $canonicalizedQueryString .= '&' . $this->percentEncode ( $key ) . '=' . $this->percentEncode ( $value ); + if($this->sms_platform=='tencent'){ + $this->sms_instance=new \Base\TencentSms(); + }else{ + $this->sms_instance=new \Base\AliyunSms(); } - $stringToSign = 'GET&%2F&' . $this->percentencode ( substr ( $canonicalizedQueryString, 1 ) ); - $signature = base64_encode ( hash_hmac ( 'sha1', $stringToSign, $accessKeySecret . '&', true ) ); - return $signature; - } + } + /** * 短信发送 @@ -98,59 +72,30 @@ class Sms public function SendCode($mobile, $code, $template_code, $sign_name = '') { // 单个验证码需要校验是否频繁 + if(is_string($code)) { + // 是否频繁操作 if(!$this->IntervalTimeCheck()) { $this->error = '防止造成骚扰,请勿频繁发送'; return false; } - $codes = ['code'=>$code]; - } else { - $codes = $code; + if($this->sms_platform=='tencent') { + $codes=array($code,''.$this->expire_time/60);//将秒转为分钟,显示在短信里。 + }else{ + $codes = ['code'=>$code,'expire_time'=>''.$this->expire_time/60];//将秒转为分钟,显示在短信里。 + } } - // 签名 - $SignName = empty($sign_name) ? $this->signName : $sign_name; + $is_success=$this->sms_instance->SendCode($mobile,$codes,$template_code,$sign_name); + $this->rawData=$this->sms_instance->rawData; - // 请求参数 - $params = array ( //此处作了修改 - 'SignName' => $SignName, - 'Format' => 'JSON', - 'Version' => '2017-05-25', - 'AccessKeyId' => $this->accessKeyId, - 'SignatureVersion' => '1.0', - 'SignatureMethod' => 'HMAC-SHA1', - 'SignatureNonce' => uniqid (), - 'Timestamp' => gmdate ( 'Y-m-d\TH:i:s\Z' ), - 'Action' => 'SendSms', - 'TemplateCode' => $template_code, - 'PhoneNumbers' => $mobile, - 'TemplateParam' => json_encode($codes, JSON_UNESCAPED_UNICODE), - ); - //print_r($params);die; - // 计算签名并把签名结果加入请求参数 - $params ['Signature'] = $this->computeSignature ( $params, $this->accessKeySecret ); - // 发送请求(此处作了修改) - //$url = 'https://sms.aliyuncs.com/?' . http_build_query ( $params ); - $url = 'http://dysmsapi.aliyuncs.com/?' . http_build_query ( $params ); - - $ch = curl_init (); - curl_setopt ( $ch, CURLOPT_URL, $url ); - curl_setopt ( $ch, CURLOPT_SSL_VERIFYPEER, FALSE ); - curl_setopt ( $ch, CURLOPT_SSL_VERIFYHOST, FALSE ); - curl_setopt ( $ch, CURLOPT_RETURNTRANSFER, 1 ); - curl_setopt ( $ch, CURLOPT_TIMEOUT, 10 ); - $result = curl_exec ( $ch ); - curl_close ( $ch ); - $result = json_decode ( $result, true ); - //print_r($result);//die; - if (isset ( $result ['Code'] ) && $result['Code'] != 'OK') { - $this->error = $this->getErrorMessage ( $result ['Code'] ); + if(!$is_success){ + $this->error=$this->sms_instance->error; return false; } - // 种session if(is_string($code)) { @@ -159,48 +104,7 @@ class Sms return true; } - /** - * 获取详细错误信息 - * - * @param unknown $status - */ - public function getErrorMessage($status) { - // 阿里云的短信 乱八七糟的(其实是用的阿里大于) - // https://api.alidayu.com/doc2/apiDetail?spm=a3142.7629140.1.19.SmdYoA&apiId=25450 - $message = array ( - 'InvalidDayuStatus.Malformed' => '账户短信开通状态不正确', - 'InvalidSignName.Malformed' => '短信签名不正确或签名状态不正确', - 'InvalidTemplateCode.MalFormed' => '短信模板Code不正确或者模板状态不正确', - 'InvalidRecNum.Malformed' => '目标手机号不正确,单次发送数量不能超过100', - 'InvalidParamString.MalFormed' => '短信模板中变量不是json格式', - 'InvalidParamStringTemplate.Malformed' => '短信模板中变量与模板内容不匹配', - 'InvalidSendSms' => '触发业务流控', - 'InvalidDayu.Malformed' => '变量不能是url,可以将变量固化在模板中', - 'isv.RAM_PERMISSION_DENY' => 'RAM权限DENY', - 'isv.OUT_OF_SERVICE' => '业务停机', - 'isv.PRODUCT_UN_SUBSCRIPT' => '未开通云通信产品的阿里云客户', - 'isv.PRODUCT_UNSUBSCRIBE' => '产品未开通', - 'isv.ACCOUNT_NOT_EXISTS' => '账户不存在', - 'isv.ACCOUNT_ABNORMAL' => '账户异常', - 'isv.SMS_TEMPLATE_ILLEGAL' => '短信模板不合法', - 'isv.SMS_SIGNATURE_ILLEGAL' => '短信签名不合法', - 'isv.INVALID_PARAMETERS' => '参数异常', - 'isv.SYSTEM_ERROR' => '系统错误', - 'isv.MOBILE_NUMBER_ILLEGAL' => '非法手机号', - 'isv.MOBILE_COUNT_OVER_LIMIT' => '手机号码数量超过限制', - 'isv.TEMPLATE_MISSING_PARAMETERS' => '模板缺少变量', - 'isv.BUSINESS_LIMIT_CONTROL' => '业务限流', - 'isv.INVALID_JSON_PARAM' => 'JSON参数不合法,只接受字符串值', - 'isv.BLACK_KEY_CONTROL_LIMIT' => '黑名单管控', - 'isv.PARAM_LENGTH_LIMIT' => '参数超出长度限制', - 'isv.PARAM_NOT_SUPPORT_URL' => '不支持URL', - 'isv.AMOUNT_NOT_ENOUGH' => '账户余额不足', - ); - if (isset ( $message [$status] )) { - return $message [$status]; - } - return $status; - } + /** * [KindofSession 种验证码session] diff --git a/extend/base/TencentSms.php b/extend/base/TencentSms.php new file mode 100755 index 000000000..d853cfac1 --- /dev/null +++ b/extend/base/TencentSms.php @@ -0,0 +1,267 @@ +signName = MyC('common_sms_sign'); + $this->accessKeyId = MyC('common_sms_apikey'); + $this->accessKeySecret = MyC('common_sms_apisecret'); + $this->platform_appid = MyC('common_sms_sdk_appid'); + } + + + /** + * 签名 + * + * @param unknown $parameters + * @param unknown $accessKeySecret + * @return string + */ + private function computeSignature($host, $payload, $timestamp) + { + $secretId = $this->accessKeyId; + $secretKey = $this->accessKeySecret; + + + $region = ''; + $service = 'sms'; + + + $algorithm = "TC3-HMAC-SHA256"; + + $httpRequestMethod = 'POST'; + $canonicalUri = "/"; + $canonicalQueryString = ""; + $canonicalHeaders = "content-type:application/json\n" . "host:" . $host . "\n"; + $signedHeaders = "content-type;host"; +// $payload = json_encode($param,JSON_UNESCAPED_UNICODE); + +// echo $payload.PHP_EOL; + + $hashedRequestPayload = hash("SHA256", $payload); + $canonicalRequest = $httpRequestMethod . "\n" + . $canonicalUri . "\n" + . $canonicalQueryString . "\n" + . $canonicalHeaders . "\n" + . $signedHeaders . "\n" + . $hashedRequestPayload; + +// echo $canonicalRequest.PHP_EOL; + + + // step 2: build string to sign + $date = gmdate("Y-m-d", $timestamp); + $credentialScope = $date . "/" . $service . "/tc3_request"; + $hashedCanonicalRequest = hash("SHA256", $canonicalRequest); + $stringToSign = $algorithm . "\n" + . $timestamp . "\n" + . $credentialScope . "\n" + . $hashedCanonicalRequest; +// echo $stringToSign.PHP_EOL; + + + // step 3: sign string + $secretDate = hash_hmac("SHA256", $date, "TC3" . $secretKey, true); + $secretService = hash_hmac("SHA256", $service, $secretDate, true); + $secretSigning = hash_hmac("SHA256", "tc3_request", $secretService, true); + $signature = hash_hmac("SHA256", $stringToSign, $secretSigning); +// echo $signature.PHP_EOL; + + // step 4: build authorization + $authorization = $algorithm + . " Credential=" . $secretId . "/" . $credentialScope + . ", SignedHeaders=content-type;host, Signature=" . $signature; +// echo $authorization.PHP_EOL; + + return $authorization;//返回认证签名 + + + } + + /** + * 短信发送 + * @param [string] $mobile [手机号码,多个以 英文逗号 , 分割] + * @param [string|array] $code [变量code(单个直接传入 code 即可,多个传入数组)] + * @param [string] $template_code [模板 id] + * @param [boolean] $sign_name [自定义签名,默认使用基础配置的签名] + * @author Devil + * @blog http://gong.gg/ + * @version 1.0.0 + * @date 2020-04-02 + * @desc description + */ + public function SendCode($mobile, $code, $template_code, $sign_name = '') + { + + // 签名 + $sign_name = empty($sign_name) ? $this->signName : $sign_name; + + // 请求参数 + $params = array( //此处作了修改 + 'PhoneNumberSet' => $mobile, + 'TemplateID' => $template_code, + 'Sign' => $sign_name, + 'TemplateParamSet' => $code, + 'SessionContext' => '', + 'SmsSdkAppid' => $this->platform_appid + ); + + // 计算签名并把签名结果加入请求参数 + $timestamp = time(); + $url = 'https://' . $this->apiHost; + $version = '2019-07-11'; + $action = "SendSms"; + $payload = json_encode($params, JSON_UNESCAPED_UNICODE); + $authorization = $this->computeSignature($this->apiHost, $payload, $timestamp); + + $headers = array( + "Authorization:$authorization", + "Content-type:application/json", + "Host:$this->apiHost", + "X-TC-Action:$action", + "X-TC-Version:$version", + "X-TC-Timestamp:$timestamp", +// "X-TC-Region:$region" + ); + + $curl = curl_init(); + curl_setopt($curl, CURLOPT_URL, $url); + curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE); + curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, FALSE); + curl_setopt($curl, CURLOPT_HTTPHEADER, $headers); + curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); + curl_setopt($curl, CURLOPT_FOLLOWLOCATION, false); + curl_setopt($curl, CURLOPT_AUTOREFERER, 1); + curl_setopt($curl, CURLOPT_POST, 1); + curl_setopt($curl, CURLOPT_POSTFIELDS, $payload); + curl_setopt($curl, CURLOPT_POST, 1); + + $result = curl_exec($curl); + curl_close($curl); + + if ($result == false) { + $this->error = "访问腾讯云短信服务失败"; + + } else { + + $result = json_decode($result, true); + } + + //因为一般业务情况是发给一个人,这里就简单处理为取第一个短信的状态。 + //如果是批量的话,需要遍历获得所有的情况,这样的可以另外写一个接口。 + $errorCode=''; + $this->rawData = $result; + if(isset($result["Response"]['Error'])){ + + $errorCode=$result["Response"]['Error']['Code']; + + }else if(isset($result["Response"]["SendStatusSet"][0])){ + $sendStatusItem = $result["Response"]["SendStatusSet"][0]; + $errorCode=$sendStatusItem['Code']; + } + + + if (strtolower($errorCode) != 'ok') { + $this->error = $this->getErrorMessage($errorCode); + return false; + } + + + + return true; + + } + + /** + * 获取详细错误信息 + * + * @param unknown $status + */ + public function getErrorMessage($status) + { + //查询错误码地址: + //https://cloud.tencent.com/document/product/382/38780 + $message = array( + 'FailedOperation.ContainSensitiveWord' => '短信内容中含有敏感词', + 'FailedOperation.FailResolvePacket' => '请求包解析失败,通常情况下是由于没有遵守 API 接口说明规范导致的', + 'FailedOperation.InsufficientBalanceInSmsPackage' => '套餐包余量不足', + 'FailedOperation.JsonParseFail' => '解析请求包体时候失败', + 'FailedOperation.MarketingSendTimeConstraint' => '营销短信发送时间限制,为避免骚扰用户,营销短信只允许在8点到22点发送。', + 'FailedOperation.MissingSignature' => '没有申请签名之前,无法申请模板,请根据 创建签名 申请完成之后再次申请。', + 'FailedOperation.PhoneNumberInBlacklist' => '手机号在黑名单库中,通常是用户退订或者命中运营商黑名单导致的,可联系 sms helper 解决。', + 'FailedOperation.PhoneNumberOnBlacklist' => '手机号在黑名单库中,通常是用户退订或者命中运营商黑名单导致的,可联系 sms helper 解决。', + 'InternalError.RequestTimeException' => '请求发起时间不正常,通常是由于您的服务器时间与腾讯云服务器时间差异超过10分钟导致的,请核对服务器时间及 API 接口中的时间字段是否正常。', + 'InternalError.Timeout' => '请求下发短信超时,请参考 60008错误详解。', + 'InvalidParameterValue.IncorrectPhoneNumber' => '手机号格式错误,请参考 1016错误详解', + 'InvalidParameterValue.ProhibitedUseUrlInTemplateParameter' => '禁止在模板变量中使用 URL。', + 'InvalidParameterValue.TemplateParameterFormatError' => '验证码模板参数格式错误,验证码类模版,模版变量只能传入0 - 6位(包括6位)纯数字', + 'LimitExceeded.AppDailyLimit' => '业务短信日下发条数超过设定的上限 ,可自行到控制台调整短信频率限制策略。', + 'LimitExceeded.DailyLimit' => '短信日下发条数超过设定的上限 (国际/港澳台),如需调整限制,可联系 sms helper。', + 'LimitExceeded.DeliveryFrequencyLimit' => '下发短信命中了频率限制策略,可自行到控制台调整短信频率限制策略,如有其他需求请联系 sms helper。', + 'LimitExceeded.PhoneNumberCountLimit' => '调用短信发送 API 接口单次提交的手机号个数超过200个', + 'LimitExceeded.PhoneNumberDailyLimit' => '单个手机号日下发短信条数超过设定的上限,可自行到控制台调整短信频率限制策略。', + 'LimitExceeded.PhoneNumberOneHourLimit' => '单个手机号1小时内下发短信条数超过设定的上限,可自行到控制台调整短信频率限制策略。', + 'LimitExceeded.PhoneNumberSameContentDailyLimit' => '单个手机号下发相同内容超过设定的上限,可自行到控制台调整短信频率限制策略。', + 'LimitExceeded.PhoneNumberThirtySecondLimit' => '单个手机号30秒内下发短信条数超过设定的上限,可自行到控制台调整短信频率限制策略。', + 'MissingParameter.EmptyPhoneNumberSet' => ' 传入的号码列表为空,请确认您的参数中是否传入号码。', + 'UnauthorizedOperation.IndividualUserMarketingSmsPermissionDeny' => '个人用户没有发营销短信的权限', + 'UnauthorizedOperation.RequestIpNotInWhitelist' => '请求 IP 不在白名单中,您配置了校验请求来源 IP,但是检测到当前请求 IP 不在配置列表中,', + 'UnauthorizedOperation.SerivceSuspendDueToArrears' => '欠费被停止服务,可自行登录腾讯云充值来缴清欠款。', + 'ContainDomesticAndInternationalPhoneNumber' => '群发请求里既有国内手机号也有国际手机号。', + 'UnsupportedOperation.UnsuportedRegion' => '不支持该地区短信下发。', + + ); + if (isset ($message [$status])) { + return $message [$status]; + } + return '错误状态码:' . $status . ',详细错查询:https://cloud.tencent.com/document/product/382/38780'; + } +} + +?> \ No newline at end of file -- Gitee From 1b19fac4d7a0c68b25b61c38a4f18a0a2022ddbb Mon Sep 17 00:00:00 2001 From: liuyi Date: Mon, 1 Jun 2020 22:28:48 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=BA=93=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E6=96=87=E4=BB=B6=E5=90=8C=E6=97=B6=E5=8A=A0=E5=85=A5?= =?UTF-8?q?2=E4=B8=AA=E5=AD=97=E6=AE=B5=EF=BC=8C=E4=BB=A5=E6=94=AF?= =?UTF-8?q?=E6=8C=81=E8=85=BE=E8=AE=AF=E4=BA=91=E7=9F=AD=E4=BF=A1=E6=9C=8D?= =?UTF-8?q?=E5=8A=A1=EF=BC=9A=20(160,=20'aliyun',=20'=E7=9F=AD=E4=BF=A1?= =?UTF-8?q?=E5=B9=B3=E5=8F=B0',=20'=E9=80=89=E6=8B=A9=E4=BD=BF=E7=94=A8?= =?UTF-8?q?=E7=9A=84=E7=9F=AD=E4=BF=A1=E5=B9=B3=E5=8F=B0',=20'=E8=AF=B7?= =?UTF-8?q?=E7=A1=AE=E8=AE=A4=E4=BD=BF=E7=94=A8=E7=9A=84=E9=85=8D=E7=BD=AE?= =?UTF-8?q?=E6=98=AF=E9=80=82=E5=90=88=E5=BD=93=E5=89=8D=E6=89=80=E9=80=89?= =?UTF-8?q?=E7=9F=AD=E4=BF=A1=E5=B9=B3=E5=8F=B0=E7=9A=84=E3=80=82',=20'com?= =?UTF-8?q?mon',=20'common=5Fsms=5Fplatform',=201590335998),=20(161,=20'',?= =?UTF-8?q?=20'=E7=9F=AD=E4=BF=A1=E5=B9=B3=E5=8F=B0APP=5FID',=20'=E8=85=BE?= =?UTF-8?q?=E8=AE=AF=E4=BA=91=E5=BF=85=E5=A1=AB=E5=AD=97=E6=AE=B5=EF=BC=8C?= =?UTF-8?q?=E5=8F=AF=E4=BB=A5=E5=9C=A8=E8=85=BE=E8=AE=AF=E4=BA=91/?= =?UTF-8?q?=E7=9F=AD=E4=BF=A1/=E5=BA=94=E7=94=A8=E7=AE=A1=E7=90=86?= =?UTF-8?q?=E6=89=BE=E5=88=B0',=20'=E8=85=BE=E8=AE=AF=E4=BA=91=E5=BF=85?= =?UTF-8?q?=E9=A1=BB=E5=A1=AB=E5=86=99=E6=AD=A4=E5=AD=97=E6=AE=B5',=20'com?= =?UTF-8?q?mon',=20'common=5Fsms=5Fsdk=5Fappid',=201590335998)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config/shopxo.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/shopxo.sql b/config/shopxo.sql index ddf3c6822..1dc0a6bd3 100644 --- a/config/shopxo.sql +++ b/config/shopxo.sql @@ -317,7 +317,7 @@ CREATE TABLE `s_config` ( -- Records of `s_config` -- ---------------------------- BEGIN; -INSERT INTO `s_config` VALUES ('15', '10', '分页数量', '分页显示数量', '分页不能超过3位数', 'admin', 'admin_page_number', '1587366387'), ('59', '1', '扣减库存规则', '需扣减库存开启方可有效,默认订单支付成功', '', 'common', 'common_deduction_inventory_rules', '1589032774'), ('60', '1', '是否扣减库存', '建议不要随意修改,以免造成库存数据错乱,关闭不影响库存回滚', '', 'common', 'common_is_deduction_inventory', '1589032774'), ('11', '0', 'Excel编码', 'excel模块编码选择', '请选择编码', 'admin', 'admin_excel_charset', '1587366387'), ('16', 'ShopXO企业级B2C电商系统提供商 - 演示站点', '站点标题', '浏览器标题,一般不超过80个字符', '站点标题不能为空', 'home', 'home_seo_site_title', '1585733314'), ('17', '商城系统,开源电商系统,免费电商系统,PHP电商系统,商城系统,B2C电商系统,B2B2C电商系统', '站点关键字', '一般不超过100个字符,多个关键字以半圆角逗号 [ , ] 隔开', '站点关键字不能为空', 'home', 'home_seo_site_keywords', '1585733314'), ('18', 'ShopXO是国内领先的商城系统提供商,为企业提供php商城系统、微信商城、小程序。', '站点描述', '站点描述,一般不超过200个字符', '站点描述不能为空', 'home', 'home_seo_site_description', '1585733314'), ('19', '', 'ICP证书号', 'ICP域名备案号', '', 'home', 'home_site_icp', '1572944120'), ('20', '', '底部统计代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_statistics_code', '0'), ('21', '1', '站点状态', '可暂时将站点关闭,其他人无法访问,但不影响管理员访问后台', '请选择站点状态', 'home', 'home_site_state', '1581399671'), ('22', '升级中...', '关闭原因', '支持html,当网站处于关闭状态时,关闭原因将显示在前台', '', 'home', 'home_site_close_reason', '1581399671'), ('23', 'Australia/Eucla', '默认时区', '默认 亚洲/上海 [标准时+8]', '请选择默认时区', 'common', 'common_timezone', '1581399671'), ('24', '', '底部代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_footer_info', '1581399671'), ('28', 'ShopXO', '站点名称', '', '站点名称不能为空', 'home', 'home_site_name', '1581399671'), ('29', '0', '链接模式', '详情ThinkPHP官网5.1版本文档 [http://www.thinkphp.cn/]', '请选择url模式', 'home', 'home_seo_url_model', '1585733314'), ('25', '2048000', '图片最大限制', '单位B [上传图片还受到服务器空间PHP配置最大上传 20M 限制]', '请填写图片上传最大限制', 'home', 'home_max_limit_image', '1558074966'), ('26', '51200000', '文件最大限制', '单位B [上传文件还受到服务器空间PHP配置最大上传 20M 限制]', '请填写文件上传最大限制', 'home', 'home_max_limit_file', '1558074966'), ('27', '102400000', '视频最大限制', '单位B [上传视频还受到服务器空间PHP配置最大上传 20M 限制]', '请填写视频上传最大限制', 'home', 'home_max_limit_video', '1558074966'), ('30', 'html', '伪静态后缀', '链接后面的后缀别名,默认 [ html ]', '小写字母,不能超过8个字符', 'home', 'home_seo_url_html_suffix', '1585733314'), ('31', '0', '用户注册开启审核', '开启后用户注册需要审核通过方可登录', '请选择用户注册开启审核', 'common', 'common_register_is_enable_audit', '1566227415'), ('32', '/static/upload/images/common/2019/01/14/1547448748316693.png', '手机端logo', '支持 [jpg, png, gif]', '请上传手机端网站logo', 'home', 'home_site_logo_wap', '1581399671'), ('33', '/static/upload/images/common/2019/01/14/1547448705165706.png', '电脑端logo', '支持 [jpg, png, gif]', '请上传电脑端网站logo', 'home', 'home_site_logo', '1581399671'), ('34', '1200', '页面最大宽度', '页面最大宽度,单位px,0则100%', '请上传桌面图标', 'home', 'home_content_max_width', '1581399671'), ('35', '/static/upload/images/common/2019/01/14/1547448728921121.jpg', '桌面图标', '建议使用png格式', '图片比例值格式有误 0~100 之间,小数点后面最大两位', 'common', 'home_site_desktop_icon', '1581399671'), ('36', 'sms,email,username', '是否开启注册', '关闭注册后,前端站点将无法注册,可选择 [ 短信, 邮箱, 用户名 ]', '请选择是否开启注册状态', 'home', 'home_user_reg_state', '1566227415'), ('37', '1', '是否开启登录', '关闭后,前端站点将无法登录', '请选择是否开启登录状态', 'home', 'home_user_login_state', '1558084931'), ('38', '1', '获取验证码-开启图片验证码', '防止短信轰炸', '请选择是否开启强制图片验证码', 'home', 'home_img_verify_state', '1558085166'), ('39', '60', '获取验证码时间间隔', '防止频繁获取验证码,一般在 30~120 秒之间,单位 [秒]', '请填写获取验证码时间间隔', 'home', 'common_verify_time_interval', '1558085166'), ('40', '', '用户注册-短信模板ID', '验证码code', '请填写用户注册短信模板内容', 'home', 'home_sms_user_reg', '1587366205'), ('41', '', '短信签名', '发送短信包含的签名', '短信签名 3~8 个的中英文字符', 'common', 'common_sms_sign', '1587366196'), ('42', '', '短信KeyID', 'Access Key ID', '请填写Access Key ID', 'common', 'common_sms_apikey', '1587366196'), ('43', '', '密码找回-短信模板ID', '验证码code', '请填写密码找回短信模板内容', 'home', 'home_sms_user_forget_pwd', '1587366205'), ('44', '600', '验证码有效时间', '验证码过期时间,一般10分钟左右,单位 [秒]', '请填写验证码有效时间', 'home', 'common_verify_expire_time', '1558085166'), ('45', '', 'SMTP服务器', '设置SMTP服务器的地址,如 smtp.163.com', '请填写SMTP服务器', 'common', 'common_email_smtp_host', '1580643917'), ('46', '', 'SMTP端口', '设置SMTP服务器的端口,默认为 25', '请填写SMTP端口号', 'common', 'common_email_smtp_port', '1580643917'), ('47', '', '发信人邮件地址', '发信人邮件地址,使用SMTP协议发送的邮件地址,如 shopxo@163.com', '请填写发信人邮件地址', 'common', 'common_email_smtp_account', '1580643917'), ('48', '', 'SMTP身份验证用户名', '如 shopxo@163.com', '请填写SMTP身份验证用户名', 'common', 'common_email_smtp_name', '1580643917'), ('49', '', 'SMTP身份验证密码', 'shopxo@163.com邮件的密码或授权码', '请填写SMTP身份验证密码', 'common', 'common_email_smtp_pwd', '1580643917'), ('50', '', '发件人显示名称', '如 ShopXO', '', 'common', 'common_email_smtp_send_name', '1580643917'), ('51', '', '通用-短信模板ID', '验证码code', '请填写通用短信模板内容', 'common', 'common_sms_currency_template', '1587366205'), ('58', '', '短信KeySecret', 'Access Key Secret', '请填写Access Key Secret', 'common', 'common_sms_apisecret', '1587366196'), ('53', '021-88888888', '商店电话', '空则不显示', '', 'common', 'common_customer_store_tel', '1587138005'), ('56', '

通用模板,你的验证码是  #code#

', '通用-邮件模板', '验证码变量标识符 [ #code# ]', '', 'common', 'common_email_currency_template', '1557728601'), ('57', 'default', '默认模板', '前台默认模板', '请填写默认模板', 'common', 'common_default_theme', '1550113393'), ('62', '', '百度地图api密钥', '百度地图api密钥', '请填写百度地图api密钥', 'common', 'common_baidu_map_ak', '1587366387'), ('63', '

用户注册,你的验证码是  #code#

', '用户注册-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_reg', '1557728601'), ('64', '

密码找回,你的验证码是  #code#

', '密码找回-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_forget_pwd', '1557728601'), ('65', '

邮箱绑定,你的验证码是  #code#

', '邮箱绑定-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_email_binding', '1557728601'), ('66', '20200202', 'css/js版本标记', '用于css/js浏览器缓存版本识别', '', 'home', 'home_static_cache_version', '1581399671'), ('67', '', '手机号码绑定-短信模板ID', '验证码code', '请填写手机号码绑定短信模板内容', 'home', 'home_sms_user_mobile_binding', '1587366205'), ('68', '连衣裙,帐篷,iphone,包包', '搜索关键字', '搜索框下热门关键字(输入回车)', '请填写关键字', 'home', 'home_search_keywords', '1566227458'), ('69', '2', '搜索关键字类型', '自定义需要配置以下关键字', '请选择关键字类型', 'home', 'home_search_keywords_type', '1566227458'), ('70', '0', '订单预约模式', '开启后用户提交订单需要管理员确认', '请选择是否开启预约模式', 'common', 'common_order_is_booking', '1589032774'), ('71', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_alipay_title', '1586248646'), ('72', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_alipay_describe', '1586248646'), ('73', '021-88888888', '客服电话', '空则不显示', '请填写客服电话', 'common', 'common_app_customer_service_tel', '1580643961'), ('74', '2019081966311589', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_alipay_appid', '1586248646'), ('75', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuxAXbZitfaALDaevrWVITveMu2fh3L8t3p/5WGPNEVOqCnL3v8EeYZWOLSuBHhpJaLb7Q3HrPWynzpcJ2C17+DxCVS3Js8J/iAgiJGJB4f8wZuPBwqKncGXdrAtN6EYp3H9K1IQeCmGN9di4Ht7igDDREnVWrUIc1Q6O64KDg8YLhWaTf2FMFvdPKiH9tijIZuvtYxxOUkHmgG6N7+IIvKPLdYde0dt/eTy6L1wbXSWoStfmFYd38vywt51N6AlChh/XAQmUGYTq1sW+PFXg2MrDyyWIEZxGb1dINhlMgXMqxTropo31kXa09vUffNvPWVmR38iT9lY+n6ZWSVzH3QIDAQAB', '应用公钥', '', '请填写应用公钥', 'common', 'common_app_mini_alipay_rsa_public', '1586248646'), ('76', 'MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQC7EBdtmK19oAsNp6+tZUhO94y7Z+Hcvy3en/lYY80RU6oKcve/wR5hlY4tK4EeGklotvtDces9bKfOlwnYLXv4PEJVLcmzwn+ICCIkYkHh/zBm48HCoqdwZd2sC03oRincf0rUhB4KYY312Lge3uKAMNESdVatQhzVDo7rgoODxguFZpN/YUwW908qIf22KMhm6+1jHE5SQeaAbo3v4gi8o8t1h17R2395PLovXBtdJahK1+YVh3fy/LC3nU3oCUKGH9cBCZQZhOrWxb48VeDYysPLJYgRnEZvV0g2GUyBcyrFOuimjfWRdrT29R98289ZWZHfyJP2Vj6fplZJXMfdAgMBAAECggEAXXHCYkscj169ZsrXZUTtBBWBRbS1DTKrVUSQqGjibb9fd+zKeg2cgZ7V8RaEX2c+OIL/rUdg/cQjZ33nuwetn+lqMWa4FYYZcvitJYO36Y8yvJMVnYbnIayhOWpENr2l97HWzaZZ41GsOp1SDInGl8bLCe93pwEZqgyltFv0GoSfNu3trFFxPZgZJalV0t5M7+RchutkHskwrwI9BdnCJs38lh08jHHppQdkgcpyCiCdu/b4f+n9z97Op5Va8WY1M+wwqRk76Ias8mqwJXT/+t/sXhqkMv1ylAb89+b3rgiOU7KlZMpIAercW/ZRojnDjpY9ViaCxwWPwb/VkPrDgQKBgQDkDuie0DAIDP5C74dPj/Z0mapsU9bKlcgC+nowEUaEO7A9cwMVFal0x9p7BKIJsV2b6d1qJGP7rM9YtRMldJQmuxPcHOKPcZR8pGLqFYT2QGKGurohb/o+btGda/SGwJfi6jwQUF0AE+1k+Dj9P3hDxHgkj6ZMkHEBtqUj520VTQKBgQDR+1rPPex8zTQgl9uSY0hlXPyYEhpXicNhzyet1Su+TV8wdGNUr2YeuDHEu6oiRocBaT8DEwpy9EToe56EK3Ht2AQ76NBSUp9EOl1twocebM42etJSJZGpB1AgP+R/hmUbcBPXEwXdy5XeYnYmpVUcoizzKrnRDxg3TRF3kIX00QKBgGc49EMFmefa8a6cOdNiJrvp3YBAhkSVfL0UX/+nohIx7fgyOV/uuQ9ZceMiWrEmbWcneAcVx4dfVU4iTzMxy+in3jpPfKBOWVX9FaQ77z2CMNYoaBzAUTS29ftZpIjlXRngySTdKurhGh8MVscRVj7eCz8JIc0fx3ZuE9rnYbE1AoGAJoqJL3LBPmL3x2e4IJVii2BW6J6iASFDIGfCc7Cl18chyqYCOV/8UXUjhWWgo6voScUEkM7k4xacs0NFZCMJRUuZ81kXK5UIsKA519SVsmrsKqm+gt9sbebuuQyhJxsG4dNfgOF3+S7N8kSGRS+hgKDvuS5Fbu7jVfsqUpTPUZECgYAcbq3mqWwExY2Kn0I660OqOFk620pGsSY7gECUQintCZioYemzC1TN9pM6fKnOIYriV4Ou7iswhEfVX+5bwMjH2ujmu8KDdpkpdhRoFCw3GUn/PDelQrptaKkKXnOIJe/R8m+TUxYCtECTlKlYS4hTst7YhTDz5sQHcXRtveATZQ==', '应用私钥', '', '请填写应用私钥', 'common', 'common_app_mini_alipay_rsa_private', '1586248646'), ('78', '0', '是否启用搜索', '默认否', '', 'common', 'common_app_is_enable_search', '1580559058'), ('77', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAkwpOGFOJ0GF6vN9k2dih7Up4+0qecYGtGeZMLdkArDMQ3vgvZFyjAM8c6uFRCHfVoUF5mflVVskLaXMH9C3VY80fxE40WM3VXVW+z0M+WFdihmfB6m/xKpN0QkMVEce7yb7AyXAdNA20KKyjVKXAnDGU3nGc6grQ6uzNIp/Eb8jMPv91GOjzY8KYOxgSiVVM9p5Y1NedGBTQGeMWcRH5vi9ys2Ia0KDYtxuXDhIxMDAqrCNy5sODh0DUpTL+Di09jQRmdI9JNN79ibVmrBoU7ud8YbL/lR4iVT+zF848+OmJiK56yTLcxY8vrU2kGlGO2K8jKWDsOK93H0GF/+lA+wIDAQAB', '支付宝公钥', '', '请填写支付宝公钥', 'common', 'common_app_mini_alipay_out_rsa_public', '1586248646'), ('79', '0', '是否启用留言', '默认否', '', 'common', 'common_app_is_enable_answer', '1580559058'), ('80', '3', '商品可添加规格最大数量', '建议不超过3个规格', '请填写谷歌最大数', 'common', 'common_spec_add_max_number', '1587366387'), ('81', '-', '路由分隔符', '建议填写 [ - ] 默认 [ - ] ,仅PATHINFO模式+短地址模式下有效', '请填写路由分隔符', 'common', 'common_route_separator', '1585733314'), ('82', 'wx0a2012ebad94beff', 'AppID', '小程序ID', '请填写appid', 'common', 'common_app_mini_weixin_appid', '1581478933'), ('83', 'd0e4e81180ea59b8fcc4299f6b05b362', 'AppSecret ', '小程序密钥', '请填写appsecret', 'common', 'common_app_mini_weixin_appsecret', '1581478933'), ('84', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_weixin_title', '1581478933'), ('85', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_weixin_describe', '1581478933'), ('61', '用户中心公告文字,后台配置修改。', '用户中心公告', '空则不显示公告', '', 'common', 'common_user_center_notice', '1580643961'), ('8', '公告内容', '商城公告', '空则不显示公告', '', 'common', 'common_shop_notice', '1580643961'), ('86', 'test@qq.com', '商店邮箱', '空则不显示', '客服邮箱格式有误', 'common', 'common_customer_store_email', '1587138005'), ('87', '', '商店二维码', '空则不展示', '', 'common', 'common_customer_store_qrcode', '1587366387'), ('152', '[{\"alias\":\"总部\",\"name\":\"devil\",\"tel\":\"13222333333\",\"lng\":\"121.594278\",\"lat\":\"31.207917\",\"address\":\"张江高科\",\"province\":\"9\",\"city\":\"155\",\"county\":\"1937\",\"province_name\":\"上海市\",\"city_name\":\"浦东新区\",\"county_name\":\"张江镇\",\"id\":0}]', '自提点地址', '', '请填写自提点地址', 'common', 'common_self_extraction_address', '1589032774'), ('88', '上海市 浦东新区', '商店地址', '空则不展示', '', 'common', 'common_customer_store_address', '1587138005'), ('89', '

用户注册协议


', '用户注册协议', '最多 105000 个字符', '用户注册协议最多 105000 个字符', 'common', 'common_agreement_userregister', '1566227622'), ('90', '/static/upload/images/common/2019/05/17/1558025141249118.png', '用户注册背景图片', '', '请上传用户注册背景图片', 'home', 'home_site_user_register_bg_images', '1566227415'), ('91', '/static/upload/images/common/2019/05/17/1558062481107570.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad1_images', '1558084931'), ('92', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad2_images', '1558084931'), ('93', '/static/upload/images/common/2019/05/17/1558073623385520.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad3_images', '1558084931'), ('94', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad1_url', '1558084931'), ('95', 'https://ask.shopxo.net/', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad2_url', '1558084931'), ('96', 'https://shopxo.net/vip.html', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad3_url', '1558084931'), ('97', '', '背景色', '背景色1', '', 'home', 'home_site_user_login_ad1_bg_color', '1558084931'), ('98', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_login_ad2_bg_color', '1558084931'), ('99', '#FAFAFA', '背景色', '背景色3', '', 'home', 'home_site_user_login_ad3_bg_color', '1558084931'), ('100', '1', '登录图片验证码', '可以防止非法登录', '请选择是否开启登录图片验证码', 'home', 'home_user_login_img_verify_state', '1558084931'), ('101', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad1_images', '1558084915'), ('102', '/static/upload/images/common/2019/05/17/1558073623641199.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad2_images', '1558084915'), ('103', '', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad3_images', '1558084915'), ('104', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad1_url', '1558084915'), ('105', '', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad2_url', '1558084915'), ('106', '', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad3_url', '1558084915'), ('107', '#FAFAFA', '背景色', '背景色1', '', 'home', 'home_site_user_forgetpwd_ad1_bg_color', '1558084915'), ('108', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_forgetpwd_ad2_bg_color', '1558084915'), ('109', '', '背景色', '背景色3', '', 'home', 'home_site_user_forgetpwd_ad3_bg_color', '1558084915'), ('110', '1', '用户注册图片验证码', '可以防止非法注册', '请选择是否开启用户注册图片验证码', 'home', 'home_user_register_img_verify_state', '1566227415'), ('111', '', '图片验证码规则', '默认白底黑字,可根据需求i加大验证码识别难度', '', 'common', 'common_images_verify_rules', '1558085166'), ('112', '0', 'SSL方式加密', '', '请选择是否使用SSL方式加密', 'common', 'common_email_is_use_ssl', '1580643917'), ('113', '活动/优惠未生效\n空包裹\n包裹丢失\n配送超时\n未按约定时间发货\n未送货上门\n物流显示签收但实际未收到货\n不喜欢/不想要', '仅退款原因', '可换行,一行一个', '请填写仅退款原因', 'home', 'home_order_aftersale_return_only_money_reason', '1570193301'), ('114', '7天无理由退换货\n配送超时\n未按约定时间发货\n未送货上门\n卖家发错货\n少件/漏发\n包装/商品破损/污渍\n商品信息描述不符\n使用后过敏\n已过/临近保质期\n无法溶解/结块/有异物', '退货退款原因', '可换行,一行一个', '请填写退货退款原因', 'home', 'home_order_aftersale_return_money_goods_reason', '1570193301'), ('115', '1', '用户注册协议', '', '请选择是否启用用户注册协议', 'home', 'home_is_enable_userregister_agreement', '1566227415'), ('116', '上海市 浦东新区', '退货地址', '用户退货货物收货地址', '请填写退货地址', 'home', 'home_order_aftersale_return_goods_address', '1570193301'), ('117', '0', '使用独立手机详情', '默认使用web详情', '请选择使用独立手机详情', 'common', 'common_app_is_use_mobile_detail', '1580559058'), ('118', '0', '强制绑定手机', '默认否', '请选择是否强制绑定手机', 'common', 'common_user_is_mandatory_bind_mobile', '1580559058'), ('121', '0', '固定顶部导航', '默认否', '请选择是否固定顶部导航', 'common', 'common_app_is_header_nav_fixed', '1580559058'), ('122', '0', '开启在线客服', '默认否', '请选择是否开启在线客服', 'common', 'common_app_is_online_service', '1580559058'), ('123', '0', '启用限时秒杀', '默认否', '请选择是否启用限时秒杀', 'common', 'common_app_is_limitedtimediscount', '1580559058'), ('124', '0', '启用好物推荐', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用好物推荐', 'common', 'common_app_is_good_thing', '1587445586'), ('125', '16634987', 'AppID', '智能小程序ID', '请填写AppID', 'common', 'common_app_mini_baidu_appid', '1586249578'), ('126', 'C9Gg744cBqQ3zvbC5uOPMg9yWpmuQ8O7', 'AppKey', '智能小程序KEY', '请填写AppKey', 'common', 'common_app_mini_baidu_appkey', '1586249578'), ('127', 'KmdPEyuSAXcbiouKVq6LOSUjctZpxmNb', 'AppSecret', '智能小程序密匙', '请填写AppSecret', 'common', 'common_app_mini_baidu_appsecret', '1586249578'), ('128', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_baidu_title', '1586249578'), ('129', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_baidu_describe', '1586249578'), ('130', '0', '留言需要登录', '默认否', '请选择是否留言需要登录', 'common', 'common_is_login_answer', '1566124965'), ('131', '0', '启用海报分享', '默认否\n', '请选择是否启用海报分享\n', 'common', 'common_app_is_poster_share', '1587445586'), ('132', '30', '订单关闭脚本时长', '单位 分钟,默认30分钟', '请填写订单关闭脚本时长', 'common', 'common_order_close_limit_time', '1566124965'), ('133', '21600', '订单自动收货脚本时长', '单位 分钟,默认21600分钟/15天', '请填写订单自动收货脚本时长', 'common', 'common_order_success_limit_time', '1566124965'), ('134', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_toutiao_appid', '1580644065'), ('135', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_toutiao_appsecret', '1580644065'), ('136', '', 'PayMerchantID', '支付商户号', '请填写支付商户号', 'common', 'common_app_mini_toutiao_pay_merchant_id', '1580644065'), ('137', '', 'PayAppID', '支付AppID', '请填写AppID', 'common', 'common_app_mini_toutiao_pay_appid', '1580644065'), ('138', '', 'PaySecret', '支付Secret', '请填写支付Secret', 'common', 'common_app_mini_toutiao_pay_secret', '1580644065'), ('139', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_toutiao_title', '1580644065'), ('140', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_toutiao_describe', '1580644065'), ('141', '', '公安备案号', '如:京公网安备xxx号', '请填写公安备案号', 'home', 'home_site_security_record_name', '1572944120'), ('142', '', '公安备案地址', '备案展示页面的url地址', '请填写公安备案地址', 'home', 'home_site_security_record_url', '1572944120'), ('143', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_qq_appid', '1580644073'), ('144', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_qq_appsecret', '1580644073'), ('145', '', 'AppToken', '小程序Token', '请填写AppToken', 'common', 'common_app_mini_qq_apptoken', '1580644073'), ('146', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_qq_title', '1580644073'), ('147', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_qq_describe', '1580644073'), ('148', '0', '是否启用用户中心头部小导航', '默认否', '请选择是否启用用户中心头部小导航', 'common', 'common_app_is_head_vice_nav', '1580559058'), ('151', '4', '站点类型', '默认销售型', '请选择站点类型', 'common', 'common_site_type', '1589032774'), ('150', '', '展示型操作名称', '默认 立即咨询', '请填写展示型操作名称', 'common', 'common_is_exhibition_mode_btn_text', '1589032774'), ('153', '', '虚拟信息标题', '默认密钥信息', '请填写虚拟信息标题', 'common', 'common_site_fictitious_return_title', '1589032774'), ('154', '', '提示信息', '', '请填写提示信息', 'common', 'common_site_fictitious_return_tips', '1589032774'), ('155', '', '在线客服-企业编码', '空则不显示在线客服', '请填写在线客服-企业编码', 'common', 'common_app_mini_alipay_tnt_inst_id', '1580643970'), ('156', '', '在线客服-聊天窗编码', '空则不显示在线客服', '请填写在线客服-聊天窗编码', 'common', 'common_app_mini_alipay_scene', '1580643970'), ('157', '0', '商品详情页展示相册', '默认否', '请选择是否商品详情页展示相册', 'common', 'common_is_goods_detail_show_photo', '1575273956'), ('158', '0', '手机简洁模式', '默认否', '请选择是否手机简洁模式', 'common', 'common_is_mobile_concise_model', '1580643961'), ('159', '0', '启用直播', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用直播', 'common', 'common_app_weixin_liveplayer', '1587445586'),(160, 'tencent', '短信平台', '选择使用的短信平台', '请确认使用的配置是适合当前所选短信平台的。', 'common', 'common_sms_platform', 1590335998),(161, '1400368404', '短信平台APP_ID', '腾讯云必填字段,可以在腾讯云/短信/应用管理找到', '腾讯云必须填写此字段', 'common', 'common_sms_sdk_appid', 1590335998); +INSERT INTO `s_config` VALUES ('15', '10', '分页数量', '分页显示数量', '分页不能超过3位数', 'admin', 'admin_page_number', '1587366387'), ('59', '1', '扣减库存规则', '需扣减库存开启方可有效,默认订单支付成功', '', 'common', 'common_deduction_inventory_rules', '1589032774'), ('60', '1', '是否扣减库存', '建议不要随意修改,以免造成库存数据错乱,关闭不影响库存回滚', '', 'common', 'common_is_deduction_inventory', '1589032774'), ('11', '0', 'Excel编码', 'excel模块编码选择', '请选择编码', 'admin', 'admin_excel_charset', '1587366387'), ('16', 'ShopXO企业级B2C电商系统提供商 - 演示站点', '站点标题', '浏览器标题,一般不超过80个字符', '站点标题不能为空', 'home', 'home_seo_site_title', '1585733314'), ('17', '商城系统,开源电商系统,免费电商系统,PHP电商系统,商城系统,B2C电商系统,B2B2C电商系统', '站点关键字', '一般不超过100个字符,多个关键字以半圆角逗号 [ , ] 隔开', '站点关键字不能为空', 'home', 'home_seo_site_keywords', '1585733314'), ('18', 'ShopXO是国内领先的商城系统提供商,为企业提供php商城系统、微信商城、小程序。', '站点描述', '站点描述,一般不超过200个字符', '站点描述不能为空', 'home', 'home_seo_site_description', '1585733314'), ('19', '', 'ICP证书号', 'ICP域名备案号', '', 'home', 'home_site_icp', '1572944120'), ('20', '', '底部统计代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_statistics_code', '0'), ('21', '1', '站点状态', '可暂时将站点关闭,其他人无法访问,但不影响管理员访问后台', '请选择站点状态', 'home', 'home_site_state', '1581399671'), ('22', '升级中...', '关闭原因', '支持html,当网站处于关闭状态时,关闭原因将显示在前台', '', 'home', 'home_site_close_reason', '1581399671'), ('23', 'Australia/Eucla', '默认时区', '默认 亚洲/上海 [标准时+8]', '请选择默认时区', 'common', 'common_timezone', '1581399671'), ('24', '', '底部代码', '支持html,可用于添加流量统计代码', '', 'home', 'home_footer_info', '1581399671'), ('28', 'ShopXO', '站点名称', '', '站点名称不能为空', 'home', 'home_site_name', '1581399671'), ('29', '0', '链接模式', '详情ThinkPHP官网5.1版本文档 [http://www.thinkphp.cn/]', '请选择url模式', 'home', 'home_seo_url_model', '1585733314'), ('25', '2048000', '图片最大限制', '单位B [上传图片还受到服务器空间PHP配置最大上传 20M 限制]', '请填写图片上传最大限制', 'home', 'home_max_limit_image', '1558074966'), ('26', '51200000', '文件最大限制', '单位B [上传文件还受到服务器空间PHP配置最大上传 20M 限制]', '请填写文件上传最大限制', 'home', 'home_max_limit_file', '1558074966'), ('27', '102400000', '视频最大限制', '单位B [上传视频还受到服务器空间PHP配置最大上传 20M 限制]', '请填写视频上传最大限制', 'home', 'home_max_limit_video', '1558074966'), ('30', 'html', '伪静态后缀', '链接后面的后缀别名,默认 [ html ]', '小写字母,不能超过8个字符', 'home', 'home_seo_url_html_suffix', '1585733314'), ('31', '0', '用户注册开启审核', '开启后用户注册需要审核通过方可登录', '请选择用户注册开启审核', 'common', 'common_register_is_enable_audit', '1566227415'), ('32', '/static/upload/images/common/2019/01/14/1547448748316693.png', '手机端logo', '支持 [jpg, png, gif]', '请上传手机端网站logo', 'home', 'home_site_logo_wap', '1581399671'), ('33', '/static/upload/images/common/2019/01/14/1547448705165706.png', '电脑端logo', '支持 [jpg, png, gif]', '请上传电脑端网站logo', 'home', 'home_site_logo', '1581399671'), ('34', '1200', '页面最大宽度', '页面最大宽度,单位px,0则100%', '请上传桌面图标', 'home', 'home_content_max_width', '1581399671'), ('35', '/static/upload/images/common/2019/01/14/1547448728921121.jpg', '桌面图标', '建议使用png格式', '图片比例值格式有误 0~100 之间,小数点后面最大两位', 'common', 'home_site_desktop_icon', '1581399671'), ('36', 'sms,email,username', '是否开启注册', '关闭注册后,前端站点将无法注册,可选择 [ 短信, 邮箱, 用户名 ]', '请选择是否开启注册状态', 'home', 'home_user_reg_state', '1566227415'), ('37', '1', '是否开启登录', '关闭后,前端站点将无法登录', '请选择是否开启登录状态', 'home', 'home_user_login_state', '1558084931'), ('38', '1', '获取验证码-开启图片验证码', '防止短信轰炸', '请选择是否开启强制图片验证码', 'home', 'home_img_verify_state', '1558085166'), ('39', '60', '获取验证码时间间隔', '防止频繁获取验证码,一般在 30~120 秒之间,单位 [秒]', '请填写获取验证码时间间隔', 'home', 'common_verify_time_interval', '1558085166'), ('40', '', '用户注册-短信模板ID', '验证码code', '请填写用户注册短信模板内容', 'home', 'home_sms_user_reg', '1587366205'), ('41', '', '短信签名', '发送短信包含的签名', '短信签名 3~8 个的中英文字符', 'common', 'common_sms_sign', '1587366196'), ('42', '', '短信KeyID', 'Access Key ID', '请填写Access Key ID', 'common', 'common_sms_apikey', '1587366196'), ('43', '', '密码找回-短信模板ID', '验证码code', '请填写密码找回短信模板内容', 'home', 'home_sms_user_forget_pwd', '1587366205'), ('44', '600', '验证码有效时间', '验证码过期时间,一般10分钟左右,单位 [秒]', '请填写验证码有效时间', 'home', 'common_verify_expire_time', '1558085166'), ('45', '', 'SMTP服务器', '设置SMTP服务器的地址,如 smtp.163.com', '请填写SMTP服务器', 'common', 'common_email_smtp_host', '1580643917'), ('46', '', 'SMTP端口', '设置SMTP服务器的端口,默认为 25', '请填写SMTP端口号', 'common', 'common_email_smtp_port', '1580643917'), ('47', '', '发信人邮件地址', '发信人邮件地址,使用SMTP协议发送的邮件地址,如 shopxo@163.com', '请填写发信人邮件地址', 'common', 'common_email_smtp_account', '1580643917'), ('48', '', 'SMTP身份验证用户名', '如 shopxo@163.com', '请填写SMTP身份验证用户名', 'common', 'common_email_smtp_name', '1580643917'), ('49', '', 'SMTP身份验证密码', 'shopxo@163.com邮件的密码或授权码', '请填写SMTP身份验证密码', 'common', 'common_email_smtp_pwd', '1580643917'), ('50', '', '发件人显示名称', '如 ShopXO', '', 'common', 'common_email_smtp_send_name', '1580643917'), ('51', '', '通用-短信模板ID', '验证码code', '请填写通用短信模板内容', 'common', 'common_sms_currency_template', '1587366205'), ('58', '', '短信KeySecret', 'Access Key Secret', '请填写Access Key Secret', 'common', 'common_sms_apisecret', '1587366196'), ('53', '021-88888888', '商店电话', '空则不显示', '', 'common', 'common_customer_store_tel', '1587138005'), ('56', '

通用模板,你的验证码是  #code#

', '通用-邮件模板', '验证码变量标识符 [ #code# ]', '', 'common', 'common_email_currency_template', '1557728601'), ('57', 'default', '默认模板', '前台默认模板', '请填写默认模板', 'common', 'common_default_theme', '1550113393'), ('62', '', '百度地图api密钥', '百度地图api密钥', '请填写百度地图api密钥', 'common', 'common_baidu_map_ak', '1587366387'), ('63', '

用户注册,你的验证码是  #code#

', '用户注册-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_reg', '1557728601'), ('64', '

密码找回,你的验证码是  #code#

', '密码找回-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_forget_pwd', '1557728601'), ('65', '

邮箱绑定,你的验证码是  #code#

', '邮箱绑定-邮件模板', '验证码变量标识符 [ #code# ]', '', 'home', 'home_email_user_email_binding', '1557728601'), ('66', '20200202', 'css/js版本标记', '用于css/js浏览器缓存版本识别', '', 'home', 'home_static_cache_version', '1581399671'), ('67', '', '手机号码绑定-短信模板ID', '验证码code', '请填写手机号码绑定短信模板内容', 'home', 'home_sms_user_mobile_binding', '1587366205'), ('68', '连衣裙,帐篷,iphone,包包', '搜索关键字', '搜索框下热门关键字(输入回车)', '请填写关键字', 'home', 'home_search_keywords', '1566227458'), ('69', '2', '搜索关键字类型', '自定义需要配置以下关键字', '请选择关键字类型', 'home', 'home_search_keywords_type', '1566227458'), ('70', '0', '订单预约模式', '开启后用户提交订单需要管理员确认', '请选择是否开启预约模式', 'common', 'common_order_is_booking', '1589032774'), ('71', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_alipay_title', '1586248646'), ('72', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_alipay_describe', '1586248646'), ('73', '021-88888888', '客服电话', '空则不显示', '请填写客服电话', 'common', 'common_app_customer_service_tel', '1580643961'), ('74', '2019081966311589', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_alipay_appid', '1586248646'), ('75', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAuxAXbZitfaALDaevrWVITveMu2fh3L8t3p/5WGPNEVOqCnL3v8EeYZWOLSuBHhpJaLb7Q3HrPWynzpcJ2C17+DxCVS3Js8J/iAgiJGJB4f8wZuPBwqKncGXdrAtN6EYp3H9K1IQeCmGN9di4Ht7igDDREnVWrUIc1Q6O64KDg8YLhWaTf2FMFvdPKiH9tijIZuvtYxxOUkHmgG6N7+IIvKPLdYde0dt/eTy6L1wbXSWoStfmFYd38vywt51N6AlChh/XAQmUGYTq1sW+PFXg2MrDyyWIEZxGb1dINhlMgXMqxTropo31kXa09vUffNvPWVmR38iT9lY+n6ZWSVzH3QIDAQAB', '应用公钥', '', '请填写应用公钥', 'common', 'common_app_mini_alipay_rsa_public', '1586248646'), ('76', 'MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQC7EBdtmK19oAsNp6+tZUhO94y7Z+Hcvy3en/lYY80RU6oKcve/wR5hlY4tK4EeGklotvtDces9bKfOlwnYLXv4PEJVLcmzwn+ICCIkYkHh/zBm48HCoqdwZd2sC03oRincf0rUhB4KYY312Lge3uKAMNESdVatQhzVDo7rgoODxguFZpN/YUwW908qIf22KMhm6+1jHE5SQeaAbo3v4gi8o8t1h17R2395PLovXBtdJahK1+YVh3fy/LC3nU3oCUKGH9cBCZQZhOrWxb48VeDYysPLJYgRnEZvV0g2GUyBcyrFOuimjfWRdrT29R98289ZWZHfyJP2Vj6fplZJXMfdAgMBAAECggEAXXHCYkscj169ZsrXZUTtBBWBRbS1DTKrVUSQqGjibb9fd+zKeg2cgZ7V8RaEX2c+OIL/rUdg/cQjZ33nuwetn+lqMWa4FYYZcvitJYO36Y8yvJMVnYbnIayhOWpENr2l97HWzaZZ41GsOp1SDInGl8bLCe93pwEZqgyltFv0GoSfNu3trFFxPZgZJalV0t5M7+RchutkHskwrwI9BdnCJs38lh08jHHppQdkgcpyCiCdu/b4f+n9z97Op5Va8WY1M+wwqRk76Ias8mqwJXT/+t/sXhqkMv1ylAb89+b3rgiOU7KlZMpIAercW/ZRojnDjpY9ViaCxwWPwb/VkPrDgQKBgQDkDuie0DAIDP5C74dPj/Z0mapsU9bKlcgC+nowEUaEO7A9cwMVFal0x9p7BKIJsV2b6d1qJGP7rM9YtRMldJQmuxPcHOKPcZR8pGLqFYT2QGKGurohb/o+btGda/SGwJfi6jwQUF0AE+1k+Dj9P3hDxHgkj6ZMkHEBtqUj520VTQKBgQDR+1rPPex8zTQgl9uSY0hlXPyYEhpXicNhzyet1Su+TV8wdGNUr2YeuDHEu6oiRocBaT8DEwpy9EToe56EK3Ht2AQ76NBSUp9EOl1twocebM42etJSJZGpB1AgP+R/hmUbcBPXEwXdy5XeYnYmpVUcoizzKrnRDxg3TRF3kIX00QKBgGc49EMFmefa8a6cOdNiJrvp3YBAhkSVfL0UX/+nohIx7fgyOV/uuQ9ZceMiWrEmbWcneAcVx4dfVU4iTzMxy+in3jpPfKBOWVX9FaQ77z2CMNYoaBzAUTS29ftZpIjlXRngySTdKurhGh8MVscRVj7eCz8JIc0fx3ZuE9rnYbE1AoGAJoqJL3LBPmL3x2e4IJVii2BW6J6iASFDIGfCc7Cl18chyqYCOV/8UXUjhWWgo6voScUEkM7k4xacs0NFZCMJRUuZ81kXK5UIsKA519SVsmrsKqm+gt9sbebuuQyhJxsG4dNfgOF3+S7N8kSGRS+hgKDvuS5Fbu7jVfsqUpTPUZECgYAcbq3mqWwExY2Kn0I660OqOFk620pGsSY7gECUQintCZioYemzC1TN9pM6fKnOIYriV4Ou7iswhEfVX+5bwMjH2ujmu8KDdpkpdhRoFCw3GUn/PDelQrptaKkKXnOIJe/R8m+TUxYCtECTlKlYS4hTst7YhTDz5sQHcXRtveATZQ==', '应用私钥', '', '请填写应用私钥', 'common', 'common_app_mini_alipay_rsa_private', '1586248646'), ('78', '0', '是否启用搜索', '默认否', '', 'common', 'common_app_is_enable_search', '1580559058'), ('77', 'MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAkwpOGFOJ0GF6vN9k2dih7Up4+0qecYGtGeZMLdkArDMQ3vgvZFyjAM8c6uFRCHfVoUF5mflVVskLaXMH9C3VY80fxE40WM3VXVW+z0M+WFdihmfB6m/xKpN0QkMVEce7yb7AyXAdNA20KKyjVKXAnDGU3nGc6grQ6uzNIp/Eb8jMPv91GOjzY8KYOxgSiVVM9p5Y1NedGBTQGeMWcRH5vi9ys2Ia0KDYtxuXDhIxMDAqrCNy5sODh0DUpTL+Di09jQRmdI9JNN79ibVmrBoU7ud8YbL/lR4iVT+zF848+OmJiK56yTLcxY8vrU2kGlGO2K8jKWDsOK93H0GF/+lA+wIDAQAB', '支付宝公钥', '', '请填写支付宝公钥', 'common', 'common_app_mini_alipay_out_rsa_public', '1586248646'), ('79', '0', '是否启用留言', '默认否', '', 'common', 'common_app_is_enable_answer', '1580559058'), ('80', '3', '商品可添加规格最大数量', '建议不超过3个规格', '请填写谷歌最大数', 'common', 'common_spec_add_max_number', '1587366387'), ('81', '-', '路由分隔符', '建议填写 [ - ] 默认 [ - ] ,仅PATHINFO模式+短地址模式下有效', '请填写路由分隔符', 'common', 'common_route_separator', '1585733314'), ('82', 'wx0a2012ebad94beff', 'AppID', '小程序ID', '请填写appid', 'common', 'common_app_mini_weixin_appid', '1581478933'), ('83', 'd0e4e81180ea59b8fcc4299f6b05b362', 'AppSecret ', '小程序密钥', '请填写appsecret', 'common', 'common_app_mini_weixin_appsecret', '1581478933'), ('84', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_weixin_title', '1581478933'), ('85', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_weixin_describe', '1581478933'), ('61', '用户中心公告文字,后台配置修改。', '用户中心公告', '空则不显示公告', '', 'common', 'common_user_center_notice', '1580643961'), ('8', '公告内容', '商城公告', '空则不显示公告', '', 'common', 'common_shop_notice', '1580643961'), ('86', 'test@qq.com', '商店邮箱', '空则不显示', '客服邮箱格式有误', 'common', 'common_customer_store_email', '1587138005'), ('87', '', '商店二维码', '空则不展示', '', 'common', 'common_customer_store_qrcode', '1587366387'), ('152', '[{\"alias\":\"总部\",\"name\":\"devil\",\"tel\":\"13222333333\",\"lng\":\"121.594278\",\"lat\":\"31.207917\",\"address\":\"张江高科\",\"province\":\"9\",\"city\":\"155\",\"county\":\"1937\",\"province_name\":\"上海市\",\"city_name\":\"浦东新区\",\"county_name\":\"张江镇\",\"id\":0}]', '自提点地址', '', '请填写自提点地址', 'common', 'common_self_extraction_address', '1589032774'), ('88', '上海市 浦东新区', '商店地址', '空则不展示', '', 'common', 'common_customer_store_address', '1587138005'), ('89', '

用户注册协议


', '用户注册协议', '最多 105000 个字符', '用户注册协议最多 105000 个字符', 'common', 'common_agreement_userregister', '1566227622'), ('90', '/static/upload/images/common/2019/05/17/1558025141249118.png', '用户注册背景图片', '', '请上传用户注册背景图片', 'home', 'home_site_user_register_bg_images', '1566227415'), ('91', '/static/upload/images/common/2019/05/17/1558062481107570.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad1_images', '1558084931'), ('92', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad2_images', '1558084931'), ('93', '/static/upload/images/common/2019/05/17/1558073623385520.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_login_ad3_images', '1558084931'), ('94', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad1_url', '1558084931'), ('95', 'https://ask.shopxo.net/', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad2_url', '1558084931'), ('96', 'https://shopxo.net/vip.html', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_login_ad3_url', '1558084931'), ('97', '', '背景色', '背景色1', '', 'home', 'home_site_user_login_ad1_bg_color', '1558084931'), ('98', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_login_ad2_bg_color', '1558084931'), ('99', '#FAFAFA', '背景色', '背景色3', '', 'home', 'home_site_user_login_ad3_bg_color', '1558084931'), ('100', '1', '登录图片验证码', '可以防止非法登录', '请选择是否开启登录图片验证码', 'home', 'home_user_login_img_verify_state', '1558084931'), ('101', '/static/upload/images/common/2019/05/17/1558072588843696.jpg', '图片', '图片1 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad1_images', '1558084915'), ('102', '/static/upload/images/common/2019/05/17/1558073623641199.jpg', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad2_images', '1558084915'), ('103', '', '图片', '图片2 [ 建议使用 450X350 像数 ]', '', 'home', 'home_site_user_forgetpwd_ad3_images', '1558084915'), ('104', 'https://shopxo.net/', 'url地址', '地址1 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad1_url', '1558084915'), ('105', '', 'url地址', '地址2 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad2_url', '1558084915'), ('106', '', 'url地址', '地址3 [ 带http://或https:// ]', '', 'home', 'home_site_user_forgetpwd_ad3_url', '1558084915'), ('107', '#FAFAFA', '背景色', '背景色1', '', 'home', 'home_site_user_forgetpwd_ad1_bg_color', '1558084915'), ('108', '#FAFAFA', '背景色', '背景色2', '', 'home', 'home_site_user_forgetpwd_ad2_bg_color', '1558084915'), ('109', '', '背景色', '背景色3', '', 'home', 'home_site_user_forgetpwd_ad3_bg_color', '1558084915'), ('110', '1', '用户注册图片验证码', '可以防止非法注册', '请选择是否开启用户注册图片验证码', 'home', 'home_user_register_img_verify_state', '1566227415'), ('111', '', '图片验证码规则', '默认白底黑字,可根据需求i加大验证码识别难度', '', 'common', 'common_images_verify_rules', '1558085166'), ('112', '0', 'SSL方式加密', '', '请选择是否使用SSL方式加密', 'common', 'common_email_is_use_ssl', '1580643917'), ('113', '活动/优惠未生效\n空包裹\n包裹丢失\n配送超时\n未按约定时间发货\n未送货上门\n物流显示签收但实际未收到货\n不喜欢/不想要', '仅退款原因', '可换行,一行一个', '请填写仅退款原因', 'home', 'home_order_aftersale_return_only_money_reason', '1570193301'), ('114', '7天无理由退换货\n配送超时\n未按约定时间发货\n未送货上门\n卖家发错货\n少件/漏发\n包装/商品破损/污渍\n商品信息描述不符\n使用后过敏\n已过/临近保质期\n无法溶解/结块/有异物', '退货退款原因', '可换行,一行一个', '请填写退货退款原因', 'home', 'home_order_aftersale_return_money_goods_reason', '1570193301'), ('115', '1', '用户注册协议', '', '请选择是否启用用户注册协议', 'home', 'home_is_enable_userregister_agreement', '1566227415'), ('116', '上海市 浦东新区', '退货地址', '用户退货货物收货地址', '请填写退货地址', 'home', 'home_order_aftersale_return_goods_address', '1570193301'), ('117', '0', '使用独立手机详情', '默认使用web详情', '请选择使用独立手机详情', 'common', 'common_app_is_use_mobile_detail', '1580559058'), ('118', '0', '强制绑定手机', '默认否', '请选择是否强制绑定手机', 'common', 'common_user_is_mandatory_bind_mobile', '1580559058'), ('121', '0', '固定顶部导航', '默认否', '请选择是否固定顶部导航', 'common', 'common_app_is_header_nav_fixed', '1580559058'), ('122', '0', '开启在线客服', '默认否', '请选择是否开启在线客服', 'common', 'common_app_is_online_service', '1580559058'), ('123', '0', '启用限时秒杀', '默认否', '请选择是否启用限时秒杀', 'common', 'common_app_is_limitedtimediscount', '1580559058'), ('124', '0', '启用好物推荐', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用好物推荐', 'common', 'common_app_is_good_thing', '1587445586'), ('125', '16634987', 'AppID', '智能小程序ID', '请填写AppID', 'common', 'common_app_mini_baidu_appid', '1586249578'), ('126', 'C9Gg744cBqQ3zvbC5uOPMg9yWpmuQ8O7', 'AppKey', '智能小程序KEY', '请填写AppKey', 'common', 'common_app_mini_baidu_appkey', '1586249578'), ('127', 'KmdPEyuSAXcbiouKVq6LOSUjctZpxmNb', 'AppSecret', '智能小程序密匙', '请填写AppSecret', 'common', 'common_app_mini_baidu_appsecret', '1586249578'), ('128', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_baidu_title', '1586249578'), ('129', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_baidu_describe', '1586249578'), ('130', '0', '留言需要登录', '默认否', '请选择是否留言需要登录', 'common', 'common_is_login_answer', '1566124965'), ('131', '0', '启用海报分享', '默认否\n', '请选择是否启用海报分享\n', 'common', 'common_app_is_poster_share', '1587445586'), ('132', '30', '订单关闭脚本时长', '单位 分钟,默认30分钟', '请填写订单关闭脚本时长', 'common', 'common_order_close_limit_time', '1566124965'), ('133', '21600', '订单自动收货脚本时长', '单位 分钟,默认21600分钟/15天', '请填写订单自动收货脚本时长', 'common', 'common_order_success_limit_time', '1566124965'), ('134', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_toutiao_appid', '1580644065'), ('135', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_toutiao_appsecret', '1580644065'), ('136', '', 'PayMerchantID', '支付商户号', '请填写支付商户号', 'common', 'common_app_mini_toutiao_pay_merchant_id', '1580644065'), ('137', '', 'PayAppID', '支付AppID', '请填写AppID', 'common', 'common_app_mini_toutiao_pay_appid', '1580644065'), ('138', '', 'PaySecret', '支付Secret', '请填写支付Secret', 'common', 'common_app_mini_toutiao_pay_secret', '1580644065'), ('139', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_toutiao_title', '1580644065'), ('140', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_toutiao_describe', '1580644065'), ('141', '', '公安备案号', '如:京公网安备xxx号', '请填写公安备案号', 'home', 'home_site_security_record_name', '1572944120'), ('142', '', '公安备案地址', '备案展示页面的url地址', '请填写公安备案地址', 'home', 'home_site_security_record_url', '1572944120'), ('143', '', 'AppID', '小程序ID', '请填写AppID', 'common', 'common_app_mini_qq_appid', '1580644073'), ('144', '', 'AppSecret', '小程序Secret', '请填写AppSecret', 'common', 'common_app_mini_qq_appsecret', '1580644073'), ('145', '', 'AppToken', '小程序Token', '请填写AppToken', 'common', 'common_app_mini_qq_apptoken', '1580644073'), ('146', 'ShopXO', '名称', '', '请填写名称', 'common', 'common_app_mini_qq_title', '1580644073'), ('147', '国内领先企业级B2C开源电商系统!', '描述', '', '请填写描述', 'common', 'common_app_mini_qq_describe', '1580644073'), ('148', '0', '是否启用用户中心头部小导航', '默认否', '请选择是否启用用户中心头部小导航', 'common', 'common_app_is_head_vice_nav', '1580559058'), ('151', '4', '站点类型', '默认销售型', '请选择站点类型', 'common', 'common_site_type', '1589032774'), ('150', '', '展示型操作名称', '默认 立即咨询', '请填写展示型操作名称', 'common', 'common_is_exhibition_mode_btn_text', '1589032774'), ('153', '', '虚拟信息标题', '默认密钥信息', '请填写虚拟信息标题', 'common', 'common_site_fictitious_return_title', '1589032774'), ('154', '', '提示信息', '', '请填写提示信息', 'common', 'common_site_fictitious_return_tips', '1589032774'), ('155', '', '在线客服-企业编码', '空则不显示在线客服', '请填写在线客服-企业编码', 'common', 'common_app_mini_alipay_tnt_inst_id', '1580643970'), ('156', '', '在线客服-聊天窗编码', '空则不显示在线客服', '请填写在线客服-聊天窗编码', 'common', 'common_app_mini_alipay_scene', '1580643970'), ('157', '0', '商品详情页展示相册', '默认否', '请选择是否商品详情页展示相册', 'common', 'common_is_goods_detail_show_photo', '1575273956'), ('158', '0', '手机简洁模式', '默认否', '请选择是否手机简洁模式', 'common', 'common_is_mobile_concise_model', '1580643961'), ('159', '0', '启用直播', '默认否,需重新生成小程序包(启用则需到微信小程序后台申请权限)', '请选择是否启用直播', 'common', 'common_app_weixin_liveplayer', '1587445586'),(160, 'aliyun', '短信平台', '选择使用的短信平台', '请确认使用的配置是适合当前所选短信平台的。', 'common', 'common_sms_platform', 1590335998),(161, '', '短信平台APP_ID', '腾讯云必填字段,可以在腾讯云/短信/应用管理找到', '腾讯云必须填写此字段', 'common', 'common_sms_sdk_appid', 1590335998); COMMIT; -- ---------------------------- -- Gitee From e6ca3758e35c62558f09d1098768b697c6518d54 Mon Sep 17 00:00:00 2001 From: liuyi Date: Mon, 1 Jun 2020 23:01:33 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E5=8E=BB=E6=8E=89=E4=B8=80=E4=BA=9B?= =?UTF-8?q?=E4=B8=8D=E9=9C=80=E8=A6=81=E7=9A=84=E5=8F=98=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- extend/base/AliyunSms.php | 125 +++++++++++++++++++------------------ extend/base/Sms.php | 12 ++-- extend/base/TencentSms.php | 12 ++-- 3 files changed, 77 insertions(+), 72 deletions(-) diff --git a/extend/base/AliyunSms.php b/extend/base/AliyunSms.php index 37706e26d..3f4e2fd20 100755 --- a/extend/base/AliyunSms.php +++ b/extend/base/AliyunSms.php @@ -31,26 +31,25 @@ class AliyunSms // 签名 private $signName = ''; - // 模版ID - private $templateCode = ''; - + //短信平台返回的原始数据 + public $rawData; /** - * [__construct 构造方法] - * @author Devil - * @blog http://gong.gg/ - * @version 0.0.1 - * @datetime 2017-03-07T14:03:02+0800 - * @param [int] $param['interval_time'] [间隔时间(默认30)单位(秒)] - * @param [int] $param['expire_time'] [到期时间(默认30)单位(秒)] - * @param [string] $param['key_prefix'] [验证码种存储前缀key(默认 空)] - */ - public function __construct($param = array()) - { - $this->signName = MyC('common_sms_sign'); - $this->accessKeyId = MyC('common_sms_apikey'); - $this->accessKeySecret = MyC('common_sms_apisecret'); - } + * [__construct 构造方法] + * @author Devil + * @blog http://gong.gg/ + * @version 0.0.1 + * @datetime 2017-03-07T14:03:02+0800 + * @param [int] $param['interval_time'] [间隔时间(默认30)单位(秒)] + * @param [int] $param['expire_time'] [到期时间(默认30)单位(秒)] + * @param [string] $param['key_prefix'] [验证码种存储前缀key(默认 空)] + */ + public function __construct() + { + $this->signName = MyC('common_sms_sign'); + $this->accessKeyId = MyC('common_sms_apikey'); + $this->accessKeySecret = MyC('common_sms_apisecret'); + } private function percentEncode($string) { $string = urlencode ( $string ); @@ -62,8 +61,8 @@ class AliyunSms /** * 签名 * - * @param unknown $parameters - * @param unknown $accessKeySecret + * @param unknown $parameters + * @param unknown $accessKeySecret * @return string */ private function computeSignature($parameters, $accessKeySecret) { @@ -91,7 +90,7 @@ class AliyunSms */ public function SendCode($mobile, $code, $template_code, $sign_name = '') { - // 单个验证码需要校验是否频繁 + // 单个验证码需要校验是否频繁 if(is_string($code)) { @@ -105,18 +104,18 @@ class AliyunSms // 请求参数 $params = array ( //此处作了修改 - 'SignName' => $SignName, - 'Format' => 'JSON', - 'Version' => '2017-05-25', - 'AccessKeyId' => $this->accessKeyId, - 'SignatureVersion' => '1.0', - 'SignatureMethod' => 'HMAC-SHA1', - 'SignatureNonce' => uniqid (), - 'Timestamp' => gmdate ( 'Y-m-d\TH:i:s\Z' ), - 'Action' => 'SendSms', - 'TemplateCode' => $template_code, - 'PhoneNumbers' => $mobile, - 'TemplateParam' => json_encode($codes, JSON_UNESCAPED_UNICODE), + 'SignName' => $SignName, + 'Format' => 'JSON', + 'Version' => '2017-05-25', + 'AccessKeyId' => $this->accessKeyId, + 'SignatureVersion' => '1.0', + 'SignatureMethod' => 'HMAC-SHA1', + 'SignatureNonce' => uniqid (), + 'Timestamp' => gmdate ( 'Y-m-d\TH:i:s\Z' ), + 'Action' => 'SendSms', + 'TemplateCode' => $template_code, + 'PhoneNumbers' => $mobile, + 'TemplateParam' => json_encode($codes, JSON_UNESCAPED_UNICODE), ); //print_r($params);die; // 计算签名并把签名结果加入请求参数 @@ -124,7 +123,7 @@ class AliyunSms // 发送请求(此处作了修改) //$url = 'https://sms.aliyuncs.com/?' . http_build_query ( $params ); $url = 'http://dysmsapi.aliyuncs.com/?' . http_build_query ( $params ); - + $ch = curl_init (); curl_setopt ( $ch, CURLOPT_URL, $url ); curl_setopt ( $ch, CURLOPT_SSL_VERIFYPEER, FALSE ); @@ -134,6 +133,8 @@ class AliyunSms $result = curl_exec ( $ch ); curl_close ( $ch ); $result = json_decode ( $result, true ); + $this->rawData=$result; + //print_r($result);//die; if (isset ( $result ['Code'] ) && $result['Code'] != 'OK') { $this->error = $this->getErrorMessage ( $result ['Code'] ); @@ -146,39 +147,39 @@ class AliyunSms /** * 获取详细错误信息 * - * @param unknown $status + * @param unknown $status */ public function getErrorMessage($status) { // 阿里云的短信 乱八七糟的(其实是用的阿里大于) // https://api.alidayu.com/doc2/apiDetail?spm=a3142.7629140.1.19.SmdYoA&apiId=25450 $message = array ( - 'InvalidDayuStatus.Malformed' => '账户短信开通状态不正确', - 'InvalidSignName.Malformed' => '短信签名不正确或签名状态不正确', - 'InvalidTemplateCode.MalFormed' => '短信模板Code不正确或者模板状态不正确', - 'InvalidRecNum.Malformed' => '目标手机号不正确,单次发送数量不能超过100', - 'InvalidParamString.MalFormed' => '短信模板中变量不是json格式', - 'InvalidParamStringTemplate.Malformed' => '短信模板中变量与模板内容不匹配', - 'InvalidSendSms' => '触发业务流控', - 'InvalidDayu.Malformed' => '变量不能是url,可以将变量固化在模板中', - 'isv.RAM_PERMISSION_DENY' => 'RAM权限DENY', - 'isv.OUT_OF_SERVICE' => '业务停机', - 'isv.PRODUCT_UN_SUBSCRIPT' => '未开通云通信产品的阿里云客户', - 'isv.PRODUCT_UNSUBSCRIBE' => '产品未开通', - 'isv.ACCOUNT_NOT_EXISTS' => '账户不存在', - 'isv.ACCOUNT_ABNORMAL' => '账户异常', - 'isv.SMS_TEMPLATE_ILLEGAL' => '短信模板不合法', - 'isv.SMS_SIGNATURE_ILLEGAL' => '短信签名不合法', - 'isv.INVALID_PARAMETERS' => '参数异常', - 'isv.SYSTEM_ERROR' => '系统错误', - 'isv.MOBILE_NUMBER_ILLEGAL' => '非法手机号', - 'isv.MOBILE_COUNT_OVER_LIMIT' => '手机号码数量超过限制', - 'isv.TEMPLATE_MISSING_PARAMETERS' => '模板缺少变量', - 'isv.BUSINESS_LIMIT_CONTROL' => '业务限流', - 'isv.INVALID_JSON_PARAM' => 'JSON参数不合法,只接受字符串值', - 'isv.BLACK_KEY_CONTROL_LIMIT' => '黑名单管控', - 'isv.PARAM_LENGTH_LIMIT' => '参数超出长度限制', - 'isv.PARAM_NOT_SUPPORT_URL' => '不支持URL', - 'isv.AMOUNT_NOT_ENOUGH' => '账户余额不足', + 'InvalidDayuStatus.Malformed' => '账户短信开通状态不正确', + 'InvalidSignName.Malformed' => '短信签名不正确或签名状态不正确', + 'InvalidTemplateCode.MalFormed' => '短信模板Code不正确或者模板状态不正确', + 'InvalidRecNum.Malformed' => '目标手机号不正确,单次发送数量不能超过100', + 'InvalidParamString.MalFormed' => '短信模板中变量不是json格式', + 'InvalidParamStringTemplate.Malformed' => '短信模板中变量与模板内容不匹配', + 'InvalidSendSms' => '触发业务流控', + 'InvalidDayu.Malformed' => '变量不能是url,可以将变量固化在模板中', + 'isv.RAM_PERMISSION_DENY' => 'RAM权限DENY', + 'isv.OUT_OF_SERVICE' => '业务停机', + 'isv.PRODUCT_UN_SUBSCRIPT' => '未开通云通信产品的阿里云客户', + 'isv.PRODUCT_UNSUBSCRIBE' => '产品未开通', + 'isv.ACCOUNT_NOT_EXISTS' => '账户不存在', + 'isv.ACCOUNT_ABNORMAL' => '账户异常', + 'isv.SMS_TEMPLATE_ILLEGAL' => '短信模板不合法', + 'isv.SMS_SIGNATURE_ILLEGAL' => '短信签名不合法', + 'isv.INVALID_PARAMETERS' => '参数异常', + 'isv.SYSTEM_ERROR' => '系统错误', + 'isv.MOBILE_NUMBER_ILLEGAL' => '非法手机号', + 'isv.MOBILE_COUNT_OVER_LIMIT' => '手机号码数量超过限制', + 'isv.TEMPLATE_MISSING_PARAMETERS' => '模板缺少变量', + 'isv.BUSINESS_LIMIT_CONTROL' => '业务限流', + 'isv.INVALID_JSON_PARAM' => 'JSON参数不合法,只接受字符串值', + 'isv.BLACK_KEY_CONTROL_LIMIT' => '黑名单管控', + 'isv.PARAM_LENGTH_LIMIT' => '参数超出长度限制', + 'isv.PARAM_NOT_SUPPORT_URL' => '不支持URL', + 'isv.AMOUNT_NOT_ENOUGH' => '账户余额不足', ); if (isset ( $message [$status] )) { return $message [$status]; diff --git a/extend/base/Sms.php b/extend/base/Sms.php index 859b452e3..c46ab51b2 100755 --- a/extend/base/Sms.php +++ b/extend/base/Sms.php @@ -49,12 +49,16 @@ class Sms $this->sms_platform = MyC('common_sms_platform'); - if($this->sms_platform=='tencent'){ - $this->sms_instance=new \Base\TencentSms(); + $this->sms_instance=$this->getSmsInstance(); + + } + private function getSmsInstance(){ + if($this->sms_platform==$this->tencentType){ + return new \Base\TencentSms(); }else{ - $this->sms_instance=new \Base\AliyunSms(); + return new \Base\AliyunSms(); } - } + } /** diff --git a/extend/base/TencentSms.php b/extend/base/TencentSms.php index d853cfac1..216cee245 100755 --- a/extend/base/TencentSms.php +++ b/extend/base/TencentSms.php @@ -31,12 +31,12 @@ class TencentSms // 签名 private $signName = ''; - // 模版ID - private $templateCode = ''; - private $apiHost = "sms.tencentcloudapi.com"; + //短信平台返回的原始数据 + public $rawData; + /** * [__construct 构造方法] * @param [int] $param['interval_time'] [间隔时间(默认30)单位(秒)] @@ -47,7 +47,7 @@ class TencentSms * @author Devil * @blog http://gong.gg/ */ - public function __construct($param = array()) + public function __construct() { $this->signName = MyC('common_sms_sign'); $this->accessKeyId = MyC('common_sms_apikey'); @@ -68,8 +68,6 @@ class TencentSms $secretId = $this->accessKeyId; $secretKey = $this->accessKeySecret; - - $region = ''; $service = 'sms'; @@ -204,6 +202,8 @@ class TencentSms }else if(isset($result["Response"]["SendStatusSet"][0])){ $sendStatusItem = $result["Response"]["SendStatusSet"][0]; $errorCode=$sendStatusItem['Code']; + }else{ + } -- Gitee From acb89d70da53d1efa9879f6678a6b9ff7201a988 Mon Sep 17 00:00:00 2001 From: liuyi Date: Mon, 1 Jun 2020 23:18:13 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E5=8E=BB=E6=8E=89=E5=A4=A7=E5=86=99?= =?UTF-8?q?=E7=9A=84FALSE=EF=BC=8C=E8=A7=84=E8=8C=83=E4=B9=A6=E5=86=99?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- extend/base/AliyunSms.php | 93 ++++++++++++++++++++------------------ extend/base/TencentSms.php | 19 ++++---- 2 files changed, 58 insertions(+), 54 deletions(-) diff --git a/extend/base/AliyunSms.php b/extend/base/AliyunSms.php index 3f4e2fd20..a99c9a540 100755 --- a/extend/base/AliyunSms.php +++ b/extend/base/AliyunSms.php @@ -36,13 +36,13 @@ class AliyunSms /** * [__construct 构造方法] - * @author Devil - * @blog http://gong.gg/ + * @param [int] $param['interval_time'] [间隔时间(默认30)单位(秒)] + * @param [int] $param['expire_time'] [到期时间(默认30)单位(秒)] + * @param [string] $param['key_prefix'] [验证码种存储前缀key(默认 空)] * @version 0.0.1 * @datetime 2017-03-07T14:03:02+0800 - * @param [int] $param['interval_time'] [间隔时间(默认30)单位(秒)] - * @param [int] $param['expire_time'] [到期时间(默认30)单位(秒)] - * @param [string] $param['key_prefix'] [验证码种存储前缀key(默认 空)] + * @author Devil + * @blog http://gong.gg/ */ public function __construct() { @@ -51,13 +51,15 @@ class AliyunSms $this->accessKeySecret = MyC('common_sms_apisecret'); } - private function percentEncode($string) { - $string = urlencode ( $string ); - $string = preg_replace ( '/\+/', '%20', $string ); - $string = preg_replace ( '/\*/', '%2A', $string ); - $string = preg_replace ( '/%7E/', '~', $string ); + private function percentEncode($string) + { + $string = urlencode($string); + $string = preg_replace('/\+/', '%20', $string); + $string = preg_replace('/\*/', '%2A', $string); + $string = preg_replace('/%7E/', '~', $string); return $string; } + /** * 签名 * @@ -65,36 +67,36 @@ class AliyunSms * @param unknown $accessKeySecret * @return string */ - private function computeSignature($parameters, $accessKeySecret) { - ksort ( $parameters ); + private function computeSignature($parameters, $accessKeySecret) + { + ksort($parameters); $canonicalizedQueryString = ''; - foreach ( $parameters as $key => $value ) { - $canonicalizedQueryString .= '&' . $this->percentEncode ( $key ) . '=' . $this->percentEncode ( $value ); + foreach ($parameters as $key => $value) { + $canonicalizedQueryString .= '&' . $this->percentEncode($key) . '=' . $this->percentEncode($value); } - $stringToSign = 'GET&%2F&' . $this->percentencode ( substr ( $canonicalizedQueryString, 1 ) ); - $signature = base64_encode ( hash_hmac ( 'sha1', $stringToSign, $accessKeySecret . '&', true ) ); + $stringToSign = 'GET&%2F&' . $this->percentencode(substr($canonicalizedQueryString, 1)); + $signature = base64_encode(hash_hmac('sha1', $stringToSign, $accessKeySecret . '&', true)); return $signature; } /** * 短信发送 + * @param [string] $mobile [手机号码,多个以 英文逗号 , 分割] + * @param [string|array] $code [变量code(单个直接传入 code 即可,多个传入数组)] + * @param [string] $template_code [模板 id] + * @param [boolean] $sign_name [自定义签名,默认使用基础配置的签名] * @author Devil * @blog http://gong.gg/ * @version 1.0.0 * @date 2020-04-02 * @desc description - * @param [string] $mobile [手机号码,多个以 英文逗号 , 分割] - * @param [string|array] $code [变量code(单个直接传入 code 即可,多个传入数组)] - * @param [string] $template_code [模板 id] - * @param [boolean] $sign_name [自定义签名,默认使用基础配置的签名] */ public function SendCode($mobile, $code, $template_code, $sign_name = '') { // 单个验证码需要校验是否频繁 - if(is_string($code)) - { + if (is_string($code)) { - $codes = ['code'=>$code]; + $codes = ['code' => $code]; } else { $codes = $code; } @@ -103,15 +105,15 @@ class AliyunSms $SignName = empty($sign_name) ? $this->signName : $sign_name; // 请求参数 - $params = array ( //此处作了修改 + $params = array( //此处作了修改 'SignName' => $SignName, 'Format' => 'JSON', 'Version' => '2017-05-25', 'AccessKeyId' => $this->accessKeyId, 'SignatureVersion' => '1.0', 'SignatureMethod' => 'HMAC-SHA1', - 'SignatureNonce' => uniqid (), - 'Timestamp' => gmdate ( 'Y-m-d\TH:i:s\Z' ), + 'SignatureNonce' => uniqid(), + 'Timestamp' => gmdate('Y-m-d\TH:i:s\Z'), 'Action' => 'SendSms', 'TemplateCode' => $template_code, 'PhoneNumbers' => $mobile, @@ -119,40 +121,42 @@ class AliyunSms ); //print_r($params);die; // 计算签名并把签名结果加入请求参数 - $params ['Signature'] = $this->computeSignature ( $params, $this->accessKeySecret ); + $params ['Signature'] = $this->computeSignature($params, $this->accessKeySecret); // 发送请求(此处作了修改) //$url = 'https://sms.aliyuncs.com/?' . http_build_query ( $params ); - $url = 'http://dysmsapi.aliyuncs.com/?' . http_build_query ( $params ); - - $ch = curl_init (); - curl_setopt ( $ch, CURLOPT_URL, $url ); - curl_setopt ( $ch, CURLOPT_SSL_VERIFYPEER, FALSE ); - curl_setopt ( $ch, CURLOPT_SSL_VERIFYHOST, FALSE ); - curl_setopt ( $ch, CURLOPT_RETURNTRANSFER, 1 ); - curl_setopt ( $ch, CURLOPT_TIMEOUT, 10 ); - $result = curl_exec ( $ch ); - curl_close ( $ch ); - $result = json_decode ( $result, true ); - $this->rawData=$result; + $url = 'http://dysmsapi.aliyuncs.com/?' . http_build_query($params); + + $ch = curl_init(); + curl_setopt($ch, CURLOPT_URL, $url); + curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); + curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false); + curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); + curl_setopt($ch, CURLOPT_TIMEOUT, 10); + $result = curl_exec($ch); + curl_close($ch); + $result = json_decode($result, true); + $this->rawData = $result; //print_r($result);//die; - if (isset ( $result ['Code'] ) && $result['Code'] != 'OK') { - $this->error = $this->getErrorMessage ( $result ['Code'] ); + if (isset ($result ['Code']) && $result['Code'] != 'OK') { + $this->error = $this->getErrorMessage($result ['Code']); return false; } return true; } + /** * 获取详细错误信息 * * @param unknown $status */ - public function getErrorMessage($status) { + public function getErrorMessage($status) + { // 阿里云的短信 乱八七糟的(其实是用的阿里大于) // https://api.alidayu.com/doc2/apiDetail?spm=a3142.7629140.1.19.SmdYoA&apiId=25450 - $message = array ( + $message = array( 'InvalidDayuStatus.Malformed' => '账户短信开通状态不正确', 'InvalidSignName.Malformed' => '短信签名不正确或签名状态不正确', 'InvalidTemplateCode.MalFormed' => '短信模板Code不正确或者模板状态不正确', @@ -181,11 +185,12 @@ class AliyunSms 'isv.PARAM_NOT_SUPPORT_URL' => '不支持URL', 'isv.AMOUNT_NOT_ENOUGH' => '账户余额不足', ); - if (isset ( $message [$status] )) { + if (isset ($message [$status])) { return $message [$status]; } return $status; } } + ?> \ No newline at end of file diff --git a/extend/base/TencentSms.php b/extend/base/TencentSms.php index 216cee245..ed3136b0c 100755 --- a/extend/base/TencentSms.php +++ b/extend/base/TencentSms.php @@ -170,8 +170,8 @@ class TencentSms $curl = curl_init(); curl_setopt($curl, CURLOPT_URL, $url); - curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE); - curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, FALSE); + curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); + curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false); curl_setopt($curl, CURLOPT_HTTPHEADER, $headers); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLOPT_FOLLOWLOCATION, false); @@ -193,17 +193,17 @@ class TencentSms //因为一般业务情况是发给一个人,这里就简单处理为取第一个短信的状态。 //如果是批量的话,需要遍历获得所有的情况,这样的可以另外写一个接口。 - $errorCode=''; + $this->rawData = $result; - if(isset($result["Response"]['Error'])){ + if (isset($result["Response"]['Error'])) { - $errorCode=$result["Response"]['Error']['Code']; + $errorCode = $result["Response"]['Error']['Code']; - }else if(isset($result["Response"]["SendStatusSet"][0])){ + } else if (isset($result["Response"]["SendStatusSet"][0])) { $sendStatusItem = $result["Response"]["SendStatusSet"][0]; - $errorCode=$sendStatusItem['Code']; - }else{ - + $errorCode = $sendStatusItem['Code']; + } else { + $errorCode = ''; } @@ -213,7 +213,6 @@ class TencentSms } - return true; } -- Gitee