From 364a083e94138f7ed2d8114bf6dbdfda4eaf2683 Mon Sep 17 00:00:00 2001
From: chengkun <chengkun@ishangstudy.com>
Date: Thu, 11 Sep 2025 16:21:25 +0800
Subject: [PATCH] 提交
---
/dev/null | 142 -----------------------------------------------
1 files changed, 0 insertions(+), 142 deletions(-)
diff --git a/app/admin/controller/BigvInfo.php b/app/admin/controller/BigvInfo.php
deleted file mode 100644
index 8dbf710..0000000
--- a/app/admin/controller/BigvInfo.php
+++ /dev/null
@@ -1,83 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\supplier\model\GoodsAnnex;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\Request;
-use think\facade\View;
-use think\Exception;
-
-class BigvInfo extends Common {
- /*
- * 品牌管理
- */
- public function index(): string {
- $other['title'] = '大V管理';
- $guide['one']['text'] = '数据审核';
- $guide['two']['text'] = '大V管理';
- View::assign('guide', $guide);
- View::assign('other', $other);
- return View::fetch('index');
- }
-
- /*
- * 获取商品品牌列表
- */
- public function getBigvInfoList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $kw = input('kw');
-
- if (!empty($kw)) {
- $condition[] = array('SBI.first_name', 'like', "%$kw%");
- }
- $p = input('page', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'BIGV.is_show desc,BIGV.id asc';
-
- $count = Db::name('seller_bigv_info')->alias('BIGV')
- ->join('seller_base_info SBI', 'SBI.seller_id=BIGV.seller_id')->where($condition)->count();
- $list = Db::name('seller_bigv_info')->alias('BIGV')
- ->join('seller_base_info SBI', 'SBI.seller_id=BIGV.seller_id')
- ->field("BIGV.*,SBI.first_name")->withAttr('personal_images', function($value) {
- return json_decode($value, true);
- })->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['code'] = 200;
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
-
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'id,is_show';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name('seller_bigv_info')->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
-}
\ No newline at end of file
diff --git a/app/admin/controller/CancelPublishOrder.php b/app/admin/controller/CancelPublishOrder.php
deleted file mode 100644
index 93977b5..0000000
--- a/app/admin/controller/CancelPublishOrder.php
+++ /dev/null
@@ -1,648 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\supplier\model\DistributionArea as DistributionAreaModel;
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\supplier\model\GoodsAnnex;
-use app\supplier\model\GoodsSpec;
-use app\supplier\model\GoodsAttribute;
-use app\supplier\model\GoodsLabel;
-use app\supplier\model\GoodsRetailPriceLimit;
-
-//use app\supplier\model\Goods;
-
-//商品零售价限制
-
-class CancelPublishOrder extends Common {
-
- /**
- * 商品管理
- * @return string
- */
- public function index() {
- return View::fetch();
- }
-
- /**
- * 获取刊登列表
- * @return mixed
- */
- public function getPublishOrder() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $platform_goods_code = input('platform_goods_code');
- $supplier_goods_code = input('supplier_goods_code');
- $condition['poc.status'] = 0;//
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'id asc';
- $count = \app\supplier\model\PublishOrder::alias('po')
- ->alias('po')
- ->join('web_publish_order_cancel poc', 'po.id=poc.publish_order_id')
- ->where($condition)
- ->count();
- $list = \app\supplier\model\PublishOrder::alias('po')
- ->alias('po')
- ->join('web_publish_order_cancel poc', 'po.id=poc.publish_order_id')
- ->field("poc.id as cancel_id,po.id,supplier_goods_code,publish_order_code,first_cate_code,second_cate_code,three_cate_code,public_type,brand_code,poc.add_time,publish_status,update_time,goods_title_cn,(select url from web_publish_order_picture where publish_order_id=po.id order by id asc limit 1) as picture,poc.status,poc.remark,poc.reason_id")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if ($list) {
- $categorylist = get_category();
- $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
- foreach ($list as &$item) {
- $item['first_cate_name'] = $categorylist[$item['first_cate_code']]['cate_name'];
- $item['second_cate_name'] = $categorylist[$item['second_cate_code']]['cate_name'];
- $item['three_cate_name'] = $categorylist[$item['three_cate_code']]['cate_name'];
- $item['add_time'] = date('Y-m-d H:i:s', $item['add_time']);
- }
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 取消刊登审核
- * @return array|int[]
- */
- public function reviewPublishOrder() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $publish_order_id = input('post.publish_order_id');
- $cancel_id = input('post.cancel_id');
- if (is_numeric($cancel_id)) {
- $status = input('post.status');
- //更新数据
- $info = Db::name('publish_order_cancel')->field('id,status')->where('id', $cancel_id)->find();
- if (!$info) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- if($info['status']==1){
- return $this->errorResponse('该申请已审核通过,不能重复审核');
- }
- if ($status == 1) {
- Db::name('publish_order_cancel')->where('id', $cancel_id)->update(['status' => 1]);
- Db::name('publish_order')->where('id', $publish_order_id)->update(['publish_status' => 0, 'audit_status' => 1, 'review_comments' => '']);
- $message = '操作成功,审核通过';
- } else {
- $comments = trim(input('comments'));
- if (!$comments) {
- return $this->errorResponse('请填写审核不通过原因');
- }
- Db::name('publish_order_cancel')->where('id', $cancel_id)->update(['status' => 1, 'comments' => $comments]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
- } else {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 创建商品
- * @return string
- */
- public function create() {
- ////////
- $id = input('id');
- if (!is_numeric($id)) {
- $this->redirect(url('/supplier/cancelPublishOrder/index')->build());
- }
- $cancel_id = input('cancel_id');
- $other['id'] = $id;
- $other['cancel_id'] = $cancel_id;
- View::assign('other', $other);
- return View::fetch();
- }
-
- public function getGoodsInfo() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $supplier_goods_code = input('supplier_goods_code');
- if (!is_numeric($supplier_goods_code)) {
- return $this->errorResponse(lang('invalid_id'));
- }
- try {
- $where = [
- 'supplier_goods_code' => $supplier_goods_code,
- ];
- $info = Db::name('goods')->field('id,first_cate_code,second_cate_code,three_cate_code,brand_code')->where($where)->find();
- if ($info['three_cate_code']) {
- $info['cate_code'] = [$info['first_cate_code'], $info['second_cate_code'], $info['three_cate_code']];
- }
- $info['goods_purpose'] = json_decode($info['goods_purpose'], TRUE);
- //////获取描述标题数据/////////
- $where_other = [
- 'goods_id' => $info['id'],
- ];
- $goods_desc = Db::name('goods_desc')->field('goods_title_en,goods_title_cn')->where($where_other)->find();
- //获取描述内容数据
- $goods_desc_content = Db::name('goods_desc_content')->field('goods_desc_en,goods_desc_cn')->where($where_other)->find();
-
- ////////////////
- $result['info'] = $info;
- $result['goods_desc'] = $goods_desc;
- $result['goods_desc_content'] = $goods_desc_content;
- return $this->successResponse($result);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 获取商品分销信息
- * @return array|int[]
- */
- public function getGoodsDisInfo() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $supplier_goods_code = input('supplier_goods_code');
-
-
- $condition['g.istemp'] = 1;//编辑过的商品
- if ($supplier_goods_code) {
- $condition['g.supplier_goods_code'] = $supplier_goods_code;
- }
-
- $info = \app\supplier\model\Goods::alias('g')
- ->join('goods_desc gd', 'g.id=gd.goods_id')
- ->join('goods_desc_content gdc', 'g.id=gdc.goods_id')
- ->field("g.id,g.warehouse_mode,g.sales_form,g.supplier_goods_code,g.platform_goods_code,g.goods_purpose,g.add_time,g.status,g.publish_status,g.whether_dis,g.is_limit_dis_platform,gd.goods_title_cn,gd.goods_title_en,gd.goods_keyword_en,gd.goods_keyword_cn,g.first_cate_code,g.second_cate_code,g.three_cate_code,g.docking_way,g.price_method,g.freight_attr_code,g.is_tort,g.is_stop_buy,g.recommend_man,gdc.goods_desc_en,gdc.goods_desc_cn")->where($condition)->find();
- if ($info) {
- $categorylist = get_category();
- $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
- $info['first_cate_name'] = $categorylist[$info['first_cate_code']]['cate_name'];
- $info['second_cate_name'] = $categorylist[$info['second_cate_code']]['cate_name'];
- $info['three_cate_name'] = $categorylist[$info['three_cate_code']]['cate_name'];
- $info['attr_name'] = Db::name('goods_freight_attr')->where('attr_code', $info['freight_attr_code'])->value('attr_name');
- $info['goods_keyword_en'] = $info['goods_keyword_en'] ? json_decode($info['goods_keyword_en'], TRUE) : [];
- $info['goods_keyword_cn'] = $info['goods_keyword_cn'] ? json_decode($info['goods_keyword_cn'], TRUE) : [];
-
- $info['goodsSpecInfo'] = Db::name('goods_spec')->field('*')->where('goods_id', $info['id'])->find();
- $goods_attribute_info = Db::name('goods_attribute')->field('*')
- ->withAttr('material_main', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_one', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_two', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_three', function ($value, $data) {
- if ($value) {
- $value = json_decode($value, TRUE);
- return Db::name('goods_material')->whereIn('id', $value)->column('material_name');
- } else {
- return [];
- }
- })
- ->where('goods_id', $info['id'])->find();
- $info['goodsAttributeInfo'] = $goods_attribute_info;
- $info['goodsAttributExtendList'] = Db::name('goods_attribute_extend')->field('*')->where('goods_id', $info['id'])->select()->toArray();
-
- $info['goodsRetailPriceLimitList'] = GoodsRetailPriceLimit::field('*')->where('goods_id', $info['id'])
- ->withAttr('sale_country_code', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value("CONCAT(country_code,' ',country)");
- })
- ->withAttr('sales_platform', function ($value, $data) {
- return Db::name('sales_platform')->where('id', $value)->value("platform_name");
- })
- ->order('id asc')->select()->toArray();///
- $info['goodsLabelList'] = GoodsLabel::field('label_type,goods_label')->where('goods_id', $info['id'])->order('id asc')->select()->toArray();///
- if ($info['is_limit_dis_platform'] == 1) {
- $info['goodsLimitDisPlatformList'] = Db::name('goods_limit_dis_platform')
- ->alias('a')
- ->join('dis_platform b', 'a.dis_platform = b.id')
- ->field('b.platform_name')->where('goods_id', $info['id'])->order('a.id asc')->select()->toArray();///
- } else {
- $info['goodsLimitDisPlatformList'] = [];
- }
- $result['info'] = $info;
- ///分销区域//
- $disAreaList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('distribution_area da', 'da.id=gda.distribution_area_id')
- ->field("gda.one_shipment,gda.distribution_area_id")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)->withAttr('one_shipment', function ($value, $data) {
- return $value == 1 ? '一件代发' : '';
- })->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disAreaList'] = $disAreaList;
- //分销库存
- $disStockList = Db::name('goods_distribution_area_stock')
- ->alias('gdas')
- ->join('third_party_stock tps', 'tps.id=gdas.third_party_stock_id')
- ->field("gdas.distribution_area_id,gdas.supplier_stock_amount,gdas.platform_stock_amount,gdas.goods_distribution_area_id,tps.third_party_stock_name,tps.docking_code,tps.stock_type")->where('gdas.goods_id', $info['id'])->where('gdas.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disStockList'] = $disStockList;
- //分销价格///
- $disPriceList = Db::name('goods_distribution_area_price')
- ->alias('gdap')
- ->join('goods_distribution_area gda', 'gda.id=gdap.goods_distribution_area_id')
- ->join('logistics_product lp', 'lp.id=gdap.logistics_product_id')
- ->field("gdap.distribution_area_id,gdap.goods_distribution_area_id,lp.product_name_cn,gdap.supply_price,gdap.dis_price,gdap.package_goods_amount,gda.take_effect_time")->where('gdap.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('take_effect_time', function ($value, $data) {
- return date('Y-m-d H:i:s', $value);
- })->select()->toArray();
- $result['disPriceList'] = $disPriceList;
- //退货地址列表//
- $disReturnGoodsList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('third_party_stock tps', 'tps.id=gda.third_party_stock_id')
- ->join('third_party_stock_address tpsa', 'tpsa.id=gda.third_party_stock_address_id')
- ->field("gda.distribution_area_id,tps.third_party_stock_name,tpsa.stock_address,tpsa.stock_city,tpsa.stock_province,tpsa.stock_post_code,tpsa.stock_country_id,tpsa.receive_man,tpsa.tel")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('stock_country_id', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value('country');
- })
- ->select()->toArray();
- $result['disReturnGoodsList'] = $disReturnGoodsList;
-
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取商品图片列表
- * @return array|int[]
- */
- public function getGoodsPictureList() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $goods_id = input('goods_id');
- $picture_type = input('picture_type');
-
- if (is_array($picture_type)) {
- $where[] = ['a.goods_id', '=', $goods_id];
- if (is_array($picture_type)) {
- $where[] = ['b.type', 'in', $picture_type];
- }
- $list = Db::name('goods_picture')
- ->alias('a')
- ->join('goods_picture_type b', 'a.id=b.picture_id')
- ->field('DISTINCT a.id,a.url')->where($where)->order('id asc')->select()->toArray();
- } else {
- $where[] = ['goods_id', '=', $goods_id];
- $list = Db::name('goods_picture')->field('id,url')->where($where)->order('id asc')->select()->toArray();
- }
-
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 根据类型获取商品图片数量
- * @return void
- */
- public function getGoodsPictureCount() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $goods_id = input('goods_id');
- $goodsPictureCount['type0'] = Db::name('goods_picture')->where(['goods_id' => $goods_id])->count();
- $goodsPictureCount['type1'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 1])->count();
- $goodsPictureCount['type2'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 2])->count();
- $goodsPictureCount['type3'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 3])->count();
- $goodsPictureCount['type4'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 4])->count();
- $goodsPictureCount['type5'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 5])->count();
- $goodsPictureCount['type6'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 6])->count();
- $goodsPictureCount['type7'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 7])->count();
- $result['goodsPictureCount'] = $goodsPictureCount;
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取分销区域
- */
- private function getDisArea($id) {
- return Db::name('distribution_area')
- ->alias('da')
- ->join('deliver_region dr', 'dr.deliver_region_id=da.deliver_region_id')
- ->field("da.dis_currency,dr.region_name,da.dis_model")
- ->where('da.id', $id)->find();
- }
-
- /**
- * 获取刊登信息
- * @return array|int[]
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\DbException
- * @throws \think\db\exception\ModelNotFoundException
- */
- public function getPublishOrderInfo() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- $cancel_id = input('cancel_id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('invalid_id'));
- }
- try {
- $where = [
- 'id' => $id,
- ];
- $info = Db::name('publish_order')->field('*')->where($where)->find();
- if ($info['three_cate_code']) {
- $info['cate_code'] = [$info['first_cate_code'], $info['second_cate_code'], $info['three_cate_code']];
- }
- //////获取描述标题数据/////////
- $cancelInfo = Db::name('publish_order_cancel')->field('*')->where('id',$cancel_id)->find();
- ////////////////
- $result['info'] = $info;
- $result['cancelInfo'] = $cancelInfo;
- return $this->successResponse($result);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 保存刊登信息
- * @return array
- */
- public function savePublishOrder() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $data = Request::post();
-
- $id = $data['id'];
- // 验证ID的合法性
- if (!is_numeric($id) || $id <= 0) {
- return $this->errorResponse(lang('invalid_id'));
- }
- // 数据验证
- $validate = new \app\supplier\validate\PublishOrder();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- /////////////////
- $img_count = Db::name('publish_order_picture')->where('publish_order_id', $id)->count();
- if ($img_count == 0) {
- return $this->errorResponse('请上传图片');
- }
-
- $data['update_time'] = time();
- $data['istemp'] = 1;
- $data['publish_status'] = 0;//未刊登
- $data['audit_status'] = 2;//提交待审核
-
- $where['id'] = $id;
- $update_result = Db::name('publish_order')->where($where)->withoutField('id,supplier_id,publish_order_code')->update($data);
- if ($update_result === FALSE) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse(lang('editing_failed'));
- }
- // 提交事务
- Db::commit();
- $result['url'] = url('/supplier/publishOrder/index')->build();
- $result['message'] = lang('successfully_saved');
- return $this->successResponse($result);
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除刊登信息
- * @return array
- */
- public function deletePublishOrder() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- throw new Exception(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('publish_order')->field('id,publish_status,audit_status')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('delete_failed'));
- } else {
- if ($info['publish_status'] == 1) {
- return $this->errorResponse('刊登单已发布,不能删除');
- }
- }
- // 启动事务
- Db::startTrans();
- try {
- $del_result = Db::name('publish_order')->where('id', $id)->delete();
- if ($del_result) {
- ////执行成功,提交事务
- Db::commit();
- return $this->successResponse(lang('delete_successful'));
- } else {
- Db::rollback();
- return $this->errorResponse(lang('delete_failed'));
- }
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
-
- /**
- * 上传商品图片
- * @return array|int[]
- */
-
- /**
- * 获取商品图片列表
- * @return array|int[]
- */
- public function getPublishOrderPictureList() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $publish_order_id = input('publish_order_id');
-
- $where[] = ['publish_order_id', '=', $publish_order_id];
- $list = Db::name('publish_order_picture')->field('id,url')->where($where)->order('id asc')->select()->toArray();
-
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /**
- * 删除商品图片
- * @return array|int[]
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\DbException
- * @throws \think\db\exception\ModelNotFoundException
- */
- public function deletePublishOrderPicture() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('publish_order_picture')->field('id,publish_order_id,url')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('delete_failed'));
- }
- // 启动事务
- Db::startTrans();
- try {
- $del_result = Db::name('publish_order_picture')->where('id', $id)->delete();
- if ($del_result) {
- ////执行成功,提交事务
- Db::commit();
- delpic($info['url']);
- return $this->successResponse(lang('delete_successful'));
- } else {
- Db::rollback();
- return $this->errorResponse(lang('delete_failed'));
- }
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
-
- /**
- * 获取分类列表
- * @return array
- */
- public function getCategoryList() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $result['list'] = $this->getchildrenids(0);
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 循环获取分类数据
- * @param $id
- * @return array|void
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\DbException
- * @throws \think\db\exception\ModelNotFoundException
- */
- protected function getchildrenids($id) {
- $where['father_code'] = $id;
- $result = Db::name('category')->field('id,cate_code as value,cate_name as label')->where($where)->cacheAlways(TRUE, 0, 'category')->order('id asc')->select()->toArray();
- if ($result) {
- foreach ($result as &$val) {
- $val['children'] = $this->getchildrenids($val['value']); ////
- }
- return $result;
- }
- }
-
- /**
- * 商品发布
- * @return array|int[]
- */
- public function goodsPublish() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $publish_order_id = input('publish_order_id');
- $goods_info = Db::name('goods')->field('id')->where('id', $publish_order_id)->find();
- if ($goods_info) {
- $update_data = [
- 'publish_status' => 1,
- 'update_time' => time(),
- ];
- Db::name('goods')->where('id', $publish_order_id)->update($update_data);
- } else {
- return $this->errorResponse(lang('goods_not_exist'));
- }
- // 提交事务
- Db::commit();
- return $this->successResponse(lang('goods_publish_success'));
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-}
diff --git a/app/admin/controller/Category.php b/app/admin/controller/Category.php
deleted file mode 100644
index 0e4ec47..0000000
--- a/app/admin/controller/Category.php
+++ /dev/null
@@ -1,185 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use think\Exception;
-
-class Category extends Common {
- private $viewPath = 'category';
-
- /**
- * 菜单列表
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
-// $other['title'] = '总共后台菜单';
- $guide['one']['text'] = '基础信息设置';
- $guide['two']['text'] = '商品分类管理';
- View::assign('guide', $guide);
-// View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch('index');
- }
- }
-
- public function getCategoryList() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $father_code = input('father_code');
- $where[] = ['father_code', '=', $father_code];
- $order = 'order_id asc,id asc';
- $list = Db::name('category')->field('*')->where($where)->order($order)->select()->toArray();
- if (!$list) {
- return $this->errorResponse('暂无菜单');
- }
- $reuslt['list'] = $list;
- return $this->successResponse($reuslt);
- } catch (\Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- ///获取平台列表
- public function getPlatformList() {
- try {
- if (!Request::isPost()) {
- throw new Exception('请求方式错误');
- }
- $order = 'order_id asc,docking_platform_id asc';
- $list = Db::name('docking_platform')->field('*')->order($order)->select()->toArray();
- if (!$list) {
- throw new Exception('暂无平台信息');
- }
- $reuslt['list'] = $list;
- return $this->successResponse($reuslt);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 保存分类 信息
- * @return array|int[]
- */
- public function saveCategory() {
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- $id = $data['id'];
- if (is_numeric($id)) {
- //更新数据
- $validate = new \app\admin\validate\Category();
- $result = $validate->check($data);
- if (!$result) {
- throw new Exception($validate->getError());
- }
- //////保存////////////
- Db::name('category')->where('id', $id)->withoutField('id')->save($data);
- ////////////////////////
- ///////执行成功,提交事务///////
- Db::commit();
- $this->delCache();
- $res['message'] = '编辑成功';
- return $this->successResponse($res);
- } else {
- unset($data['id']);
- $data['status'] = 1;
- $validate = new \app\admin\validate\Category();
- $result = $validate->check($data);
- if (!$result) {
- throw new Exception($validate->getError());
- }
- //////////////////////
- $new_id = Db::name('category')->insertGetId($data);
- if (!$new_id) {
- throw new Exception('添加失败');
- }
- Db::name('category')->where('id', $new_id)->save(['order_id' => $new_id]);
- ///////执行成功,提交事务///////
- Db::commit();
- $this->delCache();
- $res['message'] = '添加成功';
- return $this->successResponse($res);
- }
- } catch (Exception $e) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($e->getMessage());
- }
-
- }
-
- //保存对接平台信息
- public function savePlatform() {
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- $docking_platform_id = $data['docking_platform_id'];
- if (is_numeric($docking_platform_id)) {
- //更新数据
- $validate = new \app\admin\validate\DockingPlatform();
- $result = $validate->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////保存////////////
- Db::name('docking_platform')->where('docking_platform_id', $docking_platform_id)->withoutField('docking_platform_id')->save($data);
- ////////////////////////
- Db::commit();
- $this->delDPCache();
- $res['message'] = '编辑成功';
- return $this->successResponse($res);
- } else {
- unset($data['docking_platform_id']);
- $validate = new \app\admin\validate\DockingPlatform();
- $result = $validate->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////////////////////
- $new_id = Db::name('docking_platform')->insertGetId($data);
- if (!$new_id) {
- throw new Exception('添加失败');
- }
- Db::name('docking_platform')->where('docking_platform_id', $new_id)->save(['order_id' => $new_id]);
- ///////执行成功,提交事务///////
- $this->delDPCache();
- Db::commit();
- $res['message'] = '添加成功';
- return $this->successResponse($res);
- }
- } catch (Exception $e) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($e->getMessage());
- }
-
- }
-
- /**
- * 清除缓存
- * @return void
- */
- private function delCache() {
- Cache::tag('category')->clear();
- }
-
- private function delDPCache() {
- Cache::tag('docking_platform')->clear();
- }
-
-
-}
diff --git a/app/admin/controller/CountryCode.php b/app/admin/controller/CountryCode.php
deleted file mode 100644
index a9b0d02..0000000
--- a/app/admin/controller/CountryCode.php
+++ /dev/null
@@ -1,191 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-class CountryCode extends Common {
- private $viewPath = 'country_code';
- /**
- * 菜单列表
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $guide['one']['text'] = '基础信息设置';
- $guide['two']['text'] = '国家城市管理';
- View::assign('guide', $guide);
- View::assign('viewPath', $this->viewPath);
- return View::fetch('index');
- }
- }
- public function getCountryCodeList() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $father_id = input('father_id');
- $where[] = ['father_id','=',$father_id];
- $order = 'order_id asc,id asc';
- $list = Db::name('country_code')->field('id,cate_name,cate_code,order_id,status,father_id')->where($where)->order($order)->select()->toArray();
- if(!$list){
- return $this->errorResponse('暂无菜单');
- }
- $reuslt['list'] = $list;
- return $this->successResponse($reuslt);
- } catch (\Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
- /**
- * 更新显示状态
- */
- public function updateShow() {
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse('参数错误');
- }
- $status = input('status');
- $info = Db::name('country_code')->field('id')->where('id', $id)->find();
- if (empty($info)) {
- return $this->errorResponse('信息不存在');
- }
- if ($status == '1') {
- $data['status'] = 1;
- } else {
- $data['status'] = 0;
- }
- $backval = Db::name('country_code')->where('id', $id)->save($data);
- if ($backval === FALSE) {
- return $this->errorResponse('更新失败');
- } else {
- $this->delCache();
- return $this->successResponse('更新成功');
- }
- }
-
- /**
- * 保存国家信息
- * @return array|int[]
- */
- public function saveCountryCode() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- $data = Request::post();
- $id = $data['id'];
- if (is_numeric($id)) {
- //更新数据
- $validate = new \app\admin\validate\CountryCode();
- $result = $validate->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////保存////////////
- Db::name('country_code')->where('id', $id)->withoutField('id')->save($data);
- ////////////////////////
- $this->delCache();
- $res['message'] = '编辑成功';
- return $this->successResponse($res);
- } else {
- unset($data['id']);
- $data['status'] = 1;
- $validate = new \app\admin\validate\CountryCode();
- $result = $validate->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////////////////////
- Db::startTrans();
- try {
- $new_id = Db::name('country_code')->insertGetId($data);
- if ($new_id) {
- Db::name('country_code')->where('id', $new_id)->save(['order_id' => $new_id]);
- ///////执行成功,提交事务///////
- Db::commit();
- $this->delCache();
- $res['message'] = '添加成功';
- return $this->successResponse($res);
- } else {
- //任一执行失败,执行回滚操作
- Db::rollback();
- return $this->errorResponse('添加失败');
- }
- } catch (\Exception $e) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse('添加失败');
- }
- }
- }
- /*
- * 保存城市信息
- */
- public function saveCityCode() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- $data = Request::post();
- $id = $data['id'];
- if (is_numeric($id)) {
- //更新数据
- $validate = new \app\admin\validate\CountryCode();
- $result = $validate->scene('city')->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////保存////////////
- Db::name('country_code')->where('id', $id)->withoutField('id')->save($data);
- ////////////////////////
- $this->delCache();
- $res['message'] = '编辑成功';
- return $this->successResponse($res);
- } else {
- unset($data['id']);
- $data['status'] = 1;
- $validate = new \app\admin\validate\CountryCode();
- $result = $validate->scene('city')->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////////////////////
- Db::startTrans();
- try {
- $new_id = Db::name('country_code')->insertGetId($data);
- if ($new_id) {
- Db::name('country_code')->where('id', $new_id)->save(['order_id' => $new_id]);
- ///////执行成功,提交事务///////
- Db::commit();
- $this->delCache();
- $res['message'] = '添加成功';
- return $this->successResponse($res);
- } else {
- //任一执行失败,执行回滚操作
- Db::rollback();
- return $this->errorResponse('添加失败');
- }
- } catch (\Exception $e) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse('添加失败');
- }
- }
- }
- /**
- * 清除缓存
- * @return void
- */
- private function delCache() {
- Cache::tag('country_code')->clear();
- }
-
-}
diff --git a/app/admin/controller/Currency.php b/app/admin/controller/Currency.php
deleted file mode 100644
index f041f27..0000000
--- a/app/admin/controller/Currency.php
+++ /dev/null
@@ -1,137 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-//use \app\admin\validate\DeliverRegion as DeliverRegionValidate;
-
-class Currency extends Common {
- private $tableName = 'currency';
- private $viewPath = 'currency';
- /**
- * 分销区域列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '币种管理';
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('currency_name|currency_code', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name($this->tableName)->where($condition)->count();
- $list = Db::name($this->tableName)->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存分销区域
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new \app\admin\validate\Currency();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name($this->tableName)->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name($this->tableName)->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name($this->tableName)->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除分销区域
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name($this->tableName)->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name($this->tableName)->where('id', $id)->delete();
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 清除缓存
- * @return void
- */
- private function delCache() {
- Cache::tag('currency')->clear();
- }
-
-}
diff --git a/app/admin/controller/DeliverRegion.php b/app/admin/controller/DeliverRegion.php
deleted file mode 100644
index f04dd37..0000000
--- a/app/admin/controller/DeliverRegion.php
+++ /dev/null
@@ -1,136 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\DeliverRegion as DeliverRegionValidate;
-
-class DeliverRegion extends Common {
-
- /**
- * 分销区域列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('region_name|region_code', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,deliver_region_id asc';
- $count = Db::name('deliver_region')->where($condition)->count();
- $list = Db::name('deliver_region')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存分销区域
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new DeliverRegionValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $deliver_region_id = input('post.deliver_region_id');
- if (is_numeric($deliver_region_id)) {
- //更新数据
- $update_result = Db::name('deliver_region')->where('deliver_region_id', $deliver_region_id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['deliver_region_id']);
- $add_result = Db::name('deliver_region')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('deliver_region')->where('deliver_region_id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- public function getCurrencyList() {
- try{
- $order = 'order_id asc,id asc';
- $list = Db::name('currency')->field("*")->order($order)->cacheAlways(TRUE, 0, 'currency')->select()->toArray();
- if (!$list) {
- $list = [];
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- }
- catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除分销区域
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $deliver_region_id = input('deliver_region_id');
- if (!is_numeric($deliver_region_id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['deliver_region_id'] = $deliver_region_id;
- $info = Db::name('deliver_region')->field('deliver_region_id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('deliver_region')->where('deliver_region_id', $deliver_region_id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/DeliverRegionLogistics.php b/app/admin/controller/DeliverRegionLogistics.php
deleted file mode 100644
index 129890f..0000000
--- a/app/admin/controller/DeliverRegionLogistics.php
+++ /dev/null
@@ -1,148 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use function think\db\getLastSql;
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\DeliverRegionLogistics as DeliverRegionLogisticsValidate;
-
-class DeliverRegionLogistics extends Common {
-
- /**
- * 分销区域物流列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'drg.order_id asc,drg.id asc';
- $count = Db::name('deliver_region_logistics')
- ->alias('drg')
- ->join('web_deliver_region dr', 'drg.deliver_region_id=dr.deliver_region_id')
- ->where($condition)->count();
- $list = Db::name('deliver_region_logistics')
- ->alias('drg')
- ->join('web_deliver_region dr', 'drg.deliver_region_id=dr.deliver_region_id')
- ->field("drg.*,dr.region_code,dr.region_name")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
-// echo Db::getLastSql();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
-// print_r($list);
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存分销区域物流
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new DeliverRegionLogisticsValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('deliver_region_logistics')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('deliver_region_logistics')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('deliver_region_logistics')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除分销区域物流
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('deliver_region_logistics')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('deliver_region_logistics')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- public function getDeliverRegionList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $order = 'order_id asc';
- $list = Db::name('deliver_region')->field("*")->order($order)->select()->toArray();
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/DisPlatform.php b/app/admin/controller/DisPlatform.php
deleted file mode 100644
index 259622a..0000000
--- a/app/admin/controller/DisPlatform.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\DisPlatform as DisPlatformValidate;
-
-class DisPlatform extends Common {
-
- /**
- * 分销平台列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('platform_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('dis_platform')->where($condition)->count();
- $list = Db::name('dis_platform')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存分销平台
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new DisPlatformValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('dis_platform')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('dis_platform')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('dis_platform')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除分销平台
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('dis_platform')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('dis_platform')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/Goods.php b/app/admin/controller/Goods.php
deleted file mode 100644
index 38c0874..0000000
--- a/app/admin/controller/Goods.php
+++ /dev/null
@@ -1,436 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\supplier\model\DistributionArea as DistributionAreaModel;
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\supplier\model\GoodsAnnex;
-use app\supplier\model\GoodsSpec;
-use app\supplier\model\GoodsAttribute;
-use app\supplier\model\GoodsLabel;
-use app\supplier\model\GoodsRetailPriceLimit;
-
-//use app\supplier\model\Goods;
-
-//商品零售价限制
-
-class Goods extends Common {
-
- /**
- * 商品管理
- * @return string
- */
- public function index() {
- return View::fetch();
- }
-
- /**
- * 获取商品列表
- * @return mixed
- */
- public function getGoodsList() {
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $platform_goods_code = input('platform_goods_code');
- $supplier_goods_code = input('supplier_goods_code');
-
- $condition['g.istemp'] = 1;//编辑过的商品
- if ($platform_goods_code) {
- $condition['g.platform_goods_code'] = $platform_goods_code;
- }
- if ($supplier_goods_code) {
- $condition['g.supplier_goods_code'] = $supplier_goods_code;
- }
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'g.id asc';
- $count = \app\supplier\model\Goods::alias('g')->where($condition)->count();
- $list = \app\supplier\model\Goods::alias('g')
- ->join('goods_desc gd', 'g.id=gd.goods_id')
- ->field("g.id,g.sales_form,g.supplier_goods_code,g.platform_goods_code,g.goods_purpose,g.add_time,g.status,g.publish_status,g.whether_dis,gd.goods_title_cn,g.first_cate_code,g.second_cate_code,g.three_cate_code,(select url from web_goods_picture where goods_id=g.id order by id asc limit 1) as picture,g.review_comments,g.is_show")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- throw new \Exception(lang('no_data_found'));
- }
- $categorylist = get_category();
- $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
- foreach ($list as &$item) {
- $item['first_cate_name'] = $categorylist[$item['first_cate_code']]['cate_name'];
- $item['second_cate_name'] = $categorylist[$item['second_cate_code']]['cate_name'];
- $item['three_cate_name'] = $categorylist[$item['three_cate_code']]['cate_name'];
- }
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'id,is_show';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name('goods')->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- /**
- * 审核商品
- * @return array|int[]
- */
- public function reviewGoods() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $id = input('post.id');
- if (!is_numeric($id)) {
- throw new \Exception(lang('invalid_id'));
- }
-
- $status = input('post.status');
- //更新数据
- $info = Db::name('goods')->field('id,status')->where('id', $id)->find();
- if (!$info) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- if ($status == 1) {
- Db::name('goods')->where('id', $id)->update(['status' => 1, 'review_comments' => '']);
- $message = '操作成功,审核通过';
- } else {
- $review_comments = trim(input('review_comments'));
- if (!$review_comments) {
- throw new \Exception('请填写审核不通过原因');
- }
- Db::name('goods')->where('id', $id)->update(['status' => 3, 'review_comments' => $review_comments]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
-
- } catch (\Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 创建商品
- * @return string
- */
- public function create() {
- ////////
- View::assign('menuitem', 'goods-index');
- $id = input('id');
- if (!is_numeric($id)) {
- $this->redirect(url('/admin/goods/index')->build());
- }
- $other['id'] = $id;
- View::assign('other', $other);
- return View::fetch();
- }
-
- public function getGoodsInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- throw new \Exception(lang('invalid_id'));
- }
-
- $where = [
- 'id' => $id,
- ];
- $info = Db::name('goods')->field('id,first_cate_code,second_cate_code,three_cate_code,brand_code')->where($where)->find();
- if ($info['three_cate_code']) {
- $info['cate_code'] = [$info['first_cate_code'], $info['second_cate_code'], $info['three_cate_code']];
- }
- $info['goods_purpose'] = json_decode($info['goods_purpose'], TRUE);
- //////获取描述标题数据/////////
- $where_other = [
- 'goods_id' => $info['id'],
- ];
- $goods_desc = Db::name('goods_desc')->field('goods_title_en,goods_title_cn')->where($where_other)->find();
- //获取描述内容数据
- $goods_desc_content = Db::name('goods_desc_content')->field('goods_desc_en,goods_desc_cn')->where($where_other)->find();
-
- ////////////////
- $result['info'] = $info;
- $result['goods_desc'] = $goods_desc;
- $result['goods_desc_content'] = $goods_desc_content;
- return $this->successResponse($result);
- } catch (\Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 获取商品分销信息
- * @return array|int[]
- */
- public function getGoodsDisInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
-
- $condition['g.istemp'] = 1;//编辑过的商品
- if ($id) {
- $condition['g.id'] = $id;
- }
-
- $info = \app\supplier\model\Goods::alias('g')
- ->join('goods_desc gd', 'g.id=gd.goods_id')
- ->join('goods_desc_content gdc', 'g.id=gdc.goods_id')
- ->field("g.id,g.warehouse_mode,g.sales_form,g.supplier_goods_code,g.platform_goods_code,g.goods_purpose,g.add_time,g.status,g.publish_status,g.whether_dis,g.is_limit_dis_platform,gd.goods_title_cn,gd.goods_title_en,gd.goods_keyword_en,gd.goods_keyword_cn,g.first_cate_code,g.second_cate_code,g.three_cate_code,g.docking_way,g.price_method,g.freight_attr_code,g.is_tort,g.is_stop_buy,g.recommend_man,gdc.goods_desc_en,gdc.goods_desc_cn")->where($condition)->find();
- if ($info) {
-// $categorylist = get_category();
-// $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
-// $info['first_cate_name'] = $categorylist[$info['first_cate_code']]['cate_name'];
-// $info['second_cate_name'] = $categorylist[$info['second_cate_code']]['cate_name'];
-// $info['three_cate_name'] = $categorylist[$info['three_cate_code']]['cate_name'];
- $info['attr_name'] = Db::name('goods_freight_attr')->where('attr_code', $info['freight_attr_code'])->value('attr_name');
- $info['goods_keyword_en'] = $info['goods_keyword_en'] ? json_decode($info['goods_keyword_en'], TRUE) : [];
- $info['goods_keyword_cn'] = $info['goods_keyword_cn'] ? json_decode($info['goods_keyword_cn'], TRUE) : [];
-
- $info['goodsSpecInfo'] = Db::name('goods_spec')->field('*')->where('goods_id', $info['id'])->find();
- $goods_attribute_info = Db::name('goods_attribute')->field('*')
- ->withAttr('material_main', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_one', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_two', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_three', function ($value, $data) {
- if ($value) {
- $value = json_decode($value, TRUE);
- return Db::name('goods_material')->whereIn('id', $value)->column('material_name');
- } else {
- return [];
- }
- })
- ->where('goods_id', $info['id'])->find();
- $info['goodsAttributeInfo'] = $goods_attribute_info;
- $info['goodsAttributExtendList'] = Db::name('goods_attribute_extend')->field('*')->where('goods_id', $info['id'])->select()->toArray();
-
- $info['goodsRetailPriceLimitList'] = GoodsRetailPriceLimit::field('*')->where('goods_id', $info['id'])
- ->withAttr('sale_country_code', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value("CONCAT(country_code,' ',country)");
- })
- ->withAttr('sales_platform', function ($value, $data) {
- return Db::name('sales_platform')->where('id', $value)->value("platform_name");
- })
- ->order('id asc')->select()->toArray();///
- $info['goodsLabelList'] = GoodsLabel::field('label_type,goods_label')->where('goods_id', $info['id'])->order('id asc')->select()->toArray();///
- if ($info['is_limit_dis_platform'] == 1) {
- $info['goodsLimitDisPlatformList'] = Db::name('goods_limit_dis_platform')
- ->alias('a')
- ->join('dis_platform b', 'a.dis_platform = b.id')
- ->field('b.platform_name')->where('goods_id', $info['id'])->order('a.id asc')->select()->toArray();///
- } else {
- $info['goodsLimitDisPlatformList'] = [];
- }
- $result['info'] = $info;
- ///分销区域//
- $disAreaList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('distribution_area da', 'da.id=gda.distribution_area_id')
- ->field("gda.one_shipment,gda.distribution_area_id")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)->withAttr('one_shipment', function ($value, $data) {
- return $value == 1 ? '一件代发' : '';
- })->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disAreaList'] = $disAreaList;
- //分销库存
- $disStockList = Db::name('goods_distribution_area_stock')
- ->alias('gdas')
- ->join('third_party_stock tps', 'tps.id=gdas.third_party_stock_id')
- ->field("gdas.distribution_area_id,gdas.supplier_stock_amount,gdas.platform_stock_amount,gdas.goods_distribution_area_id,tps.third_party_stock_name,tps.docking_code,tps.stock_type")->where('gdas.goods_id', $info['id'])->where('gdas.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disStockList'] = $disStockList;
- //分销价格///
- $disPriceList = Db::name('goods_distribution_area_price')
- ->alias('gdap')
- ->join('goods_distribution_area gda', 'gda.id=gdap.goods_distribution_area_id')
- ->join('logistics_product lp', 'lp.id=gdap.logistics_product_id')
- ->field("gdap.distribution_area_id,gdap.goods_distribution_area_id,lp.product_name_cn,gdap.supply_price,gdap.dis_price,gdap.package_goods_amount,gda.take_effect_time")->where('gdap.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('take_effect_time', function ($value, $data) {
- return date('Y-m-d H:i:s', $value);
- })->select()->toArray();
- $result['disPriceList'] = $disPriceList;
- //退货地址列表//
- $disReturnGoodsList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('third_party_stock tps', 'tps.id=gda.third_party_stock_id')
- ->join('third_party_stock_address tpsa', 'tpsa.id=gda.third_party_stock_address_id')
- ->field("gda.distribution_area_id,tps.third_party_stock_name,tpsa.stock_address,tpsa.stock_city,tpsa.stock_province,tpsa.stock_post_code,tpsa.stock_country_id,tpsa.receive_man,tpsa.tel")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('stock_country_id', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value('country');
- })
- ->select()->toArray();
- $result['disReturnGoodsList'] = $disReturnGoodsList;
- $categorylist = get_category();
- $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
- $catelist = Db::name('goods_category')
- ->alias('GC')
- ->join('docking_platform DP', 'DP.cate_code=GC.cate_code')
- ->field('GC.*,DP.docking_platform_name')->where(['GC.goods_id' => $info['id'], 'GC.status' => 1])->select()->toArray();
- foreach ($catelist as &$value) {
- $value['first_cate_name'] = $categorylist[$value['first_cate_code']]['cate_name'];
- $value['second_cate_name'] = $categorylist[$value['second_cate_code']]['cate_name'];
- $value['three_cate_name'] = $categorylist[$value['three_cate_code']]['cate_name'];
- }
- $result['catelist']=$catelist;
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取商品图片列表
- * @return array|int[]
- */
- public function getGoodsPictureList() {
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $goods_id = input('goods_id');
- $picture_type = input('picture_type');
-
- if (is_array($picture_type)) {
- $where[] = ['a.goods_id', '=', $goods_id];
- if (is_array($picture_type)) {
- $where[] = ['b.type', 'in', $picture_type];
- }
- $list = Db::name('goods_picture')
- ->alias('a')
- ->join('goods_picture_type b', 'a.id=b.picture_id')
- ->field('DISTINCT a.id,a.url')->where($where)->order('id asc')->select()->toArray();
- } else {
- $where[] = ['goods_id', '=', $goods_id];
- $list = Db::name('goods_picture')->field('id,url')->where($where)->order('id asc')->select()->toArray();
- }
- if (!$list) {
- throw new \Exception(lang('no_data_found'));
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 根据类型获取商品图片数量
- * @return void
- */
- public function getGoodsPictureCount() {
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $goods_id = input('goods_id');
- $goodsPictureCount['type0'] = Db::name('goods_picture')->where(['goods_id' => $goods_id])->count();
- $goodsPictureCount['type1'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 1])->count();
- $goodsPictureCount['type2'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 2])->count();
- $goodsPictureCount['type3'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 3])->count();
- $goodsPictureCount['type4'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 4])->count();
- $goodsPictureCount['type5'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 5])->count();
- $goodsPictureCount['type6'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 6])->count();
- $goodsPictureCount['type7'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 7])->count();
- $result['goodsPictureCount'] = $goodsPictureCount;
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取分销区域
- */
- private function getDisArea($id) {
- return Db::name('distribution_area')
- ->alias('da')
- ->join('deliver_region dr', 'dr.deliver_region_id=da.deliver_region_id')
- ->field("da.dis_currency,dr.region_name,da.dis_model")
- ->where('da.id', $id)->find();
- }
-
- /**
- * 获取分类列表
- * @return array
- */
- public function getCategoryList() {
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $result['list'] = $this->getchildrenids(0);
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 循环获取分类数据
- * @param $id
- * @return array|void
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\DbException
- * @throws \think\db\exception\ModelNotFoundException
- */
- protected function getchildrenids($id) {
- $where['father_code'] = $id;
- $result = Db::name('category')->field('id,cate_code as value,cate_name as label')->where($where)->cacheAlways(TRUE, 0, 'category')->order('id asc')->select()->toArray();
- if ($result) {
- foreach ($result as &$val) {
- $val['children'] = $this->getchildrenids($val['value']); ////
- }
- return $result;
- }
- }
-
-}
diff --git a/app/admin/controller/GoodsBrand.php b/app/admin/controller/GoodsBrand.php
deleted file mode 100644
index 5003ad7..0000000
--- a/app/admin/controller/GoodsBrand.php
+++ /dev/null
@@ -1,181 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\supplier\model\GoodsAnnex;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\Request;
-use think\facade\View;
-use think\Exception;
-
-class GoodsBrand extends Common {
- /*
- * 品牌管理
- */
- public function index(): string {
- View::assign('menuitem', strtolower('goodsBrand-index'));
- $other['title'] = '品牌管理';
- $guide['one']['text'] = '数据审核';
- $guide['two']['text'] = '品牌审核';
- $guide['two']['url'] = url('/admin/supplier/index')->build();
- View::assign('guide', $guide);
- View::assign('other', $other);
- return View::fetch('index');
- }
-
- /*
- * 获取商品品牌列表
- */
- public function getGoodsBrandList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $kw = input('kw');
- $condition['istemp'] = 1;
- $condition['finish_status'] = 1;
- $condition['status'] = 0;
- if (!empty($kw)) {
- $condition[] = array('brand_name', 'like', "%$kw%");
- }
- $p = input('page', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'id desc';
- $count = Db::name('goods_brand')->where($condition)->count();
- $list = Db::name('goods_brand')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['code'] = 200;
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
-
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /*
- * 获取品牌证书列表
- */
- public function getBrandCertList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $brand_id = input('brand_id');
- $where['brand_id'] = $brand_id;
- $list = Db::name('goods_brand_cert')->field('id,title,filename,filesize,ext')->where($where)->withAttr('filesize', function ($value) {
- return getsizebytype($value);
- })->order('id asc')->select()->toArray();///
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /*
- * 获取品牌协议列表
- */
- public function getBrandAgreementList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $brand_id = input('brand_id');
- $where['brand_id'] = $brand_id;
- $list = Db::name('goods_brand_agreement')->field('id,title,filename,filesize,ext')->where($where)->withAttr('filesize', function ($value) {
- return getsizebytype($value);
- })->order('id asc')->select()->toArray();///
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /*
- * 获取品牌备案范围列表
- */
- public function getGoodsBrandFilingsList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $brand_id = input('brand_id');
- $where['GBF.brand_id'] = $brand_id;
- $list = Db::name('goods_brand_filings')
- ->alias('GBF')
- ->join('stock_country SC', 'GBF.stock_country_id=SC.id')
- ->join('dis_platform DP', 'GBF.dis_platform_id=DP.id')
- ->field('GBF.*,SC.country,DP.platform_name')->where($where)->order('GBF.id asc')->select()->toArray();///
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 品牌审核
- * @return array|int[]
- */
- public function reviewGoodsBrand() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $brand_id = input('post.brand_id');
- if (is_numeric($brand_id)) {
- $status = input('post.status');
- //更新数据
- $info = Db::name('goods_brand')->field('id,status')->where('id', $brand_id)->find();
- if (!$info) {
- throw new Exception(lang('no_data_found'));
- }
- if ($info['status'] == 1) {
- throw new Exception('该申请已审核通过,不能重复审核');
- }
- if ($status == 1) {
- Db::name('goods_brand')->where('id', $brand_id)->update(['status' => 1]);
- $message = '操作成功,审核通过';
- } else {
- Db::name('goods_brand')->where('id', $brand_id)->update(['status' => 2]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
- } else {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
\ No newline at end of file
diff --git a/app/admin/controller/GoodsFreightAttr.php b/app/admin/controller/GoodsFreightAttr.php
deleted file mode 100644
index a71e7ff..0000000
--- a/app/admin/controller/GoodsFreightAttr.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\GoodsFreightAttr as GoodsFreightAttrValidate;
-
-class GoodsFreightAttr extends Common {
-
- /**
- * 货运属性列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('attr_name|attr_code', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('goods_freight_attr')->where($condition)->count();
- $list = Db::name('goods_freight_attr')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存货运属性
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new GoodsFreightAttrValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('goods_freight_attr')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('goods_freight_attr')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('goods_freight_attr')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除货运属性
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('goods_freight_attr')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('goods_freight_attr')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/GoodsMaterial.php b/app/admin/controller/GoodsMaterial.php
deleted file mode 100644
index 2fb781e..0000000
--- a/app/admin/controller/GoodsMaterial.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\GoodsMaterial as GoodsMaterialValidate;
-
-class GoodsMaterial extends Common {
-
- /**
- * 材质管理列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('material_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('goods_material')->where($condition)->count();
- $list = Db::name('goods_material')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存材质
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new GoodsMaterialValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('goods_material')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('goods_material')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('goods_material')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除材质
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('goods_material')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('goods_material')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/GoodsPurpose.php b/app/admin/controller/GoodsPurpose.php
deleted file mode 100644
index 8a5dd1f..0000000
--- a/app/admin/controller/GoodsPurpose.php
+++ /dev/null
@@ -1,133 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\GoodsPurpose as GoodsPurposeValidate;
-
-class GoodsPurpose extends Common {
-
- /**
- * 商品用途列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('purpose_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('goods_purpose')->where($condition)->count();
- $list = Db::name('goods_purpose')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存商品用途
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new GoodsPurposeValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('goods_purpose')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('goods_purpose')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('goods_purpose')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除商品用途
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('goods_purpose')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('goods_purpose')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 清除缓存
- * @return void
- */
- private function delCache() {
- Cache::tag('goods_purpose')->clear();
- }
-
-}
diff --git a/app/admin/controller/Goodskd.php b/app/admin/controller/Goodskd.php
deleted file mode 100644
index bae8988..0000000
--- a/app/admin/controller/Goodskd.php
+++ /dev/null
@@ -1,519 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\supplier\model\DistributionArea as DistributionAreaModel;
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\supplier\model\GoodsAnnex;
-use app\supplier\model\GoodsSpec;
-use app\supplier\model\GoodsAttribute;
-use app\supplier\model\GoodsLabel;
-use app\supplier\model\GoodsRetailPriceLimit;
-
-//use app\supplier\model\Goods;
-
-//商品零售价限制
-
-class Goodskd extends Common {
-
- /**
- * 商品管理
- * @return string
- */
- public function index() {
- return View::fetch();
- }
-
- /**
- * 获取刊登列表
- * @return mixed
- */
- public function getGoodsList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $platform_goods_code = input('platform_goods_code');
- $supplier_goods_code = input('supplier_goods_code');
-
- $condition['g.istemp'] = 1;//编辑过的商品
- $condition['g.kd_audit_status'] = 2;
- if ($platform_goods_code) {
- $condition['g.platform_goods_code'] = $platform_goods_code;
- }
- if ($supplier_goods_code) {
- $condition['g.supplier_goods_code'] = $supplier_goods_code;
- }
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'g.id asc';
- $count = \app\supplier\model\Goods::alias('g')->where($condition)->count();
- $list = \app\supplier\model\Goods::alias('g')
- ->join('goods_desc gd', 'g.id=gd.goods_id')
- ->field("g.id,g.sales_form,g.supplier_goods_code,g.platform_goods_code,gd.goods_title_cn,(select url from web_goods_picture where goods_id=g.id order by id asc limit 1) as picture,g.kd_review_comments,g.kd_publish_status,g.kd_audit_status")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- throw new Exception(lang('no_data_found'));
- }
-// $categorylist = get_category();
-// $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
-// foreach ($list as &$item) {
-// $item['first_cate_name'] = $categorylist[$item['first_cate_code']]['cate_name'];
-// $item['second_cate_name'] = $categorylist[$item['second_cate_code']]['cate_name'];
-// $item['three_cate_name'] = $categorylist[$item['three_cate_code']]['cate_name'];
-// }
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 审核商品刊登
- * @return array|int[]
- */
- public function reviewGoodsKD() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('post.id');
- if (!is_numeric($id)) {
- throw new Exception(lang('invalid_id'));
- }
- $status = input('post.status');
- //更新数据
- $info = Db::name('goods')->field('id,kd_publish_status,kd_audit_status,supplier_goods_code')->where('id', $id)->find();
- if (!$info) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- if ($status == 1) {
- //status=kd_publish_status
- $kd_data = [
- 'status' => 1,
- 'kd_publish_status' => 1,
- 'kd_audit_status' => 1,
- 'kd_review_comments' => '',
- ];
- Db::name('goods')->where('id', $id)->update($kd_data);
- $message = '操作成功,审核通过';
- } else {
- $kd_review_comments = trim(input('kd_review_comments'));
- if (!$kd_review_comments) {
- throw new Exception('请填写审核不通过原因');
- }
- $kd_data = [
- 'status' => 0,
- 'kd_publish_status' => 0,
- 'kd_audit_status' => 3,
- 'kd_review_comments' => $kd_review_comments,
- ];
- Db::name('goods')->where('id', $id)->update($kd_data);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
- /**
- * 审核商品刊登
- * @return array|int[]
- */
-
-
- /**
- * 商品刊登审核
- * @return string
- */
- public function create() {
- ////////
- View::assign('menuitem', 'goodskd-index');
- $id = input('id');
- if (!is_numeric($id)) {
- $this->redirect(url('/admin/goodskd/index')->build());
- }
- $other['id'] = $id;
- View::assign('other', $other);
- return View::fetch();
- }
-
- public function getGoodsInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- throw new Exception(lang('invalid_id'));
- }
-
- $where = [
- 'id' => $id,
- ];
- $info = Db::name('goods')->field('id,first_cate_code,second_cate_code,three_cate_code,brand_code')->where($where)->find();
- if ($info['three_cate_code']) {
- $info['cate_code'] = [$info['first_cate_code'], $info['second_cate_code'], $info['three_cate_code']];
- }
- $info['goods_purpose'] = json_decode($info['goods_purpose'], TRUE);
- //////获取描述标题数据/////////
- $where_other = [
- 'goods_id' => $info['id'],
- ];
- $goods_desc = Db::name('goods_desc')->field('goods_title_en,goods_title_cn')->where($where_other)->find();
- //获取描述内容数据
- $goods_desc_content = Db::name('goods_desc_content')->field('goods_desc_en,goods_desc_cn')->where($where_other)->find();
-
- ////////////////
- $result['info'] = $info;
- $result['goods_desc'] = $goods_desc;
- $result['goods_desc_content'] = $goods_desc_content;
- return $this->successResponse($result);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 获取商品分销信息
- * @return array|int[]
- */
- public function getGoodsDisInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
-// $supplier_goods_code = input('supplier_goods_code');
- $id = input('id');
- $condition['g.istemp'] = 1;//编辑过的商品
- $condition['g.id'] = $id;
-
- $info = \app\supplier\model\Goods::alias('g')
- ->join('goods_desc gd', 'g.id=gd.goods_id')
- ->join('goods_desc_content gdc', 'g.id=gdc.goods_id')
- ->field("g.id,g.warehouse_mode,g.sales_form,g.supplier_goods_code,g.platform_goods_code,g.goods_purpose,g.add_time,g.status,g.publish_status,g.whether_dis,g.is_limit_dis_platform,gd.goods_title_cn,gd.goods_title_en,gd.goods_keyword_en,gd.goods_keyword_cn,g.first_cate_code,g.second_cate_code,g.three_cate_code,g.docking_way,g.price_method,g.freight_attr_code,g.is_tort,g.is_stop_buy,g.recommend_man,gdc.goods_desc_en,gdc.goods_desc_cn")->where($condition)->find();
- if ($info) {
-
- $info['attr_name'] = Db::name('goods_freight_attr')->where('attr_code', $info['freight_attr_code'])->value('attr_name');
- $info['goods_keyword_en'] = $info['goods_keyword_en'] ? json_decode($info['goods_keyword_en'], TRUE) : [];
- $info['goods_keyword_cn'] = $info['goods_keyword_cn'] ? json_decode($info['goods_keyword_cn'], TRUE) : [];
-
- $info['goodsSpecInfo'] = Db::name('goods_spec')->field('*')->where('goods_id', $info['id'])->find();
- $goods_attribute_info = Db::name('goods_attribute')->field('*')
- ->withAttr('material_main', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_one', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_two', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_three', function ($value, $data) {
- if ($value) {
- $value = json_decode($value, TRUE);
- return Db::name('goods_material')->whereIn('id', $value)->column('material_name');
- } else {
- return [];
- }
- })
- ->where('goods_id', $info['id'])->find();
- $info['goodsAttributeInfo'] = $goods_attribute_info;
- $info['goodsAttributExtendList'] = Db::name('goods_attribute_extend')->field('*')->where('goods_id', $info['id'])->select()->toArray();
-
- $info['goodsRetailPriceLimitList'] = GoodsRetailPriceLimit::field('*')->where('goods_id', $info['id'])
- ->withAttr('sale_country_code', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value("CONCAT(country_code,' ',country)");
- })
- ->withAttr('sales_platform', function ($value, $data) {
- return Db::name('sales_platform')->where('id', $value)->value("platform_name");
- })
- ->order('id asc')->select()->toArray();///
- $info['goodsLabelList'] = GoodsLabel::field('label_type,goods_label')->where('goods_id', $info['id'])->order('id asc')->select()->toArray();///
- if ($info['is_limit_dis_platform'] == 1) {
- $info['goodsLimitDisPlatformList'] = Db::name('goods_limit_dis_platform')
- ->alias('a')
- ->join('dis_platform b', 'a.dis_platform = b.id')
- ->field('b.platform_name')->where('goods_id', $info['id'])->order('a.id asc')->select()->toArray();///
- } else {
- $info['goodsLimitDisPlatformList'] = [];
- }
- $result['info'] = $info;
- ///分销区域//
- $disAreaList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('distribution_area da', 'da.id=gda.distribution_area_id')
- ->field("gda.one_shipment,gda.distribution_area_id")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)->withAttr('one_shipment', function ($value, $data) {
- return $value == 1 ? '一件代发' : '';
- })->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disAreaList'] = $disAreaList;
- //分销库存
- $disStockList = Db::name('goods_distribution_area_stock')
- ->alias('gdas')
- ->join('third_party_stock tps', 'tps.id=gdas.third_party_stock_id')
- ->field("gdas.distribution_area_id,gdas.supplier_stock_amount,gdas.platform_stock_amount,gdas.goods_distribution_area_id,tps.third_party_stock_name,tps.docking_code,tps.stock_type")->where('gdas.goods_id', $info['id'])->where('gdas.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disStockList'] = $disStockList;
- //分销价格///
- $disPriceList = Db::name('goods_distribution_area_price')
- ->alias('gdap')
- ->join('goods_distribution_area gda', 'gda.id=gdap.goods_distribution_area_id')
- ->join('logistics_product lp', 'lp.id=gdap.logistics_product_id')
- ->field("gdap.distribution_area_id,gdap.goods_distribution_area_id,lp.product_name_cn,gdap.supply_price,gdap.dis_price,gdap.package_goods_amount,gda.take_effect_time")->where('gdap.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('take_effect_time', function ($value, $data) {
- return date('Y-m-d H:i:s', $value);
- })->select()->toArray();
- $result['disPriceList'] = $disPriceList;
- //退货地址列表//
- $disReturnGoodsList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('third_party_stock tps', 'tps.id=gda.third_party_stock_id')
- ->join('third_party_stock_address tpsa', 'tpsa.id=gda.third_party_stock_address_id')
- ->field("gda.distribution_area_id,tps.third_party_stock_name,tpsa.stock_address,tpsa.stock_city,tpsa.stock_province,tpsa.stock_post_code,tpsa.stock_country_id,tpsa.receive_man,tpsa.tel")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('stock_country_id', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value('country');
- })
- ->select()->toArray();
- $result['disReturnGoodsList'] = $disReturnGoodsList;
-
- $categorylist = get_category();
- $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
- $catelist = Db::name('goods_category')
- ->alias('GC')
- ->join('docking_platform DP', 'DP.cate_code=GC.cate_code')
- ->field('GC.*,DP.docking_platform_name')->where(['GC.goods_id' => $info['id'], 'GC.status' => 1])->select()->toArray();
- foreach ($catelist as &$value) {
- $value['first_cate_name'] = $categorylist[$value['first_cate_code']]['cate_name'];
- $value['second_cate_name'] = $categorylist[$value['second_cate_code']]['cate_name'];
- $value['three_cate_name'] = $categorylist[$value['three_cate_code']]['cate_name'];
- }
- $result['catelist']=$catelist;
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('no_data_found'));
- }
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取商品图片列表
- * @return array|int[]
- */
- public function getGoodsPictureList() {
-
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $goods_id = input('goods_id');
- $picture_type = input('picture_type');
-
- if (is_array($picture_type)) {
- $where[] = ['a.goods_id', '=', $goods_id];
- if (is_array($picture_type)) {
- $where[] = ['b.type', 'in', $picture_type];
- }
- $list = Db::name('goods_picture')
- ->alias('a')
- ->join('goods_picture_type b', 'a.id=b.picture_id')
- ->field('DISTINCT a.id,a.url')->where($where)->order('id asc')->select()->toArray();
- } else {
- $where[] = ['goods_id', '=', $goods_id];
- $list = Db::name('goods_picture')->field('id,url')->where($where)->order('id asc')->select()->toArray();
- }
- if (!$list) {
- return $this->errorResponse(lang('no_data_found'));
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 根据类型获取商品图片数量
- * @return void
- */
- public function getGoodsPictureCount() {
-
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $goods_id = input('goods_id');
- $goodsPictureCount['type0'] = Db::name('goods_picture')->where(['goods_id' => $goods_id])->count();
- $goodsPictureCount['type1'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 1])->count();
- $goodsPictureCount['type2'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 2])->count();
- $goodsPictureCount['type3'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 3])->count();
- $goodsPictureCount['type4'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 4])->count();
- $goodsPictureCount['type5'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 5])->count();
- $goodsPictureCount['type6'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 6])->count();
- $goodsPictureCount['type7'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 7])->count();
- $result['goodsPictureCount'] = $goodsPictureCount;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取分销区域
- */
- private function getDisArea($id) {
- return Db::name('distribution_area')
- ->alias('da')
- ->join('deliver_region dr', 'dr.deliver_region_id=da.deliver_region_id')
- ->field("da.dis_currency,dr.region_name,da.dis_model")
- ->where('da.id', $id)->find();
- }
-
- /**
- * 获取刊登信息
- * @return array|int[]
- */
- public function getPublishOrderInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- throw new Exception(lang('invalid_id'));
- }
- $where = [
- 'id' => $id,
- ];
- $info = Db::name('publish_order')->field('*')->where($where)->find();
- if ($info['three_cate_code']) {
- $info['cate_code'] = [$info['first_cate_code'], $info['second_cate_code'], $info['three_cate_code']];
- }
- //////获取描述标题数据/////////
- $where_other = [
- 'publish_order_id' => $id,
- ];
- ////////////////
- $result['info'] = $info;
- return $this->successResponse($result);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
-
- /**
- * 获取商品图片列表
- * @return array|int[]
- */
- public function getPublishOrderPictureList() {
-
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $publish_order_id = input('publish_order_id');
-
- $where[] = ['publish_order_id', '=', $publish_order_id];
- $list = Db::name('publish_order_picture')->field('id,url')->where($where)->order('id asc')->select()->toArray();
- if (!$list) {
- throw new Exception(lang('no_data_found'));
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /**
- * 获取分类列表
- * @return array
- */
- public function getCategoryList() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $result['list'] = $this->getchildrenids(0);
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 循环获取分类数据
- * @param $id
- * @return array|void
- */
- protected function getchildrenids($id) {
- $where['father_code'] = $id;
- $result = Db::name('category')->field('id,cate_code as value,cate_name as label')->where($where)->cacheAlways(TRUE, 0, 'category')->order('id asc')->select()->toArray();
- if ($result) {
- foreach ($result as &$val) {
- $val['children'] = $this->getchildrenids($val['value']); ////
- }
- return $result;
- }
- }
-
- /**
- * 商品发布
- * @return array|int[]
- */
- public function goodsPublish() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $publish_order_id = input('publish_order_id');
- $goods_info = Db::name('goods')->field('id')->where('id', $publish_order_id)->find();
- if (!$goods_info) {
- throw new Exception(lang('goods_not_exist'));
- }
- $update_data = [
- 'publish_status' => 1,
- 'update_time' => time(),
- ];
- Db::name('goods')->where('id', $publish_order_id)->update($update_data);
- // 提交事务
- Db::commit();
- return $this->successResponse(lang('goods_publish_success'));
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-}
diff --git a/app/admin/controller/Language.php b/app/admin/controller/Language.php
deleted file mode 100644
index 0aecf97..0000000
--- a/app/admin/controller/Language.php
+++ /dev/null
@@ -1,141 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\admin\model\Language as LanguageModel;
-
-class Language extends Common {
- private $tableName = 'language';
- private $viewPath = 'language';
-
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '多语言管理';
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = LanguageModel::where($condition)->count();
- $list = LanguageModel::field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'id,is_show';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name($this->tableName)->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 保存
- */
- public function save() {
- //开始事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- $validate=new \app\admin\validate\Language();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new Exception($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name($this->tableName)->where('id', $id)->withoutField('id,delete_time')->save($data);
- if ($update_result === FALSE) {
- throw new Exception(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name($this->tableName)->insertGetId($data);
- if (!$add_result) {
- throw new Exception(lang('add_failed'));
- }
- Db::name($this->tableName)->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name($this->tableName)->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name($this->tableName)->where('id', $id)->useSoftDelete('delete_time',time())->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/LanguagePag.php b/app/admin/controller/LanguagePag.php
deleted file mode 100644
index ad90498..0000000
--- a/app/admin/controller/LanguagePag.php
+++ /dev/null
@@ -1,361 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Cache;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\admin\model\LanguagePag as LanguagePagModel;
-use app\admin\model\Language;
-
-class LanguagePag extends Common {
- private $tableName = 'language_pag';
- private $viewPath = 'languagePag';
-
- /**
- * 货运属性列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '多语言包管理';
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- } else {
- try {
- $platform_type = input('platform_type');
- $lang = input('lang');
- $type = input('type');
- $name = input('name');
- $value = input('value');
- $condition = [];
- if (!empty($platform_type)) {
- $condition[] = ['platform_type', '=', $platform_type];
- }
- if (!empty($lang)) {
- $condition[] = ['lang', '=', $lang];
- }
- if (!empty($type)) {
- $condition[] = ['type', '=', $type];
- }
- if (!empty($name)) {
- $condition[] = ['name', 'like', "%$name%"];
- }
- if (!empty($value)) {
- $condition[] = ['value', 'like', "%$value%"];
- }
-
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'id desc';
- $count = LanguagePagModel::where($condition)->count();
- $list = LanguagePagModel::field("id,lang,type,name,value,platform_type")->append(['from_value'])->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /*
- * 同步语言包
- */
- public function sync() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- if (!isset($data['from_id']) || !is_numeric($data['from_id']) || $data['from_id'] < 1) {
- throw new Exception('源语言ID错误');
- }
- $from_id = $data['from_id'];
- if (!isset($data['to_id']) || !is_numeric($data['to_id']) || $data['to_id'] < 1) {
- throw new Exception('目标语言ID错误');
- }
- $to_id = $data['to_id'];
- //获取源语言
- $from = Language::find($from_id);
- if ($from->isEmpty()) {
- throw new Exception('源语言不存在');
- }
- $platform_type = $data['platform_type'];//平台类型
-
- //获取目标语言
- $to = Language::find($to_id);
- if ($to->isEmpty()) {
- throw new Exception('目标语言不存在');
- }
- //获取源语言
- $pags = LanguagePagModel::where(['platform_type' => $platform_type, 'lang' => $from['symbol']])
- ->order(['type' => 'asc', 'name' => 'asc'])
- ->select()
- ->toArray();
-
- foreach ($pags as &$pag) {
- //查询是否存在
- $to_pag = LanguagePagModel::where(['platform_type' => $platform_type, 'lang' => $to['symbol'], 'type' => $pag['type'], 'name' => $pag['name']])->findOrEmpty();
- if ($to_pag->isEmpty()) {
- LanguagePagModel::create([
- 'platform_type' => $platform_type,
- 'lang' => $to['symbol'],
- 'type' => $pag['type'],
- 'name' => $pag['name'],
- ]);
- }
- }
- Db::commit();
- return $this->successResponse('同步成功!');
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /*
- * 翻译语言包
- */
- public function trans() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- if (!isset($data['from_id']) || !is_numeric($data['from_id']) || $data['from_id'] < 1) {
- throw new Exception('源语言ID错误');
- }
- $from_id = $data['from_id'];
- if (!isset($data['to_id']) || !is_numeric($data['to_id']) || $data['to_id'] < 1) {
- throw new Exception('目标语言ID错误');
- }
- $to_id = $data['to_id'];
- //获取源语言
- $from = Language::find($from_id);
- if ($from->isEmpty()) {
- throw new Exception('源语言不存在');
- }
- //获取目标语言
- $to = Language::find($to_id);
- if ($to->isEmpty()) {
- throw new Exception('目标语言不存在');
- }
- $platform_type = $data['platform_type'];//平台类型
- //获取待翻译目标语言
- $pags = LanguagePagModel::where(['platform_type' => $platform_type, 'lang' => $to['symbol']])
- ->where(" value IS NULL OR value='' ")
- ->order(['type' => 'asc', 'name' => 'asc'])
- ->select()
- ->toArray();
-
- $qArray = array();
-
- $idArray = array();
- foreach ($pags as &$pag) {
- //查询源语言
- $from_pag = LanguagePagModel::where(['platform_type' => $platform_type, 'lang' => $from['symbol'], 'type' => $pag['type'], 'name' => $pag['name']])->where(" value IS NOT NULL OR value='' ")->findOrEmpty();
- if ($from_pag->isEmpty()) {
- continue;
- } else {
- array_push($qArray, $from_pag['value']);
- array_push($idArray, $pag['id']);
- }
- }
- if (count($qArray) == 0) throw new Exception('不存在待翻译的内容');
- $YDObj = new \app\common\service\YouDaoTrans();
- $ret = $YDObj->do_translate($qArray, $from['trans_symbol'], $to['trans_symbol']);
- $ret = json_decode($ret, TRUE);
- if ($ret['errorCode'] != 0) {
- throw new Exception('错误代码:' . $ret['errorCode'] . ',请核对错误代码列表');
- }
- foreach ($idArray as $key => $id) {
- LanguagePagModel::update([
- 'id' => $id,
- 'value' => $ret['translateResults'][$key]['translation'],
- ]);
- }
- Db::commit();
- return $this->successResponse('翻译成功!');
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- public function getLanguageList() {
- ////////
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $condition['is_show'] = 1;
- $order = 'order_id asc,id asc';
- $list = Db::name('language')->field("*")->where($condition)->order($order)->select()->toArray();
- if (!$list) {
- $list = [];
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
- /**
- *保存
- */
- public function save() {
- //开始事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- $id = input('post.id');
- if (!is_numeric($id) || $id < 1) {
- unset($data['id']);
- }
- $validate = new \app\admin\validate\LanguagePag();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new Exception($validate->getError());
- }
-
- if (is_numeric($id) && $id > 0) {
- //更新数据
- $update_result = LanguagePagModel::where('id', $id)->withoutField('id')->update($data);
- if ($update_result === FALSE) {
- throw new Exception(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- $add_result = LanguagePagModel::insertGetId($data);
- if (!$add_result) {
- throw new Exception(lang('add_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name($this->tableName)->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name($this->tableName)->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /*
- * 清除值
- */
- public function clearValue() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name($this->tableName)->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name($this->tableName)->where('id', $id)->update(['value'=>'']);
- //提交事务
- Db::commit();
- return $this->successResponse('值已清空!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 生成json包
- */
- public function createJson() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $list = Language::order('order_id asc,id asc')->select()->toArray();
- foreach ($list as $item) {
- $paglist = LanguagePagModel::field("platform_type,lang,type,name,value")
- ->where(['lang' => $item['symbol']])
- ->order(['type' => 'asc', 'name' => 'asc', 'value' => 'asc'])
- ->select()
- ->toArray();
- if (!$paglist) {
- continue;
- }
- foreach ($paglist as $pag){
- $pag_result[$pag['platform_type']][$pag['lang']][$pag['type']][$pag['name']] = $pag['value'];
- }
- //生成json包
- foreach ($pag_result as $pltype => $platformtype){
- //平台类型
- foreach ($platformtype as $lang => $paglang){
- $json = json_encode($paglang, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE);
- // 保存文件
- g_mkdir("./static/lang/$pltype");
- $filePath="./static/lang/$pltype/$lang" . '.json';
- file_put_contents($filePath, $json);
- }
- }
- }
- $result='生成成功!';
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
-}
diff --git a/app/admin/controller/LogisticsVas.php b/app/admin/controller/LogisticsVas.php
deleted file mode 100644
index a1bdbf5..0000000
--- a/app/admin/controller/LogisticsVas.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\LogisticsVas as LogisticsVasValidate;
-
-class LogisticsVas extends Common {
-
- /**
- * 增值服务列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('vas_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('logistics_vas')->where($condition)->count();
- $list = Db::name('logistics_vas')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存增值服务
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new LogisticsVasValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('logistics_vas')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('logistics_vas')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('logistics_vas')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除增值服务
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('logistics_vas')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('logistics_vas')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/Menu.php b/app/admin/controller/Menu.php
deleted file mode 100644
index 8dea565..0000000
--- a/app/admin/controller/Menu.php
+++ /dev/null
@@ -1,125 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use think\Exception;
-
-use app\admin\util\MenuService;
-
-class Menu extends Common {
- private $menuService;
- private $tableName = 'supplier_menu';
- private $viewPath = 'menu';
-
-
- public function __construct() {
- parent::__construct();
- $this->menuService = new MenuService();
- }
-
- /**
- * 菜单列表
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '供应商菜单';
- $guide['one']['text'] = '供应商管理';
- $guide['two']['text'] = '供应商列表';
- View::assign('guide', $guide);
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch('index');
- } else {
- $order = 'order_id asc,id asc';
- $list = $this->menuService->getMenuList($this->tableName, $order);
- $result['list'] = $list;
- return $this->successResponse($result);
- }
- }
-
- /**
- * 更新菜单显示状态
- */
- public function updateShowMenu() {
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- throw new Exception('参数错误!', 400);
- }
- $showMenu = input('show_menu');
- $isUpdate = $this->menuService->upShowMenu($this->tableName, (int)$id, $showMenu);
- if (!$isUpdate) {
- throw new Exception('更新失败!', 400);
- }
- return $this->successResponse('更新成功');
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
- /*
- * 获取菜单详情
- */
- public function getMenuDetail() {
- try {
- if (!Request::isPost()){
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- throw new Exception('参数错误!', 400);
- }
- $menuDetail = $this->menuService->getMenuDetail($this->tableName, (int)$id);
- if(!$menuDetail){
- throw new Exception('菜单不存在!', 400);
- }
- $result['info']=$menuDetail;
- return $this->successResponse($result);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 保存菜单
- * @return array|int[]
- */
- public function saveMenu() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //启动事务
- Db::startTrans();
- try {
- $data = Request::post();
- $id = $data['id'];
- if (isset($data['langs']) && $data['langs']) {
- $data['langs'] = json_encode($data['langs'], JSON_UNESCAPED_UNICODE);
- }
- if (is_numeric($id)) {
- //更新数据
- $this->menuService->upMenu($this->tableName, (int)$id, $data);
- $res['message'] = '菜单编辑成功';
- } else {
- unset($data['id']);
- $this->menuService->addMenu($this->tableName, (int)$id, $data);
- $res['message'] = '菜单添加成功';
- }
- ///////执行成功,提交事务///////
- Db::commit();
- return $this->successResponse($res);
- } catch (Exception $e) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($e->getMessage());
- }
- }
-}
diff --git a/app/admin/controller/Message.php b/app/admin/controller/Message.php
deleted file mode 100644
index 2a039a2..0000000
--- a/app/admin/controller/Message.php
+++ /dev/null
@@ -1,325 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-//商品零售价限制
-
-class Message extends Common {
-
- private $viewPath = 'Message';
- /**
- * 公告管理
- * @return string
- */
- public function index() {
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- }
- /*
- * 获取消息列表
- */
- public function getMessageList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $condition = [];
- $kw = input('kw');
- if ($kw) {
- $condition[] = ['title', 'like', '%' . $kw . '%'];
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'M.id asc';
- $count = Db::name('message')
- ->alias('M')
- ->join('msg_category MC','M.msg_category_id=MC.id','left')
- ->where($condition)->count();
- $list = Db::name('message')
- ->alias('M')
- ->join('msg_category MC','M.msg_category_id=MC.id','left')
- ->field("M.*,MC.title as catetitle")->where($condition)->order($order)->withAttr('publish_time', function ($value) {
- return date('Y-m-d H:i:s', $value);
- })->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if ($list) {
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 创建消息
- */
- public function create() {
- ////////
- View::assign('menuitem', 'message-index');
- $id = input('id');
- $other['id'] = $id;
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- }
-
- public function getMessageDetail() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('message_id');
- if (!$id) {
- throw new Exception(lang('param_error'));
- }
- $info = \app\admin\model\Message::field("*")->where('id', $id)->withAttr('publish_time', function ($value) {return date('Y-m-d H:i:s', $value);})->find();
- if ($info) {
- $result['info']=$info;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 更新消息状态
- */
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'id,status';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name('message')->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- }
- catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 保存消息信息
- */
- public function saveMessage() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
-
- $data = Request::post();
- $validate = new \app\admin\validate\Message();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new Exception($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- $data['publish_time'] = strtotime($data['publish_time']);
- $data['update_time'] = time();
- Db::name('message')->where('id', $id)->update($data);//更新数据
- // 提交事务
- Db::commit();
- $result['id'] = $id;
- $result['message'] = lang('successfully_saved');
- return $this->successResponse($result);
- } else {
- unset($data['id']);
- $data['publish_time'] = strtotime($data['publish_time']);
- $data['add_time'] = time();
- $data['update_time'] = time();
- $newid = Db::name('message')->insertGetId($data);
- Db::commit();
- $result['id'] = $newid;
- $result['message'] = lang('successfully_saved');
- return $this->successResponse($result);
- }
- } catch (\Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 上传附件
- */
- public function uploadAttachment() {
- $message_id = input('message_id');
- $ext_arr = array(
- 'image' => array('gif', 'jpg', 'jpeg', 'bmp', 'png'),
- 'files' => array('doc', 'docx', 'xls', 'xlsx', 'pptx', 'ppt', 'pdf'),
- );
- $maxSizeArr = array(
- 'image' => 1024 * 1024 * 10,
- 'files' => 1024 * 1024 * 250,
- );
-
- $upload = new \common\UploadFile(); // 实例化上传类
- $upload->uploadReplace = TRUE; //同名文件自动覆盖
- $upload->autoSub = TRUE; // 启用子目录保存文件
- $upload->subType = 'date'; // 子目录创建方式 可以使用hash date custom
- $upload->dateFormat = 'Y/m/d'; //定义 subType=date 后,才需要定义dateFormat
- $upload->maxSize = 1024 * 1024 * 0; // 设置附件上传大小 10M
- $upload->maxSizeArr = $maxSizeArr; // 设置附件上传大小 10M
- $upload->allowExts = $ext_arr; // 设置附件上传类型
- $upload->savePath = './static/upload/'; // 设置附件上传目录
- $backinfo = $upload->uploadmore();
- if (!$backinfo) {// 上传错误提示错误信息
- return array('code' => 0, 'message' => $upload->getErrorMsg());
- } else {
- // 上传成功 获取上传文件信息
- foreach ($backinfo as $info) {
- $photo = $info['savename'];
- if (!empty($photo)) {
- $filed['message_id'] = $message_id;
- $filed['title'] = $info['name'];
- $filed['filename'] = $photo;
- $filed['filesize'] = getfileSize('.' . $photo);
- $filed['ext'] = strtoupper(getext($photo));
- $filed['add_time'] = time();
- Db::name('message_attachment')->insertGetId($filed);
- }
- }
- return $this->successResponse(lang('successfully_uploaded'));
- ///////////////
- }
- }
-
- /*
- * 获取附件列表
- */
- public function getAttachmentList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $message_id = input('message_id');
- $where['message_id'] = $message_id;
- $list = Db::name('message_attachment')->field('id,title,filename,filesize,ext')->where($where)->withAttr('filesize', function ($value) {
- return getsizebytype($value);
- })->order('id asc')->select()->toArray();///
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 删除消息
- */
- public function deleteMessage() {
- // 启动事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- throw new Exception(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('message')->field('id')->where($condition)->find();
- if (!$info) {
- throw new Exception(lang('delete_failed'));
- }
- $where['message_id'] = $id;
- $attachmentList = Db::name('message_attachment')->field('id,filename')->where($where)->select()->toArray();
- if ($attachmentList) {
- foreach ($attachmentList as $k => $v) {
- delpic($v['filename']);
- }
- Db::name('message_attachment')->where($where)->delete();//删除消息附件
- }
- Db::name('message')->where('id', $id)->delete();//删除消息
- ////执行成功,提交事务
- Db::commit();
- return $this->successResponse(lang('delete_successful'));
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
- /*
- * 删除消息附件
- */
- public function deleteAttachment() {
- // 启动事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
-
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- throw new Exception(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('message_attachment')->field('id,filename')->where($condition)->find();
- if (!$info) {
- throw new Exception(lang('delete_failed'));
- }
- Db::name('message_attachment')->where('id', $id)->delete();//删除消息附件
- delpic($info['filename']);
- ////执行成功,提交事务
- Db::commit();
- return $this->successResponse(lang('delete_successful'));
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
- /*
- * 获取消息类别列表
- */
- public function getMsgCategoryList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $message_id = input('message_id');
- $where['ifshow'] = 1;
- $list = Db::name('msg_category')->field('id,title,father_id')->where($where)->order('order_id asc,id asc')->select()->toArray();///
- if ($list) {
-
- $result['list'] = datalist($list, 'father_id','',true);
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
-}
diff --git a/app/admin/controller/MsgCategory.php b/app/admin/controller/MsgCategory.php
deleted file mode 100644
index ea80a0b..0000000
--- a/app/admin/controller/MsgCategory.php
+++ /dev/null
@@ -1,131 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-class MsgCategory extends Common {
-
- private $viewPath = 'msgCategory';
- /**
- * 消息分类列表
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '消息类别';
- $guide['one']['text'] = '消息中心';
- $guide['two']['text'] = '消息类别';
- View::assign('guide', $guide);
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch('index');
- } else {
- $order = 'order_id asc,id asc';
- $list = Db::name('msg_category')->field("id,title,ifshow,father_id,order_id")->order($order)->select()->toArray();
- $list = _generateListTree($list, 0, ['id', 'father_id']);;
- $result['list'] = $list;
- return $this->successResponse($result);
- }
- }
-
- /**
- * 更新消息分类显示状态
- */
- public function updateShowCate() {
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse('参数错误');
- }
- $ifshow = input('ifshow');
- $info = Db::name('msg_category')->field('id')->where('id', $id)->find();
- if (empty($info)) {
- return $this->errorResponse('信息不存在');
- }
- if ($ifshow == '1') {
- $data['ifshow'] = 1;
- } else {
- $data['ifshow'] = 0;
- }
- $backval = Db::name('msg_category')->where('id', $id)->save($data);
- if ($backval === FALSE) {
- return $this->errorResponse('更新失败');
- } else {
- $this->delCache();
- return $this->successResponse('更新成功');
- }
- }
-
- /**
- * 保存消息分类
- * @return array|int[]
- */
- public function saveCate() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- $id = input('id');
- $data = Request::post();
- $id = $data['id'];
- if (is_numeric($id)) {
- //更新数据
- $validate = new \app\admin\validate\MsgCategory();
- $result = $validate->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////保存////////////
- Db::name('msg_category')->where('id', $id)->withoutField('id')->save($data);
- ////////////////////////
- $this->delCache();
- $res['message'] = '消息分类编辑成功';
- return $this->successResponse($res);
- } else {
- unset($data['id']);
- $validate = new \app\admin\validate\MsgCategory();
- $result = $validate->check($data);
- if (!$result) {
- return $this->errorResponse($validate->getError());
- }
- //////////////////////
- Db::startTrans();
- try {
- $data['add_time'] = time();
- $data['ifshow'] = 1;//默认显示
- $new_id = Db::name('msg_category')->insertGetId($data);
- if ($new_id) {
- Db::name('msg_category')->where('id', $new_id)->save(['order_id' => $new_id]);
- ///////执行成功,提交事务///////
- Db::commit();
- $this->delCache();
- $res['message'] = '消息分类添加成功';
- return $this->successResponse($res);
- } else {
- //任一执行失败,执行回滚操作
- Db::rollback();
- return $this->errorResponse('消息分类添加失败');
- }
- } catch (\Exception $e) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse('消息分类添加失败');
- }
- }
- }
-
- /**
- * 清除缓存
- * @return void
- */
- private function delCache() {
- Cache::tag('msg_category')->clear();
- }
-
-}
diff --git a/app/admin/controller/Notice.php b/app/admin/controller/Notice.php
deleted file mode 100644
index f6a0137..0000000
--- a/app/admin/controller/Notice.php
+++ /dev/null
@@ -1,297 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-//商品零售价限制
-
-class Notice extends Common {
-
- /**
- * 公告管理
- * @return string
- */
- public function index() {
- ////////
- return View::fetch();
- }
- /*
- * 获取公告列表
- */
- public function getNoticeList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $condition = [];
- $kw = input('kw');
- if ($kw) {
- $condition[] = ['title', 'like', '%' . $kw . '%'];
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'id asc';
- $count = Db::name('notice')->where($condition)->count();
- $list = Db::name('notice')
- ->field("*")->where($condition)->order($order)->withAttr('publish_time', function ($value) {
- return date('Y-m-d H:i:s', $value);
- })->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if ($list) {
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 创建公告
- */
- public function create() {
- ////////
- View::assign('menuitem', 'notice-index');
- $id = input('id');
- $other['id'] = $id;
- View::assign('other', $other);
- return View::fetch();
- }
-
- public function getNoticeDetail() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('notice_id');
- if (!$id) {
- throw new Exception(lang('param_error'));
- }
- $info = \app\seller\model\Notice::field("*")->where('id', $id)->withAttr('publish_time', function ($value) {return date('Y-m-d H:i:s', $value);})->find();
- if ($info) {
- $result['info']=$info;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 更新公告状态
- */
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'id,status';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name('notice')->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- }
- catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 保存公告信息
- */
- public function saveNotice() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
-
- $data = Request::post();
- $validate = new \app\admin\validate\Notice();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new Exception($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- $data['publish_time'] = strtotime($data['publish_time']);
- $data['update_time'] = time();
- Db::name('notice')->where('id', $id)->update($data);//更新数据
- // 提交事务
- Db::commit();
- $result['id'] = $id;
- $result['message'] = lang('successfully_saved');
- return $this->successResponse($result);
- } else {
- unset($data['id']);
- $data['publish_time'] = strtotime($data['publish_time']);
- $data['add_time'] = time();
- $data['update_time'] = time();
- $newid = Db::name('notice')->insertGetId($data);
- Db::commit();
- $result['id'] = $newid;
- $result['message'] = lang('successfully_saved');
- return $this->successResponse($result);
- }
- } catch (\Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 上传附件
- */
- public function uploadAttachment() {
- $notice_id = input('notice_id');
- $ext_arr = array(
- 'image' => array('gif', 'jpg', 'jpeg', 'bmp', 'png'),
- 'files' => array('doc', 'docx', 'xls', 'xlsx', 'pptx', 'ppt', 'pdf'),
- );
- $maxSizeArr = array(
- 'image' => 1024 * 1024 * 10,
- 'files' => 1024 * 1024 * 250,
- );
-
- $upload = new \common\UploadFile(); // 实例化上传类
- $upload->uploadReplace = TRUE; //同名文件自动覆盖
- $upload->autoSub = TRUE; // 启用子目录保存文件
- $upload->subType = 'date'; // 子目录创建方式 可以使用hash date custom
- $upload->dateFormat = 'Y/m/d'; //定义 subType=date 后,才需要定义dateFormat
- $upload->maxSize = 1024 * 1024 * 0; // 设置附件上传大小 10M
- $upload->maxSizeArr = $maxSizeArr; // 设置附件上传大小 10M
- $upload->allowExts = $ext_arr; // 设置附件上传类型
- $upload->savePath = './static/upload/'; // 设置附件上传目录
- $backinfo = $upload->uploadmore();
- if (!$backinfo) {// 上传错误提示错误信息
- return array('code' => 0, 'message' => $upload->getErrorMsg());
- } else {
- // 上传成功 获取上传文件信息
- foreach ($backinfo as $info) {
- $photo = $info['savename'];
- if (!empty($photo)) {
- $filed['notice_id'] = $notice_id;
- $filed['title'] = $info['name'];
- $filed['filename'] = $photo;
- $filed['filesize'] = getfileSize('.' . $photo);
- $filed['ext'] = strtoupper(getext($photo));
- $filed['add_time'] = time();
- Db::name('notice_attachment')->insertGetId($filed);
- }
- }
- return $this->successResponse(lang('successfully_uploaded'));
- ///////////////
- }
- }
-
- /*
- * 获取附件列表
- */
- public function getAttachmentList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $notice_id = input('notice_id');
- $where['notice_id'] = $notice_id;
- $list = Db::name('notice_attachment')->field('id,title,filename,filesize,ext')->where($where)->withAttr('filesize', function ($value) {
- return getsizebytype($value);
- })->order('id asc')->select()->toArray();///
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 删除公告
- */
- public function deleteNotice() {
- // 启动事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- throw new Exception(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('notice')->field('id')->where($condition)->find();
- if (!$info) {
- throw new Exception(lang('delete_failed'));
- }
- $where['notice_id'] = $id;
- $attachmentList = Db::name('notice_attachment')->field('id,filename')->where($where)->select()->toArray();
- if ($attachmentList) {
- foreach ($attachmentList as $k => $v) {
- delpic($v['filename']);
- }
- Db::name('notice_attachment')->where($where)->delete();//删除公告附件
- }
- Db::name('notice')->where('id', $id)->delete();//删除公告
- ////执行成功,提交事务
- Db::commit();
- return $this->successResponse(lang('delete_successful'));
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
- /*
- * 删除公告附件
- */
- public function deleteAttachment() {
- // 启动事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
-
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- throw new Exception(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('notice_attachment')->field('id,filename')->where($condition)->find();
- if (!$info) {
- throw new Exception(lang('delete_failed'));
- }
- Db::name('notice_attachment')->where('id', $id)->delete();//删除公告附件
- delpic($info['filename']);
- ////执行成功,提交事务
- Db::commit();
- return $this->successResponse(lang('delete_successful'));
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
-
-
-}
diff --git a/app/admin/controller/PartnerSchool.php b/app/admin/controller/PartnerSchool.php
deleted file mode 100644
index 2700b20..0000000
--- a/app/admin/controller/PartnerSchool.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\PartnerSchool as PartnerSchoolValidate;
-
-class PartnerSchool extends Common {
-
- /**
- * 分销平台列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('school_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('partner_school')->where($condition)->count();
- $list = Db::name('partner_school')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存分销平台
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new PartnerSchoolValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new Exception($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('partner_school')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- throw new Exception(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('partner_school')->insertGetId($data);
- if (!$add_result) {
- throw new Exception(lang('adding_failed'));
- }
- Db::name('partner_school')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除分销平台
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('partner_school')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('partner_school')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/PayBank.php b/app/admin/controller/PayBank.php
deleted file mode 100644
index 0249af6..0000000
--- a/app/admin/controller/PayBank.php
+++ /dev/null
@@ -1,213 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-class PayBank extends Common {
- private $tableName = 'pay_bank';
- private $viewPath = 'payBank';
-
- /**
- * 货运属性列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '收款账户管理';
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('payee_name|account_name|account', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name($this->tableName)->where($condition)->count();
- $list = Db::name($this->tableName)->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'id,isoffline,isonline';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name($this->tableName)->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- public function uploadLogo() {
-
- $img_url = input('img_url');
- $id = input('id');
-
- $ext_arr = array(
- 'image' => array('jpg', 'jpeg', 'png'),
- );
- $maxSizeArr = array(
- 'image' => 1024 * 1024 * 10,
- );
- $bannersize = Config::get('app.BANNER_SIZE');
- $width = $bannersize['suolue']['w'];
- $height = $bannersize['suolue']['h'];
- $ratio = $bannersize['suolue']['r'];
-
- $upload = new \common\UploadFile(); // 实例化上传类
- $upload->uploadReplace = TRUE; //同名文件自动覆盖
- $upload->autoSub = TRUE; // 启用子目录保存文件
- $upload->subType = 'date'; // 子目录创建方式 可以使用hash date custom
- $upload->dateFormat = 'Y/m/d'; //定义 subType=date 后,才需要定义dateFormat
- $upload->maxSize = 1024 * 1024 * 0; // 设置附件上传大小 10M
- $upload->maxSizeArr = $maxSizeArr; // 设置附件上传大小 10M
- $upload->allowExts = $ext_arr; // 设置附件上传类型
- $upload->savePath = './static/upload/'; // 设置附件上传目录
- $upload->ratio = $ratio; //1:按比例缩放,2:裁切固定值大小
-
- $upload->thumb = FALSE; // 使用对上传图片进行缩略图处理
- //$upload->imageClassPath='LIB.Util.Image'; // 图库类包路径 用于生成缩略图
- $upload->thumbMaxWidth = $width; // 缩略图最大宽度
- $upload->thumbMaxHeight = $height; // 缩略图最大高度
- $upload->thumbRemoveOrigin = FALSE; // 是否移除原图 移除原图时,必须给 thumbPrefix指定一个前缀,否则会将原图误删除
-
-
- $backinfo = $upload->uploadmore();
- if (!$backinfo) {// 上传错误提示错误信息
- return $this->errorResponse($upload->getErrorMsg());
- } else {
- $update_info = $upload->getUploadFileInfo();
- $photo = $update_info['savename'];
- if (is_numeric($id) && $id > 0) {
- $info = Db::name($this->tableName)->field('img_url')->where('id', $id)->find();
- if($info){
- if($info['img_url']){
- delpic($info['img_url']);
- }
- $update_data['img_url'] = $photo;
- Db::name($this->tableName)->where('id', $id)->update($update_data);//更新数据
- }
- else{
- //数据不存在视为新增数据,删除旧图片
- if ($img_url) {
- delpic($img_url);
- }
- }
- } else {
- //新增数据,删除旧图片
- if ($img_url) {
- delpic($img_url);
- }
- }
- // 上传成功 获取上传文件信息
- //上传可同时上传多个,上传方式为一次上传多个
- $result['img_url'] = $photo;
- $result['message'] = lang('successfully_uploaded');
- return $this->successResponse($result);
- }
- }
-
- /**
- *保存货运属性
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate=new \app\admin\validate\PayBank();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name($this->tableName)->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name($this->tableName)->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name($this->tableName)->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除货运属性
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name($this->tableName)->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name($this->tableName)->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/PaymentTool.php b/app/admin/controller/PaymentTool.php
deleted file mode 100644
index 52f35bf..0000000
--- a/app/admin/controller/PaymentTool.php
+++ /dev/null
@@ -1,155 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-
-class PaymentTool extends Common {
- private $tableName = 'payment_tool';
- private $viewPath = 'payment_tool';
- /**
- * 分销区域列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '收款工具管理';
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('payment_tool_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,payment_tool_id asc';
- $count = Db::name($this->tableName)->where($condition)->count();
- $list = Db::name($this->tableName)->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存分销区域
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new \app\admin\validate\paymentTool();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $payment_tool_id = input('post.payment_tool_id');
- if (is_numeric($payment_tool_id)) {
- //更新数据
- $update_result = Db::name($this->tableName)->where('payment_tool_id', $payment_tool_id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['payment_tool_id']);
- $add_result = Db::name($this->tableName)->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name($this->tableName)->where('payment_tool_id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'payment_tool_id,is_show';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['payment_tool_id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name($this->tableName)->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除分销区域
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $payment_tool_id = input('payment_tool_id');
- if (!is_numeric($payment_tool_id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['payment_tool_id'] = $payment_tool_id;
- $info = Db::name($this->tableName)->field('payment_tool_id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name($this->tableName)->where('payment_tool_id', $payment_tool_id)->delete();
- //提交事务
- Db::commit();
- $this->delCache();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 清除缓存
- * @return void
- */
- private function delCache() {
- Cache::tag('payment_tool')->clear();
- }
-
-}
diff --git a/app/admin/controller/PlatformLogisticsProduct.php b/app/admin/controller/PlatformLogisticsProduct.php
deleted file mode 100644
index d62973f..0000000
--- a/app/admin/controller/PlatformLogisticsProduct.php
+++ /dev/null
@@ -1,123 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\PlatformLogisticsProduct as PlatformLogisticsProductValidate;
-
-class PlatformLogisticsProduct extends Common {
-
- /**
- * 货运属性列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('attr_name|attr_code', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('platform_logistics_product')->where($condition)->count();
- $list = Db::name('platform_logistics_product')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存货运属性
- */
- public function save() {
-
- //开始事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- $validate = new PlatformLogisticsProductValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new Exception($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('platform_logistics_product')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- throw new Exception(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('platform_logistics_product')->insertGetId($data);
- if (!$add_result) {
- throw new Exception(lang('add_failed'));
- }
- Db::name('platform_logistics_product')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除货运属性
- * @return array|int[]
- */
- public function delete() {
-
- //开始事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- throw new Exception(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('platform_logistics_product')->field('id')->where($condition)->find();
- if (!$info) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name('platform_logistics_product')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/PlatformRegion.php b/app/admin/controller/PlatformRegion.php
deleted file mode 100644
index 2627651..0000000
--- a/app/admin/controller/PlatformRegion.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\PlatformRegion as PlatformRegionValidate;
-
-class PlatformRegion extends Common {
-
- /**
- * 销售平台列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('region_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('platform_region')->where($condition)->count();
- $list = Db::name('platform_region')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存销售平台
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new PlatformRegionValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('platform_region')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('platform_region')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('platform_region')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除销售平台
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('platform_region')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('platform_region')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/PublicApi.php b/app/admin/controller/PublicApi.php
deleted file mode 100644
index 9ddf565..0000000
--- a/app/admin/controller/PublicApi.php
+++ /dev/null
@@ -1,99 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\View;
-use think\facade\Request;
-use think\facade\Config;
-use think\facade\Db;
-
-class PublicApi extends Common {
-
- private $categoryService;
- private $deliverRegionService;
- private $logisticsProductService;
- private $platformLogisticsProductService;
-
- public function __construct() {
-// parent::__construct();
- $this->categoryService = new \services\CategoryService();
- $this->deliverRegionService = new \services\DeliverRegionService();
- $this->logisticsProductService = new \services\LogisticsProductService();
- $this->platformLogisticsProductService = new \services\PlatformLogisticsProductService();
- }
-
- public function categoryList(){
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $where = [];
- if (Request::has('pid','post')) {
- $pid = trim(input('pid'));
-// if (!is_numeric($pid)) {
-// throw new Exception('参数错误!', 400);
-// }
- $where[] = ['father_code', '=', $pid];
- }
- if (Request::has('keyWord','post')) {
- $where[] = ['cate_name', 'like', '%'.trim(input('keyWord')).'%'];
- }
- $categorys = [];
- $categorys['list'] = $this->categoryService->getList($where);
- return $this->successResponse($categorys);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- public function deliverRegionList(){
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $where = [];
- $data = [];
- $data['list'] = $this->deliverRegionService->getList($where);
- $data['list'] = datalist($data['list'], 'deliver_region_id', '', FALSE);
- return $this->successResponse($data);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- public function logisticsProductList(){
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $where = [];
- $data = [];
- $data['list'] = $this->logisticsProductService->getList($where);
- $data['list'] = datalist($data['list'], 'id', '', FALSE);
- return $this->successResponse($data);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- public function platformLogisticsProductList(){
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $where = [];
- $data = [];
- $data['list'] = $this->platformLogisticsProductService->getList($where);
- $data['list'] = datalist($data['list'], 'id', '', FALSE);
- return $this->successResponse($data);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/PublishOrder.php b/app/admin/controller/PublishOrder.php
deleted file mode 100644
index da816c4..0000000
--- a/app/admin/controller/PublishOrder.php
+++ /dev/null
@@ -1,626 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\supplier\model\DistributionArea as DistributionAreaModel;
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\supplier\model\GoodsAnnex;
-use app\supplier\model\GoodsSpec;
-use app\supplier\model\GoodsAttribute;
-use app\supplier\model\GoodsLabel;
-use app\supplier\model\GoodsRetailPriceLimit;
-
-//use app\supplier\model\Goods;
-
-//商品零售价限制
-
-class publishOrder extends Common {
-
- /**
- * 商品管理
- * @return string
- */
- public function index() {
- return View::fetch();
- }
-
- /**
- * 获取刊登列表
- * @return mixed
- */
- public function getPublishOrder() {
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $platform_goods_code = input('platform_goods_code');
- $supplier_goods_code = input('supplier_goods_code');
- $condition['istemp'] = 1;//编辑过的商品
- $condition['audit_status'] = 2;
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'id asc';
- $count = \app\supplier\model\PublishOrder::where($condition)->count();
- $list = \app\supplier\model\PublishOrder::field("id,supplier_goods_code,publish_order_code,first_cate_code,second_cate_code,three_cate_code,public_type,brand_code,add_time,audit_status,publish_status,update_time,goods_title_cn,review_comments,(select url from web_publish_order_picture where publish_order_id=web_publish_order.id order by id asc limit 1) as picture")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- throw new \Exception(lang('no_data_found'));
- }
- $categorylist = get_category();
- $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
- foreach ($list as &$item) {
- $item['first_cate_name'] = $categorylist[$item['first_cate_code']]['cate_name'];
- $item['second_cate_name'] = $categorylist[$item['second_cate_code']]['cate_name'];
- $item['three_cate_name'] = $categorylist[$item['three_cate_code']]['cate_name'];
- $item['add_time'] = date('Y-m-d H:i:s', $item['add_time']);
- }
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
-
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 审核商品刊登
- * @return array|int[]
- */
- public function reviewPublishOrder() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $id = input('post.id');
- if (!is_numeric($id)) {
- throw new \Exception(lang('invalid_id'));
- }
- $status = input('post.status');
- //更新数据
- $info = Db::name('publish_order')->field('id,publish_status,audit_status,supplier_goods_code')->where('id', $id)->find();
- if (!$info) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- if ($status == 1) {
- Db::name('publish_order')->where('id', $id)->update(['publish_status' => 1, 'audit_status' => 1, 'review_comments' => '']);
- Db::name('goods')->where('supplier_goods_code', $info['supplier_goods_code'])->update(['kd_publish_status' => 1]);//设置为已刊登
- $message = '操作成功,审核通过';
- } else {
- $review_comments = trim(input('review_comments'));
- if (!$review_comments) {
- throw new \Exception('请填写审核不通过原因');
- }
- Db::name('publish_order')->where('id', $id)->update(['publish_status' => 0, 'audit_status' => 3, 'review_comments' => $review_comments]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
- } catch (\Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 创建商品
- * @return string
- */
- public function create() {
- ////////
- $id = input('id');
- if (!is_numeric($id)) {
- $this->redirect(url('/supplier/publishOrder/index')->build());
- }
- $other['id'] = $id;
- View::assign('other', $other);
- return View::fetch();
- }
-
- public function getGoodsInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $supplier_goods_code = input('supplier_goods_code');
- $where = [
- 'supplier_goods_code' => $supplier_goods_code,
- ];
- $info = Db::name('goods')->field('id,first_cate_code,second_cate_code,three_cate_code,brand_code')->where($where)->find();
- if ($info['three_cate_code']) {
- $info['cate_code'] = [$info['first_cate_code'], $info['second_cate_code'], $info['three_cate_code']];
- }
- $info['goods_purpose'] = json_decode($info['goods_purpose'], TRUE);
- //////获取描述标题数据/////////
- $where_other = [
- 'goods_id' => $info['id'],
- ];
- $goods_desc = Db::name('goods_desc')->field('goods_title_en,goods_title_cn')->where($where_other)->find();
- //获取描述内容数据
- $goods_desc_content = Db::name('goods_desc_content')->field('goods_desc_en,goods_desc_cn')->where($where_other)->find();
-
- ////////////////
- $result['info'] = $info;
- $result['goods_desc'] = $goods_desc;
- $result['goods_desc_content'] = $goods_desc_content;
- return $this->successResponse($result);
- } catch (\Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 获取商品分销信息
- * @return array|int[]
- */
- public function getGoodsDisInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $supplier_goods_code = input('supplier_goods_code');
-
- $condition['g.istemp'] = 1;//编辑过的商品
- if ($supplier_goods_code) {
- $condition['g.supplier_goods_code'] = $supplier_goods_code;
- }
-
- $info = \app\supplier\model\Goods::alias('g')
- ->join('goods_desc gd', 'g.id=gd.goods_id')
- ->join('goods_desc_content gdc', 'g.id=gdc.goods_id')
- ->field("g.id,g.warehouse_mode,g.sales_form,g.supplier_goods_code,g.platform_goods_code,g.goods_purpose,g.add_time,g.status,g.publish_status,g.whether_dis,g.is_limit_dis_platform,gd.goods_title_cn,gd.goods_title_en,gd.goods_keyword_en,gd.goods_keyword_cn,g.first_cate_code,g.second_cate_code,g.three_cate_code,g.docking_way,g.price_method,g.freight_attr_code,g.is_tort,g.is_stop_buy,g.recommend_man,gdc.goods_desc_en,gdc.goods_desc_cn")->where($condition)->find();
- if ($info) {
- $categorylist = get_category();
- $categorylist = datalist($categorylist, 'cate_code', '', FALSE);
- $info['first_cate_name'] = $categorylist[$info['first_cate_code']]['cate_name'];
- $info['second_cate_name'] = $categorylist[$info['second_cate_code']]['cate_name'];
- $info['three_cate_name'] = $categorylist[$info['three_cate_code']]['cate_name'];
- $info['attr_name'] = Db::name('goods_freight_attr')->where('attr_code', $info['freight_attr_code'])->value('attr_name');
- $info['goods_keyword_en'] = $info['goods_keyword_en'] ? json_decode($info['goods_keyword_en'], TRUE) : [];
- $info['goods_keyword_cn'] = $info['goods_keyword_cn'] ? json_decode($info['goods_keyword_cn'], TRUE) : [];
-
- $info['goodsSpecInfo'] = Db::name('goods_spec')->field('*')->where('goods_id', $info['id'])->find();
- $goods_attribute_info = Db::name('goods_attribute')->field('*')
- ->withAttr('material_main', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_one', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_two', function ($value, $data) {
- return Db::name('goods_material')->where('id', $value)->value('material_name');
- })
- ->withAttr('material_three', function ($value, $data) {
- if ($value) {
- $value = json_decode($value, TRUE);
- return Db::name('goods_material')->whereIn('id', $value)->column('material_name');
- } else {
- return [];
- }
- })
- ->where('goods_id', $info['id'])->find();
- $info['goodsAttributeInfo'] = $goods_attribute_info;
- $info['goodsAttributExtendList'] = Db::name('goods_attribute_extend')->field('*')->where('goods_id', $info['id'])->select()->toArray();
-
- $info['goodsRetailPriceLimitList'] = GoodsRetailPriceLimit::field('*')->where('goods_id', $info['id'])
- ->withAttr('sale_country_code', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value("CONCAT(country_code,' ',country)");
- })
- ->withAttr('sales_platform', function ($value, $data) {
- return Db::name('sales_platform')->where('id', $value)->value("platform_name");
- })
- ->order('id asc')->select()->toArray();///
- $info['goodsLabelList'] = GoodsLabel::field('label_type,goods_label')->where('goods_id', $info['id'])->order('id asc')->select()->toArray();///
- if ($info['is_limit_dis_platform'] == 1) {
- $info['goodsLimitDisPlatformList'] = Db::name('goods_limit_dis_platform')
- ->alias('a')
- ->join('dis_platform b', 'a.dis_platform = b.id')
- ->field('b.platform_name')->where('goods_id', $info['id'])->order('a.id asc')->select()->toArray();///
- } else {
- $info['goodsLimitDisPlatformList'] = [];
- }
- $result['info'] = $info;
- ///分销区域//
- $disAreaList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('distribution_area da', 'da.id=gda.distribution_area_id')
- ->field("gda.one_shipment,gda.distribution_area_id")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)->withAttr('one_shipment', function ($value, $data) {
- return $value == 1 ? '一件代发' : '';
- })->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disAreaList'] = $disAreaList;
- //分销库存
- $disStockList = Db::name('goods_distribution_area_stock')
- ->alias('gdas')
- ->join('third_party_stock tps', 'tps.id=gdas.third_party_stock_id')
- ->field("gdas.distribution_area_id,gdas.supplier_stock_amount,gdas.platform_stock_amount,gdas.goods_distribution_area_id,tps.third_party_stock_name,tps.docking_code,tps.stock_type")->where('gdas.goods_id', $info['id'])->where('gdas.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })->select()->toArray();
- $result['disStockList'] = $disStockList;
- //分销价格///
- $disPriceList = Db::name('goods_distribution_area_price')
- ->alias('gdap')
- ->join('goods_distribution_area gda', 'gda.id=gdap.goods_distribution_area_id')
- ->join('logistics_product lp', 'lp.id=gdap.logistics_product_id')
- ->field("gdap.distribution_area_id,gdap.goods_distribution_area_id,lp.product_name_cn,gdap.supply_price,gdap.dis_price,gdap.package_goods_amount,gda.take_effect_time")->where('gdap.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('take_effect_time', function ($value, $data) {
- return date('Y-m-d H:i:s', $value);
- })->select()->toArray();
- $result['disPriceList'] = $disPriceList;
- //退货地址列表//
- $disReturnGoodsList = Db::name('goods_distribution_area')
- ->alias('gda')
- ->join('third_party_stock tps', 'tps.id=gda.third_party_stock_id')
- ->join('third_party_stock_address tpsa', 'tpsa.id=gda.third_party_stock_address_id')
- ->field("gda.distribution_area_id,tps.third_party_stock_name,tpsa.stock_address,tpsa.stock_city,tpsa.stock_province,tpsa.stock_post_code,tpsa.stock_country_id,tpsa.receive_man,tpsa.tel")->where('gda.goods_id', $info['id'])->where('gda.whether_dis', 1)
- ->withAttr('distribution_area_id', function ($value, $data) {
- return $this->getDisArea($value);
- })
- ->withAttr('stock_country_id', function ($value, $data) {
- return Db::name('stock_country')->where('id', $value)->value('country');
- })
- ->select()->toArray();
- $result['disReturnGoodsList'] = $disReturnGoodsList;
-
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取商品图片列表
- * @return array|int[]
- */
- public function getGoodsPictureList() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $goods_id = input('goods_id');
- $picture_type = input('picture_type');
-
- if (is_array($picture_type)) {
- $where[] = ['a.goods_id', '=', $goods_id];
- if (is_array($picture_type)) {
- $where[] = ['b.type', 'in', $picture_type];
- }
- $list = Db::name('goods_picture')
- ->alias('a')
- ->join('goods_picture_type b', 'a.id=b.picture_id')
- ->field('DISTINCT a.id,a.url')->where($where)->order('id asc')->select()->toArray();
- } else {
- $where[] = ['goods_id', '=', $goods_id];
- $list = Db::name('goods_picture')->field('id,url')->where($where)->order('id asc')->select()->toArray();
- }
- if (!$list) {
- return $this->errorResponse(lang('no_data_found'));
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 根据类型获取商品图片数量
- * @return void
- */
- public function getGoodsPictureCount() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $goods_id = input('goods_id');
- $goodsPictureCount['type0'] = Db::name('goods_picture')->where(['goods_id' => $goods_id])->count();
- $goodsPictureCount['type1'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 1])->count();
- $goodsPictureCount['type2'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 2])->count();
- $goodsPictureCount['type3'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 3])->count();
- $goodsPictureCount['type4'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 4])->count();
- $goodsPictureCount['type5'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 5])->count();
- $goodsPictureCount['type6'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 6])->count();
- $goodsPictureCount['type7'] = Db::name('goods_picture_type')->where(['goods_id' => $goods_id, 'type' => 7])->count();
- $result['goodsPictureCount'] = $goodsPictureCount;
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取分销区域
- */
- private function getDisArea($id) {
- return Db::name('distribution_area')
- ->alias('da')
- ->join('deliver_region dr', 'dr.deliver_region_id=da.deliver_region_id')
- ->field("da.dis_currency,dr.region_name,da.dis_model")
- ->where('da.id', $id)->find();
- }
-
- /**
- * 获取刊登信息
- * @return array|int[]
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\DbException
- * @throws \think\db\exception\ModelNotFoundException
- */
- public function getPublishOrderInfo() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- throw new \Exception(lang('invalid_id'));
- }
- $where = [
- 'id' => $id,
- ];
- $info = Db::name('publish_order')->field('*')->where($where)->find();
- if ($info['three_cate_code']) {
- $info['cate_code'] = [$info['first_cate_code'], $info['second_cate_code'], $info['three_cate_code']];
- }
- //////获取描述标题数据/////////
- $where_other = [
- 'publish_order_id' => $id,
- ];
- ////////////////
- $result['info'] = $info;
- return $this->successResponse($result);
- } catch (\Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 保存刊登信息
- * @return array
- */
- public function savePublishOrder() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
-
- $id = $data['id'];
- // 验证ID的合法性
- if (!is_numeric($id) || $id <= 0) {
- throw new \Exception(lang('invalid_id'));
- }
- // 数据验证
- $validate = new \app\supplier\validate\PublishOrder();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new \Exception($validate->getError());
- }
- /////////////////
- $img_count = Db::name('publish_order_picture')->where('publish_order_id', $id)->count();
- if ($img_count == 0) {
- throw new \Exception('请上传图片');
- }
-
- $data['update_time'] = time();
- $data['istemp'] = 1;
- $data['publish_status'] = 0;//未刊登
- $data['audit_status'] = 2;//提交待审核
-
- $where['id'] = $id;
- $update_result = Db::name('publish_order')->where($where)->withoutField('id,supplier_id,publish_order_code')->update($data);
- if ($update_result === FALSE) {
- throw new \Exception(lang('editing_failed'));
- }
- // 提交事务
- Db::commit();
- $result['url'] = url('/supplier/publishOrder/index')->build();
- $result['message'] = lang('successfully_saved');
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除刊登信息
- * @return array
- */
- public function deletePublishOrder() {
-
- // 启动事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- throw new \Exception(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('publish_order')->field('id,publish_status,audit_status')->where($condition)->find();
- if (!$info) {
- throw new \Exception(lang('delete_failed'));
- } else {
- if ($info['publish_status'] == 1) {
- throw new \Exception('刊登单已发布,不能删除');
- }
- }
- $del_result = Db::name('publish_order')->where('id', $id)->delete();
- if ($del_result) {
- ////执行成功,提交事务
- Db::commit();
- return $this->successResponse(lang('delete_successful'));
- } else {
- throw new \Exception(lang('delete_failed'));
- }
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
-
- /**
- * 上传商品图片
- * @return array|int[]
- */
-
- /**
- * 获取商品图片列表
- * @return array|int[]
- */
- public function getPublishOrderPictureList() {
-
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $publish_order_id = input('publish_order_id');
-
- $where[] = ['publish_order_id', '=', $publish_order_id];
- $list = Db::name('publish_order_picture')->field('id,url')->where($where)->order('id asc')->select()->toArray();
- if (!$list) {
- throw new \Exception(lang('no_data_found'));
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /**
- * 删除商品图片
- * @return array|int[]
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\DbException
- * @throws \think\db\exception\ModelNotFoundException
- */
- public function deletePublishOrderPicture() {
-
- // 启动事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!$id || !is_numeric($id)) {
- throw new \Exception(lang('invalid_id'));
- }
- $condition['id'] = $id;
- $info = Db::name('publish_order_picture')->field('id,publish_order_id,url')->where($condition)->find();
- if (!$info) {
- throw new \Exception(lang('delete_failed'));
- }
- $del_result = Db::name('publish_order_picture')->where('id', $id)->delete();
- ////执行成功,提交事务
- Db::commit();
- delpic($info['url']);
- return $this->successResponse(lang('delete_successful'));
- } catch (\Exception $exc) {
- //// 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
-
- /**
- * 获取分类列表
- * @return array
- */
- public function getCategoryList() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $result['list'] = $this->getchildrenids(0);
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 循环获取分类数据
- * @param $id
- * @return array|void
- * @throws \think\db\exception\DataNotFoundException
- * @throws \think\db\exception\DbException
- * @throws \think\db\exception\ModelNotFoundException
- */
- protected function getchildrenids($id) {
- $where['father_code'] = $id;
- $result = Db::name('category')->field('id,cate_code as value,cate_name as label')->where($where)->cacheAlways(TRUE, 0, 'category')->order('id asc')->select()->toArray();
- if ($result) {
- foreach ($result as &$val) {
- $val['children'] = $this->getchildrenids($val['value']); ////
- }
- return $result;
- }
- }
-
- /**
- * 商品发布
- * @return array|int[]
- */
- public function goodsPublish() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new \Exception(lang('request_method_incorrect'));
- }
- $publish_order_id = input('publish_order_id');
- $goods_info = Db::name('goods')->field('id')->where('id', $publish_order_id)->find();
- if (!$goods_info) {
- throw new \Exception(lang('goods_not_exist'));
- }
- $update_data = [
- 'publish_status' => 1,
- 'update_time' => time(),
- ];
- Db::name('goods')->where('id', $publish_order_id)->update($update_data);
- // 提交事务
- Db::commit();
- return $this->successResponse(lang('goods_publish_success'));
- } catch (\Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-}
diff --git a/app/admin/controller/RemitRecord.php b/app/admin/controller/RemitRecord.php
deleted file mode 100644
index 6e593df..0000000
--- a/app/admin/controller/RemitRecord.php
+++ /dev/null
@@ -1,132 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Db;
-use think\facade\Request;
-use think\facade\View;
-use think\Exception;
-
-class RemitRecord extends Common {
- /*
- * 品牌管理
- */
- public function index(): string {
- View::assign('menuitem', strtolower('remitRecord-index'));
- $other['title'] = '汇款审核';
- $guide['one']['text'] = '数据审核';
- $guide['two']['text'] = '汇款审核';
- View::assign('guide', $guide);
- View::assign('other', $other);
- return View::fetch('index');
- }
-
- /*
- */
- public function getRemitRecordList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $kw = input('kw');
-// $condition[] = ['SRR.status', '=', 0];
- $condition[]= ['SRR.remittor_name|SRR.remittor_account|SRR.remit_transaction_number', 'like', '%' . $kw . '%'];
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'SRR.id desc';
- $count = Db::name('seller_remit_record')
- ->alias('SRR')
- ->join('pay_bank PA', 'PA.id=SRR.pay_bank_id')
- ->where($condition)->count();
- $list = Db::name('seller_remit_record')
- ->alias('SRR')
- ->field("SRR.*,PA.payee_name")
- ->join('pay_bank PA', 'PA.id=SRR.pay_bank_id')
- ->where($condition)->order($order)->page($p, $other['page_size'])->withAttr('add_time', function ($value) {
- return date('Y-m-d H:i', $value);
- })
- ->withAttr('remit_date_time', function ($value) {
- return $value ? date('Y-m-d', $value) : '';
- })
- ->select()->toArray();
- $other['count'] = $count;
- $result['other'] = $other;
- if (!$list) {
- throw new Exception(lang('no_data_found'));
- } else {
- $result['list'] = $list;
- return $this->successResponse($result);
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /**
- * 汇款审核
- */
- public function reviewRemitRecord() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $record_id = input('post.record_id');
- if (!is_numeric($record_id)) {
- throw new Exception(lang('parameter_error'));
- }
- $status = input('post.status');
- //更新数据
- $info = Db::name('seller_remit_record')->field('id,status,asset_id,remit_amount,seller_id')->where('id', $record_id)->find();
- if (!$info) {
- throw new Exception(lang('no_data_found'));
- }
- if ($info['status'] == 1) {
- throw new Exception('该申请已审核通过,不能重复审核');
- }
- if ($status == 1) {
- $service_charge = input('post.service_charge');
- $remit_amount = $info['remit_amount'];
- if (!$service_charge || !is_numeric($service_charge)) {
- throw new Exception('请输入手续费');
- }
- $add_fee = $remit_amount - $service_charge;//实际收款金额:充值金额-手续费
- $asset_update['mnyall'] = Db::raw("mnyall+$add_fee");//入库总额
- $asset_update['mnyavl'] = Db::raw("mnyavl+$add_fee");//可用余额
- Db::name('seller_asset')->where('id', $info['asset_id'])->update($asset_update);
- $record_update = [
- 'status' => 1,
- 'service_charge'=> $service_charge,
- 'review_time' => time()//审核时间
- ];
- Db::name('seller_remit_record')->where('id', $record_id)->update($record_update);//更新状态
- $LogData = [
- 'amount' => $add_fee,
- 'type' => 1,//1增加,2减少
- 'remark' => '汇款确认',
- 'user_id' => $this->admin_id,
- 'seller_id' => $info['seller_id'],
- 'target_type' => 1,
- 'target_id' => $info['asset_id'],
-
- ];
- event('SellerBillLog', $LogData);//汇款确认入账日志
- $message = '操作成功,审核通过';
- } else {
- Db::name('seller_remit_record')->where('id', $record_id)->update(['status' => 2]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
-
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
\ No newline at end of file
diff --git a/app/admin/controller/ReturnExchange.php b/app/admin/controller/ReturnExchange.php
deleted file mode 100644
index 12c53be..0000000
--- a/app/admin/controller/ReturnExchange.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\ReturnExchange as ReturnExchangeValidate;
-
-class ReturnExchange extends Common {
-
- /**
- * 退换货类型列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('return_exchange')->where($condition)->count();
- $list = Db::name('return_exchange')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存退换货类型
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new ReturnExchangeValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('return_exchange')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('return_exchange')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('return_exchange')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除退换货类型
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('return_exchange')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('return_exchange')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/ReturnExchangeType.php b/app/admin/controller/ReturnExchangeType.php
deleted file mode 100644
index 0b7ac87..0000000
--- a/app/admin/controller/ReturnExchangeType.php
+++ /dev/null
@@ -1,114 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\ReturnExchangeType as ReturnExchangeTypeValidate;
-
-class ReturnExchangeType extends Common {
-
- /**
- * 退换货类型列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('return_exchange')->where($condition)->count();
- $list = Db::name('return_exchange')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- if (count($list) > 0) {
- $idAry = [];
- $typeIdList = [];
- foreach ($list as &$item) {
- array_push($idAry, $item['id']);
- }
- $typeWhere = [
- ['return_exchange_id', 'in', $idAry]
- ];
- $typeList = Db::name('return_exchange_type')->field("*")->where($condition)->select()->toArray();
- if (count($typeList) > 0) {
- $typeIdList = dataField($typeList, 'return_exchange_id', 'type', true);
- }
- foreach ($list as &$item) {
- $item['type'] = [];
- if (isset($typeIdList[$item['id']])) {
- $item['type'] = $typeIdList[$item['id']];
- }
- }
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存退换货类型分类
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new ReturnExchangeTypeValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $return_exchange_id = $data['return_exchange_id'];
- if (!is_numeric($return_exchange_id)) {
- return $this->errorResponse('id信息不正确');
- }
- $types = $data['type'];
- if (!is_array($types)) {
- return $this->errorResponse('类型不正确');
- }
- //删除原有类型分类
- Db::name('return_exchange_type')->where('return_exchange_id', $return_exchange_id)->delete();
- $returnExchangeTypes = [];
- foreach ($types as &$type) {
- $returnExchangeTypes[] = [
- 'return_exchange_id' => $return_exchange_id,
- 'type' => $type,
- ];
- }
-
-
- $update_result = Db::name('return_exchange_type')->insertAll($returnExchangeTypes);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('编辑成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/SalesPlatform.php b/app/admin/controller/SalesPlatform.php
deleted file mode 100644
index d15e453..0000000
--- a/app/admin/controller/SalesPlatform.php
+++ /dev/null
@@ -1,240 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Config;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\SalesPlatform as SalesPlatformValidate;
-
-class SalesPlatform extends Common {
-
- private $tableName = 'sales_platform';
- private $viewPath = 'salesPlatform';
- /**
- * 销售平台列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- View::assign('viewPath', $this->viewPath);
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('platform_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name($this->tableName)->where($condition)->count();
- $list = Db::name($this->tableName)->field("*")->where($condition)->withAttr('platform_region_id', function ($value) {
-// $info['goods_purpose'] = json_decode($info['goods_purpose'], TRUE);
- return json_decode($value, TRUE);
- })->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存销售平台
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new SalesPlatformValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- throw new Exception($validate->getError());
- }
- if ($data['platform_region_id']) {
- $data['platform_region_id'] = json_encode(array_map('intval', $data['platform_region_id']));////将数组中的值转为数字类型/////
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name($this->tableName)->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name($this->tableName)->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name($this->tableName)->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- function updateExt() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $postField = 'id,is_show';
- $data = Request::only(explode(',', $postField), 'post');
- if (!$data['id']) {
- throw new Exception(lang('parameter_error'));
- }
- Db::name($this->tableName)->update($data);
- $result['message'] = '操作成功';
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- public function uploadLogo() {
-
- $logo = input('logo');
- $id = input('id');
-
- $ext_arr = array(
- 'image' => array('jpg', 'jpeg', 'png'),
- );
- $maxSizeArr = array(
- 'image' => 1024 * 1024 * 10,
- );
- $bannersize = Config::get('app.BANNER_SIZE');
- $width = $bannersize['suolue']['w'];
- $height = $bannersize['suolue']['h'];
- $ratio = $bannersize['suolue']['r'];
-
- $upload = new \common\UploadFile(); // 实例化上传类
- $upload->uploadReplace = TRUE; //同名文件自动覆盖
- $upload->autoSub = TRUE; // 启用子目录保存文件
- $upload->subType = 'date'; // 子目录创建方式 可以使用hash date custom
- $upload->dateFormat = 'Y/m/d'; //定义 subType=date 后,才需要定义dateFormat
- $upload->maxSize = 1024 * 1024 * 0; // 设置附件上传大小 10M
- $upload->maxSizeArr = $maxSizeArr; // 设置附件上传大小 10M
- $upload->allowExts = $ext_arr; // 设置附件上传类型
- $upload->savePath = './static/upload/'; // 设置附件上传目录
- $upload->ratio = $ratio; //1:按比例缩放,2:裁切固定值大小
-
- $upload->thumb = FALSE; // 使用对上传图片进行缩略图处理
- //$upload->imageClassPath='LIB.Util.Image'; // 图库类包路径 用于生成缩略图
- $upload->thumbMaxWidth = $width; // 缩略图最大宽度
- $upload->thumbMaxHeight = $height; // 缩略图最大高度
- $upload->thumbRemoveOrigin = FALSE; // 是否移除原图 移除原图时,必须给 thumbPrefix指定一个前缀,否则会将原图误删除
-
-
- $backinfo = $upload->uploadmore();
- if (!$backinfo) {// 上传错误提示错误信息
- return $this->errorResponse($upload->getErrorMsg());
- } else {
- $update_info = $upload->getUploadFileInfo();
- $photo = $update_info['savename'];
- if (is_numeric($id) && $id > 0) {
- $info = Db::name($this->tableName)->field('logo')->where('id', $id)->find();
- if($info){
- if($info['logo']){
- delpic($info['logo']);
- }
- $update_data['logo'] = $photo;
- Db::name($this->tableName)->where('id', $id)->update($update_data);//更新数据
- $this->uploadFileToCos($photo);//上传到cos
- }
- else{
- //数据不存在视为新增数据,删除旧图片
- if ($logo) {
- delpic($logo);
- $this->deleteFileFromCos($logo);//从cos删除文件
- }
- }
- } else {
- //新增数据,删除旧图片
- if ($logo) {
- delpic($logo);
- $this->deleteFileFromCos($logo);//从cos删除文件
- }
- }
- // 上传成功 获取上传文件信息
- //上传可同时上传多个,上传方式为一次上传多个
- $result['logo'] = $photo;
- $result['message'] = lang('successfully_uploaded');
- return $this->successResponse($result);
- }
- }
-
- /**
- * 删除销售平台
- * @return array|int[]
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name($this->tableName)->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name($this->tableName)->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- public function getPlatformRegion() {
- ////////
- try {
- if(!Request::isPost()){
- throw new Exception(lang('request_method_incorrect'));
- }
- $list = Db::name('platform_region')->field("*")->order('order_id,id')->select()->toArray();
- if (!$list) {
- $list = [];
- }
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
-}
diff --git a/app/admin/controller/Seller.php b/app/admin/controller/Seller.php
deleted file mode 100644
index cb1bf2a..0000000
--- a/app/admin/controller/Seller.php
+++ /dev/null
@@ -1,313 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\admin\validate\SellerAccountAdd;
-use app\admin\validate\SellerAccountEdit;
-use think\db\exception\DataNotFoundException;
-use think\db\exception\DbException;
-use think\db\exception\ModelNotFoundException;
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-class Seller extends Common
-{
-
- public function index()
- {
- ////////
- View::assign('menuitem', strtolower('seller-index'));
-
- $other['title'] = '分销商';
- $guide['one']['text'] = '分销商管理';
- $guide['two']['text'] = '分销商列表';
- View::assign('guide', $guide);
-
-
- View::assign('other', $other);
- return View::fetch('index');
- }
-
- /**
- * @throws ModelNotFoundException
- * @throws DbException
- * @throws DataNotFoundException
- */
- public function seller_list()
- {
- if (Request::isPost()) {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('a.phone|b.company_name|b.certificate_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'a.id desc';
-
- $count = Db::name('seller_account')
- ->alias('a')->join('seller_base_info b', 'a.id = b.seller_id')
- ->where($condition)->count();
-
- $list = Db::name('seller_account')
- ->alias('a')
- ->leftJoin('seller_base_info b', 'a.id = b.seller_id')
- ->field("a.id,a.phone,b.id as seller_id,b.account_type,b.certificate_name,b.first_name,b.last_name,b.company_name,login_time,login_ip,a.end_time,a.start_time,a.sub_ban_access")
- ->where($condition)
- ->order($order)
- ->page($p, $other['page_size'])
- ->select()
- ->toArray();
-
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- } else {
- foreach ($list as &$item) {
- $item['endtime'] = date('Y-m-d', $item['end_time']);
- }
- }
- $other['admin_info'] = $this->cinfo;
- $d['code'] = 200;
- $d['list'] = $list;
- $d['other'] = $other;
- return $d;
- }
- }
-
- public function update_ban_access()
- {
- header('Content-Type:text/html;charset=utf-8');
- if (Request::isPost()) {
- $id = input('id');
- $sub_ban_access = input('sub_ban_access');
- $info = Db::name('seller_account')->where('id', $id)->find();
- if (!$info) {
- $d['code'] = 400;
- $d['message'] = '信息不存在';
- return $d;
- }
- if ($sub_ban_access == '1') {
- $dd['sub_ban_access'] = 1;
- $d['sub_ban_access'] = 1;
- $d['message'] = '允许登录';
- } else {
- $dd['sub_ban_access'] = 0;
- $d['sub_ban_access'] = 0;
- $d['message'] = '禁止登录';
- }
- $backval = Db::name('seller_account')->where('id', $id)->save($dd);
- if ($backval === FALSE) {
- $d['code'] = 400;
- } else {
- $d['code'] = 200;
- }
- } else {
- $d['code'] = 400;
- $d['message'] = '非法请求';
- }
- return $d;
- }
-
-
- /**
- * 分销商编辑页
- * @param int $id
- * @return string
- */
- public function add(int $id = 0): string
- {
- View::assign('menuitem', strtolower('seller-index'));
- if ($id && is_numeric($id)) {
- $other['title'] = '编辑分销商信息';
- } else {
- $other['title'] = '添加分销商信息';
- }
- $guide['one']['text'] = '分销商管理';
- $guide['two']['text'] = $other['title'];
-
- $other['id'] = $id;
- View::assign('guide', $guide);
- View::assign('other', $other);
- return View::fetch('add');
- }
-
- /**
- * 获取分销商详细信息
- * @return array
- */
- public function get_seller_info(): array
- {
- try {
- if (!Request::isPost()) {
- throw new Exception("请求方式有误");
- }
- $seller_id = input('id');
- if (!$seller_id || !is_numeric($seller_id)) {
- throw new Exception("参数有误");
- }
- $where = [
- 'a.id' => $seller_id
- ];
- $seller_info = Db::name('seller_account')->where('id', $seller_id)->find();
- if (!$seller_info) {
- throw new Exception("分销商信息有误");
- }
- unset($seller_info['password']);
- $base_info = Db::name('seller_base_info')->where('seller_id', $seller_id)->find();
- if (!$base_info) {
- $seller_info['base_info'] = [];
- } else {
-
-
- $base_info['main_area'] = $base_info['main_area'] ? array_map('intval', explode(',', $base_info['main_area'])) : [];
- $base_info['main_dis_platform'] = $base_info['main_dis_platform'] ? array_map('intval', explode(',', $base_info['main_dis_platform'])) : [];
- $cate_code = [];
- if ($base_info['country_id']) {
- $cate_code[] = $base_info['country_id'];
- }
- if ($base_info['province_id']) {
- $cate_code[] = $base_info['province_id'];
- }
- if ($base_info['city_id']) {
- $cate_code[] = $base_info['city_id'];
- }
- $base_info['cate_code'] = $cate_code;
-
- $seller_info['base_info'] = $base_info;
- }
- $seller_info['end_time'] = date("Y-m-d", $seller_info['end_time']);
-
- $result = [
- 'code' => 200,
- 'message' => "成功",
- 'data' => $seller_info
- ];
- } catch (Exception $exc) {
- $result = [
- 'code' => $exc->getCode(),
- 'message' => $exc->getMessage()
- ];
- }
- return $result;
- }
-
- /**
- * 保存分销商帐号
- * @return array
- */
- public function save_seller_info(): array
- {
- try {
- if (!Request::isPost()) {
- throw new Exception("请求方式有误");
- }
- $params = Request::param();
- $phone = trim($params['phone'] ?? '');
- if (!$phone) {
- throw new Exception("请填写分销商手机号");
- }
-
- $seller_id = $params['id'] ?? 0;
- $where = [];
- if ($seller_id) {
- $where[] = ['phone', '=', $phone];
- $where[] = ['id', '<>', $seller_id];
- /////更新/////
- $find = Db::name('seller_account')->where($where)->find();
- if ($find) {
- throw new Exception("该手机号已被其它分销商注册");
- }
- $seller_info = Db::name('seller_account')->where('id', $seller_id)->find();
- if (!$seller_info) {
- throw new Exception("分销商账号信息有误");
- }
- $add_data = [
- 'phone' => $phone,
- 'end_time' => strtotime($params['end_time']) + 86400 - 1,
- 'sub_ban_access' => $params['sub_ban_access'] ? 1 : 0,
- ];
- if ($params['password']) {
- $add_data['password'] = joinmd5($params['password']);
- }
- Db::name('seller_account')->where('id', $seller_id)->update($add_data);
- $jump_url = "";
- } else {
- if (!$params['password']) {
- throw new Exception("请填写分销商密码");
- }
- /////添加/////
- $where[] = ['phone', '=', trim($phone)];
- $seller_info = Db::name('seller_account')->where($where)->find();
- if ($seller_info) {
- throw new Exception("该手机号已被其它分销商注册");
- }
- $add_data = [
- 'phone' => $params['phone'],
- 'password' => joinmd5($params['password']),
- 'end_time' => strtotime($params['end_time']) + 86400 - 1,
- 'sub_ban_access' => $params['sub_ban_access'] ? 1 : 0,
- 'start_time' => time(),
- 'add_time' => time()
- ];
- $seller_id = Db::name('seller_account')->insertGetId($add_data);
- if (!$seller_id) {
- throw new Exception("添加分销商失败");
- }
- $jump_url = url('admin/seller/index');
- }
- $result = [
- 'code' => 200,
- 'message' => "保存成功",
- 'jump_url' => $jump_url
- ];
- } catch (Exception $exc) {
- $result = [
- 'code' => $exc->getCode(),
- 'message' => $exc->getMessage()
- ];
- }
- return $result;
- }
- /*
- * 获取国家-省份-城市列表
- */
- public function getCountryCodeList()
- {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- try {
-
- $result['list'] = $this->getCountrychildrenids(0);
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- /*
- * 获取分销平台列表
- */
- public function getDisPlatformList()
- {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- // $seller_id = $this->sellerId;
- $condition[] = ['seller_status', '=', 1];
- $order = 'order_id asc,id asc';
- $list = Db::name('dis_platform')->field("id,platform_name")->where($condition)->order($order)->select()->toArray();
- if ($list) {
- $result['list'] = $list;
- return $this->successResponse($result);
- } else {
- throw new Exception(lang('no_data_found'));
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-}
diff --git a/app/admin/controller/SellerBaseInfo.php b/app/admin/controller/SellerBaseInfo.php
deleted file mode 100644
index fde8ec1..0000000
--- a/app/admin/controller/SellerBaseInfo.php
+++ /dev/null
@@ -1,127 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Db;
-use think\facade\Request;
-use think\facade\View;
-use think\Exception;
-
-class SellerBaseInfo extends Common {
- /*
- * 品牌管理
- */
- public function index(){
- if (!Request::isPost()) {
- $other['title'] = '分销商实名认证审核';
- $guide['one']['text'] = '数据审核';
- $guide['two']['text'] = '分销商实名认证审核';
- View::assign('guide', $guide);
- View::assign('other', $other);
- return View::fetch('index');
- }
- else{
- try {
- $kw = input('kw');
- $condition['status'] = 2;//提交审核
- if (!empty($kw)) {
- $condition[] = array('first_name|last_name|certificate_name', 'like', "%$kw%");
- }
- $p = input('page', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'id desc';
- $count = Db::name('seller_base_info')->where($condition)->count();
- $list = Db::name('seller_base_info')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- else{
- foreach ($list as &$item){
- $item['main_area'] = $item['main_area'] ? array_map('intval', explode(',', $item['main_area'])) : [];
- $item['main_dis_platform'] = $item['main_dis_platform'] ? array_map('intval', explode(',', $item['main_dis_platform'])) : [];
- $item['cate_code'] = [$item['country_id'], $item['province_id'], $item['city_id']];
- }
- }
- $result['code'] = 200;
- $result['list'] = $list;
- $result['other'] = $other;
- return $this->successResponse($result);
-
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
- /*
- * 获取国家-省份-城市列表
- */
- public function getCountryCodeList() {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- try {
- $result['list'] = $this->getCountrychildrenids(0);
- return $this->successResponse($result);
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
-
- }
-
- protected function getCountrychildrenids($id) {
- $where['father_id'] = $id;
- $result = Db::name('country_code')->field('id as value,cate_name as label')->where($where)->cacheAlways(TRUE, 0, 'country_code')->order('order_id asc,id asc')->select()->toArray();
- if ($result) {
- foreach ($result as &$val) {
- $val['children'] = $this->getCountrychildrenids($val['value']); ////
- }
- return $result;
- }
- }
-
-
- /**
- * 分销商实名认证审核
- * @return array|int[]
- */
- public function reviewBaseInfo() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $base_info_id = input('post.base_info_id');
- if (is_numeric($base_info_id)) {
- $status = input('post.status');
- //更新数据
- $info = Db::name('seller_base_info')->field('id,status')->where('id', $base_info_id)->find();
- if (!$info) {
- throw new Exception(lang('no_data_found'));
- }
- if ($info['status'] == 1) {
- throw new Exception('该申请已审核通过,不能重复审核');
- }
- if ($status == 1) {
- Db::name('seller_base_info')->where('id', $base_info_id)->update(['status' => 1]);
- $message = '操作成功,审核通过';
- } else {
- Db::name('seller_base_info')->where('id', $base_info_id)->update(['status' => 3]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
- } else {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
\ No newline at end of file
diff --git a/app/admin/controller/SellerMenu.php b/app/admin/controller/SellerMenu.php
deleted file mode 100644
index 1077761..0000000
--- a/app/admin/controller/SellerMenu.php
+++ /dev/null
@@ -1,126 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Cache;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use think\Exception;
-
-use app\admin\util\MenuService;
-
-class SellerMenu extends Common {
- private $menuService;
- private $tableName = 'seller_menu';
- private $viewPath = 'sellerMenu';
-
-
- public function __construct() {
- parent::__construct();
- $this->menuService = new MenuService();
- }
-
- /**
- * 菜单列表
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- $other['title'] = '经销商菜单';
- $guide['one']['text'] = '经销商管理';
- $guide['two']['text'] = '经销商列表';
- View::assign('guide', $guide);
- View::assign('other', $other);
- View::assign('viewPath', $this->viewPath);
- return View::fetch('/menu/index');
- } else {
- $order = 'order_id asc,id asc';
- $list = $this->menuService->getMenuList($this->tableName, $order);
- $result['list'] = $list;
- return $this->successResponse($result);
- }
- }
-
- /**
- * 更新菜单显示状态
- */
- public function updateShowMenu() {
- header('Content-Type:text/html;charset=utf-8');
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- throw new Exception('参数错误!', 400);
- }
- $showMenu = input('show_menu');
- $isUpdate = $this->menuService->upShowMenu($this->tableName, (int)$id, $showMenu);
- if (!$isUpdate) {
- throw new Exception('更新失败!', 400);
- }
- return $this->successResponse('更新成功');
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /*
- * 获取菜单详情
- */
- public function getMenuDetail() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('id');
- if (!is_numeric($id)) {
- throw new Exception('参数错误!', 400);
- }
- $menuDetail = $this->menuService->getMenuDetail($this->tableName, (int)$id);
- if (!$menuDetail) {
- throw new Exception('菜单不存在!', 400);
- }
- $result['info'] = $menuDetail;
- return $this->successResponse($result);
- } catch (Exception $e) {
- return $this->errorResponse($e->getMessage());
- }
- }
-
- /**
- * 保存菜单
- * @return array|int[]
- */
- public function saveMenu() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //启动事务
- Db::startTrans();
- try {
- $data = Request::post();
- $id = $data['id'];
- if (isset($data['langs']) && $data['langs']) {
- $data['langs'] = json_encode($data['langs'], JSON_UNESCAPED_UNICODE);
- }
- if (is_numeric($id)) {
- //更新数据
- $this->menuService->upMenu($this->tableName, (int)$id, $data);
- $res['message'] = '菜单编辑成功';
- } else {
- unset($data['id']);
- $this->menuService->addMenu($this->tableName, (int)$id, $data);
- $res['message'] = '菜单添加成功';
- }
- ///////执行成功,提交事务///////
- Db::commit();
- return $this->successResponse($res);
- } catch (Exception $e) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($e->getMessage());
- }
- }
-}
diff --git a/app/admin/controller/StockCountry.php b/app/admin/controller/StockCountry.php
deleted file mode 100644
index ce703d0..0000000
--- a/app/admin/controller/StockCountry.php
+++ /dev/null
@@ -1,120 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use \app\admin\validate\StockCountry as StockCountryValidate;
-
-class StockCountry extends Common {
-
- /**
- * 国家列表
- * @return string
- */
- public function index() {
- ////////
- if (!Request::isPost()) {
- return View::fetch();
- } else {
- try {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('purpose_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'order_id asc,id asc';
- $count = Db::name('stock_country')->where($condition)->count();
- $list = Db::name('stock_country')->field("*")->where($condition)->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $result['other'] = $other;
- $result['list'] = $list;
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
- }
-
- /**
- *保存国家
- */
- public function save() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $data = Request::post();
- $validate = new StockCountryValidate();
- $check_result = $validate->check($data);
- if (!$check_result) {
- return $this->errorResponse($validate->getError());
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- //更新数据
- $update_result = Db::name('stock_country')->where('id', $id)->withoutField('id')->save($data);
- if ($update_result === FALSE) {
- return $this->errorResponse(lang('editing_failed'));
- }
- //提交事务
- Db::commit();
- return $this->successResponse('修改成功!');
- } else {
- //添加数据
- unset($data['id']);
- $add_result = Db::name('stock_country')->insertGetId($data);
- if (!$add_result) {
- return $this->errorResponse('添加失败!');
- }
- Db::name('stock_country')->where('id', $add_result)->save(['order_id' => $add_result]);
- //提交事务
- Db::commit();
- return $this->successResponse('添加成功!');
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 删除国家
- */
- public function delete() {
- if (!Request::isPost()) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- //开始事务
- Db::startTrans();
- try {
- $id = input('id');
- if (!is_numeric($id)) {
- return $this->errorResponse(lang('parameter_error'));
- }
- $condition['id'] = $id;
- $info = Db::name('stock_country')->field('id')->where($condition)->find();
- if (!$info) {
- return $this->errorResponse(lang('parameter_error'));
- }
- Db::name('stock_country')->where('id', $id)->delete();
- //提交事务
- Db::commit();
- return $this->successResponse('删除成功!');
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
diff --git a/app/admin/controller/Supplier.php b/app/admin/controller/Supplier.php
deleted file mode 100644
index 54d80e1..0000000
--- a/app/admin/controller/Supplier.php
+++ /dev/null
@@ -1,508 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use app\admin\validate\SupplierAccountAdd;
-use app\admin\validate\SupplierAccountEdit;
-use think\db\exception\DataNotFoundException;
-use think\db\exception\DbException;
-use think\db\exception\ModelNotFoundException;
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-
-class Supplier extends Common {
-
- public function index() {
- ////////
- View::assign('menuitem', strtolower('supplier-index'));
-
- $other['title'] = '供应商';
- $guide['one']['text'] = '供应商管理';
- $guide['two']['text'] = '供应商列表';
- View::assign('guide', $guide);
-
-
- View::assign('other', $other);
- return View::fetch('index');
- }
-
- /**
- * @throws ModelNotFoundException
- * @throws DbException
- * @throws DataNotFoundException
- */
- public function supplier_list() {
- if (Request::isPost()) {
- $kw = input('kw');
- $condition[] = ['initialize', '=', 1];
- if (!empty($kw)) {
- $condition[] = array('user_name|real_name', 'like', "%$kw%");
- }
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'b.id asc';
-
- $count = Db::name('supplier')
- ->alias('a')
- ->join('supplier_account b', 'a.id = b.supplier_id')
- ->where($condition)->count();
-
- $list = Db::name('supplier')
- ->alias('a')
- ->join('supplier_account b', 'a.id = b.supplier_id')
- ->field("a.id,b.supplier_id,b.user_name,a.real_name,ban_access,a.phone,supplier_name,initialize,login_time,login_ip,a.end_time,a.start_time,a.audit_status")
- ->where($condition)
- ->order($order)
- ->page($p, $other['page_size'])
- ->select()
- ->toArray();
-
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- } else {
- foreach ($list as &$item) {
- $item['endtime'] = date('Y-m-d', $item['end_time']);
- }
- }
- $other['admin_info'] = $this->cinfo;
- $d['code'] = 200;
- $d['list'] = $list;
- $d['other'] = $other;
- return $d;
- }
- }
-
- public function update_ban_access() {
- header('Content-Type:text/html;charset=utf-8');
- if (Request::isPost()) {
-
- $id = input('id');
- $sub_ban_access = input('ban_access');
- $info = Db::name('supplier')->field('id')->where('id', $id)->find();
- if (empty($info)) {
- $d['code'] = 400;
- $d['message'] = '信息不存在';
- return $d;
- }
- ///
-
- if (is_numeric($id)) {
- if ($sub_ban_access == '1') {
- $dd['ban_access'] = 1;
- $d['ban_access'] = 1;
- $d['message'] = '允许登录';
- } else {
- $dd['ban_access'] = 0;
- $d['ban_access'] = 0;
- $d['message'] = '禁止登录';
- }
- $backval = Db::name('supplier')->where('id', $id)->save($dd);
- if ($backval === FALSE) {
- $d['code'] = 400;
- } else {
- $d['code'] = 200;
- }
- } else {
- $d['code'] = 400;
- }
- } else {
- $d['code'] = 400;
- }
- return $d;
- }
-
-
- public function setAuditStatus() {
- header('Content-Type:text/html;charset=utf-8');
- if (Request::isPost()) {
-
- $id = input('id');
- $audit_status = input('audit_status');
- $info = Db::name('supplier')->field('id')->where('id', $id)->find();
- if (empty($info)) {
- $d['code'] = 400;
- $d['message'] = '信息不存在';
- return $d;
- }
- ///
-
- if (is_numeric($id)) {
- if ($audit_status == '1') {
- $dd['audit_status'] = 1;
- $d['audit_status'] = 1;
- $d['message'] = '通过审核';
- } else {
- $dd['audit_status'] = 0;
- $d['audit_status'] = 0;
- $d['message'] = '未审核';
- }
- $backval = Db::name('supplier')->where('id', $id)->save($dd);
- if ($backval === FALSE) {
- $d['code'] = 400;
- } else {
- $d['code'] = 200;
- }
- } else {
- $d['code'] = 400;
- }
- } else {
- $d['code'] = 400;
- }
- return $d;
- }
- /**
- * 保存供应商信息(废弃)
- * @return array
- */
- public function save_supplier() {
- if (Request::isPost()) {
- header('Content-Type:text/html;charset=utf-8');
- $data = Request::post();
- $id = input('id');
- $password = input('password');
- if (empty($password)) {
- } else {
- $data['password'] = joinmd5($password);
- }
-
- if (is_numeric($id)) {//更新数据
- $supplier_id = input('supplier_id');
- /////验证密码复杂度///////////
- $validate = new SupplierAccountEdit();
- $result = $validate->scene('edit')->check($data);
- if (!$result) {
- $d['code'] = 400;
- $d['message'] = $validate->getError();
- return $d;
- }
- //////保存供应商信息////////////
- $supplier_data['supplier_name'] = $data['supplier_name'];
- $supplier_data['real_name'] = $data['real_name'];
- $supplier_data['phone'] = $data['phone'];
- $supplier_data['end_time'] = strtotime($data['endtime']);
- Db::name('supplier')->where('id', $supplier_id)->save($supplier_data);
- ////////////////////////
- if (!empty($password)) {
- /////修改密码////////////////
- $supplier_account_data['password'] = $data['password'];
- Db::name('supplier_account')->where('id', $id)->save($supplier_account_data);
- }
- $d['code'] = 200;
- $d['end_time'] = strtotime($data['endtime']);
- $d['message'] = '编辑成功';
- } else {
- unset($data['id']);
- $validate = new SupplierAccountAdd();
- $result = $validate->check($data);
- if (!$result) {
- $d['code'] = 400;
- $d['message'] = $validate->getError();
- return $d;
- }
- //////////////////////
-
- Db::startTrans();
- try {
- $end_time = getcurrdate() + 3600 * 24 * 30;
- $supplier_data['phone'] = $data['phone'];
- $supplier_data['supplier_name'] = $data['supplier_name'];
- $supplier_data['real_name'] = $data['real_name'];
- $supplier_data['add_time'] = time();
- $supplier_data['start_time'] = time();
- $supplier_data['end_time'] = $end_time;
- $supplier_id = Db::name('supplier')->insertGetId($supplier_data);
- /////--------------------////
- $supplier_account_data['supplier_id'] = $supplier_id;
- $supplier_account_data['user_name'] = $data['user_name'];
- $supplier_account_data['password'] = $data['password'];
- $supplier_account_data['phone'] = $data['phone'];
- $supplier_account_data['real_name'] = $data['real_name'];
- $supplier_account_data['add_time'] = time();
- $supplier_account_data['initialize'] = 1;
- $supplier_account_id = Db::name('supplier_account')->insertGetId($supplier_account_data);
- if ($supplier_id && $supplier_account_id) {
- ///////执行成功,提交事务///////
- Db::commit();
- $d['code'] = 200;
- $d['message'] = '供应商添加成功';
- } else {
- //任一执行失败,执行回滚操作,相当于均不执行
- Db::rollback();
- $d['code'] = 400;
- $d['message'] = '供应商添加失败';
- }
-
- } catch (\Exception $e) {
- // 回滚事务
- Db::rollback();
- $d['code'] = 400;
- $d['message'] = '供应商添加失败';
- }
- }
- } else {
- $d['code'] = 400;
- $d['message'] = '非法请求';
- }
- return $d;
- }
-
- public function delete_admin() {
- if (Request::isPost()) {
- $id = input('id');
- if (is_numeric($id)) {
- $condition['id'] = $id;
- $info = Db::name('administrators')->field('id,initialize')->where($condition)->find();
- if ($info) {
- ///////////////////
- if ($info['initialize'] == '1') {
- $d['code'] = 400;
- $d['message'] = '该账号不能删除!';
- return $d;
- }
- if ($this->cinfo['initialize'] == 1 || $this->admin_id == $info['id']) {
- Db::name('administrators')->where('id', $id)->delete();
- /////////////////////////////
- $d['code'] = 200;
- $d['message'] = '删除成功!';
- } else {
- $d['code'] = 400;
- $d['message'] = '您没有删除权限';
- }
- } else {
- $d['code'] = 400;
- $d['message'] = '子账号不存在';
- }
- } else {
- $d['code'] = 400;
- $d['message'] = '参数有误!';
- }
- return $d;
- }
- }
-
- /**
- * 供应商编辑页
- * @param int $id
- * @return string
- */
- public function add(int $id = 0): string {
- View::assign('menuitem', strtolower('supplier-index'));
- if ($id && is_numeric($id)) {
- $other['title'] = '编辑供应商信息';
- } else {
- $other['title'] = '添加供应商信息';
- }
- $guide['one']['text'] = '供应商管理';
- $guide['two']['text'] = $other['title'];
-
- $other['id'] = $id;
- View::assign('guide', $guide);
- View::assign('other', $other);
- return View::fetch('add');
- }
-
- /**
- * 获取供应商详细信息
- * @return array
- */
- public function get_supplier_info(): array {
- try {
- if (!Request::isPost()) {
- throw new Exception("请求方式有误");
- }
- $supplier_id = input('id');
- if (!$supplier_id || !is_numeric($supplier_id)) {
- throw new Exception("参数有误");
- }
- $where = [
- 'a.id' => $supplier_id
- ];
- $supplier_info = Db::name('supplier')
- ->alias("a")
- ->field("a.*,b.id as supplier_account_id,b.user_name,b.sub_ban_access,b.phone as account_phone,b.real_name as account_name")
- ->join("web_supplier_account b", "b.supplier_id = a.id and b.initialize = 1")
- ->where($where)
- ->find();
- if (!$supplier_info) {
- throw new Exception("供应商信息有误");
- }
-// $supplier_info['sub_ban_access'] = (bool)$supplier_info['sub_ban_access'];
- $supplier_info['end_time'] = date("Y-m-d", $supplier_info['end_time']);
-
- $result = [
- 'code' => 200,
- 'message' => "成功",
- 'data' => $supplier_info
- ];
- } catch (Exception $exc) {
- $result = [
- 'code' => $exc->getCode(),
- 'message' => $exc->getMessage()
- ];
- }
- return $result;
- }
-
- /**
- * 保存供应商信息
- * @return array
- */
- public function save_supplier_info(): array {
- try {
- if (!Request::isPost()) {
- throw new Exception("请求方式有误");
- }
- $params = Request::param();
- if (!$params['supplier_name']) {
- throw new Exception("请填写供应商名称");
- }
- if (!$params['user_name']) {
- throw new Exception("请填写供应商账号");
- }
- if (!$params['account_name']) {
- throw new Exception("请填写供应商联系人姓名");
- }
- if (!$params['account_phone']) {
- throw new Exception("请填写供应商联系人手机号");
- }
-
-// dump($params['sub_ban_access']);exit;
-//
-// if ($params['sub_ban_access']) {
-// $params['sub_ban_access'] = 1;
-// } else {
-// $params['sub_ban_access'] = 0;
-// }
-
- Db::startTrans();
- if ($params['id']) {
- /////更新/////
- $where = [
- 'id' => $params['id']
- ];
- $supplier_info = Db::name('supplier')->where($where)->find();
- if (!$supplier_info) {
- throw new Exception("供应商信息有误");
- }
- /////更新供应商信息/////
- $update_supplier_data = [
- 'supplier_name' => $params['supplier_name'],/////供应商名称/////
- 'supplier_en_name' => $params['supplier_en_name'],/////供应商英文名称/////
- 'real_name' => $params['real_name'],/////供应商联系人姓名/////
- 'phone' => $params['phone'],/////供应商联系人手机/////
- 'email' => $params['email'],/////供应商联系人邮箱/////
- 'phone_number' => $params['phone_number'],/////供应商联系人座机/////
- 'unique_code' => $params['unique_code'],/////供应商唯一代码。营业执照上的统一代码/////
- 'legal_person_name' => $params['legal_person_name'],/////供应商法人/////
- 'legal_person_id_number' => $params['legal_person_id_number'],/////供应商法人身份证号/////
- 'address' => $params['address'],/////供应商地址/////
- 'postal_code' => $params['postal_code'],/////邮政编码/////
- 'end_time' => strtotime($params['end_time']) + 86400 - 1,/////到期时间/////
- 'ban_access' => $params['sub_ban_access'],/////账号状态/////
- 'account_executive' => $params['account_executive'],/////业务经理/////
- 'account_executive_phone' => $params['account_executive_phone'],///业务经理联系方式////
- ];
- $update_supplier_result = Db::name('supplier')->where($where)->update($update_supplier_data);
- if ($update_supplier_result === FALSE) {
- throw new Exception("更新供应商信息失败");
- }
-
- /////更新供应商主账号信息/////
- $supplier_account_where = [
- 'id' => $params['supplier_account_id'],
- 'supplier_id' => $params['id'],
- ];
- $supplier_account_info = Db::name('supplier_account')->where($supplier_account_where)->find();
- if (!$supplier_account_info) {
- throw new Exception("供应商主账号信息有误");
- }
-
- if ($params['user_name'] != $supplier_account_info['user_name']) {
- /////账号有修改,检查新账号是否存在/////
- $check_supplier_account_where = [
- 'user_name' => $params['user_name'],
- ];
- $check_supplier_account_result = Db::name('supplier_account')->where($check_supplier_account_where)->find();
- if ($check_supplier_account_result) {
- throw new Exception("此账号已存在,请换一个账号");
- }
- }
- $updae_supplier_account_data = [
- 'user_name' => $params['user_name'],
- 'real_name' => $params['account_name'],
- 'phone' => $params['account_phone'],
- 'sub_ban_access' => $params['sub_ban_access'],/////账号状态/////
- ];
- if ($params['password']) {
- $updae_supplier_account_data['password'] = joinmd5($params['password']);
- }
- $update_supplier_account_result = Db::name('supplier_account')->where($supplier_account_where)->data($updae_supplier_account_data)->update();
- if ($update_supplier_account_result === FALSE) {
- throw new Exception("更新供应商主账号信息失败");
- }
- $jump_url = "";
- } else {
- /////添加/////
-
- /////1、先添加供应商/////
- $add_supplier_data = [
- 'supplier_name' => $params['supplier_name'],
- 'real_name' => $params['account_name'],
- 'phone' => $params['account_phone'],
- 'start_time' => time(),
- 'end_time' => strtotime($params['end_time']) + 86400 - 1,
- 'ban_access' => $params['sub_ban_access'] ? 1 : 0,
- 'account_executive' => $params['account_executive'],/////业务经理/////
- 'account_executive_phone' => $params['account_executive_phone'],///业务经理联系方式////
- 'add_time' => time()
- ];
- $add_supplier_result = Db::name('supplier')->insertGetId($add_supplier_data);
- if (!$add_supplier_result) {
- throw new Exception("添加供应商失败");
- }
- /////2、再添加供应商账号/////
- $check_user_name_where = [
- 'user_name' => $params['user_name'],
- ];
- if (Db::name('supplier_account')->where($check_user_name_where)->find()) {
- throw new Exception("账号已存在,请换一个账号");
- }
-
- $add_supplier_account_data = [
- 'supplier_id' => $add_supplier_result,
- 'user_name' => $params['user_name'],
- 'password' => joinmd5($params['password']),
- 'real_name' => $params['account_name'],
- 'phone' => $params['account_phone'],
- 'initialize' => 1,
- 'sub_ban_access' => $params['sub_ban_access'] ? 1 : 0,
- 'add_time' => time()
- ];
- $add_supplier_account_result = Db::name('supplier_account')->insertGetId($add_supplier_account_data);
- if (!$add_supplier_account_result) {
- throw new Exception("添加供应商账号失败");
- }
- $jump_url = url('admin/supplier/add/id/' . $add_supplier_result);
- }
-
- Db::commit();
- $result = [
- 'code' => 200,
- 'message' => "保存成功",
- 'jump_url' => $jump_url
- ];
- } catch (Exception $exc) {
- Db::rollback();
- $result = [
- 'code' => $exc->getCode(),
- 'message' => $exc->getMessage()
- ];
- }
- return $result;
- }
-
-}
diff --git a/app/admin/controller/ThirdPartyLogisticsProductTemp.php b/app/admin/controller/ThirdPartyLogisticsProductTemp.php
deleted file mode 100644
index eccdac0..0000000
--- a/app/admin/controller/ThirdPartyLogisticsProductTemp.php
+++ /dev/null
@@ -1,123 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\supplier\validate\LogisticsProduct;
-
-class ThirdPartyLogisticsProductTemp extends Common {
-
- /**
- * 新建物流产品首页
- * @return string
- */
- public function index() {
- ////////
- return View::fetch();
- }
-
- /**
- * 审核物流产品
- * @return array|int[]
- */
- public function reviewLogisticsProduct() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- $status = input('post.status');
- //更新数据
- $info = Db::name('logistics_product')->field('id,status')->where('id', $id)->find();
- if (!$info) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- if ($status == 1) {
- Db::name('logistics_product')->where('id', $id)->update(['status' => 1]);
- $message = '操作成功,审核通过';
- } else {
- Db::name('logistics_product')->where('id', $id)->update(['status' => 2]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
- } else {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /**
- * 获取物流产品列表
- */
- public function logisticsProductList() {
- if (Request::isPost()) {
- $kw = input('kw');
- if (!empty($kw)) {
- $condition[] = array('product_name_cn|product_name_en|docking_code', 'like', "%$kw%");
- }
- $condition[] = ['status', '=', 3];
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'status asc,edit_time asc';
- $count = Db::name('logistics_product')->where($condition)->count();
- $list = Db::name('logistics_product')->field("id,platform_logistics_product_id,logistics_type,docking_system,docking_code,product_name_cn,product_name_en,value_added_services,status,edit_time")->where($condition)
- ->withAttr('edit_time', function ($value) {
- return date('Y-m-d H:i:s', $value);
- })->withAttr('platform_logistics_product_name', function ($value, $data) {
- return $data['platform_logistics_product_id'] ? Db::name('platform_logistics_product')->where('id', $data['platform_logistics_product_id'])->field('product_name_cn,product_name_en,cycle_start,cycle_end')->find() : '';
- })
- ->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
-
- $result['other'] = $other;
- if (!$list) {
- $list = [];
- $result['code'] = 400;
- return $result;
- } else {
- foreach ($list as &$item) {
- if ($item['value_added_services']) {
- $item['value_added_services'] = json_decode($item['value_added_services'], TRUE);
- } else {
- $item['value_added_services'] = [];
- }
- }
- $result['code'] = 200;
- $result['list'] = $list;
- return $result;
- }
- return $result;
- }
- }
-
- /**
- * 获取增值服务列表
- */
- public function logisticsVasList() {
- if (Request::isPost()) {
- $order = 'order_id asc,id asc';
- $list = Db::name('logistics_vas')->field("id,vas_name,vas_code")->order($order)->cacheAlways(TRUE, 0, 'logistics_vas')->select()->toArray();
- if (!$list) {
- $list = [];
- }
- $d['code'] = 200;
- $d['list'] = $list;
- return $d;
- }
- }
-
-}
diff --git a/app/admin/controller/ThirdPartyStockTemp.php b/app/admin/controller/ThirdPartyStockTemp.php
deleted file mode 100644
index 4fe3d28..0000000
--- a/app/admin/controller/ThirdPartyStockTemp.php
+++ /dev/null
@@ -1,197 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Db;
-use think\facade\View;
-use think\facade\Request;
-use app\supplier\validate\ThirdPartyStock;
-use app\supplier\validate\ThirdPartyStockAddress;
-
-class ThirdPartyStockTemp extends Common {
-
- /**
- * 新建仓库首页
- * @return string
- */
- public function index() {
- ////////
- return View::fetch();
- }
-
- /**
- * 审核仓库
- * @return array|int[]
- */
- public function reviewStock() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- $status = input('post.status');
- //更新数据
- $info = Db::name('third_party_stock')->field('id,status')->where('id', $id)->find();
- if (!$info) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
-
- if ($status == 1) {
- $count0 = Db::name('third_party_stock_address')->where('third_party_stock_id', $id)->where('status', 0)->count();
- if ($count0 > 0) {
- return $this->errorResponse('请先审核仓库地址');
- }
- $count1 = Db::name('third_party_stock_address')->where('third_party_stock_id', $id)->where('status', 1)->count();
- if ($count1 == 0) {
- return $this->errorResponse('至少有一个仓库地址通过审核');
- }
- Db::name('third_party_stock')->where('id', $id)->update(['status' => 1, 'need_review' => 1]);
- $message = '操作成功,审核通过';
- } else {
- Db::name('third_party_stock_address')->where('third_party_stock_id', $id)->where('status', 0)->save(['status' => 2]);
- Db::name('third_party_stock')->where('id', $id)->update(['status' => 2, 'need_review' => 1]);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
- } else {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 审核仓库地址
- * @return array|int[]
- */
- public function reviewAddress() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $id = input('post.id');
- if (is_numeric($id)) {
- $status = input('post.status');
- $result = [
- 'stock_status' => 0,
- 'status' => 0,
- 'need_review' => 0,
- ];
- //更新数据
- $info = Db::name('third_party_stock_address')->field('id,status,third_party_stock_id')->where('id', $id)->find();
- if (!$info) {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- if ($status == 1) {
- Db::name('third_party_stock_address')->where('id', $id)->update(['status' => 1]);
- $result['status'] = 1;
- $result['message'] = '操作成功,审核通过';
- } else {
- Db::name('third_party_stock_address')->where('id', $id)->update(['status' => 2]);
- $result['status'] = 2;
- $result['message'] = '操作成功,审核不通过';
- }
-
- $count0 = Db::name('third_party_stock_address')->where('third_party_stock_id', $info['third_party_stock_id'])->where('status', 0)->count();
- $count1 = Db::name('third_party_stock_address')->where('third_party_stock_id', $info['third_party_stock_id'])->where('status', 1)->count();
- if ($count0 == 0) {
- //仓库地址全部审核
- if ($count1 == 0) {
- //仓库不通过审核
- Db::name('third_party_stock')->where('id', $info['third_party_stock_id'])->update(['need_review' => 1, 'status' => 2]);
- $result['need_review'] = 1;
- $result['stock_status'] = 2;
- } else {
- //仓库通过审核
- Db::name('third_party_stock')->where('id', $info['third_party_stock_id'])->update(['need_review' => 1, 'status' => 1]);
- $result['need_review'] = 1;
- $result['stock_status'] = 1;
- }
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($result);
- } else {
- return $this->errorResponse(lang('request_method_incorrect'));
- }
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
- /**
- * 获取仓库列表
- */
- public function stockList() {
- if (Request::isPost()) {
- $kw = input('kw');
-
- if (!empty($kw)) {
- $condition[] = array('third_party_stock_name|docking_code', 'like', "%$kw%");
- }
-// $condition[]= array('need_review', '=', 2);
- $p = input('p', 1);
- $_GET['p'] = $p;
- $other['page_size'] = input('page_size', 20);
- $order = 'need_review desc,edit_time asc';
- $count = Db::name('third_party_stock')->where($condition)->count();
- $list = Db::name('third_party_stock')->field("id,stock_type,docking_system,third_party_stock_name,docking_code,status,need_review,edit_time")->where($condition)
- ->withAttr('edit_time', function ($value, $data) {
- return date('Y-m-d H:i:s', $value);
- })
- ->order($order)->page($p, $other['page_size'])->select()->toArray();
- $other['count'] = $count;
- if (!$list) {
- $list = [];
- }
- $d['code'] = 200;
- $d['list'] = $list;
- $d['other'] = $other;
- return $d;
- }
- }
-
- /**
- * 获取仓库列表
- */
- public function stockAddressList() {
- if (Request::isPost()) {
- $third_party_stock_id = input('third_party_stock_id');
-
- $condition['a.third_party_stock_id'] = $third_party_stock_id;
- $order = 'a.id asc';
- $list = Db::name('third_party_stock_address')
- ->alias('a')
- ->join('web_stock_country b', 'a.stock_country_id=b.id')
- ->field("a.id,a.receive_man,a.tel,a.stock_address,a.stock_city,a.stock_province,a.stock_country_id,a.stock_post_code,a.suit_range,b.country,a.status")->where($condition)
- ->withAttr('suit_range', function ($value, $data) {
- return $value ? array_map('intval', explode(',', $value)) : [];
- })
- ->order($order)->select()->toArray();
-
- if (!$list) {
- $result['code'] = 400;
- return $result;
- } else {
- $result['code'] = 200;
- $result['list'] = $list;
- return $result;
- }
- }
- }
-
-
-}
diff --git a/app/admin/controller/Translation.php b/app/admin/controller/Translation.php
deleted file mode 100644
index b27eb05..0000000
--- a/app/admin/controller/Translation.php
+++ /dev/null
@@ -1,45 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\Exception;
-use think\facade\Request;
-
-class Translation extends Common {
- /*
- * 翻译语言包
- */
- public function trans() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $data = Request::post();
- if (!isset($data['qArray']) || !is_array($data['qArray'])) {
- throw new Exception('翻译内容错误');
- }
- if (!isset($data['from']) || empty($data['from'])) {
- throw new Exception('源语言错误');
- }
- if (!isset($data['to']) || empty($data['to'])) {
- throw new Exception('目标语言错误');
- }
-
- $YDObj = new \app\common\service\YouDaoTrans();
- $ret = $YDObj->do_translate($data['qArray'], $data['from'], $data['to']);
- $ret = json_decode($ret, TRUE);
- if ($ret['errorCode'] != 0) {
- throw new Exception('错误代码:' . $ret['errorCode'] . ',请核对错误代码列表');
- }
- $result = $ret['translateResults'];
-
- return $this->successResponse($result);
- } catch (Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
-
-
-}
diff --git a/app/admin/controller/WithdrawalRecord.php b/app/admin/controller/WithdrawalRecord.php
deleted file mode 100644
index 4382b73..0000000
--- a/app/admin/controller/WithdrawalRecord.php
+++ /dev/null
@@ -1,142 +0,0 @@
-<?php
-
-namespace app\admin\controller;
-
-use think\facade\Db;
-use think\facade\Request;
-use think\facade\View;
-use think\Exception;
-
-class WithdrawalRecord extends Common {
- /*
- * 品牌管理
- */
- public function index(): string {
- $other['title'] = '提现审核';
- $guide['one']['text'] = '数据审核';
- $guide['two']['text'] = '提现审核';
- View::assign('guide', $guide);
- View::assign('other', $other);
- return View::fetch('index');
- }
-
- /*
- */
- public function getWithdrawalRecordList() {
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $kw = input('kw');
-// $condition[] = ['SRR.status', '=', 0];
- $condition[] = ['SWR.payment_account', 'like', '%' . $kw . '%'];
- $p = input('p', 1);
- $other['page_size'] = input('page_size', 20);
- $order = 'SWR.id desc';
- $count = Db::name('supplier_withdrawal_record')
- ->alias('SWR')
- ->join('payment_tool PT', 'PT.payment_tool_id=SWR.payment_tool_id')
- ->join('supplier_asset SA', 'SA.id=SWR.asset_id')
- ->join('currency C', 'C.id=SA.currency_id')
- ->where($condition)->count();
- $list = Db::name('supplier_withdrawal_record')
- ->alias('SWR')
- ->field("SWR.*,PT.payment_tool_name,C.currency_name")
- ->join('payment_tool PT', 'PT.payment_tool_id=SWR.payment_tool_id')
- ->join('supplier_asset SA', 'SA.id=SWR.asset_id')
- ->join('currency C', 'C.id=SA.currency_id')
- ->where($condition)->order($order)->page($p, $other['page_size'])->withAttr('add_time', function ($value) {
- return date('Y-m-d H:i', $value);
- })
- ->select()->toArray();
- $other['count'] = $count;
- $result['other'] = $other;
- if (!$list) {
- throw new Exception(lang('no_data_found'));
- } else {
- $result['list'] = $list;
- return $this->successResponse($result);
- }
- } catch (\Exception $exc) {
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-
- /**
- * 汇款审核
- */
- public function reviewWithdrawalRecord() {
- // 开始数据库事务
- Db::startTrans();
- try {
- if (!Request::isPost()) {
- throw new Exception(lang('request_method_incorrect'));
- }
- $record_id = input('post.record_id');
- if (!is_numeric($record_id)) {
- throw new Exception(lang('parameter_error'));
- }
- $status = input('post.status');
- //更新数据
- $info = Db::name('supplier_withdrawal_record')->field('id,status,asset_id,payment_amount,supplier_id')->where('id', $record_id)->find();
- if (!$info) {
- throw new Exception(lang('no_data_found'));
- }
- if ($info['status'] == 1) {
- throw new Exception('该申请已审核通过,请勿重复审核');
- }
- $payment_amount = $info['payment_amount'];
- if ($status == 1) {
- $service_charge = input('post.service_charge');
- if (!is_numeric($service_charge)) {
- throw new Exception('请输入手续费');
- }
- $add_fee = $payment_amount - $service_charge;//实际收款金额:充值金额-手续费
- $asset_update['mnyusd'] = Db::raw("mnyusd+$payment_amount");//提现总额
- $asset_update['mnylck'] = Db::raw("mnylck-$payment_amount");//冻结金额
- Db::name('supplier_asset')->where('id', $info['asset_id'])->update($asset_update);
- $record_update = [
- 'status' => 1,
- 'service_charge' => $service_charge,
- 'review_time' => time()//审核时间
- ];
- Db::name('supplier_withdrawal_record')->where('id', $record_id)->update($record_update);//更新状态
- $LogData = [
- 'amount' => $add_fee,
- 'type' => 2,//1增加,2减少
- 'remark' => '提现确认',
- 'user_id' => $this->admin_id,
- 'supplier_id' => $info['supplier_id'],
- 'target_type' => 2,//提现
- 'target_id' => $info['asset_id'],
- ];
- event('SupplierBillLog', $LogData);//提现确认日志
- $message = '操作成功,审核通过';
- } else {
- $review_comments = input('post.review_comments');
- //审核不通过处理
- $asset_update['mnyavl'] = Db::raw("mnyavl+$payment_amount");//可用余额恢复
- $asset_update['mnylck'] = Db::raw("mnylck-$payment_amount");//冻结金额恢复
- Db::name('supplier_asset')->where('id', $info['asset_id'])->update($asset_update);
-
- $no_record_update = [
- 'status' => 2,
- 'review_comments' => $review_comments,
- 'review_time' => time()//审核时间
- ];
- Db::name('supplier_withdrawal_record')->where('id', $record_id)->update($no_record_update);
- $message = '操作成功,审核不通过';
- }
- // 提交事务
- Db::commit();
- return $this->successResponse($message);
-
- } catch (Exception $exc) {
- // 回滚事务
- Db::rollback();
- return $this->errorResponse($exc->getMessage());
- }
- }
-
-}
\ No newline at end of file
diff --git a/app/admin/model/Language.php b/app/admin/model/Language.php
deleted file mode 100644
index 7c417b3..0000000
--- a/app/admin/model/Language.php
+++ /dev/null
@@ -1,16 +0,0 @@
-<?php
-
-namespace app\admin\model;
-
-use think\facade\Db;
-use think\model;
-use think\model\concern\SoftDelete;
-
-
-class Language extends Model {
- // 使用软删除特性
- use SoftDelete;
- // 设置软删除字段,默认为 delete_time
- protected $deleteTime = 'delete_time';
-
-}
diff --git a/app/admin/model/LanguagePag.php b/app/admin/model/LanguagePag.php
deleted file mode 100644
index 43d96f5..0000000
--- a/app/admin/model/LanguagePag.php
+++ /dev/null
@@ -1,26 +0,0 @@
-<?php
-
-namespace app\admin\model;
-
-use think\facade\Db;
-use think\model;
-use app\admin\model\{Language};
-
-class LanguagePag extends Model {
- protected $autoWriteTimestamp = true;
- protected $createTime = 'create_time';
- protected $updateTime = 'update_time';
- /**
- * @notes 获取源语言
- * @param $value
- * @param $data
- * @return string
- * @author BD
- * @date 2024/02/22 10:54
- */
- public function getFromValueAttr($value, $data)
- {
- $language = Language::where(['is_show' => 1])->order(['order_id' => 'asc', 'id' => 'asc'])->findOrEmpty();
- return LanguagePag::where(['lang' => $language['symbol'], 'type' => $data['type'], 'name' => $data['name'], 'platform_type' => $data['platform_type']])->value('value');
- }
-}
diff --git a/app/admin/model/Message.php b/app/admin/model/Message.php
deleted file mode 100644
index be0348e..0000000
--- a/app/admin/model/Message.php
+++ /dev/null
@@ -1,13 +0,0 @@
-<?php
-
-namespace app\admin\model;
-
-use think\facade\Db;
-use think\model;
-
-class Message extends Model {
- public function messageAttachment() {
- return $this->hasMany(MessageAttachment::class, 'message_id')->visible(['title','filename']);
- }
-
-}
diff --git a/app/admin/model/MessageAttachment.php b/app/admin/model/MessageAttachment.php
deleted file mode 100644
index a2bb81c..0000000
--- a/app/admin/model/MessageAttachment.php
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-namespace app\admin\model;
-
-use think\facade\Db;
-use think\model;
-
-class MessageAttachment extends Model {}
diff --git a/app/admin/validate/Category.php b/app/admin/validate/Category.php
deleted file mode 100644
index aafb3ea..0000000
--- a/app/admin/validate/Category.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-namespace app\admin\validate;
-
-use think\Validate;
-
-class Category extends Validate {
-
-
- protected $rule = [
- 'cate_name' => 'require',
- 'cate_code' => 'require|unique:category,cate_code',
- ];
- protected $message = [
- 'cate_name.require' => '请填写分类名称',
-// 'cate_name.unique' => '分类名称已存在!',
- 'cate_code.require' => '请填写分类编码',
- 'cate_code.unique' => '分类编码已存在!',
- ];
-
-}
diff --git a/app/admin/validate/CountryCode.php b/app/admin/validate/CountryCode.php
deleted file mode 100644
index fcf825a..0000000
--- a/app/admin/validate/CountryCode.php
+++ /dev/null
@@ -1,22 +0,0 @@
-<?php
-namespace app\admin\validate;
-
-use think\Validate;
-
-class CountryCode extends Validate {
-
-
- protected $rule = [
- 'cate_name' => 'require|unique:country_code,cate_name^father_id',
- 'cate_code' => 'require',
- ];
- protected $message = [
- 'cate_name.require' => '请填写名称',
- 'cate_name.unique' => '名称已存在!',
- 'cate_code.require' => '请填写编码',
- ];
- protected $scene = [
- 'city' => ['cate_name'],
- ];
-
-}
diff --git a/app/admin/validate/Currency.php b/app/admin/validate/Currency.php
deleted file mode 100644
index b2936ac..0000000
--- a/app/admin/validate/Currency.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class Currency extends Validate {
-
- protected $rule = [
- 'currency_code' => 'require',
- 'currency_name' => 'require',
- ];
- protected $message = [
- 'currency_code.require' => '请填写货币编码',
- 'currency_name.require' => '请填写货币名称',
- ];
-
-
-}
diff --git a/app/admin/validate/DeliverRegion.php b/app/admin/validate/DeliverRegion.php
deleted file mode 100644
index 01c622e..0000000
--- a/app/admin/validate/DeliverRegion.php
+++ /dev/null
@@ -1,21 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class DeliverRegion extends Validate {
-
- protected $rule = [
- 'region_code' => 'require',
- 'region_name' => 'require',
- 'region_currency' => 'require',
- ];
- protected $message = [
- 'region_code.require' => '请填写分销区域编码',
- 'region_name.require' => '请填写分销区域名称',
- 'region_currency.require' => '请填写分销区域币别',
- ];
-
-
-}
diff --git a/app/admin/validate/DeliverRegionLogistics.php b/app/admin/validate/DeliverRegionLogistics.php
deleted file mode 100644
index 77e3f84..0000000
--- a/app/admin/validate/DeliverRegionLogistics.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class DeliverRegionLogistics extends Validate {
-
- protected $rule = [
- 'deliver_region_id' => 'require',
- 'name' => 'require',
- ];
- protected $message = [
- 'deliver_region_id.require' => '请选择分销区域',
- 'name.require' => '请输入分销区域物流名称',
- ];
-
-
-}
diff --git a/app/admin/validate/DisPlatform.php b/app/admin/validate/DisPlatform.php
deleted file mode 100644
index d45a8b1..0000000
--- a/app/admin/validate/DisPlatform.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class DisPlatform extends Validate {
-
- protected $rule = [
- 'platform_name' => 'require',
- ];
- protected $message = [
- 'platform_name.require' => '请填写分销平台名称',
- ];
-
-
-}
diff --git a/app/admin/validate/DockingPlatform.php b/app/admin/validate/DockingPlatform.php
deleted file mode 100644
index 09db57d..0000000
--- a/app/admin/validate/DockingPlatform.php
+++ /dev/null
@@ -1,20 +0,0 @@
-<?php
-namespace app\admin\validate;
-
-use think\Validate;
-
-class DockingPlatform extends Validate {
-
-
- protected $rule = [
- 'docking_platform_name' => 'require|unique:docking_platform',
- 'cate_code' => 'require|unique:docking_platform',
- ];
- protected $message = [
- 'cate_name.require' => '请填写平台名称',
- 'cate_name.unique' => '平台名称已存在!',
- 'cate_code.require' => '请填写平台编码',
- 'cate_code.unique' => '平台编码已存在',
- ];
-
-}
diff --git a/app/admin/validate/GoodsFreightAttr.php b/app/admin/validate/GoodsFreightAttr.php
deleted file mode 100644
index ed278c4..0000000
--- a/app/admin/validate/GoodsFreightAttr.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class GoodsFreightAttr extends Validate {
-
- protected $rule = [
- 'attr_code' => 'require',
- 'attr_name' => 'require',
- ];
- protected $message = [
- 'attr_code.require' => '请填写货运属性代码',
- 'attr_name.require' => '请填写货运属性名称',
- ];
-
-
-}
diff --git a/app/admin/validate/GoodsMaterial.php b/app/admin/validate/GoodsMaterial.php
deleted file mode 100644
index f6531a9..0000000
--- a/app/admin/validate/GoodsMaterial.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class GoodsMaterial extends Validate {
-
- protected $rule = [
- 'material_name' => 'require',
- ];
- protected $message = [
- 'material_name.require' => '请填写材质名称',
- ];
-
-
-}
diff --git a/app/admin/validate/GoodsPurpose.php b/app/admin/validate/GoodsPurpose.php
deleted file mode 100644
index 5c054b5..0000000
--- a/app/admin/validate/GoodsPurpose.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class GoodsPurpose extends Validate {
-
- protected $rule = [
- 'purpose_name' => 'require',
- ];
- protected $message = [
- 'purpose_name.require' => '请填写商品用途名称',
- ];
-
-
-}
diff --git a/app/admin/validate/Language.php b/app/admin/validate/Language.php
deleted file mode 100644
index 660eaa0..0000000
--- a/app/admin/validate/Language.php
+++ /dev/null
@@ -1,24 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class Language extends Validate {
-
- protected $rule = [
- 'name' => 'require',
- 'name_loc' => 'require',
- 'symbol' => 'require|unique:language,symbol',
- 'trans_symbol' => 'require',
- ];
- protected $message = [
- 'name.require' => '请输入语言名称(中文)',
- 'name_loc.require' => '请输入语言名称',
- 'symbol.require' => '请输入语言标识',
- 'trans_symbol.require' => '请输入翻译标识',
- 'symbol.unique' => '语言标识已存在',
- ];
-
-
-}
diff --git a/app/admin/validate/LanguagePag.php b/app/admin/validate/LanguagePag.php
deleted file mode 100644
index 1272c89..0000000
--- a/app/admin/validate/LanguagePag.php
+++ /dev/null
@@ -1,25 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class LanguagePag extends Validate {
-
- protected $rule = [
- 'platform_type' => 'require',
- 'type' => 'require',
- 'name' => 'require|unique:language_pag,platform_type^lang^type^name',
- 'value' => 'require|unique:language_pag,platform_type^lang^value',
- ];
- protected $message = [
- 'platform_type.require' => '请选择平台类型',
- 'type.require' => '请输入类型',
- 'name.require' => '请输入名称',
- 'name.unique' => '名称已存在',
- 'value.require' => '请输入值',
- 'value.unique' => '值已存在',
- ];
-
-
-}
diff --git a/app/admin/validate/LogisticsVas.php b/app/admin/validate/LogisticsVas.php
deleted file mode 100644
index 007cfcb..0000000
--- a/app/admin/validate/LogisticsVas.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class LogisticsVas extends Validate {
-
- protected $rule = [
- 'vas_code' => 'require',
- 'vas_name' => 'require',
- ];
- protected $message = [
- 'vas_code.require' => '请填写增值服务编码',
- 'vas_name.require' => '请填写增值服务名称',
- ];
-
-
-}
diff --git a/app/admin/validate/Message.php b/app/admin/validate/Message.php
deleted file mode 100644
index 70d4463..0000000
--- a/app/admin/validate/Message.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class Message extends Validate {
-
- protected $rule = [
- 'title' => 'require',
- ];
- protected $message = [
- 'title.require' => '请输入消息标题',
- ];
-
-
-}
diff --git a/app/admin/validate/MsgCategory.php b/app/admin/validate/MsgCategory.php
deleted file mode 100644
index f785437..0000000
--- a/app/admin/validate/MsgCategory.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-namespace app\admin\validate;
-
-use think\Validate;
-
-class MsgCategory extends Validate {
-
-
- protected $rule = [
- 'title' => 'require',
- ];
- protected $message = [
- 'title.require' => '请填写分类名称',
- ];
-
-
-}
diff --git a/app/admin/validate/Notice.php b/app/admin/validate/Notice.php
deleted file mode 100644
index 0dfb079..0000000
--- a/app/admin/validate/Notice.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class Notice extends Validate {
-
- protected $rule = [
- 'title' => 'require',
- ];
- protected $message = [
- 'title.require' => '请输入公告标题',
- ];
-
-
-}
diff --git a/app/admin/validate/PartnerSchool.php b/app/admin/validate/PartnerSchool.php
deleted file mode 100644
index 99ee5cf..0000000
--- a/app/admin/validate/PartnerSchool.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class PartnerSchool extends Validate {
-
- protected $rule = [
- 'school_name' => 'require',
- ];
- protected $message = [
- 'school_name.require' => '请填写合作学校名称',
- ];
-
-
-}
diff --git a/app/admin/validate/PayBank.php b/app/admin/validate/PayBank.php
deleted file mode 100644
index e0ca6c5..0000000
--- a/app/admin/validate/PayBank.php
+++ /dev/null
@@ -1,23 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class PayBank extends Validate {
-
- protected $rule = [
- 'payee_name' => 'require',
- 'account_name' => 'require',
- 'account' => 'require',
- 'img_url' => 'require',
- ];
- protected $message = [
- 'payee_name.require' => '请填写开户行名称',
- 'account_name.require' => '请填写账户名称',
- 'account.require' => '请填写账户',
- 'img_url.require' => '请上传LOGO',
- ];
-
-
-}
diff --git a/app/admin/validate/PaymentTool.php b/app/admin/validate/PaymentTool.php
deleted file mode 100644
index dfc82c1..0000000
--- a/app/admin/validate/PaymentTool.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class PaymentTool extends Validate {
-
- protected $rule = [
- 'payment_tool_name' => 'require',
- ];
- protected $message = [
- 'payment_tool_name.require' => '请填写名称',
- ];
-
-
-}
diff --git a/app/admin/validate/PlatformLogisticsProduct.php b/app/admin/validate/PlatformLogisticsProduct.php
deleted file mode 100644
index 23a763d..0000000
--- a/app/admin/validate/PlatformLogisticsProduct.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class PlatformLogisticsProduct extends Validate {
-
- protected $rule = [
- 'product_name_cn' => 'require',
- 'product_name_en' => 'require',
- ];
- protected $message = [
- 'product_name_cn.require' => '请输入平台物流产品中文名称',
- 'product_name_en.require' => '请输入平台物流产品英文名称',
- ];
-
-
-}
diff --git a/app/admin/validate/PlatformRegion.php b/app/admin/validate/PlatformRegion.php
deleted file mode 100644
index 0557564..0000000
--- a/app/admin/validate/PlatformRegion.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class PlatformRegion extends Validate {
-
- protected $rule = [
- 'region_name' => 'require',
- ];
- protected $message = [
- 'region_name.require' => '请填写区域名称',
- ];
-
-
-}
diff --git a/app/admin/validate/ReturnExchange.php b/app/admin/validate/ReturnExchange.php
deleted file mode 100644
index 3016a40..0000000
--- a/app/admin/validate/ReturnExchange.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class ReturnExchange extends Validate {
-
- protected $rule = [
- 'is_proportion' => 'require',
- 'name' => 'require',
- ];
- protected $message = [
- 'is_proportion.require' => '请选择是否开启比例',
- 'name.require' => '请输入退换货类型名称',
- ];
-
-
-}
diff --git a/app/admin/validate/ReturnExchangeType.php b/app/admin/validate/ReturnExchangeType.php
deleted file mode 100644
index e331d17..0000000
--- a/app/admin/validate/ReturnExchangeType.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class ReturnExchangeType extends Validate {
-
- protected $rule = [
- 'return_exchange_id' => 'require',
- 'type' => 'require',
- ];
- protected $message = [
- 'return_exchange_id.require' => 'id信息不正确',
- 'type.require' => '请选择退换货类型分类',
- ];
-
-
-}
diff --git a/app/admin/validate/SalesPlatform.php b/app/admin/validate/SalesPlatform.php
deleted file mode 100644
index 7f57ea6..0000000
--- a/app/admin/validate/SalesPlatform.php
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class SalesPlatform extends Validate {
-
- protected $rule = [
- 'platform_name' => 'require',
- ];
- protected $message = [
- 'platform_name.require' => '请填写平台名称',
- ];
-
-
-}
diff --git a/app/admin/validate/SellerAccountAdd.php b/app/admin/validate/SellerAccountAdd.php
deleted file mode 100644
index 191375a..0000000
--- a/app/admin/validate/SellerAccountAdd.php
+++ /dev/null
@@ -1,27 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class SellerAccountAdd extends Validate
-{
-
-
- protected $rule = [
- 'user_name' => 'require|unique:seller_account,user_name',
- 'pwd' => 'require|regexo:/^.{6,18}$/|regext:/^.*?[\d]+.*$/|regexth:/^.*?[A-Za-z].*$/',
- 'seller_name' => 'require',
- 'real_name' => 'require',
- ];
- protected $message = [
- 'user_name.require' => '请填写账号',
- 'user_name.unique' => '账号已存在',
- 'pwd.require' => '请输入密码',
- 'pwd.regexo' => '密码必须在6-18位',
- 'pwd.regext' => '密码必须包含数字',
- 'pwd.regexth' => '密码必须包含字母',
- 'seller_name.require' => '请填写供应商名称',
- 'real_name.require' => '请填写联系人',
- ];
-}
diff --git a/app/admin/validate/SellerAccountEdit.php b/app/admin/validate/SellerAccountEdit.php
deleted file mode 100644
index e4e9935..0000000
--- a/app/admin/validate/SellerAccountEdit.php
+++ /dev/null
@@ -1,22 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class SellerAccountEdit extends Validate
-{
-
- protected $rule = [
- 'pwd' => 'regexo:/^.{6,18}$/|regext:/^.*?[\d]+.*$/|regexth:/^.*?[A-Za-z].*$/', ////填写密码就验证,不填写不验证////////
- 'seller_name' => 'require',
- 'real_name' => 'require',
- ];
- protected $message = [
- 'pwd.regexo' => '密码必须在6-18位',
- 'pwd.regext' => '密码必须包含数字',
- 'pwd.regexth' => '密码必须包含字母',
- 'seller_name.require' => '请填写供应商名称',
- 'real_name.require' => '请填写联系人',
- ];
-}
diff --git a/app/admin/validate/StockCountry.php b/app/admin/validate/StockCountry.php
deleted file mode 100644
index 32217a0..0000000
--- a/app/admin/validate/StockCountry.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-
-namespace app\admin\validate;
-
-use think\Validate;
-
-class StockCountry extends Validate {
-
- protected $rule = [
- 'country' => 'require',
- 'country_code' => 'require',
- ];
- protected $message = [
- 'country.require' => '请填写国家名称',
- 'country_code.require' => '请填写国家编码',
- ];
-
-
-}
diff --git a/app/admin/validate/SupplierAccountAdd.php b/app/admin/validate/SupplierAccountAdd.php
deleted file mode 100644
index 356f190..0000000
--- a/app/admin/validate/SupplierAccountAdd.php
+++ /dev/null
@@ -1,27 +0,0 @@
-<?php
-namespace app\admin\validate;
-
-use think\Validate;
-
-class SupplierAccountAdd extends Validate {
-
-
- protected $rule = [
- 'user_name' => 'require|unique:supplier_account,user_name',
- 'pwd' => 'require|regexo:/^.{6,18}$/|regext:/^.*?[\d]+.*$/|regexth:/^.*?[A-Za-z].*$/',
- 'supplier_name' => 'require',
- 'real_name' => 'require',
- ];
- protected $message = [
- 'user_name.require' => '请填写账号',
- 'user_name.unique' => '账号已存在',
- 'pwd.require' => '请输入密码',
- 'pwd.regexo' => '密码必须在6-18位',
- 'pwd.regext' => '密码必须包含数字',
- 'pwd.regexth' => '密码必须包含字母',
- 'supplier_name.require' => '请填写供应商名称',
- 'real_name.require' => '请填写联系人',
- ];
-
-
-}
diff --git a/app/admin/validate/SupplierAccountEdit.php b/app/admin/validate/SupplierAccountEdit.php
deleted file mode 100644
index e3637cd..0000000
--- a/app/admin/validate/SupplierAccountEdit.php
+++ /dev/null
@@ -1,21 +0,0 @@
-<?php
-namespace app\admin\validate;
-
-use think\Validate;
-
-class SupplierAccountEdit extends Validate {
-
- protected $rule = [
- 'pwd' => 'regexo:/^.{6,18}$/|regext:/^.*?[\d]+.*$/|regexth:/^.*?[A-Za-z].*$/',////填写密码就验证,不填写不验证////////
- 'supplier_name' => 'require',
- 'real_name' => 'require',
- ];
- protected $message = [
- 'pwd.regexo' => '密码必须在6-18位',
- 'pwd.regext' => '密码必须包含数字',
- 'pwd.regexth' => '密码必须包含字母',
- 'supplier_name.require' => '请填写供应商名称',
- 'real_name.require' => '请填写联系人',
- ];
-
-}
diff --git a/app/admin/validate/SupplierMenu.php b/app/admin/validate/SupplierMenu.php
deleted file mode 100644
index 7390c70..0000000
--- a/app/admin/validate/SupplierMenu.php
+++ /dev/null
@@ -1,19 +0,0 @@
-<?php
-namespace app\admin\validate;
-
-use think\Validate;
-
-class SupplierMenu extends Validate {
-
-
- protected $rule = [
- 'title' => 'require',
- 'menu_index' => 'require',
- ];
- protected $message = [
- 'title.require' => '请填写菜单名称',
- 'menu_index.require' => '请填写菜单索引',
- ];
-
-
-}
diff --git a/app/admin/view/bigv_info/index.html b/app/admin/view/bigv_info/index.html
deleted file mode 100644
index bd28eab..0000000
--- a/app/admin/view/bigv_info/index.html
+++ /dev/null
@@ -1,210 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide['one']['text']}" two_word="{$guide['two']['text']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span data-i18n="goods_brand_management">{$other['title']}</span>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchData.kw" placeholder="请输入关键词" style="width: 300px"></el-input>
-  
- <el-button type="success" icon="Search" @click="getBigvInfoList()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="bigvInfoList" v-loading="loading" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column prop="first_name" label="名称"></el-table-column>
- <el-table-column prop="preferred_product_type" label="偏好带货产品类型"></el-table-column>
- <el-table-column prop="nationality" label="国籍"></el-table-column>
- <el-table-column prop="graduation_school" label="毕业学院"></el-table-column>
- <el-table-column prop="personal_images" label="个人图像">
- <template #default="scope">
- <template v-for="item in scope.row.personal_images">
- <el-image style="width: 60px; height: 60px; margin-right: 5px;" :src="item.url" fit="cover" :preview-src-list="[item.url]" lazy>
- <div slot="error" class="image-slot">
- <i class="el-icon-picture-outline"></i>
- </div>
- </el-image>
- </template>
- </template>
- </el-table-column>
- <el-table-column label="是否显示官网" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'is_show')" v-model="scope.row.is_show"
- style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1" :inactive-value="0" inline-prompt active-text="是"
- inactive-text="否" />
- </template>
- </el-table-column>
-
-
-
- <!-- <el-table-column prop="brand_type" label="品牌类型" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.brand_type==1">
- <span data-i18n="brand_type_1">非自有品牌</span>
- </template>
- <template v-else>
- <span data-i18n="brand_type_2">自有品牌</span>
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="need_filings" label="是否需要备案" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.need_filings==1">
- <span data-i18n="need_filings_1">是</span>
- </template>
- <template v-else>
- <span data-i18n="need_filings_0">否</span>
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="real_name" label="审核状态" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">已审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="info">未通过审核</el-tag></template>
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.status==0?false:true" @click="showBrand(scope.row)">审核</el-button>
- </template>
- </el-table-column> -->
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchData.page" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchData.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog title="品牌信息" width="1200px" align-center="true" class="icon-dialog" v-model="dialogBrand" :before-close="closeForm" append-to-body>
- <el-card style="width: 100%">
- <el-form label-width="auto">
- <el-form-item label="品牌名称:">
- {{brandInfo.brand_name}}
- </el-form-item>
- <el-form-item label="品牌类型:">
- <template v-if="brandInfo.brand_type==1">
- <span data-i18n="brand_type_1">非自有品牌</span>
- </template>
- <template v-else>
- <span data-i18n="brand_type_2">自有品牌</span>
- </template>
- </el-form-item>
- <el-form-item label="是否需要备案:">
- <template v-if="brandInfo.need_filings==1">
- <span data-i18n="need_filings_1">是</span>
- </template>
- <template v-else>
- <span data-i18n="need_filings_0">否</span>
- </template>
- </el-form-item>
- <el-form-item label="品牌介绍">
- {{brandInfo.brand_desc}}
- </el-form-item>
- <el-form-item label="品牌LOGO">
- <template v-if="brandInfo.brand_logo">
- <img :src="brandInfo.brand_logo" @click="previewPictureCard(brandInfo.brand_logo)" :zoom-rate="1.2" :max-scale="7" :min-scale="0.2"
- style="width: 100px;height: 100px;" />
- </template>
- </el-form-item>
- </el-form></el-card>
-
- <br />
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span>品牌证书</span>
- </div>
- </template>
- <el-table :data="brandCertList" v-loading="loading_brand_cert" border style="width: 100%" :stripe="true">
- <el-table-column prop="title" label="文件名称" align="center">
- <template #default="scope">
- <el-link :href="scope.row.filename" target="_blank" type="success">{{ scope.row.title }}</el-link>
- </template>
- </el-table-column>
- <el-table-column prop="filesize" label="文件大小" align="center"></el-table-column>
- </el-table>
- </el-card>
- <br />
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span>备案范围</span>
- </div>
- </template>
- <el-table :data="bigvInfoFilingsList" border style="width: 100%" :stripe="true">
- <el-table-column prop="country" label="销售国家" align="center"></el-table-column>
- <el-table-column prop="platform_name" label="销售平台" align="center"></el-table-column>
- <el-table-column prop="amount" label="店铺数量上限" align="center"></el-table-column>
- </el-table>
- </el-card>
- <br />
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span>授权协议</span>
- </div>
- </template>
- <el-table :data="brandAgreementList" v-loading="loading_brand_agreement" border style="width: 100%" :stripe="true">
- <el-table-column prop="title" label="文件名称" align="center">
- <template #default="scope">
- <el-link :href="scope.row.filename" target="_blank" type="success">{{ scope.row.title }}</el-link>
- </template>
- </el-table-column>
- <el-table-column prop="filesize" label="文件大小" align="center"></el-table-column>
- </el-table>
- </el-card>
- <el-row>
- <el-col :span="24" style="text-align: center;margin:30px 0px;">
- <el-button type="success" @click="reviewBigvInfo(1)">通过审核</el-Button>
- <el-button type="danger" @click="reviewBigvInfo(2)">不通过审核</el-button>
- </el-col>
- </el-row>
- </el-dialog>
- <el-dialog v-model="dialogVisible_Picture">
- <img w-full :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/bigv_info/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/cancel_publish_order/create.html b/app/admin/view/cancel_publish_order/create.html
deleted file mode 100644
index deacef8..0000000
--- a/app/admin/view/cancel_publish_order/create.html
+++ /dev/null
@@ -1,860 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8" />
- <include file="common:title" />
- <meta name="renderer" content="webkit" />
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0" />
- <include file="common:header" />
- <include file="common:element-plus" />
- <script src="/static/tinymce/js/tinymce/tinymce.min.js"></script>
- <style>
- /* .goods_card .el-tabs__item {
- padding: 0 50px;
- height: 50px;
- line-height: 50px;
- font-size: 16px;
- } */
-
- .goods_description .el-tabs__item {
- padding: 0 20px;
- height: 40px;
- line-height: 40px;
- font-size: 16px;
- }
-
- .goods_card>.el-tabs__header .el-tabs__item.is-active {
- color: #fff !important;
- background-color: #35aca6;
- }
- </style>
- <style>
- .crSubItem {
- margin-bottom: 20px;
- }
-
- .SubTi {
- margin-bottom: 10px;
- }
-
- .SubTi h4 {
- line-height: 30px;
- margin-right: 10px;
- font-size: 15px;
- }
-
- .subSec {
- padding: 10px 20px 0px 20px;
- background: #f9f9f9;
- border: 1px solid #e7e7e7;
- border-radius: 2px;
- }
-
- .tox .tox-edit-area::before {
- border: 0px !important;
- }
-
- .ml-3 {
- margin-left: 0.75rem;
- }
-
- .otherParameter .el-textarea__inner {
- height: 120px;
- }
-
- .num {
- font-size: 12px;
- }
- </style>
-
- <style>
- .form_submit_box {
- position: fixed;
- bottom: 0px;
- left: 250px;
- right: 0;
- text-align: center;
- padding: 35px 0;
- background-color: #fff;
- z-index: 10;
- border-top: 1px solid #e7e7e7;
- }
-
- .disdetail .el-dialog__header {
- border-bottom: 1px solid #e7e7e7;
- position: absolute;
- top: 16px;
- left: 16px;
- right: 0px;
- height: 20px;
- }
-
- .disdetail .SubTi h4 {
- font-weight: bold;
- }
-
- .disdetail .el-row {
- height: 30px;
- line-height: 30px;
- margin-bottom: 20px;
- }
-
- .el-tabs__new-tab {
- margin: 10px 10px 10px 10px;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <input type="hidden" id="publish_order_id" value="{$other['id']}" />
- <input type="hidden" id="cancel_id" value="{$other['cancel_id']}" />
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="刊登" two_word="审核刊登单" />
- </el-header>
- <el-main style="position: relative;">
- <el-card style="width:100%;margin-bottom: 103px;">
- <template #header>
- <div class="card-header">
- <span data-i18n="thirdpartystock_management">审核刊登单</span>
- </div>
- </template>
- <el-card style="max-width:100%;" v-loading="loading.loading">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">基础信息</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="刊登类型">
- <el-radio-group v-model="publishOrderInfoForm.public_type" disabled class="ml-4">
- <el-radio :value="1">无属性</el-radio>
- </el-radio-group>
- </el-form-item>
- <template v-if="publishOrderInfoForm.supplier_goods_code!==null">
- <el-form-item label="选择分类">
- <el-cascader v-model="publishOrderInfoForm.cate_code" disabled :options="categoryList" clearable style="width:350px;" @change="handleCategoryChange" />
- </el-form-item>
-
- <el-form-item label="品牌名称">
- <el-select v-model="publishOrderInfoForm.brand_code" disabled placeholder="请选择品牌名称" style="width:350px;">
- <el-option v-for="freight_attr_item in goodsBrandList" :key="freight_attr_item.attr_code" :label="freight_attr_item.attr_name"
- :value="freight_attr_item.attr_code" />
- </el-select>
- </template>
- </el-form-item>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top: 20px;" v-if="publishOrderInfoForm.public_type==1">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">商品信息</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="供应商商品编码">
- <el-input v-model="publishOrderInfoForm.supplier_goods_code" @change="getGoodsInfo" placeholder="请输入供应商商品编码" style="width:350px;"
- :disabled="publishOrderInfoForm.istemp===1?true:false"></el-input>
- </el-form-item>
-
- <el-form-item label="商品名称">
- {{publishOrderInfoForm.goods_title_cn}}
- </el-form-item>
-
- <el-form-item label="分销信息">
- <el-button type="success" @click="showGoodsDisInfo()">查看</el-button>
- </el-form-item>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top: 20px;" v-loading="loading.loading">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">描述信息</span>
- </div>
- </template>
- <el-tabs class="goods_description" type="border-card">
- <el-tab-pane label="英文">
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="标题" :rules="[{required:true}]">
- {{publishOrderInfoForm.goods_title_en}}
- </el-form-item>
- <el-form-item label="描述">
- <div v-html="publishOrderInfoForm.goods_desc_en"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- <el-tab-pane label="中文">
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="标题">
- {{publishOrderInfoForm.goods_title_cn}}
- </el-form-item>
- <el-form-item label="描述">
- <div v-html="publishOrderInfoForm.goods_desc_cn"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- </el-tabs>
-
- </el-card>
- <el-card style="max-width:100%;margin-top: 20px;" v-loading="loading.loading">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">通用图片</span>
- </div>
- </template>
- <el-row :gutter="20" style="margin-top: 20px;">
- <el-col :span="24">
- <div class="grid-content ep-bg-purple">
- <template v-for="(item,index) in publishOrderPictureList" :key="index">
- <el-image style="width: 100px; height: 100px" :src="item.url" :zoom-rate="1.2" :max-scale="7" :min-scale="0.2" :preview-src-list="[item.url]" />
- </template>
- </div>
- </el-col>
- </el-row>
-
- </el-card>
- <el-card style="max-width:100%;margin-top: 20px;" v-loading="loading.loading">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">取消刊登信息</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left" ref="form" :model="cancelInfo" label-width="100px">
-
- <el-form-item label="取消原因">
- <el-select v-model="cancelInfo.reason_id" placeholder="请选择取消原因" disabled style="width:350px;" clearable>
- <el-option v-for="item in cancelReasonList" :key="item.id" :label="item.name" :value="item.id" />
- </el-select>
- </el-form-item>
- <el-form-item label="备注">
- {{cancelInfo.remark}}
- </el-form-item>
-
-
- </el-form>
- </el-card>
-
- </el-card>
- <div class="form_submit_box">
- <el-button type="success" @click="reviewPublishOrder(1)">通过审核(取消刊登)</el-Button>
- <el-button type="danger" @click="showReviewPublishOrder()">不通过审核(取消刊登)</el-button>
- </div>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog v-model="dialogVisible_Picture">
- <img w-full :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
-
- <el-dialog v-model="dialogVisible_reason" style="position: relative;width: 600px;">
- <template #header>
- {{set_nopass_reason_title}}
- </template>
- <el-form label-width="150px" label-position="left" ref="form">
- <el-form-item label="不通过理由">
- <el-input v-model="comments" maxlength="30" style="width: 90%" placeholder="请填写不通过理由" type="textarea" show-word-limit />
- </el-form-item>
- <el-form-item>
- <el-button type="danger" @click="reviewPublishOrder(2)">确定不通过</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
-
-
- <el-dialog class="disdetail" v-model="dialog.setGoodsDisInfo" :show-close="true" :close-on-click-modal="false" style="position: relative;width: 70%;">
- <template #header>
- {{set_goods_dis_info_title}}
- </template>
- <div style="max-width:100%;max-height: 850px;overflow-y: scroll;margin-top: 50px;">
- <el-card v-loading="loading.goodsDisInfo" style="max-width:100%;">
- <template #header>商品基本信息</template>
-
- <el-form label-width="150px" label-position="left" ref="form">
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="商品分类">
- {{goodsDisInfo.first_cate_name}} > {{goodsDisInfo.second_cate_name}} > {{goodsDisInfo.three_cate_name}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="供应商商品编码">
- {{goodsDisInfo.supplier_goods_code}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品仓库模式">
- <template v-if="goodsDisInfo.warehouse_mode==1">自建仓</template>
-
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="对接系统">
- <template v-if="goodsDisInfo.docking_way==0">无</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="定价方式">
- <template v-if="goodsDisInfo.price_method==1">自主定价</template>
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="货运属性">
- {{goodsDisInfo.attr_name}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="品牌">
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品用途">
- {{goodsDisInfo.goods_purpose}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="销售形式">
- {{goodsDisInfo.sales_form}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="是否侵权">
- <template v-if="goodsDisInfo.is_tort==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="是否停购">
- <template v-if="goodsDisInfo.is_stop_buy==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="负责人">
- {{goodsDisInfo.recommend_man}}
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- </el-card>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="分销区域">
- <el-table :data="disAreaList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="分销区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="one_shipment" label="销售模式"></el-table-column>
- <el-table-column prop="one_shipment" label="配送方式">
- <template #default="scope">
- <template v-if="scope.row.distribution_area_id.dis_model==1">海外仓配送</template>
- </template>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="分销库存">
- <el-table :data="disStockList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="供应商仓库"></el-table-column>
- <!-- <el-table-column prop="docking_code" label="平台仓库"></el-table-column> -->
- <el-table-column prop="supplier_stock_amount" label="供应商库存量"></el-table-column>
- <el-table-column prop="platform_stock_amount" label="平台库存量"></el-table-column>
- <!-- <el-table-column prop="one_shipment" label="平台库存量同步供应商库存量"></el-table-column>
- <el-table-column prop="one_shipment" label="税号"></el-table-column> -->
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="代发价格">
- <el-table :data="disPriceList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="product_name_cn" label="供应商物流产品"></el-table-column>
- <el-table-column label="平台物流产品">Standard Shipping</el-table-column>
- <el-table-column prop="supply_price" label="供货单价"></el-table-column>
- <el-table-column label="平台运费">0.00</el-table-column>
- <el-table-column prop="dis_price" label="分销售价"></el-table-column>
- <el-table-column prop="distribution_area_id" label="币别">
- <template #default="scope">{{scope.row.distribution_area_id.dis_currency}}</template>
- </el-table-column>
- <el-table-column prop="take_effect_time" label="价格生效时间"></el-table-column>
- <el-table-column prop="package_goods_amount" label="包裹可含商品数量"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="退货地址">
- <el-table :data="disReturnGoodsList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域" width="80">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="退货仓库" width="150"></el-table-column>
- <el-table-column label="退货地址">
- <template #default="scope">
- {{scope.row.stock_address}}
- {{scope.row.stock_city}}
- {{scope.row.stock_province}}
- {{scope.row.stock_country_id}}
- {{scope.row.stock_post_code}}
- </template>
- </el-table-column>
-
- <el-table-column prop="receive_man" label="联系人" width="180"></el-table-column>
- <el-table-column prop="tel" label="联系电话" width="150"></el-table-column>
- </el-table>
- </el-tab-pane>
- </el-tabs>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="商品描述">
- <el-tabs type="border-card" class="goods_card" style="margin-top: 20px;">
- <el-tab-pane label="英文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_en}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_en">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_en"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- <el-tab-pane label="中文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_cn}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_cn">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_cn"></div>
- </el-form-item>
- </el-form>
-
- </el-tab-pane>
- </el-tabs>
- </el-tab-pane>
- <el-tab-pane label="规格参数">
- <el-form label-width="150px" label-position="left" ref="form" :model="goodsSpecForm" label-width="100px">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>净规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(cm)">
- {{goodsDisInfo.goodsSpecInfo.goods_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(cm)">
- {{goodsDisInfo.goodsSpecInfo.goods_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(cm)">
- {{goodsDisInfo.goodsSpecInfo.goods_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(kg)">
- {{goodsDisInfo.goodsSpecInfo.goods_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>包装规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(cm)">
- {{goodsDisInfo.goodsSpecInfo.spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(cm)">
- {{goodsDisInfo.goodsSpecInfo.spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(cm)">
- {{goodsDisInfo.goodsSpecInfo.spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(kg)">
- {{goodsDisInfo.goodsSpecInfo.spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>装箱规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(cm)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(cm)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(cm)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(kg)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="箱率">
- {{goodsDisInfo.goodsSpecInfo.box_pcs}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
-
- </el-tab-pane>
- <el-tab-pane label="商品属性">
- <el-card style="max-width:100%;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">默认属性</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>采购参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="出厂价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.factory_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="分销价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.distribution_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="采购周期(天)">
- {{goodsDisInfo.goodsAttributeInfo.procurement_cycle}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
-
- <div class="crSubItem">
- <div class="SubTi">
- <h4>商品识别码</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="MPN">
- {{goodsDisInfo.goodsAttributeInfo.mpn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="JAN">
- {{goodsDisInfo.goodsAttributeInfo.jan}}
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="GTIN(UPC)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_upc}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="GTIN(ISBN)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_isbn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="ISBN(EAN)">
- {{goodsDisInfo.goodsAttributeInfo.isbn_ean}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>面料/材料</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="主材质">
- {{goodsDisInfo.goodsAttributeInfo.material_main}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质一">
- {{goodsDisInfo.goodsAttributeInfo.material_one}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质二">
- {{goodsDisInfo.goodsAttributeInfo.material_two}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="次材质三">
- <template v-for="material_three_item in goodsDisInfo.goodsAttributeInfo.material_three">
- {{material_three_item}};
- </template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="详细材质">
- {{goodsDisInfo.goodsAttributeInfo.material_detailed}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem otherParameter">
- <div class="SubTi">
- <h4>其它参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="参考链接">
- {{goodsDisInfo.goodsAttributeInfo.reference_link}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="包装内含">
- {{goodsDisInfo.goodsAttributeInfo.packaging_contains}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="产品卖点">
- {{goodsDisInfo.goodsAttributeInfo.selling_points}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <div class="grid-content">
- <el-form-item label="售后配件">
- <template v-if="goodsDisInfo.goodsAttributeInfo.after_sales_parts==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>电池参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="电池型号">
- {{goodsDisInfo.goodsAttributeInfo.battery_type}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池电压(V)">
- {{goodsDisInfo.goodsAttributeInfo.battery_voltage}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池容量(mAh)">
- {{goodsDisInfo.goodsAttributeInfo.battery_capacity}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top:20px;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">扩展属性</span>
- </div>
- </template>
-
- <el-row :gutter="20" v-for="(AttributExtendItem,index) in goodsDisInfo.goodsAttributExtendList">
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="属性名称">
- {{AttributExtendItem.define_attribute_name}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="16">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="属性值">
- {{AttributExtendItem.define_attribute_value}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </el-card>
- </el-tab-pane>
- <el-tab-pane label="零售限价">
- <el-table :data="goodsDisInfo.goodsRetailPriceLimitList" border style="width: 100%" :stripe="true">
- <el-table-column label="价格类型" width="180">
- <template #default="scope">
- <template v-if="scope.row.price_type==1">日常价</template>
- <template v-else-if="scope.row.price_type==2">活动价</template>
- </template>
- </el-table-column>
- <el-table-column label="销售国家">
- <template #default="scope">
- {{scope.row.sale_country_code}}
- </template>
- </el-table-column>
- <el-table-column label="销售平台">
- <template #default="scope">
- {{scope.row.sales_platform}}
- </template>
- </el-table-column>
- <el-table-column label="币别">
- <template #default="scope">
- {{scope.row.currency}}
- </template>
- </el-table-column>
- <el-table-column label="最低零售价">
- <template #default="scope">
- {{scope.row.min_retail_price}}
- </template>
- </el-table-column>
- <el-table-column label="生效时间">
- <template #default="scope">
- {{scope.row.start_time}}
- </template>
- </el-table-column>
- <el-table-column label="失效时间">
- <template #default="scope">
- {{scope.row.end_time}}
- </template>
- </el-table-column>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品标签">
- <el-table :data="goodsDisInfo.goodsLabelList" border style="width: 100%" :stripe="true">
- <el-table-column prop="label_type" label="标签类型" width="280"></el-table-column>
- <el-table-column prop="goods_label" label="商品标签"></el-table-column>
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="限制分销平台">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-form-item label="是否限制分销平台">
- <template v-if="goodsDisInfo.is_limit_dis_platform==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-table v-if="goodsDisInfo.is_limit_dis_platform==1" :data="goodsDisInfo.goodsLimitDisPlatformList" border style="width: 100%" :stripe="true">
- <el-table-column prop="platform_name" label="限制分销平台"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品图片">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-button :type="pictureStatuslist[0]==true?'primary':''" @click="setPictureStatus(0)">全部(<span class="num">{{goodsPictureCount.type0??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[1]==true?'primary':''" @click="setPictureStatus(1)">原图(<span class="num">{{goodsPictureCount.type1??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[2]==true?'primary':''" @click="setPictureStatus(2)">普修图(<span class="num">{{goodsPictureCount.type2??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[3]==true?'primary':''" @click="setPictureStatus(3)">精修图(<span class="num">{{goodsPictureCount.type3??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[4]==true?'primary':''" @click="setPictureStatus(4)">主图(<span class="num">{{goodsPictureCount.type4??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[5]==true?'primary':''" @click="setPictureStatus(5)">包装图(<span class="num">{{goodsPictureCount.type5??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[6]==true?'primary':''" @click="setPictureStatus(6)">图片尺寸1000(<span class="num">{{goodsPictureCount.type6??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[7]==true?'primary':''" @click="setPictureStatus(7)">图片尺寸1600(<span class="num">{{goodsPictureCount.type7??0}}</span>)</el-button>
- </div>
- </el-col>
- </el-row>
- <div>
- <el-image v-for="(img,index) in goodsPictureList" style="width: 100px; height: 100px" :src="img.url" @click="previewPictureCard(img)" :fit="fit" />
- </div>
-
- </el-tab-pane>
- </el-tabs>
- <div style="text-align: center; margin: 20px 0px;" v-if="!loading.dis_loading">
- <el-button @click="dialog.setGoodsDisInfo=false">关闭</el-Button>
- </div>
- </div>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/cancel_publish_order/create.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/cancel_publish_order/index.html b/app/admin/view/cancel_publish_order/index.html
deleted file mode 100644
index f6133ab..0000000
--- a/app/admin/view/cancel_publish_order/index.html
+++ /dev/null
@@ -1,105 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="取消刊登审核" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">取消刊登审核</span>
- </div>
- </template>
- <el-form :model="searchdata" label-width="auto">
- <el-input v-model="searchdata.platform_goods_code" placeholder="平台商品编码" style="width: 200px; margin-right: 10px;"></el-input>
- <el-input v-model="searchdata.supplier_goods_code" placeholder="供应商商品编码" style="width: 200px"></el-input>
-  <el-button type="success" icon="Search" @click="searchPublishOrder()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="PublishOrderList" v-loading="loading.loading" border style="width: 100%;position: relative;z-index: 0 !important;" ref="tableRef">
- <el-table-column align="center" prop="picture" label="图片" show-overflow-tooltip width="100">
- <template #default="scope">
- <el-image :src="scope.row.picture" style="width: 60px; height: 60px;" hide-on-click-modal="true" :z-index="99" :preview-src-list="[scope.row.picture]" />
- </template>
-
- </el-table-column>
- <el-table-column prop="publish_order_code" label="刊登单号" show-overflow-tooltip width="150"></el-table-column>
- <el-table-column prop="public_type" label="刊登类型" show-overflow-tooltip width="180">
- <template #default="scope">
- <template v-if="scope.row.public_type == 1">无属性</template>
- <template v-else-if="scope.row.public_type == 2">多属性</template>
- </template>
- </el-table-column>
- <el-table-column prop="goods_title_cn" label="中文标题"></el-table-column>
- <el-table-column prop="supplier_goods_code" label="供应商商品编码" width="150"></el-table-column>
-
- <el-table-column label="取消刊登原因" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.reason_id == 1">不合作</template>
- <template v-else-if="scope.row.reason_id == 2">商品更新换代</template>
- <template v-else-if="scope.row.reason_id == 3">商品侵权</template>
- <template v-else-if="scope.row.reason_id == 4">商品收货问题严重</template>
- <template v-else-if="scope.row.reason_id == 5">其他</template>
- </template>
- </el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.status == 0">未审核</template>
- <template v-else-if="scope.row.status == 1">已审核</template>
- </template>
- </el-table-column>
- <el-table-column prop="remark" label="备注" show-overflow-tooltip width="180"></el-table-column>
- <el-table-column prop="add_time" label="创建时间" width="180"></el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" @click="editPublishOrder(scope.row.id,scope.row.cancel_id)">审核</el-button>
-
-
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/cancel_publish_order/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/category/index.html b/app/admin/view/category/index.html
deleted file mode 100644
index a050d9e..0000000
--- a/app/admin/view/category/index.html
+++ /dev/null
@@ -1,264 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script>
- $(function () {
- $(".el-sub-menu__title").hover(function () {
- $(this).addClass('hovercurrent');
- }, function () {
- $(this).removeClass('hovercurrent');
- });
- });
- </script>
- <style>
- .gap-4 {
- grid-gap: 1rem;
- gap: 1rem;
- }
-
- .flex-wrap {
- flex-wrap: wrap;
- }
-
- .flex {
- display: flex;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide.one.text}" two_word="{$guide.two.text}" />
- </el-header>
- <el-main>
- <div class="flex-wrap gap-4">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-card>
- <template #header>
- <div class="card-header">
- <span>平台列表</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="createPlatform(-1)">添加</el-link>
- </div>
- </template>
-
- <el-table :data="platformList" border style="width: 100%">
- <el-table-column label="平台名称" prop="docking_platform_name"></el-table-column>
- <el-table-column label="平台编码" prop="cate_code" align="center"></el-table-column>
- <el-table-column label="排序" prop="order_id" align="center" width="80"></el-table-column>
- <el-table-column label="操作选项" width="160" align="center" fixed="right">
- <template #default="scope">
- <el-button size="small" type="primary" @click="createPlatform(scope.$index)">编辑</el-button>
- <el-button size="small" @click="setOne(scope.$index)">管理下级</el-button>
- </template>
- </el-table-column>
- </el-table>
-
- </el-card>
- </el-col>
- <el-col :span="6">
- <el-card>
- <template #header>
- <div class="card-header">
- <span>一级分类列表</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="createOne(-1)">添加</el-link>
- </div>
- </template>
-
- <el-table :data="oneList" border style="width: 100%">
- <el-table-column label="一级分类名称" prop="cate_name"></el-table-column>
- <el-table-column label="一级分类编码" prop="cate_code" align="center"></el-table-column>
-
- <el-table-column label="排序" prop="order_id" align="center" width="80"></el-table-column>
- <el-table-column label="操作选项" width="160" align="center" fixed="right">
- <template #default="scope">
- <el-button size="small" type="primary" @click="createOne(scope.$index)">编辑</el-button>
- <el-button size="small" @click="setTwo(scope.$index)">管理下级</el-button>
- </template>
- </el-table-column>
- </el-table>
-
- </el-card>
- </el-col>
- <el-col :span="6">
- <el-card>
- <template #header>
- <div class="card-header">
- <span>二级分类列表</span>
- <template v-if="oneList[currOneIndex]">({{oneList[currOneIndex].cate_name}})</template>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="createTwo(-1)">添加</el-link>
- </div>
- </template>
-
- <el-table :data="twoList" border style="width: 100%">
- <el-table-column label="二级分类名称" prop="cate_name">
- <template #default="scope">
- {{scope.row.cate_name}}
- </template>
- </el-table-column>
- <el-table-column label="二级分类编码" prop="cate_code" align="center"></el-table-column>
-
- <el-table-column label="排序" prop="order_id" align="center" width="80"></el-table-column>
- <el-table-column label="操作选项" width="160" align="center" fixed="right">
- <template #default="scope">
- <el-button size="small" type="primary" @click="createTwo(scope.$index)">编辑</el-button>
- <el-button size="small" @click="setThree(scope.$index)">管理下级</el-button>
- </template>
- </el-table-column>
- </el-table>
-
- </el-card>
- </el-col>
- <el-col :span="6">
- <el-card>
- <template #header>
- <div class="card-header">
- <span>三级分类列表</span>
- <template v-if="oneList[currOneIndex]">
- ({{oneList[currOneIndex].cate_name}}
- <template v-if="twoList[currTwoIndex]">/{{twoList[currTwoIndex].cate_name}})</template>
- </template>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="createThree(-1)">添加</el-link>
- </div>
- </template>
-
- <el-table :data="threeList" border style="width: 100%">
- <el-table-column label="三级分类名称" prop="cate_name"></el-table-column>
- <el-table-column label="三级分类编码" prop="cate_code" align="center"></el-table-column>
- <el-table-column label="排序" prop="order_id" align="center" width="80"></el-table-column>
- <el-table-column label="操作选项" width="100" align="center" fixed="right">
- <template #default="scope">
- <el-button size="small" type="primary" @click="createThree(scope.$index)">编辑</el-button>
- </template>
- </el-table-column>
- </el-table>
-
- </el-card>
- </el-col>
- </el-row>
-
-
-
- </div>
- </el-main>
-
- </el-container>
- </el-container>
-
-
- <el-dialog :title="createPlatformTitle" v-model="dialogVisible.platform" :show-close="true" :before-close="platformCloseForm" width="600px">
- <el-form :rules="platformRules" ref="platformForm" :model="platformForm" label-width="150px">
- <el-form-item label="对接平台名称" prop="docking_platform_name">
- <el-input v-model="platformForm.docking_platform_name" placeholder="请输入对接平台名称" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item label="平台编码" prop="cate_code">
- <el-input v-model="platformForm.cate_code" placeholder="请输入平台编码" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item v-if="platformForm.id>0" label="排序值">
- <el-input-number v-model="platformForm.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
-
- <el-button type="primary" :loading="ifsubmit" @click="savePlatform">
- <span v-if="!ifsubmit">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="platformCloseForm">取消</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
-
- <!-- 添加一级分类 -->
-
- <el-dialog :title="createOneTitle" v-model="dialogVisible.one" :show-close="true" :before-close="oneCloseForm" width="600px">
- <el-form :rules="oneRules" ref="oneForm" :model="oneForm" label-width="100px">
- <el-form-item label="分类名称" prop="cate_name">
- <el-input v-model="oneForm.cate_name" placeholder="请输入分类名称" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item label="分类编码" prop="cate_code">
- <el-input v-model="oneForm.cate_code" placeholder="请输入分类编码" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item v-if="oneForm.id>0" label="排序值">
- <el-input-number v-model="oneForm.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
-
- <el-button type="primary" :loading="ifsubmit" @click="saveOne">
- <span v-if="!ifsubmit">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="oneCloseForm">取消</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- <!-- 添加二级分类 -->
- <el-dialog :title="createTwoTitle" v-model="dialogVisible.two" :show-close="true" :before-close="twoCloseForm" width="600px">
- <el-form :rules="twoRules" ref="twoForm" :model="twoForm" label-width="100px">
- <el-form-item label="分类名称" prop="cate_name">
- <el-input v-model="twoForm.cate_name" placeholder="请输入分类名称" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item label="分类编码" prop="cate_code">
- <el-input v-model="twoForm.cate_code" placeholder="请输入分类编码" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item v-if="twoForm.id>0" label="排序值">
- <el-input-number v-model="twoForm.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button type="primary" :loading="ifsubmit" @click="saveTwo">
- <span v-if="!ifsubmit">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="twoCloseForm">取消</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- <!-- 添加三级分类 -->
- <el-dialog :title="createThreeTitle" v-model="dialogVisible.three" :show-close="true" :before-close="threeCloseForm" width="600px">
- <el-form :rules="threeRules" ref="threeForm" :model="threeForm" label-width="100px">
- <el-form-item label="分类名称" prop="cate_name">
- <el-input v-model="threeForm.cate_name" placeholder="请输入分类名称" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item label="分类编码" prop="cate_code">
- <el-input v-model="threeForm.cate_code" placeholder="请输入分类编码" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item v-if="threeForm.id>0" label="排序值">
- <el-input-number v-model="threeForm.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button type="primary" :loading="ifsubmit" @click="saveThree">
- <span v-if="!ifsubmit">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="threeCloseForm">取消</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/category/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/country_code/index.html b/app/admin/view/country_code/index.html
deleted file mode 100644
index ed89b0d..0000000
--- a/app/admin/view/country_code/index.html
+++ /dev/null
@@ -1,218 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script>
- $(function () {
- $(".el-sub-menu__title").hover(function () {
- $(this).addClass('hovercurrent');
- }, function () {
- $(this).removeClass('hovercurrent');
- });
- });
- </script>
- <style>
- .gap-4 {
- grid-gap: 1rem;
- gap: 1rem;
- }
-
- .flex-wrap {
- flex-wrap: wrap;
- }
-
- .flex {
- display: flex;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide.one.text}" two_word="{$guide.two.text}" />
- </el-header>
- <el-main>
- <div class="flex flex-wrap gap-4">
-
- <el-card style="width: 32%">
- <template #header>
- <div class="card-header">
- <span>国家列表</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="createCountry(-1)">添加</el-link>
- </div>
- </template>
-
- <el-table :data="countryList" border style="width: 100%">
- <el-table-column label="国家名称" prop="cate_name"></el-table-column>
- <el-table-column label="国家代码" prop="cate_code" align="center" width="100"></el-table-column>
- <el-table-column label="显示/隐藏" width="100" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="显示" inactive-text="隐藏" @change="updateShow(scope.row)" />
- </template>
- </el-table-column>
- <el-table-column label="排序" prop="order_id" align="center" width="80"></el-table-column>
- <el-table-column label="操作选项" width="200" align="center">
- <template #default="scope">
- <el-button size="small" type="primary" @click="createCountry(scope.$index)">编辑</el-button>
- <el-button size="small" @click="setProvince(scope.$index)">管理省份</el-button>
- </template>
- </el-table-column>
- </el-table>
-
- </el-card>
- <el-card style="width: 32%">
- <template #header>
- <div class="card-header">
- <span>省份列表</span>
- <template v-if="countryList[currCountryIndex]">({{countryList[currCountryIndex].cate_name}})</template>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="createProvince(-1)">添加</el-link>
- </div>
- </template>
-
- <el-table :data="provinceList" border style="width: 100%">
- <el-table-column label="省份名称" prop="cate_name">
- <template #default="scope">
- {{scope.row.cate_name}}
- </template>
- </el-table-column>
- <el-table-column label="省份代码" prop="cate_code" align="center"></el-table-column>
- <el-table-column label="显示/隐藏" width="100" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="显示" inactive-text="隐藏" @change="updateShow(scope.row)" />
- </template>
- </el-table-column>
- <el-table-column label="排序" prop="order_id" align="center" width="80"></el-table-column>
- <el-table-column label="操作选项" width="200" align="center">
- <template #default="scope">
- <el-button size="small" type="primary" @click="createProvince(scope.$index)">编辑</el-button>
- <el-button size="small" @click="setCity(scope.$index)">管理城市</el-button>
- </template>
- </el-table-column>
- </el-table>
-
- </el-card>
- <el-card style="width: 32%">
- <template #header>
- <div class="card-header">
- <span>城市列表</span>
- <template v-if="countryList[currCountryIndex]">
- ({{countryList[currCountryIndex].cate_name}}
- <template v-if="provinceList[currProvinceIndex]">/{{provinceList[currProvinceIndex].cate_name}})</template>
- </template>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="createCity(-1)">添加</el-link>
- </div>
- </template>
-
- <el-table :data="cityList" border style="width: 100%">
- <el-table-column label="城市名称" prop="cate_name"></el-table-column>
- <el-table-column label="显示/隐藏" width="100" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="显示" inactive-text="隐藏" @change="updateShow(scope.row)" />
- </template>
- </el-table-column>
- <el-table-column label="排序" prop="order_id" align="center" width="80"></el-table-column>
- <el-table-column label="操作选项" width="200" align="center">
- <template #default="scope">
- <el-button size="small" type="primary" @click="createCity(scope.$index)">编辑</el-button>
- </template>
- </el-table-column>
- </el-table>
-
- </el-card>
- </div>
- </el-main>
-
- </el-container>
- </el-container>
- <!-- 添加国家 -->
-
- <el-dialog :title="createCountryTitle" v-model="dialogVisible.country" :show-close="true" :before-close="countryCloseForm" width="600px">
- <el-form :rules="countryRules" ref="countryForm" :model="countryForm" label-width="100px">
- <el-form-item label="国家名称" prop="cate_name">
- <el-input v-model="countryForm.cate_name" placeholder="请输入国家名称" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item label="国家编码" prop="cate_code">
- <el-input v-model="countryForm.cate_code" placeholder="请输入国家编码" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item v-if="countryForm.id>0" label="排序值">
- <el-input-number v-model="countryForm.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
-
- <el-button type="primary" :loading="ifsubmit" @click="saveCountry">
- <span v-if="!ifsubmit">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="countryCloseForm">取消</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- <!-- 添加省份 -->
- <el-dialog :title="createProvinceTitle" v-model="dialogVisible.province" :show-close="true" :before-close="provinceCloseForm" width="600px">
- <el-form :rules="provinceRules" ref="provinceForm" :model="provinceForm" label-width="100px">
- <el-form-item label="省份名称" prop="cate_name">
- <el-input v-model="provinceForm.cate_name" placeholder="请输入省份名称" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item label="省份编码" prop="cate_code">
- <el-input v-model="provinceForm.cate_code" placeholder="请输入省份编码" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item v-if="provinceForm.id>0" label="排序值">
- <el-input-number v-model="provinceForm.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button type="primary" :loading="ifsubmit" @click="saveProvince">
- <span v-if="!ifsubmit">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="provinceCloseForm">取消</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- <!-- 添加城市 -->
- <el-dialog :title="createCityTitle" v-model="dialogVisible.city" :show-close="true" :before-close="cityCloseForm" width="600px">
- <el-form :rules="cityRules" ref="cityForm" :model="cityForm" label-width="100px">
- <el-form-item label="城市名称" prop="cate_name">
- <el-input v-model="cityForm.cate_name" placeholder="请输入城市名称" style="width: 300px;"></el-input>
- </el-form-item>
- <el-form-item v-if="cityForm.id>0" label="排序值">
- <el-input-number v-model="cityForm.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button type="primary" :loading="ifsubmit" @click="saveCity">
- <span v-if="!ifsubmit">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="cityCloseForm">取消</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/country_code/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/currency/index.html b/app/admin/view/currency/index.html
deleted file mode 100644
index a2f9fed..0000000
--- a/app/admin/view/currency/index.html
+++ /dev/null
@@ -1,94 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="{$other.title}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">{$other.title}</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入货币编码或名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="currency_code" label="货币编码"></el-table-column>
- <el-table-column prop="currency_name" label="货币名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="货币编码">
- <el-input v-model="Add_form.currency_code" placeholder="请输入货币编码" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="货币名称">
- <el-input v-model="Add_form.currency_name" placeholder="请输入货币名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/currency/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/deliver_region/index.html b/app/admin/view/deliver_region/index.html
deleted file mode 100644
index d3f0aa5..0000000
--- a/app/admin/view/deliver_region/index.html
+++ /dev/null
@@ -1,114 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="分销区域管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">分销区域管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入分销区域编码或名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column prop="deliver_region_id" label="编号" width="80"></el-table-column>
- <el-table-column prop="region_code" label="分销区域编码"></el-table-column>
- <el-table-column prop="region_name" label="分销区域名称"></el-table-column>
- <el-table-column prop="region_currency" label="分销区域币别">
- <template #default="scope">
- {{scope.row.currency_code}} {{scope.row.region_currency}}
- </template>
- </el-table-column>
- <el-table-column prop="order_id" label="语言"></el-table-column>
- <el-table-column prop="language" label="排序">
- <template #default="scope">
- {{getCurrencyLanguage(scope.row.language)}}
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="200" :align="alignValue(300)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="分销区域编码">
- <el-input v-model="Add_form.region_code" placeholder="请输入分销区域编码" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="分销区域名称">
- <el-input v-model="Add_form.region_name" placeholder="请输入分销区域名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="选择币种">
- <el-select v-model="Add_form.currency_id" @change="setCurrency" placeholder="选择对接系统" size="large" style="width: 260px">
- <el-option v-for="item in currencyList" :key="item.id" :label="item.currency_name" :value="item.id" />
- </el-select>
- </el-form-item>
- <!-- <el-form-item label="分销区域币别">
- <el-input v-model="Add_form.region_currency" placeholder="请输入分销区域币别" style="width:260px;"></el-input>
- </el-form-item> -->
- <el-form-item label="选择对应语言">
- <el-select v-model="Add_form.language" placeholder="选择语言" size="large" style="width: 260px">
- <el-option v-for="item in languageOptions" :key="item.value" :label="item.label" :value="item.value" />
- </el-select>
- </el-form-item>
- <el-form-item v-if="Add_form.deliver_region_id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/deliver_region/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/deliver_region_logistics/index.html b/app/admin/view/deliver_region_logistics/index.html
deleted file mode 100644
index 402e94b..0000000
--- a/app/admin/view/deliver_region_logistics/index.html
+++ /dev/null
@@ -1,108 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
-<head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
-</head>
-
-<body>
-<div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="分销区域物流管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">分销区域物流管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入分销区域物流名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="region_code" label="分销区域编码"></el-table-column>
- <el-table-column prop="region_name" label="分销区域名称"></el-table-column>
- <el-table-column prop="name" label="分销区域物流名称"></el-table-column>
- <el-table-column label="是否开启">
- <template #default="scope">
- {{getIsOpen(scope.row.is_open)}}
- </template>
- </el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="150px">
- <el-form-item label="分销区域">
- <el-select v-model="Add_form.deliver_region_id" style="width:600px;" placeholder="请选择">
- <el-option v-for="deliverRegionItem in deliverRegionList" :key="deliverRegionItem.deliver_region_id" :label="deliverRegionItem.region_code+' - '+deliverRegionItem.region_name" :value="deliverRegionItem.deliver_region_id" />
- </el-select>
- </el-form-item>
-
- <el-form-item label="分销区域物流名称">
- <el-input v-model="Add_form.name" placeholder="请输入分销区域物流名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="是否开启">
- <el-switch
- v-model="Add_form.is_open"
- active-color="#13ce66"
- inactive-color="#ff4949"
- active-value="1"
- inactive-value="2">
- </el-switch>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
-</div>
-</body>
-<!-- 共用的方法 -->
-<script src="/static/vue/mixin_admin.js"></script>
-<script src="/static/admin/js/deliver_region_logistics/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/dis_platform/index.html b/app/admin/view/dis_platform/index.html
deleted file mode 100644
index 0a57cfe..0000000
--- a/app/admin/view/dis_platform/index.html
+++ /dev/null
@@ -1,87 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="分销平台管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">分销平台管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入分销平台名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="platform_name" label="分销平台名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="分销平台名称">
- <el-input v-model="Add_form.platform_name" placeholder="请输入分销平台名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/dis_platform/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goods/create.html b/app/admin/view/goods/create.html
deleted file mode 100644
index db5a101..0000000
--- a/app/admin/view/goods/create.html
+++ /dev/null
@@ -1,748 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8" />
- <include file="common:title" />
- <meta name="renderer" content="webkit" />
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0" />
- <include file="common:header" />
- <include file="common:element-plus" />
- <script src="/static/tinymce/js/tinymce/tinymce.min.js"></script>
- <style>
- /* .goods_card .el-tabs__item {
- padding: 0 50px;
- height: 50px;
- line-height: 50px;
- font-size: 16px;
- } */
-
- .goods_description .el-tabs__item {
- padding: 0 20px;
- height: 40px;
- line-height: 40px;
- font-size: 16px;
- }
-
- .goods_card>.el-tabs__header .el-tabs__item.is-active {
- color: #fff !important;
- background-color: #35aca6;
- }
- </style>
- <style>
- .crSubItem {
- margin-bottom: 20px;
- }
-
- .SubTi {
- margin-bottom: 10px;
- }
-
- .SubTi h4 {
- line-height: 30px;
- margin-right: 10px;
- font-size: 15px;
- }
-
- .subSec {
- padding: 10px 20px 0px 20px;
- background: #f9f9f9;
- border: 1px solid #e7e7e7;
- border-radius: 2px;
- }
-
- .tox .tox-edit-area::before {
- border: 0px !important;
- }
-
- .ml-3 {
- margin-left: 0.75rem;
- }
-
- .otherParameter .el-textarea__inner {
- height: 120px;
- }
-
- .num {
- font-size: 12px;
- }
- </style>
-
- <style>
- .form_submit_box {
- position: fixed;
- bottom: 0px;
- left: 250px;
- right: 0;
- text-align: center;
- padding: 35px 0;
- background-color: #fff;
- z-index: 10;
- border-top: 1px solid #e7e7e7;
- }
-
- .disdetail .el-dialog__header {
- border-bottom: 1px solid #e7e7e7;
- position: absolute;
- top: 16px;
- left: 16px;
- right: 0px;
- height: 20px;
- }
-
- .disdetail .SubTi h4 {
- font-weight: bold;
- }
-
- .disdetail .el-row {
- height: 30px;
- line-height: 30px;
- margin-bottom: 20px;
- }
-
- .el-tabs__new-tab {
- margin: 10px 10px 10px 10px;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <input type="hidden" id="goods_id" value="{$other['id']}" />
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="商品审核" />
- </el-header>
- <el-main style="position: relative;">
- <el-card style="width:100%;margin-bottom: 103px;">
- <template #header>
- <div class="card-header">
- <span data-i18n="thirdpartystock_management">商品审核</span>
- </div>
- </template>
- <div style="max-width:100%;">
- <el-card v-loading="loading.goodsDisInfo" style="max-width:100%;">
- <template #header>商品基本信息</template>
-
- <el-form label-width="150px" label-position="left" ref="form">
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="商品分类">
- <template v-for="(item,index) in catelist">
- {{item.docking_platform_name}}>{{item.first_cate_name}}> {{item.second_cate_name}} > {{item.three_cate_name}}<br>
- </template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="供应商商品编码">
- {{goodsDisInfo.supplier_goods_code}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品仓库模式">
- <template v-if="goodsDisInfo.warehouse_mode==1">自建仓</template>
-
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="对接系统">
- <template v-if="goodsDisInfo.docking_way==0">无</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="定价方式">
- <template v-if="goodsDisInfo.price_method==1">自主定价</template>
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="货运属性">
- {{goodsDisInfo.attr_name}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="品牌">
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品用途">
- {{goodsDisInfo.goods_purpose}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="销售形式">
- {{goodsDisInfo.sales_form}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="是否侵权">
- <template v-if="goodsDisInfo.is_tort==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="是否停购">
- <template v-if="goodsDisInfo.is_stop_buy==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="负责人">
- {{goodsDisInfo.recommend_man}}
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- </el-card>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="分销区域">
- <el-table :data="disAreaList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="分销区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="one_shipment" label="销售模式"></el-table-column>
- <el-table-column prop="one_shipment" label="配送方式">
- <template #default="scope">
- <template v-if="scope.row.distribution_area_id.dis_model==1">海外仓配送</template>
- </template>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="分销库存">
- <el-table :data="disStockList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="供应商仓库"></el-table-column>
- <!-- <el-table-column prop="docking_code" label="平台仓库"></el-table-column> -->
- <el-table-column prop="supplier_stock_amount" label="供应商库存量"></el-table-column>
- <el-table-column prop="platform_stock_amount" label="平台库存量"></el-table-column>
- <!-- <el-table-column prop="one_shipment" label="平台库存量同步供应商库存量"></el-table-column>
- <el-table-column prop="one_shipment" label="税号"></el-table-column> -->
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="代发价格">
- <el-table :data="disPriceList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="product_name_cn" label="供应商物流产品"></el-table-column>
- <el-table-column label="平台物流产品">Standard Shipping</el-table-column>
- <el-table-column prop="supply_price" label="供货单价"></el-table-column>
- <el-table-column label="平台运费">0.00</el-table-column>
- <el-table-column prop="dis_price" label="分销售价"></el-table-column>
- <el-table-column prop="distribution_area_id" label="币别">
- <template #default="scope">{{scope.row.distribution_area_id.dis_currency}}</template>
- </el-table-column>
- <el-table-column prop="take_effect_time" label="价格生效时间"></el-table-column>
- <el-table-column prop="package_goods_amount" label="包裹可含商品数量"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="退货地址">
- <el-table :data="disReturnGoodsList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域" width="80">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="退货仓库" width="150"></el-table-column>
- <el-table-column label="退货地址">
- <template #default="scope">
- {{scope.row.stock_address}}
- {{scope.row.stock_city}}
- {{scope.row.stock_province}}
- {{scope.row.stock_country_id}}
- {{scope.row.stock_post_code}}
- </template>
- </el-table-column>
-
- <el-table-column prop="receive_man" label="联系人" width="180"></el-table-column>
- <el-table-column prop="tel" label="联系电话" width="150"></el-table-column>
- </el-table>
- </el-tab-pane>
- </el-tabs>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="商品描述">
- <el-tabs type="border-card" class="goods_card" style="margin-top: 20px;">
- <el-tab-pane label="英文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_en}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_en">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_en"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- <el-tab-pane label="中文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_cn}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_cn">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_cn"></div>
- </el-form-item>
- </el-form>
-
- </el-tab-pane>
- </el-tabs>
- </el-tab-pane>
- <el-tab-pane label="规格参数">
- <el-form label-width="150px" label-position="left" ref="form" :model="goodsSpecForm" label-width="100px">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>净规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(英寸)">
- {{goodsDisInfo.goodsSpecInfo.goods_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(英寸)">
- {{goodsDisInfo.goodsSpecInfo.goods_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(英寸)">
- {{goodsDisInfo.goodsSpecInfo.goods_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(镑)">
- {{goodsDisInfo.goodsSpecInfo.goods_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>包装规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(英寸)">
- {{goodsDisInfo.goodsSpecInfo.spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(英寸)">
- {{goodsDisInfo.goodsSpecInfo.spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(英寸)">
- {{goodsDisInfo.goodsSpecInfo.spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(镑)">
- {{goodsDisInfo.goodsSpecInfo.spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>装箱规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(英寸)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(英寸)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(英寸)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(镑)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="箱率">
- {{goodsDisInfo.goodsSpecInfo.box_pcs}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
-
- </el-tab-pane>
- <el-tab-pane label="商品属性">
- <el-card style="max-width:100%;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">默认属性</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>采购参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="出厂价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.factory_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="分销价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.distribution_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="采购周期(天)">
- {{goodsDisInfo.goodsAttributeInfo.procurement_cycle}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
-
- <div class="crSubItem">
- <div class="SubTi">
- <h4>商品识别码</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="MPN">
- {{goodsDisInfo.goodsAttributeInfo.mpn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="JAN">
- {{goodsDisInfo.goodsAttributeInfo.jan}}
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="GTIN(UPC)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_upc}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="GTIN(ISBN)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_isbn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="ISBN(EAN)">
- {{goodsDisInfo.goodsAttributeInfo.isbn_ean}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>面料/材料</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="主材质">
- {{goodsDisInfo.goodsAttributeInfo.material_main}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质一">
- {{goodsDisInfo.goodsAttributeInfo.material_one}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质二">
- {{goodsDisInfo.goodsAttributeInfo.material_two}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="次材质三">
- <template v-for="material_three_item in goodsDisInfo.goodsAttributeInfo.material_three">
- {{material_three_item}};
- </template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="详细材质">
- {{goodsDisInfo.goodsAttributeInfo.material_detailed}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem otherParameter">
- <div class="SubTi">
- <h4>其它参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="参考链接">
- {{goodsDisInfo.goodsAttributeInfo.reference_link}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="包装内含">
- {{goodsDisInfo.goodsAttributeInfo.packaging_contains}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="产品卖点">
- {{goodsDisInfo.goodsAttributeInfo.selling_points}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <div class="grid-content">
- <el-form-item label="售后配件">
- <template v-if="goodsDisInfo.goodsAttributeInfo.after_sales_parts==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>电池参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="电池型号">
- {{goodsDisInfo.goodsAttributeInfo.battery_type}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池电压(V)">
- {{goodsDisInfo.goodsAttributeInfo.battery_voltage}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池容量(mAh)">
- {{goodsDisInfo.goodsAttributeInfo.battery_capacity}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top:20px;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">扩展属性</span>
- </div>
- </template>
-
- <el-row :gutter="20" v-for="(AttributExtendItem,index) in goodsDisInfo.goodsAttributExtendList">
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="属性名称">
- {{AttributExtendItem.define_attribute_name}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="16">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="属性值">
- {{AttributExtendItem.define_attribute_value}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </el-card>
- </el-tab-pane>
- <el-tab-pane label="零售限价">
- <el-table :data="goodsDisInfo.goodsRetailPriceLimitList" border style="width: 100%" :stripe="true">
- <el-table-column label="价格类型" width="180">
- <template #default="scope">
- <template v-if="scope.row.price_type==1">日常价</template>
- <template v-else-if="scope.row.price_type==2">活动价</template>
- </template>
- </el-table-column>
- <el-table-column label="销售国家">
- <template #default="scope">
- {{scope.row.sale_country_code}}
- </template>
- </el-table-column>
- <el-table-column label="销售平台">
- <template #default="scope">
- {{scope.row.sales_platform}}
- </template>
- </el-table-column>
- <el-table-column label="币别">
- <template #default="scope">
- {{scope.row.currency}}
- </template>
- </el-table-column>
- <el-table-column label="最低零售价">
- <template #default="scope">
- {{scope.row.min_retail_price}}
- </template>
- </el-table-column>
- <el-table-column label="生效时间">
- <template #default="scope">
- {{scope.row.start_time}}
- </template>
- </el-table-column>
- <el-table-column label="失效时间">
- <template #default="scope">
- {{scope.row.end_time}}
- </template>
- </el-table-column>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品标签">
- <el-table :data="goodsDisInfo.goodsLabelList" border style="width: 100%" :stripe="true">
- <el-table-column prop="label_type" label="标签类型" width="280"></el-table-column>
- <el-table-column prop="goods_label" label="商品标签"></el-table-column>
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="限制分销平台">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-form-item label="是否限制分销平台">
- <template v-if="goodsDisInfo.is_limit_dis_platform==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-table v-if="goodsDisInfo.is_limit_dis_platform==1" :data="goodsDisInfo.goodsLimitDisPlatformList" border style="width: 100%" :stripe="true">
- <el-table-column prop="platform_name" label="限制分销平台"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品图片">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-button :type="pictureStatuslist[0]==true?'primary':''" @click="setPictureStatus(0)">全部(<span class="num">{{goodsPictureCount.type0??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[1]==true?'primary':''" @click="setPictureStatus(1)">原图(<span class="num">{{goodsPictureCount.type1??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[2]==true?'primary':''" @click="setPictureStatus(2)">普修图(<span
- class="num">{{goodsPictureCount.type2??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[3]==true?'primary':''" @click="setPictureStatus(3)">精修图(<span
- class="num">{{goodsPictureCount.type3??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[4]==true?'primary':''" @click="setPictureStatus(4)">主图(<span class="num">{{goodsPictureCount.type4??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[5]==true?'primary':''" @click="setPictureStatus(5)">包装图(<span
- class="num">{{goodsPictureCount.type5??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[6]==true?'primary':''" @click="setPictureStatus(6)">图片尺寸1000(<span
- class="num">{{goodsPictureCount.type6??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[7]==true?'primary':''" @click="setPictureStatus(7)">图片尺寸1600(<span
- class="num">{{goodsPictureCount.type7??0}}</span>)</el-button>
- </div>
- </el-col>
- </el-row>
- <div>
- <el-image v-for="(img,index) in goodsPictureList" style="width: 100px; height: 100px" :src="img.url" @click="previewPictureCard(img)" :fit="fit" />
- </div>
-
- </el-tab-pane>
- </el-tabs>
- </div>
-
-
-
-
-
- </el-card>
- <div class="form_submit_box">
- <el-button type="success" @click="reviewGoods(1)">通过审核(商品审核)</el-Button>
- <el-button type="danger" @click="showReviewGoods()">不通过审核(商品审核)</el-button>
- </div>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog v-model="dialogVisible_Picture">
- <img w-full :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
-
- <el-dialog v-model="dialogVisible_reason" style="position: relative;width: 600px;">
- <template #header>
- {{set_nopass_reason_title}}
- </template>
- <el-form label-width="150px" label-position="left" ref="form">
- <el-form-item label="不通过理由">
- <el-input v-model="review_comments" maxlength="30" style="width: 90%" placeholder="请填写不通过理由" type="textarea" show-word-limit />
- </el-form-item>
- <el-form-item>
- <el-button type="danger" @click="reviewGoods(2)">确定不通过</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
-
-
-
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goods/create.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goods/index.html b/app/admin/view/goods/index.html
deleted file mode 100644
index 043ddc3..0000000
--- a/app/admin/view/goods/index.html
+++ /dev/null
@@ -1,119 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="商品审核" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">商品审核</span>
- </div>
- </template>
- <el-form :model="searchdata" label-width="auto">
- <el-input v-model="searchdata.platform_goods_code" placeholder="平台商品编码" style="width: 200px; margin-right: 10px;"></el-input>
- <el-input v-model="searchdata.supplier_goods_code" placeholder="供应商商品编码" style="width: 200px"></el-input>
-  <el-button type="success" icon="Search" @click="searchPublishOrder()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="goodsList" v-loading="loading.loading" border style="width: 100%;position: relative;z-index: 0 !important;">
-
- <el-table-column align="center" prop="picture" label="图片" show-overflow-tooltip width="180">
- <template #default="scope">
- <el-image :src="scope.row.picture" style="width: 60px; height: 60px;" hide-on-click-modal="true" :z-index="99" :preview-src-list="[scope.row.picture]" />
- </template>
- </el-table-column>
- <el-table-column label="是否显示官网" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'is_show')" v-model="scope.row.is_show" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="是" inactive-text="否" />
- </template>
- </el-table-column>
- <el-table-column prop="goods_title_cn" label="商品中文名称"></el-table-column>
- <el-table-column label="发布状态" width="150" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.publish_status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1" :inactive-value="0" inline-prompt
- active-text="已发布" inactive-text="未发布" disabled />
- </template>
- </el-table-column>
- <el-table-column label="分销状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.whether_dis==1">已分销</template>
- <template v-else>未分销</template>
- </template>
- </el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.status == 0">待提交</template>
- <template v-else-if="scope.row.status == 1">审核通过</template>
- <template v-else-if="scope.row.status == 2">审核中</template>
- <template v-else-if="scope.row.status == 3">审核不通过</template>
- </template>
- </el-table-column>
- <el-table-column prop="review_comments" label="审核意见" show-overflow-tooltip width="180"></el-table-column>
- <el-table-column prop="add_time" label="创建时间" width="180"></el-table-column>
- <el-table-column label="操作选项" fixed="right" width="120" align="center">
- <template #default="scope">
- <el-button v-if="scope.row.status==2" type="primary" @click="editGoods(scope.row.id)">审核</el-button>
- <el-button v-if="scope.row.status==1" type="danger" @click="showReviewGoods(scope.$index)">下架</el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog v-model="dialogVisible_reason" style="position: relative;width: 600px;">
- <template #header>
- {{set_nopass_reason_title}}
- </template>
- <el-form label-width="150px" label-position="left" ref="form">
- <el-form-item label="下架理由">
- <el-input v-model="review_comments" maxlength="30" style="width: 90%" placeholder="请填写下架理由" type="textarea" show-word-limit />
- </el-form-item>
- <el-form-item>
- <el-button type="danger" @click="reviewGoods(2)">确定下架</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goods/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goods_brand/index.html b/app/admin/view/goods_brand/index.html
deleted file mode 100644
index 47b70e7..0000000
--- a/app/admin/view/goods_brand/index.html
+++ /dev/null
@@ -1,174 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide['one']['text']}" two_word="{$guide['two']['text']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span data-i18n="goods_brand_management">{$other['title']}</span>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchData.kw" placeholder="请输入关键词" style="width: 300px"></el-input>
-  
- <el-button type="success" icon="Search" @click="getGoodsBrandList()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="goodsBrandList" v-loading="loading" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column prop="brand_name" label="品牌名称"></el-table-column>
- <el-table-column prop="brand_type" label="品牌类型" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.brand_type==1">
- <span data-i18n="brand_type_1">非自有品牌</span>
- </template>
- <template v-else>
- <span data-i18n="brand_type_2">自有品牌</span>
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="need_filings" label="是否需要备案" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.need_filings==1">
- <span data-i18n="need_filings_1">是</span>
- </template>
- <template v-else>
- <span data-i18n="need_filings_0">否</span>
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="real_name" label="审核状态" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">已审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="info">未通过审核</el-tag></template>
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.status==0?false:true" @click="showBrand(scope.row)">审核</el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchData.page" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchData.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog title="品牌信息" width="1200px" align-center="true" class="icon-dialog" v-model="dialogBrand" :before-close="closeForm" append-to-body>
- <el-card style="width: 100%">
- <el-form label-width="auto">
- <el-form-item label="品牌名称:">
- {{brandInfo.brand_name}}
- </el-form-item>
- <el-form-item label="品牌类型:">
- <template v-if="brandInfo.brand_type==1">
- <span data-i18n="brand_type_1">非自有品牌</span>
- </template>
- <template v-else>
- <span data-i18n="brand_type_2">自有品牌</span>
- </template>
- </el-form-item>
- <el-form-item label="是否需要备案:">
- <template v-if="brandInfo.need_filings==1">
- <span data-i18n="need_filings_1">是</span>
- </template>
- <template v-else>
- <span data-i18n="need_filings_0">否</span>
- </template>
- </el-form-item>
- <el-form-item label="品牌介绍">
- {{brandInfo.brand_desc}}
- </el-form-item>
- <el-form-item label="品牌LOGO">
- <template v-if="brandInfo.brand_logo">
- <img :src="brandInfo.brand_logo" @click="previewPictureCard(brandInfo.brand_logo)" :zoom-rate="1.2" :max-scale="7" :min-scale="0.2"
- style="width: 100px;height: 100px;" />
- </template>
- </el-form-item>
- </el-form></el-card>
-
- <br />
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span>品牌证书</span>
- </div>
- </template>
- <el-table :data="brandCertList" v-loading="loading_brand_cert" border style="width: 100%" :stripe="true">
- <el-table-column prop="title" label="文件名称" align="center">
- <template #default="scope">
- <el-link :href="scope.row.filename" target="_blank" type="success">{{ scope.row.title }}</el-link>
- </template>
- </el-table-column>
- <el-table-column prop="filesize" label="文件大小" align="center"></el-table-column>
- </el-table>
- </el-card>
- <br />
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span>备案范围</span>
- </div>
- </template>
- <el-table :data="goodsBrandFilingsList" border style="width: 100%" :stripe="true">
- <el-table-column prop="country" label="销售国家" align="center"></el-table-column>
- <el-table-column prop="platform_name" label="销售平台" align="center"></el-table-column>
- <el-table-column prop="amount" label="店铺数量上限" align="center"></el-table-column>
- </el-table>
- </el-card>
- <br />
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span>授权协议</span>
- </div>
- </template>
- <el-table :data="brandAgreementList" v-loading="loading_brand_agreement" border style="width: 100%" :stripe="true">
- <el-table-column prop="title" label="文件名称" align="center">
- <template #default="scope">
- <el-link :href="scope.row.filename" target="_blank" type="success">{{ scope.row.title }}</el-link>
- </template>
- </el-table-column>
- <el-table-column prop="filesize" label="文件大小" align="center"></el-table-column>
- </el-table>
- </el-card>
- <el-row>
- <el-col :span="24" style="text-align: center;margin:30px 0px;">
- <el-button type="success" @click="reviewGoodsBrand(1)">通过审核</el-Button>
- <el-button type="danger" @click="reviewGoodsBrand(2)">不通过审核</el-button>
- </el-col>
- </el-row>
- </el-dialog>
- <el-dialog v-model="dialogVisible_Picture">
- <img w-full :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goods_brand/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goods_freight_attr/index.html b/app/admin/view/goods_freight_attr/index.html
deleted file mode 100644
index 0371fb6..0000000
--- a/app/admin/view/goods_freight_attr/index.html
+++ /dev/null
@@ -1,92 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="货运属性管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">货运属性管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入货运属性名称或属性代码" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="attr_code" label="货运属性代码" width="180"></el-table-column>
- <el-table-column prop="attr_name" label="货运属性名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="200" :align="alignValue(200)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="货运属性代码">
- <el-input v-model="Add_form.attr_code" placeholder="请输入属性代码" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="货运属性名称">
- <el-input v-model="Add_form.attr_name" placeholder="请输入属性名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <!-- <el-input v-model="Add_form.order_id" placeholder="请输入排序" style="width:260px;"></el-input> -->
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goods_freight_attr/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goods_material/index.html b/app/admin/view/goods_material/index.html
deleted file mode 100644
index 0159b3a..0000000
--- a/app/admin/view/goods_material/index.html
+++ /dev/null
@@ -1,87 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="材质管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">材质管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入材质名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="material_name" label="材质名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="材质名称">
- <el-input v-model="Add_form.material_name" placeholder="请输入材质名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goods_material/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goods_purpose/index.html b/app/admin/view/goods_purpose/index.html
deleted file mode 100644
index 4731b7b..0000000
--- a/app/admin/view/goods_purpose/index.html
+++ /dev/null
@@ -1,87 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="商品用途管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">商品用途管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入商品用途名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="purpose_name" label="商品用途名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="商品用途名称">
- <el-input v-model="Add_form.purpose_name" placeholder="请输入商品用途名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goods_purpose/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goodskd/create.html b/app/admin/view/goodskd/create.html
deleted file mode 100644
index 7fe78a6..0000000
--- a/app/admin/view/goodskd/create.html
+++ /dev/null
@@ -1,735 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8" />
- <include file="common:title" />
- <meta name="renderer" content="webkit" />
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0" />
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- .goods_description .el-tabs__item {
- padding: 0 20px;
- height: 40px;
- line-height: 40px;
- font-size: 16px;
- }
-
- .goods_card>.el-tabs__header .el-tabs__item.is-active {
- color: #fff !important;
- background-color: #35aca6;
- }
- </style>
- <style>
- .crSubItem {
- margin-bottom: 20px;
- }
-
- .SubTi {
- margin-bottom: 10px;
- }
-
- .SubTi h4 {
- line-height: 30px;
- margin-right: 10px;
- font-size: 15px;
- }
-
- .subSec {
- padding: 10px 20px 0px 20px;
- background: #f9f9f9;
- border: 1px solid #e7e7e7;
- border-radius: 2px;
- }
-
- .tox .tox-edit-area::before {
- border: 0px !important;
- }
-
- .ml-3 {
- margin-left: 0.75rem;
- }
-
- .otherParameter .el-textarea__inner {
- height: 120px;
- }
-
- .num {
- font-size: 12px;
- }
- </style>
-
- <style>
- .form_submit_box {
- position: fixed;
- bottom: 0px;
- left: 250px;
- right: 0;
- text-align: center;
- padding: 35px 0;
- background-color: #fff;
- z-index: 10;
- border-top: 1px solid #e7e7e7;
- }
-
- .disdetail .el-dialog__header {
- border-bottom: 1px solid #e7e7e7;
- position: absolute;
- top: 16px;
- left: 16px;
- right: 0px;
- height: 20px;
- }
-
- .disdetail .SubTi h4 {
- font-weight: bold;
- }
-
- .disdetail .el-row {
- height: 30px;
- line-height: 30px;
- margin-bottom: 20px;
- }
-
- .el-tabs__new-tab {
- margin: 10px 10px 10px 10px;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <input type="hidden" id="goods_id" value="{$other['id']}" />
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="商品刊登审核" />
- </el-header>
- <el-main style="position: relative;">
- <el-card style="width:100%;margin-bottom: 103px;">
- <template #header>
- <div class="card-header">
- <span data-i18n="thirdpartystock_management">商品刊登审核</span>
- </div>
- </template>
- <div style="max-width:100%;">
- <el-card v-loading="loading.goodsDisInfo" style="max-width:100%;">
- <template #header>商品基本信息</template>
-
- <el-form label-width="150px" label-position="left" ref="form">
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="商品分类">
- <template v-for="(item,index) in catelist">
- {{item.docking_platform_name}}>{{item.first_cate_name}}> {{item.second_cate_name}} > {{item.three_cate_name}}<br>
- </template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="供应商商品编码">
- {{goodsDisInfo.supplier_goods_code}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品仓库模式">
- <template v-if="goodsDisInfo.warehouse_mode==1">自建仓</template>
-
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="对接系统">
- <template v-if="goodsDisInfo.docking_way==0">无</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="定价方式">
- <template v-if="goodsDisInfo.price_method==1">自主定价</template>
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="货运属性">
- {{goodsDisInfo.attr_name}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="品牌">
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品用途">
- {{goodsDisInfo.goods_purpose}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="销售形式">
- {{goodsDisInfo.sales_form}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="是否侵权">
- <template v-if="goodsDisInfo.is_tort==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="是否停购">
- <template v-if="goodsDisInfo.is_stop_buy==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="负责人">
- {{goodsDisInfo.recommend_man}}
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- </el-card>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="分销区域">
- <el-table :data="disAreaList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="分销区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="one_shipment" label="销售模式"></el-table-column>
- <el-table-column prop="one_shipment" label="配送方式">
- <template #default="scope">
- <template v-if="scope.row.distribution_area_id.dis_model==1">海外仓配送</template>
- </template>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="分销库存">
- <el-table :data="disStockList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="供应商仓库"></el-table-column>
- <!-- <el-table-column prop="docking_code" label="平台仓库"></el-table-column> -->
- <el-table-column prop="supplier_stock_amount" label="供应商库存量"></el-table-column>
- <el-table-column prop="platform_stock_amount" label="平台库存量"></el-table-column>
- <!-- <el-table-column prop="one_shipment" label="平台库存量同步供应商库存量"></el-table-column>
- <el-table-column prop="one_shipment" label="税号"></el-table-column> -->
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="代发价格">
- <el-table :data="disPriceList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="product_name_cn" label="供应商物流产品"></el-table-column>
- <el-table-column label="平台物流产品">Standard Shipping</el-table-column>
- <el-table-column prop="supply_price" label="供货单价"></el-table-column>
- <el-table-column label="平台运费">0.00</el-table-column>
- <el-table-column prop="dis_price" label="分销售价"></el-table-column>
- <el-table-column prop="distribution_area_id" label="币别">
- <template #default="scope">{{scope.row.distribution_area_id.dis_currency}}</template>
- </el-table-column>
- <el-table-column prop="take_effect_time" label="价格生效时间"></el-table-column>
- <el-table-column prop="package_goods_amount" label="包裹可含商品数量"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="退货地址">
- <el-table :data="disReturnGoodsList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域" width="80">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="退货仓库" width="150"></el-table-column>
- <el-table-column label="退货地址">
- <template #default="scope">
- {{scope.row.stock_address}}
- {{scope.row.stock_city}}
- {{scope.row.stock_province}}
- {{scope.row.stock_country_id}}
- {{scope.row.stock_post_code}}
- </template>
- </el-table-column>
-
- <el-table-column prop="receive_man" label="联系人" width="180"></el-table-column>
- <el-table-column prop="tel" label="联系电话" width="150"></el-table-column>
- </el-table>
- </el-tab-pane>
- </el-tabs>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="商品描述">
- <el-tabs type="border-card" class="goods_card" style="margin-top: 20px;">
- <el-tab-pane label="英文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_en}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_en">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_en"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- <el-tab-pane label="中文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_cn}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_cn">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_cn"></div>
- </el-form-item>
- </el-form>
-
- </el-tab-pane>
- </el-tabs>
- </el-tab-pane>
- <el-tab-pane label="规格参数">
- <el-form label-width="150px" label-position="left" ref="form" :model="goodsSpecForm" label-width="100px">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>净规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(英寸)">
- {{goodsDisInfo.goodsSpecInfo.goods_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(英寸)">
- {{goodsDisInfo.goodsSpecInfo.goods_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(英寸)">
- {{goodsDisInfo.goodsSpecInfo.goods_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(镑)">
- {{goodsDisInfo.goodsSpecInfo.goods_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>包装规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(英寸)">
- {{goodsDisInfo.goodsSpecInfo.spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(英寸)">
- {{goodsDisInfo.goodsSpecInfo.spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(英寸)">
- {{goodsDisInfo.goodsSpecInfo.spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(镑)">
- {{goodsDisInfo.goodsSpecInfo.spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>装箱规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(英寸)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(英寸)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(英寸)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(镑)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="箱率">
- {{goodsDisInfo.goodsSpecInfo.box_pcs}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
-
- </el-tab-pane>
- <el-tab-pane label="商品属性">
- <el-card style="max-width:100%;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">默认属性</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>采购参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="出厂价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.factory_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="分销价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.distribution_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="采购周期(天)">
- {{goodsDisInfo.goodsAttributeInfo.procurement_cycle}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
-
- <div class="crSubItem">
- <div class="SubTi">
- <h4>商品识别码</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="MPN">
- {{goodsDisInfo.goodsAttributeInfo.mpn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="JAN">
- {{goodsDisInfo.goodsAttributeInfo.jan}}
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="GTIN(UPC)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_upc}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="GTIN(ISBN)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_isbn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="ISBN(EAN)">
- {{goodsDisInfo.goodsAttributeInfo.isbn_ean}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>面料/材料</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="主材质">
- {{goodsDisInfo.goodsAttributeInfo.material_main}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质一">
- {{goodsDisInfo.goodsAttributeInfo.material_one}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质二">
- {{goodsDisInfo.goodsAttributeInfo.material_two}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="次材质三">
- <template v-for="material_three_item in goodsDisInfo.goodsAttributeInfo.material_three">
- {{material_three_item}};
- </template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="详细材质">
- {{goodsDisInfo.goodsAttributeInfo.material_detailed}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem otherParameter">
- <div class="SubTi">
- <h4>其它参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="参考链接">
- {{goodsDisInfo.goodsAttributeInfo.reference_link}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="包装内含">
- {{goodsDisInfo.goodsAttributeInfo.packaging_contains}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="产品卖点">
- {{goodsDisInfo.goodsAttributeInfo.selling_points}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <div class="grid-content">
- <el-form-item label="售后配件">
- <template v-if="goodsDisInfo.goodsAttributeInfo.after_sales_parts==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>电池参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="电池型号">
- {{goodsDisInfo.goodsAttributeInfo.battery_type}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池电压(V)">
- {{goodsDisInfo.goodsAttributeInfo.battery_voltage}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池容量(mAh)">
- {{goodsDisInfo.goodsAttributeInfo.battery_capacity}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top:20px;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">扩展属性</span>
- </div>
- </template>
-
- <el-row :gutter="20" v-for="(AttributExtendItem,index) in goodsDisInfo.goodsAttributExtendList">
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="属性名称">
- {{AttributExtendItem.define_attribute_name}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="16">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="属性值">
- {{AttributExtendItem.define_attribute_value}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </el-card>
- </el-tab-pane>
- <el-tab-pane label="零售限价">
- <el-table :data="goodsDisInfo.goodsRetailPriceLimitList" border style="width: 100%" :stripe="true">
- <el-table-column label="价格类型" width="180">
- <template #default="scope">
- <template v-if="scope.row.price_type==1">日常价</template>
- <template v-else-if="scope.row.price_type==2">活动价</template>
- </template>
- </el-table-column>
- <el-table-column label="销售国家">
- <template #default="scope">
- {{scope.row.sale_country_code}}
- </template>
- </el-table-column>
- <el-table-column label="销售平台">
- <template #default="scope">
- {{scope.row.sales_platform}}
- </template>
- </el-table-column>
- <el-table-column label="币别">
- <template #default="scope">
- {{scope.row.currency}}
- </template>
- </el-table-column>
- <el-table-column label="最低零售价">
- <template #default="scope">
- {{scope.row.min_retail_price}}
- </template>
- </el-table-column>
- <el-table-column label="生效时间">
- <template #default="scope">
- {{scope.row.start_time}}
- </template>
- </el-table-column>
- <el-table-column label="失效时间">
- <template #default="scope">
- {{scope.row.end_time}}
- </template>
- </el-table-column>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品标签">
- <el-table :data="goodsDisInfo.goodsLabelList" border style="width: 100%" :stripe="true">
- <el-table-column prop="label_type" label="标签类型" width="280"></el-table-column>
- <el-table-column prop="goods_label" label="商品标签"></el-table-column>
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="限制分销平台">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-form-item label="是否限制分销平台">
- <template v-if="goodsDisInfo.is_limit_dis_platform==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-table v-if="goodsDisInfo.is_limit_dis_platform==1" :data="goodsDisInfo.goodsLimitDisPlatformList" border style="width: 100%" :stripe="true">
- <el-table-column prop="platform_name" label="限制分销平台"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品图片">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-button :type="pictureStatuslist[0]==true?'primary':''" @click="setPictureStatus(0)">全部(<span class="num">{{goodsPictureCount.type0??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[1]==true?'primary':''" @click="setPictureStatus(1)">原图(<span class="num">{{goodsPictureCount.type1??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[2]==true?'primary':''" @click="setPictureStatus(2)">普修图(<span
- class="num">{{goodsPictureCount.type2??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[3]==true?'primary':''" @click="setPictureStatus(3)">精修图(<span
- class="num">{{goodsPictureCount.type3??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[4]==true?'primary':''" @click="setPictureStatus(4)">主图(<span class="num">{{goodsPictureCount.type4??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[5]==true?'primary':''" @click="setPictureStatus(5)">包装图(<span
- class="num">{{goodsPictureCount.type5??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[6]==true?'primary':''" @click="setPictureStatus(6)">图片尺寸1000(<span
- class="num">{{goodsPictureCount.type6??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[7]==true?'primary':''" @click="setPictureStatus(7)">图片尺寸1600(<span
- class="num">{{goodsPictureCount.type7??0}}</span>)</el-button>
- </div>
- </el-col>
- </el-row>
- <div>
- <el-image v-for="(img,index) in goodsPictureList" style="width: 100px; height: 100px" :src="img.url" @click="previewPictureCard(img)" :fit="fit" />
- </div>
-
- </el-tab-pane>
- </el-tabs>
- </div>
- </el-card>
- <div class="form_submit_box">
- <el-button type="success" @click="reviewGoodsKD(1)">通过审核(刊登)</el-Button>
- <el-button type="danger" @click="showReviewGoodsKD()">不通过审核(刊登)</el-button>
- </div>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog v-model="dialogVisible_Picture">
- <img w-full :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
-
- <el-dialog v-model="dialogVisible_reason" style="position: relative;width: 600px;">
- <template #header>
- {{set_nopass_reason_title}}
- </template>
- <el-form label-width="150px" label-position="left" ref="form">
- <el-form-item label="不通过理由">
- <el-input v-model="kd_review_comments" maxlength="30" style="width: 90%" placeholder="请填写不通过理由" type="textarea" show-word-limit />
- </el-form-item>
- <el-form-item>
- <el-button type="danger" @click="reviewGoodsKD(2)">确定不通过</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
-
-
-
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goodskd/create.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/goodskd/index.html b/app/admin/view/goodskd/index.html
deleted file mode 100644
index c032996..0000000
--- a/app/admin/view/goodskd/index.html
+++ /dev/null
@@ -1,98 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="刊登审核" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">刊登审核</span>
- </div>
- </template>
- <el-form :model="searchdata" label-width="auto">
- <el-input v-model="searchdata.platform_goods_code" placeholder="平台商品编码" style="width: 200px; margin-right: 10px;"></el-input>
- <el-input v-model="searchdata.supplier_goods_code" placeholder="供应商商品编码" style="width: 200px"></el-input>
-  <el-button type="success" icon="Search" @click="searchPublishOrder()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="PublishOrderList" v-loading="loading.loading" border style="width: 100%;position: relative;z-index: 0 !important;" ref="tableRef">
- <el-table-column align="center" prop="picture" label="图片" show-overflow-tooltip width="100">
- <template #default="scope">
- <el-image :src="scope.row.picture" style="width: 60px; height: 60px;" hide-on-click-modal="true" :z-index="99" :preview-src-list="[scope.row.picture]" />
- </template>
-
- </el-table-column>
- <el-table-column prop="goods_title_cn" label="中文标题"></el-table-column>
- <el-table-column prop="supplier_goods_code" label="供应商商品编码" width="150"></el-table-column>
-
- <el-table-column label="刊登状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.kd_publish_status == 0">
- <el-button type="danger">未刊登</el-button>
- </template>
- <template v-else-if="scope.row.kd_publish_status == 1"><el-button type="success">已刊登</el-button></template>
- </template>
- </el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.kd_audit_status == 0">待提交</template>
- <template v-else-if="scope.row.kd_audit_status == 1">审核通过</template>
- <template v-else-if="scope.row.kd_audit_status == 2">审核中</template>
- <template v-else-if="scope.row.kd_audit_status == 3">审核不通过</template>
- </template>
- </el-table-column>
-
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" @click="editGoodsKD(scope.row.id)">审核</el-button>
-
-
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/goodskd/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/language/index.html b/app/admin/view/language/index.html
deleted file mode 100644
index 60df060..0000000
--- a/app/admin/view/language/index.html
+++ /dev/null
@@ -1,116 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <link rel="stylesheet" href="/static/admin/css/image_viewer.css" media="all">
- <style>
- .previewImage {
- width: 100%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="{$other['title']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">{$other['title']}</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入语言名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="name" label="语言名称(中文)"></el-table-column>
- <el-table-column prop="name_loc" label="语言名称"></el-table-column>
- <el-table-column prop="symbol" label="语言标识"></el-table-column>
- <el-table-column prop="trans_symbol" label="翻译标识"></el-table-column>
-
- <el-table-column label="是否启用" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'is_show')" v-model="scope.row.is_show" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="是" inactive-text="否" />
- </template>
- </el-table-column>
-
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="900px">
- <el-form ref="Add_form" :rules="rules" :model="Add_form" label-width="180px">
-
- <el-form-item label="语言名称(中文)" prop="name">
- <el-input v-model="Add_form.name" clearable placeholder="请输入语言名称(中文)" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="语言名称" prop="name_loc">
- <el-input v-model="Add_form.name_loc" clearable placeholder="请输入语言名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="语言标识" prop="symbol">
- <el-input v-model="Add_form.symbol" clearable placeholder="请输入语言标识" :disabled="Add_form.id>0" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="翻译标识" prop="trans_symbol">
- <el-input v-model="Add_form.trans_symbol" clearable placeholder="请输入翻译标识" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/language/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/language_pag/index.html b/app/admin/view/language_pag/index.html
deleted file mode 100644
index bac1dfc..0000000
--- a/app/admin/view/language_pag/index.html
+++ /dev/null
@@ -1,151 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <link rel="stylesheet" href="/static/admin/css/image_viewer.css" media="all">
- <style>
- .previewImage {
- width: 100%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="{$other['title']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">{$other['title']}</span>
-  
- </div>
- </template>
- <el-form label-width="auto">
- <!-- <el-select v-model="searchdata.platform_type" style="width: 180px;margin-right: 10px;" @change="index">
- <el-option v-for="item in platformTypeList" :key="item.id" :label="item.name" :value="item.id" />
- </el-select> -->
- <el-input v-model="searchdata.type" placeholder="请输入类型" style="width: 180px;margin-right: 10px;" clearable></el-input>
- <el-input v-model="searchdata.name" placeholder="请输入名称" style="width: 180px;margin-right: 10px;" clearable></el-input>
- <el-input v-model="searchdata.value" placeholder="请输入值" style="width: 180px;" clearable></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button> <el-button type="warning" @click="createJson()">生成json文件</el-button>
- </el-form>
- <br />
- <el-tabs v-model="langs.symbol" @tab-change="handChange">
- <el-tab-pane v-for="(item, index) in langs.list" :key="index" :label="item.name" :name="item.symbol" lazy></el-tab-pane>
- </el-tabs>
- <el-button type="primary" icon="Plus" @click="handleAdd" v-if="active==0">新增</el-button>
- <el-button @click="handleSync" v-if="active!=0">
- 同步
- </el-button>
- <el-button @click="handleTrans" v-if="active!=0">
- 翻译
- </el-button>
- <el-table :data="list" v-loading="loading.list" border style="width: 100%;margin-top: 10px;" :stripe="true" ref="tableRef">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="type" label="类型" width="150">
- <template #default="scope">
- <div @click="copyToClipboard(scope.row,1)">
- {{scope.row.type}}
- </div>
- </template>
- </el-table-column>
- <el-table-column prop="name" label="名称" width="300">
- <template #default="scope">
- <div @click="copyToClipboard(scope.row,2)">
- {{scope.row.name}}
- </div>
- </template>
- </el-table-column>
- <el-table-column prop="symbol" label="引用方式">
- <template #default="scope">
- <div @click="copyToClipboard(scope.row,3)">
- t('{{scope.row.type}}.{{scope.row.name}}','{{scope.row.from_value}}')
- </div>
- </template>
- </el-table-column>
- <el-table-column prop="from_value" label="源语言" v-if="active!=0">
- <template #default="scope">
- <div @click="copyToClipboard(scope.row,4)">
- {{scope.row.from_value}}
- </div>
- </template>
- </el-table-column>
- <el-table-column prop="value" label="值">
- <template #default="scope">
- <div @click="copyToClipboard(scope.row,4)">
- {{scope.row.value}}
- </div>
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="150" :align="alignValue(200)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- <el-button type="warning" @click="clearValue(scope.$index)">清空值</el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="800px">
- <el-form ref="Add_form" :rules="rules" :model="Add_form" label-width="120px">
- <!-- <el-form-item label="平台类型" prop="platform_type">
- <el-select v-model="Add_form.platform_type" style="width: 180px;margin-right: 10px;" @change="index">
- <el-option v-for="item in platformTypeList" :key="item.id" :label="item.name" :value="item.id" />
- </el-select>
- </el-form-item> -->
- <el-form-item label="类型" prop="type">
- <el-input v-model="Add_form.type" clearable placeholder="请输入类型" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="名称" prop="name">
- <el-input v-model="Add_form.name" clearable placeholder="请输入名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="值" prop="value">
- <el-input v-model="Add_form.value" clearable placeholder="请输入值" style="width:260px;"></el-input>
- <div class="form-tips" v-if="mode == 'edit'" style="margin-left: 10px;">源语言:{{Add_form.from_value}}</div>
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading.add" type="primary" @click="submit">
- <span v-if="!loading.add">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/language_pag/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/logistics_vas/index.html b/app/admin/view/logistics_vas/index.html
deleted file mode 100644
index 695d23c..0000000
--- a/app/admin/view/logistics_vas/index.html
+++ /dev/null
@@ -1,91 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="增值服务管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">增值服务管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入增值服务名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="vas_code" label="增值服务编码"></el-table-column>
- <el-table-column prop="vas_name" label="增值服务名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="增值服务编码">
- <el-input v-model="Add_form.vas_code" placeholder="请输入增值服务编码" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="增值服务名称">
- <el-input v-model="Add_form.vas_name" placeholder="请输入增值服务名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/logistics_vas/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/menu/index.html b/app/admin/view/menu/index.html
deleted file mode 100644
index a14221c..0000000
--- a/app/admin/view/menu/index.html
+++ /dev/null
@@ -1,108 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script>
- $(function () {
- $(".el-sub-menu__title").hover(function () {
- $(this).addClass('hovercurrent');
- }, function () {
- $(this).removeClass('hovercurrent');
- });
- });
- </script>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="后台菜单管理" two_word="{$other.title}" />
- </el-header>
- <el-main>
- <el-card>
- <template #header>
- <div class="card-header">
- <span>{$other.title}</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add()">添加</el-link>
- </div>
- </template>
- <el-table :data="list" :tree-props="{children: 'children'}" row-key="id" default-expand-all border style="width: 100%" ref="tableRef">
- <el-table-column label="菜单名称" prop="title"></el-table-column>
- <el-table-column label="菜单索引" prop="menu_index"></el-table-column>
- <el-table-column label="连接地址" prop="menu_url"></el-table-column>
- <el-table-column label="Icon图标" prop="menu_icon" align="center"></el-table-column>
- <el-table-column label="显示/隐藏" width="120" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.show_menu" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1" :inactive-value="0"
- inline-prompt active-text="显示" inactive-text="隐藏" @change="updateShowMenu(scope.row)" />
- </template>
- </el-table-column>
- <el-table-column label="排序" prop="order_id" align="center" width="100"></el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="150" :align="alignValue(200)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Edit(scope.row)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- </el-card>
- </el-main>
-
- </el-container>
- </el-container>
- <!-- 添加一级菜单 -->
- <el-dialog :title="Add_title" v-model="dialogVisible_menu" :show-close="true" width="30%">
- <el-tabs v-model="languages.symbol" @tab-change="handChange">
- <el-tab-pane v-for="(item, index) in languages.list" :key="index" :label="item.name" :name="item.symbol" lazy></el-tab-pane>
- </el-tabs>
- <el-form ref="form" :model="Add_form" label-width="100px">
- <el-form-item label="所属父类">
- <el-select v-model="Add_form.father_id" placeholder="选择上级菜单" filterable clearable style="width: 80%;">
- <el-option label="--" :value="0"></el-option>
- <el-option v-for="(item,i) in list" :key="i" :label="item.title" :value="item.id"></el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="菜单名称">
- <el-input v-model="Add_form.title" placeholder="请输入菜单名称" style="width: 80%;"></el-input>
- <el-button type="primary" size="small" style="margin-left: 10px;" v-if="active!=0" @click="handTranslation('title')" :loading="loadingTran">翻译</el-button>
- </el-form-item>
- <el-form-item label="菜单索引">
- <el-input v-model="Add_form.menu_index" placeholder="请输入菜单索引" style="width: 80%;"></el-input>
- </el-form-item>
- <el-form-item label="Icon图标">
- <el-input v-model="Add_form.menu_icon" placeholder="请输入icon" style="width: 80%;"></el-input>
- </el-form-item>
- <el-form-item label="连接地址">
- <el-input v-model="Add_form.menu_url" placeholder="请输入连接地址" style="width: 80%;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button type="primary" :loading="ifsubmit" @click="saveMenu">保存</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/menu/index.js"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/message/create.html b/app/admin/view/message/create.html
deleted file mode 100644
index a485859..0000000
--- a/app/admin/view/message/create.html
+++ /dev/null
@@ -1,121 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script src="/static/tinymce/js/tinymce/tinymce.min.js"></script>
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="消息管理" two_word="编辑商城消息 " />
- </el-header>
- <el-main>
- <input type="hidden" id="message_id" value="{$other.id}">
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">{{message_title}}</span>
- </div>
- </template>
- <el-form :rules="messageRules" ref="Form" :model="messageInfo" :before-close="closeForm" label-width="150px">
- <el-form-item label="消息标题" prop="title">
- <el-input v-model="messageInfo.title"></el-input>
- </el-form-item>
- <el-form-item label="消息类别" prop="title">
- <el-select v-model="messageInfo.msg_category_id" placeholder="请选择消息分类" @change="handleCategory" style="width: 220px">
- <el-option v-for="item in msgCategoryList[0]" :key="item.id" :label="item.title" :value="item.id" />
- </el-select>
- <el-select v-model="messageInfo.sub_msg_category_id" placeholder="请选择二级消息分类" clearable style="width: 220px; margin-left: 10px;">
- <el-option label="默认消息类别" :value="0"></el-option>
- <el-option v-if="curr_category_id>0" v-for="item in msgCategoryList[curr_category_id]" :key="item.id" :label="item.title" :value="item.id" />
- </el-select>
- </el-form-item>
- <el-form-item label="发布时间" prop="publish_time">
- <el-date-picker value-format="YYYY-MM-DD hh:mm:ss" type="datetime" v-model="messageInfo.publish_time" clearable
- placeholder="请输入发布时间"></el-date-picker>
- </el-form-item>
- <el-form-item label="消息内容" prop="content">
- <textarea class="textarea" :id="'tinymce-content'" v-model="messageInfo.content" style="height: 300px;"></textarea>
- </el-form-item>
- <template v-if="messageInfo.id && messageInfo.id>0">
- <el-form-item label="消息附件">
-
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
-
- <el-upload ref="upload" class="upload-demo" :show-file-list="false" :http-request="uploadAttachment" action="" :auto-upload="true">
- <template #trigger>
- <el-link type="primary" class="header_add_btn" icon="upload-filled" :underline="false" href="javascript:void(0)">
- <span>上传</span>
- </el-link>
- </template>
- </el-upload>
- </div>
- </template>
- <el-table :data="attachmentList" v-loading="loading_attachment" border style="width: 100%" :stripe="true">
- <el-table-column prop="title" label="文件名称" align="center">
- <template #default="scope">
- <el-link :href="scope.row.filename" target="_blank" type="success">{{ scope.row.title }}</el-link>
- </template>
- </el-table-column>
- <el-table-column prop="filesize" label="文件大小" align="center"></el-table-column>
- <el-table-column label="操作选项" align="center">
- <template #default="scope">
- <el-button icon="delete" type="danger" @click="deleteAttachment(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- </el-card>
- </el-form-item>
- </template>
- <el-form-item>
- <el-button type="primary" :loading="loading.addLoading" @click="submitForm">
- <span v-if="!loading.addLoading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="backForm">返回</el-button>
-
- </el-form-item>
-
- </el-form>
- </el-card>
-
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/message/create.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/message/index.html b/app/admin/view/message/index.html
deleted file mode 100644
index 7444cd9..0000000
--- a/app/admin/view/message/index.html
+++ /dev/null
@@ -1,89 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script src="/static/tinymce/js/tinymce/tinymce.min.js"></script>
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="消息管理" two_word="商城消息 " />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">商城消息</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" @click="create()" href="javascript:void(0)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form :model="searchdata" label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入标题" style="width: 200px; margin-right: 10px;" clearable></el-input>
-  <el-button type="success" icon="Search" @click="getMessageList()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="messageList" v-loading="loading.loading" border style="width: 100%;position: relative;z-index: 0 !important;" ref="tableRef">
- <el-table-column prop="title" label="消息标题" show-overflow-tooltip align="left"></el-table-column>
- <el-table-column prop="catetitle" label="消息类别" show-overflow-tooltip width="180" align="center"></el-table-column>
-
- <el-table-column prop="publish_time" label="发布时间" width="180" align="center"></el-table-column>
- <el-table-column prop="views" label="浏览次数" width="180" align="center"></el-table-column>
- <el-table-column label="发布状态" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'status')" v-model="scope.row.status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc"
- :active-value="1" :inactive-value="0" inline-prompt active-text="发布" inactive-text="草稿" />
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="200" :align="alignValue(300)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="editMessage(scope.row.id)"></el-button>
- <el-button icon="delete" type="danger" @click="deleteMessage(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
-
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/message/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/msg_category/index.html b/app/admin/view/msg_category/index.html
deleted file mode 100644
index dd6f3d7..0000000
--- a/app/admin/view/msg_category/index.html
+++ /dev/null
@@ -1,94 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script>
- $(function () {
- $(".el-sub-menu__title").hover(function () {
- $(this).addClass('hovercurrent');
- }, function () {
- $(this).removeClass('hovercurrent');
- });
- });
- </script>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边消息分类 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide.one.text}" two_word="{$guide.two.text}" />
- </el-header>
- <el-main>
- <el-card>
- <template #header>
- <div class="card-header">
- <span>{$other.title}</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add()">添加</el-link>
- </div>
- </template>
- <el-table :data="list" :tree-props="{children: 'children'}" row-key="id" default-expand-all border style="width: 100%" ref="tableRef">
- <el-table-column label="消息分类名称" prop="title"></el-table-column>
-
- <el-table-column label="显示/隐藏" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.ifshow" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1" :inactive-value="0"
- inline-prompt active-text="显示" inactive-text="隐藏" @change="updateShowCate(scope.row)" />
- </template>
- </el-table-column>
- <el-table-column label="排序" prop="order_id" align="center"></el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Edit(scope.row)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- </el-card>
- </el-main>
-
- </el-container>
- </el-container>
- <!-- 添加一级消息分类 -->
- <el-dialog :title="Add_title" v-model="dialogVisible" :show-close="true" width="30%">
- <el-form ref="form" :model="Add_form" label-width="100px">
-
- <el-form-item label="所属父类">
- <el-select v-model="Add_form.father_id" placeholder="选择上级消息分类" filterable clearable style="width: 90%;">
- <el-option label="顶级分类" :value="0"></el-option>
- <el-option v-for="(item,i) in list" :key="i" :label="item.title" :value="item.id"></el-option>
- </el-select>
- </el-form-item>
- <el-form-item label="消息分类名称">
- <el-input v-model="Add_form.title" placeholder="请输入消息分类名称" style="width: 90%;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button type="primary" :loading="ifsubmit" @click="saveCate">保存</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/msg_category/index.js"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/notice/create.html b/app/admin/view/notice/create.html
deleted file mode 100644
index b7f78b9..0000000
--- a/app/admin/view/notice/create.html
+++ /dev/null
@@ -1,109 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script src="/static/tinymce/js/tinymce/tinymce.min.js"></script>
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="消息管理" two_word="编辑商城公告 " />
- </el-header>
- <el-main>
- <input type="hidden" id="notice_id" value="{$other.id}">
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">{{notice_title}}</span>
- </div>
- </template>
- <el-form :rules="noticeRules" ref="Form" :model="noticeInfo" :before-close="closeForm" label-width="150px">
- <el-form-item label="公告标题" prop="title">
- <el-input v-model="noticeInfo.title"></el-input>
- </el-form-item>
- <el-form-item label="发布时间" prop="publish_time">
- <el-date-picker value-format="YYYY-MM-DD hh:mm:ss" type="datetime" v-model="noticeInfo.publish_time" clearable
- placeholder="请输入发布时间"></el-date-picker>
- </el-form-item>
- <el-form-item label="公告内容" prop="content">
- <textarea class="textarea" :id="'tinymce-content'" v-model="noticeInfo.content" style="height: 300px;"></textarea>
- </el-form-item>
- <template v-if="noticeInfo.id && noticeInfo.id>0">
- <el-form-item label="公告附件">
-
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
-
- <el-upload ref="upload" class="upload-demo" :show-file-list="false" :http-request="uploadAttachment" action="" :auto-upload="true">
- <template #trigger>
- <el-link type="primary" class="header_add_btn" icon="upload-filled" :underline="false" href="javascript:void(0)">
- <span>上传</span>
- </el-link>
- </template>
- </el-upload>
- </div>
- </template>
- <el-table :data="attachmentList" v-loading="loading_attachment" border style="width: 100%" :stripe="true">
- <el-table-column prop="title" label="文件名称" align="center">
- <template #default="scope">
- <el-link :href="scope.row.filename" target="_blank" type="success">{{ scope.row.title }}</el-link>
- </template>
- </el-table-column>
- <el-table-column prop="filesize" label="文件大小" align="center"></el-table-column>
- <el-table-column label="操作选项" align="center">
- <template #default="scope">
- <el-button icon="delete" type="danger" @click="deleteAttachment(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- </el-card>
- </el-form-item>
- </template>
- <el-form-item>
- <el-button type="primary" :loading="loading.addLoading" @click="submitForm">
- <span v-if="!loading.addLoading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button><el-button @click="backForm">返回</el-button>
-
- </el-form-item>
-
- </el-form>
- </el-card>
-
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/notice/create.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/notice/index.html b/app/admin/view/notice/index.html
deleted file mode 100644
index d792d16..0000000
--- a/app/admin/view/notice/index.html
+++ /dev/null
@@ -1,84 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <script src="/static/tinymce/js/tinymce/tinymce.min.js"></script>
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="消息管理" two_word="商城公告 " />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">商城公告</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" @click="create()" href="javascript:void(0)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form :model="searchdata" label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入标题" style="width: 200px; margin-right: 10px;" clearable></el-input>
-  <el-button type="success" icon="Search" @click="getNoticeList()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="noticeList" v-loading="loading.loading" border style="width: 100%;position: relative;z-index: 0 !important;" ref="tableRef">
- <el-table-column prop="title" label="公告标题" show-overflow-tooltip align="left"></el-table-column>
- <el-table-column prop="publish_time" label="发布时间" width="180" align="center"></el-table-column>
- <el-table-column prop="views" label="浏览次数" width="180" align="center"></el-table-column>
- <el-table-column label="发布状态" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'status')" v-model="scope.row.status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc"
- :active-value="1" :inactive-value="0" inline-prompt active-text="发布" inactive-text="草稿" />
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="200" :align="alignValue(300)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="editNotice(scope.row.id)"></el-button>
- <el-button icon="delete" type="danger" @click="deleteNotice(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
-
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/notice/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/partner_school/index.html b/app/admin/view/partner_school/index.html
deleted file mode 100644
index 6c3bdd0..0000000
--- a/app/admin/view/partner_school/index.html
+++ /dev/null
@@ -1,87 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="合作学校管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">合作学校管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入合作学校名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="school_name" label="合作学校名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="合作学校名称">
- <el-input v-model="Add_form.school_name" placeholder="请输入合作学校名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/partner_school/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/pay_bank/index.html b/app/admin/view/pay_bank/index.html
deleted file mode 100644
index e6d070e..0000000
--- a/app/admin/view/pay_bank/index.html
+++ /dev/null
@@ -1,151 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <link rel="stylesheet" href="/static/admin/css/image_viewer.css" media="all">
- <style>
- .previewImage {
- width: 100%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="{$other['title']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">{$other['title']}</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入开户行/账户名称/账户" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="payee_name" label="开户行"></el-table-column>
- <el-table-column prop="account_name" label="账户名称"></el-table-column>
- <el-table-column prop="account" label="账户"></el-table-column>
- <el-table-column prop="img_url" label="logo">
- <template #default="scope">
- <el-image :src="scope.row.img_url" :preview-src-list="[scope.row.img_url]" style="width: 40px;height: 40px;"></el-image>
- </template>
- </el-table-column>
- <el-table-column label="线下支付" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'isoffline')" v-model="scope.row.isoffline" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc"
- :active-value="1" :inactive-value="0" inline-prompt active-text="是" inactive-text="否" />
- </template>
- </el-table-column>
- <el-table-column label="线上支付" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'isonline')" v-model="scope.row.isonline" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc"
- :active-value="1" :inactive-value="0" inline-prompt active-text="是" inactive-text="否" />
- </template>
- </el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="开户行">
- <el-input v-model="Add_form.payee_name" placeholder="请输入开户行" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="账户名称">
- <el-input v-model="Add_form.account_name" placeholder="请输入账户名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="账户">
- <el-input v-model="Add_form.account" placeholder="请输入账户" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="LOGO:" prop="img_url">
- <el-upload :show-file-list="false" list-type="picture-card" accept="png,jpg,jpeg,gif" :before-upload="handleBeforeUpload" :http-request="uploadLogo">
-
- <template #trigger>
- <template v-if="Add_form.img_url">
- <img class="el-upload-list__item-thumbnail" :src="Add_form.img_url" style="width: 100%;height: 100%;" alt="" />
- <div style="position: absolute; bottom: 0px;right: 0px;"></div>
- </template>
- <template v-else>
- <el-icon>
- <Plus />
- </el-icon>
- </template>
-
- </template>
- <template #tip>
- <div class="el-upload__tip">
- <template v-if="Add_form.img_url"><span @click="handleView" :preview-src-list="[Add_form.img_url]"
- style="color: #CB261C; cursor: pointer; margin-right: 10px;">预览</span></template>
- 限1张,格式为png、jpg、jpeg,大小不超过4M
- </div>
- </template>
- </el-upload>
- <el-dialog v-model="dialogVisible_img">
- <img w-full :src="dialogImageUrl" class="previewImage" alt="Preview Image" />
- </el-dialog>
- </el-form-item>
- <el-form-item label="备注">
- <el-input v-model="Add_form.remark" placeholder="请输入备注" type="textarea" style="width:90%;" :rows="3"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/pay_bank/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/payment_tool/index.html b/app/admin/view/payment_tool/index.html
deleted file mode 100644
index c038352..0000000
--- a/app/admin/view/payment_tool/index.html
+++ /dev/null
@@ -1,95 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="{$other.title}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">{$other.title}</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="payment_tool_id" label="编号" width="80"></el-table-column>
- <el-table-column prop="payment_tool_name" label="收款工具名称"></el-table-column>
- <el-table-column label="是否开通" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'is_show')" v-model="scope.row.is_show" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="是" inactive-text="否" />
- </template>
- </el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
- <el-form-item label="货币名称">
- <el-input v-model="Add_form.payment_tool_name" placeholder="请输入收款工具名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.payment_tool_id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/payment_tool/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/platform_logistics_product/index.html b/app/admin/view/platform_logistics_product/index.html
deleted file mode 100644
index 9880d04..0000000
--- a/app/admin/view/platform_logistics_product/index.html
+++ /dev/null
@@ -1,99 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="平台物流产品管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">平台物流产品管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入平台物流产品名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="product_name_cn" label="平台物流产品中文名称" width="180"></el-table-column>
- <el-table-column prop="product_name_en" label="平台物流产品英文名称"></el-table-column>
- <el-table-column prop="cycle_start" label="时间周期-最少天数"></el-table-column>
- <el-table-column prop="cycle_end" label="时间周期-最大天数"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="200" :align="alignValue(200)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="200px">
-
- <el-form-item label="平台物流产品中文名称">
- <el-input v-model="Add_form.product_name_cn" placeholder="请输入平台物流产品中文名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="平台物流产品英文名称">
- <el-input v-model="Add_form.product_name_en" placeholder="请输入平台物流产品英文名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="时间周期-最少天数">
- <el-input-number v-model="Add_form.cycle_start" placeholder="请输入最少天数" style="width:260px;" />
- </el-form-item>
- <el-form-item label="时间周期-最大天数">
- <el-input-number v-model="Add_form.cycle_end" placeholder="请输入最大天数" style="width:260px;" />
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" style="width:260px;" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/platform_logistics_product/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/platform_region/index.html b/app/admin/view/platform_region/index.html
deleted file mode 100644
index a68b942..0000000
--- a/app/admin/view/platform_region/index.html
+++ /dev/null
@@ -1,87 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="平台所属区域管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">平台所属区域管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入区域名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="region_name" label="区域名称"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="区域名称">
- <el-input v-model="Add_form.region_name" placeholder="请输入区域名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/platform_region/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/publish_order/create.html b/app/admin/view/publish_order/create.html
deleted file mode 100644
index b38ae46..0000000
--- a/app/admin/view/publish_order/create.html
+++ /dev/null
@@ -1,840 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8" />
- <include file="common:title" />
- <meta name="renderer" content="webkit" />
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0" />
- <include file="common:header" />
- <include file="common:element-plus" />
- <script src="/static/tinymce/js/tinymce/tinymce.min.js"></script>
- <style>
- /* .goods_card .el-tabs__item {
- padding: 0 50px;
- height: 50px;
- line-height: 50px;
- font-size: 16px;
- } */
-
- .goods_description .el-tabs__item {
- padding: 0 20px;
- height: 40px;
- line-height: 40px;
- font-size: 16px;
- }
-
- .goods_card>.el-tabs__header .el-tabs__item.is-active {
- color: #fff !important;
- background-color: #35aca6;
- }
- </style>
- <style>
- .crSubItem {
- margin-bottom: 20px;
- }
-
- .SubTi {
- margin-bottom: 10px;
- }
-
- .SubTi h4 {
- line-height: 30px;
- margin-right: 10px;
- font-size: 15px;
- }
-
- .subSec {
- padding: 10px 20px 0px 20px;
- background: #f9f9f9;
- border: 1px solid #e7e7e7;
- border-radius: 2px;
- }
-
- .tox .tox-edit-area::before {
- border: 0px !important;
- }
-
- .ml-3 {
- margin-left: 0.75rem;
- }
-
- .otherParameter .el-textarea__inner {
- height: 120px;
- }
-
- .num {
- font-size: 12px;
- }
- </style>
-
- <style>
- .form_submit_box {
- position: fixed;
- bottom: 0px;
- left: 250px;
- right: 0;
- text-align: center;
- padding: 35px 0;
- background-color: #fff;
- z-index: 10;
- border-top: 1px solid #e7e7e7;
- }
-
- .disdetail .el-dialog__header {
- border-bottom: 1px solid #e7e7e7;
- position: absolute;
- top: 16px;
- left: 16px;
- right: 0px;
- height: 20px;
- }
-
- .disdetail .SubTi h4 {
- font-weight: bold;
- }
-
- .disdetail .el-row {
- height: 30px;
- line-height: 30px;
- margin-bottom: 20px;
- }
-
- .el-tabs__new-tab {
- margin: 10px 10px 10px 10px;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <input type="hidden" id="publish_order_id" value="{$other['id']}" />
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="刊登" two_word="审核刊登单" />
- </el-header>
- <el-main style="position: relative;">
- <el-card style="width:100%;margin-bottom: 103px;">
- <template #header>
- <div class="card-header">
- <span data-i18n="thirdpartystock_management">审核刊登单</span>
- </div>
- </template>
- <el-card style="max-width:100%;" v-loading="loading.loading">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">基础信息</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="刊登类型">
- <el-radio-group v-model="publishOrderInfoForm.public_type" disabled class="ml-4">
- <el-radio :value="1">无属性</el-radio>
- </el-radio-group>
- </el-form-item>
- <template v-if="publishOrderInfoForm.supplier_goods_code!==null">
- <el-form-item label="选择分类">
- <el-cascader v-model="publishOrderInfoForm.cate_code" disabled :options="categoryList" clearable style="width:350px;" @change="handleCategoryChange" />
- </el-form-item>
-
- <el-form-item label="品牌名称">
- <el-select v-model="publishOrderInfoForm.brand_code" disabled placeholder="请选择品牌名称" style="width:350px;">
- <el-option v-for="freight_attr_item in goodsBrandList" :key="freight_attr_item.attr_code" :label="freight_attr_item.attr_name"
- :value="freight_attr_item.attr_code" />
- </el-select>
- </template>
- </el-form-item>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top: 20px;" v-if="publishOrderInfoForm.public_type==1">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">商品信息</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="供应商商品编码">
- <el-input v-model="publishOrderInfoForm.supplier_goods_code" @change="getGoodsInfo" placeholder="请输入供应商商品编码" style="width:350px;"
- :disabled="publishOrderInfoForm.istemp===1?true:false"></el-input>
- </el-form-item>
-
- <el-form-item label="商品名称">
- {{publishOrderInfoForm.goods_title_cn}}
- </el-form-item>
-
- <el-form-item label="分销信息">
- <el-button type="success" @click="showGoodsDisInfo()">查看</el-button>
- </el-form-item>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top: 20px;" v-loading="loading.loading">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">描述信息</span>
- </div>
- </template>
- <el-tabs class="goods_description" type="border-card">
- <el-tab-pane label="英文">
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="标题" :rules="[{required:true}]">
- {{publishOrderInfoForm.goods_title_en}}
- </el-form-item>
- <el-form-item label="描述">
- <div v-html="publishOrderInfoForm.goods_desc_en"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- <el-tab-pane label="中文">
- <el-form label-width="150px" label-position="left" ref="form" :model="publishOrderInfoForm" label-width="100px">
- <el-form-item label="标题">
- {{publishOrderInfoForm.goods_title_cn}}
- </el-form-item>
- <el-form-item label="描述">
- <div v-html="publishOrderInfoForm.goods_desc_cn"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- </el-tabs>
-
- </el-card>
- <el-card style="max-width:100%;margin-top: 20px;" v-loading="loading.loading">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">通用图片</span>
- </div>
- </template>
- <el-row :gutter="20" style="margin-top: 20px;">
- <el-col :span="24">
- <div class="grid-content ep-bg-purple">
- <template v-for="(item,index) in publishOrderPictureList" :key="index">
- <el-image style="width: 100px; height: 100px" :src="item.url" :zoom-rate="1.2" :max-scale="7" :min-scale="0.2" :preview-src-list="[item.url]" />
- </template>
- </div>
- </el-col>
- </el-row>
-
- </el-card>
-
-
- </el-card>
- <div class="form_submit_box">
- <el-button type="success" @click="reviewPublishOrder(1)">通过审核(刊登)</el-Button>
- <el-button type="danger" @click="showReviewPublishOrder()">不通过审核(刊登)</el-button>
- </div>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog v-model="dialogVisible_Picture">
- <img w-full :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
-
- <el-dialog v-model="dialogVisible_reason" style="position: relative;width: 600px;">
- <template #header>
- {{set_nopass_reason_title}}
- </template>
- <el-form label-width="150px" label-position="left" ref="form">
- <el-form-item label="不通过理由">
- <el-input v-model="review_comments" maxlength="30" style="width: 90%" placeholder="请填写不通过理由" type="textarea" show-word-limit />
- </el-form-item>
- <el-form-item>
- <el-button type="danger" @click="reviewPublishOrder(2)">确定不通过</el-button>
- </el-form-item>
- </el-form>
- </el-dialog>
-
-
- <el-dialog class="disdetail" v-model="dialog.setGoodsDisInfo" :show-close="true" :close-on-click-modal="false" style="position: relative;width: 70%;">
- <template #header>
- {{set_goods_dis_info_title}}
- </template>
- <div style="max-width:100%;max-height: 850px;overflow-y: scroll;margin-top: 50px;">
- <el-card v-loading="loading.goodsDisInfo" style="max-width:100%;">
- <template #header>商品基本信息</template>
-
- <el-form label-width="150px" label-position="left" ref="form">
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="商品分类">
- {{goodsDisInfo.first_cate_name}} > {{goodsDisInfo.second_cate_name}} > {{goodsDisInfo.three_cate_name}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="供应商商品编码">
- {{goodsDisInfo.supplier_goods_code}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品仓库模式">
- <template v-if="goodsDisInfo.warehouse_mode==1">自建仓</template>
-
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="对接系统">
- <template v-if="goodsDisInfo.docking_way==0">无</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="定价方式">
- <template v-if="goodsDisInfo.price_method==1">自主定价</template>
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="货运属性">
- {{goodsDisInfo.attr_name}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="品牌">
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="商品用途">
- {{goodsDisInfo.goods_purpose}}
-
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="销售形式">
- {{goodsDisInfo.sales_form}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="8">
- <el-form-item label="是否侵权">
- <template v-if="goodsDisInfo.is_tort==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="是否停购">
- <template v-if="goodsDisInfo.is_stop_buy==0">否</template>
- <template v-else>是</template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="负责人">
- {{goodsDisInfo.recommend_man}}
- </el-form-item>
- </el-col>
- </el-row>
- </el-form>
- </el-card>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="分销区域">
- <el-table :data="disAreaList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="分销区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="one_shipment" label="销售模式"></el-table-column>
- <el-table-column prop="one_shipment" label="配送方式">
- <template #default="scope">
- <template v-if="scope.row.distribution_area_id.dis_model==1">海外仓配送</template>
- </template>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="分销库存">
- <el-table :data="disStockList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="供应商仓库"></el-table-column>
- <!-- <el-table-column prop="docking_code" label="平台仓库"></el-table-column> -->
- <el-table-column prop="supplier_stock_amount" label="供应商库存量"></el-table-column>
- <el-table-column prop="platform_stock_amount" label="平台库存量"></el-table-column>
- <!-- <el-table-column prop="one_shipment" label="平台库存量同步供应商库存量"></el-table-column>
- <el-table-column prop="one_shipment" label="税号"></el-table-column> -->
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="代发价格">
- <el-table :data="disPriceList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="product_name_cn" label="供应商物流产品"></el-table-column>
- <el-table-column label="平台物流产品">Standard Shipping</el-table-column>
- <el-table-column prop="supply_price" label="供货单价"></el-table-column>
- <el-table-column label="平台运费">0.00</el-table-column>
- <el-table-column prop="dis_price" label="分销售价"></el-table-column>
- <el-table-column prop="distribution_area_id" label="币别">
- <template #default="scope">{{scope.row.distribution_area_id.dis_currency}}</template>
- </el-table-column>
- <el-table-column prop="take_effect_time" label="价格生效时间"></el-table-column>
- <el-table-column prop="package_goods_amount" label="包裹可含商品数量"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="退货地址">
- <el-table :data="disReturnGoodsList" border style="width: 100%" :stripe="true">
- <el-table-column prop="distribution_area_id" label="区域" width="80">
- <template #default="scope">{{scope.row.distribution_area_id.region_name}}</template>
- </el-table-column>
- <el-table-column prop="third_party_stock_name" label="退货仓库" width="150"></el-table-column>
- <el-table-column label="退货地址">
- <template #default="scope">
- {{scope.row.stock_address}}
- {{scope.row.stock_city}}
- {{scope.row.stock_province}}
- {{scope.row.stock_country_id}}
- {{scope.row.stock_post_code}}
- </template>
- </el-table-column>
-
- <el-table-column prop="receive_man" label="联系人" width="180"></el-table-column>
- <el-table-column prop="tel" label="联系电话" width="150"></el-table-column>
- </el-table>
- </el-tab-pane>
- </el-tabs>
- <el-tabs type="border-card" v-loading="loading.goodsDisInfo" style="margin-top: 20px;">
- <el-tab-pane label="商品描述">
- <el-tabs type="border-card" class="goods_card" style="margin-top: 20px;">
- <el-tab-pane label="英文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_en}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_en">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_en"></div>
- </el-form-item>
- </el-form>
- </el-tab-pane>
- <el-tab-pane label="中文">
- <el-form label-width="150px" label-position="left" label-width="100px">
- <el-form-item label="标题">
- {{goodsDisInfo.goods_title_cn}}
- </el-form-item>
- <el-form-item label="关键词">
- <template v-for="keyword_item in goodsDisInfo.goods_keyword_cn">
- {{keyword_item}};
- </template>
- </el-form-item>
- <el-form-item label="首段描述">
- <div v-html="goodsDisInfo.goods_desc_cn"></div>
- </el-form-item>
- </el-form>
-
- </el-tab-pane>
- </el-tabs>
- </el-tab-pane>
- <el-tab-pane label="规格参数">
- <el-form label-width="150px" label-position="left" ref="form" :model="goodsSpecForm" label-width="100px">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>净规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(cm)">
- {{goodsDisInfo.goodsSpecInfo.goods_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(cm)">
- {{goodsDisInfo.goodsSpecInfo.goods_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(cm)">
- {{goodsDisInfo.goodsSpecInfo.goods_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(kg)">
- {{goodsDisInfo.goodsSpecInfo.goods_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>包装规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(cm)">
- {{goodsDisInfo.goodsSpecInfo.spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(cm)">
- {{goodsDisInfo.goodsSpecInfo.spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(cm)">
- {{goodsDisInfo.goodsSpecInfo.spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(kg)">
- {{goodsDisInfo.goodsSpecInfo.spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>装箱规格</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="长(cm)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_length}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="宽(cm)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_width}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="高(cm)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_height}}
- </el-form-item>
- </el-col>
- <el-col :span="6">
- <el-form-item label="重量(kg)">
- {{goodsDisInfo.goodsSpecInfo.box_spec_weight}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row :gutter="20">
- <el-col :span="6">
- <el-form-item label="箱率">
- {{goodsDisInfo.goodsSpecInfo.box_pcs}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
-
- </el-tab-pane>
- <el-tab-pane label="商品属性">
- <el-card style="max-width:100%;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">默认属性</span>
- </div>
- </template>
- <el-form label-width="150px" label-position="left">
- <div class="crSubItem">
- <div class="SubTi">
- <h4>采购参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="出厂价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.factory_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="分销价(USD)">
- {{goodsDisInfo.goodsAttributeInfo.distribution_price}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="采购周期(天)">
- {{goodsDisInfo.goodsAttributeInfo.procurement_cycle}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
-
- <div class="crSubItem">
- <div class="SubTi">
- <h4>商品识别码</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="MPN">
- {{goodsDisInfo.goodsAttributeInfo.mpn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="JAN">
- {{goodsDisInfo.goodsAttributeInfo.jan}}
- </el-form-item>
- </el-col>
-
- <el-col :span="8">
- <el-form-item label="GTIN(UPC)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_upc}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="GTIN(ISBN)">
- {{goodsDisInfo.goodsAttributeInfo.gtin_isbn}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="ISBN(EAN)">
- {{goodsDisInfo.goodsAttributeInfo.isbn_ean}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>面料/材料</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="主材质">
- {{goodsDisInfo.goodsAttributeInfo.material_main}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质一">
- {{goodsDisInfo.goodsAttributeInfo.material_one}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="次材质二">
- {{goodsDisInfo.goodsAttributeInfo.material_two}}
- </el-form-item>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="8">
- <el-form-item label="次材质三">
- <template v-for="material_three_item in goodsDisInfo.goodsAttributeInfo.material_three">
- {{material_three_item}};
- </template>
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="详细材质">
- {{goodsDisInfo.goodsAttributeInfo.material_detailed}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem otherParameter">
- <div class="SubTi">
- <h4>其它参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="参考链接">
- {{goodsDisInfo.goodsAttributeInfo.reference_link}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="包装内含">
- {{goodsDisInfo.goodsAttributeInfo.packaging_contains}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="8">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="产品卖点">
- {{goodsDisInfo.goodsAttributeInfo.selling_points}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-row>
- <el-col :span="12">
- <div class="grid-content">
- <el-form-item label="售后配件">
- <template v-if="goodsDisInfo.goodsAttributeInfo.after_sales_parts==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </div>
- </div>
- <div class="crSubItem">
- <div class="SubTi">
- <h4>电池参数</h4>
- <em></em>
- </div>
- <div class="subSec">
- <el-row>
- <el-col :span="8">
- <el-form-item label="电池型号">
- {{goodsDisInfo.goodsAttributeInfo.battery_type}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池电压(V)">
- {{goodsDisInfo.goodsAttributeInfo.battery_voltage}}
- </el-form-item>
- </el-col>
- <el-col :span="8">
- <el-form-item label="电池容量(mAh)">
- {{goodsDisInfo.goodsAttributeInfo.battery_capacity}}
- </el-form-item>
- </el-col>
- </el-row>
- </div>
- </div>
- </el-form>
- </el-card>
- <el-card style="max-width:100%;margin-top:20px;">
- <template #header>
- <div class="card-header">
- <span style="font-size:14px;font-weight:normal;">扩展属性</span>
- </div>
- </template>
-
- <el-row :gutter="20" v-for="(AttributExtendItem,index) in goodsDisInfo.goodsAttributExtendList">
- <el-col :span="8">
- <div class="grid-content">
- <el-form-item label="属性名称">
- {{AttributExtendItem.define_attribute_name}}
- </el-form-item>
- </div>
- </el-col>
- <el-col :span="16">
- <div class="grid-content ep-bg-purple">
- <el-form-item label="属性值">
- {{AttributExtendItem.define_attribute_value}}
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- </el-card>
- </el-tab-pane>
- <el-tab-pane label="零售限价">
- <el-table :data="goodsDisInfo.goodsRetailPriceLimitList" border style="width: 100%" :stripe="true">
- <el-table-column label="价格类型" width="180">
- <template #default="scope">
- <template v-if="scope.row.price_type==1">日常价</template>
- <template v-else-if="scope.row.price_type==2">活动价</template>
- </template>
- </el-table-column>
- <el-table-column label="销售国家">
- <template #default="scope">
- {{scope.row.sale_country_code}}
- </template>
- </el-table-column>
- <el-table-column label="销售平台">
- <template #default="scope">
- {{scope.row.sales_platform}}
- </template>
- </el-table-column>
- <el-table-column label="币别">
- <template #default="scope">
- {{scope.row.currency}}
- </template>
- </el-table-column>
- <el-table-column label="最低零售价">
- <template #default="scope">
- {{scope.row.min_retail_price}}
- </template>
- </el-table-column>
- <el-table-column label="生效时间">
- <template #default="scope">
- {{scope.row.start_time}}
- </template>
- </el-table-column>
- <el-table-column label="失效时间">
- <template #default="scope">
- {{scope.row.end_time}}
- </template>
- </el-table-column>
- </el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品标签">
- <el-table :data="goodsDisInfo.goodsLabelList" border style="width: 100%" :stripe="true">
- <el-table-column prop="label_type" label="标签类型" width="280"></el-table-column>
- <el-table-column prop="goods_label" label="商品标签"></el-table-column>
- </el-table>
-
- </el-tab-pane>
- <el-tab-pane label="限制分销平台">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-form-item label="是否限制分销平台">
- <template v-if="goodsDisInfo.is_limit_dis_platform==1">是</template>
- <template v-else>否</template>
- </el-form-item>
- </div>
- </el-col>
- </el-row>
- <el-table v-if="goodsDisInfo.is_limit_dis_platform==1" :data="goodsDisInfo.goodsLimitDisPlatformList" border style="width: 100%" :stripe="true">
- <el-table-column prop="platform_name" label="限制分销平台"></el-table-column>
- </el-table>
- </el-tab-pane>
- <el-tab-pane label="商品图片">
- <el-row :gutter="20">
- <el-col :span="24">
- <div class="grid-content">
- <el-button :type="pictureStatuslist[0]==true?'primary':''" @click="setPictureStatus(0)">全部(<span class="num">{{goodsPictureCount.type0??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[1]==true?'primary':''" @click="setPictureStatus(1)">原图(<span class="num">{{goodsPictureCount.type1??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[2]==true?'primary':''" @click="setPictureStatus(2)">普修图(<span class="num">{{goodsPictureCount.type2??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[3]==true?'primary':''" @click="setPictureStatus(3)">精修图(<span class="num">{{goodsPictureCount.type3??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[4]==true?'primary':''" @click="setPictureStatus(4)">主图(<span class="num">{{goodsPictureCount.type4??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[5]==true?'primary':''" @click="setPictureStatus(5)">包装图(<span class="num">{{goodsPictureCount.type5??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[6]==true?'primary':''" @click="setPictureStatus(6)">图片尺寸1000(<span class="num">{{goodsPictureCount.type6??0}}</span>)</el-button>
- <el-button :type="pictureStatuslist[7]==true?'primary':''" @click="setPictureStatus(7)">图片尺寸1600(<span class="num">{{goodsPictureCount.type7??0}}</span>)</el-button>
- </div>
- </el-col>
- </el-row>
- <div>
- <el-image v-for="(img,index) in goodsPictureList" style="width: 100px; height: 100px" :src="img.url" @click="previewPictureCard(img)" :fit="fit" />
- </div>
-
- </el-tab-pane>
- </el-tabs>
- <div style="text-align: center; margin: 20px 0px;" v-if="!loading.dis_loading">
- <el-button @click="dialog.setGoodsDisInfo=false">关闭</el-Button>
- </div>
- </div>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/publish_order/create.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/publish_order/index.html b/app/admin/view/publish_order/index.html
deleted file mode 100644
index 0f29725..0000000
--- a/app/admin/view/publish_order/index.html
+++ /dev/null
@@ -1,111 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="刊登审核" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="goods_management">刊登审核</span>
- </div>
- </template>
- <el-form :model="searchdata" label-width="auto">
- <el-input v-model="searchdata.platform_goods_code" placeholder="平台商品编码" style="width: 200px; margin-right: 10px;"></el-input>
- <el-input v-model="searchdata.supplier_goods_code" placeholder="供应商商品编码" style="width: 200px"></el-input>
-  <el-button type="success" icon="Search" @click="searchPublishOrder()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="PublishOrderList" v-loading="loading.loading" border style="width: 100%;position: relative;z-index: 0 !important;" ref="tableRef">
- <el-table-column align="center" prop="picture" label="图片" show-overflow-tooltip width="100">
- <template #default="scope">
- <el-image :src="scope.row.picture" style="width: 60px; height: 60px;" hide-on-click-modal="true" :z-index="99" :preview-src-list="[scope.row.picture]" />
- </template>
-
- </el-table-column>
- <el-table-column prop="publish_order_code" label="刊登单号" show-overflow-tooltip width="150"></el-table-column>
- <el-table-column prop="public_type" label="刊登类型" show-overflow-tooltip width="180">
- <template #default="scope">
- <template v-if="scope.row.public_type == 1">无属性</template>
- <template v-else-if="scope.row.public_type == 2">多属性</template>
- </template>
- </el-table-column>
- <el-table-column prop="goods_title_cn" label="中文标题"></el-table-column>
- <el-table-column label="刊登分类">
- <template #default="scope">
- {{scope.row.first_cate_name}}/{{scope.row.second_cate_name}}/{{scope.row.three_cate_name}}
- </template>
- </el-table-column>
- <el-table-column prop="supplier_goods_code" label="供应商商品编码" width="150"></el-table-column>
-
- <el-table-column label="刊登状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.publish_status == 0">
- <el-button type="danger">未刊登</el-button>
- </template>
- <template v-else-if="scope.row.publish_status == 1"><el-button type="success">已刊登</el-button></template>
- </template>
- </el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.audit_status == 0">待提交</template>
- <template v-else-if="scope.row.audit_status == 1">审核通过</template>
- <template v-else-if="scope.row.audit_status == 2">审核中</template>
- <template v-else-if="scope.row.audit_status == 3">审核不通过</template>
- </template>
- </el-table-column>
- <el-table-column prop="review_comments" label="审核意见" show-overflow-tooltip width="180"></el-table-column>
- <el-table-column prop="add_time" label="创建时间" width="180"></el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" @click="editPublishOrder(scope.row.id)">审核</el-button>
-
-
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/publish_order/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/remit_record/index.html b/app/admin/view/remit_record/index.html
deleted file mode 100644
index eb57bc5..0000000
--- a/app/admin/view/remit_record/index.html
+++ /dev/null
@@ -1,166 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- /* 解决图片放大时层显示问题 */
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide['one']['text']}" two_word="{$guide['two']['text']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span data-i18n="goods_brand_management">{$other['title']}</span>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchData.kw" placeholder="请输入关键词" style="width: 300px"></el-input>
-  
- <el-button type="success" icon="Search" @click="getRemitRecordList()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" v-loading="loading" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column type="index" label="编号" width="80" show-overflow-tooltip></el-table-column>
- <el-table-column prop="payee_name" label="汇款方式" show-overflow-tooltip></el-table-column>
- <el-table-column prop="account_name" label="收款账户信息" show-overflow-tooltip>
- <template #default="scope">
- {{scope.row.account_name}}<br>
- {{scope.row.account}}
-
- </template>
- </el-table-column>
- <el-table-column prop="remit_amount" label="汇款金额" width="100" show-overflow-tooltip>
- <template #default="scope">
- {{scope.row.asset_name}} {{scope.row.remit_amount}}
- </template>
- </el-table-column>
- <el-table-column prop="service_charge" label="手续费" width="100" show-overflow-tooltip>
- <template #default="scope">
- <template v-if="scope.row.status==1">{{scope.row.service_charge}}</template>
- <template v-else>-</template>
- </template>
- </el-table-column>
- <el-table-column prop="remittor_name" label="汇款人账户信息" show-overflow-tooltip>
- <template #default="scope">
- {{scope.row.remittor_name}}<br>
- {{scope.row.remittor_account}}
- </template>
- </el-table-column>
- <el-table-column prop="remit_transaction_number" label="汇款交易号" show-overflow-tooltip></el-table-column>
- <el-table-column prop="remit_date_time" label="汇款日期" align="center" show-overflow-tooltip></el-table-column>
- <el-table-column prop="add_time" label="系统时间" align="center" show-overflow-tooltip></el-table-column>
- <el-table-column prop="voucher_url" label="转账截图" width="100" show-overflow-tooltip>
- <template #default="scope">
- <el-image :src="scope.row.voucher_url" :preview-src-list="[scope.row.voucher_url]" style="width: 40px;height: 40px;"></el-image>
- </template>
- </el-table-column>
- <el-table-column prop="real_name" label="审核状态" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">已审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="info">未通过审核</el-tag></template>
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.status==0?false:true" @click="showRecord(scope.row)">审核</el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchData.page" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchData.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog title="汇款信息" width="1200px" align-center="true" class="icon-dialog" v-model="dialogRecord" :before-close="closeForm" append-to-body>
- <el-card style="width: 100%">
- <el-form :rules="assetRules" ref="assetForm" :inline-message="true" :model="assetInfo" :validate-on-rule-change="false" label-width="200px">
- <el-form-item label="汇款方式:">
- {{recordInfo.payee_name}}
- </el-form-item>
- <el-form-item label="收款账户名:">
- <p>{{recordInfo.account_name}}</p>
- </el-form-item>
- <el-form-item label="收款账户:">
- <p>{{recordInfo.account}}</p>
- </el-form-item>
- <el-form-item label="汇款币别:">
- {{recordInfo.asset_name}}
- </el-form-item>
- <el-form-item label="汇款金额:">
- {{recordInfo.asset_name}} {{recordInfo.remit_amount}}
- </el-form-item>
- <el-form-item label="汇款人账户名称:">
- {{recordInfo.remittor_name}}
- </el-form-item>
- <el-form-item label="汇款人账户:">
- {{recordInfo.remittor_account}}
- </el-form-item>
- <el-form-item label="汇款交易号:">
- {{recordInfo.remit_transaction_number}}
- </el-form-item>
- <el-form-item label="汇款日期:">
- {{recordInfo.remit_date_time}}
- </el-form-item>
- <el-form-item label="转账截图:" prop="voucher_url">
- <el-image :src="recordInfo.voucher_url" :preview-src-list="[recordInfo.voucher_url]" style="width: 50px;"></el-image>
- </el-form-item>
- <el-form-item label="系统时间:">
- {{recordInfo.add_time}}
- </el-form-item>
- <el-form-item label="手续费:" prop="service_charge">
- <el-input v-model="assetInfo.service_charge" style="width:200px;" placeholder="请输入手续费"></el-input>
- </el-form-item>
- </el-form>
- </el-card>
-
- <br />
-
- <el-row>
- <el-col :span="24" style="text-align: center;margin:30px 0px;">
- <el-button type="success" @click="passReviewRemitRecord()">到账通过审核</el-Button>
- <el-button type="danger" @click="reviewRemitRecord(2)">不通过审核</el-button>
- </el-col>
- </el-row>
- </el-dialog>
- <el-dialog v-model="dialogVisible_Picture">
- <img w-full :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/remit_record/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/return_exchange/index.html b/app/admin/view/return_exchange/index.html
deleted file mode 100644
index cafd1f7..0000000
--- a/app/admin/view/return_exchange/index.html
+++ /dev/null
@@ -1,115 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
-<head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
-</head>
-
-<body>
-<div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="退换货类型管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">退换货类型管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入退换货类型名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="name" label="退换货类型名称"></el-table-column>
- <el-table-column label="是否开启比例">
- <template #default="scope">
- {{getIsProportion(scope.row.is_proportion)}}
- </template>
- </el-table-column>
- <el-table-column label="比例">
- <template #default="scope">
- {{getProportion(scope.row)}}
- </template>
- </el-table-column>
- <el-table-column prop="note" label="比例说明"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="120px">
- <el-form-item label="退换货类型名称">
- <el-input v-model="Add_form.name" placeholder="请输入退换货类型名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="是否开启比例">
- <el-switch
- v-model="Add_form.is_proportion"
- active-color="#13ce66"
- inactive-color="#ff4949"
- active-value="1"
- inactive-value="2">
- </el-switch>
- </el-form-item>
-
- <el-form-item label="比例">
- <el-input-number v-model="Add_form.proportion" :min="1" :max="100" label="请输入比例"></el-input-number>
- </el-form-item>
-
- <el-form-item label="比例说明">
- <el-input v-model="Add_form.note" placeholder="请输入比例说明" style="width:260px;"></el-input>
- </el-form-item>
-
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
-</div>
-</body>
-<!-- 共用的方法 -->
-<script src="/static/vue/mixin_admin.js"></script>
-<script src="/static/admin/js/return_exchange/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/return_exchange_type/index.html b/app/admin/view/return_exchange_type/index.html
deleted file mode 100644
index 3ad38ab..0000000
--- a/app/admin/view/return_exchange_type/index.html
+++ /dev/null
@@ -1,91 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="退换货类型分类管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span data-i18n="logisticsProduct_management">退换货类型分类管理</span>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入退换货类型名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="name" label="退换货类型名称"></el-table-column>
- <el-table-column label="分类">
- <template #default="scope">
- {{getTypes(scope.row.type)}}
- </template>
- </el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="120px">
- <el-form-item label="退换货类型名称">
- {{Add_name}}
- </el-form-item>
-
- <el-form-item label="退换货类型分类">
- <el-select v-model="Add_form.type" placeholder="请选择退换货类型分类" style="width:260px;" multiple clearable>
- <el-option v-for="typeItem in typeList" :key="typeItem.id" :label="typeItem.name" :value="typeItem.id" />
- </el-select>
- </el-form-item>
-
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/return_exchange_type/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/sales_platform/index.html b/app/admin/view/sales_platform/index.html
deleted file mode 100644
index d66d262..0000000
--- a/app/admin/view/sales_platform/index.html
+++ /dev/null
@@ -1,146 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <link rel="stylesheet" href="/static/admin/css/image_viewer.css" media="all">
- <style>
- .previewImage {
- width: 100%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="销售平台管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">销售平台管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入销售平台名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="platform_name" label="销售平台名称"></el-table-column>
- <el-table-column label="所属区域">
- <template #default="scope">
- <template v-for="item in platformRegionList">
- <template v-if="scope.row.platform_region_id!=null&&scope.row.platform_region_id.includes(item.id)">{{item.region_name}};</template>
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="logo" label="logo">
- <template #default="scope">
- <el-image :src="scope.row.logo" :preview-src-list="[scope.row.logo]" style="width: 40px;height: 40px;"></el-image>
- </template>
- </el-table-column>
- <el-table-column label="是否显示官网" width="150" align="center">
- <template #default="scope">
- <el-switch @change="updateExt(scope.row,'is_show')" v-model="scope.row.is_show" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="是" inactive-text="否" />
- </template>
- </el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="销售平台名称">
- <el-input v-model="Add_form.platform_name" placeholder="请输入销售平台名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="所属区域" :rules="[{required:true}]">
- <el-select v-model="Add_form.platform_region_id" placeholder="请选择所属区域" style="width:350px;" clearable multiple>
- <el-option v-for="item in platformRegionList" :key="item.id" :label="item.region_name" :value="item.id" />
- </el-select>
- </el-form-item>
- <el-form-item label="LOGO:" prop="logo">
- <el-upload :show-file-list="false" list-type="picture-card" accept="png,jpg,jpeg,gif" :before-upload="handleBeforeUpload" :http-request="uploadLogo">
-
- <template #trigger>
- <template v-if="Add_form.logo">
- <img class="el-upload-list__item-thumbnail" :src="Add_form.logo" style="width: 100%;height: 100%;" alt="" />
- <div style="position: absolute; bottom: 0px;right: 0px;"></div>
- </template>
- <template v-else>
- <el-icon>
- <Plus />
- </el-icon>
- </template>
-
- </template>
- <template #tip>
- <div class="el-upload__tip">
- <template v-if="Add_form.logo"><span @click="handleView" :preview-src-list="[Add_form.logo]"
- style="color: #CB261C; cursor: pointer; margin-right: 10px;">预览</span></template>
- 限1张,格式为png、jpg、jpeg,大小不超过4M
- </div>
- </template>
- </el-upload>
- <el-dialog v-model="dialogVisible_img">
- <img w-full :src="dialogImageUrl" class="previewImage" alt="Preview Image" />
- </el-dialog>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script language="JavaScript">
- const viewPath = '{$viewPath}';
- </script>
- <script src="/static/admin/js/sales_platform/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/seller/add.html b/app/admin/view/seller/add.html
deleted file mode 100644
index b05e460..0000000
--- a/app/admin/view/seller/add.html
+++ /dev/null
@@ -1,192 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
-<head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport"
- content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
-</head>
-
-<body>
- <input type="hidden" value="{$other['id']}" id="seller_id">
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="分销商管理" two_word="{$other.title}" />
- </el-header>
- <el-main>
- <el-card>
- <template #header>
- <div class="card-header">
- <span>分销商账号信息</span>
-  
- <el-link type="primary" class="header_add_btn" icon="ArrowLeftBold" :underline="false"
- href="/admin/seller/index.html">返回</el-link>
- </div>
- </template>
- <el-form ref="useritem" :model="seller_info" label-width="100px" size="large">
- <el-form-item label="手机">
- <el-input v-model="seller_info.phone" style="width: 350px;"
- placeholder="请输入分销商手机号"></el-input>
- </el-form-item>
- <el-form-item label="密码">
- <el-input placeholder="请输入密码" v-model="seller_info.password" show-password
- style="width: 350px;"></el-input>
- <span v-if="seller_info.id" class="gray14">不修改密码保留为空</span>
- </el-form-item>
-
- <el-form-item label="账号到期时间">
- <el-date-picker v-model="seller_info.end_time" type="date" placeholder="选择日期"
- value-format="YYYY-MM-DD"></el-date-picker>
- </el-form-item>
- <el-form-item label="状态" prop="delivery">
- <el-switch v-model="seller_info.sub_ban_access" inline-prompt active-text="允许登录"
- inactive-text="禁止登录"
- style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ff4949"
- :active-value="1" :inactive-value="0"></el-switch>
- </el-form-item>
- <el-form-item>
- <el-button type="primary" @click="save_seller_info()" size="large">提交保存</el-button>
- <!-- <el-button @click="show_seller_info=false" size="large">取消</el-button> -->
- </el-form-item>
- </el-form>
- </el-card>
-<br />
- <el-card v-if="seller_id>0">
- <template #header>
- <div class="card-header">
- <span>分销商信息</span>
- </div>
- </template>
- <el-form :inline-message="true" :model="baseInfo" :validate-on-rule-change="false"
- label-width="300px" style="margin-top: 50px;">
- <el-form-item label="账户类型" prop="account_type">
- <el-radio-group v-model="baseInfo.account_type" @change="setAccountType" class="ml-4">
- <el-radio :value="1">个人</el-radio>
- <el-radio :value="2">企业</el-radio>
- </el-radio-group>
- </el-form-item>
- <el-form-item label="联系人名称">
- <el-input v-model="baseInfo.first_name" style="width:350px;"></el-input>
- </el-form-item>
- <el-form-item label="联系人姓氏">
- <el-input v-model="baseInfo.last_name" style="width:350px;"></el-input>
- </el-form-item>
- <el-form-item label="国家/省份城市" prop="cate_code">
- <el-cascader :placeholder="请选择" v-model="baseInfo.cate_code" :options="countryList"
- clearable style="width:350px;" @change="handleCountryChange" />
- </el-form-item>
-
- <el-form-item label="详细地址">
- <el-input v-model="baseInfo.detailed_address" style="width: 50%" :rows="3"
- type="textarea"></el-input>
- </el-form-item>
-
-
- <el-divider></el-divider>
- <div style="font-size: 24px;
- line-height: 33px;
- color: #333333;
- margin-bottom: 10px;margin-left: 110px;">
- 为给您提供定制化的分销服务,烦请您完善以下资料:
- </div>
- <template v-if="baseInfo.account_type==2">
- <el-form-item label="公司名称" prop="company_name">
- <el-input v-model="baseInfo.company_name" style="width:350px;"></el-input>
- </el-form-item>
- <el-form-item label="公司主营业务" prop="main_business">
- <el-radio-group v-model="baseInfo.main_business" class="ml-4">
- <template v-for="(item, index) in mainBusiness">
- <el-radio :value="item.id">{{item.name}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- <el-form-item label="公司规模" prop="company_scale">
- <el-radio-group v-model="baseInfo.company_scale" class="ml-4">
- <template v-for="(item, index) in company_scales">
- <el-radio :value="item.id">{{item.name}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- </template>
-
-
-
- <el-form-item label="电商经验" prop="ec_exp">
- <el-radio-group v-model="baseInfo.ec_exp" class="ml-4">
- <template v-for="(item, index) in ecExps">
- <el-radio :value="item.value" :key="index">{{item.label}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- <el-form-item label="主营区域(多选)" prop="main_area">
- <el-checkbox-group v-model="baseInfo.main_area" class="ml-4">
- <template v-for="(item, index) in mainAreas">
- <el-checkbox :value="item.id" :label="item.country_name" />
- </template>
- </el-checkbox-group>
- </el-form-item>
- <el-form-item label="主营平台(多选)" prop="main_dis_platform">
- <el-checkbox-group v-model="baseInfo.main_dis_platform" class="ml-4">
- <template v-for="(item, index) in disPlatformList">
- <el-checkbox :value="item.id" :label="item.platform_name" />
- </template>
- </el-checkbox-group>
- </el-form-item>
-
- <el-form-item label="运营策略" prop="operate_str">
- <el-radio-group v-model="baseInfo.operate_str" class="ml-4">
- <template v-for="(item, index) in operateStrs">
- <el-radio :value="item.id" :key="index">{{item.name}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- <el-form-item label="店铺链接" prop="store_link">
- <el-input v-model="baseInfo.store_link" style="width:350px;"
- :placeholder="请输入店铺链接"></el-input>
- </el-form-item>
- <el-form-item label="QQ:" prop="contact_qq">
- <el-input v-model="baseInfo.contact_qq" style="width:350px;"
- :placeholder="请输入QQ"></el-input>
- </el-form-item>
- <el-form-item label="请输入联系微信" prop="contact_weixin">
- <el-input v-model="baseInfo.contact_weixin" style="width:350px;"
- :placeholder="请输入联系微信"></el-input>
- </el-form-item>
- <el-form-item style="display: none;">
- <el-button type="primary" @click="submitForm">
- <span>保存</span>
- </el-button>
-
- </el-form-item>
- </el-form>
- </el-card>
- <br />
- <el-card style="display: none;">
- <template #header>
- <div class="card-header">
- <span>资质证明文件</span>
- </div>
- </template>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- </div>
-</body>
-<!-- 共用的方法 -->
-<script src="/static/vue/mixin_admin.js"></script>
-<script src="/static/vue/moment.min.js"></script>
-<script src="/static/admin/js/seller/add.js"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/seller/index.html b/app/admin/view/seller/index.html
deleted file mode 100644
index 9032616..0000000
--- a/app/admin/view/seller/index.html
+++ /dev/null
@@ -1,146 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="分销商管理" two_word="{$other.title}列表" />
- </el-header>
- <el-main>
- <el-card>
- <template #header>
- <div class="card-header">
- <span>{$other.title}列表</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="goto_edit_seller(0)">添加</el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" size="large" placeholder="可通过账号/姓名 筛选" style="width: 300px"></el-input>
-  
- <el-button type="success" size="large" icon="Search" @click="searchseller_list()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="seller_list" border style="width: 100%" ref="tableRef">
- <el-table-column label="账号(手机号)" prop="phone" width="150"></el-table-column>
- <el-table-column label="帐号类型">
- <template #default="scope">
- <span v-if="scope.row.account_type==1">个人</span>
- <span v-else-if="scope.row.account_type==2">企业</span>
- <span v-else>个人</span>
- </template>
- </el-table-column>
- <el-table-column label="用户信息" prop="certificate_name" width="200">
- <template #default="scope">
- <span>联系人:</span><br />
- {{scope.row.last_name}} {{scope.row.first_name}}
- <span v-if="scope.row.account_type==2">公司:{{scope.row.company_name}}</span>
- </template>
- </el-table-column>
- <el-table-column label="账号状态" width="150" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.sub_ban_access" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="允许登录" inactive-text="禁止登录" @change="set_ban_access(scope.$index)" />
- </template>
- </el-table-column>
- <!-- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="通过审核" inactive-text="未审核" @change="setAuditStatus(scope.$index)" />
- </template>
- </el-table-column> -->
- <el-table-column label="账号时间" width="180" align="center">
- <template #default="scope">
- 开始:{{formatDate(scope.row['start_time'])}}<br />
- 结束:{{formatDate(scope.row['end_time'])}}
- </template>
- </el-table-column>
- <el-table-column label="最近登录信息" width="180" align="center">
- <template #default="scope">
- <template v-if="scope.row.login_time>0">
- 时间:{{formatDate(scope.row['login_time'])}}
- <br />
- IP:{{scope.row['login_ip']}}
- </template>
- </template>
- </el-table-column>
- <el-table-column label="操作" fixed="right" min-width="150" :align="alignValue(200)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="goto_edit_seller(scope.row.id)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-drawer :title="seller_title" :direction="direction" v-model="show_seller_info" size="35%">
- <div id="comment_item">
- <div class="layui-row">
- <div class="layui-col-md12 caller-contar">
- <div class="caller-item">
- <el-form ref="useritem" :model="useritem" label-width="150px">
- <el-form-item label="账号">
- <template v-if="useritem.id">
- {{useritem.user_name}}
- </template>
- <template v-else>
- <el-input v-model="useritem.user_name" style="width: 330px;"></el-input>
- </template>
- </el-form-item>
- <el-form-item label="密码">
- <el-input placeholder="请输入密码" v-model="useritem.pwd" show-password style="width: 330px;"></el-input>
- <span v-if="useritem.id" class="gray14">不修改密码保留为空</span>
- </el-form-item>
- <el-form-item label="分销商名称">
- <el-input v-model="useritem.seller_name" style="width: 330px;"></el-input>
- </el-form-item>
- <el-form-item label="联系人">
- <el-input v-model="useritem.real_name" style="width: 330px;"></el-input>
- </el-form-item>
- <el-form-item label="手机号">
- <el-input v-model="useritem.phone" style="width: 330px;"></el-input>
- </el-form-item>
- <el-form-item v-if="useritem.id" label="账号到期时间">
- <el-date-picker v-model="useritem.endtime" type="date" placeholder="选择日期">
- </el-date-picker>
- </el-form-item>
-
- <el-form-item>
- <el-button type="primary" @click="save_seller">{{seller_button_txt}}</el-button>
- <el-button @click="show_seller_info=false">取消</el-button>
- </el-form-item>
- </el-form>
-
- </div>
- </div>
- </div>
- </div>
- </el-drawer>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/seller/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/seller_base_info/index.html b/app/admin/view/seller_base_info/index.html
deleted file mode 100644
index 77fc1e6..0000000
--- a/app/admin/view/seller_base_info/index.html
+++ /dev/null
@@ -1,217 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- .el-checkbox__input.is-checked+.el-checkbox__label {
- color: var(--el-checkbox-checked-text-color) !important;
- }
-
- .el-checkbox__input.is-checked .el-checkbox__inner {
- background-color: var(--el-checkbox-checked-bg-color) !important;
- border-color: var(--el-checkbox-checked-input-border-color) !important;
- }
-
- .el-checkbox__input.is-checked .el-checkbox__inner:after {
- border-color: var(--el-checkbox-checked-icon-color) !important;
- transform: rotate(45deg) scaleY(1) !important;
- }
-
- .el-radio__input.is-checked+.el-radio__label {
- color: var(--el-color-primary) !important;
- }
-
- .el-radio__input.is-checked .el-radio__inner {
- background: var(--el-color-primary) !important;
- border-color: var(--el-color-primary) !important;
- }
-
- .el-radio__input.is-disabled .el-radio__inner:after {
- background-color: var(--el-disabled-bg-color) !important;
- cursor: not-allowed;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide['one']['text']}" two_word="{$guide['two']['text']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span data-i18n="goods_brand_management">{$other['title']}</span>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchData.kw" placeholder="请输入姓名" style="width: 300px" clearable></el-input>
-  
- <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" v-loading="loading" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column prop="last_name" label="姓氏"></el-table-column>
- <el-table-column prop="first_name" label="名称"></el-table-column>
- <el-table-column prop="certificate_name" label="认证姓名"></el-table-column>
- <el-table-column prop="certificate_number" label="证件号码"></el-table-column>
-
- <el-table-column prop="real_name" label="审核状态" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">已审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="danger">待审核</el-tag></template>
- <template v-else-if="scope.row.status==3"><el-tag type="info">未通过审核</el-tag></template>
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.status==2?false:true" @click="showBaseInfo(scope.row)">审核</el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchData.page" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchData.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog title="分销商实名信息" width="1200px" align-center="true" class="icon-dialog" v-model="dialogBaseInfo" :before-close="closeForm" append-to-body>
- <el-card style="width: 100%">
- <el-form label-width="auto">
- <el-form-item label="账户类型:">
- <template v-if="baseInfo.account_type==1">
- <span data-i18n="account_type_1">个人</span>
- </template>
- <template v-else>
- <span data-i18n="account_type_2">企业</span>
- </template>
- </el-form-item>
- <el-form-item v-if="baseInfo.account_type==1" label="名称" prop="first_name">
- {{baseInfo.first_name}}
- </el-form-item>
- <el-form-item v-if="baseInfo.account_type==2" label="联系人名称" prop="first_name">
- {{baseInfo.first_name}}
- </el-form-item>
- <el-form-item v-if="baseInfo.account_type==1" label="姓氏" prop="last_name">
- {{baseInfo.last_name}}
- </el-form-item>
- <el-form-item v-if="baseInfo.account_type==2" label="联系人姓氏" prop="last_name">
- {{baseInfo.last_name}}
- </el-form-item>
- <el-form-item label="国家/省份/城市">
- <el-cascader v-model="baseInfo.cate_code" :options="countryList" style="width:450px;" disabled />
- </el-form-item>
- <el-form-item label="详细地址">
- {{baseInfo.detailed_address}}
- </el-form-item>
- <el-divider></el-divider>
- <el-form-item v-if="baseInfo.account_type==2" label="公司名称" prop="company_name">
- {{baseInfo.company_name}}
- </el-form-item>
-
-
- <el-form-item v-if="baseInfo.account_type==2" label="公司主营业务" prop="main_business">
- <el-radio-group v-model="baseInfo.main_business" class="ml-4">
- <template v-for="(item, index) in mainBusiness">
- <el-radio :value="item.id" disabled>{{item.name}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- <el-form-item v-if="baseInfo.account_type==2" label="公司规模" prop="company_scale">
- <el-radio-group v-model="baseInfo.company_scale" class="ml-4">
- <template v-for="(item, index) in company_scales">
- <el-radio :value="item.id" disabled>{{item.name}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- <el-form-item label="电商经验">
- <el-radio-group v-model="baseInfo.ec_exp" class="ml-4">
- <template v-for="(item, index) in ecExps">
- <el-radio :value="item.value" :key="index" disabled>{{item.label}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- <el-form-item label="主营区域(多选)">
- <el-checkbox-group v-model="baseInfo.main_area" class="ml-4">
- <template v-for="(item, index) in mainAreas">
- <el-checkbox :value="item.id" :label="item.country_name" disabled />
- </template>
- </el-checkbox-group>
- </el-form-item>
- <el-form-item label="主营平台(多选)">
- <el-checkbox-group v-model="baseInfo.main_dis_platform" class="ml-4">
- <template v-for="(item, index) in disPlatformList">
- <el-checkbox :value="item.id" :label="item.platform_name" disabled />
- </template>
- </el-checkbox-group>
- </el-form-item>
- <el-form-item label="运营策略">
- <el-radio-group v-model="baseInfo.operate_str" class="ml-4">
- <template v-for="(item, index) in operateStrs">
- <el-radio :value="item.id" :key="index" disabled>{{item.name}}</el-radio>
- </template>
- </el-radio-group>
- </el-form-item>
- <el-form-item label="店铺链接:">
- {{baseInfo.store_link}}
- </el-form-item>
- <el-form-item label="联系QQ:">{{baseInfo.contact_qq}}
- </el-form-item>
- <el-form-item label="联系微信:">{{baseInfo.contact_weixin}}
- </el-form-item>
- <el-divider></el-divider>
- <el-form-item label="证件类型:" prop="certificate_type">
- <template v-for="item in certificatetypes">
- <template v-if="item.id==baseInfo.certificate_type">
- {{item.type_name}}
- </template>
- </template>
- </el-form-item>
- <el-form-item label="姓名:" prop="certificate_name">
- {{baseInfo.certificate_name}}
- </el-form-item>
- <el-form-item v-if="baseInfo.certificate_type==1" label="身份证号:">
- {{baseInfo.certificate_number}}
- </el-form-item>
- <el-form-item v-else label="通行证号码:">
- {{baseInfo.certificate_number}}
- </el-form-item>
- <el-form-item label="证件照片" prop="cert_front">
- <el-image :src="baseInfo.cert_front" :preview-src-list="[baseInfo.cert_front]" style="width: 100px;height: 100px;"></el-image>
- <el-image :src="baseInfo.cert_back" :preview-src-list="[baseInfo.cert_back]" style="width: 100px;height: 100px; margin-left: 10px;"></el-image>
- </el-form-item>
-
- </el-form></el-card>
- <el-row>
- <el-col :span="24" style="text-align: center;margin:30px 0px;">
- <el-button type="success" @click="reviewBaseInfo(1)">通过审核</el-Button>
- <el-button type="danger" @click="reviewBaseInfo(3)">不通过审核</el-button>
- </el-col>
- </el-row>
- </el-dialog>
- <el-dialog v-model="dialogVisible_Picture">
- <img :src="previewImageUrl" alt="Preview Image" style="width: 100%;" />
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/seller_baseinfo/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/stock_country/index.html b/app/admin/view/stock_country/index.html
deleted file mode 100644
index dc2a36f..0000000
--- a/app/admin/view/stock_country/index.html
+++ /dev/null
@@ -1,91 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="基础信息配置" two_word="国家管理" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="logisticsProduct_management">国家管理</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)" @click="Add(-1)"><span
- data-i18n="add">添加</span></el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" placeholder="请输入国家名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search" @click="index()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" border style="width: 100%" :stripe="true">
- <el-table-column prop="id" label="编号" width="80"></el-table-column>
- <el-table-column prop="country" label="国家名称"></el-table-column>
- <el-table-column prop="country_code" label="国家编码"></el-table-column>
- <el-table-column prop="order_id" label="排序"></el-table-column>
- <el-table-column label="操作选项">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="Add(scope.$index)"></el-button>
- <el-button icon="delete" type="danger" @click="del(scope.$index)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="Add_title" v-model="dialog.addDialogStatus" :show-close="true" width="700px">
- <el-form ref="Add_form" :model="Add_form" label-width="100px">
-
- <el-form-item label="国家名称">
- <el-input v-model="Add_form.country" placeholder="请输入国家名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="国家编码">
- <el-input v-model="Add_form.country_code" placeholder="请输入国家编码" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item v-if="Add_form.id>0" label="排序值">
- <el-input-number v-model="Add_form.order_id" class="mx-4" controls-position="right" />
- </el-form-item>
- <el-form-item>
- <el-button :loading="loading" type="primary" @click="submit">
- <span v-if="!loading">保 存</span>
- <span v-else>提 交 中...</span>
- </el-button>
- <el-button @click="dialog.addDialogStatus=false">取消</el-button>
-
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/stock_country/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/supplier/add.html b/app/admin/view/supplier/add.html
deleted file mode 100644
index 6d843b0..0000000
--- a/app/admin/view/supplier/add.html
+++ /dev/null
@@ -1,138 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <input type="hidden" value="{$other['id']}" id="supplier_id">
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="供应商管理" two_word="{$other.title}" />
- </el-header>
- <el-main>
- <el-card>
- <template #header>
- <div class="card-header">
- <span>供应商账号信息</span>
-  
- <el-link type="primary" class="header_add_btn" icon="ArrowLeftBold" :underline="false" href="/admin/supplier/index.html">返回</el-link>
- </div>
- </template>
- <el-form ref="useritem" :model="supplier_info" label-width="100px" size="large">
- <el-form-item label="供应商名称" v-if="supplier_id==0">
- <el-input v-model="supplier_info.supplier_name" style="width: 350px;" placeholder="请输入供应商名称"></el-input>
- </el-form-item>
- <el-form-item label="主账号">
- <el-input v-model="supplier_info.user_name" style="width: 350px;" placeholder="请输入供应商账号"></el-input>
- </el-form-item>
- <el-form-item label="密码">
- <el-input placeholder="请输入密码" v-model="supplier_info.password" show-password style="width: 350px;"></el-input>
- <span v-if="supplier_info.id" class="gray14">不修改密码保留为空</span>
- </el-form-item>
- <el-form-item label="姓名">
- <el-input v-model="supplier_info.account_name" style="width: 350px;" placeholder="请输入供应商联系人姓名"></el-input>
- </el-form-item>
- <el-form-item label="手机号">
- <el-input v-model="supplier_info.account_phone" style="width: 350px;" placeholder="请输入联系人手机号"></el-input>
- </el-form-item>
- <el-form-item label="账号到期时间">
- <el-date-picker v-model="supplier_info.end_time" type="date" placeholder="选择日期" value-format="YYYY-MM-DD"></el-date-picker>
- </el-form-item>
- <el-form-item label="状态" prop="delivery">
- <el-switch v-model="supplier_info.sub_ban_access" inline-prompt active-text="允许登录" inactive-text="禁止登录"
- style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ff4949" :active-value="1" :inactive-value="0"></el-switch>
- </el-form-item>
- <el-form-item>
- <el-button type="primary" @click="save_supplier_info()" size="large">提交保存</el-button>
- <!-- <el-button @click="show_supplier_info=false" size="large">取消</el-button> -->
- </el-form-item>
- </el-form>
- </el-card>
- <template v-if="supplier_id>0">
- <br />
- <el-card>
- <template #header>
- <div class="card-header">
- <span>供应商信息</span>
- </div>
- </template>
- <el-form ref="useritem" :model="supplier_info" label-width="160px" size="large">
- <el-form-item label="供应商名称">
- <el-input v-model="supplier_info.supplier_name" style="width: 500px;" placeholder="请输入供应商名称"></el-input>
- </el-form-item>
- <el-form-item label="英文名称">
- <el-input v-model="supplier_info.supplier_en_name" style="width: 500px;" placeholder="请输入供应商英文名称"></el-input>
- </el-form-item>
- <el-form-item label="联系人">
- <el-input v-model="supplier_info.real_name" style="width: 500px;" placeholder="请输入供应商联系人姓名"></el-input>
- </el-form-item>
- <el-form-item label="手机号">
- <el-input v-model="supplier_info.phone" style="width: 500px;" placeholder="请输入联系人手机号"></el-input>
- </el-form-item>
- <el-form-item label="邮箱">
- <el-input v-model="supplier_info.email" style="width: 500px;" placeholder="请输入联系人邮箱"></el-input>
- </el-form-item>
- <el-form-item label="座机">
- <el-input v-model="supplier_info.phone_number" style="width: 500px;" placeholder="请输入联系人座机"></el-input>
- </el-form-item>
- <el-form-item label="公司唯一代码">
- <el-input v-model="supplier_info.unique_code" style="width: 500px;" placeholder="请输入供应商的企业唯一代码"></el-input>
- </el-form-item>
- <el-form-item label="法人姓名">
- <el-input v-model="supplier_info.legal_person_name" style="width: 500px;" placeholder="请输入供应商的法人姓名"></el-input>
- </el-form-item>
- <el-form-item label="法人身份证号">
- <el-input v-model="supplier_info.legal_person_id_number" style="width: 500px;" placeholder="请输入供应商的法人身份证号"></el-input>
- </el-form-item>
- <el-form-item label="公司地址">
- <el-input v-model="supplier_info.address" style="width: 500px;" placeholder="请输入供应商的地址"></el-input>
- </el-form-item>
- <el-form-item label="邮编">
- <el-input v-model="supplier_info.postal_code" style="width: 500px;" placeholder="请输入供应商的邮编"></el-input>
- </el-form-item>
- <el-form-item label="业务经理">
- <el-input v-model="supplier_info.account_executive" style="width: 500px;" placeholder="请输入业务经理"></el-input>
- </el-form-item>
- <el-form-item label="业务经理联系方式">
- <el-input v-model="supplier_info.account_executive_phone" style="width: 500px;" placeholder="请输入业务经理联系方式"></el-input>
- </el-form-item>
- <el-form-item>
- <el-button type="primary" @click="save_supplier_info()" size="large">提交保存</el-button>
- <!-- <el-button @click="show_supplier_info=false" size="large">取消</el-button> -->
- </el-form-item>
- </el-form>
- </el-card>
- <br />
- <el-card>
- <template #header>
- <div class="card-header">
- <span>资质证明文件</span>
- </div>
- </template>
- </el-card>
- </template>
- </el-main>
- </el-container>
- </el-container>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/vue/moment.min.js"></script>
- <script src="/static/admin/js/supplier/add.js"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/supplier/index.html b/app/admin/view/supplier/index.html
deleted file mode 100644
index 267c1bf..0000000
--- a/app/admin/view/supplier/index.html
+++ /dev/null
@@ -1,139 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="供应商管理" two_word="{$other.title}列表" />
- </el-header>
- <el-main>
- <el-card>
- <template #header>
- <div class="card-header">
- <span>{$other.title}列表</span>
-  
- <el-link type="primary" class="header_add_btn" icon="CirclePlusFilled" :underline="false" href="javascript:void(0)"
- @click="goto_edit_supplier(0)">添加</el-link>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchdata.kw" size="large" placeholder="可通过账号/姓名 筛选" style="width: 300px"></el-input>
-  
- <el-button type="success" size="large" icon="Search" @click="searchsupplier_list()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="supplier_list" border style="width: 100%" ref="tableRef">
- <el-table-column label="账号" prop="user_name" width="150"></el-table-column>
- <el-table-column label="供应商名称" prop="supplier_name"></el-table-column>
- <el-table-column label="联系人" prop="real_name" width="200">
- <template #default="scope">
- {{scope.row.real_name}}<br />
- {{scope.row.phone}}
- </template>
- </el-table-column>
- <el-table-column label="账号状态" width="150" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.ban_access" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="允许登录" inactive-text="禁止登录" @change="set_ban_access(scope.$index)" />
- </template>
- </el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <el-switch v-model="scope.row.audit_status" style="--el-switch-on-color: #13ce66; --el-switch-off-color: #ccc" :active-value="1"
- :inactive-value="0" inline-prompt active-text="通过审核" inactive-text="未审核" @change="setAuditStatus(scope.$index)" />
- </template>
- </el-table-column>
- <el-table-column label="账号时间" width="180" align="center">
- <template #default="scope">
- 开始:{{formatDate(scope.row['start_time'])}}<br />
- 结束:{{formatDate(scope.row['end_time'])}}
- </template>
- </el-table-column>
- <el-table-column label="最近登录信息" width="180" align="center">
- <template #default="scope">
- <template v-if="scope.row.login_time>0">
- 时间:{{formatDate(scope.row['login_time'])}}
- <br />
- IP:{{scope.row['login_ip']}}
- </template>
- </template>
- </el-table-column>
- <el-table-column label="操作" fixed="right" min-width="150" :align="alignValue(200)">
- <template #default="scope">
- <el-button icon="edit" type="primary" @click="goto_edit_supplier(scope.row.id)"></el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-drawer :title="supplier_title" :direction="direction" v-model="show_supplier_info" size="35%">
- <div id="comment_item">
- <div class="layui-row">
- <div class="layui-col-md12 caller-contar">
- <div class="caller-item">
- <el-form ref="useritem" :model="useritem" label-width="150px">
- <el-form-item label="账号">
- <template v-if="useritem.id">
- {{useritem.user_name}}
- </template>
- <template v-else>
- <el-input v-model="useritem.user_name" style="width: 330px;"></el-input>
- </template>
- </el-form-item>
- <el-form-item label="密码">
- <el-input placeholder="请输入密码" v-model="useritem.pwd" show-password style="width: 330px;"></el-input>
- <span v-if="useritem.id" class="gray14">不修改密码保留为空</span>
- </el-form-item>
- <el-form-item label="供应商名称">
- <el-input v-model="useritem.supplier_name" style="width: 330px;"></el-input>
- </el-form-item>
- <el-form-item label="联系人">
- <el-input v-model="useritem.real_name" style="width: 330px;"></el-input>
- </el-form-item>
- <el-form-item label="手机号">
- <el-input v-model="useritem.phone" style="width: 330px;"></el-input>
- </el-form-item>
- <el-form-item v-if="useritem.id" label="账号到期时间">
- <el-date-picker v-model="useritem.endtime" type="date" placeholder="选择日期">
- </el-date-picker>
- </el-form-item>
-
- <el-form-item>
- <el-button type="primary" @click="save_supplier">{{supplier_button_txt}}</el-button>
- <el-button @click="show_supplier_info=false">取消</el-button>
- </el-form-item>
- </el-form>
-
- </div>
- </div>
- </div>
- </div>
- </el-drawer>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/supplier/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/third_party_logistics_product_temp/index.html b/app/admin/view/third_party_logistics_product_temp/index.html
deleted file mode 100644
index d1bb86e..0000000
--- a/app/admin/view/third_party_logistics_product_temp/index.html
+++ /dev/null
@@ -1,130 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="物流产品审核" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span>物流产品审核</span>
-
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="input" placeholder="请输入物流产品名称/对接编码" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="logistics_product_list" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column label="对接平台产品">
- <template #default="scope">
- <template v-if="scope.row.platform_logistics_product_id!=null">
- {{scope.row.platform_logistics_product_name.product_name_en}}
- {{scope.row.platform_logistics_product_name.product_name_cn}}({{scope.row.platform_logistics_product_name.cycle_start}}-{{scope.row.platform_logistics_product_name.cycle_end}}天)
-
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="docking_code" label="对接编码" width="180"></el-table-column>
- <el-table-column prop="product_name_cn" label="第三方物流名称"></el-table-column>
- <el-table-column prop="product_name_en" label="第三方物流英文名称"></el-table-column>
- <el-table-column label="增值服务" width="220">
- <template #default="scope">
- <template v-if="scope.row.value_added_services!=null" v-for="vas_item in logistics_vas">
- <template v-if="scope.row.value_added_services.includes(vas_item.vas_code)">{{vas_item.vas_name}};</template>
- </template>
- </template>
- </el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">已审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="warning">未通过</el-tag></template>
- <template v-else-if="scope.row.status==3"><el-tag type="warning">已提交审核</el-tag></template>
- </template>
- </el-table-column>
- <el-table-column prop="edit_time" label="提交时间"></el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.status==3?false:true" @click="create_product(scope.$index)">审核</el-button>
-
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="create_product_title" v-model="Visible_logisticsProduct" :show-close="true" width="40%">
- <el-form ref="form" :model="create_product_form" label-width="100px">
- <!-- <el-form-item label="物流类型">
- <el-input placeholder="自建仓物流" disabled style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="对接系统">
- <el-select v-model="create_product_form.docking_system" disabled placeholder="选择对接系统" size="large" style="width: 260px">
- <el-option v-for="item in docking_system_options" :key="item.value" :label="item.label" :value="item.value" />
- </el-select>
- </el-form-item> -->
- <el-form-item label="平台物流产品" prop="platform_logistics_product_id">
- <el-select v-model="create_product_form.platform_logistics_product_id" disabled placeholder="请选择平台物流产品" style="width: 350px">
- <el-option v-for="item in platformLogisticsProductList" :key="item.id" :label="item.product_name_en+' '+item.product_name_cn+'('+item.cycle_start+'-'+item.cycle_end+'天)'"
- :value="item.id" />
- </el-select>
- </el-form-item>
- <el-form-item label="对接编码">
- <el-input v-model="create_product_form.docking_code" readonly placeholder="请输入对接编码" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="物流产品名称">
- <el-input v-model="create_product_form.product_name_cn" readonly placeholder="请输入物流产品名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="物流英文名称">
- <el-input v-model="create_product_form.product_name_en" readonly placeholder="请输入物流英文名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="增值服务">
- <el-checkbox-group disabled v-model="create_product_form.value_added_services" @change="handleCheckedCitiesChange">
- <el-checkbox v-for="vas_item in logistics_vas" :key="vas_item.vas_code" :label="vas_item.vas_name" :value="vas_item.vas_code">
- {{ vas_item.vas_name }}
- </el-checkbox>
- </el-checkbox-group>
-
- </el-form-item>
- <el-form-item>
- <el-button type="primary" @click="reviewLogisticsProduct(1)">通过审核</el-button>
- <el-button type="danger" @click="reviewLogisticsProduct(2)">不通过审核</el-button>
- </el-form-item>
- </el-form>
-
-
-
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/third_party_logistics_product_temp/index.js?v=<?php echo create_random()?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/third_party_stock_temp/index.html b/app/admin/view/third_party_stock_temp/index.html
deleted file mode 100644
index 20c03c6..0000000
--- a/app/admin/view/third_party_stock_temp/index.html
+++ /dev/null
@@ -1,160 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="数据审核" two_word="第三方仓库审核" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header"><span data-i18n="thirdpartystock_management">第三方仓库审核</span>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="input" placeholder="请输入对接编码/仓库名称" style="width: 300px"></el-input>
-  <el-button type="success" icon="Search">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="stock_list" border style="width: 100%" :stripe="true" ref="tableRef">
- <!-- <el-table-column prop="stock_type" label="仓库类型" width="180">
- <template #default="scope">
- 自建仓
- </template>
- </el-table-column>
- <el-table-column prop="docking_system" label="对接系统" width="180">
- <template #default="scope">
- 无
- </template>
- </el-table-column> -->
- <el-table-column prop="third_party_stock_name" label="仓库名称" width="180"></el-table-column>
- <el-table-column prop="docking_code" label="对接编码" width="180"></el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.need_review==2">
- <el-tag type="danger">提交审核</el-tag>
- </template>
- <template v-else-if="scope.row.need_review==0"><el-tag type="warning">未提交</el-tag></template>
- <template v-else>
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">通过审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="warning">未通过</el-tag></template>
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="edit_time" label="提交时间" width="180"></el-table-column>
- <el-table-column label="是否需要审核" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.need_review==2">是</template>
- <template v-else-if="scope.row.need_review==1">--</template>
- </template>
- </el-table-column>
- <el-table-column label="审核" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.need_review==2?false:true" @click="create_stock(scope.$index)">审核</el-button>
-
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchdata.p" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchdata.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- <!-- <el-footer>Footer</el-footer> -->
- </el-container>
- </el-container>
-
- <el-dialog :title="create_stock_title" v-model="Visible_thirdPartyStock" :show-close="true" width="75%">
- <el-form ref="form" :model="create_stock_form" label-width="100px">
- <el-form-item label="仓库类型">
- <el-input placeholder="自建仓" disabled style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="对接系统">
- <el-select v-model="create_stock_form.docking_system" placeholder="选择对接系统" disabled size="large" style="width: 260px">
- <el-option v-for="item in docking_system_options" :key="item.value" :label="item.label" :value="item.value" />
- </el-select>
- </el-form-item>
- <el-form-item label="仓库名称">
- <el-input v-model="create_stock_form.third_party_stock_name" readonly placeholder="请输入仓库名称" style="width:260px;"></el-input>
- </el-form-item>
- <el-form-item label="对接编码">
- <el-input v-model="create_stock_form.docking_code" readonly placeholder="请输入对接编码" style="width:260px;"></el-input>
- </el-form-item>
- </el-form>
-
- <el-card v-if="create_stock_form.id" style="width: 100%">
- <template #header>
- <div class="card-header">
- <span data-i18n="thirdpartystock_management">仓库地址</span>
- </div>
- </template>
- <br />
- <el-table :data="stock_address_list" border style="width: 100%" :stripe="true">
- <el-table-column label="适用范围" width="220">
- <template #default="scope">
- <template v-for="range_item in suit_range_list">
- <template v-if="scope.row.suit_range.includes(range_item.id)">{{range_item.name}};</template>
- </template>
- </template>
- </el-table-column>
- <el-table-column prop="receive_man" label="联系人" width="180"></el-table-column>
- <el-table-column prop="tel" label="电话" width="180"></el-table-column>
- <el-table-column label="详细地址">
- <template #default="scope">
- {{scope.row.stock_address}}
- {{scope.row.stock_city}}
- {{scope.row.stock_province}}
- {{scope.row.country}}
- {{scope.row.stock_post_code}}
- </template>
-
- </el-table-column>
- <el-table-column label="审核状态" width="150" align="center">
- <template #default="scope">
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">已审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="warning">未通过</el-tag></template>
- </template>
- </el-table-column>
- <el-table-column label="审核" align="center" width="280">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.status==0?false:true" @click="reviewAddress(scope.$index,1)">通过审核</el-button>
- <el-button type="danger" :disabled="scope.row.status==0?false:true" @click="reviewAddress(scope.$index,2)">不通过审核</el-button>
-
- </template>
- </el-table-column>
- </el-table>
- </el-card>
- <div style="margin-top: 20px; text-align: center;">
- <!-- <el-button type="primary" @click="reviewStock(1)">通过审核</el-button> -->
- <el-button type="danger" @click="reviewStock(2)">不通过审核</el-button>
- </div>
-
- </el-dialog>
-
-
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/third_party_stock_temp/index.js?v=<?php echo create_random()?>"></script>
-
-</html>
\ No newline at end of file
diff --git a/app/admin/view/withdrawal_record/index.html b/app/admin/view/withdrawal_record/index.html
deleted file mode 100644
index dff5c84..0000000
--- a/app/admin/view/withdrawal_record/index.html
+++ /dev/null
@@ -1,142 +0,0 @@
-<!DOCTYPE html>
-<html lang="zh-cn">
-
- <head>
- <meta charset="utf-8">
- <include file="common:title" />
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
- <include file="common:header" />
- <include file="common:element-plus" />
- <style>
- /* 解决图片放大时层显示问题 */
- .el-table th.el-table__cell,
- .el-table td.el-table__cell,
- .el-select,
- .el-select__wrapper {
- position: unset;
- }
-
- .el-image-viewer__img {
- width: 50%;
- }
- </style>
- </head>
-
- <body>
- <div id="vue_item" v-cloak>
- <el-container>
- <el-aside class="el-menu-container" :width="el_aside_width">
- <!-- 侧边菜单 -->
- <include file="common:side_menu" />
- </el-aside>
- <el-container>
- <el-header>
- <include file="common:guide" one_word="{$guide['one']['text']}" two_word="{$guide['two']['text']}" />
- </el-header>
- <el-main>
- <el-card style="width: 100%">
- <template #header>
- <div class="card-header">
- <span data-i18n="goods_brand_management">{$other['title']}</span>
- </div>
- </template>
- <el-form label-width="auto">
- <el-input v-model="searchData.kw" placeholder="请输入收款账户" style="width: 300px"></el-input>
-  
- <el-button type="success" icon="Search" @click="getWithdrawalRecordList()">搜索</el-button>
- </el-form>
- <br />
- <el-table :data="list" v-loading="loading" border style="width: 100%" :stripe="true" ref="tableRef">
- <el-table-column type="index" label="编号" width="80" show-overflow-tooltip></el-table-column>
- <el-table-column label="提现账户" show-overflow-tooltip>
- <template #default="scope">
- {{scope.row.asset_name}} {{scope.row.currency_name}}
- </template>
- </el-table-column>
- <el-table-column prop="payment_tool_name" label="提现方式" show-overflow-tooltip></el-table-column>
- <el-table-column prop="payment_account" label="收款账户" show-overflow-tooltip>
-
- </el-table-column>
- <el-table-column prop="remit_amount" label="提现金额" width="100" show-overflow-tooltip>
- <template #default="scope">
- {{scope.row.asset_name}} {{scope.row.payment_amount}}
- </template>
- </el-table-column>
- <el-table-column prop="payment_remark" label="备注" show-overflow-tooltip></el-table-column>
- <el-table-column prop="review_comments" label="未通过原因" show-overflow-tooltip></el-table-column>
- <el-table-column prop="add_time" label="系统时间" align="center" show-overflow-tooltip></el-table-column>
-
- <el-table-column prop="service_charge" label="手续费" width="100" show-overflow-tooltip>
- <template #default="scope">
- <template v-if="scope.row.status==1">{{scope.row.service_charge}}</template>
- <template v-else>-</template>
- </template>
- </el-table-column>
- <el-table-column prop="real_name" label="审核状态" width="200" align="center">
- <template #default="scope">
- <template v-if="scope.row.status==0"><el-tag type="danger">未审核</el-tag></template>
- <template v-else-if="scope.row.status==1"><el-tag type="success">已审核</el-tag></template>
- <template v-else-if="scope.row.status==2"><el-tag type="info">未通过审核</el-tag></template>
- </template>
- </el-table-column>
- <el-table-column label="操作选项" fixed="right" min-width="140" :align="alignValue(200)">
- <template #default="scope">
- <el-button type="primary" :disabled="scope.row.status==0?false:true" @click="showRecord(scope.row)">审核</el-button>
- </template>
- </el-table-column>
- </el-table>
- <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="searchData.page" :page-sizes="[20, 30, 40, 50]"
- :page-size="searchData.page_size" layout="total, sizes, prev, pager, next" :total="other.count">
- </el-pagination>
- </el-card>
- </el-main>
- </el-container>
- </el-container>
- <el-dialog title="提现信息" width="1200px" align-center="true" class="icon-dialog" v-model="dialogRecord" :before-close="closeForm" append-to-body>
- <el-card style="width: 100%">
- <el-form :rules="assetRules" ref="assetForm" :inline-message="true" :model="assetInfo" :validate-on-rule-change="false" label-width="200px">
- <el-form-item label="提现账户:">
- {{recordInfo.asset_name}} {{recordInfo.currency_name}}
- </el-form-item>
- <el-form-item label="提现方式:">
- <p>{{recordInfo.payment_tool_name}}</p>
- </el-form-item>
- <el-form-item label="收款账户:">
- <p>{{recordInfo.payment_account}}</p>
- </el-form-item>
- <el-form-item label="提现币别:">
- {{recordInfo.asset_name}}
- </el-form-item>
- <el-form-item label="提现金额:">
- {{recordInfo.asset_name}} {{recordInfo.payment_amount}}
- </el-form-item>
- <el-form-item label="系统时间:">
- {{recordInfo.add_time}}
- </el-form-item>
- <el-form-item label="备注:">
- {{recordInfo.payment_remark}}
- </el-form-item>
- <el-form-item label="手续费:" prop="service_charge">
- <el-input v-model="assetInfo.service_charge" style="width:200px;" placeholder="请输入手续费"></el-input>
- </el-form-item>
- <el-form-item label="不通过原因" prop="review_comments" v-if="assetInfo.status==2">
- <el-input v-model="assetInfo.review_comments" style="width: 500px" :rows="2" type="textarea" placeholder="不通过原因" />
- </el-form-item>
-
- <el-form-item>
-
- <el-button type="success" @click="passReviewWithdrawalRecord()">到账通过审核</el-Button>
- <el-button type="danger" @click="reviewWithdrawalRecord(2)">不通过审核</el-button>
- </el-form-item>
- </el-form>
- </el-card>
- </el-dialog>
- </div>
- </body>
- <!-- 共用的方法 -->
- <script src="/static/vue/mixin_admin.js"></script>
- <script src="/static/admin/js/withdrawal_record/index.js?v=<?php echo rand(1000,9999)?>"></script>
-
-</html>
\ No newline at end of file
--
Gitblit v1.9.0