From 1ba32f7b79af42830a2a1f2c488675e8bd25f150 Mon Sep 17 00:00:00 2001
From: zhangqian <zhangqian@123.com>
Date: 星期五, 01 九月 2023 17:42:10 +0800
Subject: [PATCH] 获取工艺参数优先从本地数据库获取,没有再尝试从云端获取

---
 constvar/const.go |   19 ++++++++++++++++---
 1 files changed, 16 insertions(+), 3 deletions(-)

diff --git a/constvar/const.go b/constvar/const.go
index 087eeb5..3856612 100644
--- a/constvar/const.go
+++ b/constvar/const.go
@@ -6,13 +6,21 @@
 	NsqTopicSendPlcAddress        = "aps.%v.sendPlcAddress"
 	NsqTopicProcessParamsRequest  = "aps.%v.processParams.request"
 	NsqTopicProcessParamsResponse = "aps.%v.processParams.response"
+	NsqTopicApsProcessParams      = "aps.%v.aps.processParams" //鏈変簡鏂扮殑宸ヨ壓妯″瀷
 )
 
-type PlcStartAddressType string
+type PlcStartAddressType int
 
 const (
-	PlcStartAddressTypeFinishNumber = 1
-	PlcStartAddressTypeTotalNumber  = 2
+	PlcStartAddressTypeFinishNumber PlcStartAddressType = 1
+	PlcStartAddressTypeTotalNumber  PlcStartAddressType = 2
+)
+
+type PlcStartAddressValueType string
+
+const (
+	PlcStartAddressValueTypeString PlcStartAddressValueType = "string"
+	PlcStartAddressValueTypeInt    PlcStartAddressValueType = "int"
 )
 
 const (
@@ -31,3 +39,8 @@
 func (slf PlcMethod) Valid() bool {
 	return slf == PlcMethodModbusTCP || slf == PlcMethodSerial
 }
+
+const (
+	PlcCacheKeyFinishNumber = "finish_number"
+	PlcCacheKeyTotalNumber  = "total_number"
+)

--
Gitblit v1.8.0