Commit bb865f41 by 朱继来

fix conflicts

parent 515f9825
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Illuminate\Http\Response;
use App\Http\Requests;
use App\Http\Controllers\Controller;
use DB;
use Cookie;
use App\Http\Page;
use App\Http\Controllers\PermController;
function CheckActive($menus, &$arr, $url)
{
for ($i = 0; $i < count($menus); $i++) {
$menu = $menus[$i];
array_push($arr, $i);
if (isset($menu->href) && ($menu->href == $url || ($menu->href == '/' && $url == '//')))
return true;
if (isset($menu->childs) && count($menu->childs) > 0) {
$ret = CheckActive($menu->childs, $arr, $url);
if ($ret)
return $ret;
}
array_pop($arr);
}
return false;
}
function createMenuReal($menus, $active, $level)
{
$subclass = ($level == 0) ? 'nav-second-level' : 'nav-third-level';
$ret = '';
for ($ii = 0; $ii < ($level == 0 ? 1 : 2); $ii++) {
for ($i = 0; $i < count($menus); $i++) {
$menu = $menus[$i];
$act = (count($active) > $level && $active[$level] == $i) ? true : false;
$actclass = $act ? ' class="active"' : '';
$actmenu = $act ? ' in': '';
if (isset($menu->childs) && count($menu->childs) > 0) {
if ($ii != 0 && $level > 0)
continue;
$ret .= '<li' . $actclass . '><a><i class="'
. $menu->class . '"></i><span class="nav-label">'
. $menu->title . '</span><span class="fa arrow"></span></a>'
. '<ul class="nav ' . $subclass . ' collapse' . $actmenu . '">'
. createMenuReal($menu->childs, $act ? $active : [], $level + 1)
. '</ul></li>';
} else {
if ($ii != 1 && $level > 0)
continue;
$ret .= '<li' . $actclass . '><a href="'. $menu->href . '"><i class="' .
$menu->class . '"></i><span class="nav-label">' . $menu->title . '</span></a></li>';
}
}
}
return $ret;
}
function createMenu($menus, $url)
{
$actives = [];
$ret = CheckActive($menus, $actives, $url);
if (!$ret)
$actives = [];
return createMenuReal($menus, $actives, 0);
}
Class AddOrderController extends Controller
{
// 页面用户、菜单信息
public function getPageInfo(Request $request)
{
$uri = '/' . $request->path();
$username = $request->user->email;
$useremail= $request->user->email;
// 菜单
$menuconfig = DB::table('config')->where('config_title', '订单系统')->first();
$menus = [];
if ($menuconfig && !($menus = json_decode($menuconfig->config_data)))
$menus = [];
$perm = new PermController;
// 获取权限菜单
if ($request->user->email != 'admin@ichunt.com' && $request->user->userId != 1000)
$menus = $perm->getPermMenu($request, $menus);
$data = [
'header' => $request->user->header,
'uri' => $uri,
'username' => $username,
'useremail' => $useremail,
'menus' => $menus,
];
return $data;
}
// 查询省市区
public function getAddress($id)
{
$addr = DB::connection('order')->table('lie_region')->where('region_id', $id)->select('region_name')->first();
return $addr->region_name;
}
// 新增自营线下订单
public function addOffline(Request $request)
{
$info = $this->getPageInfo($request);
$info['title'] = '新增自营线下订单';
$info['paths'] = [["title" => '新增自营线下订单', "href" => '#']];
// 默认内部账号ID
$internal = DB::connection('order')->table('lie_user_main')->where('mobile', Config('website.internal-account'))->select('user_id')->first();
$info['internal_uid'] = $internal->user_id;
// 默认内部账号收货地址
$address = DB::connection('order')->table('lie_user_address')->where(['user_id' => $info['internal_uid'], 'is_default' => 1])->first();
$address->province_val = $this->getAddress($address->province);
$address->city_val = $this->getAddress($address->city);
$address->district_val = $this->getAddress($address->district);
$info['address'] = $address;
$sale_id = $request->user->userId;
$info['sale_id'] = $sale_id;
// 当前登录用户名称
$userInfo = DB::table('user_info')->where('userId', $sale_id)->select('name')->first();
$info['name'] = $userInfo->name;
// 当前登录用户内部绑定手机
$intracode = DB::table('lie_intracode')->where('admin_id', $sale_id)->select('user_id')->first();
if (!empty($intracode)) {
$user = DB::connection('order')->table('lie_user_main')->where('user_id', $intracode->user_id)->select('mobile')->first();
$info['mobile'] = $user->mobile;
}
return view('addOffline', $info);
}
// 获取SKU信息
public function getSku(Request $request)
{
if ($request->isMethod('post')) {
$url = Config('website.search-skuid');
$data['sku_id'] = $request->input('sku_id');
$response = json_decode(curlApi($url, $data), true);
if (!empty($response['data']['data'])) {
return ['errcode' => 0, 'errmsg' => '', 'data' => $response['data']['data'][0]];
} else {
return ['errcode' => -1, 'errmsg' => '未找SKU信息'];
}
}
}
// 添加到购物车
public function addCart(Request $request)
{
if ($request->isMethod('post')) {
$data['uid'] = $request->input('uid');
$data['id'] = $request->input('id');
$data['num'] = $request->input('num');
$data['buy'] = $request->input('buy');
$data['delivery_place'] = $request->input('delivery_place');
$data['pf'] = 4;
$data['k1'] = time();
$data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi');
$url = Config('website.api_domain').'cart/addByOrderSystem';
$response = json_decode(curlApi($url, $data), true);
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg']];
}
}
// 获取购物车列表
public function cartList(Request $request)
{
if ($request->isMethod('post')) {
$data['uid'] = $request->input('uid');
$data['type'] = $request->input('type');
$data['k1'] = time();
$data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi');
$url = Config('website.api_domain').'cart/listsByOrderSystem';
$response = json_decode(curlApi($url, $data), true);
if ($response['err_code'] == 0) {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg'], 'data'=>$response['data']];
} else {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg']];
}
}
}
// 修改购物车商品数量
public function changeNum(Request $request)
{
if ($request->isMethod('post')) {
$data['uid'] = $request->input('uid');
$data['num'] = $request->input('num');
$data['cart_id'] = $request->input('cart_id');
$data['k1'] = time();
$data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi');
$url = Config('website.api_domain').'cart/changeNumByOrderSystem';
$response = json_decode(curlApi($url, $data), true);
if ($response['err_code'] == 0) {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg'], 'data'=>$response['data']];
} else {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg']];
}
}
}
// 删除购物车商品
public function deleteGoods(Request $request)
{
if ($request->isMethod('post')) {
$data['uid'] = $request->input('uid');
$data['cart_id'] = $request->input('cart_id');
$data['k1'] = time();
$data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi');
$url = Config('website.api_domain').'cart/deleteByOrderSystem';
$response = json_decode(curlApi($url, $data), true);
if ($response['err_code'] == 0) {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg'], 'data'=>$response['data']];
} else {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg']];
}
}
}
// 提交订单
public function create(Request $request)
{
if ($request->isMethod('post')) {
$data['uid'] = $request->input('uid');
$data['sale_id'] = $request->input('sale_id');
$data['address_id'] = $request->input('address_id');
$data['cart_id'] = implode(',', $request->input('cart_ids'));
$data['type'] = $request->input('type');
if ($data['type'] == 3) {
$data['address_name'] = $request->input('address_name');
$data['address_mobile'] = $request->input('address_mobile');
}
$data['k1'] = time();
$data['k2'] = md5(md5($data['k1']).'fh6y5t4rr351d2c3bryi');
$url = Config('website.api_domain').'order/createByOrderSystem';
$response = json_decode(curlApi($url, $data), true);
if ($response['err_code'] == 0) {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg'], 'data'=>['order_id' => $response['data'], 'type' => $data['type']]];
} else {
return ['errcode' => $response['err_code'], 'errmsg' => $response['err_msg']];
}
}
}
// 提交订单成功页面
public function success(Request $request)
{
$info = $this->getPageInfo($request);
$order_id = $request->input('order_id');
$type = $request->input('type');
if ($type == 1) {
$title = '新增联营订单';
} else if ($type == 2) {
$title = '新增自营线上订单';
} else {
$title = '新增自营线下订单';
}
$info['title'] = $title;
$info['paths'] = [["title" => $title, "href" => '#']];
$order = DB::connection('order')->table('lie_order')->where('order_id', $order_id)->first();
$info['order_info'] = $order;
return view('success', $info);
}
// 自营线下订单审核
public function selfCheck(Request $request)
{
if ($request->isMethod('post')) {
$order_id = $request->input('order_id');
$update = DB::connection('order')->table('lie_order')->where('order_id', $order_id)->update(['status' => 4]); // 待发货状态
if (!empty($update)) {
return ['errcode' => 0, 'errmsg' => '审核成功'];
} else {
return ['errcode' => -1, 'errmsg' => '审核失败'];
}
}
}
}
\ No newline at end of file
......@@ -5,12 +5,18 @@
'平台订单' => ['orderlist_check', 'export', 'cancel_order', 'check_account', 'order_send', 'update_address', 'update_invoice', 'check_test_order', 'check_order', 'download_contract', 'send_salesman'],
'ERP订单' => ['erp_order_check'],
'新增订单' => ['add_order_check'],
],
'自营订单' => [
'订单列表' => ['self_order_check', 'self_order_export', 'self_order_cancel', 'self_order_express', 'self_order_invoice_express', 'self_order_update_address', 'self_order_update_invoice', 'self_check_test_order', 'self_order_download_contract'],
'快递配置' => ['self_order_express_set_check'],
'新增订单_线上' => ['add_online_check'],
'新增订单_线下' => ['add_offline_check'],
],
'订单统计' => [
......
......@@ -41,4 +41,21 @@ return [
// www站点
'main_url' => 'https://www.liexin.com/',
// 新增自营线下订单内部账号
'internal-account' => '15011111111',
// 新增用户入口
'add-user-url' => 'http://member.liexin.net/add',
// 查询SKUID接口
'search-skuid' => 'http://footstone.liexin.net/webapi/sku_list',
// 新增SKU入口
'add-sku-url' => 'http://footstone.liexin.net/manage/addsku',
// 查询联营SKU入口
'search-sku-url-1' => 'http://footstone.liexin.net/manage/skulist',
// 查询自营SKU入口
'search-sku-url-2' => 'http://footstone.liexin.net/manage/GoodsList',
];
......@@ -99,3 +99,68 @@ li {
resize: none;
}
/*新增订单*/
.title-tips {
font-size: 12px;
color: #ff9900;
}
.clear {
clear:both;
height: 0;
line-height: 0;
font-size: 0;
}
.sku-info {
width: 100%;
height: auto;
min-height: 100px;
margin-top: 20px;
display: none;
}
.sku-info-left {
float: left;
width: 70%;
}
.sku-info-right {
float: right;
width: 30%;
}
.sku-info-right .table > tbody > tr > th, .sku-info-right .table > tbody > tr > td {
line-height: 0.5;
}
.shop-lists{
margin-top: 10px;
display: none;
}
.shop-lists input {
width: 100px;
}
.amount-section{
margin-top: 40px;
text-align: right;
display: none;
}
/*提交订单成功页面*/
.section-1, .section-3{
text-align: center;
margin: 20px;
}
.section-1 img{
margin-bottom: 20px;
}
.section-2 {
width: 50%;
height: 100px;
border: 1px solid #ccc;
margin: 0 25%;
padding: 25px;
background: #f0f0f0;
}
.section-2 p {
margin-left: 33%;
}
+(function($){
$.lie = $.lie || {version: "v1.0.0"};
$.extend($.lie, {
add_order:{
offline: function() {
this.bind(2);
this.lists(user_id, 2);
},
bind: function(type) {
var loading = this;
// 获取SKU信息
$('.get-sku').click(function() {
var sku_id = $(this).siblings('.search-sku').val();
if (!sku_id) return false;
$.ajax({
url: '/ajax/getSku',
type: 'post',
data: {sku_id : sku_id.trim()},
dataType: 'json',
success: function (resp) {
if (resp.errcode != 0) {
layer.msg(resp.errmsg);
return false;
}
$('.sku-info').show();
var data = resp.data;
$('.goods_name').text(data.goods_name);
$('.brand_name').text(data.brand_name);
$('.supplier_name').text(data.supplier_name);
$('.stock').text(data.stock);
$('.moq').text(data.moq);
$('.mpq').text(data.mpq);
$('.goods_id').val(data.goods_id);
//阶梯价格
var len = data.ladder_price.length;
if (len > 0) {
var html = '';
for (var i = 0; i < len; i++) {
if (i == 0) {
html += '<tr><td><span class="goods-min-num">'+data.ladder_price[i]['purchases']+'</span></td><td>¥<span class="goods-min-price">'+data.ladder_price[i]['price_cn']+'</span></td></tr>';
} else {
html += '<tr><td><span>'+data.ladder_price[i]['purchases']+'</span></td><td>¥<span>'+data.ladder_price[i]['price_cn']+'</span></td></tr>';
}
}
$('.ladder_price_table tr:gt(0)').remove();
$('.ladder_price_table').append(html);
}
}
})
})
// 添加到商品列表
$('.add-to-lists').click(function() {
var goods_min_num = $(this).parents('.sku-info').find('.goods-min-num').text();
var goods_id = $(this).siblings('.goods_id').val();
var datax = {
uid: user_id,
id: goods_id,
num: goods_min_num,
buy: -1,
delivery_place: 1, // 1.大陆,2.香港 自营默认是大陆
}
$.ajax({
type: "POST",
url: '/ajax/addCart',
data: datax,
dataType: "json",
success: function(resp){
layer.msg(resp.errmsg);
loading.lists(user_id, type); // 加载购物车列表
return false;
},
})
})
// 调整商品数量
$('.shop-table').delegate('.goods_num', 'blur', function() {
var self = $(this);
var num = self.val();
var cart_id = self.parents('tr').data('cid');
$.ajax({
type: "POST",
url: '/ajax/changeNum',
data: {uid : user_id, num : num, cart_id : cart_id},
dataType: "json",
success: function(resp){
if (resp.errcode == 0) {
loading.lists(user_id, type); // 加载购物车列表
// var data = resp.data;
// self.parents('tr').find('.goods_price').text(data.goods_price);
// self.parents('tr').find('.goods_amount').text(data.goods_amount_format);
}
layer.msg(resp.errmsg);
},
})
})
// 删除商品
$('.shop-table').delegate('.remove-goods', 'click', function() {
var self = $(this);
var cart_id = self.parents('tr').data('cid');
layer.open({
title: '删除提示',
content: '确定删除该商品吗?',
btn: ['确定', '取消'],
btn1: function () {
$.ajax({
type: "POST",
url: '/ajax/deleteGoods',
data: {uid : user_id, cart_id : cart_id},
dataType: "json",
success: function(resp){
layer.msg(resp.errmsg);
// self.parents('tr').remove();
loading.lists(user_id, type); // 加载购物车列表
return false;
},
})
},
btn2: function (index) {
layer.close(index);
}
})
})
// 提交订单
$('.submit-order').click(function() {
var address_id = $('input[name=address_id]').val();
var address_name = $('input[name=address_name]').val();
var address_mobile = $('input[name=address_mobile]').val();
var type = $(this).data('type');
var cart_ids = [];
$('.shop-table tbody tr').each(function() {
var cid = $(this).data('cid');
cart_ids.push(cid);
})
if (cart_ids.length > 0) {
var datax = {
uid: user_id,
sale_id: sale_id,
address_id: address_id,
type: type,
cart_ids: cart_ids,
}
if (type == 3) { // 自营线下订单
datax.address_name = address_name;
datax.address_mobile = address_mobile;
}
$.ajax({
type: "POST",
url: '/ajax/create',
data: datax,
dataType: "json",
success: function(resp){
if (resp.errcode == 0) {
layer.msg(resp.errmsg);
location.href = '/addorder/success?order_id='+resp.data.order_id+'&type='+resp.data.type;
return false;
}
layer.msg(resp.errmsg);
},
})
} else {
layer.msg('请先添加商品');
}
})
},
lists: function(user_id, type=1) {
$.ajax({
type: 'post',
url: '/ajax/cartList',
data: {uid : user_id, type: type},
dataType: "json",
success: function(resp){
if (resp.errcode == 0) {
var list = resp.data.list;
var len = list.length;
var html = '';
var order_amount = 0;
if (len > 0) {
for (var i = 0; i < len; i++) {
html += '<tr data-cid="'+list[i].cart_id+'">'+
'<td>'+list[i].goods_name+'</td>'+
'<td>'+list[i].brand_name+'</td>'+
'<td><input type="text" class="goods_num" name="goods_num" value="'+list[i].goods_number+'"></td>'+
'<td class="goods_price">'+list[i].goods_price+'</td>'+
'<td class="goods_amount">'+list[i].goods_amount_format+'</td>'+
'<td>'+list[i].delivery_time+'</td>'+
'<td>'+list[i].supplier_name+'</td>'+
'<td><a class="btn btn-danger btn-xs remove-goods">删除</a></td>'+
'</tr>';
order_amount += list[i].goods_number * list[i].goods_price;
}
order_amount = parseFloat(order_amount).toFixed(4);
if (list[0].currency == 1) {
order_amount = '¥'+ order_amount;
} else {
order_amount = '$'+ order_amount;
}
$('.shop-lists').show();
$('.shop-table tbody').empty().append(html);
$('.amount-section').show();
$('.order_amount').empty().text(order_amount);
}
}
},
});
}
}
});
})(jQuery)
\ No newline at end of file
......@@ -1491,6 +1491,40 @@
});
})
// 自营审单
$('.self-check').click(function(){
var order_id = $(this).data('id');
layer.open({
title: '审核自营线下订单',
content: '确定审核通过吗?',
btn:['取消','确定'],
yes: function(index, layero){
layer.close(index);
},
btn2: function(index, layero){
$.ajax({
url: '/ajax/selfCheck',
type: 'post',
data: {order_id: order_id},
dataType:'json',
success: function(resp) {
if(resp.errcode === 0){
layer.msg(resp.errmsg || '操作成功');
setTimeout(function(){
location.reload();
}, 1000);
} else {
layer.alert(resp.errmsg || '网络异常');
}
},
error: function(err) {
console.log(err)
}
})
}
});
})
},
}
......
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>订单管理后台 | {{ $title }}</title>
<script>document.domain="{{ Config::get('website.domain') }}";</script>
@include('addOffline.css')
@include('addOffline.js')
</head>
<body class="body-small" style="min-width:1024px;">
<div id="wrapper">
<!-- layouts.navigation -->
@include('layouts.navigation')
@include('addOffline.content')
</div>
</body>
<div id="page-wrapper" class="gray-bg">
@include('layouts.header')
<div class="wrapper wrapper-content">
<div class="row">
<div class="col-lg-12">
<div class="ibox float-e-margins">
<form>
<div class="ibox-title" style="border-top:0;">
<h3>客户信息</h3>
</div>
<div class="ibox-content">
<div class="account-info">
<h4>账户信息 <span class="title-tips"><i class="fa fa-info-circle"></i> 此账号为内部下单账号,前台不可登录。</span></h4>
<input type="hidden" name="user_id" value="{{$internal_uid}}">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>手机号码:</span>
<span>{{Config('website.internal-account')}}</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>密码:</span>
<span>******</span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>测试账号:</span>
<span></span>
</div>
</div>
</div>
</div>
<div class="express-info">
<h4>快递信息</h4>
<input type="hidden" name="address_id" value="{{ $address->address_id }}">
<input type="hidden" name="address_name" value="{{ $name }}">
<input type="hidden" name="address_mobile" value="{{ $mobile }}">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>收货方式:</span>
<span>快递上门</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>联系人:</span>
<span>{{$name}}</span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>联系电话:</span>
<span>{{$mobile}}</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>收货地址:</span>
<span>{{ $address->province_val.$address->city_val.$address->district_val.$address->detail_address }}</span>
</div>
</div>
</div>
</div>
</div>
<div class="ibox-title">
<h3>商品信息</h3>
</div>
<div class="ibox-content">
<div class="row">
<style>
.search-sku{width: 240px !important;}
.label-prompt{padding: 6px 6px;}
.get-sku{padding: 3px 6px; margin-right: 20px;}
</style>
<div class="col-sm-6">
<input type="text" class="search-sku" name="sku_id" value="" placeholder="请输入SKUID">
<a class="btn btn-info get-sku">获取SKU信息</a>
<span>快捷入口:<a href="{{Config('website.search-sku-url-2')}}" target="_blank">查询SKU</a></span>
</div>
</div>
<!-- SKU信息 -->
<div class="sku-info">
<h4>型号信息</h4>
<div class="sku-info-left">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>SKU型号:</span>
<span class="goods_name"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>制造商:</span>
<span class="brand_name"></span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>供应商:</span>
<span class="supplier_name"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>库存数量:</span>
<span class="stock"></span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>起订量:</span>
<span class="moq"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>标准包装量:</span>
<span class="mpq"></span>
</div>
</div>
</div>
</div>
<div class="sku-info-right">
<table class="table table-hover ladder_price_table">
<tr>
<th>阶梯</th>
<th>RMB价格</th>
</tr>
</table>
</div>
<input type="hidden" name="goods_id" class="goods_id" value="">
<div class="clear"></div>
<a class="btn btn-success add-to-lists">添加至商品列表</a>
</div>
<!-- 商品列表 -->
<div class="shop-lists">
<table class="table table-bordered table-hover shop-table">
<thead>
<tr>
<th width="15%">商品型号</th>
<th width="15%">制造商</th>
<th width="10%">采购数量</th>
<th width="10%">采购单价</th>
<th width="10%">小计</th>
<th width="15%">货期</th>
<th width="15%">供应商</th>
<th width="10%">操作</th>
</tr>
</thead>
<tbody></tbody>
</table>
</div>
<!-- 订单金额 -->
<div class="amount-section">
<p>应付金额:<span class="text-danger order_amount"></span></p>
</div>
</div>
<div class="ibox-title" style="text-align: right;">
<a class="btn btn-success submit-order" data-type="3">提交</a>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<script>
var user_id = "{{$internal_uid}}";
var sale_id = "{{$sale_id}}";
var URL_api = "{{Config('website.api_domain')}}";
$.lie.add_order.offline();
</script>
\ No newline at end of file
<link href="/css/bootstrap.min.css" rel="stylesheet">
<link href="/font-awesome/css/font-awesome.css" rel="stylesheet">
<link href="/css/style.css" rel="stylesheet">
<link href="/layer/skin/layer.css" rel="stylesheet">
<link href="/css/order.css" rel="stylesheet">
<link href="/css/detail.css" rel="stylesheet">
\ No newline at end of file
<script src="/js/jquery-2.2.1.js"></script>
<script src="/js/jquery.form.js"></script>
<script src="/js/bootstrap.min.js"></script>
<script src="/layer/layer.js"></script>
<script src="/js/plugins/slimscroll/jquery.slimscroll.min.js"></script>
<script src="/js/plugins/metisMenu/jquery.metisMenu.js"></script>
<script src="/js/inspinia.min.js"></script>
<script src="/js/common.js"></script>
<script src="/js/add_order.js"></script>
<script src="/js/plugins/DatePicker/WdatePicker.js"></script>
<div id="page-wrapper" class="gray-bg">
@include('layouts.header')
<div class="wrapper wrapper-content">
<div class="row">
<div class="col-lg-12">
<div class="ibox float-e-margins">
<form>
<div class="ibox-title" style="border-top:0;">
<h3>客户信息</h3>
</div>
<div class="ibox-content">
<div class="account-info">
<h4>账户信息 <span class="title-tips"><i class="fa fa-info-circle"></i> 此账号为内部下单账号,前台不可登录。</span></h4>
<input type="hidden" name="user_id" value="{{$internal_uid}}">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>手机号码:</span>
<span>{{Config('website.internal-account')}}</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>密码:</span>
<span>******</span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>测试账号:</span>
<span></span>
</div>
</div>
</div>
</div>
<div class="express-info">
<h4>快递信息</h4>
<input type="hidden" name="address_id" value="{{ $address->address_id }}">
<input type="hidden" name="address_name" value="{{ $name }}">
<input type="hidden" name="address_mobile" value="{{ $mobile }}">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>收货方式:</span>
<span>快递上门</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>联系人:</span>
<span>{{$name}}</span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>联系电话:</span>
<span>{{$mobile}}</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>收货地址:</span>
<span>{{ $address->province_val.$address->city_val.$address->district_val.$address->detail_address }}</span>
</div>
</div>
</div>
</div>
</div>
<div class="ibox-title">
<h3>商品信息</h3>
</div>
<div class="ibox-content">
<div class="row">
<style>
.search-sku{width: 240px !important;}
.label-prompt{padding: 6px 6px;}
.get-sku{padding: 3px 6px; margin-right: 20px;}
</style>
<div class="col-sm-6">
<input type="text" class="search-sku" name="sku_id" value="" placeholder="请输入SKUID">
<a class="btn btn-info get-sku">获取SKU信息</a>
<span>快捷入口:<a href="{{Config('website.search-sku-url')}}" target="_blank">查询SKU</a></span>
</div>
</div>
<!-- SKU信息 -->
<div class="sku-info">
<h4>型号信息</h4>
<div class="sku-info-left">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>SKU型号:</span>
<span class="goods_name"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>制造商:</span>
<span class="brand_name"></span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>供应商:</span>
<span class="supplier_name"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>库存数量:</span>
<span class="stock"></span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>起订量:</span>
<span class="moq"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>标准包装量:</span>
<span class="mpq"></span>
</div>
</div>
</div>
</div>
<div class="sku-info-right">
<table class="table table-hover ladder_price_table">
<tr>
<th>阶梯</th>
<th>RMB价格</th>
</tr>
</table>
</div>
<div class="clear"></div>
<a class="btn btn-success add-to-lists">添加至商品列表</a>
</div>
<!-- 商品列表 -->
<div class="shop-lists">
<table class="table table-bordered table-hover shop-table">
<thead>
<tr>
<th width="15%">商品型号</th>
<th width="15%">制造商</th>
<th width="10%">采购数量</th>
<th width="10%">采购单价</th>
<th width="10%">小计</th>
<th width="15%">货期</th>
<th width="15%">供应商</th>
<th width="10%">操作</th>
</tr>
</thead>
<tbody></tbody>
</table>
</div>
<!-- 订单金额 -->
<div class="amount-section">
<p>应付金额:<span class="text-danger order_amount"></span></p>
</div>
</div>
<div class="ibox-title" style="text-align: right;">
<a class="btn btn-success submit-order" data-type="3">提交</a>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<script>
var user_id = "{{$internal_uid}}";
var sale_id = "{{$sale_id}}";
var URL_api = "{{Config('website.api_domain')}}";
$.lie.add_order.offline();
</script>
\ No newline at end of file
<div id="page-wrapper" class="gray-bg">
@include('layouts.header')
<div class="wrapper wrapper-content">
<div class="row">
<div class="col-lg-12">
<div class="ibox float-e-margins">
<form>
<div class="ibox-title" style="border-top:0;">
<h3>客户信息</h3>
</div>
<div class="ibox-content">
<div class="account-info">
<h4>账户信息 <span class="title-tips"><i class="fa fa-info-circle"></i> 此账号为内部下单账号,前台不可登录。</span></h4>
<input type="hidden" name="user_id" value="{{$internal_uid}}">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>手机号码:</span>
<span>{{Config('website.internal-account')}}</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>密码:</span>
<span>******</span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>测试账号:</span>
<span></span>
</div>
</div>
</div>
</div>
<div class="express-info">
<h4>快递信息</h4>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>收货方式:</span>
<span>快递上门</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>联系人:</span>
<span>{{$name}}</span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>联系电话:</span>
<span>{{$mobile}}</span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>收货地址:</span>
<span>广东省深圳市龙岗区坂田街道五和大道南路2号万科星火Online天枢仓6栋3楼</span>
</div>
</div>
</div>
</div>
</div>
<div class="ibox-title">
<h3>商品信息</h3>
</div>
<div class="ibox-content">
<div class="row">
<style>
.search-sku{width: 240px !important;}
.label-prompt{padding: 6px 6px;}
.get-sku{padding: 3px 6px; margin-right: 20px;}
</style>
<div class="col-sm-6">
<input type="text" class="search-sku" name="sku_id" value="" placeholder="请输入SKUID">
<a class="btn btn-info get-sku">获取SKU信息</a>
<span>快捷入口:<a href="{{Config('website.search-sku-url')}}" target="_blank">查询SKU</a></span>
</div>
</div>
<!-- SKU信息 -->
<div class="sku-info">
<h4>型号信息</h4>
<div class="sku-info-left">
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>SKU型号:</span>
<span class="goods_name"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>制造商:</span>
<span class="brand_name"></span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>供应商:</span>
<span class="supplier_name"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>库存数量:</span>
<span class="stock"></span>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="form-group">
<span>起订量:</span>
<span class="moq"></span>
</div>
</div>
<div class="col-sm-6">
<div class="form-group">
<span>标准包装量:</span>
<span class="mpq"></span>
</div>
</div>
</div>
</div>
<div class="sku-info-right">
<table class="table table-hover ladder_price_table">
<tr>
<th>阶梯</th>
<th>RMB价格</th>
</tr>
</table>
</div>
<input type="hidden" name="goods_id" class="goods_id" value="">
<input type="hidden" name="cn_delivery_time" class="cn_delivery_time" value="">
<div class="clear"></div>
<a class="btn btn-success add-to-lists">添加至商品列表</a>
</div>
<!-- 商品列表 -->
<div class="shop-lists">
<table class="table table-bordered table-hover shop-table">
<thead>
<tr>
<th width="15%">商品型号</th>
<th width="15%">制造商</th>
<th width="10%">采购数量</th>
<th width="10%">采购单价</th>
<th width="10%">小计</th>
<th width="15%">货期</th>
<th width="15%">供应商</th>
<th width="10%">操作</th>
</tr>
</thead>
<tbody></tbody>
</table>
</div>
</div>
<div class="ibox-title">
<h3>订单信息</h3>
</div>
<div class="ibox-content">
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<script>
var user_id = "{{$internal_uid}}";
var URL_api = "{{Config('website.api_domain')}}";
$.lie.add_order.offline();
</script>
\ No newline at end of file
......@@ -554,7 +554,7 @@
@endif
<!-- 预付款 管理员完成首款对账后改变'对账'按钮 -->
@if ($order_info['status'] >= 2 && in_array('check_account', $userPerms))
@if (in_array($order_info['status'], [2, 3]) && in_array('check_account', $userPerms))
@if ($order_info['status'] == 3 && (!empty($order_pay_log) && $order_pay_log[0]['pay_type'] != ''))
<a href="javascript:;" data-id="{{$order_info['order_id']}}" class="btn btn-default last-check">对账</a>
@else
......@@ -576,6 +576,10 @@
<p style="padding-left: 5px;">操作</p>
<div class="tabs-box">
<!-- 判断状态和权限 -->
@if ($order_info['status'] == 1)
<a class="btn btn-success self-check" data-id="{{$order_info['order_id']}}" class="btn btn-default">审单</a>
@endif
@if (in_array($order_info['status'], [2, 3, 4]) && in_array('self_order_cancel', $userPerms))
<a class="btn btn-default self_cancel" href="javascript:;" data-id="{{$order_info['order_id']}}" class="btn btn-default">取消订单</a>
@endif
......
<div class="row wrapper border-bottom white-bg page-heading">
<div class="col-lg-10" style="height:10px"></div>
<div class="col-lg-10">
<a class="navbar-minimalize minimalize-styl-2 btn btn-primary pull-left" style="margin-left:0px;margin-top:18px;" href="#"><i class="fa fa-bars"></i> </a>
<div class="col-lg-10" style="padding-left:0px;">
<h2>{{ $title }}</h2>
<ol class="breadcrumb">
@for ($i = 0; $i < count($paths); $i++)
......
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>订单管理后台 | {{ $title }}</title>
<script>document.domain="{{ Config::get('website.domain') }}";</script>
@include('addOffline.css')
@include('addOffline.js')
</head>
<body class="body-small" style="min-width:1024px;">
<div id="wrapper">
<!-- layouts.navigation -->
@include('layouts.navigation')
@include('success.content')
</div>
</body>
<div id="page-wrapper" class="gray-bg">
@include('layouts.header')
<div class="wrapper wrapper-content">
<div class="row">
<div class="col-lg-12">
<div class="ibox float-e-margins">
<div class="ibox-title" style="border-top:0;">
<?php
$currency = $order_info->currency == 1 ? '¥' : '$';
?>
<div class="section-1">
<img src="../img/success.png" alt="提交成功">
<h3>订单提交成功</h3>
<p>下单时间:{{ date('Y-m-d H:i:s', $order_info->create_time) }}</p>
<p class="title-tips"><i class="fa fa-info-circle"></i>为了方便后续操作,请将如下订单编号,备注在ERP中的采购单中。</p>
</div>
<div class="section-2">
<p>订单编号:{{ $order_info->order_sn }}</p>
<p>应付金额:<span class="text-danger">{{ $currency.$order_info->order_amount }}</span></p>
</div>
<div class="section-3">
<a class="btn btn-success" href="/self_order">查看订单</a>
<a class="btn btn-default" href="/add_offline">继续新增</a>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
// $.lie.add_order.offline();
</script>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment