Commit 29e8147e by wang

删除test文件

parent 2cff7c1d
......@@ -19,3 +19,4 @@ cmd.exe~
/doc/spuTest
/doc/test3
package main
import (
"fmt"
"github.com/gogf/gf/util/gconv"
)
func main() {
//str:="dfjksldjfksjdkfjskdfjk"
//byteStr:=[]byte(str)
inta:="123123123"
inta2:="1"
s1:=gconv.Int(string(inta))
s2:=gconv.Int(string(inta2))
s3:=gconv.Int([]uint8(inta))
fmt.Println(s3)
fmt.Println(s1,s2)
/*fmt.Println([]byte(inta),byteStr,[]uint8(inta))
uint8S:=[]uint8(inta)
uint8S2:=[]uint8(inta2)
fmt.Println(binary.BigEndian.Uint32(uint8S))
fmt.Println(binary.BigEndian.Uint32(uint8S2))*/
}
package main
import (
"fmt"
"regexp"
"unicode"
)
func main() {
str:="中的开发健康的反馈123123sdfsd"
str2:="fsdfsdf"
fmt.Println(IsChineseChar(str))
fmt.Println(IsChineseChar(str2))
}
func IsChineseChar(str string) bool {
for _, r := range str {
if unicode.Is(unicode.Scripts["Han"], r) || (regexp.MustCompile("[\u3002\uff1b\uff0c\uff1a\u201c\u201d\uff08\uff09\u3001\uff1f\u300a\u300b]").MatchString(string(r))) {
return true
}
}
return false
}
package main
import "fmt"
func main() {
defer func() {
fmt.Print("最后在还行的")
}()
panic(123)
}
func exec1() {
}
package main
import "fmt"
func main() {
fmt.Println(f2());
//result := watShadowDefer(50)
//fmt.Println(result)
}
func watShadowDefer(i int) (ret int) {
ret = i * 2
if ret > 10 {
fmt.Println(ret)
ret := 10
defer func() int{
ret = ret + 1
return ret
}()
fmt.Println(ret)
}
fmt.Println(ret)
return
}
func f2() (r int) {
t := 5
defer func(t int) {
t = t + 5
fmt.Printf("defer内部 t等于: %d\n",t)
}(t)
fmt.Printf("return 前 t等于: %d\n",t)
return t
}
func test() {
ret:=100
if ret > 10 {
fmt.Println(ret)
ret := 10
/*defer func() {
ret = ret + 1
}()*/
fmt.Println(ret)
}
fmt.Println(ret)
}
package main
import "fmt"
type SS struct {
a int
b int
}
var SSS *SS
func main() {
SSS=&SS{}
SSS.a=2
SSS.b=2
ju(SSS.b)
}
func ju(t int) {
switch t {
case SSS.a :
fmt.Println("a")
case SSS.b:
fmt.Printf("b")
}
}
package main
import (
"encoding/json"
"fmt"
"github.com/tidwall/gjson"
)
type testS struct {
A int `json:"a"`
B string `json:"b"`
}
func main() {
gjsontest()
return
testS:=testS{}
jsonStr:=`{"a":"123","b":"dfdf"}`
err:=json.Unmarshal([]byte(jsonStr),&testS)
fmt.Println(err.Error())
}
func gjsontest() {
s:="dfjklsjdfklsjdfl"
s=`{"a":"bcd"}`
res:=gjson.Parse(s)
if(res.Exists()){
fmt.Printf("1")
}else{
fmt.Printf("2")
}
}
\ No newline at end of file
package main
import (
"fmt"
"strings"
)
func main() {
s:="a b c d e"
s1:=strings.Replace(s," ",",",-1)
fmt.Printf(s1)
}
### 日志
#### 同步调用方法(不需要额外配置)
```json
import ("golang_open_platform/pkg/logger")
logger.SyncInsert("sku_save","记录一下日志",logger.LogLevelError) //记录错误日志
logger.SyncInsert("sku_save","记录一下日志",logger.LogLevelDebug) //记录debug日志
logger.SyncInsert("sku_save","记录一下日志") //默认记录info
```
### 异步日志
#### 配置文件
```ini
[log_config]
1=sku_save,5
2=sku_edit,5
```
比如 sku_save,5 路径 sku_save 即文件夹是 sku 文件名类似 是save_2020-12-10.log
#### 调用示例
```json
import ("golang_open_platform/pkg/logger")
logger.Select("sku_save").Info(errMsg)
logger.Select("sku_save").Error(errMsg)
```
\ No newline at end of file
### 请求参数示例
batch_sn
spu_brief
goods_images
```json
{
"stock": 2055,
"pn": "maritex",
"is_api": 0,
"url": "https://en.maritex.com.pl/acoustics/audio_transducers/magnetic_buzzers_without_driving_circuit/cfd02-e.html",
"goods_name": "CFD02-E6",
"goods_sn": "CFD02-E",
"brand_name": "Changzhou EST ELECTRONICS Co.,Ltd.",
"is_error": 0,
"supplier_id": 17,
"canal": "L0010826",
"mpq": 1,
"moq": 1,
"pdf": "",
"hk_delivery_time": "5-7\u5de5\u4f5c\u65e5",
"cn_delivery_time": "6-12\u5de5\u4f5c\u65e5",
"ladder_price": [
{
"purchases": 1,
"price_cn": 0.2886,
"price_us": 0.2886
},
{
"purchases": 25,
"price_cn": 0.2662,
"price_us": 0.2662
}
],
"attrs":{
"0":{"attr_name":"标准包装","attr_value":"1"},
"2":{"attr_name":"包装","attr_value":"剪切带(CT)11"}
}
}
```
### 批次 redis Self_goods_batch 相关数据
```json
"[{"traceno":"00010486","pcs":"2950.0000","dc":"","goods_id":"10365","add_time":1578363429}]"
2) "[{"traceno":"00010489","pcs":"4500.0000","dc":"","goods_id":"10333","add_time":1578363429}]"
3) "[{"traceno":"00013255","pcs":"1350.0000","dc":0,"goods_id":"10643","add_time":1606109821,"dc_time":0}]"
4) "[{"traceno":"00011909","pcs":"2470.0000","dc":"","goods_id":"10288","add_time":1578363429},{"traceno":"00011910","pcs":"2500.0000","dc":"","goods_id":"10288","add_time":1578363429}]"
5) "[{"traceno":"00071835","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1529244995},{"traceno":"00071836","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1529244995},{"traceno":"00071837","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1529244995},{"traceno":"00071838","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1529244995},{"traceno":"00071839","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1529244995}]"
6) "[{"traceno":"00008706","pcs":"4000.0000","dc":"","goods_id":"11050","add_time":1578363429},{"traceno":"00008978","pcs":"4000.0000","dc":"","goods_id":"11050","add_time":1578363429}]"
7) "[{"traceno":"00071835","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1578240000},{"traceno":"00071836","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1578240000},{"traceno":"00071837","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1578240000},{"traceno":"00071838","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1578240000},{"traceno":"00071839","pcs":"100.0000","dc":"2002","goods_id":"95877","add_time":1578559395,"dc_time":1578240000}]"
8) "[{"traceno":"00008700","pcs":"9820.0000","dc":0,"goods_id":"11030","add_time":1579249375,"dc_time":0},{"traceno":"00009108","pcs":"10000.0000","dc":0,"goods_id":"11030","add_time":1579249375,"dc_time":0},{"traceno":"00009109","pcs":"10000.0000","dc":0,"goods_id":"11030","add_time":1579249375,"dc_time":0},{"traceno":"00071756","pcs":"5.0000","dc":0,"goods_id":"11030","add_time":1579249375,"dc_time":0},{"traceno":"00071758","pcs":"25.0000","dc":0,"goods_id":"11030","add_time":1579249375,"dc_time":0},{"traceno":"00071764","pcs":"10.0000","dc":0,"goods_id":"11030","add_time":1579249375,"dc_time":0},{"traceno":"00071766","pcs":"1.0000","dc":0,"goods_id":"11030","add_time":1579249375,"dc_time":0},{"traceno":"00071874","pcs":"400.0000","dc":"1809","goods_id":"11030","add_time":1579249375,"dc_time":1518969600},{"traceno":"00071876","pcs":"3600.0000","dc":"1810","goods_id":"11030","add_time":1579249375,"dc_time":1519574400},{"traceno":"00071871","pcs":"4000.0000","dc":"1802","goods_id":"11030","add_time":1579249375,"dc_time":1514736000},{"traceno":"00071872","pcs":"4000.0000","dc":"1802","goods_id":"11030","add_time":1579249375,"dc_time":1514736000},{"traceno":"00071873","pcs":"4000.0000","dc":"1802","goods_id":"11030","add_time":1579249375,"dc_time":1514736000},{"traceno":"00071875","pcs":"4000.0000","dc":"1830","goods_id":"11030","add_time":1579249375,"dc_time":1531670400}]"
9) "[{"traceno":"00010485","pcs":"3000.0000","dc":"","goods_id":"10345","add_time":1578363429}]"
10) "[{"traceno":"00008700","pcs":"9820.0000","dc":0,"goods_id":"11030","add_time":1579164431,"dc_time":0},{"traceno":"00009108","pcs":"10000.0000","dc":0,"goods_id":"11030","add_time":1579164431,"dc_time":0},{"traceno":"00009109","pcs":"10000.0000","dc":0,"goods_id":"11030","add_time":1579164431,"dc_time":0},{"traceno":"00071756","pcs":"5.0000","dc":0,"goods_id":"11030","add_time":1579164431,"dc_time":0},{"traceno":"00071758","pcs":"25.0000","dc":0,"goods_id":"11030","add_time":1579164431,"dc_time":0},{"traceno":"00071764","pcs":"10.0000","dc":0,"goods_id":"11030","add_time":1579164431,"dc_time":0},{"traceno":"00071766","pcs":"1.0000","dc":0,"goods_id":"11030","add_time":1579164431,"dc_time":0},{"traceno":"00071874","pcs":"400.0000","dc":"1809","goods_id":"11030","add_time":1579164431,"dc_time":1518969600},{"traceno":"00071876","pcs":"3600.0000","dc":"1810","goods_id":"11030","add_time":1579164431,"dc_time":1519574400},{"traceno":"00071871","pcs":"4000.0000","dc":"1802","goods_id":"11030","add_time":1579164431,"dc_time":1514736000},{"traceno":"00071872","pcs":"4000.0000","dc":"1802","goods_id":"11030","add_time":1579164431,"dc_time":1514736000},{"traceno":"00071873","pcs":"4000.0000","dc":"1802","goods_id":"11030","add_time":1579164431,"dc_time":1514736000},{"traceno":"00071875","pcs":"4000.0000","dc":"1830","goods_id":"11030","add_time":1579164431,"dc_time":1531670400}]"
11) "[{"traceno":"00008673","pcs":"10000.0000","dc":"","goods_id":"11033","add_time":1578363429},{"traceno":"00009122","pcs":"10000.0000","dc":"","goods_id":"11033","add_time":1578363429},{"traceno":"00024542","pcs":"10000.0000","dc":"","goods_id":"11033","add_time":1578363429},{"traceno":"00024543","pcs":"10000.0000","dc":"","goods_id":"11033","add_time":1578363429}]"
12) "[{"traceno":"00008714","pcs":"4000.0000","dc":"","goods_id":"11051","add_time":1578363429},{"traceno":"00008977","pcs":"4000.0000","dc":"","goods_id":"11051","add_time":1578363429}]
```
package main
import (
"fmt"
)
type MyError struct {
errCode uint8
}
func (e *MyError) Error() string {
switch e.errCode {
case 1:
return "file not found"
case 2:
return "time out"
case 3:
return "permission denied"
default:
return "unknown error"
}
}
// 相当于使用interface进行封箱操作
func GetError1() error {
var err *MyError = nil
return err
}
// 没有使用interface进行封箱操作
func GetError2() *MyError {
var err *MyError = nil
return err
}
func main() {
ret1 := GetError1() //封箱,所以不为nil
fmt.Println(ret1 == nil) //false
e, _ := ret1.(*MyError) //显式拆箱,所以为nil
fmt.Println(e == nil) //true
ret2 := GetError2() // 不用转换,所以为nil
fmt.Println(ret2 == nil) //true
}
package main
import "golang_open_platform/open"
func main() {
open.NewFlow().GetUsedMinNum("a","c")
}
\ No newline at end of file
package main
func main() {
}
package main
import (
"fmt"
)
func main() {
fmt.Println("sdfsdfsdf")
/*tokenStr:="fjksdjfk"
name:="fddsf"
token.NewToken(tokenStr,name).Check()*/
}
package main
import (
"fmt"
"golang_open_platform/token"
"reflect"
)
func main() {
err:=ddd()
if(err==nil){
fmt.Println("等于空")
}else{
fmt.Println("不等于空")
}
CheckError(err)
return
tokenStr:="AbopJDAbopdu800820mcspcq=="
name:="getSkuListById"
s:= open.NewToken(tokenStr,name).Check()
/*if(s==nil){
fmt.Println("等于空")
}else{
fmt.Println("不等于空")
}*/
//return
/*fmt.Println(s)
fmt.Println(s)
fmt.Println(nil)*/
CheckError(nil)
CheckError(s)
/*if(s!=nil){
fmt.Println(s.Code,s.Error())
}*/
}
func ddd()error{
return nil
//return e.NewApiError("djfklsdjfk")
}
/**
检测异常,并抛出异常
*/
func CheckError(err error) {
fmt.Println(reflect.TypeOf(err))
if(err==nil){
fmt.Println("等于空")
}else{
fmt.Println("不等于空")
}
/*if(err!=nil){
fmt.Println("不等于空")
}else{
fmt.Println("等于空")
}*/
/*if err != nil {
fmt.Print(err.Error());
if apiError,ok:=err.(*ApiError);ok{
panic(apiError)
}else{
panic(NewApiError(err.Error()))
}
}*/
}
package main
import (
"fmt"
"time"
)
func main() {
s:=time.Hour.Seconds()*24
a:=time.Minute.Seconds()
fmt.Println(s)
fmt.Println(a)
}
\ No newline at end of file
package main
import (
"fmt"
"github.com/gogf/gf/util/gconv"
"golang_open_platform/pkg/common"
"sync"
"time"
)
type SoucreData []string
var num int
func main() {
c:=make(chan SoucreData)
page:=1;
go func() {
defer close(c)
for{
zySkuEntityS,err:=GetSoucreData(page)
if(len(zySkuEntityS)<=0 || err!=nil){
if(err!=nil){
common.PrintDebugString(err.Error())
}
break
}
c<-zySkuEntityS
page++
}
}()
//消费chan
w:=sync.WaitGroup{}
limits:=make(chan struct{},1)
for soucreData:=range c{
w.Add(1)
limits<- struct{}{}
go func() {
defer func() {
defer w.Done()
<-limits
}()
exec(soucreData)
}()
}
w.Wait()
fmt.Println(num)
}
func GetSoucreData(page int) (soucreData SoucreData,err error) {
if(page >10){
return soucreData,nil
}
pre:="吱吱吱"
for i:=0;i<=100;i++{
randNum:=common.Rand(1,1000000)
soucreData=append(soucreData,pre+gconv.String(randNum))
}
return soucreData,err
}
func exec(s SoucreData) {
time.Sleep(time.Second*5)
for _,v:=range s {
num+=1
common.PrintDebugString(v)
}
}
package main
import "github.com/syyongx/php2go"
func main() {
php2go.Ceil()
}
package main
import "fmt"
//换行符
func main() {
s:="abc\n"
s=s+"erg\n"
fmt.Print(s)
}
package main
import "fmt"
func main() {
s:=[]string{"goods_id","spu_id","brand_id","brand_name","goods_name", "stock","moq","mpq","class_id1","class_name","attrs","ladder_price",}
}
\ No newline at end of file
package main
import "fmt"
func main() {
s:=make([]string,0)
s[0]="fjksdf"
fmt.Println(s)
}
package main
import (
"fmt"
"strings"
)
func main() {
a:="a,b,c,d dfsdf"
sliceA:=strings.Split(a,",")
fmt.Print(sliceA)
}
\ No newline at end of file
### szlc mongodb
### szlc mongodb
```json
{
"stock": [
NumberInt(5),
NumberInt(7380)
],
"tiered": [
[
NumberInt(5),
0.544911
],
[
NumberInt(50),
0.406958
],
[
NumberInt(150),
0.38162
],
[
NumberInt(500),
0.356282
],
[
NumberInt(2500),
0.34502
],
[
NumberInt(5000),
0.339456
]
],
"increment": NumberInt(5),
"pn": "szlc",
"is_api": NumberInt(0),
"encap_sulation_number": NumberInt(4000),
"goods_name": "MCZ1210AH900TA0G",
"sale_count": NumberInt(10280),
"sale_unit": "个",
"url": "http://item.szlcsc.com/147580.html",
"time": NumberInt(1568786720),
"is_error": NumberInt(0),
"goods_id": NumberLong(31000000000),
"goods_sn": "C136265",
"brand_name": "TDK",
"brand_id": NumberInt(1)
}
```
redis Self_szlc_class_mapping
```json
"{"class_id": 10329, "parent_id": 10229, "financial_classify_id": "0"}"
```
\ No newline at end of file
***redis键值: Self_SelfGoods
{
"other_attrs": "",
"goods_id": 203065,
"goods_type": 0,
"supplier_id": 10000,
"brand_id": 4492,
"class_id1": 10152,
"class_id2": 10164,
"goods_name": "RR0603(0201)L1203FTD",
"status": 1,
"encoded": "",
"encap": "0201(0603)",
"packing": 5,
"goods_unit": 1,
"goods_images": "",
"pdf": "",
"goods_brief": "",
"moq": 50,
"mpq": 15000,
"ladder_price": [
{
"purchases": 50,
"price_cn": 0.0044
},
{
"purchases": 1000,
"price_cn": 0.0044
},
{
"purchases": 15000,
"price_cn": 0.0044
}
],
"update_time": 1592218150,
"sku_name": "RR0603(0201)L1203FTD u7f16u5e26 PTC u70edu654fu7535u963b ",
"mpl": 1,
"stock": 0,
"attrs": "",
"cost": "0.000000",
"new_cost": "0.000000",
"supplier_stock": 473349,
"self_supplier_type": 4
}
#############最终结果##########
Array
(
[33072] => Array
(
[other_attrs] => Array
(
[length] =>
[gross_wegiht] => 0.000582
)
[goods_id] => 33072
[goods_type] => 0
[supplier_id] => 10000
[brand_id] => 703
[class_id1] => 161
[class_id2] => 169
[goods_name] => 3362P-1-101LF
[status] => 1
[encoded] => 10141
[encap] => 3362P
[packing] => 8
[goods_unit] => 1
[goods_images] => http://img.ichunt.com/images/goods/bb/a6/bba6b9cb12bf5f581cd4525a9d5995de.png
[pdf] => http://img.ichunt.com/doc/pdf/cms/201809/13/d110c1966263019b39775c419f57b4a2.pdf
[goods_brief] =>
[moq] => 1
[mpq] => 50
[ladder_price] => Array
(
[0] => Array
(
[purchases] => 1
[price_cn] => 0.95
[price_ac] => 0.5944
)
[1] => Array
(
[purchases] => 10
[price_cn] => 0.874
[price_ac] => 0.5944
)
[2] => Array
(
[purchases] => 20
[price_cn] => 0.836
[price_ac] => 0.5944
)
[3] => Array
(
[purchases] => 50
[price_cn] => 0.798
[price_ac] => 0.5944
)
[4] => Array
(
[purchases] => 250
[price_cn] => 0.76
[price_ac] => 0.5944
)
)
[update_time] => 1596436153
[sku_name] => 3362P-1-101LF 精密可调电阻 100Ω(101) 3362P
[mpl] => 1
[stock] => 67
[attrs] => Array
(
[0] => Array
(
[attr_name] => 阻值(欧姆)
[attr_value] => 100Ω(101)
)
[1] => Array
(
[attr_name] => 精度
[attr_value] =>
)
[2] => Array
(
[attr_name] => 温度系数
[attr_value] =>
)
)
[cost] => 0.699248
[new_cost] => 0.602800
[supplier_stock] => 0
[self_supplier_type] => 1
[cn_delivery_time] => 3-7工作日
[brand_name] => BOURNS(伯恩斯)
[supplier_name] => 猎芯自营
[goods_unit_name] => 个
[packing_name] => 管
[mpq_unit_name] => 管
[scm_brand_name] =>
[actual_stock] => 100
[ac_type] => 6
[allow_coupon] => 1
[allow_presale] => 1
[saler_atio] =>
[szlc_price] =>
[class_id1_name] => 电阻
[class_id2_name] => 精密可调电阻
[is_buy] => 1
)
)
### redis Self_supplier_brand_mapping
```json
"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u4e1c\u9ad8\u5fd7(TOCOS)","supplier_brand_id":"98","brand_id":"4707","brand_name":"TOCOS(\u4e1c\u9ad8\u5fd7)","add_time":1592202603,"update_time":1592209621,"id":61}"
2) "{"supplier_id":"10000","self_supplier_type":"2","supplier_brand_name":"YAGEO","supplier_brand_id":"442","brand_id":"5148","brand_name":"YAGEO(\u56fd\u5de8)","add_time":1585037042,"update_time":1585037042,"id":12}"
3) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u661f\u6d77\u7535\u5b50","supplier_brand_id":"61","brand_id":"5291","brand_name":"STARSEA(\u661f\u6d77)","add_time":1592202603,"update_time":1592209621,"id":24}"
4) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u77fd\u529b\u6770(Silicon)","supplier_brand_id":"83","brand_id":"4248","brand_name":"Silergy(\u77fd\u529b\u6770)","add_time":1592202603,"update_time":1592209621,"id":46}"
5) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u987a\u7edc(Sunlord)","supplier_brand_id":"54","brand_id":"4208","brand_name":"Sunlord(\u987a\u7edc)","add_time":1592202603,"update_time":1592209620,"id":17}"
6) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u56fd\u661f\u5149\u7535","supplier_brand_id":"69","brand_id":"17","brand_name":"Nationstar(\u56fd\u661f\u5149\u7535)","add_time":1592202603,"update_time":1592209621,"id":32}"
7) "{"supplier_id":"10000","self_supplier_type":"3","supplier_brand_name":"3M","supplier_brand_id":"2","brand_id":"30","brand_name":"3M","add_time":1585031844,"update_time":1585117120,"id":3}"
8) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u610f\u6cd5\u534a\u5bfc\u4f53(ST)","supplier_brand_id":"76","brand_id":"21","brand_name":"ST(\u610f\u6cd5)","add_time":1592202603,"update_time":1592209621,"id":39}"
9) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u57fa\u7f8e(KEMET)","supplier_brand_id":"122","brand_id":"5347","brand_name":"KEMET(\u57fa\u7f8e)","add_time":1592202604,"update_time":1592209622,"id":85}"
10) "{"supplier_id":"10000","self_supplier_type":"3","supplier_brand_name":"0N","supplier_brand_id":"1","brand_id":"27","brand_name":"ON","add_time":1585031844,"update_time":1585117120,"id":2}"
11) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u5b89\u68ee\u7f8e(ON)","supplier_brand_id":"89","brand_id":"266","brand_name":"ON(\u5b89\u68ee\u7f8e)","add_time":1592202603,"update_time":1592209621,"id":52}"
12) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u957f\u7535(JCET)","supplier_brand_id":"62","brand_id":"985","brand_name":"CJ(\u957f\u7535)","add_time":1592202603,"update_time":1592209621,"id":25}"
13) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u7acb\u9686(Lelon)","supplier_brand_id":"85","brand_id":"2724","brand_name":"LELON(\u7acb\u9686)","add_time":1592202603,"update_time":1592209621,"id":48}"
14) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u539a\u58f0(ROYALOHM)","supplier_brand_id":"118","brand_id":"4857","brand_name":"UniOhm(\u539a\u58f0)","add_time":1592202604,"update_time":1592209621,"id":81}"
15) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u4e2d\u535a(ZHONGB)","supplier_brand_id":"100","brand_id":"5893","brand_name":"ZHONGB(\u4e2d\u535a)","add_time":1592202603,"update_time":1592209621,"id":63}"
16) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u65f6\u6052(SHIHENG)","supplier_brand_id":"92","brand_id":"5337","brand_name":"SHIHENG(\u65f6\u6052)","add_time":1592202603,"update_time":1592209621,"id":55}"
17) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u4e09\u661f(Samsung)","supplier_brand_id":"59","brand_id":"4076","brand_name":"SAMSUNG(\u4e09\u661f)","add_time":1592202603,"update_time":1592209620,"id":22}"
18) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u5b87\u9633(EYANG)","supplier_brand_id":"134","brand_id":"1753","brand_name":"EYANG(\u5b87\u9633)","add_time":1592202604,"update_time":1592209622,"id":97}"
{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u7cbe\u62d3\u91d1(JTJ)","supplier_brand_id":"119","brand_id":"5573","brand_name":"JTJ(\u7cbe\u62d3\u91d1)","add_time":1592202604,"update_time":1592209621,"id":82}"
{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u67cf\u6069\u65af(BOURNS)","supplier_brand_id":"97","brand_id":"703","brand_name":"BOURNS(\u4f2f\u6069\u65af)","add_time":1592202603,"update_time":1592209621,"id":60}"
{"supplier_id":"10000","self_supplier_type":"3","supplier_brand_name":"MURATA","supplier_brand_id":"264","brand_id":"3249","brand_name":"muRata(\u6751\u7530)","add_time":1585117120,"update_time":1585117120,"id":13}"
1) "60"
2) 1) "10000_4_113"
2) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"KEC","supplier_brand_id":"113","brand_id":"2636","brand_name":"KEC(\u5f00\u76ca\u79a7)","add_time":1592202604,"update_time":1592209621,"id":76}"
3) "10000_4_94"
4) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u5b8f\u53d1(HONGFA)","supplier_brand_id":"94","brand_id":"2119","brand_name":"HF(\u5b8f\u53d1)","add_time":1592202603,"update_time":1592209621,"id":57}"
5) "10000_2_264"
6) "{"supplier_id":"10000","self_supplier_type":"2","supplier_brand_name":"MURATA","supplier_brand_id":"264","brand_id":"3249","brand_name":"muRata(\u6751\u7530)","add_time":1585037042,"update_time":1585037042,"id":11}"
7) "10000_4_132"
8) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u6842\u5fae(GSME)","supplier_brand_id":"132","brand_id":"5899","brand_name":"GSME(\u6842\u5fae)","add_time":1592202604,"update_time":1592209622,"id":95}"
9) "10000_2_1"
10) "{"supplier_id":"10000","self_supplier_type":"2","supplier_brand_name":"0N","supplier_brand_id":"1","brand_id":"27","brand_name":"ON","add_time":1585037042,"update_time":1585037042,"id":7}"
11) "10000_3_1"
12) "{"supplier_id":"10000","self_supplier_type":"3","supplier_brand_name":"0N","supplier_brand_id":"1","brand_id":"27","brand_name":"ON","add_time":1585031844,"update_time":1585117120,"id":2}"
13) "10000_4_89"
14) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u5b89\u68ee\u7f8e(ON)","supplier_brand_id":"89","brand_id":"266","brand_name":"ON(\u5b89\u68ee\u7f8e)","add_time":1592202603,"update_time":1592209621,"id":52}"
15) "10000_4_95"
16) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u5317\u9646\u7535\u6c14(HDK)","supplier_brand_id":"95","brand_id":"5329","brand_name":"HDK(\u5317\u9646\u7535\u6c14)","add_time":1592202603,"update_time":1592209621,"id":58}"
17) "10000_4_79"
18) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u6676\u4e30\u660e\u6e90(BPS)","supplier_brand_id":"79","brand_id":"5297","brand_name":"BPS(\u6676\u4e30\u660e\u6e90)","add_time":1592202603,"update_time":1592209621,"id":42}"
19) "10000_4_110"
20) "{"supplier_id":"10000","self_supplier_type":"4","supplier_brand_name":"\u4e2d\u7acb(zlfy)","supplier_brand_id":"110","brand_id":"5541","brand_name":"zlfy(\u4e2d\u7acb)","add_time":1592202603,"update_time":1592209621,"id":73}"
```
redis Self_supplier_class_mapping
```json
1) "70"
2) 1) "10000_4_1027"
2) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"\u5171\u6a21\u7535\u611f","supplier_class_id":"1027","class_id":"10243","class_name":"\u5171\u6a21\u627c\u6d41\u5708","parent_id":10242,"financial_classify_id":"","add_time":1592199826,"update_time":1592214605,"id":75}"
3) "10000_4_993"
4) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"DC-DC\u82af\u7247","supplier_class_id":"993","class_id":"10056","class_name":"74\u7cfb\u5217\u903b\u8f91\u82af\u7247","parent_id":10051,"financial_classify_id":"","add_time":1592209319,"update_time":1592214605,"id":162}"
5) "10000_4_985"
6) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"\u76f4\u63d2\u5149\u7535\u5f00\u5173","supplier_class_id":"985","class_id":"10216","class_name":"\u5149\u7535\u5f00\u5173","parent_id":10212,"financial_classify_id":"","add_time":1592199826,"update_time":1592214605,"id":40}"
7) "10000_4_1116"
8) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"1.25\u8fde\u63a5\u5668","supplier_class_id":"1116","class_id":"10321","class_name":"\u8fde\u63a5\u5668","parent_id":10045,"financial_classify_id":"","add_time":1592199828,"update_time":1592214607,"id":144}"
9) "10000_4_977"
10) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"\u8d34\u7247\u6709\u6e90\u6676\u632f","supplier_class_id":"977","class_id":"10226","class_name":"\u8d34\u7247\u6709\u6e90\u6676\u632f","parent_id":10222,"financial_classify_id":"","add_time":1592199826,"update_time":1592214605,"id":35}"
11) "10000_4_961"
12) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"\u4e09\u6781\u7ba1(\u6676\u4f53\u7ba1)","supplier_class_id":"961","class_id":"10233","class_name":"\u6676\u4f53\u7ba1","parent_id":10229,"financial_classify_id":"","add_time":1592199825,"update_time":1592214605,"id":24}"
13) "10000_4_1063"
14) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"\u8096\u7279\u57fa\u6865","supplier_class_id":"1063","class_id":"10149","class_name":"\u6574\u6d41\u6865","parent_id":10142,"financial_classify_id":"","add_time":1592199827,"update_time":1592214606,"id":99}"
15) "10000_4_1082"
16) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"\u5e26\u706f\u5f00\u5173","supplier_class_id":"1082","class_id":"10263","class_name":"\u5e26\u706f\u5f00\u5173","parent_id":10262,"financial_classify_id":"","add_time":1592199827,"update_time":1592214606,"id":114}"
17) "10000_4_1095"
18) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"HDMI_USB\u8fde\u63a5\u5668","supplier_class_id":"1095","class_id":"10307","class_name":"USB Type-C\u8fde\u63a5\u5668","parent_id":10276,"financial_classify_id":"","add_time":1592209320,"update_time":1592214606,"id":172}"
19) "10000_4_1118"
20) "{"supplier_id":"10000","self_supplier_type":"4","supplier_class_name":"\u5f00\u5173\u6676\u4f53\u7ba1","supplier_class_id":"1118","class_id":"10238","class_name":"\u901a\u7528\u4e09\u6781\u7ba1","parent_id":10229,"financial_classify_id":"","add_time":1592199828,"update_time":1592214607,"id":146}"
```
自营分类表 custom 字段
```json
[
{
"attr_name": "商品型号",
"attr_id": "custom4",
"is_name": 2,
"name_sort": "255"
},
{
"attr_name": "包装/方式",
"attr_id": "custom5",
"is_name": 2,
"name_sort": "254"
},
{
"attr_name": "封装",
"attr_id": "custom3",
"is_name": 2,
"name_sort": "253"
},
{
"attr_name": "制造商",
"attr_id": "custom2",
"is_name": 2,
"name_sort": "252"
},
{
"attr_name": "分类名称",
"attr_id": "custom1",
"is_name": 2,
"name_sort": "-1"
}
]
```
Self_SelfGoods
```json
1) "222266"
2) "{"other_attrs":"","goods_id":222266,"goods_type":0,"supplier_id":10000,"brand_id":5287,"class_id1":10125,"class_id2":10141,"goods_name":"1SMA4750A","status":1,"encoded":"","encap":"SMA(DO-214AC)","packing":5,"goods_unit":1,"goods_images":"","pdf":"","goods_brief":"","moq":10,"mpq":2000,"ladder_price":[{"purchases":10,"price_cn":0.0722},{"purchases":100,"price_cn":0.0722},{"purchases":2000,"price_cn":0.0722}],"update_time":1592218801,"sku_name":"1SMA4750A \u7f16\u5e26 \u653e\u7535\u7ba1 ","mpl":1,"stock":0,"attrs":"","cost":"0.000000","new_cost":"0.000000","supplier_stock":10000,"self_supplier_type":4}"
3) "168560"
4) "{"other_attrs":{"gross_wegiht":"0.00003300"},"goods_id":168560,"goods_type":0,"supplier_id":10000,"brand_id":23,"class_id1":10096,"class_id2":10102,"goods_name":"OPA137N\/250","status":1,"encoded":"","encap":"SOT-23-5","packing":5,"goods_unit":1,"goods_images":"","pdf":"2584","goods_brief":"","moq":1,"mpq":250,"ladder_price":[{"purchases":1,"price_cn":"24.3495"},{"purchases":10,"price_cn":"23.73"},{"purchases":30,"price_cn":"23.31"},{"purchases":100,"price_cn":"22.89"}],"update_time":1577698767,"sku_name":"OPA137N\/250 \u7f16\u5e26 FET\u8f93\u5165\u8fd0\u653e ","mpl":1,"stock":0,"attrs":"","cost":"0.000000","new_cost":"0.000000","supplier_stock":5,"self_supplier_type":2}"
```
other_attrs
```json
{"pick_type":"3","length":"10.9","gross_wegiht":"0.258"}
```
\ 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