第二次提交
This commit is contained in:
68
application/home/controller/Illustrations.php
Normal file
68
application/home/controller/Illustrations.php
Normal file
@@ -0,0 +1,68 @@
|
||||
<?php
|
||||
/**
|
||||
* tpshop
|
||||
* ============================================================================
|
||||
* * 版权所有 2015-2027 深圳搜豹网络科技有限公司,并保留所有权利。
|
||||
* 网站地址: http://www.tp-shop.cn
|
||||
* ----------------------------------------------------------------------------
|
||||
* 这不是一个自由软件!您只能在不用于商业目的的前提下对程序代码进行修改和使用 .
|
||||
* 不允许对程序代码以任何形式任何目的的再发布。
|
||||
* 采用最新Thinkphp5助手函数特性实现单字母函数M D U等简写方式
|
||||
* ============================================================================
|
||||
* $Author: IT宇宙人 2015-08-10 $
|
||||
*/
|
||||
|
||||
namespace app\home\controller;
|
||||
|
||||
|
||||
use app\common\logic\FreightLogic;
|
||||
use app\common\logic\GoodsPromFactory;
|
||||
use app\common\logic\SearchWordLogic;
|
||||
use app\common\logic\GoodsLogic;
|
||||
use app\common\model\Combination;
|
||||
use app\common\model\SpecGoodsPrice;
|
||||
use app\common\util\TpshopException;
|
||||
use think\AjaxPage;
|
||||
use think\Page;
|
||||
use think\Validate;
|
||||
use think\Verify;
|
||||
use think\Db;
|
||||
use think\Cookie;
|
||||
use think\Log;
|
||||
class Illustrations extends Base
|
||||
|
||||
{
|
||||
public function illustrations()
|
||||
{
|
||||
return $this->fetch();
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 商品咨询
|
||||
*/
|
||||
public function consult()
|
||||
{
|
||||
|
||||
$username = input("username", 'TPshop用户'); // 网友咨询
|
||||
$content = trim(input("content", '')); // 咨询内容
|
||||
$dess = trim(input("dess", '')); // 咨询内容
|
||||
$model = trim(input("model", '')); // 咨询内容
|
||||
|
||||
$data = array(
|
||||
'username' => $username,
|
||||
'content' => $content,
|
||||
'dess' => $dess,
|
||||
'model' => $model,
|
||||
'is_show' => 1,
|
||||
'add_time' => time(),
|
||||
);
|
||||
|
||||
|
||||
Db::name('goodsConsult')->add($data);
|
||||
$this->ajaxReturn(['status' => 1, 'msg' => '咨询已提交!']);
|
||||
}
|
||||
|
||||
|
||||
}
|
Reference in New Issue
Block a user