Commit 43533a5b by mushishixian

temp

parent 72089b79
Showing with 444 additions and 55 deletions
......@@ -27,6 +27,7 @@ class SupplierApiController extends Controller
//默认要接收的数据
private $channelMap = [
'supplier_id',
'supplier_code',
//基础资料
'supplier_name',
'register_company_name',
......@@ -61,7 +62,7 @@ class SupplierApiController extends Controller
//附加费
'cn',
'us',
'hk',
// 'status',
//商品上传规则
......@@ -84,7 +85,7 @@ class SupplierApiController extends Controller
}
$channel = $request->only($this->channelMap);
$service = new SupplierService();
$result = $service->saveSupplier($channel, $request->get('contact'));
$result = $service->saveSupplier($channel);
if (!$result) {
$this->response(-1, '操作失败');
}
......
<?php
namespace App\Http\Services;
use App\Model\SupplierExtendModel;
class SupplierExtraFeeService
{
public function saveSupplierExtraFee($extraFee)
{
$supplierExtendFee = [];
if (!empty($extraFee['cn'])) {
$supplierExtendFee['cn'] = $extraFee['cn'];
}
if (!empty($extraFee['hk'])) {
$supplierExtendFee['hk'] = $extraFee['hk'];
}
if (empty($supplierExtendFee)) {
return true;
}
$model = new SupplierExtendModel();
$cache = $model->getExtendExtra($extraFee['supplier_code'], $extraFee['supplier_id']);
$extraFee['charge_content'] = json_encode($supplierExtendFee);
$supplierCode = $extraFee['supplier_code'];
unset($extraFee['hk'], $extraFee['cn'], $extraFee['supplier_code']);
if (empty($cache)) {
$model->add_change_extra($extraFee, $supplierCode);
} else {
$model->save_change_extra($extraFee, $supplierCode);
}
}
}
\ No newline at end of file
......@@ -4,6 +4,7 @@
namespace App\Http\Services;
use App\Http\Transformers\SupplierTransformer;
use App\Model\RedisModel;
use App\Model\SupplierAddressModel;
use App\Model\SupplierChannelModel;
use App\Model\SupplierContactModel;
......@@ -32,6 +33,18 @@ class SupplierService
return array_get($snMap, $supplierGroup, "ERR") . $supplierCodeNumber;
}
//保存价格系数到redis
public function saveRatioToRedis($supplierId)
{
$model = new SupplierChannelModel();
$supplier = $model->where('supplier_id', $supplierId)->first()->toArray();
$Redis = new RedisModel();
$pre = config('fixed.SUPPLIER_RATION');
$data = array_only($supplier, ['cn_delivery_time', 'us_delivery_time', 'cn_ratio', 'us_ratio', 'supplier_id']);
$data['supplier_id'] = strval($data['supplier_id']);
$Redis->hset($pre, $supplier['supplier_code'], json_encode($data));
}
public function saveSupplier($channel)
{
//先处理下数据
......@@ -54,18 +67,20 @@ class SupplierService
//走事务
return DB::connection('web')->transaction(function () use ($channel) {
$model = new SupplierChannelModel();
$contactModel = new SupplierContactModel();
$contactService = new SupplierContactService();
$extraFax = [
'us' => $channel['us'],
'supplier_id' => $channel['supplier_id'],
'supplier_code' => $channel['supplier_code'],
'hk' => $channel['hk'],
'cn' => $channel['cn'],
];
$address = array_only($channel,
['supplier_id', 'shipping_address', 'return_address', 'return_consignee', 'return_phone']);
$supplierAddressService = new SupplierAddressService();
$supplierAddressService->saveAddress($address);
//插入
unset($channel['us'], $channel['cn'], $channel['return_phone'], $channel['return_address'],
unset($channel['hk'], $channel['cn'], $channel['return_phone'], $channel['return_address'],
$channel['return_consignee'], $channel['shipping_address'], $channel['cn_delivery_time_period'], $channel['us_delivery_time_period']);
if (empty($channel['supplier_id'])) {
//先去插入到channel表
......@@ -75,10 +90,15 @@ class SupplierService
$supplierId = $model->insertGetId($channel);
$this->saveSupplierCode($supplierId);
} else {
$extraFaxService = new SupplierExtraFeeService();
$extraFaxService->saveSupplierExtraFee($extraFax);
$supplierId = $channel['supplier_id'];
$model->where('supplier_id', $supplierId)->update($channel);
$this->saveSupplierCode($supplierId);
}
//插入系数到redis
$this->saveRatioToRedis($supplierId);
$supplierSn = $this->generateSupplierSn($supplierId, $channel['supplier_group']);
//修改数据
$model->where('supplier_id', $supplierId)->update(['supplier_sn' => $supplierSn]);
......
......@@ -9,6 +9,7 @@ use App\Http\Services\ViewCheckService;
use App\Model\IntracodeModel;
use App\Model\RedisModel;
use App\Model\SupplierContactModel;
use App\Model\SupplierExtendModel;
class SupplierTransformer
{
......@@ -100,7 +101,8 @@ class SupplierTransformer
$supplier['region_name'] = array_get(config('fixed.Region'), $supplier['region']);
$supplier['currency_name'] = array_get(config('fixed.Currency'), $supplier['currency']);
$supplier['supplier_group_name'] = array_get(config('fixed.SupplierGroup'), $supplier['supplier_group']);
$supplier['pay_type_name'] = array_get(config('fixed.PayType'), $supplier['pay_type']);
$supplier['pay_type_name'] = array_get(config('fixed.SupplierPayType'), $supplier['pay_type']);
$supplier['trading_method_name'] = array_get(config('fixed.TradingMethod'), $supplier['trading_method']);
$supplier['main_brand_names'] = $this->getMainBrandNames($supplier['main_brands']);
$supplier['update_time'] = $supplier['update_time'] ? date('Y-m-d H:i:s', $supplier['update_time']) : '';
$supplier['create_time'] = $supplier['create_time'] ? date('Y-m-d H:i:s', $supplier['create_time']) : '';
......@@ -109,28 +111,39 @@ class SupplierTransformer
$supplier['qualification_photos'] = $this->getPhotosDataForForm($supplier['qualification_photos']);
$supplier['sku_upload_ruler'] = json_decode($supplier['sku_upload_ruler'], true);
$supplier['is_channel_or_purchase_user_view'] = $this->getIsChannelOrPurchaseUserView($supplier);
if (!empty($supplier['contact'])) {
$adminUserService = new AdminUserService();
foreach ($supplier['contact'] as &$contact) {
$user = $adminUserService->getAdminUserInfo($contact['can_check_uids']);
$contact['can_check_name'] = array_get($user, 'name');
if (empty($contact['can_check_name'])) {
$user = $adminUserService->getAdminUserInfo($supplier['create_uid']);
$contact['can_check_name'] = array_get($user, 'name');
}
}
}
$supplier = $this->transformDeliveryTimeData($supplier);
$ExtendModel = new SupplierExtendModel();
//获取该supplier_code对应的数据
$supplier['extra_fee'] = $ExtendModel->getExtendExtra($supplier['supplier_code'], $supplier['supplier_id']);
return $supplier;
}
private function transformDeliveryTimeData($supplier)
{
$supplier['cn_delivery_time_period'] = strpos($supplier['cn_delivery_time'], '天') !== false ? '天' : '周';
$supplier['us_delivery_time_period'] = strpos($supplier['us_delivery_time'], '天') !== false ? '天' : '周';
$supplier['cn_delivery_time'] = str_replace('天', '', $supplier['cn_delivery_time']);
$supplier['cn_delivery_time'] = str_replace('周', '', $supplier['cn_delivery_time']);
$supplier['us_delivery_time'] = str_replace('天', '', $supplier['us_delivery_time']);
$supplier['us_delivery_time'] = str_replace('周', '', $supplier['us_delivery_time']);
return $supplier;
}
private function getPhotosDataForForm($photos)
{
$data = [];
if (empty($photos)) {
return [];
}
$photos = json_decode($photos, true);
foreach ($photos as $name=>$photo) {
if (empty($photos['business_license'])){
return [];
}
$data = [];
foreach ($photos as $name => $photo) {
$data[$name] = [
'value' => $photo['url'] . '|_|' . $photo['file_name'],
'file_name' => $photo['file_name'],
'file_name' => $photo['file_name'] ? : '选择文件上传',
'url' => $photo['url'],
];
}
return $data;
......
......@@ -21,6 +21,10 @@ class SupplierValidator
'stockup_type' => 'required',
'supplier_group' => 'required',
'region' => 'required',
'cn_delivery_time' => 'regex:/^\d+\-\d$/',
'us_delivery_time' => 'regex:/^\d+\-\d$/',
'cn_ratio' => 'min:1',
'us_ratio' => 'min:1',
'contact.supplier_consignee.*' => 'required|max:50',
'contact.supplier_mobile.*' => 'required|max:30',
'contact.supplier_telephone.*' => 'max:30',
......@@ -66,6 +70,10 @@ class SupplierValidator
'supplier_group.required' => '行业性质不能为空',
'region.required' => '所属区域不能为空',
'purchase_uid.required' => '渠道开发员不能为空',
'cn_ratio.min' => '人民币系数必须是大于1的浮点数',
'us_ratio.min' => '美金系数必须是大于1的浮点数',
'us_delivery_time.regex' => '香港货期格式不正确',
'cn_delivery_time.regex' => '大陆货期格式不正确',
'tax_number.required' => '如果选择币种为人民币,则公司税号不能为空',
'contact.supplier_consignee.*.required' => '联系方式的联系人不能为空',
'contact.supplier_consignee.*.max' => '联系方式的联系人不能超过50个字符',
......
<?php
namespace App\Model;
use Illuminate\Database\Eloquent\Model;
use Request;
use RedisDB;
class SupplierExtendModel extends Model
{
protected $connection='web';
protected $table='supplier_extend';
public $timestamps = false;
/*
* 方法作废于20200402,原因附加费改版
*/
public function AddInfo($supplierID='', $supplierSn='', $data='', $isUpdate = false){
if(empty($supplierID) || empty($data) || !is_array($data)) return false;
empty($data['price']) && $data['price'] = 0;
empty($data['max']) && $data['max'] = 0;
$charge_content[0] = [
'max' => $data['max'],
'price' => $data['price'],
];
$charge_content_json = json_encode($charge_content);
$Add['charge_content'] = $charge_content_json;
if (!empty($isUpdate)) { // 编辑
$Add['update_time'] = time();
$Add['status'] = $data['status'];
$res = $this->where('supplier_id','=',$supplierID)->update($Add);
// 修改redis
if (!empty($data['status']) && $data['status'] == '-1') { // 禁用
$charge_content_json = '';
}
} else { // 新增
$Add['supplier_id'] = $supplierID;
$Add['create_time'] = time();
$res = $this->insert($Add);
}
//redis 处理
$Redis = RedisDB::connection();
$pre = Config('fixed.SUPPLIER_REDIS_PRE');
$SUPPLIER_ID = Config('fixed.SUPPLIER_ID'); // 联营供应商ID 17
$Redis->hset($pre, $SUPPLIER_ID. '.' . $supplierSn, $charge_content_json); // 联营供应商ID是17,储存内容格式如下{"max":2000,"price":10}
return $res;
}
public function ExtendInfo($SupplierID=''){
$collert=Request::only('supplier_id');
$collert=TrimX($collert,true,['supplier_id']);
empty($collert) && $collert['supplier_id']=$SupplierID;
if(empty($collert['supplier_id'])) return false;
$info=$this->where('supplier_id','=',$collert['supplier_id'])->first();
if(!$info) return false;$info = $info->toArray();
if (!empty($info)) {
if ($info['charge_content']) {
$charge_content = json_decode($info['charge_content'], true);
$info['charge_content'] = $charge_content;
}
}
return $info ? $info : '';
}
// 获取附加费信息
public function getExtendExtra($SupplierCode='', $SupplierID=''){
if(empty($SupplierCode)) return false;
$Redis = new RedisModel();
$pre = Config('fixed.SUPPLIER_REDIS_PRE');
$SUPPLIER_ID = Config('fixed.SUPPLIER_ID'); // 联营供应商ID 17
$extendInfo = $Redis->hget($pre, $SUPPLIER_ID. '.' . $SupplierCode); // 联营供应商ID是17,储存内容格式如下{"max":2000,"price":10}
if (empty($extendInfo)) {
$charge_content = $this->select(['charge_content'])->where('supplier_id','=',$SupplierID)->where('status', '=', 1)->first();
if (!empty($charge_content)) {
$charge_content = $charge_content->toArray();
$extendInfo = $charge_content['charge_content'];
}
if (!empty($extendInfo)) {
$Redis->hset($pre, $SUPPLIER_ID. '.' . $SupplierCode, $extendInfo);
}
}
if ($extendInfo) {
$extendInfo = json_decode($extendInfo, true);
}
return $extendInfo ? $extendInfo : '';
}
/**
* 此方法废弃于20200402,原因是附加费改版
* @param string $UserInfo
* @return array
*/
private function changeExtra($UserInfo=''){
// return [20001,'新增供应商失败'];
$arr=['extra'];
$collert=Request::only($arr);
$collert=TrimX($collert,true,$arr);
$extra = $collert['extra'];
// 根据supplier_code 和supplier_id
$extra['status'] = '1'; // 目前暂时皆为1启用(默认)
$re = $this->select(['supplier_id'])->where('supplier_id', '=', $extra['supplier_id'])->get()->toArray();
$isUpdate = false;
if (!empty($re[0]['supplier_id'])) $isUpdate = true;
$FeeInfo=$this->getExtendExtra($extra['supplier_code'],$extra['supplier_id']);
$res = $this->AddInfo($extra['supplier_id'], $extra['supplier_code'], $extra, $isUpdate);
if ($res) {
$url=Config('website.Feer_Robot_Url');
$UserModel=new UserModel();
$UserName=$UserModel->FinduserInfoName($UserInfo->userId);
$RemindInfo ='附加费调整通知'."\n";
$RemindInfo .='渠道编码:'.$extra['supplier_code']."\n";
if($FeeInfo){
$RemindInfo .='原附加费:不满'.$FeeInfo['max'].'收取'.$FeeInfo['price']."运费\n";
}
$RemindInfo .='新附加费:不满'.$extra['max'].'收取'.$extra['price']."运费\n";
$RemindInfo .='调整人:'.$UserName;
if(config('website.data')=='http://supplier.ichunt.net') SendRobot($url,$RemindInfo);
return [0,'修改成功'];
} else {
return [11010,'修改失败,失败原因:数据库修改更新失败'];
}
}
public function save_change_extra($data, $supplier_code){
$data['status'] = 1;
$data['update_time'] = time();
$res = $this->where('supplier_id','=',$data['supplier_id'])->update($data);
if(!$res){
return false;
}
$this->set_change_extra_cache($supplier_code, $data['charge_content']);
return true;
}
public function add_change_extra($data, $supplier_code){
$data['status'] = 1;
$data['create_time'] = time();
$data['update_time'] = time();
$res = $this->insert($data);
if(!$res){
return false;
}
$this->set_change_extra_cache($supplier_code, $data['charge_content']);
return true;
}
public function set_change_extra_cache($supplier_code, $charge_content){
$Redis = new RedisModel();
$pre = Config('fixed.SUPPLIER_REDIS_PRE');
$SUPPLIER_ID = Config('fixed.SUPPLIER_ID'); // 联营供应商ID 17
// 联营供应商ID是17
$Redis->hset($pre, $SUPPLIER_ID. '.' . $supplier_code, $charge_content);
return true;
}
}
\ No newline at end of file
......@@ -31,6 +31,7 @@ class TransformableInputPresenter
let form = layui.form;
form.on('select($unique)', function(data){
data.othis.parent().parent().parent().find('input').attr('name',data.value);
form.render();
});
});
</script>
......
......@@ -316,4 +316,18 @@ return [
1=>'先款后货',
2 => '月结',
],
'FileNameMapping'=>[
'business_license' => '营业执照',
'billing_information' => '开票资料',
'registration_certificate' => '商业登记证',
'incorporation_certificate' => '公司注册证',
'certification_notice' => '认证通知书',
'supplier_survey' => '供应商调查表',
'proxy_certificate' => '代理证',
'quality_assurance_agreement' => '品质保证协议',
'confidentiality_agreement' => '保密协议',
'cooperation_agreement' => '合作协议',
'other_attachment' => '其它附件',
]
];
/** layui-v2.5.6 MIT License By https://www.layui.com */
/** layui-v2.5.6 MIT License By https://www.layui.com */
blockquote,body,button,dd,div,dl,dt,form,h1,h2,h3,h4,h5,h6,input,legend,li,ol,p,td,textarea,th,ul{margin:0;padding:0;-webkit-tap-highlight-color:rgba(0,0,0,0)}html{font:12px 'Helvetica Neue','PingFang SC',STHeitiSC-Light,Helvetica,Arial,sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}a,button,input{-webkit-tap-highlight-color:rgba(255,0,0,0)}a{text-decoration:none;background:0 0}a:active,a:hover{outline:0}table{border-collapse:collapse;border-spacing:0}li{list-style:none}b,strong{font-weight:700}h1,h2,h3,h4,h5,h6{font-weight:500}address,cite,dfn,em,var{font-style:normal}dfn{font-style:italic}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}img{border:0;vertical-align:bottom}.layui-inline,input,label{vertical-align:middle}button,input,optgroup,select,textarea{color:inherit;font:inherit;margin:0;outline:0}button,select{text-transform:none}select{-webkit-appearance:none;border:none}input{line-height:normal}input[type=checkbox],input[type=radio]{box-sizing:border-box;padding:0}input[type=number]::-webkit-inner-spin-button,input[type=number]::-webkit-outer-spin-button{height:auto}input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}@font-face{font-family:layui-icon;src:url(../font/iconfont.eot?v=1.0.7);src:url(../font/iconfont.eot?v=1.0.7#iefix) format('embedded-opentype'),url(../font/iconfont.woff?v=1.0.7) format('woff'),url(../font/iconfont.ttf?v=1.0.7) format('truetype'),url(../font/iconfont.svg?v=1.0.7#iconfont) format('svg')}.layui-icon{font-family:layui-icon!important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.layui-box,.layui-box *{-webkit-box-sizing:content-box!important;-moz-box-sizing:content-box!important;box-sizing:content-box!important}.layui-border-box,.layui-border-box *{-webkit-box-sizing:border-box!important;-moz-box-sizing:border-box!important;box-sizing:border-box!important}.layui-inline{position:relative;display:inline-block;*display:inline;*zoom:1}.layui-edge,.layui-upload-iframe{position:absolute;width:0;height:0}.layui-edge{border-style:dashed;border-color:transparent;overflow:hidden}.layui-elip{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layui-unselect{-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none}.layui-disabled,.layui-disabled:active{background-color:#d2d2d2!important;color:#fff!important;cursor:not-allowed!important}.layui-circle{border-radius:100%}.layui-show{display:block!important}.layui-hide{display:none!important}.layui-upload-iframe{border:0;visibility:hidden}.layui-upload-enter{border:1px solid #009E94;background-color:#009E94;color:#fff;-webkit-transform:scale(1.1);transform:scale(1.1)}@-webkit-keyframes layui-m-anim-scale{0%{opacity:0;-webkit-transform:scale(.5);transform:scale(.5)}100%{opacity:1;-webkit-transform:scale(1);transform:scale(1)}}@keyframes layui-m-anim-scale{0%{opacity:0;-webkit-transform:scale(.5);transform:scale(.5)}100%{opacity:1;-webkit-transform:scale(1);transform:scale(1)}}.layui-m-anim-scale{animation-name:layui-m-anim-scale;-webkit-animation-name:layui-m-anim-scale}@-webkit-keyframes layui-m-anim-up{0%{opacity:0;-webkit-transform:translateY(800px);transform:translateY(800px)}100%{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes layui-m-anim-up{0%{opacity:0;-webkit-transform:translateY(800px);transform:translateY(800px)}100%{opacity:1;-webkit-transform:translateY(0);transform:translateY(0)}}.layui-m-anim-up{-webkit-animation-name:layui-m-anim-up;animation-name:layui-m-anim-up}@-webkit-keyframes layui-m-anim-left{0%{-webkit-transform:translateX(100%);transform:translateX(100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}@keyframes layui-m-anim-left{0%{-webkit-transform:translateX(100%);transform:translateX(100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}.layui-m-anim-left{-webkit-animation-name:layui-m-anim-left;animation-name:layui-m-anim-left}@-webkit-keyframes layui-m-anim-right{0%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}@keyframes layui-m-anim-right{0%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}100%{-webkit-transform:translateX(0);transform:translateX(0)}}.layui-m-anim-right{-webkit-animation-name:layui-m-anim-right;animation-name:layui-m-anim-right}@-webkit-keyframes layui-m-anim-lout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}@keyframes layui-m-anim-lout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(-100%);transform:translateX(-100%)}}.layui-m-anim-lout{-webkit-animation-name:layui-m-anim-lout;animation-name:layui-m-anim-lout}@-webkit-keyframes layui-m-anim-rout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(100%);transform:translateX(100%)}}@keyframes layui-m-anim-rout{0%{-webkit-transform:translateX(0);transform:translateX(0)}100%{-webkit-transform:translateX(100%);transform:translateX(100%)}}.layui-m-anim-rout{-webkit-animation-name:layui-m-anim-rout;animation-name:layui-m-anim-rout}.layui-m-layer{position:relative;z-index:19891014}.layui-m-layer *{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.layui-m-layermain,.layui-m-layershade{position:fixed;left:0;top:0;width:100%;height:100%}.layui-m-layershade{background-color:rgba(0,0,0,.7);pointer-events:auto}.layui-m-layermain{display:table;font-family:Helvetica,arial,sans-serif;pointer-events:none}.layui-m-layermain .layui-m-layersection{display:table-cell;vertical-align:middle;text-align:center}.layui-m-layerchild{position:relative;display:inline-block;text-align:left;background-color:#fff;font-size:14px;border-radius:5px;box-shadow:0 0 8px rgba(0,0,0,.1);pointer-events:auto;-webkit-overflow-scrolling:touch;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:.2s;animation-duration:.2s}.layui-m-layer0 .layui-m-layerchild{width:90%;max-width:640px}.layui-m-layer1 .layui-m-layerchild{border:none;border-radius:0}.layui-m-layer2 .layui-m-layerchild{width:auto;max-width:260px;min-width:40px;border:none;background:0 0;box-shadow:none;color:#fff}.layui-m-layerchild h3{padding:0 10px;height:60px;line-height:60px;font-size:16px;font-weight:400;border-radius:5px 5px 0 0;text-align:center}.layui-m-layerbtn span,.layui-m-layerchild h3{text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.layui-m-layercont{padding:50px 30px;line-height:22px;text-align:center}.layui-m-layer1 .layui-m-layercont{padding:0;text-align:left}.layui-m-layer2 .layui-m-layercont{text-align:center;padding:0;line-height:0}.layui-m-layer2 .layui-m-layercont i{width:25px;height:25px;margin-left:8px;display:inline-block;background-color:#fff;border-radius:100%;-webkit-animation:layui-m-anim-loading 1.4s infinite ease-in-out;animation:layui-m-anim-loading 1.4s infinite ease-in-out;-webkit-animation-fill-mode:both;animation-fill-mode:both}.layui-m-layerbtn,.layui-m-layerbtn span{position:relative;text-align:center;border-radius:0 0 5px 5px}.layui-m-layer2 .layui-m-layercont p{margin-top:20px}@-webkit-keyframes layui-m-anim-loading{0%,100%,80%{transform:scale(0);-webkit-transform:scale(0)}40%{transform:scale(1);-webkit-transform:scale(1)}}@keyframes layui-m-anim-loading{0%,100%,80%{transform:scale(0);-webkit-transform:scale(0)}40%{transform:scale(1);-webkit-transform:scale(1)}}.layui-m-layer2 .layui-m-layercont i:first-child{margin-left:0;-webkit-animation-delay:-.32s;animation-delay:-.32s}.layui-m-layer2 .layui-m-layercont i.layui-m-layerload{-webkit-animation-delay:-.16s;animation-delay:-.16s}.layui-m-layer2 .layui-m-layercont>div{line-height:22px;padding-top:7px;margin-bottom:20px;font-size:14px}.layui-m-layerbtn{display:box;display:-moz-box;display:-webkit-box;width:100%;height:50px;line-height:50px;font-size:0;border-top:1px solid #D0D0D0;background-color:#F2F2F2}.layui-m-layerbtn span{display:block;-moz-box-flex:1;box-flex:1;-webkit-box-flex:1;font-size:14px;cursor:pointer}.layui-m-layerbtn span[yes]{color:#40AFFE}.layui-m-layerbtn span[no]{border-right:1px solid #D0D0D0;border-radius:0 0 0 5px}.layui-m-layerbtn span:active{background-color:#F6F6F6}.layui-m-layerend{position:absolute;right:7px;top:10px;width:30px;height:30px;border:0;font-weight:400;background:0 0;cursor:pointer;-webkit-appearance:none;font-size:30px}.layui-m-layerend::after,.layui-m-layerend::before{position:absolute;left:5px;top:15px;content:'';width:18px;height:1px;background-color:#999;transform:rotate(45deg);-webkit-transform:rotate(45deg);border-radius:3px}.layui-m-layerend::after{transform:rotate(-45deg);-webkit-transform:rotate(-45deg)}body .layui-m-layer .layui-m-layer-footer{position:fixed;width:95%;max-width:100%;margin:0 auto;left:0;right:0;bottom:10px;background:0 0}.layui-m-layer-footer .layui-m-layercont{padding:20px;border-radius:5px 5px 0 0;background-color:rgba(255,255,255,.8)}.layui-m-layer-footer .layui-m-layerbtn{display:block;height:auto;background:0 0;border-top:none}.layui-m-layer-footer .layui-m-layerbtn span{background-color:rgba(255,255,255,.8)}.layui-m-layer-footer .layui-m-layerbtn span[no]{color:#FD482C;border-top:1px solid #c2c2c2;border-radius:0 0 5px 5px}.layui-m-layer-footer .layui-m-layerbtn span[yes]{margin-top:10px;border-radius:5px}body .layui-m-layer .layui-m-layer-msg{width:auto;max-width:90%;margin:0 auto;bottom:-150px;background-color:rgba(0,0,0,.7);color:#fff}.layui-m-layer-msg .layui-m-layercont{padding:10px 20px}
\ No newline at end of file
/** layui-v2.5.6 MIT License By https://www.layui.com */
/** layui-v2.5.6 MIT License By https://www.layui.com */
html #layuicss-skincodecss{display:none;position:absolute;width:1989px}.layui-code-h3,.layui-code-view{position:relative;font-size:12px}.layui-code-view{display:block;margin:10px 0;padding:0;border:1px solid #e2e2e2;border-left-width:6px;background-color:#F2F2F2;color:#333;font-family:Courier New}.layui-code-h3{padding:0 10px;height:32px;line-height:32px;border-bottom:1px solid #e2e2e2}.layui-code-h3 a{position:absolute;right:10px;top:0;color:#999}.layui-code-view .layui-code-ol{position:relative;overflow:auto}.layui-code-view .layui-code-ol li{position:relative;margin-left:45px;line-height:20px;padding:0 5px;border-left:1px solid #e2e2e2;list-style-type:decimal-leading-zero;*list-style-type:decimal;background-color:#fff}.layui-code-view pre{margin:0}.layui-code-notepad{border:1px solid #0C0C0C;border-left-color:#3F3F3F;background-color:#0C0C0C;color:#C2BE9E}.layui-code-notepad .layui-code-h3{border-bottom:none}.layui-code-notepad .layui-code-ol li{background-color:#3F3F3F;border-left:none}
\ No newline at end of file
/** layui-v2.5.6 MIT License By https://www.layui.com */
/** layui-v2.5.6 MIT License By https://www.layui.com */
.laydate-set-ym,.layui-laydate,.layui-laydate *,.layui-laydate-list{box-sizing:border-box}html #layuicss-laydate{display:none;position:absolute;width:1989px}.layui-laydate *{margin:0;padding:0}.layui-laydate{position:absolute;z-index:66666666;margin:5px 0;border-radius:2px;font-size:14px;-webkit-animation-duration:.3s;animation-duration:.3s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-name:laydate-upbit;animation-name:laydate-upbit}.layui-laydate-main{width:272px}.layui-laydate-content td,.layui-laydate-header *,.layui-laydate-list li{transition-duration:.3s;-webkit-transition-duration:.3s}@-webkit-keyframes laydate-upbit{from{-webkit-transform:translate3d(0,20px,0);opacity:.3}to{-webkit-transform:translate3d(0,0,0);opacity:1}}@keyframes laydate-upbit{from{transform:translate3d(0,20px,0);opacity:.3}to{transform:translate3d(0,0,0);opacity:1}}.layui-laydate-static{position:relative;z-index:0;display:inline-block;margin:0;-webkit-animation:none;animation:none}.laydate-ym-show .laydate-next-m,.laydate-ym-show .laydate-prev-m{display:none!important}.laydate-ym-show .laydate-next-y,.laydate-ym-show .laydate-prev-y{display:inline-block!important}.laydate-time-show .laydate-set-ym span[lay-type=month],.laydate-time-show .laydate-set-ym span[lay-type=year],.laydate-time-show .layui-laydate-header .layui-icon,.laydate-ym-show .laydate-set-ym span[lay-type=month]{display:none!important}.layui-laydate-header{position:relative;line-height:30px;padding:10px 70px 5px}.laydate-set-ym span,.layui-laydate-header i{padding:0 5px;cursor:pointer}.layui-laydate-header *{display:inline-block;vertical-align:bottom}.layui-laydate-header i{position:absolute;top:10px;color:#999;font-size:18px}.layui-laydate-header i.laydate-prev-y{left:15px}.layui-laydate-header i.laydate-prev-m{left:45px}.layui-laydate-header i.laydate-next-y{right:15px}.layui-laydate-header i.laydate-next-m{right:45px}.laydate-set-ym{width:100%;text-align:center;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.laydate-time-text{cursor:default!important}.layui-laydate-content{position:relative;padding:10px;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none}.layui-laydate-content table{border-collapse:collapse;border-spacing:0}.layui-laydate-content td,.layui-laydate-content th{width:36px;height:30px;padding:5px;text-align:center}.layui-laydate-content td{position:relative;cursor:pointer}.laydate-day-mark{position:absolute;left:0;top:0;width:100%;height:100%;line-height:30px;font-size:12px;overflow:hidden}.laydate-day-mark::after{position:absolute;content:'';right:2px;top:2px;width:5px;height:5px;border-radius:50%}.layui-laydate-footer{position:relative;height:46px;line-height:26px;padding:10px 20px}.layui-laydate-footer span{margin-right:15px;display:inline-block;cursor:pointer;font-size:12px}.layui-laydate-footer span:hover{color:#5FB878}.laydate-footer-btns{position:absolute;right:10px;top:10px}.laydate-footer-btns span{height:26px;line-height:26px;margin:0 0 0 -1px;padding:0 10px;border:1px solid #C9C9C9;background-color:#fff;white-space:nowrap;vertical-align:top;border-radius:2px}.layui-laydate-list>li,.layui-laydate-range .layui-laydate-main{display:inline-block;vertical-align:middle}.layui-laydate-list{position:absolute;left:0;top:0;width:100%;height:100%;padding:10px;background-color:#fff}.layui-laydate-list>li{position:relative;width:33.3%;height:36px;line-height:36px;margin:3px 0;text-align:center;cursor:pointer}.laydate-month-list>li{width:25%;margin:17px 0}.laydate-time-list>li{height:100%;margin:0;line-height:normal;cursor:default}.laydate-time-list p{position:relative;top:-4px;line-height:29px}.laydate-time-list ol{height:181px;overflow:hidden}.laydate-time-list>li:hover ol{overflow-y:auto}.laydate-time-list ol li{width:130%;padding-left:33px;line-height:30px;text-align:left;cursor:pointer}.layui-laydate-hint{position:absolute;top:115px;left:50%;width:250px;margin-left:-125px;line-height:20px;padding:15px;text-align:center;font-size:12px}.layui-laydate-range{width:546px}.layui-laydate-range .laydate-main-list-0 .laydate-next-m,.layui-laydate-range .laydate-main-list-0 .laydate-next-y,.layui-laydate-range .laydate-main-list-1 .laydate-prev-m,.layui-laydate-range .laydate-main-list-1 .laydate-prev-y{display:none}.layui-laydate-range .laydate-main-list-1 .layui-laydate-content{border-left:1px solid #e2e2e2}.layui-laydate,.layui-laydate-hint{border:1px solid #d2d2d2;box-shadow:0 2px 4px rgba(0,0,0,.12);background-color:#fff;color:#666}.layui-laydate-header{border-bottom:1px solid #e2e2e2}.layui-laydate-header i:hover,.layui-laydate-header span:hover{color:#5FB878}.layui-laydate-content{border-top:none 0;border-bottom:none 0}.layui-laydate-content th{font-weight:400;color:#333}.layui-laydate-content td{color:#666}.layui-laydate-content td.laydate-selected{background-color:#00F7DE}.laydate-selected:hover{background-color:#00F7DE!important}.layui-laydate-content td:hover,.layui-laydate-list li:hover{background-color:#eaeaea;color:#333}.laydate-time-list li ol{margin:0;padding:0;border:1px solid #e2e2e2;border-left-width:0}.laydate-time-list li:first-child ol{border-left-width:1px}.laydate-time-list>li:hover{background:0 0}.layui-laydate-content .laydate-day-next,.layui-laydate-content .laydate-day-prev{color:#d2d2d2}.laydate-selected.laydate-day-next,.laydate-selected.laydate-day-prev{background-color:#f8f8f8!important}.layui-laydate-footer{border-top:1px solid #e2e2e2}.layui-laydate-hint{color:#FF5722}.laydate-day-mark::after{background-color:#5FB878}.layui-laydate-content td.layui-this .laydate-day-mark::after{display:none}.layui-laydate-footer span[lay-type=date]{color:#5FB878}.layui-laydate .layui-this{background-color:#009688!important;color:#fff!important}.layui-laydate .laydate-disabled,.layui-laydate .laydate-disabled:hover{background:0 0!important;color:#d2d2d2!important;cursor:not-allowed!important;-moz-user-select:none;-webkit-user-select:none;-ms-user-select:none}.laydate-theme-molv{border:none}.laydate-theme-molv.layui-laydate-range{width:548px}.laydate-theme-molv .layui-laydate-main{width:274px}.laydate-theme-molv .layui-laydate-header{border:none;background-color:#009688}.laydate-theme-molv .layui-laydate-header i,.laydate-theme-molv .layui-laydate-header span{color:#f6f6f6}.laydate-theme-molv .layui-laydate-header i:hover,.laydate-theme-molv .layui-laydate-header span:hover{color:#fff}.laydate-theme-molv .layui-laydate-content{border:1px solid #e2e2e2;border-top:none;border-bottom:none}.laydate-theme-molv .laydate-main-list-1 .layui-laydate-content{border-left:none}.laydate-theme-grid .laydate-month-list>li,.laydate-theme-grid .laydate-year-list>li,.laydate-theme-grid .layui-laydate-content td,.laydate-theme-grid .layui-laydate-content thead,.laydate-theme-molv .layui-laydate-footer{border:1px solid #e2e2e2}.laydate-theme-grid .laydate-selected,.laydate-theme-grid .laydate-selected:hover{background-color:#f2f2f2!important;color:#009688!important}.laydate-theme-grid .laydate-selected.laydate-day-next,.laydate-theme-grid .laydate-selected.laydate-day-prev{color:#d2d2d2!important}.laydate-theme-grid .laydate-month-list,.laydate-theme-grid .laydate-year-list{margin:1px 0 0 1px}.laydate-theme-grid .laydate-month-list>li,.laydate-theme-grid .laydate-year-list>li{margin:0 -1px -1px 0}.laydate-theme-grid .laydate-year-list>li{height:43px;line-height:43px}.laydate-theme-grid .laydate-month-list>li{height:71px;line-height:71px}
\ No newline at end of file
This diff could not be displayed because it is too large.
/** layui-v2.5.6 MIT License By https://www.layui.com */
/** layui-v2.5.6 MIT License By https://www.layui.com */
;!function(e){"use strict";var t=document,n={modules:{},status:{},timeout:10,event:{}},r=function(){this.v="2.5.6"},o=function(){var e=t.currentScript?t.currentScript.src:function(){for(var e,n=t.scripts,r=n.length-1,o=r;o>0;o--)if("interactive"===n[o].readyState){e=n[o].src;break}return e||n[r].src}();return e.substring(0,e.lastIndexOf("/")+1)}(),a=function(t){e.console&&console.error&&console.error("Layui hint: "+t)},i="undefined"!=typeof opera&&"[object Opera]"===opera.toString(),u={layer:"modules/layer",laydate:"modules/laydate",laypage:"modules/laypage",laytpl:"modules/laytpl",layim:"modules/layim",layedit:"modules/layedit",form:"modules/form",upload:"modules/upload",transfer:"modules/transfer",tree:"modules/tree",table:"modules/table",element:"modules/element",rate:"modules/rate",colorpicker:"modules/colorpicker",slider:"modules/slider",carousel:"modules/carousel",flow:"modules/flow",util:"modules/util",code:"modules/code",jquery:"modules/jquery",mobile:"modules/mobile","layui.all":"../layui.all"};r.prototype.cache=n,r.prototype.define=function(e,t){var r=this,o="function"==typeof e,a=function(){var e=function(e,t){layui[e]=t,n.status[e]=!0};return"function"==typeof t&&t(function(r,o){e(r,o),n.callback[r]=function(){t(e)}}),this};return o&&(t=e,e=[]),!layui["layui.all"]&&layui["layui.mobile"]?a.call(r):(r.use(e,a),r)},r.prototype.use=function(e,r,l){function c(e,t){var r="PLaySTATION 3"===navigator.platform?/^complete$/:/^(complete|loaded)$/;("load"===e.type||r.test((e.currentTarget||e.srcElement).readyState))&&(n.modules[d]=t,y.removeChild(h),function o(){return++m>1e3*n.timeout/4?a(d+" is not a valid module"):void(n.status[d]?s():setTimeout(o,4))}())}function s(){l.push(layui[d]),e.length>1?p.use(e.slice(1),r,l):"function"==typeof r&&r.apply(layui,l)}var p=this,f=n.dir=n.dir?n.dir:o,y=t.getElementsByTagName("head")[0];e="string"==typeof e?[e]:e,window.jQuery&&jQuery.fn.on&&(p.each(e,function(t,n){"jquery"===n&&e.splice(t,1)}),layui.jquery=layui.$=jQuery);var d=e[0],m=0;if(l=l||[],n.host=n.host||(f.match(/\/\/([\s\S]+?)\//)||["//"+location.host+"/"])[0],0===e.length||layui["layui.all"]&&u[d]||!layui["layui.all"]&&layui["layui.mobile"]&&u[d])return s(),p;var v=(u[d]?f+"lay/":/^\{\/\}/.test(p.modules[d])?"":n.base||"")+(p.modules[d]||d)+".js";if(v=v.replace(/^\{\/\}/,""),!n.modules[d]&&layui[d]&&(n.modules[d]=v),n.modules[d])!function g(){return++m>1e3*n.timeout/4?a(d+" is not a valid module"):void("string"==typeof n.modules[d]&&n.status[d]?s():setTimeout(g,4))}();else{var h=t.createElement("script");h.async=!0,h.charset="utf-8",h.src=v+function(){var e=n.version===!0?n.v||(new Date).getTime():n.version||"";return e?"?v="+e:""}(),y.appendChild(h),!h.attachEvent||h.attachEvent.toString&&h.attachEvent.toString().indexOf("[native code")<0||i?h.addEventListener("load",function(e){c(e,v)},!1):h.attachEvent("onreadystatechange",function(e){c(e,v)}),n.modules[d]=v}return p},r.prototype.getStyle=function(t,n){var r=t.currentStyle?t.currentStyle:e.getComputedStyle(t,null);return r[r.getPropertyValue?"getPropertyValue":"getAttribute"](n)},r.prototype.link=function(e,r,o){var i=this,u=t.createElement("link"),l=t.getElementsByTagName("head")[0];"string"==typeof r&&(o=r);var c=(o||e).replace(/\.|\//g,""),s=u.id="layuicss-"+c,p=0;return u.rel="stylesheet",u.href=e+(n.debug?"?v="+(new Date).getTime():""),u.media="all",t.getElementById(s)||l.appendChild(u),"function"!=typeof r?i:(function f(){return++p>1e3*n.timeout/100?a(e+" timeout"):void(1989===parseInt(i.getStyle(t.getElementById(s),"width"))?function(){r()}():setTimeout(f,100))}(),i)},n.callback={},r.prototype.factory=function(e){if(layui[e])return"function"==typeof n.callback[e]?n.callback[e]:null},r.prototype.addcss=function(e,t,r){return layui.link(n.dir+"css/"+e,t,r)},r.prototype.img=function(e,t,n){var r=new Image;return r.src=e,r.complete?t(r):(r.onload=function(){r.onload=null,"function"==typeof t&&t(r)},void(r.onerror=function(e){r.onerror=null,"function"==typeof n&&n(e)}))},r.prototype.config=function(e){e=e||{};for(var t in e)n[t]=e[t];return this},r.prototype.modules=function(){var e={};for(var t in u)e[t]=u[t];return e}(),r.prototype.extend=function(e){var t=this;e=e||{};for(var n in e)t[n]||t.modules[n]?a("模块名 "+n+" 已被占用"):t.modules[n]=e[n];return t},r.prototype.router=function(e){var t=this,e=e||location.hash,n={path:[],search:{},hash:(e.match(/[^#](#.*$)/)||[])[1]||""};return/^#\//.test(e)?(e=e.replace(/^#\//,""),n.href="/"+e,e=e.replace(/([^#])(#.*$)/,"$1").split("/")||[],t.each(e,function(e,t){/^\w+=/.test(t)?function(){t=t.split("="),n.search[t[0]]=t[1]}():n.path.push(t)}),n):n},r.prototype.url=function(e){var t=this,n={pathname:function(){var t=e?function(){var t=(e.match(/\.[^.]+?\/.+/)||[])[0]||"";return t.replace(/^[^\/]+/,"").replace(/\?.+/,"")}():location.pathname;return t.replace(/^\//,"").split("/")}(),search:function(){var n={},r=(e?function(){var t=(e.match(/\?.+/)||[])[0]||"";return t.replace(/\#.+/,"")}():location.search).replace(/^\?+/,"").split("&");return t.each(r,function(e,t){var r=t.indexOf("="),o=function(){return r<0?t.substr(0,t.length):0!==r&&t.substr(0,r)}();o&&(n[o]=r>0?t.substr(r+1):null)}),n}(),hash:t.router(function(){return e?(e.match(/#.+/)||[])[0]||"":location.hash}())};return n},r.prototype.data=function(t,n,r){if(t=t||"layui",r=r||localStorage,e.JSON&&e.JSON.parse){if(null===n)return delete r[t];n="object"==typeof n?n:{key:n};try{var o=JSON.parse(r[t])}catch(a){var o={}}return"value"in n&&(o[n.key]=n.value),n.remove&&delete o[n.key],r[t]=JSON.stringify(o),n.key?o[n.key]:o}},r.prototype.sessionData=function(e,t){return this.data(e,t,sessionStorage)},r.prototype.device=function(t){var n=navigator.userAgent.toLowerCase(),r=function(e){var t=new RegExp(e+"/([^\\s\\_\\-]+)");return e=(n.match(t)||[])[1],e||!1},o={os:function(){return/windows/.test(n)?"windows":/linux/.test(n)?"linux":/iphone|ipod|ipad|ios/.test(n)?"ios":/mac/.test(n)?"mac":void 0}(),ie:function(){return!!(e.ActiveXObject||"ActiveXObject"in e)&&((n.match(/msie\s(\d+)/)||[])[1]||"11")}(),weixin:r("micromessenger")};return t&&!o[t]&&(o[t]=r(t)),o.android=/android/.test(n),o.ios="ios"===o.os,o.mobile=!(!o.android&&!o.ios),o},r.prototype.hint=function(){return{error:a}},r.prototype.each=function(e,t){var n,r=this;if("function"!=typeof t)return r;if(e=e||[],e.constructor===Object){for(n in e)if(t.call(e[n],n,e[n]))break}else for(n=0;n<e.length&&!t.call(e[n],n,e[n]);n++);return r},r.prototype.sort=function(e,t,n){var r=JSON.parse(JSON.stringify(e||[]));return t?(r.sort(function(e,n){var r=/^-?\d+$/,o=e[t],a=n[t];return r.test(o)&&(o=parseFloat(o)),r.test(a)&&(a=parseFloat(a)),o&&!a?1:!o&&a?-1:o>a?1:o<a?-1:0}),n&&r.reverse(),r):r},r.prototype.stope=function(t){t=t||e.event;try{t.stopPropagation()}catch(n){t.cancelBubble=!0}},r.prototype.onevent=function(e,t,n){return"string"!=typeof e||"function"!=typeof n?this:r.event(e,t,null,n)},r.prototype.event=r.event=function(e,t,r,o){var a=this,i=null,u=t.match(/\((.*)\)$/)||[],l=(e+"."+t).replace(u[0],""),c=u[1]||"",s=function(e,t){var n=t&&t.call(a,r);n===!1&&null===i&&(i=!1)};return o?(n.event[l]=n.event[l]||{},n.event[l][c]=[o],this):(layui.each(n.event[l],function(e,t){return"{*}"===c?void layui.each(t,s):(""===e&&layui.each(t,s),void(c&&e===c&&layui.each(t,s)))}),i)},e.layui=new r}(window);
\ No newline at end of file
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
......@@ -5,7 +5,7 @@
let admin = layui.admin;
// 水平分割,需要分割的元素(id)、默认大小(百分比)、最小值(单位px)
Split(['#s1', '#s2', '#s3', '#s4', '#s5'], {sizes: [7, 9, 9, 9, 63], minSize: 70});
let whereCondition = {source_type: 'all'};
let table = layui.table;
let form = layui.form;
table.render({
......@@ -14,9 +14,7 @@
, method: 'post'
, size: 'sm'
, cellMinWidth: 80 //全局定义常规单元格的最小宽度
, where: {
source_type: 'all'
}
, where: whereCondition
, loading: true
, first: true //不显示首页
, last: false //不显示尾页
......@@ -143,20 +141,23 @@
}
});
} else {
layer.msg('只有已通过或者未通过状态,并且没有sku的供应商才可以禁用',{'icon': 5});
layer.msg('只有已通过或者未通过状态,并且没有sku的供应商才可以禁用', {'icon': 5});
}
}
});
form.on('submit(load)', function (data) {
form.render();
// console.log(data.field)
let map = data.field
// form.render();
// console.log(map)
//执行重载
table.reload('list', {
page: {
curr: 1
}
, where: data.field
, where: map
});
return false;
});
......
......@@ -16,8 +16,14 @@
first: true,//不显示首页
last: false,//不显示尾页
cols: [[
{type: 'radio',},
{field: 'supplier_consignee', title: '联系人', align: 'center'},
@if($operate=='update')
{
type: 'radio',
},
@endif
{
field: 'supplier_consignee', title: '联系人', align: 'center'
},
{field: 'supplier_position', title: '职位', align: 'center'},
{field: 'supplier_email', title: '邮箱', align: 'center'},
{field: 'supplier_mobile', title: '手机号', align: 'center'},
......
......@@ -21,8 +21,14 @@
first: true,//不显示首页
last: false,//不显示尾页
cols: [[
{type: 'radio',},
{field: 'receipt_type', title: '银行类型', align: 'center', width: 120},
@if($operate=='update')
{
type: 'radio',
},
@endif
{
field: 'receipt_type', title: '银行类型', align: 'center', width: 120
},
{field: 'bank_name', title: '开户名称', align: 'center', width: 150},
{field: 'bank_adderss', title: '开户行', align: 'center', width: 150},
{field: 'account_no', title: '银行账号', align: 'center', width: 130},
......@@ -30,7 +36,8 @@
{field: 'swift_code', title: '电汇号码', align: 'center', width: 150},
{
field: 'certificate', title: '信息凭证', width: 150, align: 'center', templet: function (data) {
return "<img class='certificate_img' style='width: 70px;height: 60px' src='" + data.certificate + "'>";
return "<a href='" + data.certificate + "' target='_blank'>" +
"<img class='certificate_img' style='width: 70px;height: 60px' src='" + data.certificate + "'></a>";
}
},
{field: 'remark', title: '备注', align: 'center', width: 200},
......
......@@ -13,7 +13,7 @@
状态 : {{$supplier['status_name']}}
</div>
<div class="layui-col-xs6">
公司性质 : {{$supplier['supplier_group']}}
公司性质 : {{$supplier['supplier_group_name']}}
</div>
<div class="layui-col-xs6">
合作类型 : {{$supplier['stockup_type']}}
......
......@@ -42,7 +42,7 @@
</div>
<div class="layui-row">
<div class="layui-col-md2">
公司性质 : {{$supplier['supplier_group']}}
公司性质 : {{$supplier['supplier_group_name']}}
</div>
<div class="layui-col-md2">
合作类型:{{$supplier['stockup_type_name']}}
......
<div class="layui-row">
<blockquote class="layui-elem-quote layui-text">
<b>联系人管理</b>
</blockquote>
@if($operate == 'update')
<div class="layui-btn-group demoTable" style="margin-top: 5px">
<button type="button" class="layui-btn layui-btn-sm" id="add_contact">新增</button>
......
<div class="layui-form-item">
<div class="layui-row">
<div class="layui-col-md4">
<div class="layui-col-md3">
<label class="layui-form-label"><span class="require">*</span>营业执照 :
</label>
<div class="layui-upload">
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['business_license']['file_name']}}</button>
<input type="hidden" class="upload_obj" name="upload_file[business_license]" value="{{$supplier['qualification_photos']['business_license']['value'] or ''}}">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['business_license']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[business_license]"
value="{{$supplier['qualification_photos']['business_license']['value'] or ''}}">
</div>
</div>
<div class="layui-col-md4">
<div class="layui-col-md3">
<label class="layui-form-label">开票资料 :
</label>
<div class="layui-upload">
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['billing_information']['file_name']}}</button>
<input type="hidden" class="upload_obj" name="upload_file[billing_information]" value="{{$supplier['qualification_photos']['billing_information']['value'] or ''}}">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['billing_information']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[billing_information]"
value="{{$supplier['qualification_photos']['billing_information']['value'] or ''}}">
</div>
</div>
</div>
<div class="layui-row">
<div class="layui-col-md3">
<label class="layui-form-label">商业登记证 :
</label>
<div class="layui-upload">
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm uploadButton">
{{$supplier['qualification_photos']['registration_certificate']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[registration_certificate]"
value="{{$supplier['qualification_photos']['registration_certificate']['value'] or ''}}">
</div>
</div>
<div class="layui-col-md3">
<label class="layui-form-label">公司注册证 :
</label>
<div class="layui-upload">
<button type="button" class="layui-btn layui-btn-primary layui-btn-sm uploadButton">
{{$supplier['qualification_photos']['incorporation_certificate']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[incorporation_certificate]"
value="{{$supplier['qualification_photos']['incorporation_certificate']['value'] or ''}}">
</div>
</div>
</div>
<div class="layui-row">
<div class="layui-col-md3">
<label class="layui-form-label">认证通知书 :
</label>
<div class="layui-upload">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['certification_notice']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[certification_notice]"
value="{{$supplier['qualification_photos']['certification_notice']['value'] or ''}}">
</div>
</div>
<div class="layui-col-md3">
<label class="layui-form-label">供应商调查表 :
</label>
<div class="layui-upload">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['supplier_survey']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[supplier_survey]"
value="{{$supplier['qualification_photos']['supplier_survey']['value'] or ''}}">
</div>
</div>
</div>
<div class="layui-row">
<div class="layui-col-md3">
<label class="layui-form-label">代理证 :
</label>
<div class="layui-upload">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['proxy_certificate']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[proxy_certificate]"
value="{{$supplier['qualification_photos']['proxy_certificate']['value'] or ''}}">
</div>
</div>
<div class="layui-col-md3">
<label class="layui-form-label">品质保证协议 :
</label>
<div class="layui-upload">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['quality_assurance_agreement']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[quality_assurance_agreement]"
value="{{$supplier['qualification_photos']['quality_assurance_agreement']['value'] or ''}}">
</div>
</div>
</div>
<div class="layui-row">
<div class="layui-col-md3">
<label class="layui-form-label">保密协议 :
</label>
<div class="layui-upload">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['confidentiality_agreement']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[confidentiality_agreement]"
value="{{$supplier['qualification_photos']['confidentiality_agreement']['value'] or ''}}">
</div>
</div>
<div class="layui-col-md3">
<label class="layui-form-label">合作协议 :
</label>
<div class="layui-upload">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['cooperation_agreement']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[cooperation_agreement]"
value="{{$supplier['qualification_photos']['cooperation_agreement']['value'] or ''}}">
</div>
</div>
</div>
<div class="layui-row">
<div class="layui-col-md3">
<label class="layui-form-label">其它附件 :
</label>
<div class="layui-upload">
<button type="button"
class="layui-btn layui-btn-primary layui-btn-sm uploadButton">{{$supplier['qualification_photos']['other_attachment']['file_name'] or '选择文件上传'}}</button>
<input type="hidden" class="upload_obj" name="upload_file[other_attachment]"
value="{{$supplier['qualification_photos']['other_attachment']['value'] or ''}}">
</div>
</div>
</div>
......
......@@ -5,12 +5,12 @@
<div class="layui-inline">
<label class="layui-form-label">商品总价不满</label>
<div class="layui-input-inline" style="width: 100px;">
<input class="layui-input" type="text" name="cn[max]" id="cn_max" value="{{$info['cn']['max'] or ''}}"
<input class="layui-input" type="text" name="cn[max]" id="cn_max" value="{{$supplier['extra_fee']['cn']['max'] or ''}}"
lay-verify="num">
</div>
<div class="layui-form-label" style="width: 100px;margin-left: -20px">元(人民币),收取</div>
<div class="layui-input-inline" style="width: 100px;">
<input class="layui-input" type="text" name="cn[price]" value="{{$info['cn']['price'] or ''}}"
<input class="layui-input" type="text" name="cn[price]" value="{{$supplier['extra_fee']['cn']['price'] or ''}}"
lay-verify="float" value="">
</div>
<div class="layui-form-label" style="width: 40px;margin-left: -20px">元运费</div>
......@@ -23,12 +23,12 @@
<div class="layui-inline">
<label class="layui-form-label">商品总价不满</label>
<div class="layui-input-inline" style="width: 100px;">
<input class="layui-input" type="text" name="hk[max]" id="hk_max" value="{{$info['hk']['max'] or ''}}"
<input class="layui-input" type="text" name="hk[max]" id="hk_max" value="{{$supplier['extra_fee']['hk']['max'] or ''}}"
lay-verify="num" value="">
</div>
<div class="layui-form-label" style="width: 55px;margin-left: -20px">美金,收取</div>
<div class="layui-input-inline" style="width: 100px;">
<input class="layui-input" type="text" name="hk[price]" value="{{$info['hk']['price'] or ''}}"
<input class="layui-input" type="text" name="hk[price]" value="{{$supplier['extra_fee']['hk']['price'] or ''}}"
lay-verify="float" value="">
</div>
<div class="layui-form-label" style="width: 40px;margin-left: -20px">元运费</div>
......@@ -45,14 +45,14 @@
<div class="layui-inline">
<label class="layui-form-label">人民币系数</label>
<div class="layui-input-inline" style="width: 50px">
<input type="text" name="cn_ratio" value="{{$ratio['cn_ratio'] or 1}}" lay-verify="required"
<input type="text" name="cn_ratio" value="{{$supplier['cn_ratio'] or 1}}" lay-verify="required"
placeholder="请输入人民币系数" autocomplete="off" class="layui-input" style="display: inline-block">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">美金系数</label>
<div class="layui-input-inline" style="width: 50px">
<input type="text" name="us_ratio" value="{{$RatioInfo['us_ratio'] or 1}}" lay-verify="required"
<input type="text" name="us_ratio" value="{{$supplier['us_ratio'] or 1}}" lay-verify="required"
placeholder="请输入采购附加费" autocomplete="off" class="layui-input">
</div>
<div class="layui-form-mid layui-word-aux">
......@@ -67,26 +67,26 @@
<div class="layui-inline">
<label class="layui-form-label">大陆交期</label>
<div class="layui-input-inline" style="width: 50px">
<input type="text" name="cn_delivery_time" value="{{$RatioInfo['cn_delivery_time'] or 1}}"
lay-verify="required" placeholder="请输入大陆货期" autocomplete="off" class="layui-input">
<input type="text" name="cn_delivery_time" value="{{$supplier['cn_delivery_time'] or 1}}"
lay-verify="required" autocomplete="off" class="layui-input">
</div>
<div class="layui-input-inline" style="width: 50px">
<select name="cn_delivery_time_period">
<option value="天"></option>
<option value="周"></option>
<option value="天" @if($supplier['cn_delivery_time_period'] == '天') selected @endif></option>
<option value="周" @if($supplier['cn_delivery_time_period'] == '周') selected @endif></option>
</select>
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">香港交期</label>
<div class="layui-input-inline" style="width: 50px">
<input type="text" name="us_delivery_time" value="{{$RatioInfo['us_delivery_time'] or 1}}"
lay-verify="required" placeholder="请输入香港货期" autocomplete="off" class="layui-input">
<input type="text" name="us_delivery_time" value="{{$supplier['us_delivery_time'] or 1}}"
lay-verify="required" autocomplete="off" class="layui-input">
</div>
<div class="layui-input-inline" style="width: 50px">
<select name="us_delivery_time_period">
<option value="天"></option>
<option value="周"></option>
<option value="天" @if($supplier['us_delivery_time_period'] == '天') selected @endif></option>
<option value="周" @if($supplier['us_delivery_time_period'] == '周') selected @endif></option>
</select>
</div>
<div class="layui-form-mid layui-word-aux">
......
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