12345678910111213141516171819202122232425262728 |
- <?php
- namespace Scm_supplier\Lib;
- use Dever;
- class Manage
- {
- public function __construct()
- {
- Dever::load('manage/auth.init');
- }
- public function check($id, $name, $data)
- {
- $goods = Dever::param('goods', $data);
- list($goods_id, $sku_id) = explode('-', $goods);
- $where['goods_id'] = $goods_id;
- $where['sku_id'] = $sku_id;
- $where['supplier_id'] = Dever::input('update_supplier_id');
- $info = Dever::db('scm_supplier/goods')->getOne($where);
- if (!$info) {
- $supplier = Dever::db('scm_supplier/info')->one($where['supplier_id']);
- $goods_info = Dever::load('scm_product/lib/info')->getBaseInfo($goods_id, $sku_id);
- return Dever::alert($supplier['name'] . '无此商品:【' . $goods_info['aname'] . '】');
- }
- }
- }
|