修复错误
This commit is contained in:
parent
4a249f1719
commit
b0e628e143
@ -2501,7 +2501,7 @@ class StoreOrderRepository extends BaseRepository
|
||||
* @throws DbException
|
||||
* @throws ModelNotFoundException
|
||||
*/
|
||||
public function setProduct(array $arrary, $merId)
|
||||
public function setProduct(array $arrary, $merId,$type_id=0)
|
||||
{
|
||||
//读取excel
|
||||
$data = SpreadsheetExcelService::instance()->_import($arrary['path'], $arrary['sql'], $arrary['where'], 1);
|
||||
@ -2516,9 +2516,9 @@ class StoreOrderRepository extends BaseRepository
|
||||
// $mer_cate['level'] = 1;
|
||||
// $mer_cate_id = Db::name('store_category')->insertGetId($mer_cate);
|
||||
// }
|
||||
$typeCode = Db::name('merchant_type')->where('mer_type_id', $merId)->value('type_code');
|
||||
// $typeCode = Db::name('merchant_type')->where('mer_type_id', $merId)->value('type_code');
|
||||
$product_type = 0;
|
||||
if ($typeCode == Merchant::TypeCode['TypeSupplyChain']) {
|
||||
if ($type_id == 12) {
|
||||
$product_type = 98; //供应链
|
||||
}
|
||||
try {
|
||||
@ -2721,7 +2721,7 @@ class StoreOrderRepository extends BaseRepository
|
||||
$datas['product_id'] = $product_id;
|
||||
$datas['mer_id'] = $merId;
|
||||
$datas['store_name'] = $datum['value']['store_name'];
|
||||
$datas['content'] = $datum['value']['store_name'];
|
||||
$datas['content'] = $e->getMessage().'line:'.$e->getLine();
|
||||
$this->create_product_import_log($datas, 0);
|
||||
}
|
||||
return true;
|
||||
|
@ -837,11 +837,11 @@ class ProductRepository extends BaseRepository
|
||||
break;
|
||||
}
|
||||
if ($productType == 0) {
|
||||
$where[] = empty($merId) ? ['product_type', 'in', [0, 98, 99]] : ['product_type', 'in', [0]];
|
||||
$where['product_type'] = $productType;
|
||||
if (!$merId) $where['is_gift_bag'] = 0;
|
||||
}
|
||||
if ($productType == 1) {
|
||||
$where[] = ['product_type', 'in', [$productType]];
|
||||
if ($productType == 1 ||$productType==98) {
|
||||
$where['product_type'] = $productType;
|
||||
}
|
||||
if ($productType == 10) {
|
||||
$where['is_gift_bag'] = 1;
|
||||
@ -914,7 +914,8 @@ class ProductRepository extends BaseRepository
|
||||
public function getList(?int $merId, array $where, int $page, int $limit)
|
||||
{
|
||||
$query = $this->dao->search($merId, $where)->with(['merCateId.category', 'storeCategory', 'brand', 'attrValue']);
|
||||
$count = $query->count();
|
||||
$count = $query->fetchSql(true)->count();
|
||||
halt($count);
|
||||
$data = $query->page($page, $limit)->setOption('field', [])->field($this->filed)->select();
|
||||
|
||||
$data->append(['us_status']);
|
||||
|
@ -212,7 +212,7 @@ class StoreImport extends BaseController
|
||||
'where' => ['store_name' => 'A'],
|
||||
]
|
||||
];
|
||||
app()->make(StoreOrderRepository::class)->setProduct($data['data'],$data['mer_id']);
|
||||
app()->make(StoreOrderRepository::class)->setProduct($data['data'],$data['mer_id'],$type_id);
|
||||
}else{
|
||||
$check =[
|
||||
'A1'=>'商品名称(必填)',
|
||||
@ -238,7 +238,7 @@ class StoreImport extends BaseController
|
||||
'where' => ['store_name' => 'A'],
|
||||
]
|
||||
];
|
||||
app()->make(StoreOrderRepository::class)->setProduct($data['data'],$data['mer_id']);
|
||||
app()->make(StoreOrderRepository::class)->setProduct($data['data'],$data['mer_id'],$type_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -55,6 +55,7 @@ class Product extends BaseController
|
||||
$type=$this->request->merchant()['type_id'];
|
||||
$typeCode=Db::name('merchant_type')->where('mer_type_id',$type)->value('type_code');
|
||||
$product_type=0;
|
||||
|
||||
// if ($type==12){
|
||||
if ($typeCode==Merchant::TypeCode['TypeSupplyChain']){
|
||||
$where['product_type']=98;//供应链
|
||||
|
File diff suppressed because one or more lines are too long
@ -1 +1 @@
|
||||
.title[data-v-3500ed7a]{margin-bottom:16px;color:#17233d;font-weight:500;font-size:14px}.description-term[data-v-3500ed7a]{display:table-cell;padding-bottom:10px;line-height:20px;width:50%;font-size:12px}[data-v-3cd1b9b0] .el-cascader{display:block}.dialog-scustom[data-v-3cd1b9b0]{width:1200px;height:600px}.ela-btn[data-v-3cd1b9b0]{color:#2d8cf0}.Box .ivu-radio-wrapper[data-v-3cd1b9b0]{margin-right:25px}.Box .numPut[data-v-3cd1b9b0]{width:80%!important}.lunBox[data-v-3cd1b9b0]{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;border:1px solid #0bb20c}.pictrueBox[data-v-3cd1b9b0]{display:inline-block}.pictrue[data-v-3cd1b9b0]{width:50px;height:50px;border:1px dotted rgba(0,0,0,.1);display:inline-block;position:relative;cursor:pointer}.pictrue img[data-v-3cd1b9b0]{width:100%;height:100%}.pictrueTab[data-v-3cd1b9b0]{width:40px!important;height:40px!important}.upLoad[data-v-3cd1b9b0]{width:40px;height:40px;border:1px dotted rgba(0,0,0,.1);border-radius:4px;background:rgba(0,0,0,.02);cursor:pointer}.ft[data-v-3cd1b9b0]{color:red}.buttonGroup[data-v-3cd1b9b0]{position:relative;display:inline-block;vertical-align:middle;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.buttonGroup .small-btn[data-v-3cd1b9b0]{position:relative;float:left;height:24px;padding:0 7px;font-size:14px;border-radius:3px}.buttonGroup .small-btn[data-v-3cd1b9b0]:first-child{margin-left:0;border-bottom-right-radius:0;border-top-right-radius:0}.virtual_boder[data-v-3cd1b9b0]{border:1px solid #1890ff}.virtual_boder2[data-v-3cd1b9b0]{border:1px solid #e7e7e7}.virtual_san[data-v-3cd1b9b0]{position:absolute;bottom:0;right:0;width:0;height:0;border-bottom:26px solid #1890ff;border-left:26px solid transparent}.virtual_dui[data-v-3cd1b9b0]{position:absolute;bottom:-2px;right:2px;color:#fff;font-family:system-ui}.virtual[data-v-3cd1b9b0]{width:120px;height:60px;background:#fff;border-radius:3px;float:left;text-align:center;padding-top:8px;position:relative;cursor:pointer;line-height:23px}.virtual .virtual_top[data-v-3cd1b9b0]{font-size:14px;font-weight:600;color:rgba(0,0,0,.85)}.virtual .virtual_bottom[data-v-3cd1b9b0]{font-size:12px;font-weight:400;color:#999}.virtual[data-v-3cd1b9b0]:nth-child(2n){margin:0 12px}[data-v-7d87bc0d] .el-cascader{display:block}.ela-btn[data-v-7d87bc0d]{color:#2d8cf0}.priceBox[data-v-7d87bc0d]{width:80px}.pictrue[data-v-7d87bc0d]{width:50px;height:50px;border:1px dotted rgba(0,0,0,.1);display:inline-block;position:relative;cursor:pointer}.pictrue img[data-v-7d87bc0d]{width:100%;height:100%}[data-v-7d87bc0d] .el-input-number__decrease,[data-v-7d87bc0d] .el-input-number__increase{display:none}[data-v-7d87bc0d] .el-input-number.is-controls-right .el-input__inner,[data-v-7d87bc0d] .el-input__inner{padding:0 5px}.pictrueTab[data-v-7d87bc0d]{width:40px!important;height:40px!important}.upLoad[data-v-7d87bc0d]{width:40px;height:40px;border:1px dotted rgba(0,0,0,.1);border-radius:4px;background:rgba(0,0,0,.02);cursor:pointer}.bg[data-v-3eed27bd]{z-index:100;position:fixed;left:0;top:0;width:100%;height:100%;background:rgba(0,0,0,.5)}.goods_detail .goods_detail_wrapper[data-v-3eed27bd]{z-index:-10}[data-v-3eed27bd] table.el-input__inner{padding:0}.demo-table-expand[data-v-3eed27bd]{font-size:0}.demo-table-expand1[data-v-3eed27bd] label{width:77px!important;color:#99a9bf}.demo-table-expand .el-form-item[data-v-3eed27bd]{margin-right:0;margin-bottom:0;width:33.33%}.selWidth[data-v-3eed27bd]{width:350px!important}.seachTiele[data-v-3eed27bd]{line-height:35px}
|
||||
.title[data-v-3500ed7a]{margin-bottom:16px;color:#17233d;font-weight:500;font-size:14px}.description-term[data-v-3500ed7a]{display:table-cell;padding-bottom:10px;line-height:20px;width:50%;font-size:12px}[data-v-3cd1b9b0] .el-cascader{display:block}.dialog-scustom[data-v-3cd1b9b0]{width:1200px;height:600px}.ela-btn[data-v-3cd1b9b0]{color:#2d8cf0}.Box .ivu-radio-wrapper[data-v-3cd1b9b0]{margin-right:25px}.Box .numPut[data-v-3cd1b9b0]{width:80%!important}.lunBox[data-v-3cd1b9b0]{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;border:1px solid #0bb20c}.pictrueBox[data-v-3cd1b9b0]{display:inline-block}.pictrue[data-v-3cd1b9b0]{width:50px;height:50px;border:1px dotted rgba(0,0,0,.1);display:inline-block;position:relative;cursor:pointer}.pictrue img[data-v-3cd1b9b0]{width:100%;height:100%}.pictrueTab[data-v-3cd1b9b0]{width:40px!important;height:40px!important}.upLoad[data-v-3cd1b9b0]{width:40px;height:40px;border:1px dotted rgba(0,0,0,.1);border-radius:4px;background:rgba(0,0,0,.02);cursor:pointer}.ft[data-v-3cd1b9b0]{color:red}.buttonGroup[data-v-3cd1b9b0]{position:relative;display:inline-block;vertical-align:middle;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-tap-highlight-color:rgba(0,0,0,0)}.buttonGroup .small-btn[data-v-3cd1b9b0]{position:relative;float:left;height:24px;padding:0 7px;font-size:14px;border-radius:3px}.buttonGroup .small-btn[data-v-3cd1b9b0]:first-child{margin-left:0;border-bottom-right-radius:0;border-top-right-radius:0}.virtual_boder[data-v-3cd1b9b0]{border:1px solid #1890ff}.virtual_boder2[data-v-3cd1b9b0]{border:1px solid #e7e7e7}.virtual_san[data-v-3cd1b9b0]{position:absolute;bottom:0;right:0;width:0;height:0;border-bottom:26px solid #1890ff;border-left:26px solid transparent}.virtual_dui[data-v-3cd1b9b0]{position:absolute;bottom:-2px;right:2px;color:#fff;font-family:system-ui}.virtual[data-v-3cd1b9b0]{width:120px;height:60px;background:#fff;border-radius:3px;float:left;text-align:center;padding-top:8px;position:relative;cursor:pointer;line-height:23px}.virtual .virtual_top[data-v-3cd1b9b0]{font-size:14px;font-weight:600;color:rgba(0,0,0,.85)}.virtual .virtual_bottom[data-v-3cd1b9b0]{font-size:12px;font-weight:400;color:#999}.virtual[data-v-3cd1b9b0]:nth-child(2n){margin:0 12px}[data-v-7d87bc0d] .el-cascader{display:block}.ela-btn[data-v-7d87bc0d]{color:#2d8cf0}.priceBox[data-v-7d87bc0d]{width:80px}.pictrue[data-v-7d87bc0d]{width:50px;height:50px;border:1px dotted rgba(0,0,0,.1);display:inline-block;position:relative;cursor:pointer}.pictrue img[data-v-7d87bc0d]{width:100%;height:100%}[data-v-7d87bc0d] .el-input-number__decrease,[data-v-7d87bc0d] .el-input-number__increase{display:none}[data-v-7d87bc0d] .el-input-number.is-controls-right .el-input__inner,[data-v-7d87bc0d] .el-input__inner{padding:0 5px}.pictrueTab[data-v-7d87bc0d]{width:40px!important;height:40px!important}.upLoad[data-v-7d87bc0d]{width:40px;height:40px;border:1px dotted rgba(0,0,0,.1);border-radius:4px;background:rgba(0,0,0,.02);cursor:pointer}.bg[data-v-e9391b98]{z-index:100;position:fixed;left:0;top:0;width:100%;height:100%;background:rgba(0,0,0,.5)}.goods_detail .goods_detail_wrapper[data-v-e9391b98]{z-index:-10}[data-v-e9391b98] table.el-input__inner{padding:0}.demo-table-expand[data-v-e9391b98]{font-size:0}.demo-table-expand1[data-v-e9391b98] label{width:77px!important;color:#99a9bf}.demo-table-expand .el-form-item[data-v-e9391b98]{margin-right:0;margin-bottom:0;width:33.33%}.selWidth[data-v-e9391b98]{width:350px!important}.seachTiele[data-v-e9391b98]{line-height:35px}
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
1
public/mer/js/chunk-ada5bd26.85765c23.js
Normal file
1
public/mer/js/chunk-ada5bd26.85765c23.js
Normal file
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user