From c688f083caf965cd13f640098ad204d8fd8c9e69 Mon Sep 17 00:00:00 2001 From: zhangqian <zhangqian@123.com> Date: 星期二, 19 十二月 2023 17:21:01 +0800 Subject: [PATCH] 接收字节序参数 --- model/device_plc.go | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/model/device_plc.go b/model/device_plc.go index a6e7331..2d40004 100644 --- a/model/device_plc.go +++ b/model/device_plc.go @@ -12,7 +12,7 @@ // DevicePlc 璁惧鐨凱LC閰嶇疆 DevicePlc struct { - gorm.Model + CommonModel DeviceID string `gorm:"column:device_id;type:varchar(255);not null;unique" json:"deviceID"` //璁惧缂栧彿 Brand string `gorm:"type:varchar(191)" json:"brand"` Method constvar.PlcMethod `gorm:"type:varchar(191)" json:"method"` @@ -41,6 +41,7 @@ Length int `json:"length"` // 鏁版嵁闀垮害 Type constvar.PlcStartAddressValueType `json:"type"` // 鏁版嵁绫诲瀷 FieldName constvar.PlcStartAddressType `json:"fieldName"` // 瀵瑰簲绯荤粺瀛楁 + Endian constvar.EndianType `json:"endian"` // 瀛楄妭瀛樺偍椤哄簭锛宐ig(ABCD)/little(CDBA)/mix(CDAB) } DevicePlcSearch struct { -- Gitblit v1.8.0