其余文件
This commit is contained in:
94
app/shop/controller/express_assistant/FaceSheetOrder.php
Normal file
94
app/shop/controller/express_assistant/FaceSheetOrder.php
Normal file
@ -0,0 +1,94 @@
|
||||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | likeshop100%开源免费商用商城系统
|
||||
// +----------------------------------------------------------------------
|
||||
// | 欢迎阅读学习系统程序代码,建议反馈是我们前进的动力
|
||||
// | 开源版本可自由商用,可去除界面版权logo
|
||||
// | 商业版本务必购买商业授权,以免引起法律纠纷
|
||||
// | 禁止对系统程序代码以任何目的,任何形式的再发布
|
||||
// | gitee下载:https://gitee.com/likeshop_gitee
|
||||
// | github下载:https://github.com/likeshop-github
|
||||
// | 访问官网:https://www.likeshop.cn
|
||||
// | 访问社区:https://home.likeshop.cn
|
||||
// | 访问手册:http://doc.likeshop.cn
|
||||
// | 微信公众号:likeshop技术社区
|
||||
// | likeshop团队 版权所有 拥有最终解释权
|
||||
// +----------------------------------------------------------------------
|
||||
// | author: likeshopTeam
|
||||
// +----------------------------------------------------------------------
|
||||
|
||||
namespace app\shop\controller\express_assistant;
|
||||
|
||||
use app\common\basics\ShopBase;
|
||||
use app\common\server\JsonServer;
|
||||
use app\shop\logic\express_assistant\FaceSheetOrderLogic;
|
||||
use app\shop\logic\express_assistant\FaceSheetSenderLogic;
|
||||
use app\shop\logic\express_assistant\FaceSheetTplLogic;
|
||||
use app\shop\validate\express_assistant\FaceSheetOrderValidate;
|
||||
|
||||
/**
|
||||
* 打印订单
|
||||
* Class FaceSheetOrder
|
||||
* @package app\shop\controller\express_assistant
|
||||
*/
|
||||
class FaceSheetOrder extends ShopBase
|
||||
{
|
||||
|
||||
/**
|
||||
* @notes 获取待发货订单列表
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:56
|
||||
*/
|
||||
public function lists()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$get = $this->request->get();
|
||||
$lists = FaceSheetOrderLogic::lists($get, $this->shop_id);
|
||||
return JsonServer::success("", $lists);
|
||||
}
|
||||
return view();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 选择打印模板
|
||||
* @return \think\response\View
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:55
|
||||
*/
|
||||
public function select()
|
||||
{
|
||||
return view("", [
|
||||
'template' => FaceSheetTplLogic::allTpl($this->shop_id),
|
||||
'sender' => FaceSheetSenderLogic::allSender($this->shop_id),
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 打印
|
||||
* @return \think\response\Json
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:56
|
||||
*/
|
||||
public function print()
|
||||
{
|
||||
if (!$this->request->isAjax()) {
|
||||
return JsonServer::error('请求异常');
|
||||
}
|
||||
$params = (new FaceSheetOrderValidate())->goCheck(null, [
|
||||
'shop_id' => $this->shop_id,
|
||||
'admin_id' => $this->admin_id
|
||||
]);
|
||||
$result = FaceSheetOrderLogic::print($params);
|
||||
if ($result !== true) {
|
||||
return JsonServer::error(FaceSheetOrderLogic::getError());
|
||||
}
|
||||
return JsonServer::success('操作成功');
|
||||
|
||||
}
|
||||
}
|
||||
113
app/shop/controller/express_assistant/FaceSheetSender.php
Normal file
113
app/shop/controller/express_assistant/FaceSheetSender.php
Normal file
@ -0,0 +1,113 @@
|
||||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | likeshop100%开源免费商用商城系统
|
||||
// +----------------------------------------------------------------------
|
||||
// | 欢迎阅读学习系统程序代码,建议反馈是我们前进的动力
|
||||
// | 开源版本可自由商用,可去除界面版权logo
|
||||
// | 商业版本务必购买商业授权,以免引起法律纠纷
|
||||
// | 禁止对系统程序代码以任何目的,任何形式的再发布
|
||||
// | gitee下载:https://gitee.com/likeshop_gitee
|
||||
// | github下载:https://github.com/likeshop-github
|
||||
// | 访问官网:https://www.likeshop.cn
|
||||
// | 访问社区:https://home.likeshop.cn
|
||||
// | 访问手册:http://doc.likeshop.cn
|
||||
// | 微信公众号:likeshop技术社区
|
||||
// | likeshop团队 版权所有 拥有最终解释权
|
||||
// +----------------------------------------------------------------------
|
||||
// | author: likeshopTeam
|
||||
// +----------------------------------------------------------------------
|
||||
|
||||
namespace app\shop\controller\express_assistant;
|
||||
|
||||
|
||||
use app\common\basics\ShopBase;
|
||||
use app\common\server\JsonServer;
|
||||
use app\shop\logic\express_assistant\FaceSheetSenderLogic;
|
||||
|
||||
/**
|
||||
* 发件人模板
|
||||
* Class FaceSheetSender
|
||||
* @package app\shop\controller\express_assistant
|
||||
*/
|
||||
class FaceSheetSender extends ShopBase
|
||||
{
|
||||
|
||||
/**
|
||||
* @notes 发件人列表
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:39
|
||||
*/
|
||||
public function lists()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$get = $this->request->get();
|
||||
$list = FaceSheetSenderLogic::lists($get, $this->shop_id);
|
||||
return JsonServer::success("", $list);
|
||||
}
|
||||
return view();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 新增发件人模板
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:39
|
||||
*/
|
||||
public function add()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$post = $this->request->post();
|
||||
$result = FaceSheetSenderLogic::add($post, $this->shop_id);
|
||||
if ($result !== true) {
|
||||
return JsonServer::error($result);
|
||||
}
|
||||
return JsonServer::success("操作成功");
|
||||
}
|
||||
return view();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 编辑发件人
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:40
|
||||
*/
|
||||
public function edit()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$post = $this->request->post();
|
||||
$result = FaceSheetSenderLogic::edit($post, $this->shop_id);
|
||||
if ($result !== true) {
|
||||
return JsonServer::error($result);
|
||||
}
|
||||
return JsonServer::success("操作成功");
|
||||
}
|
||||
|
||||
$id = $this->request->get('id');
|
||||
return view('', [
|
||||
'detail' => FaceSheetSenderLogic::detail($id, $this->shop_id)
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 删除发件人
|
||||
* @return \think\response\Json|void
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:40
|
||||
*/
|
||||
public function del()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$id = $this->request->post('id');
|
||||
$result = FaceSheetSenderLogic::del($id, $this->shop_id);
|
||||
if ($result !== true) {
|
||||
return JsonServer::error($result);
|
||||
}
|
||||
return JsonServer::success("操作成功");
|
||||
}
|
||||
}
|
||||
}
|
||||
65
app/shop/controller/express_assistant/FaceSheetSetting.php
Normal file
65
app/shop/controller/express_assistant/FaceSheetSetting.php
Normal file
@ -0,0 +1,65 @@
|
||||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | likeshop100%开源免费商用商城系统
|
||||
// +----------------------------------------------------------------------
|
||||
// | 欢迎阅读学习系统程序代码,建议反馈是我们前进的动力
|
||||
// | 开源版本可自由商用,可去除界面版权logo
|
||||
// | 商业版本务必购买商业授权,以免引起法律纠纷
|
||||
// | 禁止对系统程序代码以任何目的,任何形式的再发布
|
||||
// | gitee下载:https://gitee.com/likeshop_gitee
|
||||
// | github下载:https://github.com/likeshop-github
|
||||
// | 访问官网:https://www.likeshop.cn
|
||||
// | 访问社区:https://home.likeshop.cn
|
||||
// | 访问手册:http://doc.likeshop.cn
|
||||
// | 微信公众号:likeshop技术社区
|
||||
// | likeshop团队 版权所有 拥有最终解释权
|
||||
// +----------------------------------------------------------------------
|
||||
// | author: likeshopTeam
|
||||
// +----------------------------------------------------------------------
|
||||
|
||||
namespace app\shop\controller\express_assistant;
|
||||
|
||||
|
||||
use app\common\basics\ShopBase;
|
||||
use app\common\server\ConfigServer;
|
||||
use app\common\server\JsonServer;
|
||||
|
||||
|
||||
/**
|
||||
* 面单
|
||||
* Class FaceSheet
|
||||
* @package app\shop\controller\express_assistant
|
||||
*/
|
||||
class FaceSheetSetting extends ShopBase
|
||||
{
|
||||
|
||||
/**
|
||||
* @notes 面单设置
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 14:38
|
||||
*/
|
||||
public function setting()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$post = $this->request->post();
|
||||
ConfigServer::set('faceSheet', 'type', $post['type'], $this->shop_id);
|
||||
ConfigServer::set('kd100', 'kd100_key', $post['kd100_key'], $this->shop_id);
|
||||
ConfigServer::set('kd100', 'kd100_secret', $post['kd100_secret'], $this->shop_id);
|
||||
ConfigServer::set('kd100', 'kd100_siid', $post['kd100_siid'], $this->shop_id);
|
||||
return JsonServer::success('修改成功');
|
||||
}
|
||||
|
||||
$faceSheet = ConfigServer::get('faceSheet', null,null, $this->shop_id);
|
||||
$detail = ConfigServer::get('kd100', null, null, $this->shop_id);
|
||||
return view('', [
|
||||
'detail' => $detail,
|
||||
'faceSheet' => $faceSheet
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
127
app/shop/controller/express_assistant/FaceSheetTpl.php
Normal file
127
app/shop/controller/express_assistant/FaceSheetTpl.php
Normal file
@ -0,0 +1,127 @@
|
||||
<?php
|
||||
// +----------------------------------------------------------------------
|
||||
// | likeshop100%开源免费商用商城系统
|
||||
// +----------------------------------------------------------------------
|
||||
// | 欢迎阅读学习系统程序代码,建议反馈是我们前进的动力
|
||||
// | 开源版本可自由商用,可去除界面版权logo
|
||||
// | 商业版本务必购买商业授权,以免引起法律纠纷
|
||||
// | 禁止对系统程序代码以任何目的,任何形式的再发布
|
||||
// | gitee下载:https://gitee.com/likeshop_gitee
|
||||
// | github下载:https://github.com/likeshop-github
|
||||
// | 访问官网:https://www.likeshop.cn
|
||||
// | 访问社区:https://home.likeshop.cn
|
||||
// | 访问手册:http://doc.likeshop.cn
|
||||
// | 微信公众号:likeshop技术社区
|
||||
// | likeshop团队 版权所有 拥有最终解释权
|
||||
// +----------------------------------------------------------------------
|
||||
// | author: likeshopTeam
|
||||
// +----------------------------------------------------------------------
|
||||
|
||||
namespace app\shop\controller\express_assistant;
|
||||
|
||||
use app\common\basics\ShopBase;
|
||||
use app\common\server\JsonServer;
|
||||
use app\shop\logic\express_assistant\FaceSheetTplLogic;
|
||||
|
||||
|
||||
/**
|
||||
* 面单模板
|
||||
* Class FaceSheetTpl
|
||||
* @package app\shop\controller\express_assistant
|
||||
*/
|
||||
class FaceSheetTpl extends ShopBase
|
||||
{
|
||||
|
||||
/**
|
||||
* @notes 电子面单模板列表
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:02
|
||||
*/
|
||||
public function lists()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$get = $this->request->get();
|
||||
$list = FaceSheetTplLogic::lists($get, $this->shop_id);
|
||||
return JsonServer::success('', $list);
|
||||
}
|
||||
return view();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 新增电子面单模板
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:01
|
||||
*/
|
||||
public function add()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$post = $this->request->post();
|
||||
$result = FaceSheetTplLogic::add($post, $this->shop_id);
|
||||
if ($result !== true) {
|
||||
return JsonServer::error($result);
|
||||
}
|
||||
return JsonServer::success('操作成功');
|
||||
}
|
||||
|
||||
return view('', [
|
||||
'express' => FaceSheetTplLogic::allExpress()
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 编辑电子面单模板
|
||||
* @return \think\response\Json|\think\response\View
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:01
|
||||
*/
|
||||
public function edit()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$post = $this->request->post();
|
||||
$result = FaceSheetTplLogic::edit($post, $this->shop_id);
|
||||
if ($result !== true) {
|
||||
return JsonServer::error($result);
|
||||
}
|
||||
return JsonServer::success('操作成功');
|
||||
}
|
||||
|
||||
$id = $this->request->get('id');
|
||||
return view('', [
|
||||
'detail' => FaceSheetTplLogic::detail($id, $this->shop_id),
|
||||
'express' => FaceSheetTplLogic::allExpress(),
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @notes 删除电子面单模板
|
||||
* @return \think\response\Json|void
|
||||
* @author 段誉
|
||||
* @date 2023/2/13 16:01
|
||||
*/
|
||||
public function del()
|
||||
{
|
||||
if ($this->request->isAjax()) {
|
||||
$id = $this->request->post('id');
|
||||
$result = FaceSheetTplLogic::del($id, $this->shop_id);
|
||||
if ($result !== true) {
|
||||
return JsonServer::error($result);
|
||||
}
|
||||
return JsonServer::success('操作成功');
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user