diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index 902c8a068..fbae9af70 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -5,13 +5,53 @@
+
+
+
+
+
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
@@ -52,6 +92,7 @@
+
@@ -123,98 +164,123 @@
file://$PROJECT_DIR$/cmd/cmd_api.go
- 48
+ 49
file://$PROJECT_DIR$/cmd/cmd_api.go
- 24
+ 25
file://$PROJECT_DIR$/cmd/cmd_api.go
- 111
+ 122
file://$PROJECT_DIR$/cmd/cmd_api.go
- 89
+ 97
- file://$PROJECT_DIR$/iSolarCloud/sungro.go
+ file://$PROJECT_DIR$/iSolarCloud/sungro/sungro.go
113
- file://$PROJECT_DIR$/iSolarCloud/sungro.go
+ file://$PROJECT_DIR$/iSolarCloud/sungro/sungro.go
142
- file://$PROJECT_DIR$/iSolarCloud/sungro.go
+ file://$PROJECT_DIR$/iSolarCloud/sungro/sungro.go
133
- file://$PROJECT_DIR$/iSolarCloud/sungro.go
- 174
+ file://$PROJECT_DIR$/iSolarCloud/sungro/sungro.go
+ 175
- file://$PROJECT_DIR$/iSolarCloud/sungro.go
- 179
+ file://$PROJECT_DIR$/iSolarCloud/sungro/sungro.go
+ 180
file://$PROJECT_DIR$/cmd/cmd_api.go
- 88
+ 92
- file://$PROJECT_DIR$/iSolarCloud/sungro.go
- 102
-
+ file://$PROJECT_DIR$/iSolarCloud/api/utils.go
+ 59
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/getPowerDevicePointNames/init.go
- 17
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 76
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/getPowerDevicePointNames/init.go
- 19
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 72
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/getPowerDevicePointNames/getPowerDevicePointNames.go
- 30
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 68
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/getPowerDevicePointNames/getPowerDevicePointNames.go
- 36
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 64
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/init.go
- 624
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 91
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/init.go
- 613
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 95
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/getPowerDevicePointNames/getPowerDevicePointNames.go
- 52
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 80
+
- file://$PROJECT_DIR$/iSolarCloud/AppService/getPowerDevicePointNames/getPowerDevicePointNames.go
- 65
-
+ file://$PROJECT_DIR$/iSolarCloud/api/struct_endpoint.go
+ 100
+
+
+
+ file://$PROJECT_DIR$/iSolarCloud/api/utils.go
+ 219
+
+
+
+ file://$PROJECT_DIR$/cmd/cmd_api.go
+ 100
+
+
+
+ file://$PROJECT_DIR$/iSolarCloud/sungro/AppService/struct.go
+ 615
+
+
+
+ file://$PROJECT_DIR$/iSolarCloud/api/utils.go
+ 137
+
+
+
+ file://$PROJECT_DIR$/iSolarCloud/sungro/AppService/login/struct.go
+ 170
+
@@ -222,6 +288,9 @@
+
+
+
diff --git a/cmd/cmd_api.go b/cmd/cmd_api.go
index f33afe5ab..91f20e67e 100644
--- a/cmd/cmd_api.go
+++ b/cmd/cmd_api.go
@@ -2,6 +2,7 @@ package cmd
import (
"GoSungro/Only"
+ "GoSungro/iSolarCloud/sungro/AppService/login"
"fmt"
"github.com/spf13/cobra"
)
@@ -56,7 +57,7 @@ func cmdApiListFunc(cmd *cobra.Command, args []string) {
Cmd.Error = SunGro.ListEndpoints("")
case args[0] == "areas":
- Cmd.Error = SunGro.ListAreas()
+ SunGro.ListAreas()
default:
Cmd.Error = SunGro.ListEndpoints(args[0])
@@ -86,8 +87,18 @@ func cmdApiGetFunc(cmd *cobra.Command, args []string) {
args[1] = "AppService"
}
+ // foo := AppService.Init()
+ // bar := foo.GetEndPoints()
+ // fmt.Printf("%v\n", bar)
hey := SunGro.GetEndpoint(args[1], args[0])
+ hey.SetRequest(login.Request {
+ UserAccount: "",
+ UserPassword: "",
+ })
fmt.Printf("HEY:%v\n", hey)
+ fmt.Printf("HEY:%v\n", hey.GetError())
+ fmt.Printf("HEY:%s\n", hey.GetRequest())
+ fmt.Printf("HEY:%s\n", hey.GetData())
if Cmd.Error != nil {
break
}
diff --git a/cmd/commands.go b/cmd/commands.go
index e0d3b78bd..9220f301b 100644
--- a/cmd/commands.go
+++ b/cmd/commands.go
@@ -2,7 +2,7 @@ package cmd
import (
"GoSungro/Only"
- "GoSungro/iSolarCloud"
+ "GoSungro/iSolarCloud/sungro"
"GoSungro/mmGit"
"fmt"
"github.com/spf13/cobra"
@@ -14,7 +14,7 @@ import (
)
-var SunGro *iSolarCloud.SunGro
+var SunGro *sungro.SunGro
var Git *mmGit.Git
var Cmd CommandArgs
var rootViper *viper.Viper
diff --git a/cmd/struct.go b/cmd/struct.go
index 9a1cc2042..b2f688f4d 100644
--- a/cmd/struct.go
+++ b/cmd/struct.go
@@ -2,9 +2,8 @@ package cmd
import (
"GoSungro/Only"
- "GoSungro/google"
- "GoSungro/iSolarCloud"
- "GoSungro/iSolarCloud/web"
+ "GoSungro/iSolarCloud/sungro"
+ "GoSungro/iSolarCloud/sungro/web"
"GoSungro/lsgo"
"GoSungro/mmGit"
"errors"
@@ -107,7 +106,7 @@ func (ca *CommandArgs) ProcessArgs(cmd *cobra.Command, args []string) error {
for range Only.Once {
ca.Args = args
- SunGro = iSolarCloud.NewSunGro(ca.ApiUrl)
+ SunGro = sungro.NewSunGro(ca.ApiUrl)
if SunGro.Error != nil {
break
}
@@ -133,9 +132,9 @@ func (ca *CommandArgs) ProcessArgs(cmd *cobra.Command, args []string) error {
ca.Error = writeConfig()
}
- if Cmd.GoogleSheetUpdate {
- SunGro.OutputType = iSolarCloud.TypeGoogle
- }
+ // if Cmd.GoogleSheetUpdate {
+ // SunGro.OutputType = iSolarCloud.TypeGoogle
+ // }
//Git.Error = Cmd.GitSet()
//if Cmd.Error != nil {
@@ -256,14 +255,12 @@ func (ca *CommandArgs) GitSave(entities ...string) error {
fmt.Printf("Saving %d entities from the SunGro to Git...\n", len(entities))
//SunGro.OutputType = iSolarCloud.StringTypeJson
- SunGro.OutputType = iSolarCloud.TypeJson
- //domain := SunGro.VerifyDomain("")
- //user := SunGro.VerifyUser("")
+ // SunGro.OutputType = iSolarCloud.TypeJson
for _, entity := range entities {
// Remove plurals.
entity = strings.TrimSuffix(entity, "s")
- SunGro.OutputString = ""
+ // SunGro.OutputString = ""
switch entity {
case "domain":
@@ -274,7 +271,7 @@ func (ca *CommandArgs) GitSave(entities ...string) error {
}
jf := AddJsonSuffix(entity)
- Cmd.Error = Git.SaveFile(jf, []byte(SunGro.OutputString))
+ Cmd.Error = Git.SaveFile(jf, []byte(ca.OutputFile))
if Cmd.Error != nil {
break
}
@@ -290,9 +287,7 @@ func (ca *CommandArgs) GitSave(entities ...string) error {
func (ca *CommandArgs) GoogleUpdate(entities ...string) error {
for range Only.Once {
- SunGro.OutputType = iSolarCloud.TypeGoogle
- //domain := SunGro.VerifyDomain("")
- //user := SunGro.VerifyUser("")
+ // SunGro.OutputType = iSolarCloud.TypeGoogle
if len(entities) == 0 {
entities = DefaultAreas
@@ -308,15 +303,15 @@ func (ca *CommandArgs) GoogleUpdate(entities ...string) error {
}
}
- sheet := google.Sheet {
- Id: "",
- Credentials: nil,
- SheetName: entity,
- Range: "",
- Data: SunGro.OutputArray,
- }
- sheet.Set(sheet)
- ca.Error = sheet.WriteSheet()
+ // sheet := google.Sheet {
+ // Id: "",
+ // Credentials: nil,
+ // SheetName: entity,
+ // Range: "",
+ // Data: ca.OutputFile,
+ // }
+ // sheet.Set(sheet)
+ // ca.Error = sheet.WriteSheet()
if ca.Error != nil {
break
}
diff --git a/go.mod b/go.mod
index 5907da413..deef89f9b 100644
--- a/go.mod
+++ b/go.mod
@@ -50,7 +50,6 @@ require (
github.com/spf13/cast v1.4.1 // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/subosito/gotenv v1.2.0 // indirect
- github.com/ungerik/pkgreflect v0.0.0-20170905122726-bfeb2a931863 // indirect
github.com/xanzy/ssh-agent v0.3.0 // indirect
go.opencensus.io v0.23.0 // indirect
golang.org/x/crypto v0.0.0-20210817164053-32db794688a5 // indirect
diff --git a/go.sum b/go.sum
index de5a2dc89..34a16841b 100644
--- a/go.sum
+++ b/go.sum
@@ -406,8 +406,6 @@ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/
github.com/subosito/gotenv v1.2.0 h1:Slr1R9HxAlEKefgq5jn9U+DnETlIUa6HfgEzj0g5d7s=
github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw=
github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM=
-github.com/ungerik/pkgreflect v0.0.0-20170905122726-bfeb2a931863 h1:dHyLkSlucRGhdxes0MgPD3ssqaKuP/UgatG9Y+MtHT4=
-github.com/ungerik/pkgreflect v0.0.0-20170905122726-bfeb2a931863/go.mod h1:7BUOYDBcsUKbB1yDwkUV8YpTj4Z5jEylGg9rvcRXR3A=
github.com/willf/pad v0.0.0-20200313202418-172aa767f2a4 h1:Y+IMUhhlO9FLTZpNrUAMWOr7Lh0tHDKu0nrDVhp6A7o=
github.com/willf/pad v0.0.0-20200313202418-172aa767f2a4/go.mod h1:+pVHwmjc9CH7ugBFxESIwQkXkVj0gUj4cFp63TLwP1Y=
github.com/xanzy/ssh-agent v0.3.0 h1:wUMzuKtKilRgBAD1sUb8gOwwRr2FGoBVumcjoOACClI=
diff --git a/iSolarCloud/AppService/getPowerDevicePointNames/getPowerDevicePointNames.go b/iSolarCloud/AppService/getPowerDevicePointNames/getPowerDevicePointNames.go
deleted file mode 100644
index 39cc4b6f2..000000000
--- a/iSolarCloud/AppService/getPowerDevicePointNames/getPowerDevicePointNames.go
+++ /dev/null
@@ -1,69 +0,0 @@
-// Resource
-package getPowerDevicePointNames
-
-import (
- "GoSungro/iSolarCloud/api"
- "fmt"
-)
-
-var Url = "/v1/reportService/getPowerDevicePointNames"
-
-var _ api.Resource = (*Resource)(nil)
-
-type Resource struct {
- api.TypeEndPoint
- // api.Common
- // Request
- // Response
-}
-
-type Request struct {
- api.RequestCommon
- Extra string
-}
-type Response struct {
- api.ResponseCommon
- Another string
-}
-
-func (g Resource) Call() api.Json {
- fmt.Println("Call() implement me")
- return ""
-}
-
-func (g Resource) SetRequest(ref interface{}) error {
- fmt.Println("Call() implement me")
- fmt.Printf("ref == %v\n", ref)
- return nil
-}
-
-func (g Resource) GetResource() interface{} {
- fmt.Println("Call() implement me")
- return &Resource{}
-}
-
-func (g Resource) Init() *Resource {
- fmt.Println("Init()")
- return &Resource{}
-}
-
-func Init() *Resource {
- fmt.Println("Init()")
-
- foo := Resource {
- api.TypeEndPoint {
- Area: api.GetArea(Resource{}),
- Name: api.GetEndPoint(Resource{}),
- Url: api.GetUrl(Url),
- // Resource: nil,
- Request: Request{},
- Response: Response{},
- // Get: nil,
- // Put: nil,
- Error: nil,
- },
- }
- fmt.Printf("endpoint: %v\n", foo)
-
- return &foo
-}
diff --git a/iSolarCloud/AppService/getPowerDevicePointNames/init.go b/iSolarCloud/AppService/getPowerDevicePointNames/init.go
deleted file mode 100644
index e0f99d055..000000000
--- a/iSolarCloud/AppService/getPowerDevicePointNames/init.go
+++ /dev/null
@@ -1,33 +0,0 @@
-package getPowerDevicePointNames
-
-// var EndPointFunctions template.FuncMap
-// var EndPointResource Resource
-func init() {
- // @TODO - How can we pull in all Tool functions automatically?
- //
- // Turns out we can't do it at runtime, (makes sense)...
- // https://stackoverflow.com/questions/41629293/how-do-i-list-the-public-methods-of-a-package-in-golang
- //
- // So as part of the build process, we perform a static analysis of the helper packages which creates a pkgreflect.go
- // https://github.com/ungerik/pkgreflect
- //
- // This results in all top level functions being imported automatically, (no method functions will be imported).
- //
- // EndPointResource = make(template.FuncMap)
- //
- // for name, fn := range Types {
- // // Ignore GetTools function.
- // if name == "Resource" {
- // continue
- // }
- //
- // // Ignore any function that doesn't have a ToolPrefix
- // if !strings.HasPrefix(name, ToolPrefix) {
- // continue
- // }
- //
- // // Trim ToolPrefix from function template name.
- // name = strings.TrimPrefix(name, ToolPrefix)
- // EndPointResource[name] = fn.Interface()
- // }
-}
\ No newline at end of file
diff --git a/iSolarCloud/AppService/getPowerDevicePointNames/pkgreflect.go b/iSolarCloud/AppService/getPowerDevicePointNames/pkgreflect.go
deleted file mode 100644
index 543c2947d..000000000
--- a/iSolarCloud/AppService/getPowerDevicePointNames/pkgreflect.go
+++ /dev/null
@@ -1,21 +0,0 @@
-// Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
-
-package getPowerDevicePointNames
-
-import "reflect"
-
-var Types = map[string]reflect.Type{
- "Request": reflect.TypeOf((*Request)(nil)).Elem(),
- "Resource": reflect.TypeOf((*Resource)(nil)).Elem(),
- "Response": reflect.TypeOf((*Response)(nil)).Elem(),
-}
-
-var Functions = map[string]reflect.Value{
-}
-
-var Variables = map[string]reflect.Value{
-}
-
-var Consts = map[string]reflect.Value{
-}
-
diff --git a/iSolarCloud/AppService/init.go b/iSolarCloud/AppService/init.go
deleted file mode 100644
index 86ed18dfa..000000000
--- a/iSolarCloud/AppService/init.go
+++ /dev/null
@@ -1,675 +0,0 @@
-package AppService
-
-import (
- "GoSungro/iSolarCloud/AppService/getPowerDevicePointNames"
- "GoSungro/iSolarCloud/api"
- "fmt"
- "reflect"
- "strings"
-)
-
-
-var endpoints = [][]string {
- {"AppService","acceptPsSharing","/v1/powerStationService/acceptPsSharing"},
- {"AppService","activateEmail","/v1/userService/activateEmail"},
- {"AppService","addConfig","/devDataHandleService/addConfig"},
- {"AppService","addDeviceRepair","/v1/devService/addDeviceRepair"},
- {"AppService","addDeviceToStructureForHousehold","/devDataHandleService/addDeviceToStructureForHousehold"},
- {"AppService","addDeviceToStructureForHouseholdByPsIdS","/devDataHandleService/addDeviceToStructureForHouseholdByPsIdS"},
- {"AppService","addFault","/v1/faultService/addFault"},
- {"AppService","addFaultOrder","/v1/faultService/addFaultOrder"},
- {"AppService","addFaultPlan","/v1/faultService/addFaultPlan"},
- {"AppService","addFaultRepairSteps","/v1/faultService/addFaultRepairSteps"},
- {"AppService","addHouseholdEvaluation","/v1/faultService/addHouseholdEvaluation"},
- {"AppService","addHouseholdLeaveMessage","/v1/faultService/addHouseholdLeaveMessage"},
- {"AppService","addHouseholdOpinionFeedback","/v1/faultService/addHouseholdOpinionFeedback"},
- {"AppService","addHouseholdWorkOrder","/v1/faultService/addHouseholdWorkOrder"},
- {"AppService","addOnDutyInfo","/v1/otherService/addOnDutyInfo"},
- {"AppService","addOperRule","/v1/faultService/addOperRule"},
- {"AppService","addOrDelPsStructure","/v1/devService/addOrDelPsStructure"},
- {"AppService","addOrderStep","/v1/faultService/addOrderStep"},
- {"AppService","addPowerStationForHousehold","/v1/powerStationService/addPowerStationForHousehold"},
- {"AppService","addPowerStationInfo","/v1/powerStationService/addPowerStationInfo"},
- {"AppService","addReportConfigEmail","/v1/reportService/addReportConfigEmail"},
- {"AppService","addSysAdvancedParam","/v1/devService/addSysAdvancedParam"},
- {"AppService","addSysOrgNew","/v1/otherService/addSysOrgNew"},
- {"AppService","aliPayAppTest","/onlinepay/aliPayAppTest"},
- {"AppService","auditOperRule","/v1/faultService/auditOperRule"},
- {"AppService","batchAddStationBySn","/v1/powerStationService/batchAddStationBySn"},
- {"AppService","batchImportSN","/v1/devService/batchImportSN"},
- {"AppService","batchInsertUserAndOrg","/v1/userService/batchInsertUserAndOrg"},
- {"AppService","batchModifyDevicesInfoAndPropertis","/v1/devService/batchModifyDevicesInfoAndPropertis"},
- {"AppService","batchProcessPlantReport","/v1/powerStationService/batchProcessPlantReport"},
- {"AppService","batchUpdateDeviceSim","/v1/devService/batchUpdateDeviceSim"},
- {"AppService","batchUpdateUserIsAgreeGdpr","/v1/userService/batchUpdateUserIsAgreeGdpr"},
- {"AppService","boundMobilePhone","/v1/userService/boundMobilePhone"},
- {"AppService","boundUserMail","/v1/userService/boundUserMail"},
- {"AppService","caculateDeviceInputDiscrete","/v1/devService/caculateDeviceInputDiscrete"},
- {"AppService","calculateDeviceDiscrete","/v1/devService/calculateDeviceDiscrete"},
- {"AppService","calculateInitialCompensationData","/v1/powerStationService/calculateInitialCompensationData"},
- {"AppService","cancelDeliverMail","/v1/messageService/cancelDeliverMail"},
- {"AppService","cancelOrderScan","/v1/devService/cancelOrderScan"},
- {"AppService","cancelParamSetTask","/v1/devService/cancelParamSetTask"},
- {"AppService","cancelPsSharing","/v1/powerStationService/cancelPsSharing"},
- {"AppService","cancelRechargeOrder","/onlinepay/cancelRechargeOrder"},
- {"AppService","changRechargeOrderToCancel","/onlinepay/changRechargeOrderToCancel"},
- {"AppService","changeHouseholdUser2Installer","/v1/orgService/changeHouseholdUser2Installer"},
- {"AppService","changeRemoteParam","/v1/devService/changeRemoteParam"},
- {"AppService","checkDealerOrgCode","/v1/orgService/checkDealerOrgCode"},
- {"AppService","checkDevSnIsBelongsToUser","/v1/userService/checkDevSnIsBelongsToUser"},
- {"AppService","checkInverterResult","/v1/devService/checkInverterResult"},
- {"AppService","checkIsCanDoParamSet","/v1/devService/checkIsCanDoParamSet"},
- {"AppService","checkIsIvScan","/v1/devService/checkIsIvScan"},
- {"AppService","checkOssObjectExist","/v1/commonService/checkOssObjectExist"},
- {"AppService","checkServiceIsConnect","/v1/commonService/checkServiceIsConnect"},
- {"AppService","checkTechnicalParameters","/v1/devService/checkTechnicalParameters"},
- {"AppService","checkUnitStatus","/v1/devService/checkUnitStatus"},
- {"AppService","checkUpRechargeDevicePaying","/onlinepay/checkUpRechargeDevicePaying"},
- {"AppService","checkUserAccountUnique","/v1/userService/checkUserAccountUnique"},
- {"AppService","checkUserAccountUniqueAll","/v1/userService/checkUserAccountUniqueAll"},
- {"AppService","checkUserInfoUnique","/v1/userService/checkUserInfoUnique"},
- {"AppService","checkUserIsExist","/v1/userService/checkUserIsExist"},
- {"AppService","checkUserListIsExist","/v1/userService/checkUserListIsExist"},
- {"AppService","checkUserPassword","/v1/userService/checkUserPassword"},
- {"AppService","cloudDeploymentRecord","/v1/commonService/cloudDeploymentRecord"},
- {"AppService","comfirmParamModel","/v1/devService/comfirmParamModel"},
- {"AppService","communicationModuleDetail","/v1/devService/communicationModuleDetail"},
- {"AppService","compareValidateCode","/v1/userService/compareValidateCode"},
- {"AppService","componentInfo2Cloud","/v1/devService/componentInfo2Cloud"},
- {"AppService","confirmFault","/v1/faultService/confirmFault"},
- {"AppService","confirmIvFault","/v1/devService/confirmIvFault"},
- {"AppService","confirmReportConfig","/v1/reportService/confirmReportConfig"},
- {"AppService","createAppkeyInfo","/v1/userService/createAppkeyInfo"},
- {"AppService","createRenewInvoice","/onlinepay/createRenewInvoice"},
- {"AppService","dealCommandReply","/devDataHandleService/dealCommandReply"},
- {"AppService","dealDeletePsFailPsDelete","/v1/powerStationService/dealDeletePsFailPsDelete"},
- {"AppService","dealFailRemoteUpgradeSubTasks","/v1/devService/dealFailRemoteUpgradeSubTasks"},
- {"AppService","dealFailRemoteUpgradeTasks","/v1/devService/dealFailRemoteUpgradeTasks"},
- {"AppService","dealFaultOrder","/v1/faultService/dealFaultOrder"},
- {"AppService","dealGroupStringDisableOrEnable","/v1/devService/dealGroupStringDisableOrEnable"},
- {"AppService","dealNumberOfServiceCalls2Mysql","/v1/commonService/dealNumberOfServiceCalls2Mysql"},
- {"AppService","dealParamSettingAfterComplete","/v1/devService/dealParamSettingAfterComplete"},
- {"AppService","dealPsDataSupplement","/v1/powerStationService/dealPsDataSupplement"},
- {"AppService","dealPsReportEmailSend","/v1/reportService/dealPsReportEmailSend"},
- {"AppService","dealRemoteUpgrade","/v1/devService/dealRemoteUpgrade"},
- {"AppService","dealSnElectrifyCheck","/v1/devService/dealSnElectrifyCheck"},
- {"AppService","dealSysDeviceSimFlowInfo","/v1/devService/dealSysDeviceSimFlowInfo"},
- {"AppService","dealSysDeviceSimInfo","/v1/devService/dealSysDeviceSimInfo"},
- {"AppService","definiteTimeDealSnExpRemind","/v1/devService/definiteTimeDealSnExpRemind"},
- {"AppService","definiteTimeDealSnStatus","/v1/devService/definiteTimeDealSnStatus"},
- {"AppService","delDeviceRepair","/v1/devService/delDeviceRepair"},
- {"AppService","delOperRule","/v1/faultService/delOperRule"},
- {"AppService","delayCallApiResidueTimes","/v1/commonService/delayCallApiResidueTimes"},
- {"AppService","deleteComponent","/v1/devService/deleteComponent"},
- {"AppService","deleteCustomerEmployee","/v1/devService/deleteCustomerEmployee"},
- {"AppService","deleteDeviceAccount","/v1/devService/deleteDeviceAccount"},
- {"AppService","deleteDeviceSimById","/v1/devService/deleteDeviceSimById"},
- {"AppService","deleteElectricitySettlementData","/v1/otherService/deleteElectricitySettlementData"},
- {"AppService","deleteFaultPlan","/v1/faultService/deleteFaultPlan"},
- {"AppService","deleteFirmwareFiles","/v1/commonService/deleteFirmwareFiles"},
- {"AppService","deleteHouseholdEvaluation","/v1/faultService/deleteHouseholdEvaluation"},
- {"AppService","deleteHouseholdLeaveMessage","/v1/faultService/deleteHouseholdLeaveMessage"},
- {"AppService","deleteHouseholdWorkOrder","/v1/faultService/deleteHouseholdWorkOrder"},
- {"AppService","deleteInverterSnInChnnl","/devDataHandleService/deleteInverterSnInChnnl"},
- {"AppService","deleteModuleLog","/integrationService/deleteModuleLog"},
- {"AppService","deleteOnDutyInfo","/v1/otherService/deleteOnDutyInfo"},
- {"AppService","deleteOperateBillFile","/v1/faultService/deleteOperateBillFile"},
- {"AppService","deleteOssObject","/v1/commonService/deleteOssObject"},
- {"AppService","deletePowerDevicePointById","/v1/reportService/deletePowerDevicePointById"},
- {"AppService","deletePowerPicture","/v1/powerStationService/deletePowerPicture"},
- {"AppService","deletePowerRobotInfoBySnAndPsId","/v1/devService/deletePowerRobotInfoBySnAndPsId"},
- {"AppService","deletePowerRobotSweepStrategy","/v1/devService/deletePowerRobotSweepStrategy"},
- {"AppService","deleteProductionData","/v1/devService/deleteProductionData"},
- {"AppService","deletePs","/v1/powerStationService/deletePs"},
- {"AppService","deleteRechargeOrder","/onlinepay/deleteRechargeOrder"},
- {"AppService","deleteRegularlyConnectionInfo","/v1/commonService/deleteRegularlyConnectionInfo"},
- {"AppService","deleteReportConfigEmailAddr","/v1/reportService/deleteReportConfigEmailAddr"},
- {"AppService","deleteSysAdvancedParam","/v1/devService/deleteSysAdvancedParam"},
- {"AppService","deleteSysOrgNew","/v1/otherService/deleteSysOrgNew"},
- {"AppService","deleteTemplate","/v1/devService/deleteTemplate"},
- {"AppService","deleteUserInfoAllByUserId","/v1/userService/deleteUserInfoAllByUserId"},
- {"AppService","deviceInputDiscreteDeleteTime","/v1/devService/deviceInputDiscreteDeleteTime"},
- {"AppService","deviceInputDiscreteGetTime","/v1/devService/deviceInputDiscreteGetTime"},
- {"AppService","deviceInputDiscreteInsertTime","/v1/devService/deviceInputDiscreteInsertTime"},
- {"AppService","deviceInputDiscreteUpdateTime","/v1/devService/deviceInputDiscreteUpdateTime"},
- {"AppService","devicePointsDataFromMySql","/v1/devService/devicePointsDataFromMySql"},
- {"AppService","deviceReplace","/v1/devService/deviceReplace"},
- {"AppService","editDeviceRepair","/v1/devService/editDeviceRepair"},
- {"AppService","editOperRule","/v1/faultService/editOperRule"},
- {"AppService","energyPovertyAlleviation","/v1/orgService/energyPovertyAlleviation"},
- {"AppService","energyTrend","/v1/powerStationService/energyTrend"},
- {"AppService","exportParamSettingValPDF","/v1/devService/exportParamSettingValPDF"},
- {"AppService","exportPlantReportPDF","/v1/powerStationService/exportPlantReportPDF"},
- {"AppService","faultAutoClose","/v1/faultService/faultAutoClose"},
- {"AppService","faultCloseRemindOrderHandler","/v1/faultService/faultCloseRemindOrderHandler"},
- {"AppService","findCodeValueList","/v1/commonService/findCodeValueList"},
- {"AppService","findEmgOrgInfo","/v1/otherService/findEmgOrgInfo"},
- {"AppService","findEnvironmentInfo","/v1/devService/findEnvironmentInfo"},
- {"AppService","findFromHbaseAndRedis","/v1/commonService/findFromHbaseAndRedis"},
- {"AppService","findInfoByuuid","/v1/devService/findInfoByuuid"},
- {"AppService","findLossAnalysisList","/v1/powerStationService/findLossAnalysisList"},
- {"AppService","findOnDutyInfo","/v1/otherService/findOnDutyInfo"},
- {"AppService","findPsType","/v1/powerStationService/findPsType"},
- {"AppService","findSingleStationPR","/v1/powerStationService/findSingleStationPR"},
- {"AppService","findUserPassword","/v1/devService/findUserPassword"},
- {"AppService","genTLSUserSigByUserAccount","/v1/userService/genTLSUserSigByUserAccount"},
- {"AppService","generateRandomPassword","/v1/userService/generateRandomPassword"},
- {"AppService","getAPIServiceInfo","/v1/commonService/getAPIServiceInfo"},
- {"AppService","getAccessedPermission","/v1/commonService/getAccessedPermission"},
- {"AppService","getAllDeviceByPsId","/v1/devService/getAllDeviceByPsId"},
- {"AppService","getAllPowerDeviceSetName","/v1/devService/getAllPowerDeviceSetName"},
- {"AppService","getAllPowerRobotViewInfoByPsId","/v1/devService/getAllPowerRobotViewInfoByPsId"},
- {"AppService","getAllPsIdByOrgIds","/v1/devService/getAllPsIdByOrgIds"},
- {"AppService","getAllUserRemindCount","/v1/devService/getAllUserRemindCount"},
- {"AppService","getAndOutletsAndUnit","/v1/devService/getAndOutletsAndUnit"},
- {"AppService","getApiCallsForAppkeys","/v1/commonService/getApiCallsForAppkeys"},
- {"AppService","getAreaInfoCodeByCounty","/v1/commonService/getAreaInfoCodeByCounty"},
- {"AppService","getAreaList","/v1/powerStationService/getAreaList"},
- {"AppService","getAutoCreatePowerStation","/v1/powerStationService/getAutoCreatePowerStation"},
- {"AppService","getBackReadValue","/v1/devService/getBackReadValue"},
- {"AppService","getBatchNewestPointData","/v1/devService/getBatchNewestPointData"},
- {"AppService","getCallApiResidueTimes","/v1/commonService/getCallApiResidueTimes"},
- {"AppService","getChangedPsListByTime","/v1/powerStationService/getChangedPsListByTime"},
- {"AppService","getChnnlListByPsId","/v1/devService/getChnnlListByPsId"},
- {"AppService","getCloudList","/v1/commonService/getCloudList"},
- {"AppService","getCloudServiceMappingConfig","/v1/commonService/getCloudServiceMappingConfig"},
- {"AppService","getCommunicationDeviceConfigInfo","/v1/devService/getCommunicationDeviceConfigInfo"},
- {"AppService","getCommunicationModuleMonitorData","/v1/devService/getCommunicationModuleMonitorData"},
- {"AppService","getComponentModelFactory","/v1/devService/getComponentModelFactory"},
- {"AppService","getConfigList","/devDataHandleService/getConfigList"},
- {"AppService","getConnectionInfoBySnAndLocalPort","/v1/commonService/getConnectionInfoBySnAndLocalPort"},
- {"AppService","getCountDown","/v1/devService/getCountDown"},
- {"AppService","getCountryServiceInfo","/v1/commonService/getCountryServiceInfo"},
- {"AppService","getCounty","/v1/commonService/getCounty"},
- {"AppService","getCustomerEmployee","/v1/devService/getCustomerEmployee"},
- {"AppService","getCustomerList","/v1/devService/getCustomerList"},
- {"AppService","getDataFromHBase","/v1/commonService/getDataFromHBase"},
- {"AppService","getDataFromHbaseByRowKey","/v1/commonService/getDataFromHbaseByRowKey"},
- {"AppService","getDevInstalledPowerByPsId","/v1/devService/getDevInstalledPowerByPsId"},
- {"AppService","getDevRecord","/v1/devService/getDevRecord"},
- {"AppService","getDevRunRecordList","/v1/devService/getDevRunRecordList"},
- {"AppService","getDevSimByList","/v1/devService/getDevSimByList"},
- {"AppService","getDevSimList","/v1/devService/getDevSimList"},
- {"AppService","getDeviceAccountById","/v1/devService/getDeviceAccountById"},
- {"AppService","getDeviceFaultStatisticsData","/v1/devService/getDeviceFaultStatisticsData"},
- {"AppService","getDeviceInfo","/v1/devService/getDeviceInfo"},
- {"AppService","getDeviceList","/v1/devService/getDeviceList"},
- {"AppService","getDeviceModelInfoList","/v1/devService/getDeviceModelInfoList"},
- {"AppService","getDevicePointMinuteDataList","/v1/commonService/getDevicePointMinuteDataList"},
- {"AppService","getDevicePoints","/v1/devService/getDevicePoints"},
- {"AppService","getDevicePropertys","/v1/devService/getDevicePropertys"},
- {"AppService","getDeviceRepairDetail","/v1/devService/getDeviceRepairDetail"},
- {"AppService","getDeviceTechBranchCount","/v1/devService/getDeviceTechBranchCount"},
- {"AppService","getDeviceTypeInfoList","/v1/devService/getDeviceTypeInfoList"},
- {"AppService","getDeviceTypeList","/v1/devService/getDeviceTypeList"},
- {"AppService","getDstInfo","/v1/userService/getDstInfo"},
- {"AppService","getElectricitySettlementData","/v1/otherService/getElectricitySettlementData"},
- {"AppService","getElectricitySettlementDetailData","/v1/otherService/getElectricitySettlementDetailData"},
- {"AppService","getEncryptPublicKey","/v1/commonService/getEncryptPublicKey"},
- {"AppService","getFaultCount","/v1/faultService/getFaultCount"},
- {"AppService","getFaultDetail","/v1/faultService/getFaultDetail"},
- {"AppService","getFaultMsgByFaultCode","/v1/faultService/getFaultMsgByFaultCode"},
- {"AppService","getFaultMsgListByPageWithYYYYMM","/v1/faultService/getFaultMsgListByPageWithYYYYMM"},
- {"AppService","getFaultMsgListWithYYYYMM","/v1/faultService/getFaultMsgListWithYYYYMM"},
- {"AppService","getFaultPlanList","/v1/faultService/getFaultPlanList"},
- {"AppService","getFileOperationRecordOne","/v1/commonService/getFileOperationRecordOne"},
- {"AppService","getFormulaFaultAnalyseList","/v1/powerStationService/getFormulaFaultAnalyseList"},
- {"AppService","getGroupStringCheckResult","/v1/devService/getGroupStringCheckResult"},
- {"AppService","getGroupStringCheckRule","/v1/devService/getGroupStringCheckRule"},
- {"AppService","getHisData","/v1/devService/getHisData"},
- {"AppService","getHistoryInfo","/v1/powerStationService/getHistoryInfo"},
- {"AppService","getHouseholdEvaluation","/v1/faultService/getHouseholdEvaluation"},
- {"AppService","getHouseholdLeaveMessage","/v1/faultService/getHouseholdLeaveMessage"},
- {"AppService","getHouseholdOpinionFeedback","/v1/faultService/getHouseholdOpinionFeedback"},
- {"AppService","getHouseholdPsInstallerByUserId","/v1/userService/getHouseholdPsInstallerByUserId"},
- {"AppService","getHouseholdStoragePsReport","/v1/powerStationService/getHouseholdStoragePsReport"},
- {"AppService","getHouseholdUserInfo","/v1/userService/getHouseholdUserInfo"},
- {"AppService","getHouseholdWorkOrderInfo","/v1/faultService/getHouseholdWorkOrderInfo"},
- {"AppService","getHouseholdWorkOrderList","/v1/faultService/getHouseholdWorkOrderList"},
- {"AppService","getI18nConfigByType","/integrationService/i18nfile/getI18nConfigByType"},
- {"AppService","getI18nFileInfo","/integrationService/i18nfile/getI18nFileInfo"},
- {"AppService","getI18nInfoByKey","/integrationService/i18nfile/getI18nInfoByKey"},
- {"AppService","getI18nVersion","/integrationService/international/getI18nVersion"},
- {"AppService","getIncomeSettingInfos","/v1/powerStationService/getIncomeSettingInfos"},
- {"AppService","getInfoFromAMap","/v1/commonService/getInfoFromAMap"},
- {"AppService","getInfomationFromRedis","/v1/devService/getInfomationFromRedis"},
- {"AppService","getInstallInfoList","/v1/orgService/getInstallInfoList"},
- {"AppService","getInstallerInfoByDealerOrgCodeOrId","/v1/orgService/getInstallerInfoByDealerOrgCodeOrId"},
- {"AppService","getInvertDataList","/v1/devService/getInvertDataList"},
- {"AppService","getInverterDataCount","/v1/devService/getInverterDataCount"},
- {"AppService","getInverterProcess","/v1/devService/getInverterProcess"},
- {"AppService","getInverterUuidBytotalId","/v1/devService/getInverterUuidBytotalId"},
- {"AppService","getIvEchartsData","/v1/devService/getIvEchartsData"},
- {"AppService","getIvEchartsDataById","/v1/devService/getIvEchartsDataById"},
- {"AppService","getKpiInfo","/v1/powerStationService/getKpiInfo"},
- {"AppService","getListMiFromHBase","/v1/commonService/getListMiFromHBase"},
- {"AppService","getMapInfo","/v1/powerStationService/getMapInfo"},
- {"AppService","getMapMiFromHBase","/v1/commonService/getMapMiFromHBase"},
- {"AppService","getMenuAndPrivileges","/v1/userService/getMenuAndPrivileges"},
- {"AppService","getMicrogridEStoragePsReport","/v1/powerStationService/getMicrogridEStoragePsReport"},
- {"AppService","getModuleLogInfo","/integrationService/getModuleLogInfo"},
- {"AppService","getModuleLogTaskList","/integrationService/getModuleLogTaskList"},
- {"AppService","getNationProvJSON","/v1/commonService/getNationProvJSON"},
- {"AppService","getNeedOpAsynOpRecordList","/v1/commonService/getNeedOpAsynOpRecordList"},
- {"AppService","getNoticeInfo","/v1/otherService/getNoticeInfo"},
- {"AppService","getNumberOfServiceCalls","/v1/commonService/getNumberOfServiceCalls"},
- {"AppService","getOSSConfig","/v1/commonService/getOSSConfig"},
- {"AppService","getOperRuleDetail","/v1/faultService/getOperRuleDetail"},
- {"AppService","getOperateBillFileId","/v1/faultService/getOperateBillFileId"},
- {"AppService","getOperateTicketForDetail","/v1/faultService/getOperateTicketForDetail"},
- {"AppService","getOrCreateNetEaseUserToken","/v1/userService/getOrCreateNetEaseUserToken"},
- {"AppService","getOrderDataList","/v1/faultService/getOrderDataList"},
- {"AppService","getOrderDataSql2","/v1/devService/getOrderDataSql2"},
- {"AppService","getOrderDatas","/v1/devService/getOrderDatas"},
- {"AppService","getOrderDetail","/v1/faultService/getOrderDetail"},
- {"AppService","getOrderStatistics","/v1/faultService/getOrderStatistics"},
- {"AppService","getOrgIdNameByUserId","/v1/orgService/getOrgIdNameByUserId"},
- {"AppService","getOrgInfoByDealerOrgCode","/v1/orgService/getOrgInfoByDealerOrgCode"},
- {"AppService","getOrgListByName","/v1/orgService/getOrgListByName"},
- {"AppService","getOrgListByUserId","/v1/userService/getOrgListByUserId"},
- {"AppService","getOrgListForUser","/v1/orgService/getOrgListForUser"},
- {"AppService","getOssObjectStream","/v1/commonService/getOssObjectStream"},
- {"AppService","getOwnerFaultConfigList","/v1/faultService/getOwnerFaultConfigList"},
- {"AppService","getPListinfoFromMysql","/v1/powerStationService/getPListinfoFromMysql"},
- {"AppService","getParamSetTemplate4NewProtocol","/v1/devService/getParamSetTemplate4NewProtocol"},
- {"AppService","getParamSetTemplatePointInfo","/v1/devService/getParamSetTemplatePointInfo"},
- {"AppService","getParamterSettingBase","/v1/devService/getParamterSettingBase"},
- {"AppService","getPhotoInfo","/v1/otherService/getPhotoInfo"},
- {"AppService","getPlanedOrNotPsList","/v1/faultService/getPlanedOrNotPsList"},
- {"AppService","getPlantReportPDFList","/v1/powerStationService/getPlantReportPDFList"},
- {"AppService","getPowerChargeSettingInfo","/v1/powerStationService/getPowerChargeSettingInfo"},
- {"AppService","getPowerDeviceModelTechList","/v1/devService/getPowerDeviceModelTechList"},
- {"AppService","getPowerDeviceModelTree","/v1/devService/getPowerDeviceModelTree"},
- {"AppService","getPowerDevicePointInfo","/v1/reportService/getPowerDevicePointInfo"},
- {"AppService","getPowerDevicePointNames","/v1/reportService/getPowerDevicePointNames"},
- {"AppService","getPowerDeviceSetTaskDetailList","/v1/devService/getPowerDeviceSetTaskDetailList"},
- {"AppService","getPowerDeviceSetTaskList","/v1/devService/getPowerDeviceSetTaskList"},
- {"AppService","getPowerFormulaFaultAnalyse","/v1/powerStationService/getPowerFormulaFaultAnalyse"},
- {"AppService","getPowerPictureList","/v1/powerStationService/getPowerPictureList"},
- {"AppService","getPowerRobotInfoByRobotSn","/v1/devService/getPowerRobotInfoByRobotSn"},
- {"AppService","getPowerRobotSweepAttrByPsId","/v1/devService/getPowerRobotSweepAttrByPsId"},
- {"AppService","getPowerRobotSweepStrategy","/v1/devService/getPowerRobotSweepStrategy"},
- {"AppService","getPowerRobotSweepStrategyList","/v1/devService/getPowerRobotSweepStrategyList"},
- {"AppService","getPowerSettingCharges","/v1/powerStationService/getPowerSettingCharges"},
- {"AppService","getPowerSettingHistoryRecords","/v1/powerStationService/getPowerSettingHistoryRecords"},
- {"AppService","getPowerStationBasicInfo","/v1/powerStationService/getPowerStationBasicInfo"},
- {"AppService","getPowerStationData","/v1/powerStationService/getPowerStationData"},
- {"AppService","getPowerStationForHousehold","/v1/powerStationService/getPowerStationForHousehold"},
- {"AppService","getPowerStationInfo","/v1/powerStationService/getPowerStationInfo"},
- {"AppService","getPowerStationPR","/v1/powerStationService/getPowerStationPR"},
- {"AppService","getPowerStationTableDataSql","/v1/devService/getPowerStationTableDataSql"},
- {"AppService","getPowerStationTableDataSqlCount","/v1/devService/getPowerStationTableDataSqlCount"},
- {"AppService","getPowerStatistics","/v1/powerStationService/getPowerStatistics"},
- {"AppService","getPowerTrendDayData","/v1/powerStationService/getPowerTrendDayData"},
- {"AppService","getPrivateCloudValidityPeriod","/v1/commonService/getPrivateCloudValidityPeriod"},
- {"AppService","getProvInfoListByNationCode","/v1/commonService/getProvInfoListByNationCode"},
- {"AppService","getPsAuthKey","/v1/powerStationService/getPsAuthKey"},
- {"AppService","getPsCurveInfo","/v1/devService/getPsCurveInfo"},
- {"AppService","getPsDataSupplementTaskList","/v1/powerStationService/getPsDataSupplementTaskList"},
- {"AppService","getPsDetail","/v1/powerStationService/getPsDetail"},
- {"AppService","getPsDetailByUserTokens","/v1/powerStationService/getPsDetailByUserTokens"},
- {"AppService","getPsDetailForSinglePage","/v1/powerStationService/getPsDetailForSinglePage"},
- {"AppService","getPsDetailWithPsType","/v1/powerStationService/getPsDetailWithPsType"},
- {"AppService","getPsHealthState","/v1/powerStationService/getPsHealthState"},
- {"AppService","getPsInstallerByPsId","/v1/orgService/getPsInstallerByPsId"},
- {"AppService","getPsInstallerOrgInfoByPsId","/v1/powerStationService/getPsInstallerOrgInfoByPsId"},
- {"AppService","getPsList","/v1/powerStationService/getPsList"},
- {"AppService","getPsListByName","/v1/powerStationService/getPsListByName"},
- {"AppService","getPsListForPsDataByPsId","/v1/powerStationService/getPsListForPsDataByPsId"},
- {"AppService","getPsListStaticData","/v1/powerStationService/getPsListStaticData"},
- {"AppService","getPsReport","/v1/reportService/getPsReport"},
- {"AppService","getPsUser","/v1/userService/getPsUser"},
- {"AppService","getPsWeatherList","/v1/powerStationService/getPsWeatherList"},
- {"AppService","getRechargeOrderDetail","/onlinepay/getRechargeOrderDetail"},
- {"AppService","getRechargeOrderItemDeviceList","/onlinepay/getRechargeOrderItemDeviceList"},
- {"AppService","getRechargeOrderList","/onlinepay/getRechargeOrderList"},
- {"AppService","getRegionalTree","/v1/orgService/getRegionalTree"},
- {"AppService","getRemoteParamSettingList","/v1/devService/getRemoteParamSettingList"},
- {"AppService","getRemoteUpgradeDeviceList","/v1/devService/getRemoteUpgradeDeviceList"},
- {"AppService","getRemoteUpgradeScheduleDetails","/v1/devService/getRemoteUpgradeScheduleDetails"},
- {"AppService","getRemoteUpgradeSubTasksList","/v1/devService/getRemoteUpgradeSubTasksList"},
- {"AppService","getRemoteUpgradeTaskList","/v1/devService/getRemoteUpgradeTaskList"},
- {"AppService","getReportData","/v1/powerStationService/getReportData"},
- {"AppService","getReportEmailConfigInfo","/v1/reportService/getReportEmailConfigInfo"},
- {"AppService","getReportExportColumns","/v1/reportService/getReportExportColumns"},
- {"AppService","getReportListByUserId","/v1/reportService/getReportListByUserId"},
- {"AppService","getRobotDynamicCleaningView","/v1/devService/getRobotDynamicCleaningView"},
- {"AppService","getRobotNumAndSweepCapacity","/v1/devService/getRobotNumAndSweepCapacity"},
- {"AppService","getRuleUnit","/v1/powerStationService/getRuleUnit"},
- {"AppService","getSendReportConfigCron","/v1/reportService/getSendReportConfigCron"},
- {"AppService","getSerialNum","/v1/devService/getSerialNum"},
- {"AppService","getShieldMapConditionList","/v1/commonService/getShieldMapConditionList"},
- {"AppService","getSimIdBySnList","/v1/devService/getSimIdBySnList"},
- {"AppService","getSingleIVData","/v1/devService/getSingleIVData"},
- {"AppService","getSnChangeRecord","/v1/devService/getSnChangeRecord"},
- {"AppService","getSnConnectionInfo","/v1/commonService/getSnConnectionInfo"},
- {"AppService","getStationInfoSql","/v1/devService/getStationInfoSql"},
- {"AppService","getSungwsConfigCache","/v1/commonService/getSungwsConfigCache"},
- {"AppService","getSungwsGlobalConfigCache","/v1/commonService/getSungwsGlobalConfigCache"},
- {"AppService","getSweepDevParamSetTemplate","/v1/devService/getSweepDevParamSetTemplate"},
- {"AppService","getSweepRobotDevList","/v1/devService/getSweepRobotDevList"},
- {"AppService","getSysMsg","/v1/otherService/getSysMsg"},
- {"AppService","getSysOrgNewList","/v1/otherService/getSysOrgNewList"},
- {"AppService","getSysOrgNewOne","/v1/otherService/getSysOrgNewOne"},
- {"AppService","getSysUserById","/v1/userService/getSysUserById"},
- {"AppService","getTableDataSql","/v1/devService/getTableDataSql"},
- {"AppService","getTableDataSqlCount","/v1/devService/getTableDataSqlCount"},
- {"AppService","getTemplateByInfoType","/v1/messageService/getTemplateByInfoType"},
- {"AppService","getTemplateList","/v1/devService/getTemplateList"},
- {"AppService","getUUIDByUpuuid","/v1/devService/getUUIDByUpuuid"},
- {"AppService","getUpTimePoint","/v1/devService/getUpTimePoint"},
- {"AppService","getUserById","/v1/userService/getUserById"},
- {"AppService","getUserByInstaller","/v1/userService/getUserByInstaller"},
- {"AppService","getUserDevOnlineOffineCount","/v1/devService/getUserDevOnlineOffineCount"},
- {"AppService","getUserGDPRAttrs","/v1/userService/getUserGDPRAttrs"},
- {"AppService","getUserHavePowerStationCount","/v1/userService/getUserHavePowerStationCount"},
- {"AppService","getUserInfoByUserAccounts","/v1/userService/getUserInfoByUserAccounts"},
- {"AppService","getUserList","/v1/userService/getUserList"},
- {"AppService","getUserPsOrderList","/v1/faultService/getUserPsOrderList"},
- {"AppService","getValFromHBase","/v1/commonService/getValFromHBase"},
- {"AppService","getValidateCode","/v1/userService/getValidateCode"},
- {"AppService","getValidateCodeAtRegister","/v1/userService/getValidateCodeAtRegister"},
- {"AppService","getWeatherInfo","/v1/powerStationService/getWeatherInfo"},
- {"AppService","getWechatPushConfig","/v1/userService/getWechatPushConfig"},
- {"AppService","getWorkInfo","/v1/otherService/getWorkInfo"},
- {"AppService","groupStringCheck","/v1/devService/groupStringCheck"},
- {"AppService","handleDevByCommunicationSN","/devDataHandleService/handleDevByCommunicationSN"},
- {"AppService","householdResetPassBySN","/v1/userService/householdResetPassBySN"},
- {"AppService","immediatePayment","/onlinepay/immediatePayment"},
- {"AppService","importExcelData","/v1/devService/importExcelData"},
- {"AppService","incomeStatistics","/v1/powerStationService/incomeStatistics"},
- {"AppService","informPush","/v1/messageService/informPush"},
- {"AppService","insertEmgOrgInfo","/v1/otherService/insertEmgOrgInfo"},
- {"AppService","insightSynDeviceStructure2Cloud","/v1/powerStationService/insightSynDeviceStructure2Cloud"},
- {"AppService","intoDataToHbase","/v1/commonService/intoDataToHbase"},
- {"AppService","ipLocationQuery","/v1/commonService/ipLocationQuery"},
- {"AppService","isHave2GSn","/v1/devService/isHave2GSn"},
- {"AppService","judgeDevIsHasInitSetTemplate","/v1/devService/judgeDevIsHasInitSetTemplate"},
- {"AppService","judgeIsSettingMan","/v1/faultService/judgeIsSettingMan"},
- {"AppService","listOssFiles","/v1/commonService/listOssFiles"},
- {"AppService","loadAreaInfo","/v1/commonService/loadAreaInfo"},
- {"AppService","loadPowerStation","/v1/powerStationService/loadPowerStation"},
- {"AppService","login","/v1/userService/login"},
- {"AppService","loginByToken","/v1/userService/loginByToken"},
- {"AppService","logout","/v1/userService/logout"},
- {"AppService","mobilePhoneHasBound","/v1/userService/mobilePhoneHasBound"},
- {"AppService","modifiedDeviceInfo","/v1/devService/modifiedDeviceInfo"},
- {"AppService","modifyEmgOrgStruc","/v1/otherService/modifyEmgOrgStruc"},
- {"AppService","modifyFaultPlan","/v1/faultService/modifyFaultPlan"},
- {"AppService","modifyOnDutyInfo","/v1/otherService/modifyOnDutyInfo"},
- {"AppService","modifyPassword","/v1/userService/modifyPassword"},
- {"AppService","modifyPersonalUnitList","/v1/userService/modifyPersonalUnitList"},
- {"AppService","modifyPsUser","/v1/userService/modifyPsUser"},
- {"AppService","moduleLogParamSet","/integrationService/moduleLogParamSet"},
- {"AppService","operateOssFile","/v1/commonService/operateOssFile"},
- {"AppService","operationPowerRobotSweepStrategy","/v1/devService/operationPowerRobotSweepStrategy"},
- {"AppService","orgPowerReport","/v1/orgService/orgPowerReport"},
- {"AppService","paramSetTryAgain","/v1/devService/paramSetTryAgain"},
- {"AppService","paramSetting","/v1/devService/paramSetting"},
- {"AppService","planPower","/v1/powerStationService/planPower"},
- {"AppService","powerDevicePointList","/v1/reportService/powerDevicePointList"},
- {"AppService","powerTrendChartData","/v1/powerStationService/powerTrendChartData"},
- {"AppService","psForcastInfo","/v1/powerStationService/psForcastInfo"},
- {"AppService","psHourPointsValue","/v1/powerStationService/psHourPointsValue"},
- {"AppService","queryAllPsIdAndName","/v1/powerStationService/queryAllPsIdAndName"},
- {"AppService","queryBatchCreatePsTaskList","/v1/powerStationService/queryBatchCreatePsTaskList"},
- {"AppService","queryBatchSpeedyAddPowerStationResult","/v1/powerStationService/queryBatchSpeedyAddPowerStationResult"},
- {"AppService","queryCardStatusCTCC","/v1/devService/queryCardStatusCTCC"},
- {"AppService","queryChildAccountList","/v1/userService/queryChildAccountList"},
- {"AppService","queryCompensationRecordData","/v1/powerStationService/queryCompensationRecordData"},
- {"AppService","queryCompensationRecordList","/v1/powerStationService/queryCompensationRecordList"},
- {"AppService","queryComponent","/v1/devService/queryComponent"},
- {"AppService","queryComponentTechnicalParam","/v1/devService/queryComponentTechnicalParam"},
- {"AppService","queryCountryGridAndRelation","/v1/devService/queryCountryGridAndRelation"},
- {"AppService","queryCountryList","/v1/commonService/queryCountryList"},
- {"AppService","queryCtrlTaskById","/v1/devService/queryCtrlTaskById"},
- {"AppService","queryDeviceInfo","/v1/devService/queryDeviceInfoForApp"},
- {"AppService","queryDeviceInfoForApp","/v1/devService/queryDeviceInfoForApp"},
- {"AppService","queryDeviceList","/v1/devService/queryDeviceList"},
- {"AppService","queryDeviceListByUserId","/v1/devService/queryDeviceListByUserId"},
- {"AppService","queryDeviceListForApp","/v1/devService/queryDeviceListForApp"},
- {"AppService","queryDeviceModelTechnical","/v1/devService/queryDeviceModelTechnical"},
- {"AppService","queryDevicePointDayMonthYearDataList","/v1/commonService/queryDevicePointDayMonthYearDataList"},
- {"AppService","queryDevicePointMinuteDataList","/v1/commonService/queryDevicePointMinuteDataList"},
- {"AppService","queryDevicePointsDayMonthYearDataList","/v1/commonService/queryDevicePointsDayMonthYearDataList"},
- {"AppService","queryDeviceRealTimeDataByPsKeys","/v1/devService/queryDeviceRealTimeDataByPsKeys"},
- {"AppService","queryDeviceRepairList","/v1/devService/queryDeviceRepairList"},
- {"AppService","queryDeviceTypeInfoList","/v1/devService/queryDeviceTypeInfoList"},
- {"AppService","queryEnvironmentList","/v1/devService/queryEnvironmentList"},
- {"AppService","queryFaultList","/v1/faultService/queryFaultList"},
- {"AppService","queryFaultPlanDetail","/v1/faultService/queryFaultPlanDetail"},
- {"AppService","queryFaultRepairSteps","/v1/faultService/queryFaultRepairSteps"},
- {"AppService","queryFaultTypeAndLevelByCode","/v1/faultService/queryFaultTypeAndLevelByCode"},
- {"AppService","queryFaultTypeByDevice","/v1/faultService/queryFaultTypeByDevice"},
- {"AppService","queryFaultTypeByDevicePage","/v1/faultService/queryFaultTypeByDevicePage"},
- {"AppService","queryFirmwareFilesPage","/v1/commonService/queryFirmwareFilesPage"},
- {"AppService","queryInfotoAlert","/v1/devService/queryInfotoAlert"},
- {"AppService","queryInverterModelList","/v1/devService/queryInverterModelList"},
- {"AppService","queryInverterVersionList","/v1/devService/queryInverterVersionList"},
- {"AppService","queryM2MCardInfoCMCC","/v1/devService/queryM2MCardInfoCMCC"},
- {"AppService","queryM2MCardTermInfoCMCC","/v1/devService/queryM2MCardTermInfoCMCC"},
- {"AppService","queryModelInfoByModelId","/v1/devService/queryModelInfoByModelId"},
- {"AppService","queryMutiPointDataList","/v1/commonService/queryMutiPointDataList"},
- {"AppService","queryNoticeList","/v1/otherService/queryNoticeList"},
- {"AppService","queryNumberOfRenewalReminders","/v1/devService/queryNumberOfRenewalReminders"},
- {"AppService","queryOperRules","/v1/faultService/queryOperRules"},
- {"AppService","queryOrderList","/v1/faultService/queryOrderList"},
- {"AppService","queryOrderStep","/v1/faultService/queryOrderStep"},
- {"AppService","queryOrgGenerationReport","/v1/orgService/queryOrgGenerationReport"},
- {"AppService","queryOrgInfoList","/v1/userService/queryOrgInfoList"},
- {"AppService","queryOrgPowerElecPercent","/v1/orgService/queryOrgPowerElecPercent"},
- {"AppService","queryOrgPsCompensationRecordList","/v1/powerStationService/queryOrgPsCompensationRecordList"},
- {"AppService","queryParamSettingTask","/v1/devService/queryParamSettingTask"},
- {"AppService","queryPersonalUnitList","/v1/userService/queryPersonalUnitList"},
- {"AppService","queryPointDataTopOne","/v1/devService/queryPointDataTopOne"},
- {"AppService","queryPowerStationInfo","/v1/powerStationService/queryPowerStationInfo"},
- {"AppService","queryPsAreaByUserIdAndAreaCode","/v1/powerStationService/queryPsAreaByUserIdAndAreaCode"},
- {"AppService","queryPsCompensationRecordList","/v1/powerStationService/queryPsCompensationRecordList"},
- {"AppService","queryPsDataByDate","/v1/powerStationService/queryPsDataByDate"},
- {"AppService","queryPsIdList","/v1/powerStationService/queryPsIdList"},
- {"AppService","queryPsListByUserIdAndAreaCode","/v1/powerStationService/queryPsListByUserIdAndAreaCode"},
- {"AppService","queryPsNameByPsId","/v1/devService/queryPsNameByPsId"},
- {"AppService","queryPsPrByDate","/v1/powerStationService/queryPsPrByDate"},
- {"AppService","queryPsProfit","/v1/powerStationService/queryPsProfit"},
- {"AppService","queryPsReportComparativeAnalysisOfPowerGeneration","/v1/powerStationService/queryPsReportComparativeAnalysisOfPowerGeneration"},
- {"AppService","queryPsStructureList","/v1/devService/queryPsStructureList"},
- {"AppService","queryPuuidsByCommandTotalId","/v1/devService/queryPuuidsByCommandTotalId"},
- {"AppService","queryPuuidsByCommandTotalId2","/v1/devService/queryPuuidsByCommandTotalId2"},
- {"AppService","queryRepairRuleList","/v1/devService/queryRepairRuleList"},
- {"AppService","queryReportListForManagementPage","/v1/reportService/queryReportListForManagementPage"},
- {"AppService","queryReportMsg","/v1/reportService/queryReportMsg"},
- {"AppService","querySharingPs","/v1/powerStationService/querySharingPs"},
- {"AppService","querySysAdvancedParam","/v1/devService/querySysAdvancedParam"},
- {"AppService","queryTimeBySN","/v1/devService/queryTimeBySN"},
- {"AppService","queryTrafficByDateCTCC","/v1/devService/queryTrafficByDateCTCC"},
- {"AppService","queryTrafficCTCC","/v1/devService/queryTrafficCTCC"},
- {"AppService","queryUnitList","/v1/userService/queryUnitList"},
- {"AppService","queryUnitUuidBytotalId","/v1/devService/queryUnitUuidBytotalId"},
- {"AppService","queryUserBtnPri","/v1/userService/queryUserBtnPri"},
- {"AppService","queryUserByUserIds","/v1/userService/queryUserByUserIds"},
- {"AppService","queryUserExtensionAttribute","/v1/userService/queryUserExtensionAttribute"},
- {"AppService","queryUserForStep","/v1/userService/queryUserForStep"},
- {"AppService","queryUserList","/v1/userService/queryUserList"},
- {"AppService","queryUserProcessPri","/v1/userService/queryUserProcessPri"},
- {"AppService","queryUserWechatBindRel","/v1/userService/queryUserWechatBindRel"},
- {"AppService","queryUuidByTotalIdAndUuid","/v1/devService/queryUuidByTotalIdAndUuid"},
- {"AppService","rechargeOrderSetMeal","/v1/devService/rechargeOrderSetMeal"},
- {"AppService","renewSendReportConfirmEmail","/v1/reportService/renewSendReportConfirmEmail"},
- {"AppService","reportList","/v1/powerStationService/reportList"},
- {"AppService","saveCustomerEmployee","/v1/devService/saveCustomerEmployee"},
- {"AppService","saveDevSimList","/v1/devService/saveDevSimList"},
- {"AppService","saveDeviceAccountBatchData","/v1/devService/saveDeviceAccountBatchData"},
- {"AppService","saveEnviromentIncomeInfos","/v1/powerStationService/saveEnviromentIncomeInfos"},
- {"AppService","saveEnvironmentCurve","/v1/devService/saveEnvironmentCurve"},
- {"AppService","saveFirmwareFile","/v1/commonService/saveFirmwareFile"},
- {"AppService","saveIncomeSettingInfos","/v1/powerStationService/saveIncomeSettingInfos"},
- {"AppService","saveOrUpdateGroupStringCheckRule","/v1/devService/saveOrUpdateGroupStringCheckRule"},
- {"AppService","saveParamModel","/v1/devService/saveParamModel"},
- {"AppService","savePowerCharges","/v1/powerStationService/savePowerCharges"},
- {"AppService","savePowerDevicePoint","/v1/reportService/savePowerDevicePoint"},
- {"AppService","savePowerRobotInfo","/v1/devService/savePowerRobotInfo"},
- {"AppService","savePowerRobotSweepAttr","/v1/devService/savePowerRobotSweepAttr"},
- {"AppService","savePowerSettingCharges","/v1/powerStationService/savePowerSettingCharges"},
- {"AppService","savePowerSettingInfo","/v1/powerStationService/savePowerSettingInfo"},
- {"AppService","saveProductionBatchData","/v1/devService/saveProductionBatchData"},
- {"AppService","saveRechargeOrderObj","/onlinepay/saveRechargeOrderObj"},
- {"AppService","saveRechargeOrderOtherInfo","/onlinepay/saveRechargeOrderOtherInfo"},
- {"AppService","saveRepair","/v1/faultService/saveRepair"},
- {"AppService","saveReportExportColumns","/v1/reportService/saveReportExportColumns"},
- {"AppService","saveSetParam","/v1/devService/saveSetParam"},
- {"AppService","saveSysUserMsg","/v1/otherService/saveSysUserMsg"},
- {"AppService","saveTemplate","/v1/devService/saveTemplate"},
- {"AppService","searchM2MMonthFlowCMCC","/v1/devService/searchM2MMonthFlowCMCC"},
- {"AppService","selectSysTranslationNames","/v1/reportService/selectSysTranslationNames"},
- {"AppService","sendPsTimeZoneInstruction","/devDataHandleService/sendPsTimeZoneInstruction"},
- {"AppService","setUpFormulaFaultAnalyse","/v1/powerStationService/setUpFormulaFaultAnalyse"},
- {"AppService","setUserGDPRAttrs","/v1/userService/setUserGDPRAttrs"},
- {"AppService","settingNotice","/v1/userService/settingNotice"},
- {"AppService","shareMyPs","/v1/powerStationService/shareMyPs"},
- {"AppService","sharePsBySN","/v1/powerStationService/sharePsBySN"},
- {"AppService","showInverterByUnit","/v1/devService/showInverterByUnit"},
- {"AppService","showOnlineUsers","/v1/userService/showOnlineUsers"},
- {"AppService","showWarning","/v1/userService/showWarning"},
- {"AppService","snIsExist","/v1/devService/snIsExist"},
- {"AppService","snsIsExist","/v1/devService/snsIsExist"},
- {"AppService","speedyAddPowerStation","/v1/powerStationService/speedyAddPowerStation"},
- {"AppService","stationDeviceHistoryDataList","/v1/powerStationService/stationDeviceHistoryDataList"},
- {"AppService","stationUnitsList","/v1/powerStationService/stationUnitsList"},
- {"AppService","stationsDiscreteData","/v1/devService/stationsDiscreteData"},
- {"AppService","stationsIncomeList","/v1/powerStationService/stationsIncomeList"},
- {"AppService","stationsPointReport","/v1/powerStationService/stationsPointReport"},
- {"AppService","stationsYearPlanReport","/v1/reportService/stationsYearPlanReport"},
- {"AppService","sureAndImportSelettlementData","/v1/otherService/sureAndImportSelettlementData"},
- {"AppService","sweepDevParamSet","/v1/devService/sweepDevParamSet"},
- {"AppService","sweepDevRunControl","/v1/devService/sweepDevRunControl"},
- {"AppService","sweepDevStrategyIssue","/v1/devService/sweepDevStrategyIssue"},
- {"AppService","sysTimeZoneList","/v1/commonService/sysTimeZoneList"},
- {"AppService","unLockUser","/v1/userService/unLockUser"},
- {"AppService","unlockChildAccount","/v1/userService/unlockChildAccount"},
- {"AppService","updateCommunicationModuleState","/v1/devService/updateCommunicationModuleState"},
- {"AppService","updateDevInstalledPower","/v1/devService/updateDevInstalledPower"},
- {"AppService","updateFault","/v1/faultService/updateFaultStatus"},
- {"AppService","updateFaultData","/v1/faultService/updateFaultData"},
- {"AppService","updateFaultMsgByFaultCode","/v1/faultService/updateFaultMsgByFaultCode"},
- {"AppService","updateFaultStatus","/v1/faultService/updateFaultStatus"},
- {"AppService","updateHouseholdWorkOrder","/v1/faultService/updateHouseholdWorkOrder"},
- {"AppService","updateInverterSn2ModuleSn","/devDataHandleService/updateInverterSn2ModuleSn"},
- {"AppService","updateOperateTicketAttachmentId","/v1/faultService/updateOperateTicketAttachmentId"},
- {"AppService","updateOrderDeviceByCustomerService","/onlinepay/updateOrderDeviceByCustomerService"},
- {"AppService","updateOwnerFaultConfig","/v1/faultService/updateOwnerFaultConfig"},
- {"AppService","updateParamSettingSysMsg","/v1/devService/updateParamSettingSysMsg"},
- {"AppService","updatePlatformLevelFaultLevel","/v1/faultService/updatePlatformLevelFaultLevel"},
- {"AppService","updatePowerDevicePoint","/v1/reportService/updatePowerDevicePoint"},
- {"AppService","updatePowerRobotInfo","/v1/devService/updatePowerRobotInfo"},
- {"AppService","updatePowerRobotSweepAttr","/v1/devService/updatePowerRobotSweepAttr"},
- {"AppService","updatePowerStationForHousehold","/v1/powerStationService/updatePowerStationForHousehold"},
- {"AppService","updatePowerStationInfo","/v1/powerStationService/updatePowerStationInfo"},
- {"AppService","updatePowerUserInfo","/v1/userService/updatePowerUserInfo"},
- {"AppService","updateReportConfigByEmailAddr","/v1/reportService/updateReportConfigByEmailAddr"},
- {"AppService","updateShareAttr","/v1/powerStationService/updateShareAttr"},
- {"AppService","updateSnIsSureFlag","/devDataHandleService/updateSnIsSureFlag"},
- {"AppService","updateStationPics","/v1/powerStationService/updateStationPics"},
- {"AppService","updateSysAdvancedParam","/v1/devService/updateSysAdvancedParam"},
- {"AppService","updateSysOrgNew","/v1/otherService/updateSysOrgNew"},
- {"AppService","updateTemplate","/v1/devService/updateDataCurveTemplate"},
- {"AppService","updateUinfoNetEaseUser","/v1/userService/updateUinfoNetEaseUser"},
- {"AppService","updateUserExtensionAttribute","/v1/userService/updateUserExtensionAttribute"},
- {"AppService","updateUserLanguage","/v1/userService/updateUserLanguage"},
- {"AppService","updateUserPosition","/v1/userService/updateUserPosition"},
- {"AppService","updateUserUpOrg","/v1/orgService/updateUserUpOrg"},
- {"AppService","upgrade","/v1/userService/upgrade"},
- {"AppService","upgrate","/v1/userService/upgrade"},
- {"AppService","uploadFileToOss","/v1/commonService/uploadFileToOss"},
- {"AppService","userAgreeGdprProtocol","/v1/userService/userAgreeGdprProtocol"},
- {"AppService","userInfoUniqueCheck","/v1/userService/userInfoUniqueCheck"},
- {"AppService","userMailHasBound","/v1/userService/userMailHasBound"},
- {"AppService","userRegister","/v1/userService/userRegister"},
-}
-
-
-type AreaStruct struct {
- Name api.AreaName
- EndPoints api.TypeEndPoints
-}
-var Area AreaStruct
-
-func init() {
- ref := reflect.TypeOf(AreaStruct{})
- p := ref.String()
- s := ref.Name()
- Area.Name = api.AreaName(strings.TrimSuffix(p, "." + s))
- Area.EndPoints = api.CreateEndPoints(endpoints)
-
- for _, e := range Area.EndPoints {
- fmt.Printf("%s/%s -> %s\n",
- e.Area,
- e.Name,
- e.Url.String(),
- )
-
- if e.Name == "getPowerDevicePointNames" {
- fmt.Println("HEYHEYHEY")
- // foo := e.Resource.GetResource()
- // fmt.Printf("R:%v\n", foo)
- e.Resource = getPowerDevicePointNames.Init()
- fmt.Printf("Resource: %v\n", e.Resource)
- // (getPowerDevicePointNames.Resource)(e.Resource).Call()
- // e.Response = getPowerDevicePointNames.Resource{}
- // e.Request = getPowerDevicePointNames.Resource{}
- continue
- }
-
- }
-
-
- fmt.Println("HEY")
- foo := Area.EndPoints.GetEndPoint("getPowerDevicePointNames")
- foo.Resource = getPowerDevicePointNames.Resource{}
- // _ = foo.SetRequest(getPowerDevicePointNames.Request {
- // RequestCommon: api.RequestCommon {
- // Appkey: "",
- // DeviceType: "",
- // Lang: "",
- // SysCode: "",
- // Token: "",
- // UserID: "",
- // ValidFlag: "",
- // },
- // Extra: "HOWDY",
- // })
-
- // foo.Resource = getPowerDevicePointNames.Resource {
- // Request: getPowerDevicePointNames.Request {
- // RequestCommon: api.RequestCommon {
- // Get: nil,
- // Set: nil,
- // Appkey: "",
- // DeviceType: "",
- // Lang: "",
- // SysCode: "",
- // Token: "",
- // UserID: "",
- // ValidFlag: "",
- // },
- // Extra: "",
- // },
- // Response: getPowerDevicePointNames.Response {
- // ResponseCommon: api.ResponseCommon {
- // Get: nil,
- // Set: nil,
- // ReqSerialNum: "",
- // ResultCode: "",
- // ResultData: nil,
- // ResultMsg: "",
- // },
- // Another: "",
- // },
- // }
- // foo.Resource.SetRequest(nil)
-}
-
-
-func PutMe(j api.Json) {
- fmt.Println("Hello world!")
- fmt.Println(j)
-}
\ No newline at end of file
diff --git a/iSolarCloud/AppService/pkgreflect.go b/iSolarCloud/AppService/pkgreflect.go
deleted file mode 100644
index b9ca7fc57..000000000
--- a/iSolarCloud/AppService/pkgreflect.go
+++ /dev/null
@@ -1,21 +0,0 @@
-// Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
-
-package AppService
-
-import "reflect"
-
-var Types = map[string]reflect.Type{
- "AreaStruct": reflect.TypeOf((*AreaStruct)(nil)).Elem(),
-}
-
-var Functions = map[string]reflect.Value{
- "PutMe": reflect.ValueOf(PutMe),
-}
-
-var Variables = map[string]reflect.Value{
- "Area": reflect.ValueOf(&Area),
-}
-
-var Consts = map[string]reflect.Value{
-}
-
diff --git a/iSolarCloud/api/api.go b/iSolarCloud/api/api.go
index 071b4fd23..e45e8efaf 100644
--- a/iSolarCloud/api/api.go
+++ b/iSolarCloud/api/api.go
@@ -3,6 +3,11 @@
package api
+
+
+
+
+
var ApiFoo = (*Api)(nil)
func LoadMe() bool {
diff --git a/iSolarCloud/api/call.go b/iSolarCloud/api/call.go
new file mode 100644
index 000000000..a91cf34bd
--- /dev/null
+++ b/iSolarCloud/api/call.go
@@ -0,0 +1,5 @@
+package api
+
+func Call() {
+
+}
diff --git a/iSolarCloud/api/content_handler.go b/iSolarCloud/api/content_handler.go
index 1d684b89a..91f8abfb8 100644
--- a/iSolarCloud/api/content_handler.go
+++ b/iSolarCloud/api/content_handler.go
@@ -1,6 +1,6 @@
package api
-type ContentHandlers []ContentHandler
-type ContentHandler interface {
- InitializeContentType(*ContentType) *ContentType
-}
+// type ContentHandlers []ContentHandler
+// type ContentHandler interface {
+// InitializeContentType(*ContentType) *ContentType
+// }
diff --git a/iSolarCloud/api/content_type.go b/iSolarCloud/api/content_type.go
index 7b4cbf57e..ae43e343a 100644
--- a/iSolarCloud/api/content_type.go
+++ b/iSolarCloud/api/content_type.go
@@ -1,111 +1,106 @@
package api
-import (
- "reflect"
- "strings"
-)
-
-
-var contentTypes ContentTypes
-
-func init() {
- contentTypes = make(ContentTypes, 0)
-}
-
-type ContentTable string
-type ContentTypeSlug string
-type ContentTypes map[ContentTypeSlug]*ContentType
-
-func GetContentTypes() ContentTypes {
- return contentTypes
-}
-
-type DbFields []DbField
-type DbField string
+// var contentTypes ContentTypes
//
-// Nil instances are created by using (*)(nil)
-// or ()(nil), e.g. (*ContentType)(nil)
+// func init() {
+// contentTypes = make(ContentTypes, 0)
+// }
//
-type ContentType struct {
- //
- // Lowercase version of the Struct name w/o the package name
- // e.g. syncer.ContentType => 'contenttype'
- //
- slug ContentTypeSlug
-
- //
- // Table name in MySQL database to store content for this content type.
- //
- table ContentTable
-
- DbFields DbFields
-
- DbOnDupKey DbFields
-
- //
- // Nil instance of the type to contain the actual content
- // after unmarshalling JSON from API response
- //
- InstanceType interface{}
-
- //
- // Nil instance of the type that can be used to unmarshal JSON
- // for a API response containing a single "resource."
- //
- ResourceType interface{}
-
- //
- // Nil instance of the type that can be used to unmarshal JSON
- // for a API response containing a multiples "resources."
- //
- CollectionType interface{}
-
- //
- // The MIME type returned by API responses. Typically "application/json"
- // but we envision supporting "application/xml"
- //
- MimeType MimeType
-
- //
- // Content with Api Entry Points have direct URLs that do
- // not need to be discovered in other API responses.
- //
- IsApiEntryPoint bool
-
- //
- // Content with a Download Priority can be downloaded directly from the API.
- // Content w/o Download Priority is found embedded in downloaded content.
- //
- DownloadPriority int
-}
-
-func (me *ContentType) SetSlug(slug ContentTypeSlug) {
- me.slug = slug
-}
-
-func (me *ContentType) GetSlug() ContentTypeSlug {
- if me.slug == "" {
- s := strings.Split(reflect.TypeOf(me.InstanceType).String(), ".")[1]
- me.slug = ContentTypeSlug(ToSnakeCase(s))
- }
- return me.slug
-}
-
-func (me *ContentType) SetTable(table ContentTable) {
- me.table = table
-}
-
-func (me *ContentType) GetTable() ContentTable {
- if me.table == "" {
- me.table = ContentTable(me.GetSlug())
- }
- return me.table
-}
-
-func NewContentType(instanceType interface{}) *ContentType {
- return &ContentType{
- InstanceType: instanceType,
- MimeType: ApplicationJson,
- }
-}
+// type ContentTable string
+// type ContentTypeSlug string
+// type ContentTypes map[ContentTypeSlug]*ContentType
+//
+// func GetContentTypes() ContentTypes {
+// return contentTypes
+// }
+//
+// type DbFields []DbField
+// type DbField string
+//
+// //
+// // Nil instances are created by using (*)(nil)
+// // or ()(nil), e.g. (*ContentType)(nil)
+// //
+// type ContentType struct {
+// //
+// // Lowercase version of the Struct name w/o the package name
+// // e.g. syncer.ContentType => 'contenttype'
+// //
+// slug ContentTypeSlug
+//
+// //
+// // Table name in MySQL database to store content for this content type.
+// //
+// table ContentTable
+//
+// DbFields DbFields
+//
+// DbOnDupKey DbFields
+//
+// //
+// // Nil instance of the type to contain the actual content
+// // after unmarshalling JSON from API response
+// //
+// InstanceType interface{}
+//
+// //
+// // Nil instance of the type that can be used to unmarshal JSON
+// // for a API response containing a single "EndPoint."
+// //
+// ResourceType interface{}
+//
+// //
+// // Nil instance of the type that can be used to unmarshal JSON
+// // for a API response containing a multiples "resources."
+// //
+// CollectionType interface{}
+//
+// //
+// // The MIME type returned by API responses. Typically "application/json"
+// // but we envision supporting "application/xml"
+// //
+// MimeType MimeType
+//
+// //
+// // Content with Api Entry Points have direct URLs that do
+// // not need to be discovered in other API responses.
+// //
+// IsApiEntryPoint bool
+//
+// //
+// // Content with a Download Priority can be downloaded directly from the API.
+// // Content w/o Download Priority is found embedded in downloaded content.
+// //
+// DownloadPriority int
+// }
+//
+// func (me *ContentType) SetSlug(slug ContentTypeSlug) {
+// me.slug = slug
+// }
+//
+// func (me *ContentType) GetSlug() ContentTypeSlug {
+// if me.slug == "" {
+// s := strings.Split(reflect.TypeOf(me.InstanceType).String(), ".")[1]
+// me.slug = ContentTypeSlug(ToSnakeCase(s))
+// }
+// return me.slug
+// }
+//
+// func (me *ContentType) SetTable(table ContentTable) {
+// me.table = table
+// }
+//
+// func (me *ContentType) GetTable() ContentTable {
+// if me.table == "" {
+// me.table = ContentTable(me.GetSlug())
+// }
+// return me.table
+// }
+//
+// func NewContentType(instanceType interface{}) *ContentType {
+// return &ContentType{
+// InstanceType: instanceType,
+// MimeType: ApplicationJson,
+// }
+// }
diff --git a/iSolarCloud/api/init.go b/iSolarCloud/api/init.go
index 6a78b99e7..4f181fcd1 100644
--- a/iSolarCloud/api/init.go
+++ b/iSolarCloud/api/init.go
@@ -1,19 +1,19 @@
package api
-func Initialize(contentHandlers ContentHandlers) {
- for _, ch := range contentHandlers {
- contentHandler, ok := ch.(ContentHandler)
- if !ok {
- LogError(ErrorArgs{
- Instance: ch,
- ErrorType: DoesNotImplement,
- Interface: (ContentHandler)(nil),
- })
- continue
- }
- ct := NewContentType(ch)
- ct = contentHandler.InitializeContentType(ct)
- contentTypes[ct.GetSlug()] = ct
- }
-
-}
+// func Initialize(contentHandlers ContentHandlers) {
+// for _, ch := range contentHandlers {
+// contentHandler, ok := ch.(ContentHandler)
+// if !ok {
+// LogError(ErrorArgs{
+// Instance: ch,
+// ErrorType: DoesNotImplement,
+// Interface: (ContentHandler)(nil),
+// })
+// continue
+// }
+// ct := NewContentType(ch)
+// ct = contentHandler.InitializeContentType(ct)
+// contentTypes[ct.GetSlug()] = ct
+// }
+//
+// }
diff --git a/iSolarCloud/api/pkgreflect.go b/iSolarCloud/api/pkgreflect.go
index 714b0371d..778f64ec1 100644
--- a/iSolarCloud/api/pkgreflect.go
+++ b/iSolarCloud/api/pkgreflect.go
@@ -1,65 +1 @@
-// Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
-
package api
-
-import "reflect"
-
-var Types = map[string]reflect.Type{
- "Api": reflect.TypeOf((*Api)(nil)).Elem(),
- "AreaName": reflect.TypeOf((*AreaName)(nil)).Elem(),
- "Common": reflect.TypeOf((*Common)(nil)).Elem(),
- "ContentHandler": reflect.TypeOf((*ContentHandler)(nil)).Elem(),
- "ContentHandlers": reflect.TypeOf((*ContentHandlers)(nil)).Elem(),
- "ContentTable": reflect.TypeOf((*ContentTable)(nil)).Elem(),
- "ContentType": reflect.TypeOf((*ContentType)(nil)).Elem(),
- "ContentTypeSlug": reflect.TypeOf((*ContentTypeSlug)(nil)).Elem(),
- "ContentTypes": reflect.TypeOf((*ContentTypes)(nil)).Elem(),
- "DbField": reflect.TypeOf((*DbField)(nil)).Elem(),
- "DbFields": reflect.TypeOf((*DbFields)(nil)).Elem(),
- "EndPointName": reflect.TypeOf((*EndPointName)(nil)).Elem(),
- "ErrorArg": reflect.TypeOf((*ErrorArg)(nil)).Elem(),
- "ErrorArgs": reflect.TypeOf((*ErrorArgs)(nil)).Elem(),
- "GetFunc": reflect.TypeOf((*GetFunc)(nil)).Elem(),
- "Guid": reflect.TypeOf((*Guid)(nil)).Elem(),
- "Json": reflect.TypeOf((*Json)(nil)).Elem(),
- "MimeType": reflect.TypeOf((*MimeType)(nil)).Elem(),
- "ParentGuid": reflect.TypeOf((*ParentGuid)(nil)).Elem(),
- "RequestCommon": reflect.TypeOf((*RequestCommon)(nil)).Elem(),
- "Resource": reflect.TypeOf((*Resource)(nil)).Elem(),
- "ResponseCommon": reflect.TypeOf((*ResponseCommon)(nil)).Elem(),
- "SetFunc": reflect.TypeOf((*SetFunc)(nil)).Elem(),
- "TypeAreaNames": reflect.TypeOf((*TypeAreaNames)(nil)).Elem(),
- "TypeEndPoint": reflect.TypeOf((*TypeEndPoint)(nil)).Elem(),
- "TypeEndPoints": reflect.TypeOf((*TypeEndPoints)(nil)).Elem(),
- "Url": reflect.TypeOf((*Url)(nil)).Elem(),
-}
-
-var Functions = map[string]reflect.Value{
- "AppendUrl": reflect.ValueOf(AppendUrl),
- "CreateEndPoints": reflect.ValueOf(CreateEndPoints),
- "GetContentTypes": reflect.ValueOf(GetContentTypes),
- "Initialize": reflect.ValueOf(Initialize),
- "LoadMe": reflect.ValueOf(LoadMe),
- "LogError": reflect.ValueOf(LogError),
- "MakeNewFrom": reflect.ValueOf(MakeNewFrom),
- "NewContentType": reflect.ValueOf(NewContentType),
- "SetBasicAuth": reflect.ValueOf(SetBasicAuth),
- "SetUrl": reflect.ValueOf(SetUrl),
- "ToSnakeCase": reflect.ValueOf(ToSnakeCase),
-}
-
-var Variables = map[string]reflect.Value{
- "ApiFoo": reflect.ValueOf(&ApiFoo),
- "OnlyOnce": reflect.ValueOf(&OnlyOnce),
- "SunGro": reflect.ValueOf(&SunGro),
-}
-
-var Consts = map[string]reflect.Value{
- "ApplicationJson": reflect.ValueOf(ApplicationJson),
- "ApplicationXml": reflect.ValueOf(ApplicationXml),
- "DoesNotImplement": reflect.ValueOf(DoesNotImplement),
- "ErrorType": reflect.ValueOf(ErrorType),
- "Instance": reflect.ValueOf(Instance),
- "Interface": reflect.ValueOf(Interface),
-}
-
diff --git a/iSolarCloud/api/struct_area.go b/iSolarCloud/api/struct_area.go
new file mode 100644
index 000000000..198493e01
--- /dev/null
+++ b/iSolarCloud/api/struct_area.go
@@ -0,0 +1,70 @@
+package api
+
+import (
+ "GoSungro/Only"
+ "errors"
+ "fmt"
+)
+
+type Area interface {
+ Init() AreaStruct
+ GetAreaName() AreaName
+ GetEndPoints() TypeEndPoints
+ Call(name EndPointName) Json
+ SetRequest(name EndPointName, ref interface{}) error
+ GetRequest(name EndPointName) Json
+ GetResponse(name EndPointName) Json
+ GetData(name EndPointName) Json
+ IsValid(name EndPointName) error
+ GetError(name EndPointName) error
+}
+
+type AreaStruct struct {
+ Name AreaName
+ EndPoints TypeEndPoints
+ Error error
+}
+
+
+func (as AreaStruct) Exists(name EndPointName) error {
+ var err error
+ for range Only.Once {
+ if _, ok := as.EndPoints[name]; !ok {
+ err = errors.New("unknown endpoint")
+ break
+ }
+ }
+
+ return err
+}
+
+func (as *AreaStruct) SortEndPoints() []EndPointName {
+ return as.EndPoints.SortEndPoints()
+}
+
+func (as *AreaStruct) GetEndPoint(name EndPointName) EndPoint {
+ return as.EndPoints.GetEndPoint(name)
+}
+
+func (as AreaStruct) ListEndpoints() {
+ for range Only.Once {
+ fmt.Printf("Listing all endpoints from area '%s':\n", as.Name)
+ as.EndPoints.ListEndpoints()
+
+ // table := tablewriter.NewWriter(os.Stdout)
+ // table.SetHeader([]string{"Area", "EndPoint", "Url"})
+ // table.SetBorder(true)
+ // for _, endpoint := range as.SortEndPoints() {
+ // table.Append([]string{
+ // string(as.Name),
+ // string(as.EndPoints[endpoint].GetName()),
+ // as.EndPoints[endpoint].GetUrl().String(),
+ // })
+ // }
+ // table.Render()
+ }
+}
+
+func (as AreaStruct) CountEndpoints() int {
+ return as.EndPoints.CountEndpoints()
+}
diff --git a/iSolarCloud/api/struct_areas.go b/iSolarCloud/api/struct_areas.go
index aaaade2c1..17bf10f02 100644
--- a/iSolarCloud/api/struct_areas.go
+++ b/iSolarCloud/api/struct_areas.go
@@ -3,15 +3,28 @@ package api
import (
"GoSungro/Only"
"errors"
+ "fmt"
+ "github.com/olekukonko/tablewriter"
+ "os"
"sort"
)
-type TypeAreaNames map[AreaName]TypeEndPoints // Map of EndPoints by area name.
+type Areas map[AreaName]AreaStruct // TypeEndPoints // Map of EndPoints by area name.
type AreaName string
+type AreaNames []AreaName
-func (an *TypeAreaNames) Exists(area AreaName, name EndPointName) error {
+func (an *Areas) Exists(area string) bool {
+ var ok bool
+ _, ok = (*an)[AreaName(area)]
+ return ok
+}
+func (an *Areas) NotExists(area string) bool {
+ return !an.Exists(area)
+}
+
+func (an *Areas) EndpointExists(area AreaName, name EndPointName) error {
var err error
for range Only.Once {
if _, ok := (*an)[area]; !ok {
@@ -25,112 +38,106 @@ func (an *TypeAreaNames) Exists(area AreaName, name EndPointName) error {
return err
}
-func (an *TypeAreaNames) SortAreas() []AreaName {
+func (an *Areas) SortAreas() AreaNames {
keys := make([]string, 0, len(*an))
for k := range *an {
keys = append(keys, string(k))
}
sort.Strings(keys)
- ret := make([]AreaName, 0, len(keys))
+ ret := make(AreaNames, 0, len(keys))
for _, r := range keys {
ret = append(ret, AreaName(r))
}
return ret
}
-func (an *TypeAreaNames) GetEndPoint(area AreaName, name EndPointName) *TypeEndPoint {
- var ret *TypeEndPoint
+func (an *Areas) GetEndPoint(area AreaName, name EndPointName) EndPoint {
+ var ret EndPoint
for range Only.Once {
if _, ok := (*an)[area]; !ok {
break
}
- point := (*an)[area]
- ret = point.GetEndPoint(name)
+ ret = (*an)[area].EndPoints[name]
}
return ret
}
-func (an *TypeAreaNames) SetFuncPut(area AreaName, endpoint EndPointName, fn SetFunc) error {
+func (an Areas) ListAreas() {
+ for range Only.Once {
+ fmt.Println("Listing all endpoint areas:")
+
+ table := tablewriter.NewWriter(os.Stdout)
+ table.SetHeader([]string{"Areas", "EndPoints"})
+ table.SetBorder(true)
+ for _, area := range an.SortAreas() {
+ size := fmt.Sprintf("%d", an[area].CountEndpoints())
+ table.Append([]string{string(area), size})
+ }
+ table.Render()
+ }
+}
+
+func (an Areas) ListEndpoints(area string) error {
var err error
for range Only.Once {
- err = an.Exists(area, endpoint)
- if err != nil {
+ if area == "" {
+ fmt.Printf("Listing all areas:\n")
+ for _, a := range an.SortAreas() {
+ an[a].ListEndpoints()
+ }
break
}
- point := (*an)[area][endpoint]
- err = point.SetFuncPut(fn)
+
+ if an.NotExists(area) {
+ err = errors.New("unknown area name")
+ break
+ }
+
+ an[AreaName(area)].ListEndpoints()
}
+
return err
}
-func (an *TypeAreaNames) SetFuncGet(area AreaName, endpoint EndPointName, fn GetFunc) error {
- var err error
- for range Only.Once {
- err = an.Exists(area, endpoint)
- if err != nil {
- break
- }
- point := (*an)[area][endpoint]
- err = point.SetFuncGet(fn)
- }
- return err
-}
-
-func (an *TypeAreaNames) SetRequest(area AreaName, endpoint EndPointName, ref interface{}) error {
+func (an *Areas) SetRequest(area AreaName, name EndPointName, ref interface{}) error {
var err error
for range Only.Once {
- err = an.Exists(area, endpoint)
+ err = an.EndpointExists(area, name)
if err != nil {
break
}
- point := (*an)[area][endpoint]
+ point := (*an)[area].EndPoints[name]
err = point.SetRequest(ref)
}
return err
}
-func (an *TypeAreaNames) SetResponse(area AreaName, endpoint EndPointName, ref interface{}) error {
- var err error
+func (an *Areas) GetRequest(area AreaName, endpoint EndPointName) Json {
+ var ret Json
for range Only.Once {
- err = an.Exists(area, endpoint)
+ err := an.EndpointExists(area, endpoint)
if err != nil {
break
}
-
- point := (*an)[area][endpoint]
- err = point.SetResponse(ref)
- }
-
- return err
-}
-
-func (an *TypeAreaNames) GetRequest(area AreaName, endpoint EndPointName) interface{} {
- var ret interface{}
-
- for range Only.Once {
- err := an.Exists(area, endpoint)
- if err != nil {
- break
- }
- ret = an.GetEndPoint(area, endpoint).Request
+ ret = an.GetEndPoint(area, endpoint).GetRequest()
}
return ret
}
-func (an *TypeAreaNames) GetResponse(area AreaName, endpoint EndPointName) interface{} {
- var ret interface{}
+func (an *Areas) GetResponse(area AreaName, endpoint EndPointName) Json {
+ var ret Json
for range Only.Once {
- err := an.Exists(area, endpoint)
+ err := an.EndpointExists(area, endpoint)
if err != nil {
break
}
- ret = an.GetEndPoint(area, endpoint).Response
+ ret = an.GetEndPoint(area, endpoint).GetResponse()
}
return ret
diff --git a/iSolarCloud/api/struct_endpoint.go b/iSolarCloud/api/struct_endpoint.go
index 07b75603f..f662064c5 100644
--- a/iSolarCloud/api/struct_endpoint.go
+++ b/iSolarCloud/api/struct_endpoint.go
@@ -8,24 +8,28 @@ import (
)
-// type ResourceType struct {
-// Area AreaName `json:"area"`
-// Name EndPointName `json:"name"`
-// Url *url.URL `json:"url"`
-// }
-
-type Resource interface {
+type EndPoint interface {
+ GetArea() AreaName
+ GetName() EndPointName
+ GetUrl() *url.URL
Call() Json
SetRequest(ref interface{}) error
- GetResource() interface{}
+ GetRequest() Json
+ GetResponse() Json
+ GetData() Json
+ IsValid() error
+ GetError() error
}
-// type Response interface {
-// SetFuncPut(fn SetFunc) error
-// SetFuncGet(fn GetFunc) error
-// SetResponse(ref interface{})
-// }
+type EndPointStruct struct {
+ Area AreaName `json:"area"`
+ Name EndPointName `json:"name"`
+ Url *url.URL `json:"url"`
+ Request interface{} `json:"request"`
+ Response interface{} `json:"response"`
+ Error error `json:"error"`
+}
type Common struct {
Get GetFunc
@@ -34,56 +38,22 @@ type Common struct {
}
type RequestCommon struct {
- Get GetFunc
- Set SetFunc
-
Appkey string `json:"appkey"`
- DeviceType string `json:"device_type"`
Lang string `json:"lang"`
SysCode string `json:"sys_code"`
Token string `json:"token"`
UserID string `json:"user_id"`
ValidFlag string `json:"valid_flag"`
+ // DeviceType string `json:"device_type"`
}
type ResponseCommon struct {
- Get GetFunc
- Set SetFunc
-
ReqSerialNum string `json:"req_serial_num"`
ResultCode string `json:"result_code"`
ResultData []interface{} `json:"result_data"`
ResultMsg string `json:"result_msg"`
}
-
-type TypeEndPoint struct {
- Area AreaName `json:"area"`
- Name EndPointName `json:"name"`
- Url *url.URL `json:"url"`
-
- resource interface{}
- Request interface{}
- Response interface{}
-
- Get GetFunc
- Put SetFunc
-
- Error error
-}
-
-// func (p *TypeEndPoint) Call() Json {
-// panic("implement me")
-// }
-//
-// func (p *TypeEndPoint) GetResource() interface{} {
-// panic("implement me")
-// }
-
-func (ps *TypeEndPoints) SetResource(ref interface{}) {
-
-}
-
type EndPointName string
type Json string
@@ -91,7 +61,42 @@ type GetFunc func() Json
type SetFunc func(j Json)
-func (p *TypeEndPoint) IsValid() error {
+func (p *EndPointStruct) GetArea() AreaName {
+ return p.Area
+}
+
+func (p *EndPointStruct) GetName() EndPointName {
+ return p.Name
+}
+
+func (p *EndPointStruct) GetUrl() *url.URL {
+ return p.Url
+}
+
+func (p *EndPointStruct) Call() Json {
+ panic("implement me")
+}
+
+func (p *EndPointStruct) SetRequest(ref interface{}) error {
+ for range Only.Once {
+ if ref == nil {
+ p.Error = errors.New("endpoint has a nil request structure")
+ break
+ }
+ p.Request = ref
+ }
+ return p.Error
+}
+
+func (p *EndPointStruct) GetRequest() Json {
+ panic("implement me")
+}
+
+func (p *EndPointStruct) GetResponse() Json {
+ panic("implement me")
+}
+
+func (p *EndPointStruct) IsValid() error {
var err error
for range Only.Once {
if p == nil {
@@ -110,53 +115,43 @@ func (p *TypeEndPoint) IsValid() error {
return err
}
-func (p *TypeEndPoint) SetFuncPut(fn SetFunc) error {
- for range Only.Once {
- if fn == nil {
- p.Error = errors.New("endpoint put function is nil")
- break
- }
- p.Put = fn
- }
- return p.Error
-}
-func (p *TypeEndPoint) SetFuncGet(fn GetFunc) error {
- for range Only.Once {
- if fn == nil {
- p.Error = errors.New("endpoint get function is nil")
- break
- }
- p.Get = fn
- }
- return p.Error
-}
-
-func (p *TypeEndPoint) SetResponse(ref interface{}) error {
- for range Only.Once {
- if ref == nil {
- p.Error = errors.New("endpoint has a nil response structure")
- break
- }
- p.Response = ref
- }
- return p.Error
-}
-
-func (p *TypeEndPoint) SetRequest(ref interface{}) error {
- for range Only.Once {
- if ref == nil {
- p.Error = errors.New("endpoint has a nil request structure")
- break
- }
- p.Request = ref
- }
- return p.Error
-}
-
-// func (p *TypeEndPoint) SetResource(ref interface{}) Resource {
+// func (p *EndPointStruct) SetFuncPut(fn SetFunc) error {
// for range Only.Once {
-// p.Resource = ref
+// if fn == nil {
+// p.Error = errors.New("endpoint put function is nil")
+// break
+// }
+// p.Put = fn
// }
-// return p.Resource
+// return p.Error
+// }
+//
+// func (p *EndPointStruct) SetFuncGet(fn GetFunc) error {
+// for range Only.Once {
+// if fn == nil {
+// p.Error = errors.New("endpoint get function is nil")
+// break
+// }
+// p.Get = fn
+// }
+// return p.Error
+// }
+//
+// func (p *EndPointStruct) SetResponse(ref interface{}) error {
+// for range Only.Once {
+// if ref == nil {
+// p.Error = errors.New("endpoint has a nil response structure")
+// break
+// }
+// p.Response = ref
+// }
+// return p.Error
+// }
+//
+// func (p *EndPointStruct) SetResource(ref interface{}) EndPoint {
+// for range Only.Once {
+// p.EndPoint = ref
+// }
+// return p.EndPoint
// }
diff --git a/iSolarCloud/api/struct_endpoints.go b/iSolarCloud/api/struct_endpoints.go
index eb51baf0d..18d061a9d 100644
--- a/iSolarCloud/api/struct_endpoints.go
+++ b/iSolarCloud/api/struct_endpoints.go
@@ -3,12 +3,15 @@ package api
import (
"GoSungro/Only"
"errors"
+ "fmt"
+ "github.com/olekukonko/tablewriter"
+ "os"
"sort"
)
-type TypeEndPoints map[EndPointName]TypeEndPoint // Map of EndPoints by endpoint name.
-// type EndPointNames []EndPointName
+// type TypeEndPoints map[EndPointName]EndPointStruct // Map of EndPoints by endpoint name.
+type TypeEndPoints map[EndPointName]EndPoint // Map of EndPoints by endpoint name.
func (ps TypeEndPoints) Exists(name EndPointName) error {
@@ -23,16 +26,41 @@ func (ps TypeEndPoints) Exists(name EndPointName) error {
return err
}
-func (ps *TypeEndPoints) SortEndPoints() []string {
+func (ps *TypeEndPoints) SortEndPoints() []EndPointName {
keys := make([]string, 0, len(*ps))
for k := range *ps {
keys = append(keys, string(k))
}
sort.Strings(keys)
- return keys
+
+ ret := make([]EndPointName, 0, len(*ps))
+ for k := range keys {
+ keys = append(keys, string(k))
+ }
+ return ret
}
-func (ps *TypeEndPoints) GetEndPoint(name EndPointName) *TypeEndPoint {
- ret, _ := (*ps)[name]
- return &ret
+func (ps TypeEndPoints) ListEndpoints() {
+ for range Only.Once {
+ table := tablewriter.NewWriter(os.Stdout)
+ table.SetHeader([]string{"EndPoint", "Url"})
+ table.SetBorder(true)
+ for _, endpoint := range ps.SortEndPoints() {
+ table.Append([]string{
+ string(ps[endpoint].GetName()),
+ ps[endpoint].GetUrl().String(),
+ })
+ }
+ table.Render()
+ }
+}
+
+func (ps *TypeEndPoints) CountEndpoints() int {
+ return len(*ps)
+}
+
+func (ps *TypeEndPoints) GetEndPoint(name EndPointName) EndPoint {
+ ret, _ := (*ps)[name]
+ fmt.Printf("ok:%v\tref:%v\n")
+ return ret
}
diff --git a/iSolarCloud/api/utils.go b/iSolarCloud/api/utils.go
index 5c325b9e5..168c2e94c 100644
--- a/iSolarCloud/api/utils.go
+++ b/iSolarCloud/api/utils.go
@@ -2,51 +2,27 @@ package api
import (
"GoSungro/Only"
+ "encoding/json"
"fmt"
"net/url"
"reflect"
"strings"
)
-var OnlyOnce = "1"
-func MakeNewFrom(i interface{}) (new interface{}) {
- for range OnlyOnce {
- t := reflect.TypeOf(i)
- if t == nil {
+// This is used to trim the sub-packages imported under the API.
+var thisPackagePath string
+func init() {
+ for range Only.Once {
+ val := reflect.ValueOf(Api{})
+ if val.Kind() == reflect.Ptr {
+ thisPackagePath = val.Elem().Type().PkgPath()
break
}
- new = reflect.New(t.Elem()).Interface()
+ thisPackagePath = strings.TrimSuffix(val.Type().PkgPath(), "api")
}
- return new
}
-func ToSnakeCase(s string) string {
- slen := len(s)
- b := []byte(s)
- pos := make([]int, 0)
- for i := 1; i < len(b); i++ {
- if b[i] >= 'A' && b[i] <= 'Z' {
- pos = append(pos, i)
- slen++
- }
- }
- if len(pos) > 0 {
- sc := make([]byte, slen)
- n := 0
- p := 0
- for i := 0; i < len(b); i++ {
- if pos[p] == i {
- sc[n] = '_'
- n++
- }
- sc[n] = b[i]
- n++
- }
- s = string(sc)
- }
- return strings.ToLower(s)
-}
func AppendUrl(host string, endpoint string) *url.URL {
var ret *url.URL
@@ -57,31 +33,88 @@ func AppendUrl(host string, endpoint string) *url.URL {
return ret
}
-func CreateEndPoints(list [][]string) TypeEndPoints {
- endpoints := make(TypeEndPoints, len(list))
+// func CreateEndPoints(list [][]string) TypeEndPoints {
+// endpoints := make(TypeEndPoints, len(list))
+//
+// for range Only.Once {
+// for _, e := range list {
+// if len(e) != 3 {
+// continue
+// }
+// area := AreaName(e[0])
+// name := EndPointName(e[1])
+// u, _ := url.Parse(e[2])
+//
+// // endpoints[name] = EndPointStruct {
+// // Area: area,
+// // Name: name,
+// // Url: u,
+// // Request: nil,
+// // Response: nil,
+// // // EndPoint: EndPoint(),
+// // }
+// fmt.Printf("EndPoint: %s\t%s\t%s\n", area, name, u)
+//
+// if name == "getPowerDevicePointNames" {
+// fmt.Println("HEYHEYHEY")
+// point := endpoints[name]
+// fmt.Printf("EndPoint: %s\t%s\t%s\n",
+// point.GetArea(),
+// point.GetName(),
+// point.GetUrl(),
+// )
+//
+// // point.SetResource(getPowerDevicePointNames.Init())
+// // fmt.Printf("EndPoint: %v\n", point.GetResource())
+// continue
+// }
+// }
+// }
+//
+// return endpoints
+// }
- for range Only.Once {
- for _, e := range list {
- if len(e) != 3 {
- continue
- }
- area := AreaName(e[0])
- name := EndPointName(e[1])
- u, _ := url.Parse(e[2])
+// func getType(myvar interface{}) string {
+// if t := reflect.TypeOf(myvar); t.Kind() == reflect.Ptr {
+// return "*" + t.Elem().Name()
+// } else {
+// return t.Name()
+// }
+// }
- endpoints[name] = TypeEndPoint {
- Area: area,
- Name: name,
- Url: u,
- Request: nil,
- Response: nil,
- // Resource: Resource(),
- }
- }
- }
-
- return endpoints
-}
+// func SetEndPointReference(endpoint string, ref interface{}) *EndPointStruct {
+// var endpoint EndPointStruct
+//
+// for range Only.Once {
+// for _, e := range list {
+// if len(e) != 3 {
+// continue
+// }
+// area := AreaName(e[0])
+// name := EndPointName(e[1])
+// u, _ := url.Parse(e[2])
+//
+// endpoint = EndPointStruct {
+// Area: area,
+// Name: name,
+// Url: u,
+// Request: nil,
+// Response: nil,
+// // EndPoint: EndPoint(),
+// }
+//
+// // if name == "getPowerDevicePointNames" {
+// // fmt.Println("HEYHEYHEY")
+// // point := endpoints[name]
+// // point.SetResource(getPowerDevicePointNames.Init())
+// // fmt.Printf("EndPoint: %v\n", point.GetResource())
+// // continue
+// // }
+// }
+// }
+//
+// return &endpoint
+// }
func PackageName(v interface{}) string {
var ret string
@@ -96,7 +129,13 @@ func PackageName(v interface{}) string {
break
}
+ ret2 := val.Type().Name()
+ ret3 := val.Type().String()
ret = val.Type().PkgPath()
+ ret = strings.TrimPrefix(ret, thisPackagePath)
+
+ fmt.Printf("%s\t%s\t%s\n", ret, ret2, ret3)
+ fmt.Println("")
}
return ret
}
@@ -104,23 +143,60 @@ func PackageName(v interface{}) string {
func GetArea(v interface{}) AreaName {
var ret AreaName
for range Only.Once {
- s := strings.Split(PackageName(v), "/")
- if len(s) < 2 {
+ if v == nil {
break
}
- ret = AreaName(s[len(s)-1])
+
+ val := reflect.ValueOf(v)
+ ret1 := val.Type().PkgPath()
+ ret2 := val.Type().Name()
+ ret3 := val.Type().String()
+ fmt.Printf("%s\t%s\t%s\n", ret1, ret2, ret3)
+
+ if strings.HasSuffix(ret3, "Area") {
+ ret = AreaName(strings.TrimSuffix(ret3, ".Area"))
+ break
+ }
+
+ if strings.HasSuffix(ret3, "EndPoint") {
+ s := strings.Split(ret1, "/")
+ ret = AreaName(s[len(s)-2])
+ break
+ }
+
+ ret = AreaName(strings.TrimPrefix(ret1, thisPackagePath))
+
+ fmt.Println("")
}
return ret
}
-func GetEndPoint(v interface{}) EndPointName {
+func GetName(v interface{}) EndPointName {
var ret EndPointName
for range Only.Once {
- s := strings.Split(PackageName(v), "/")
- if len(s) < 2 {
+ if v == nil {
break
}
- ret = EndPointName(s[len(s)-1])
+
+ val := reflect.ValueOf(v)
+ ret1 := val.Type().PkgPath()
+ ret2 := val.Type().Name()
+ ret3 := val.Type().String()
+ fmt.Printf("%s\t%s\t%s\n", ret1, ret2, ret3)
+
+ if strings.HasSuffix(ret3, "Area") {
+ ret = EndPointName(strings.TrimSuffix(ret3, ".Area"))
+ break
+ }
+
+ if strings.HasSuffix(ret3, "EndPoint") {
+ ret = EndPointName(strings.TrimSuffix(ret3, ".EndPoint"))
+ break
+ }
+
+ ret = EndPointName(strings.TrimPrefix(ret1, thisPackagePath))
+
+ fmt.Println("")
}
return ret
}
@@ -136,3 +212,55 @@ func GetUrl(u string) *url.URL {
}
return ret
}
+
+
+func GetAsJson(r interface{}) Json {
+ var ret Json
+ for range Only.Once {
+ j, err := json.Marshal(r)
+ if err != nil {
+ break
+ }
+ ret = Json(j)
+ }
+ return ret
+}
+
+
+// func MakeNewFrom(i interface{}) (new interface{}) {
+// for range OnlyOnce {
+// t := reflect.TypeOf(i)
+// if t == nil {
+// break
+// }
+// new = reflect.New(t.Elem()).Interface()
+// }
+// return new
+// }
+//
+// func ToSnakeCase(s string) string {
+// slen := len(s)
+// b := []byte(s)
+// pos := make([]int, 0)
+// for i := 1; i < len(b); i++ {
+// if b[i] >= 'A' && b[i] <= 'Z' {
+// pos = append(pos, i)
+// slen++
+// }
+// }
+// if len(pos) > 0 {
+// sc := make([]byte, slen)
+// n := 0
+// p := 0
+// for i := 0; i < len(b); i++ {
+// if pos[p] == i {
+// sc[n] = '_'
+// n++
+// }
+// sc[n] = b[i]
+// n++
+// }
+// s = string(sc)
+// }
+// return strings.ToLower(s)
+// }
diff --git a/iSolarCloud/api_init.go b/iSolarCloud/api_init.go
index 7e02c8b77..179481b34 100644
--- a/iSolarCloud/api_init.go
+++ b/iSolarCloud/api_init.go
@@ -1,20 +1,18 @@
package iSolarCloud
-import "GoSungro/iSolarCloud/api"
-
-func Initialize(contentHandlers api.ContentHandlers) {
- for _, ch := range contentHandlers {
- resourceHandler, ok := ch.(ResourceHandler)
- if !ok {
- continue
- }
- rt := NewResourceType(ch)
- rt = resourceHandler.InitializeResourceType(rt)
- resourceTypes[rt.GetSlug()] = rt
- }
-
-}
+// func Initialize(contentHandlers api.ContentHandlers) {
+// for _, ch := range contentHandlers {
+// resourceHandler, ok := ch.(ResourceHandler)
+// if !ok {
+// continue
+// }
+// rt := NewResourceType(ch)
+// rt = resourceHandler.InitializeResourceType(rt)
+// resourceTypes[rt.GetSlug()] = rt
+// }
+//
+// }
type CommonAttributes struct {
Appkey string `json:"appkey"`
diff --git a/iSolarCloud/api_resource_handler.go b/iSolarCloud/api_resource_handler.go
index 3689f93ee..0949ebd2c 100644
--- a/iSolarCloud/api_resource_handler.go
+++ b/iSolarCloud/api_resource_handler.go
@@ -1,6 +1,6 @@
package iSolarCloud
-type ResourceHandlers []ResourceHandler
-type ResourceHandler interface {
- InitializeResourceType(*ResourceType) *ResourceType
-}
+// type ResourceHandlers []ResourceHandler
+// type ResourceHandler interface {
+// InitializeResourceType(*ResourceType) *ResourceType
+// }
diff --git a/iSolarCloud/api_resource_type.go b/iSolarCloud/api_resource_type.go
index 9eff0c230..7f6857ad7 100644
--- a/iSolarCloud/api_resource_type.go
+++ b/iSolarCloud/api_resource_type.go
@@ -1,62 +1,56 @@
package iSolarCloud
-import (
- "GoSungro/Only"
- "GoSungro/iSolarCloud/api"
- "reflect"
- "strings"
-)
-
-
-var resourceTypes ResourceTypes
-
-func init() {
- resourceTypes = make(ResourceTypes, 0)
-}
-
-type ResourceTypeSlug string
-type ResourceTypes map[ResourceTypeSlug]*ResourceType
-
-func GetResourceTypes() ResourceTypes {
- return resourceTypes
-}
-
-type ResourceType struct {
- slug ResourceTypeSlug
- ResultData interface{}
- ReqSerialNum string `json:"req_serial_num"`
- ResultCode string `json:"result_code"`
- ResultMsg string `json:"result_msg"`
- //HasImages bool
- //HasGeoProfile bool
- //HasCountries bool
- //HasAudience bool
- //HasGenre bool
- //HasPlatforms bool
- //HasLinks bool
- //HasTopics bool
- //HasVideos bool
- //HasCaptions bool
- //HasAvailabilities bool
-}
-
-func NewResourceType(instanceType interface{}) *ResourceType {
- return &ResourceType{
- ResultData: instanceType,
- }
-}
-
-func (me *ResourceType) SetSlug(slug ResourceTypeSlug) {
- me.slug = slug
-}
-
-func (me *ResourceType) GetSlug() ResourceTypeSlug {
- for range Only.Once {
- if me.slug != "" {
- break
- }
- s := strings.Split(reflect.TypeOf(me.ResultData).String(), ".")[1]
- me.slug = ResourceTypeSlug(api.ToSnakeCase(s))
- }
- return me.slug
-}
\ No newline at end of file
+//
+//
+// var resourceTypes ResourceTypes
+//
+// func init() {
+// resourceTypes = make(ResourceTypes, 0)
+// }
+//
+// type ResourceTypeSlug string
+// type ResourceTypes map[ResourceTypeSlug]*ResourceType
+//
+// func GetResourceTypes() ResourceTypes {
+// return resourceTypes
+// }
+//
+// type ResourceType struct {
+// slug ResourceTypeSlug
+// ResultData interface{}
+// ReqSerialNum string `json:"req_serial_num"`
+// ResultCode string `json:"result_code"`
+// ResultMsg string `json:"result_msg"`
+// //HasImages bool
+// //HasGeoProfile bool
+// //HasCountries bool
+// //HasAudience bool
+// //HasGenre bool
+// //HasPlatforms bool
+// //HasLinks bool
+// //HasTopics bool
+// //HasVideos bool
+// //HasCaptions bool
+// //HasAvailabilities bool
+// }
+//
+// func NewResourceType(instanceType interface{}) *ResourceType {
+// return &ResourceType{
+// ResultData: instanceType,
+// }
+// }
+//
+// func (me *ResourceType) SetSlug(slug ResourceTypeSlug) {
+// me.slug = slug
+// }
+//
+// func (me *ResourceType) GetSlug() ResourceTypeSlug {
+// for range Only.Once {
+// if me.slug != "" {
+// break
+// }
+// s := strings.Split(reflect.TypeOf(me.ResultData).String(), ".")[1]
+// me.slug = ResourceTypeSlug(api.ToSnakeCase(s))
+// }
+// return me.slug
+// }
\ No newline at end of file
diff --git a/iSolarCloud/content_types.go b/iSolarCloud/content_types.go
index 8e230e38d..bd94ca0d8 100644
--- a/iSolarCloud/content_types.go
+++ b/iSolarCloud/content_types.go
@@ -1,8 +1,6 @@
package iSolarCloud
-import "GoSungro/iSolarCloud/api"
-
-var ContentTypes = api.ContentHandlers {
- LoginType,
- SomethingType,
-}
+// var ContentTypes = api.ContentHandlers {
+// LoginType,
+// SomethingType,
+// }
diff --git a/iSolarCloud/login.go b/iSolarCloud/login.go
index 5ec09c1a2..3599471c1 100644
--- a/iSolarCloud/login.go
+++ b/iSolarCloud/login.go
@@ -1,157 +1,153 @@
package iSolarCloud
-import (
- "GoSungro/iSolarCloud/api"
-)
-
-var LoginType = (*Login)(nil)
-
-var _ ResourceHandler = LoginType
-var _ api.ContentHandler = LoginType
-
-type Login struct {
- //GuidsAndLinks
- Attributes LoginAttributes
- ResourceType
- api.ContentType
-}
-
-func (*Login) InitializeResourceType(rt *ResourceType) *ResourceType {
- //rt.HasVideos = true
- //rt.HasCaptions = true
- //rt.HasCountries = true
- //rt.HasGeoProfile = true
- //rt.HasTopics = true
- //rt.HasPlatforms = true
- //rt.HasImages = true
- //rt.HasAvailabilities = true
- //rt.HasLinks = true
- return rt
-}
-
-func (*Login) InitializeContentType(ct *api.ContentType) *api.ContentType {
- ct.DownloadPriority = 6
- ct.ResourceType = (*LoginResource)(nil)
- ct.CollectionType = (*LoginCollection)(nil)
- return ct
-}
-
-type LoginAttributes struct {
- CommonAttributes
- ResultData struct {
- AcceptOrderNum int64 `json:"accept_order_num"`
- BackgroundColor int64 `json:"background_color"`
- Countryid string `json:"countryid"`
- Createdate string `json:"createdate"`
- Createuserid string `json:"createuserid"`
- CurrentOrderNum int64 `json:"current_order_num"`
- DisableTime string `json:"disable_time"`
- Email string `json:"email"`
- Englishname interface{} `json:"englishname"`
- ErrTimes string `json:"err_times"`
- GcjLatitude interface{} `json:"gcj_latitude"`
- GcjLongitude interface{} `json:"gcj_longitude"`
- ImToken interface{} `json:"im_token"`
- IsAfsFlag string `json:"is_afs_flag"`
- IsAgreeGdpr int64 `json:"is_agree_gdpr"`
- IsAu int64 `json:"is_au"`
- IsCanModifyUserAccount int64 `json:"is_can_modify_user_account"`
- IsDisableMap string `json:"is_disable_map"`
- IsGdpr int64 `json:"is_gdpr"`
- IsHaveIm int64 `json:"is_have_im"`
- IsNewVersion int64 `json:"is_new_version"`
- IsOnline string `json:"is_online"`
- IsOpenProtocol int64 `json:"is_open_protocol"`
- IsReceiveNotice int64 `json:"is_receive_notice"`
- IsSharePosition int64 `json:"is_share_position"`
- IsUploadLocation int64 `json:"is_upload_location"`
- IsUseSungrowBrand string `json:"is_use_sungrow_brand"`
- IsValidMobileEmail int64 `json:"is_valid_mobile_email"`
- Isdst string `json:"isdst"` // DUPLICATE
- IsDST string `json:"isDST"` // DUPLICATE
- Jobs interface{} `json:"jobs"`
- Language string `json:"language"`
- LoginFirstDate string `json:"loginFirstDate"` // DUPLICATE
- LoginFristDate string `json:"loginFristDate"` // DUPLICATE
- LoginLastDate string `json:"loginLastDate"`
- LoginLastIP string `json:"loginLastIp"`
- LoginTimes int64 `json:"loginTimes"`
- LoginState string `json:"login_state"`
- Logo interface{} `json:"logo"`
- LogoHTTPSURL interface{} `json:"logo_https_url"`
- MapType string `json:"map_type"`
- MinDate string `json:"min_date"`
- MobileTel interface{} `json:"mobile_tel"`
- OrgID string `json:"org_id"`
- OrgName string `json:"org_name"`
- OrgTimezone string `json:"org_timezone"`
- PasswordIsSimple int64 `json:"password_is_simple"`
- PhotoID interface{} `json:"photo_id"`
- PhotoURL interface{} `json:"photo_url"`
- Privileges LoginPrivileges `json:"privileges"`
- RoleID string `json:"role_id"`
- SecondaryOrgIds []interface{} `json:"secondaryOrgIds"`
- ServerTel string `json:"server_tel"`
- ServiceVersion string `json:"service_version"`
- Sex string `json:"sex"`
- StyleName string `json:"stylename"`
- TimeZone string `json:"timeZone"`
- Timezone string `json:"timezone"`
- TimeZoneId string `json:"timezoneid"`
- ToggleFlag string `json:"toggleflag"`
- Token string `json:"token"`
- UnlockLaveMinute int64 `json:"unlock_lave_minute"`
- UploadTime interface{} `json:"upload_time"`
- UserAccount string `json:"user_account"`
- UserAccountModifyCount int64 `json:"user_account_modify_count"`
- UserAccountModifyRemainTimes int64 `json:"user_account_modify_remain_times"`
- UserDealerOrgCode interface{} `json:"user_dealer_org_code"`
- UserID string `json:"user_id"`
- UserLevel string `json:"user_level"`
- UserMasterOrgID string `json:"user_master_org_id"`
- UserMasterOrgName string `json:"user_master_org_name"`
- UserMasterOrgTimeZoneID string `json:"user_master_org_time_zone_id"`
- UserMasterOrgTimeZoneName string `json:"user_master_org_time_zone_name"`
- UserName string `json:"user_name"`
- UserRoleIDList []string `json:"user_role_id_list"`
- UserTelNationCode interface{} `json:"user_tel_nation_code"`
- UserAuthorURL []interface{} `json:"userauthorURL"`
- UserAuthorButto []string `json:"userauthorbutto"`
- UserDescription interface{} `json:"userdesc"`
- UsePassword string `json:"userpassword"`
- ValidFlag string `json:"validflag"`
- Voice string `json:"voice"`
- WelcomeText string `json:"welcometext"`
- Wgs84Latitude interface{} `json:"wgs84_latitude"`
- Wgs84Longitude interface{} `json:"wgs84_longitude"`
- WorkTel interface{} `json:"work_tel"`
- } `json:"result_data"`
-}
-
-type LoginPrivileges []struct {
- FatherID int64 `json:"father_id"`
- IconURL interface{} `json:"icon_url"`
- IsOpen interface{} `json:"is_open"`
- IsThirdPlatform int64 `json:"is_third_platform"`
- MenuCode string `json:"menu_code"`
- MenuLevel int64 `json:"menu_level"`
- MenuName string `json:"menu_name"`
- MenuOrder interface{} `json:"menu_order"`
- MenuType string `json:"menu_type"`
- MenuURL string `json:"menu_url"`
- PrivilegeID int64 `json:"privilege_id"`
- RoleID int64 `json:"role_id"`
- URLTarget string `json:"url_target"`
- VueIcon interface{} `json:"vue_icon"`
- VuePath interface{} `json:"vue_path"`
-}
-
-
-type LoginResource struct {
- Data Login
-}
-
-type LoginCollection struct {
- Data []Login
-}
+// var LoginType = (*Login)(nil)
+//
+// var _ ResourceHandler = LoginType
+// // var _ api.ContentHandler = LoginType
+//
+// type Login struct {
+// //GuidsAndLinks
+// Attributes LoginAttributes
+// ResourceType
+// // api.ContentType
+// }
+//
+// func (*Login) InitializeResourceType(rt *ResourceType) *ResourceType {
+// //rt.HasVideos = true
+// //rt.HasCaptions = true
+// //rt.HasCountries = true
+// //rt.HasGeoProfile = true
+// //rt.HasTopics = true
+// //rt.HasPlatforms = true
+// //rt.HasImages = true
+// //rt.HasAvailabilities = true
+// //rt.HasLinks = true
+// return rt
+// }
+//
+// func (*Login) InitializeContentType(ct *api.ContentType) *api.ContentType {
+// ct.DownloadPriority = 6
+// ct.ResourceType = (*LoginResource)(nil)
+// ct.CollectionType = (*LoginCollection)(nil)
+// return ct
+// }
+//
+// type LoginAttributes struct {
+// CommonAttributes
+// ResultData struct {
+// AcceptOrderNum int64 `json:"accept_order_num"`
+// BackgroundColor int64 `json:"background_color"`
+// Countryid string `json:"countryid"`
+// Createdate string `json:"createdate"`
+// Createuserid string `json:"createuserid"`
+// CurrentOrderNum int64 `json:"current_order_num"`
+// DisableTime string `json:"disable_time"`
+// Email string `json:"email"`
+// Englishname interface{} `json:"englishname"`
+// ErrTimes string `json:"err_times"`
+// GcjLatitude interface{} `json:"gcj_latitude"`
+// GcjLongitude interface{} `json:"gcj_longitude"`
+// ImToken interface{} `json:"im_token"`
+// IsAfsFlag string `json:"is_afs_flag"`
+// IsAgreeGdpr int64 `json:"is_agree_gdpr"`
+// IsAu int64 `json:"is_au"`
+// IsCanModifyUserAccount int64 `json:"is_can_modify_user_account"`
+// IsDisableMap string `json:"is_disable_map"`
+// IsGdpr int64 `json:"is_gdpr"`
+// IsHaveIm int64 `json:"is_have_im"`
+// IsNewVersion int64 `json:"is_new_version"`
+// IsOnline string `json:"is_online"`
+// IsOpenProtocol int64 `json:"is_open_protocol"`
+// IsReceiveNotice int64 `json:"is_receive_notice"`
+// IsSharePosition int64 `json:"is_share_position"`
+// IsUploadLocation int64 `json:"is_upload_location"`
+// IsUseSungrowBrand string `json:"is_use_sungrow_brand"`
+// IsValidMobileEmail int64 `json:"is_valid_mobile_email"`
+// Isdst string `json:"isdst"` // DUPLICATE
+// IsDST string `json:"isDST"` // DUPLICATE
+// Jobs interface{} `json:"jobs"`
+// Language string `json:"language"`
+// LoginFirstDate string `json:"loginFirstDate"` // DUPLICATE
+// LoginFristDate string `json:"loginFristDate"` // DUPLICATE
+// LoginLastDate string `json:"loginLastDate"`
+// LoginLastIP string `json:"loginLastIp"`
+// LoginTimes int64 `json:"loginTimes"`
+// LoginState string `json:"login_state"`
+// Logo interface{} `json:"logo"`
+// LogoHTTPSURL interface{} `json:"logo_https_url"`
+// MapType string `json:"map_type"`
+// MinDate string `json:"min_date"`
+// MobileTel interface{} `json:"mobile_tel"`
+// OrgID string `json:"org_id"`
+// OrgName string `json:"org_name"`
+// OrgTimezone string `json:"org_timezone"`
+// PasswordIsSimple int64 `json:"password_is_simple"`
+// PhotoID interface{} `json:"photo_id"`
+// PhotoURL interface{} `json:"photo_url"`
+// Privileges LoginPrivileges `json:"privileges"`
+// RoleID string `json:"role_id"`
+// SecondaryOrgIds []interface{} `json:"secondaryOrgIds"`
+// ServerTel string `json:"server_tel"`
+// ServiceVersion string `json:"service_version"`
+// Sex string `json:"sex"`
+// StyleName string `json:"stylename"`
+// TimeZone string `json:"timeZone"`
+// Timezone string `json:"timezone"`
+// TimeZoneId string `json:"timezoneid"`
+// ToggleFlag string `json:"toggleflag"`
+// Token string `json:"token"`
+// UnlockLaveMinute int64 `json:"unlock_lave_minute"`
+// UploadTime interface{} `json:"upload_time"`
+// UserAccount string `json:"user_account"`
+// UserAccountModifyCount int64 `json:"user_account_modify_count"`
+// UserAccountModifyRemainTimes int64 `json:"user_account_modify_remain_times"`
+// UserDealerOrgCode interface{} `json:"user_dealer_org_code"`
+// UserID string `json:"user_id"`
+// UserLevel string `json:"user_level"`
+// UserMasterOrgID string `json:"user_master_org_id"`
+// UserMasterOrgName string `json:"user_master_org_name"`
+// UserMasterOrgTimeZoneID string `json:"user_master_org_time_zone_id"`
+// UserMasterOrgTimeZoneName string `json:"user_master_org_time_zone_name"`
+// UserName string `json:"user_name"`
+// UserRoleIDList []string `json:"user_role_id_list"`
+// UserTelNationCode interface{} `json:"user_tel_nation_code"`
+// UserAuthorURL []interface{} `json:"userauthorURL"`
+// UserAuthorButto []string `json:"userauthorbutto"`
+// UserDescription interface{} `json:"userdesc"`
+// UsePassword string `json:"userpassword"`
+// ValidFlag string `json:"validflag"`
+// Voice string `json:"voice"`
+// WelcomeText string `json:"welcometext"`
+// Wgs84Latitude interface{} `json:"wgs84_latitude"`
+// Wgs84Longitude interface{} `json:"wgs84_longitude"`
+// WorkTel interface{} `json:"work_tel"`
+// } `json:"result_data"`
+// }
+//
+// type LoginPrivileges []struct {
+// FatherID int64 `json:"father_id"`
+// IconURL interface{} `json:"icon_url"`
+// IsOpen interface{} `json:"is_open"`
+// IsThirdPlatform int64 `json:"is_third_platform"`
+// MenuCode string `json:"menu_code"`
+// MenuLevel int64 `json:"menu_level"`
+// MenuName string `json:"menu_name"`
+// MenuOrder interface{} `json:"menu_order"`
+// MenuType string `json:"menu_type"`
+// MenuURL string `json:"menu_url"`
+// PrivilegeID int64 `json:"privilege_id"`
+// RoleID int64 `json:"role_id"`
+// URLTarget string `json:"url_target"`
+// VueIcon interface{} `json:"vue_icon"`
+// VuePath interface{} `json:"vue_path"`
+// }
+//
+//
+// type LoginResource struct {
+// Data Login
+// }
+//
+// type LoginCollection struct {
+// Data []Login
+// }
diff --git a/iSolarCloud/pkgreflect.go b/iSolarCloud/pkgreflect.go
index d38d78f98..58e845022 100644
--- a/iSolarCloud/pkgreflect.go
+++ b/iSolarCloud/pkgreflect.go
@@ -1,51 +1,3 @@
// Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
package iSolarCloud
-
-import "reflect"
-
-var Types = map[string]reflect.Type{
- "Areas": reflect.TypeOf((*Areas)(nil)).Elem(),
- "CommonAttributes": reflect.TypeOf((*CommonAttributes)(nil)).Elem(),
- "Login": reflect.TypeOf((*Login)(nil)).Elem(),
- "LoginAttributes": reflect.TypeOf((*LoginAttributes)(nil)).Elem(),
- "LoginCollection": reflect.TypeOf((*LoginCollection)(nil)).Elem(),
- "LoginPrivileges": reflect.TypeOf((*LoginPrivileges)(nil)).Elem(),
- "LoginResource": reflect.TypeOf((*LoginResource)(nil)).Elem(),
- "OutputType": reflect.TypeOf((*OutputType)(nil)).Elem(),
- "ResourceHandler": reflect.TypeOf((*ResourceHandler)(nil)).Elem(),
- "ResourceHandlers": reflect.TypeOf((*ResourceHandlers)(nil)).Elem(),
- "ResourceType": reflect.TypeOf((*ResourceType)(nil)).Elem(),
- "ResourceTypeSlug": reflect.TypeOf((*ResourceTypeSlug)(nil)).Elem(),
- "ResourceTypes": reflect.TypeOf((*ResourceTypes)(nil)).Elem(),
- "Something": reflect.TypeOf((*Something)(nil)).Elem(),
- "SomethingAttributes": reflect.TypeOf((*SomethingAttributes)(nil)).Elem(),
- "SomethingCollection": reflect.TypeOf((*SomethingCollection)(nil)).Elem(),
- "SomethingResource": reflect.TypeOf((*SomethingResource)(nil)).Elem(),
- "SunGro": reflect.TypeOf((*SunGro)(nil)).Elem(),
-}
-
-var Functions = map[string]reflect.Value{
- "GetResourceTypes": reflect.ValueOf(GetResourceTypes),
- "Initialize": reflect.ValueOf(Initialize),
- "NewResourceType": reflect.ValueOf(NewResourceType),
- "NewSunGro": reflect.ValueOf(NewSunGro),
-}
-
-var Variables = map[string]reflect.Value{
- "ContentTypes": reflect.ValueOf(&ContentTypes),
- "LoginType": reflect.ValueOf(&LoginType),
- "SomethingType": reflect.ValueOf(&SomethingType),
-}
-
-var Consts = map[string]reflect.Value{
- "StringTypeGit": reflect.ValueOf(StringTypeGit),
- "StringTypeGoogle": reflect.ValueOf(StringTypeGoogle),
- "StringTypeHuman": reflect.ValueOf(StringTypeHuman),
- "StringTypeJson": reflect.ValueOf(StringTypeJson),
- "TypeGit": reflect.ValueOf(TypeGit),
- "TypeGoogle": reflect.ValueOf(TypeGoogle),
- "TypeHuman": reflect.ValueOf(TypeHuman),
- "TypeJson": reflect.ValueOf(TypeJson),
-}
-
diff --git a/iSolarCloud/something.go b/iSolarCloud/something.go
index fad256e19..7559970fc 100644
--- a/iSolarCloud/something.go
+++ b/iSolarCloud/something.go
@@ -1,138 +1,135 @@
package iSolarCloud
-import (
- "GoSungro/iSolarCloud/api"
-)
-
-
-var SomethingType = (*Something)(nil)
-
-var _ ResourceHandler = SomethingType
-var _ api.ContentHandler = SomethingType
-
-type Something struct {
- //GuidsAndLinks
- Attributes SomethingAttributes
- ResourceType
- api.ContentType
-}
-
-func (*Something) InitializeResourceType(rt *ResourceType) *ResourceType {
- //rt.HasVideos = true
- //rt.HasCaptions = true
- //rt.HasCountries = true
- //rt.HasGeoProfile = true
- //rt.HasTopics = true
- //rt.HasPlatforms = true
- //rt.HasImages = true
- //rt.HasAvailabilities = true
- //rt.HasLinks = true
- return rt
-}
-
-func (*Something) InitializeContentType(ct *api.ContentType) *api.ContentType {
- ct.DownloadPriority = 6
- ct.ResourceType = (*SomethingResource)(nil)
- ct.CollectionType = (*SomethingCollection)(nil)
- return ct
-}
-
-type SomethingAttributes struct {
- CommonAttributes
- ResultData struct {
- AcceptOrderNum int64 `json:"accept_order_num"`
- BackgroundColor int64 `json:"background_color"`
- Countryid string `json:"countryid"`
- Createdate string `json:"createdate"`
- Createuserid string `json:"createuserid"`
- CurrentOrderNum int64 `json:"current_order_num"`
- DisableTime string `json:"disable_time"`
- Email string `json:"email"`
- Englishname interface{} `json:"englishname"`
- ErrTimes string `json:"err_times"`
- GcjLatitude interface{} `json:"gcj_latitude"`
- GcjLongitude interface{} `json:"gcj_longitude"`
- ImToken interface{} `json:"im_token"`
- IsAfsFlag string `json:"is_afs_flag"`
- IsAgreeGdpr int64 `json:"is_agree_gdpr"`
- IsAu int64 `json:"is_au"`
- IsCanModifyUserAccount int64 `json:"is_can_modify_user_account"`
- IsDisableMap string `json:"is_disable_map"`
- IsGdpr int64 `json:"is_gdpr"`
- IsHaveIm int64 `json:"is_have_im"`
- IsNewVersion int64 `json:"is_new_version"`
- IsOnline string `json:"is_online"`
- IsOpenProtocol int64 `json:"is_open_protocol"`
- IsReceiveNotice int64 `json:"is_receive_notice"`
- IsSharePosition int64 `json:"is_share_position"`
- IsUploadLocation int64 `json:"is_upload_location"`
- IsUseSungrowBrand string `json:"is_use_sungrow_brand"`
- IsValidMobileEmail int64 `json:"is_valid_mobile_email"`
- Isdst string `json:"isdst"` // DUPLICATE
- IsDST string `json:"isDST"` // DUPLICATE
- Jobs interface{} `json:"jobs"`
- Language string `json:"language"`
- SomethingFirstDate string `json:"SomethingFirstDate"` // DUPLICATE
- SomethingFristDate string `json:"SomethingFristDate"` // DUPLICATE
- SomethingLastDate string `json:"SomethingLastDate"`
- SomethingLastIP string `json:"SomethingLastIp"`
- SomethingTimes int64 `json:"SomethingTimes"`
- SomethingState string `json:"Something_state"`
- Logo interface{} `json:"logo"`
- LogoHTTPSURL interface{} `json:"logo_https_url"`
- MapType string `json:"map_type"`
- MinDate string `json:"min_date"`
- MobileTel interface{} `json:"mobile_tel"`
- OrgID string `json:"org_id"`
- OrgName string `json:"org_name"`
- OrgTimezone string `json:"org_timezone"`
- PasswordIsSimple int64 `json:"password_is_simple"`
- PhotoID interface{} `json:"photo_id"`
- PhotoURL interface{} `json:"photo_url"`
- RoleID string `json:"role_id"`
- SecondaryOrgIds []interface{} `json:"secondaryOrgIds"`
- ServerTel string `json:"server_tel"`
- ServiceVersion string `json:"service_version"`
- Sex string `json:"sex"`
- StyleName string `json:"stylename"`
- TimeZone string `json:"timeZone"`
- Timezone string `json:"timezone"`
- TimeZoneId string `json:"timezoneid"`
- ToggleFlag string `json:"toggleflag"`
- Token string `json:"token"`
- UnlockLaveMinute int64 `json:"unlock_lave_minute"`
- UploadTime interface{} `json:"upload_time"`
- UserAccount string `json:"user_account"`
- UserAccountModifyCount int64 `json:"user_account_modify_count"`
- UserAccountModifyRemainTimes int64 `json:"user_account_modify_remain_times"`
- UserDealerOrgCode interface{} `json:"user_dealer_org_code"`
- UserID string `json:"user_id"`
- UserLevel string `json:"user_level"`
- UserMasterOrgID string `json:"user_master_org_id"`
- UserMasterOrgName string `json:"user_master_org_name"`
- UserMasterOrgTimeZoneID string `json:"user_master_org_time_zone_id"`
- UserMasterOrgTimeZoneName string `json:"user_master_org_time_zone_name"`
- UserName string `json:"user_name"`
- UserRoleIDList []string `json:"user_role_id_list"`
- UserTelNationCode interface{} `json:"user_tel_nation_code"`
- UserAuthorURL []interface{} `json:"userauthorURL"`
- UserAuthorButto []string `json:"userauthorbutto"`
- UserDescription interface{} `json:"userdesc"`
- UsePassword string `json:"userpassword"`
- ValidFlag string `json:"validflag"`
- Voice string `json:"voice"`
- WelcomeText string `json:"welcometext"`
- Wgs84Latitude interface{} `json:"wgs84_latitude"`
- Wgs84Longitude interface{} `json:"wgs84_longitude"`
- WorkTel interface{} `json:"work_tel"`
- } `json:"result_data"`
-}
-
-
-type SomethingResource struct {
- Data Something
-}
-
-type SomethingCollection struct {
- Data []Something
-}
+//
+//
+// var SomethingType = (*Something)(nil)
+//
+// var _ ResourceHandler = SomethingType
+// var _ api.ContentHandler = SomethingType
+//
+// type Something struct {
+// //GuidsAndLinks
+// Attributes SomethingAttributes
+// ResourceType
+// api.ContentType
+// }
+//
+// func (*Something) InitializeResourceType(rt *ResourceType) *ResourceType {
+// //rt.HasVideos = true
+// //rt.HasCaptions = true
+// //rt.HasCountries = true
+// //rt.HasGeoProfile = true
+// //rt.HasTopics = true
+// //rt.HasPlatforms = true
+// //rt.HasImages = true
+// //rt.HasAvailabilities = true
+// //rt.HasLinks = true
+// return rt
+// }
+//
+// func (*Something) InitializeContentType(ct *api.ContentType) *api.ContentType {
+// ct.DownloadPriority = 6
+// ct.ResourceType = (*SomethingResource)(nil)
+// ct.CollectionType = (*SomethingCollection)(nil)
+// return ct
+// }
+//
+// type SomethingAttributes struct {
+// CommonAttributes
+// ResultData struct {
+// AcceptOrderNum int64 `json:"accept_order_num"`
+// BackgroundColor int64 `json:"background_color"`
+// Countryid string `json:"countryid"`
+// Createdate string `json:"createdate"`
+// Createuserid string `json:"createuserid"`
+// CurrentOrderNum int64 `json:"current_order_num"`
+// DisableTime string `json:"disable_time"`
+// Email string `json:"email"`
+// Englishname interface{} `json:"englishname"`
+// ErrTimes string `json:"err_times"`
+// GcjLatitude interface{} `json:"gcj_latitude"`
+// GcjLongitude interface{} `json:"gcj_longitude"`
+// ImToken interface{} `json:"im_token"`
+// IsAfsFlag string `json:"is_afs_flag"`
+// IsAgreeGdpr int64 `json:"is_agree_gdpr"`
+// IsAu int64 `json:"is_au"`
+// IsCanModifyUserAccount int64 `json:"is_can_modify_user_account"`
+// IsDisableMap string `json:"is_disable_map"`
+// IsGdpr int64 `json:"is_gdpr"`
+// IsHaveIm int64 `json:"is_have_im"`
+// IsNewVersion int64 `json:"is_new_version"`
+// IsOnline string `json:"is_online"`
+// IsOpenProtocol int64 `json:"is_open_protocol"`
+// IsReceiveNotice int64 `json:"is_receive_notice"`
+// IsSharePosition int64 `json:"is_share_position"`
+// IsUploadLocation int64 `json:"is_upload_location"`
+// IsUseSungrowBrand string `json:"is_use_sungrow_brand"`
+// IsValidMobileEmail int64 `json:"is_valid_mobile_email"`
+// Isdst string `json:"isdst"` // DUPLICATE
+// IsDST string `json:"isDST"` // DUPLICATE
+// Jobs interface{} `json:"jobs"`
+// Language string `json:"language"`
+// SomethingFirstDate string `json:"SomethingFirstDate"` // DUPLICATE
+// SomethingFristDate string `json:"SomethingFristDate"` // DUPLICATE
+// SomethingLastDate string `json:"SomethingLastDate"`
+// SomethingLastIP string `json:"SomethingLastIp"`
+// SomethingTimes int64 `json:"SomethingTimes"`
+// SomethingState string `json:"Something_state"`
+// Logo interface{} `json:"logo"`
+// LogoHTTPSURL interface{} `json:"logo_https_url"`
+// MapType string `json:"map_type"`
+// MinDate string `json:"min_date"`
+// MobileTel interface{} `json:"mobile_tel"`
+// OrgID string `json:"org_id"`
+// OrgName string `json:"org_name"`
+// OrgTimezone string `json:"org_timezone"`
+// PasswordIsSimple int64 `json:"password_is_simple"`
+// PhotoID interface{} `json:"photo_id"`
+// PhotoURL interface{} `json:"photo_url"`
+// RoleID string `json:"role_id"`
+// SecondaryOrgIds []interface{} `json:"secondaryOrgIds"`
+// ServerTel string `json:"server_tel"`
+// ServiceVersion string `json:"service_version"`
+// Sex string `json:"sex"`
+// StyleName string `json:"stylename"`
+// TimeZone string `json:"timeZone"`
+// Timezone string `json:"timezone"`
+// TimeZoneId string `json:"timezoneid"`
+// ToggleFlag string `json:"toggleflag"`
+// Token string `json:"token"`
+// UnlockLaveMinute int64 `json:"unlock_lave_minute"`
+// UploadTime interface{} `json:"upload_time"`
+// UserAccount string `json:"user_account"`
+// UserAccountModifyCount int64 `json:"user_account_modify_count"`
+// UserAccountModifyRemainTimes int64 `json:"user_account_modify_remain_times"`
+// UserDealerOrgCode interface{} `json:"user_dealer_org_code"`
+// UserID string `json:"user_id"`
+// UserLevel string `json:"user_level"`
+// UserMasterOrgID string `json:"user_master_org_id"`
+// UserMasterOrgName string `json:"user_master_org_name"`
+// UserMasterOrgTimeZoneID string `json:"user_master_org_time_zone_id"`
+// UserMasterOrgTimeZoneName string `json:"user_master_org_time_zone_name"`
+// UserName string `json:"user_name"`
+// UserRoleIDList []string `json:"user_role_id_list"`
+// UserTelNationCode interface{} `json:"user_tel_nation_code"`
+// UserAuthorURL []interface{} `json:"userauthorURL"`
+// UserAuthorButto []string `json:"userauthorbutto"`
+// UserDescription interface{} `json:"userdesc"`
+// UsePassword string `json:"userpassword"`
+// ValidFlag string `json:"validflag"`
+// Voice string `json:"voice"`
+// WelcomeText string `json:"welcometext"`
+// Wgs84Latitude interface{} `json:"wgs84_latitude"`
+// Wgs84Longitude interface{} `json:"wgs84_longitude"`
+// WorkTel interface{} `json:"work_tel"`
+// } `json:"result_data"`
+// }
+//
+//
+// type SomethingResource struct {
+// Data Something
+// }
+//
+// type SomethingCollection struct {
+// Data []Something
+// }
diff --git a/iSolarCloud/struct.go b/iSolarCloud/struct.go
index e6e44f1b8..31d2cbbcd 100644
--- a/iSolarCloud/struct.go
+++ b/iSolarCloud/struct.go
@@ -1,26 +1,12 @@
package iSolarCloud
-import (
- "GoSungro/iSolarCloud/api"
- "GoSungro/iSolarCloud/domain"
- "GoSungro/iSolarCloud/web"
-)
+import "GoSungro/iSolarCloud/sungro"
+var SunGro sungro.SunGro
-type SunGro struct {
- Web web.Web
- Error error
- Areas Areas
- AreaNames api.TypeAreaNames
- // EndPoints api.TypeEndPoints
- OutputString string
- OutputArray [][]interface{}
- OutputType
-}
-
-type Areas struct {
- domain.Domain
-}
+// type Areas struct {
+// domain.Domain
+// }
const (
TypeGit = iota
@@ -35,94 +21,6 @@ const (
)
-func NewSunGro(url string) *SunGro {
- var p SunGro
-
- p.Error = p.Web.SetUrl(url)
- p.OutputType = TypeHuman
-
- p.Areas.Domain.Web = &p.Web
-
- return &p
-}
-
-func (p *SunGro) SetAuth(auth web.SunGroAuth) error {
- return p.Web.Login(&auth)
-}
-
-func (p *SunGro) SetOutput(outType string) error {
-
- switch {
- case p.IsStrGit(outType):
- p.OutputType = TypeGit
- case p.IsStrJson(outType):
- p.OutputType = TypeJson
- case p.IsStrHuman(outType):
- p.OutputType = TypeHuman
- }
-
- return p.Error
-}
-
-func (p *SunGro) SetOutputString(f string) {
- p.OutputString = f
-}
-
-func (p *SunGro) GetToken() string {
- return p.Web.GetToken()
-}
-
-func (p *SunGro) GetTokenExpiry() string {
- return p.Web.GetTokenExpiry().Format(web.DateTimeFormat)
-}
-
-func (p *SunGro) GetDomain() string {
- return p.Web.GetDomain()
-}
-func (p *SunGro) VerifyDomain(domain string) string {
- return p.Web.VerifyDomain(domain)
-}
-
-func (p *SunGro) GetUser() string {
- return p.Web.GetUser()
-}
-func (p *SunGro) VerifyUser(user string) string {
- return p.Web.VerifyUser(user)
-}
-
-func (p *SunGro) GetUserMac() string {
- return p.Web.GetUser()
-}
-func (p *SunGro) VerifyUserMac(user string) string {
- return p.Web.VerifyUser(user)
-}
-
-func (p *SunGro) GetUsername() string {
- return p.Web.GetUsername()
-}
-func (p *SunGro) VerifyUsername(user string) string {
- return p.Web.VerifyUsername(user)
-}
-
-func (p *SunGro) GetUserEmail() string {
- return p.Web.GetUserEmail()
-}
-func (p *SunGro) VerifyUserEmail(user string) string {
- return p.Web.VerifyUserEmail(user)
-}
-
-func (p *SunGro) GetDisplayName() string {
- return p.Web.GetDisplayName()
-}
-func (p *SunGro) VerifyDisplayName(user string) string {
- return p.Web.VerifyDisplayName(user)
-}
-
-
-func (p *SunGro) HasTokenChanged() bool {
- return p.Web.HasTokenChanged()
-}
-
type OutputType int
func (out *OutputType) IsGit() bool {
diff --git a/iSolarCloud/sungro.go b/iSolarCloud/sungro.go
deleted file mode 100644
index 998adfd6e..000000000
--- a/iSolarCloud/sungro.go
+++ /dev/null
@@ -1,202 +0,0 @@
-package iSolarCloud
-
-import (
- "GoSungro/Only"
- "GoSungro/iSolarCloud/AliSmsService"
- "GoSungro/iSolarCloud/AppService"
- "GoSungro/iSolarCloud/MttvScreenService"
- "GoSungro/iSolarCloud/PowerPointService"
- "GoSungro/iSolarCloud/WebAppService"
- "GoSungro/iSolarCloud/WebIscmAppService"
- "GoSungro/iSolarCloud/api"
- "errors"
- "fmt"
- "github.com/olekukonko/tablewriter"
- "net/url"
- "os"
-)
-
-
-//var AreaNames TypeAreaNames
-//var EndPoints TypeEndPoints
-func (p *SunGro) Init() error {
- for range Only.Once {
- p.AreaNames = make(api.TypeAreaNames)
- // p.EndPoints = make(api.TypeEndPoints)
-
- p.AreaNames[AliSmsService.Area.Name] = AliSmsService.Area.EndPoints
- p.AreaNames[AppService.Area.Name] = AppService.Area.EndPoints
- p.AreaNames[MttvScreenService.Area.Name] = MttvScreenService.Area.EndPoints
- p.AreaNames[PowerPointService.Area.Name] = PowerPointService.Area.EndPoints
- p.AreaNames[WebAppService.Area.Name] = WebAppService.Area.EndPoints
- p.AreaNames[WebIscmAppService.Area.Name] = WebIscmAppService.Area.EndPoints
-
- // foo := p.AreaNames[AppService.Area.Name]
- // fmt.Printf("[%s] => %v", AppService.Area.Name, foo.SortEndPoints())
-
- // for _, e := range api.SunGro {
- // if len(e) != 3 {
- // continue
- // }
- // area := api.AreaName(e[0])
- // name := api.EndPointName(e[1])
- // u := p.AppendUrl(e[2])
- //
- // if _, ok := p.AreaNames[area]; !ok {
- // p.AreaNames[area] = make(api.TypeEndPoints)
- // }
- //
- // p.AreaNames[area][name] = api.TypeEndPoint {
- // Area: area,
- // Name: name,
- // Url: u,
- // Request: nil,
- // Response: nil,
- // }
- //
- // }
- }
-
- // for range Only.Once {
- // api.Initialize(ContentTypes)
- // Initialize(ContentTypes)
- //
- // println("Content Types\n---------")
- // for _, ct := range api.GetContentTypes() {
- // println(ct.GetSlug())
- // }
- // println("\nResource Types\n---------")
- // for _, rt := range GetResourceTypes() {
- // println(rt.GetSlug())
- // }
- //
- // }
-
- return p.Error
-}
-
-func (p *SunGro) AppendUrl(endpoint string) *url.URL {
- var ret *url.URL
- for range Only.Once {
- endpoint = fmt.Sprintf("%s%s", p.Web.Url.String(), endpoint)
- ret, p.Error = url.Parse(endpoint)
- if p.Error != nil {
- break
- }
- }
- return ret
-}
-
-
-func (p *SunGro) GetEndpoint(area string, endpoint string) *api.TypeEndPoint {
- var ret *api.TypeEndPoint
- for range Only.Once {
- if area == "" {
- p.Error = errors.New("empty area name")
- break
- }
- if endpoint == "" {
- p.Error = errors.New("empty endpoint name")
- break
- }
-
- ret = p.AreaNames.GetEndPoint(api.AreaName(area), api.EndPointName(endpoint))
- if ret != nil {
- break
- }
-
- p.Error = errors.New("endpoint not found")
- }
- return ret
-}
-
-// func (p *SunGro) AddEndpoint(endpoint *api.TypeEndPoint) error {
-// for range Only.Once {
-// if endpoint == nil {
-// p.Error = errors.New("empty endpoint")
-// break
-// }
-//
-// p.EndPoints[endpoint.Name] = *endpoint
-// }
-// return p.Error
-// }
-
-func (p *SunGro) ListEndpoints(area string) error {
- for range Only.Once {
- if area == "" {
- fmt.Printf("Listing all endpoints from all areas:\n")
- table := tablewriter.NewWriter(os.Stdout)
- table.SetHeader([]string{"Area", "Resource", "Url"})
- table.SetBorder(true)
- for _, area := range p.AreaNames.SortAreas() {
- endpoints := p.AreaNames[area]
- for _, endpoint := range endpoints.SortEndPoints() {
- table.Append([]string{
- string(p.AreaNames[area][api.EndPointName(endpoint)].Area),
- string(p.AreaNames[area][api.EndPointName(endpoint)].Name),
- p.AreaNames[area][api.EndPointName(endpoint)].Url.String(),
- })
- }
- }
- table.Render()
- break
- }
-
- if p.AreaNotExists(area) {
- p.Error = errors.New("unknown area name")
- break
- }
-
- fmt.Printf("Listing all endpoints from area '%s':\n", area)
- table := tablewriter.NewWriter(os.Stdout)
- table.SetHeader([]string{"Resource", "Url"})
- table.SetBorder(true)
- endpoints := p.AreaNames[api.AreaName(area)]
- for _, endpoint := range endpoints.SortEndPoints() {
- table.Append([]string{
- string(p.AreaNames[api.AreaName(area)][api.EndPointName(endpoint)].Name),
- p.AreaNames[api.AreaName(area)][api.EndPointName(endpoint)].Url.String(),
- })
- }
- table.Render()
- }
-
- return p.Error
-}
-
-func (p *SunGro) ListAreas() error {
- for range Only.Once {
- fmt.Println("Listing all endpoint areas:")
- table := tablewriter.NewWriter(os.Stdout)
- table.SetHeader([]string{"Areas", "EndPoints"})
- table.SetBorder(true)
-
- for _, area := range p.AreaNames.SortAreas() {
- size := fmt.Sprintf("%d", len(p.AreaNames[api.AreaName(area)]))
- table.Append([]string{string(area), size})
- }
-
- table.Render()
- }
- return p.Error
-}
-
-
-func (p *SunGro) AreaExists(area string) bool {
- var ok bool
- _, ok = p.AreaNames[api.AreaName(area)]
- return ok
-}
-func (p *SunGro) AreaNotExists(area string) bool {
- return !p.AreaExists(area)
-}
-
-// func (p *SunGro) EndPointExists(area string, endpoint string) bool {
-// var ok bool
-// _, ok = p.EndPoints[api.EndPointName(endpoint)]
-// return ok
-// }
-// func (p *SunGro) EndPointNotExists(area string, endpoint string) bool {
-// return !p.EndPointExists(area, endpoint)
-// }
diff --git a/iSolarCloud/AliSmsService/init.go b/iSolarCloud/sungro/AliSmsService/init.go
similarity index 91%
rename from iSolarCloud/AliSmsService/init.go
rename to iSolarCloud/sungro/AliSmsService/init.go
index 644c3ab57..a34772786 100644
--- a/iSolarCloud/AliSmsService/init.go
+++ b/iSolarCloud/sungro/AliSmsService/init.go
@@ -24,5 +24,5 @@ func init() {
p := ref.String()
s := ref.Name()
Area.Name = api.AreaName(strings.TrimSuffix(p, "." + s))
- Area.EndPoints = api.CreateEndPoints(endpoints)
+ // Area.EndPoints = api.CreateEndPoints(endpoints)
}
diff --git a/iSolarCloud/AliSmsService/pkgreflect.go b/iSolarCloud/sungro/AliSmsService/pkgreflect.go
similarity index 100%
rename from iSolarCloud/AliSmsService/pkgreflect.go
rename to iSolarCloud/sungro/AliSmsService/pkgreflect.go
diff --git a/iSolarCloud/sungro/AppService/getPowerDevicePointNames/struct.go b/iSolarCloud/sungro/AppService/getPowerDevicePointNames/struct.go
new file mode 100644
index 000000000..7e8810310
--- /dev/null
+++ b/iSolarCloud/sungro/AppService/getPowerDevicePointNames/struct.go
@@ -0,0 +1,96 @@
+// EndPoint
+package getPowerDevicePointNames
+
+import (
+ "GoSungro/iSolarCloud/api"
+ "fmt"
+ "net/url"
+)
+
+
+var Url = "/v1/reportService/getPowerDevicePointNames"
+
+var _ api.EndPoint = (*EndPoint)(nil)
+
+type EndPoint api.EndPointStruct
+
+type Request struct {
+ api.RequestCommon
+ Extra string
+}
+type Response struct {
+ api.ResponseCommon
+ Another string
+}
+
+
+func Init() EndPoint {
+ fmt.Println("Init()")
+
+ foo := EndPoint {
+ Area: api.GetArea(EndPoint{}),
+ Name: api.GetName(EndPoint{}),
+ Url: api.GetUrl(Url),
+ Request: Request{},
+ Response: Response{},
+ Error: nil,
+ }
+
+ fmt.Printf("endpoint: %v\n", foo)
+
+ return foo
+}
+
+
+func (g EndPoint) GetArea() api.AreaName {
+ fmt.Println("g.GetArea()")
+ return g.Area
+}
+
+func (g EndPoint) GetName() api.EndPointName {
+ fmt.Println("g.GetName()")
+ return g.Name
+}
+
+func (g EndPoint) GetUrl() *url.URL {
+ fmt.Println("g.GetUrl()")
+ return g.Url
+}
+
+func (g EndPoint) SetRequest(ref interface{}) error {
+ fmt.Println("g.SetRequest()")
+ fmt.Printf("ref == %v\n", ref)
+ return nil
+}
+
+func (g EndPoint) GetRequest() api.Json {
+ return api.GetAsJson(g.Request)
+}
+
+func (g EndPoint) GetResponse() api.Json {
+ return api.GetAsJson(g.Response)
+}
+
+func (g EndPoint) GetData() api.Json {
+ return api.GetAsJson(g.Response.(Response).ResultData)
+}
+
+func (g EndPoint) IsValid() error {
+ fmt.Println("g.IsValid() implement me")
+ return nil
+}
+
+func (g EndPoint) Call() api.Json {
+ fmt.Println("g.Call() implement me")
+ return ""
+}
+
+func (g EndPoint) Init() *EndPoint {
+ fmt.Println("g.Init()")
+ ret := Init()
+ return &ret
+}
+
+func (g EndPoint) GetError() error {
+ return g.Error
+}
diff --git a/iSolarCloud/sungro/AppService/login/struct.go b/iSolarCloud/sungro/AppService/login/struct.go
new file mode 100644
index 000000000..7f38e27a8
--- /dev/null
+++ b/iSolarCloud/sungro/AppService/login/struct.go
@@ -0,0 +1,204 @@
+// EndPoint
+package login
+
+import (
+ "GoSungro/iSolarCloud/api"
+ "fmt"
+ "net/url"
+)
+
+
+var Url = "/v1/userService/login"
+
+var _ api.EndPoint = (*EndPoint)(nil)
+
+type EndPoint api.EndPointStruct
+
+type Request struct {
+ // api.RequestCommon // login is special as it doesn't have the usual fields.
+ Appkey string `json:"appkey"`
+ SysCode string `json:"sys_code"`
+ UserAccount string `json:"user_account"`
+ UserPassword string `json:"user_password"`
+}
+
+type Response struct {
+ api.ResponseCommon
+ ResultData struct {
+ AcceptOrderNum int64 `json:"accept_order_num"`
+ BackgroundColor int64 `json:"background_color"`
+ Countryid string `json:"countryid"`
+ Createdate string `json:"createdate"`
+ Createuserid string `json:"createuserid"`
+ CurrentOrderNum int64 `json:"current_order_num"`
+ DisableTime string `json:"disable_time"`
+ Email string `json:"email"`
+ Englishname interface{} `json:"englishname"`
+ ErrTimes string `json:"err_times"`
+ GcjLatitude interface{} `json:"gcj_latitude"`
+ GcjLongitude interface{} `json:"gcj_longitude"`
+ ImToken interface{} `json:"im_token"`
+ IsDST string `json:"isDST"`
+ IsAfsFlag string `json:"is_afs_flag"`
+ IsAgreeGdpr int64 `json:"is_agree_gdpr"`
+ IsAu int64 `json:"is_au"`
+ IsCanModifyUserAccount int64 `json:"is_can_modify_user_account"`
+ IsDisableMap string `json:"is_disable_map"`
+ IsGdpr int64 `json:"is_gdpr"`
+ IsHaveIm int64 `json:"is_have_im"`
+ IsNewVersion int64 `json:"is_new_version"`
+ IsOnline string `json:"is_online"`
+ IsOpenProtocol int64 `json:"is_open_protocol"`
+ IsReceiveNotice int64 `json:"is_receive_notice"`
+ IsSharePosition int64 `json:"is_share_position"`
+ IsUploadLocation int64 `json:"is_upload_location"`
+ IsUseSungrowBrand string `json:"is_use_sungrow_brand"`
+ IsValidMobileEmail int64 `json:"is_valid_mobile_email"`
+ Isdst string `json:"isdst"`
+ Jobs interface{} `json:"jobs"`
+ Language string `json:"language"`
+ LoginFirstDate string `json:"loginFirstDate"`
+ LoginFristDate string `json:"loginFristDate"`
+ LoginLastDate string `json:"loginLastDate"`
+ LoginLastIP string `json:"loginLastIp"`
+ LoginTimes int64 `json:"loginTimes"`
+ LoginState string `json:"login_state"`
+ Logo interface{} `json:"logo"`
+ LogoHTTPSURL interface{} `json:"logo_https_url"`
+ MapType string `json:"map_type"`
+ MinDate string `json:"min_date"`
+ MobileTel interface{} `json:"mobile_tel"`
+ OrgID string `json:"org_id"`
+ OrgName string `json:"org_name"`
+ OrgTimezone string `json:"org_timezone"`
+ PasswordIsSimple int64 `json:"password_is_simple"`
+ PhotoID interface{} `json:"photo_id"`
+ PhotoURL interface{} `json:"photo_url"`
+ Privileges []struct {
+ FatherID int64 `json:"father_id"`
+ IconURL interface{} `json:"icon_url"`
+ IsOpen interface{} `json:"is_open"`
+ IsThirdPlatform int64 `json:"is_third_platform"`
+ MenuCode string `json:"menu_code"`
+ MenuLevel int64 `json:"menu_level"`
+ MenuName string `json:"menu_name"`
+ MenuOrder interface{} `json:"menu_order"`
+ MenuType string `json:"menu_type"`
+ MenuURL string `json:"menu_url"`
+ PrivilegeID int64 `json:"privilege_id"`
+ RoleID int64 `json:"role_id"`
+ URLTarget string `json:"url_target"`
+ VueIcon interface{} `json:"vue_icon"`
+ VuePath interface{} `json:"vue_path"`
+ } `json:"privileges"`
+ RoleID string `json:"role_id"`
+ SecondaryOrgIds []interface{} `json:"secondaryOrgIds"`
+ ServerTel string `json:"server_tel"`
+ ServiceVersion string `json:"service_version"`
+ Sex string `json:"sex"`
+ Stylename string `json:"stylename"`
+ TimeZone string `json:"timeZone"`
+ Timezone string `json:"timezone"`
+ Timezoneid string `json:"timezoneid"`
+ Toggleflag string `json:"toggleflag"`
+ Token string `json:"token"`
+ UnlockLaveMinute int64 `json:"unlock_lave_minute"`
+ UploadTime interface{} `json:"upload_time"`
+ UserAccount string `json:"user_account"`
+ UserAccountModifyCount int64 `json:"user_account_modify_count"`
+ UserAccountModifyRemainTimes int64 `json:"user_account_modify_remain_times"`
+ UserDealerOrgCode interface{} `json:"user_dealer_org_code"`
+ UserID string `json:"user_id"`
+ UserLevel string `json:"user_level"`
+ UserMasterOrgID string `json:"user_master_org_id"`
+ UserMasterOrgName string `json:"user_master_org_name"`
+ UserMasterOrgTimeZoneID string `json:"user_master_org_time_zone_id"`
+ UserMasterOrgTimeZoneName string `json:"user_master_org_time_zone_name"`
+ UserName string `json:"user_name"`
+ UserRoleIDList []string `json:"user_role_id_list"`
+ UserTelNationCode interface{} `json:"user_tel_nation_code"`
+ UserauthorURL []interface{} `json:"userauthorURL"`
+ Userauthorbutto []string `json:"userauthorbutto"`
+ Userdesc interface{} `json:"userdesc"`
+ Userpassword string `json:"userpassword"`
+ Validflag string `json:"validflag"`
+ Voice string `json:"voice"`
+ Welcometext string `json:"welcometext"`
+ Wgs84Latitude interface{} `json:"wgs84_latitude"`
+ Wgs84Longitude interface{} `json:"wgs84_longitude"`
+ WorkTel interface{} `json:"work_tel"`
+ } `json:"result_data"`
+}
+
+
+func Init() EndPoint {
+ fmt.Println("Init()")
+
+ foo := EndPoint {
+ Area: api.GetArea(EndPoint{}),
+ Name: api.GetName(EndPoint{}),
+ Url: api.GetUrl(Url),
+ Request: Request{},
+ Response: Response{},
+ Error: nil,
+ }
+
+ fmt.Printf("endpoint: %v\n", foo)
+
+ return foo
+}
+
+
+func (g EndPoint) GetArea() api.AreaName {
+ fmt.Println("g.GetArea()")
+ return g.Area
+}
+
+func (g EndPoint) GetName() api.EndPointName {
+ fmt.Println("g.GetName()")
+ return g.Name
+}
+
+func (g EndPoint) GetUrl() *url.URL {
+ fmt.Println("g.GetUrl()")
+ return g.Url
+}
+
+func (g EndPoint) SetRequest(ref interface{}) error {
+ fmt.Println("g.SetRequest()")
+ g.Request = ref.(Request)
+ fmt.Printf("ref == %v\n", g.Request)
+ return nil
+}
+
+func (g EndPoint) GetRequest() api.Json {
+ return api.GetAsJson(g.Request)
+}
+
+func (g EndPoint) GetResponse() api.Json {
+ return api.GetAsJson(g.Response)
+}
+
+func (g EndPoint) GetData() api.Json {
+ return api.GetAsJson(g.Response.(Response).ResultData)
+}
+
+func (g EndPoint) IsValid() error {
+ fmt.Println("g.IsValid() implement me")
+ return nil
+}
+
+func (g EndPoint) Call() api.Json {
+ fmt.Println("g.Call() implement me")
+ return ""
+}
+
+func (g EndPoint) Init() *EndPoint {
+ fmt.Println("g.Init()")
+ ret := Init()
+ return &ret
+}
+
+func (g EndPoint) GetError() error {
+ return g.Error
+}
diff --git a/iSolarCloud/sungro/AppService/nullEndPoint/struct.go b/iSolarCloud/sungro/AppService/nullEndPoint/struct.go
new file mode 100644
index 000000000..3a12a9aaf
--- /dev/null
+++ b/iSolarCloud/sungro/AppService/nullEndPoint/struct.go
@@ -0,0 +1,96 @@
+// EndPoint
+package nullEndPoint
+
+import (
+ "GoSungro/iSolarCloud/api"
+ "fmt"
+ "net/url"
+)
+
+
+var Url = ""
+
+var _ api.EndPoint = (*EndPoint)(nil)
+
+type EndPoint api.EndPointStruct
+
+type Request struct {
+ api.RequestCommon
+}
+
+type Response struct {
+ api.ResponseCommon
+}
+
+func Init() EndPoint {
+ fmt.Println("Init()")
+
+ foo := EndPoint {
+ Area: api.GetArea(EndPoint{}),
+ Name: api.GetName(EndPoint{}),
+ Url: api.GetUrl(Url),
+ Request: Request{},
+ Response: Response{},
+ Error: nil,
+ }
+
+ fmt.Printf("endpoint: %v\n", foo)
+
+ return foo
+}
+
+
+func (g EndPoint) GetArea() api.AreaName {
+ fmt.Println("g.GetArea() implement me")
+ return g.Area
+}
+
+func (g EndPoint) GetName() api.EndPointName {
+ fmt.Println("g.GetName() implement me")
+ return g.Name
+}
+
+func (g EndPoint) GetUrl() *url.URL {
+ fmt.Println("g.GetUrl() implement me")
+ return g.Url
+}
+
+func (g EndPoint) SetRequest(ref interface{}) error {
+ fmt.Println("g.SetRequest() implement me")
+ fmt.Printf("ref == %v\n", ref)
+ return nil
+}
+
+func (g EndPoint) GetRequest() api.Json {
+ return api.GetAsJson(g.Request)
+}
+
+func (g EndPoint) GetResponse() api.Json {
+ return api.GetAsJson(g.Response)
+}
+
+func (g EndPoint) GetData() api.Json {
+ fmt.Println("g.GetData() implement me")
+ return api.GetAsJson(g.Response.(Response).ResultData)
+}
+
+func (g EndPoint) IsValid() error {
+ fmt.Println("g.IsValid() implement me")
+ return nil
+}
+
+func (g EndPoint) Call() api.Json {
+ fmt.Println("g.Call() implement me")
+ return ""
+}
+
+func (g EndPoint) Init() *EndPoint {
+ fmt.Println("g.Init() implement me")
+ ret := Init()
+ return &ret
+}
+
+func (g EndPoint) GetError() error {
+ fmt.Println("g.IsValid() implement me")
+ return g.Error
+}
diff --git a/iSolarCloud/sungro/AppService/pkgreflect.go b/iSolarCloud/sungro/AppService/pkgreflect.go
new file mode 100644
index 000000000..24831ba7a
--- /dev/null
+++ b/iSolarCloud/sungro/AppService/pkgreflect.go
@@ -0,0 +1,3 @@
+// Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
+
+package AppService
diff --git a/iSolarCloud/sungro/AppService/struct.go b/iSolarCloud/sungro/AppService/struct.go
new file mode 100644
index 000000000..12b6a78ac
--- /dev/null
+++ b/iSolarCloud/sungro/AppService/struct.go
@@ -0,0 +1,652 @@
+package AppService
+
+import (
+ "GoSungro/iSolarCloud/api"
+ "GoSungro/iSolarCloud/sungro/AppService/getPowerDevicePointNames"
+ "GoSungro/iSolarCloud/sungro/AppService/login"
+ "GoSungro/iSolarCloud/sungro/AppService/nullEndPoint"
+ "fmt"
+)
+
+var _ api.Area = (*Area)(nil)
+
+type Area api.AreaStruct
+
+
+func init() {
+ name := api.GetArea(Area{})
+ fmt.Printf("Name: %s\n", name)
+}
+
+func Init() Area {
+ fmt.Println("Init()")
+ name := api.GetArea(Area{})
+ fmt.Printf("Name: %s\n", name)
+
+ area := Area {
+ Name: api.GetArea(Area{}),
+ EndPoints: api.TypeEndPoints {
+ "acceptPsSharing": nullEndPoint.Init(), // "/v1/powerStationService/acceptPsSharing"}
+ "activateEmail": nullEndPoint.Init(), // "/v1/userService/activateEmail"}
+ "addConfig": nullEndPoint.Init(), // "/devDataHandleService/addConfig"}
+ "addDeviceRepair": nullEndPoint.Init(), // "/v1/devService/addDeviceRepair"}
+ "addDeviceToStructureForHousehold": nullEndPoint.Init(), // "/devDataHandleService/addDeviceToStructureForHousehold"}
+ "addDeviceToStructureForHouseholdByPsIdS": nullEndPoint.Init(), // "/devDataHandleService/addDeviceToStructureForHouseholdByPsIdS"}
+ "addFault": nullEndPoint.Init(), // "/v1/faultService/addFault"}
+ "addFaultOrder": nullEndPoint.Init(), // "/v1/faultService/addFaultOrder"}
+ "addFaultPlan": nullEndPoint.Init(), // "/v1/faultService/addFaultPlan"}
+ "addFaultRepairSteps": nullEndPoint.Init(), // "/v1/faultService/addFaultRepairSteps"}
+ "addHouseholdEvaluation": nullEndPoint.Init(), // "/v1/faultService/addHouseholdEvaluation"}
+ "addHouseholdLeaveMessage": nullEndPoint.Init(), // "/v1/faultService/addHouseholdLeaveMessage"}
+ "addHouseholdOpinionFeedback": nullEndPoint.Init(), // "/v1/faultService/addHouseholdOpinionFeedback"}
+ "addHouseholdWorkOrder": nullEndPoint.Init(), // "/v1/faultService/addHouseholdWorkOrder"}
+ "addOnDutyInfo": nullEndPoint.Init(), // "/v1/otherService/addOnDutyInfo"}
+ "addOperRule": nullEndPoint.Init(), // "/v1/faultService/addOperRule"}
+ "addOrDelPsStructure": nullEndPoint.Init(), // "/v1/devService/addOrDelPsStructure"}
+ "addOrderStep": nullEndPoint.Init(), // "/v1/faultService/addOrderStep"}
+ "addPowerStationForHousehold": nullEndPoint.Init(), // "/v1/powerStationService/addPowerStationForHousehold"}
+ "addPowerStationInfo": nullEndPoint.Init(), // "/v1/powerStationService/addPowerStationInfo"}
+ "addReportConfigEmail": nullEndPoint.Init(), // "/v1/reportService/addReportConfigEmail"}
+ "addSysAdvancedParam": nullEndPoint.Init(), // "/v1/devService/addSysAdvancedParam"}
+ "addSysOrgNew": nullEndPoint.Init(), // "/v1/otherService/addSysOrgNew"}
+ "aliPayAppTest": nullEndPoint.Init(), // "/onlinepay/aliPayAppTest"}
+ "auditOperRule": nullEndPoint.Init(), // "/v1/faultService/auditOperRule"}
+ "batchAddStationBySn": nullEndPoint.Init(), // "/v1/powerStationService/batchAddStationBySn"}
+ "batchImportSN": nullEndPoint.Init(), // "/v1/devService/batchImportSN"}
+ "batchInsertUserAndOrg": nullEndPoint.Init(), // "/v1/userService/batchInsertUserAndOrg"}
+ "batchModifyDevicesInfoAndPropertis": nullEndPoint.Init(), // "/v1/devService/batchModifyDevicesInfoAndPropertis"}
+ "batchProcessPlantReport": nullEndPoint.Init(), // "/v1/powerStationService/batchProcessPlantReport"}
+ "batchUpdateDeviceSim": nullEndPoint.Init(), // "/v1/devService/batchUpdateDeviceSim"}
+ "batchUpdateUserIsAgreeGdpr": nullEndPoint.Init(), // "/v1/userService/batchUpdateUserIsAgreeGdpr"}
+ "boundMobilePhone": nullEndPoint.Init(), // "/v1/userService/boundMobilePhone"}
+ "boundUserMail": nullEndPoint.Init(), // "/v1/userService/boundUserMail"}
+ "caculateDeviceInputDiscrete": nullEndPoint.Init(), // "/v1/devService/caculateDeviceInputDiscrete"}
+ "calculateDeviceDiscrete": nullEndPoint.Init(), // "/v1/devService/calculateDeviceDiscrete"}
+ "calculateInitialCompensationData": nullEndPoint.Init(), // "/v1/powerStationService/calculateInitialCompensationData"}
+ "cancelDeliverMail": nullEndPoint.Init(), // "/v1/messageService/cancelDeliverMail"}
+ "cancelOrderScan": nullEndPoint.Init(), // "/v1/devService/cancelOrderScan"}
+ "cancelParamSetTask": nullEndPoint.Init(), // "/v1/devService/cancelParamSetTask"}
+ "cancelPsSharing": nullEndPoint.Init(), // "/v1/powerStationService/cancelPsSharing"}
+ "cancelRechargeOrder": nullEndPoint.Init(), // "/onlinepay/cancelRechargeOrder"}
+ "changRechargeOrderToCancel": nullEndPoint.Init(), // "/onlinepay/changRechargeOrderToCancel"}
+ "changeHouseholdUser2Installer": nullEndPoint.Init(), // "/v1/orgService/changeHouseholdUser2Installer"}
+ "changeRemoteParam": nullEndPoint.Init(), // "/v1/devService/changeRemoteParam"}
+ "checkDealerOrgCode": nullEndPoint.Init(), // "/v1/orgService/checkDealerOrgCode"}
+ "checkDevSnIsBelongsToUser": nullEndPoint.Init(), // "/v1/userService/checkDevSnIsBelongsToUser"}
+ "checkInverterResult": nullEndPoint.Init(), // "/v1/devService/checkInverterResult"}
+ "checkIsCanDoParamSet": nullEndPoint.Init(), // "/v1/devService/checkIsCanDoParamSet"}
+ "checkIsIvScan": nullEndPoint.Init(), // "/v1/devService/checkIsIvScan"}
+ "checkOssObjectExist": nullEndPoint.Init(), // "/v1/commonService/checkOssObjectExist"}
+ "checkServiceIsConnect": nullEndPoint.Init(), // "/v1/commonService/checkServiceIsConnect"}
+ "checkTechnicalParameters": nullEndPoint.Init(), // "/v1/devService/checkTechnicalParameters"}
+ "checkUnitStatus": nullEndPoint.Init(), // "/v1/devService/checkUnitStatus"}
+ "checkUpRechargeDevicePaying": nullEndPoint.Init(), // "/onlinepay/checkUpRechargeDevicePaying"}
+ "checkUserAccountUnique": nullEndPoint.Init(), // "/v1/userService/checkUserAccountUnique"}
+ "checkUserAccountUniqueAll": nullEndPoint.Init(), // "/v1/userService/checkUserAccountUniqueAll"}
+ "checkUserInfoUnique": nullEndPoint.Init(), // "/v1/userService/checkUserInfoUnique"}
+ "checkUserIsExist": nullEndPoint.Init(), // "/v1/userService/checkUserIsExist"}
+ "checkUserListIsExist": nullEndPoint.Init(), // "/v1/userService/checkUserListIsExist"}
+ "checkUserPassword": nullEndPoint.Init(), // "/v1/userService/checkUserPassword"}
+ "cloudDeploymentRecord": nullEndPoint.Init(), // "/v1/commonService/cloudDeploymentRecord"}
+ "comfirmParamModel": nullEndPoint.Init(), // "/v1/devService/comfirmParamModel"}
+ "communicationModuleDetail": nullEndPoint.Init(), // "/v1/devService/communicationModuleDetail"}
+ "compareValidateCode": nullEndPoint.Init(), // "/v1/userService/compareValidateCode"}
+ "componentInfo2Cloud": nullEndPoint.Init(), // "/v1/devService/componentInfo2Cloud"}
+ "confirmFault": nullEndPoint.Init(), // "/v1/faultService/confirmFault"}
+ "confirmIvFault": nullEndPoint.Init(), // "/v1/devService/confirmIvFault"}
+ "confirmReportConfig": nullEndPoint.Init(), // "/v1/reportService/confirmReportConfig"}
+ "createAppkeyInfo": nullEndPoint.Init(), // "/v1/userService/createAppkeyInfo"}
+ "createRenewInvoice": nullEndPoint.Init(), // "/onlinepay/createRenewInvoice"}
+ "dealCommandReply": nullEndPoint.Init(), // "/devDataHandleService/dealCommandReply"}
+ "dealDeletePsFailPsDelete": nullEndPoint.Init(), // "/v1/powerStationService/dealDeletePsFailPsDelete"}
+ "dealFailRemoteUpgradeSubTasks": nullEndPoint.Init(), // "/v1/devService/dealFailRemoteUpgradeSubTasks"}
+ "dealFailRemoteUpgradeTasks": nullEndPoint.Init(), // "/v1/devService/dealFailRemoteUpgradeTasks"}
+ "dealFaultOrder": nullEndPoint.Init(), // "/v1/faultService/dealFaultOrder"}
+ "dealGroupStringDisableOrEnable": nullEndPoint.Init(), // "/v1/devService/dealGroupStringDisableOrEnable"}
+ "dealNumberOfServiceCalls2Mysql": nullEndPoint.Init(), // "/v1/commonService/dealNumberOfServiceCalls2Mysql"}
+ "dealParamSettingAfterComplete": nullEndPoint.Init(), // "/v1/devService/dealParamSettingAfterComplete"}
+ "dealPsDataSupplement": nullEndPoint.Init(), // "/v1/powerStationService/dealPsDataSupplement"}
+ "dealPsReportEmailSend": nullEndPoint.Init(), // "/v1/reportService/dealPsReportEmailSend"}
+ "dealRemoteUpgrade": nullEndPoint.Init(), // "/v1/devService/dealRemoteUpgrade"}
+ "dealSnElectrifyCheck": nullEndPoint.Init(), // "/v1/devService/dealSnElectrifyCheck"}
+ "dealSysDeviceSimFlowInfo": nullEndPoint.Init(), // "/v1/devService/dealSysDeviceSimFlowInfo"}
+ "dealSysDeviceSimInfo": nullEndPoint.Init(), // "/v1/devService/dealSysDeviceSimInfo"}
+ "definiteTimeDealSnExpRemind": nullEndPoint.Init(), // "/v1/devService/definiteTimeDealSnExpRemind"}
+ "definiteTimeDealSnStatus": nullEndPoint.Init(), // "/v1/devService/definiteTimeDealSnStatus"}
+ "delDeviceRepair": nullEndPoint.Init(), // "/v1/devService/delDeviceRepair"}
+ "delOperRule": nullEndPoint.Init(), // "/v1/faultService/delOperRule"}
+ "delayCallApiResidueTimes": nullEndPoint.Init(), // "/v1/commonService/delayCallApiResidueTimes"}
+ "deleteComponent": nullEndPoint.Init(), // "/v1/devService/deleteComponent"}
+ "deleteCustomerEmployee": nullEndPoint.Init(), // "/v1/devService/deleteCustomerEmployee"}
+ "deleteDeviceAccount": nullEndPoint.Init(), // "/v1/devService/deleteDeviceAccount"}
+ "deleteDeviceSimById": nullEndPoint.Init(), // "/v1/devService/deleteDeviceSimById"}
+ "deleteElectricitySettlementData": nullEndPoint.Init(), // "/v1/otherService/deleteElectricitySettlementData"}
+ "deleteFaultPlan": nullEndPoint.Init(), // "/v1/faultService/deleteFaultPlan"}
+ "deleteFirmwareFiles": nullEndPoint.Init(), // "/v1/commonService/deleteFirmwareFiles"}
+ "deleteHouseholdEvaluation": nullEndPoint.Init(), // "/v1/faultService/deleteHouseholdEvaluation"}
+ "deleteHouseholdLeaveMessage": nullEndPoint.Init(), // "/v1/faultService/deleteHouseholdLeaveMessage"}
+ "deleteHouseholdWorkOrder": nullEndPoint.Init(), // "/v1/faultService/deleteHouseholdWorkOrder"}
+ "deleteInverterSnInChnnl": nullEndPoint.Init(), // "/devDataHandleService/deleteInverterSnInChnnl"}
+ "deleteModuleLog": nullEndPoint.Init(), // "/integrationService/deleteModuleLog"}
+ "deleteOnDutyInfo": nullEndPoint.Init(), // "/v1/otherService/deleteOnDutyInfo"}
+ "deleteOperateBillFile": nullEndPoint.Init(), // "/v1/faultService/deleteOperateBillFile"}
+ "deleteOssObject": nullEndPoint.Init(), // "/v1/commonService/deleteOssObject"}
+ "deletePowerDevicePointById": nullEndPoint.Init(), // "/v1/reportService/deletePowerDevicePointById"}
+ "deletePowerPicture": nullEndPoint.Init(), // "/v1/powerStationService/deletePowerPicture"}
+ "deletePowerRobotInfoBySnAndPsId": nullEndPoint.Init(), // "/v1/devService/deletePowerRobotInfoBySnAndPsId"}
+ "deletePowerRobotSweepStrategy": nullEndPoint.Init(), // "/v1/devService/deletePowerRobotSweepStrategy"}
+ "deleteProductionData": nullEndPoint.Init(), // "/v1/devService/deleteProductionData"}
+ "deletePs": nullEndPoint.Init(), // "/v1/powerStationService/deletePs"}
+ "deleteRechargeOrder": nullEndPoint.Init(), // "/onlinepay/deleteRechargeOrder"}
+ "deleteRegularlyConnectionInfo": nullEndPoint.Init(), // "/v1/commonService/deleteRegularlyConnectionInfo"}
+ "deleteReportConfigEmailAddr": nullEndPoint.Init(), // "/v1/reportService/deleteReportConfigEmailAddr"}
+ "deleteSysAdvancedParam": nullEndPoint.Init(), // "/v1/devService/deleteSysAdvancedParam"}
+ "deleteSysOrgNew": nullEndPoint.Init(), // "/v1/otherService/deleteSysOrgNew"}
+ "deleteTemplate": nullEndPoint.Init(), // "/v1/devService/deleteTemplate"}
+ "deleteUserInfoAllByUserId": nullEndPoint.Init(), // "/v1/userService/deleteUserInfoAllByUserId"}
+ "deviceInputDiscreteDeleteTime": nullEndPoint.Init(), // "/v1/devService/deviceInputDiscreteDeleteTime"}
+ "deviceInputDiscreteGetTime": nullEndPoint.Init(), // "/v1/devService/deviceInputDiscreteGetTime"}
+ "deviceInputDiscreteInsertTime": nullEndPoint.Init(), // "/v1/devService/deviceInputDiscreteInsertTime"}
+ "deviceInputDiscreteUpdateTime": nullEndPoint.Init(), // "/v1/devService/deviceInputDiscreteUpdateTime"}
+ "devicePointsDataFromMySql": nullEndPoint.Init(), // "/v1/devService/devicePointsDataFromMySql"}
+ "deviceReplace": nullEndPoint.Init(), // "/v1/devService/deviceReplace"}
+ "editDeviceRepair": nullEndPoint.Init(), // "/v1/devService/editDeviceRepair"}
+ "editOperRule": nullEndPoint.Init(), // "/v1/faultService/editOperRule"}
+ "energyPovertyAlleviation": nullEndPoint.Init(), // "/v1/orgService/energyPovertyAlleviation"}
+ "energyTrend": nullEndPoint.Init(), // "/v1/powerStationService/energyTrend"}
+ "exportParamSettingValPDF": nullEndPoint.Init(), // "/v1/devService/exportParamSettingValPDF"}
+ "exportPlantReportPDF": nullEndPoint.Init(), // "/v1/powerStationService/exportPlantReportPDF"}
+ "faultAutoClose": nullEndPoint.Init(), // "/v1/faultService/faultAutoClose"}
+ "faultCloseRemindOrderHandler": nullEndPoint.Init(), // "/v1/faultService/faultCloseRemindOrderHandler"}
+ "findCodeValueList": nullEndPoint.Init(), // "/v1/commonService/findCodeValueList"}
+ "findEmgOrgInfo": nullEndPoint.Init(), // "/v1/otherService/findEmgOrgInfo"}
+ "findEnvironmentInfo": nullEndPoint.Init(), // "/v1/devService/findEnvironmentInfo"}
+ "findFromHbaseAndRedis": nullEndPoint.Init(), // "/v1/commonService/findFromHbaseAndRedis"}
+ "findInfoByuuid": nullEndPoint.Init(), // "/v1/devService/findInfoByuuid"}
+ "findLossAnalysisList": nullEndPoint.Init(), // "/v1/powerStationService/findLossAnalysisList"}
+ "findOnDutyInfo": nullEndPoint.Init(), // "/v1/otherService/findOnDutyInfo"}
+ "findPsType": nullEndPoint.Init(), // "/v1/powerStationService/findPsType"}
+ "findSingleStationPR": nullEndPoint.Init(), // "/v1/powerStationService/findSingleStationPR"}
+ "findUserPassword": nullEndPoint.Init(), // "/v1/devService/findUserPassword"}
+ "genTLSUserSigByUserAccount": nullEndPoint.Init(), // "/v1/userService/genTLSUserSigByUserAccount"}
+ "generateRandomPassword": nullEndPoint.Init(), // "/v1/userService/generateRandomPassword"}
+ "getAPIServiceInfo": nullEndPoint.Init(), // "/v1/commonService/getAPIServiceInfo"}
+ "getAccessedPermission": nullEndPoint.Init(), // "/v1/commonService/getAccessedPermission"}
+ "getAllDeviceByPsId": nullEndPoint.Init(), // "/v1/devService/getAllDeviceByPsId"}
+ "getAllPowerDeviceSetName": nullEndPoint.Init(), // "/v1/devService/getAllPowerDeviceSetName"}
+ "getAllPowerRobotViewInfoByPsId": nullEndPoint.Init(), // "/v1/devService/getAllPowerRobotViewInfoByPsId"}
+ "getAllPsIdByOrgIds": nullEndPoint.Init(), // "/v1/devService/getAllPsIdByOrgIds"}
+ "getAllUserRemindCount": nullEndPoint.Init(), // "/v1/devService/getAllUserRemindCount"}
+ "getAndOutletsAndUnit": nullEndPoint.Init(), // "/v1/devService/getAndOutletsAndUnit"}
+ "getApiCallsForAppkeys": nullEndPoint.Init(), // "/v1/commonService/getApiCallsForAppkeys"}
+ "getAreaInfoCodeByCounty": nullEndPoint.Init(), // "/v1/commonService/getAreaInfoCodeByCounty"}
+ "getAreaList": nullEndPoint.Init(), // "/v1/powerStationService/getAreaList"}
+ "getAutoCreatePowerStation": nullEndPoint.Init(), // "/v1/powerStationService/getAutoCreatePowerStation"}
+ "getBackReadValue": nullEndPoint.Init(), // "/v1/devService/getBackReadValue"}
+ "getBatchNewestPointData": nullEndPoint.Init(), // "/v1/devService/getBatchNewestPointData"}
+ "getCallApiResidueTimes": nullEndPoint.Init(), // "/v1/commonService/getCallApiResidueTimes"}
+ "getChangedPsListByTime": nullEndPoint.Init(), // "/v1/powerStationService/getChangedPsListByTime"}
+ "getChnnlListByPsId": nullEndPoint.Init(), // "/v1/devService/getChnnlListByPsId"}
+ "getCloudList": nullEndPoint.Init(), // "/v1/commonService/getCloudList"}
+ "getCloudServiceMappingConfig": nullEndPoint.Init(), // "/v1/commonService/getCloudServiceMappingConfig"}
+ "getCommunicationDeviceConfigInfo": nullEndPoint.Init(), // "/v1/devService/getCommunicationDeviceConfigInfo"}
+ "getCommunicationModuleMonitorData": nullEndPoint.Init(), // "/v1/devService/getCommunicationModuleMonitorData"}
+ "getComponentModelFactory": nullEndPoint.Init(), // "/v1/devService/getComponentModelFactory"}
+ "getConfigList": nullEndPoint.Init(), // "/devDataHandleService/getConfigList"}
+ "getConnectionInfoBySnAndLocalPort": nullEndPoint.Init(), // "/v1/commonService/getConnectionInfoBySnAndLocalPort"}
+ "getCountDown": nullEndPoint.Init(), // "/v1/devService/getCountDown"}
+ "getCountryServiceInfo": nullEndPoint.Init(), // "/v1/commonService/getCountryServiceInfo"}
+ "getCounty": nullEndPoint.Init(), // "/v1/commonService/getCounty"}
+ "getCustomerEmployee": nullEndPoint.Init(), // "/v1/devService/getCustomerEmployee"}
+ "getCustomerList": nullEndPoint.Init(), // "/v1/devService/getCustomerList"}
+ "getDataFromHBase": nullEndPoint.Init(), // "/v1/commonService/getDataFromHBase"}
+ "getDataFromHbaseByRowKey": nullEndPoint.Init(), // "/v1/commonService/getDataFromHbaseByRowKey"}
+ "getDevInstalledPowerByPsId": nullEndPoint.Init(), // "/v1/devService/getDevInstalledPowerByPsId"}
+ "getDevRecord": nullEndPoint.Init(), // "/v1/devService/getDevRecord"}
+ "getDevRunRecordList": nullEndPoint.Init(), // "/v1/devService/getDevRunRecordList"}
+ "getDevSimByList": nullEndPoint.Init(), // "/v1/devService/getDevSimByList"}
+ "getDevSimList": nullEndPoint.Init(), // "/v1/devService/getDevSimList"}
+ "getDeviceAccountById": nullEndPoint.Init(), // "/v1/devService/getDeviceAccountById"}
+ "getDeviceFaultStatisticsData": nullEndPoint.Init(), // "/v1/devService/getDeviceFaultStatisticsData"}
+ "getDeviceInfo": nullEndPoint.Init(), // "/v1/devService/getDeviceInfo"}
+ "getDeviceList": nullEndPoint.Init(), // "/v1/devService/getDeviceList"}
+ "getDeviceModelInfoList": nullEndPoint.Init(), // "/v1/devService/getDeviceModelInfoList"}
+ "getDevicePointMinuteDataList": nullEndPoint.Init(), // "/v1/commonService/getDevicePointMinuteDataList"}
+ "getDevicePoints": nullEndPoint.Init(), // "/v1/devService/getDevicePoints"}
+ "getDevicePropertys": nullEndPoint.Init(), // "/v1/devService/getDevicePropertys"}
+ "getDeviceRepairDetail": nullEndPoint.Init(), // "/v1/devService/getDeviceRepairDetail"}
+ "getDeviceTechBranchCount": nullEndPoint.Init(), // "/v1/devService/getDeviceTechBranchCount"}
+ "getDeviceTypeInfoList": nullEndPoint.Init(), // "/v1/devService/getDeviceTypeInfoList"}
+ "getDeviceTypeList": nullEndPoint.Init(), // "/v1/devService/getDeviceTypeList"}
+ "getDstInfo": nullEndPoint.Init(), // "/v1/userService/getDstInfo"}
+ "getElectricitySettlementData": nullEndPoint.Init(), // "/v1/otherService/getElectricitySettlementData"}
+ "getElectricitySettlementDetailData": nullEndPoint.Init(), // "/v1/otherService/getElectricitySettlementDetailData"}
+ "getEncryptPublicKey": nullEndPoint.Init(), // "/v1/commonService/getEncryptPublicKey"}
+ "getFaultCount": nullEndPoint.Init(), // "/v1/faultService/getFaultCount"}
+ "getFaultDetail": nullEndPoint.Init(), // "/v1/faultService/getFaultDetail"}
+ "getFaultMsgByFaultCode": nullEndPoint.Init(), // "/v1/faultService/getFaultMsgByFaultCode"}
+ "getFaultMsgListByPageWithYYYYMM": nullEndPoint.Init(), // "/v1/faultService/getFaultMsgListByPageWithYYYYMM"}
+ "getFaultMsgListWithYYYYMM": nullEndPoint.Init(), // "/v1/faultService/getFaultMsgListWithYYYYMM"}
+ "getFaultPlanList": nullEndPoint.Init(), // "/v1/faultService/getFaultPlanList"}
+ "getFileOperationRecordOne": nullEndPoint.Init(), // "/v1/commonService/getFileOperationRecordOne"}
+ "getFormulaFaultAnalyseList": nullEndPoint.Init(), // "/v1/powerStationService/getFormulaFaultAnalyseList"}
+ "getGroupStringCheckResult": nullEndPoint.Init(), // "/v1/devService/getGroupStringCheckResult"}
+ "getGroupStringCheckRule": nullEndPoint.Init(), // "/v1/devService/getGroupStringCheckRule"}
+ "getHisData": nullEndPoint.Init(), // "/v1/devService/getHisData"}
+ "getHistoryInfo": nullEndPoint.Init(), // "/v1/powerStationService/getHistoryInfo"}
+ "getHouseholdEvaluation": nullEndPoint.Init(), // "/v1/faultService/getHouseholdEvaluation"}
+ "getHouseholdLeaveMessage": nullEndPoint.Init(), // "/v1/faultService/getHouseholdLeaveMessage"}
+ "getHouseholdOpinionFeedback": nullEndPoint.Init(), // "/v1/faultService/getHouseholdOpinionFeedback"}
+ "getHouseholdPsInstallerByUserId": nullEndPoint.Init(), // "/v1/userService/getHouseholdPsInstallerByUserId"}
+ "getHouseholdStoragePsReport": nullEndPoint.Init(), // "/v1/powerStationService/getHouseholdStoragePsReport"}
+ "getHouseholdUserInfo": nullEndPoint.Init(), // "/v1/userService/getHouseholdUserInfo"}
+ "getHouseholdWorkOrderInfo": nullEndPoint.Init(), // "/v1/faultService/getHouseholdWorkOrderInfo"}
+ "getHouseholdWorkOrderList": nullEndPoint.Init(), // "/v1/faultService/getHouseholdWorkOrderList"}
+ "getI18nConfigByType": nullEndPoint.Init(), // "/integrationService/i18nfile/getI18nConfigByType"}
+ "getI18nFileInfo": nullEndPoint.Init(), // "/integrationService/i18nfile/getI18nFileInfo"}
+ "getI18nInfoByKey": nullEndPoint.Init(), // "/integrationService/i18nfile/getI18nInfoByKey"}
+ "getI18nVersion": nullEndPoint.Init(), // "/integrationService/international/getI18nVersion"}
+ "getIncomeSettingInfos": nullEndPoint.Init(), // "/v1/powerStationService/getIncomeSettingInfos"}
+ "getInfoFromAMap": nullEndPoint.Init(), // "/v1/commonService/getInfoFromAMap"}
+ "getInfomationFromRedis": nullEndPoint.Init(), // "/v1/devService/getInfomationFromRedis"}
+ "getInstallInfoList": nullEndPoint.Init(), // "/v1/orgService/getInstallInfoList"}
+ "getInstallerInfoByDealerOrgCodeOrId": nullEndPoint.Init(), // "/v1/orgService/getInstallerInfoByDealerOrgCodeOrId"}
+ "getInvertDataList": nullEndPoint.Init(), // "/v1/devService/getInvertDataList"}
+ "getInverterDataCount": nullEndPoint.Init(), // "/v1/devService/getInverterDataCount"}
+ "getInverterProcess": nullEndPoint.Init(), // "/v1/devService/getInverterProcess"}
+ "getInverterUuidBytotalId": nullEndPoint.Init(), // "/v1/devService/getInverterUuidBytotalId"}
+ "getIvEchartsData": nullEndPoint.Init(), // "/v1/devService/getIvEchartsData"}
+ "getIvEchartsDataById": nullEndPoint.Init(), // "/v1/devService/getIvEchartsDataById"}
+ "getKpiInfo": nullEndPoint.Init(), // "/v1/powerStationService/getKpiInfo"}
+ "getListMiFromHBase": nullEndPoint.Init(), // "/v1/commonService/getListMiFromHBase"}
+ "getMapInfo": nullEndPoint.Init(), // "/v1/powerStationService/getMapInfo"}
+ "getMapMiFromHBase": nullEndPoint.Init(), // "/v1/commonService/getMapMiFromHBase"}
+ "getMenuAndPrivileges": nullEndPoint.Init(), // "/v1/userService/getMenuAndPrivileges"}
+ "getMicrogridEStoragePsReport": nullEndPoint.Init(), // "/v1/powerStationService/getMicrogridEStoragePsReport"}
+ "getModuleLogInfo": nullEndPoint.Init(), // "/integrationService/getModuleLogInfo"}
+ "getModuleLogTaskList": nullEndPoint.Init(), // "/integrationService/getModuleLogTaskList"}
+ "getNationProvJSON": nullEndPoint.Init(), // "/v1/commonService/getNationProvJSON"}
+ "getNeedOpAsynOpRecordList": nullEndPoint.Init(), // "/v1/commonService/getNeedOpAsynOpRecordList"}
+ "getNoticeInfo": nullEndPoint.Init(), // "/v1/otherService/getNoticeInfo"}
+ "getNumberOfServiceCalls": nullEndPoint.Init(), // "/v1/commonService/getNumberOfServiceCalls"}
+ "getOSSConfig": nullEndPoint.Init(), // "/v1/commonService/getOSSConfig"}
+ "getOperRuleDetail": nullEndPoint.Init(), // "/v1/faultService/getOperRuleDetail"}
+ "getOperateBillFileId": nullEndPoint.Init(), // "/v1/faultService/getOperateBillFileId"}
+ "getOperateTicketForDetail": nullEndPoint.Init(), // "/v1/faultService/getOperateTicketForDetail"}
+ "getOrCreateNetEaseUserToken": nullEndPoint.Init(), // "/v1/userService/getOrCreateNetEaseUserToken"}
+ "getOrderDataList": nullEndPoint.Init(), // "/v1/faultService/getOrderDataList"}
+ "getOrderDataSql2": nullEndPoint.Init(), // "/v1/devService/getOrderDataSql2"}
+ "getOrderDatas": nullEndPoint.Init(), // "/v1/devService/getOrderDatas"}
+ "getOrderDetail": nullEndPoint.Init(), // "/v1/faultService/getOrderDetail"}
+ "getOrderStatistics": nullEndPoint.Init(), // "/v1/faultService/getOrderStatistics"}
+ "getOrgIdNameByUserId": nullEndPoint.Init(), // "/v1/orgService/getOrgIdNameByUserId"}
+ "getOrgInfoByDealerOrgCode": nullEndPoint.Init(), // "/v1/orgService/getOrgInfoByDealerOrgCode"}
+ "getOrgListByName": nullEndPoint.Init(), // "/v1/orgService/getOrgListByName"}
+ "getOrgListByUserId": nullEndPoint.Init(), // "/v1/userService/getOrgListByUserId"}
+ "getOrgListForUser": nullEndPoint.Init(), // "/v1/orgService/getOrgListForUser"}
+ "getOssObjectStream": nullEndPoint.Init(), // "/v1/commonService/getOssObjectStream"}
+ "getOwnerFaultConfigList": nullEndPoint.Init(), // "/v1/faultService/getOwnerFaultConfigList"}
+ "getPListinfoFromMysql": nullEndPoint.Init(), // "/v1/powerStationService/getPListinfoFromMysql"}
+ "getParamSetTemplate4NewProtocol": nullEndPoint.Init(), // "/v1/devService/getParamSetTemplate4NewProtocol"}
+ "getParamSetTemplatePointInfo": nullEndPoint.Init(), // "/v1/devService/getParamSetTemplatePointInfo"}
+ "getParamterSettingBase": nullEndPoint.Init(), // "/v1/devService/getParamterSettingBase"}
+ "getPhotoInfo": nullEndPoint.Init(), // "/v1/otherService/getPhotoInfo"}
+ "getPlanedOrNotPsList": nullEndPoint.Init(), // "/v1/faultService/getPlanedOrNotPsList"}
+ "getPlantReportPDFList": nullEndPoint.Init(), // "/v1/powerStationService/getPlantReportPDFList"}
+ "getPowerChargeSettingInfo": nullEndPoint.Init(), // "/v1/powerStationService/getPowerChargeSettingInfo"}
+ "getPowerDeviceModelTechList": nullEndPoint.Init(), // "/v1/devService/getPowerDeviceModelTechList"}
+ "getPowerDeviceModelTree": nullEndPoint.Init(), // "/v1/devService/getPowerDeviceModelTree"}
+ "getPowerDevicePointInfo": nullEndPoint.Init(), // "/v1/reportService/getPowerDevicePointInfo"}
+ api.GetName(getPowerDevicePointNames.EndPoint{}): getPowerDevicePointNames.Init(),
+ "getPowerDeviceSetTaskDetailList": nullEndPoint.Init(), // "/v1/devService/getPowerDeviceSetTaskDetailList"}
+ "getPowerDeviceSetTaskList": nullEndPoint.Init(), // "/v1/devService/getPowerDeviceSetTaskList"}
+ "getPowerFormulaFaultAnalyse": nullEndPoint.Init(), // "/v1/powerStationService/getPowerFormulaFaultAnalyse"}
+ "getPowerPictureList": nullEndPoint.Init(), // "/v1/powerStationService/getPowerPictureList"}
+ "getPowerRobotInfoByRobotSn": nullEndPoint.Init(), // "/v1/devService/getPowerRobotInfoByRobotSn"}
+ "getPowerRobotSweepAttrByPsId": nullEndPoint.Init(), // "/v1/devService/getPowerRobotSweepAttrByPsId"}
+ "getPowerRobotSweepStrategy": nullEndPoint.Init(), // "/v1/devService/getPowerRobotSweepStrategy"}
+ "getPowerRobotSweepStrategyList": nullEndPoint.Init(), // "/v1/devService/getPowerRobotSweepStrategyList"}
+ "getPowerSettingCharges": nullEndPoint.Init(), // "/v1/powerStationService/getPowerSettingCharges"}
+ "getPowerSettingHistoryRecords": nullEndPoint.Init(), // "/v1/powerStationService/getPowerSettingHistoryRecords"}
+ "getPowerStationBasicInfo": nullEndPoint.Init(), // "/v1/powerStationService/getPowerStationBasicInfo"}
+ "getPowerStationData": nullEndPoint.Init(), // "/v1/powerStationService/getPowerStationData"}
+ "getPowerStationForHousehold": nullEndPoint.Init(), // "/v1/powerStationService/getPowerStationForHousehold"}
+ "getPowerStationInfo": nullEndPoint.Init(), // "/v1/powerStationService/getPowerStationInfo"}
+ "getPowerStationPR": nullEndPoint.Init(), // "/v1/powerStationService/getPowerStationPR"}
+ "getPowerStationTableDataSql": nullEndPoint.Init(), // "/v1/devService/getPowerStationTableDataSql"}
+ "getPowerStationTableDataSqlCount": nullEndPoint.Init(), // "/v1/devService/getPowerStationTableDataSqlCount"}
+ "getPowerStatistics": nullEndPoint.Init(), // "/v1/powerStationService/getPowerStatistics"}
+ "getPowerTrendDayData": nullEndPoint.Init(), // "/v1/powerStationService/getPowerTrendDayData"}
+ "getPrivateCloudValidityPeriod": nullEndPoint.Init(), // "/v1/commonService/getPrivateCloudValidityPeriod"}
+ "getProvInfoListByNationCode": nullEndPoint.Init(), // "/v1/commonService/getProvInfoListByNationCode"}
+ "getPsAuthKey": nullEndPoint.Init(), // "/v1/powerStationService/getPsAuthKey"}
+ "getPsCurveInfo": nullEndPoint.Init(), // "/v1/devService/getPsCurveInfo"}
+ "getPsDataSupplementTaskList": nullEndPoint.Init(), // "/v1/powerStationService/getPsDataSupplementTaskList"}
+ "getPsDetail": nullEndPoint.Init(), // "/v1/powerStationService/getPsDetail"}
+ "getPsDetailByUserTokens": nullEndPoint.Init(), // "/v1/powerStationService/getPsDetailByUserTokens"}
+ "getPsDetailForSinglePage": nullEndPoint.Init(), // "/v1/powerStationService/getPsDetailForSinglePage"}
+ "getPsDetailWithPsType": nullEndPoint.Init(), // "/v1/powerStationService/getPsDetailWithPsType"}
+ "getPsHealthState": nullEndPoint.Init(), // "/v1/powerStationService/getPsHealthState"}
+ "getPsInstallerByPsId": nullEndPoint.Init(), // "/v1/orgService/getPsInstallerByPsId"}
+ "getPsInstallerOrgInfoByPsId": nullEndPoint.Init(), // "/v1/powerStationService/getPsInstallerOrgInfoByPsId"}
+ "getPsList": nullEndPoint.Init(), // "/v1/powerStationService/getPsList"}
+ "getPsListByName": nullEndPoint.Init(), // "/v1/powerStationService/getPsListByName"}
+ "getPsListForPsDataByPsId": nullEndPoint.Init(), // "/v1/powerStationService/getPsListForPsDataByPsId"}
+ "getPsListStaticData": nullEndPoint.Init(), // "/v1/powerStationService/getPsListStaticData"}
+ "getPsReport": nullEndPoint.Init(), // "/v1/reportService/getPsReport"}
+ "getPsUser": nullEndPoint.Init(), // "/v1/userService/getPsUser"}
+ "getPsWeatherList": nullEndPoint.Init(), // "/v1/powerStationService/getPsWeatherList"}
+ "getRechargeOrderDetail": nullEndPoint.Init(), // "/onlinepay/getRechargeOrderDetail"}
+ "getRechargeOrderItemDeviceList": nullEndPoint.Init(), // "/onlinepay/getRechargeOrderItemDeviceList"}
+ "getRechargeOrderList": nullEndPoint.Init(), // "/onlinepay/getRechargeOrderList"}
+ "getRegionalTree": nullEndPoint.Init(), // "/v1/orgService/getRegionalTree"}
+ "getRemoteParamSettingList": nullEndPoint.Init(), // "/v1/devService/getRemoteParamSettingList"}
+ "getRemoteUpgradeDeviceList": nullEndPoint.Init(), // "/v1/devService/getRemoteUpgradeDeviceList"}
+ "getRemoteUpgradeScheduleDetails": nullEndPoint.Init(), // "/v1/devService/getRemoteUpgradeScheduleDetails"}
+ "getRemoteUpgradeSubTasksList": nullEndPoint.Init(), // "/v1/devService/getRemoteUpgradeSubTasksList"}
+ "getRemoteUpgradeTaskList": nullEndPoint.Init(), // "/v1/devService/getRemoteUpgradeTaskList"}
+ "getReportData": nullEndPoint.Init(), // "/v1/powerStationService/getReportData"}
+ "getReportEmailConfigInfo": nullEndPoint.Init(), // "/v1/reportService/getReportEmailConfigInfo"}
+ "getReportExportColumns": nullEndPoint.Init(), // "/v1/reportService/getReportExportColumns"}
+ "getReportListByUserId": nullEndPoint.Init(), // "/v1/reportService/getReportListByUserId"}
+ "getRobotDynamicCleaningView": nullEndPoint.Init(), // "/v1/devService/getRobotDynamicCleaningView"}
+ "getRobotNumAndSweepCapacity": nullEndPoint.Init(), // "/v1/devService/getRobotNumAndSweepCapacity"}
+ "getRuleUnit": nullEndPoint.Init(), // "/v1/powerStationService/getRuleUnit"}
+ "getSendReportConfigCron": nullEndPoint.Init(), // "/v1/reportService/getSendReportConfigCron"}
+ "getSerialNum": nullEndPoint.Init(), // "/v1/devService/getSerialNum"}
+ "getShieldMapConditionList": nullEndPoint.Init(), // "/v1/commonService/getShieldMapConditionList"}
+ "getSimIdBySnList": nullEndPoint.Init(), // "/v1/devService/getSimIdBySnList"}
+ "getSingleIVData": nullEndPoint.Init(), // "/v1/devService/getSingleIVData"}
+ "getSnChangeRecord": nullEndPoint.Init(), // "/v1/devService/getSnChangeRecord"}
+ "getSnConnectionInfo": nullEndPoint.Init(), // "/v1/commonService/getSnConnectionInfo"}
+ "getStationInfoSql": nullEndPoint.Init(), // "/v1/devService/getStationInfoSql"}
+ "getSungwsConfigCache": nullEndPoint.Init(), // "/v1/commonService/getSungwsConfigCache"}
+ "getSungwsGlobalConfigCache": nullEndPoint.Init(), // "/v1/commonService/getSungwsGlobalConfigCache"}
+ "getSweepDevParamSetTemplate": nullEndPoint.Init(), // "/v1/devService/getSweepDevParamSetTemplate"}
+ "getSweepRobotDevList": nullEndPoint.Init(), // "/v1/devService/getSweepRobotDevList"}
+ "getSysMsg": nullEndPoint.Init(), // "/v1/otherService/getSysMsg"}
+ "getSysOrgNewList": nullEndPoint.Init(), // "/v1/otherService/getSysOrgNewList"}
+ "getSysOrgNewOne": nullEndPoint.Init(), // "/v1/otherService/getSysOrgNewOne"}
+ "getSysUserById": nullEndPoint.Init(), // "/v1/userService/getSysUserById"}
+ "getTableDataSql": nullEndPoint.Init(), // "/v1/devService/getTableDataSql"}
+ "getTableDataSqlCount": nullEndPoint.Init(), // "/v1/devService/getTableDataSqlCount"}
+ "getTemplateByInfoType": nullEndPoint.Init(), // "/v1/messageService/getTemplateByInfoType"}
+ "getTemplateList": nullEndPoint.Init(), // "/v1/devService/getTemplateList"}
+ "getUUIDByUpuuid": nullEndPoint.Init(), // "/v1/devService/getUUIDByUpuuid"}
+ "getUpTimePoint": nullEndPoint.Init(), // "/v1/devService/getUpTimePoint"}
+ "getUserById": nullEndPoint.Init(), // "/v1/userService/getUserById"}
+ "getUserByInstaller": nullEndPoint.Init(), // "/v1/userService/getUserByInstaller"}
+ "getUserDevOnlineOffineCount": nullEndPoint.Init(), // "/v1/devService/getUserDevOnlineOffineCount"}
+ "getUserGDPRAttrs": nullEndPoint.Init(), // "/v1/userService/getUserGDPRAttrs"}
+ "getUserHavePowerStationCount": nullEndPoint.Init(), // "/v1/userService/getUserHavePowerStationCount"}
+ "getUserInfoByUserAccounts": nullEndPoint.Init(), // "/v1/userService/getUserInfoByUserAccounts"}
+ "getUserList": nullEndPoint.Init(), // "/v1/userService/getUserList"}
+ "getUserPsOrderList": nullEndPoint.Init(), // "/v1/faultService/getUserPsOrderList"}
+ "getValFromHBase": nullEndPoint.Init(), // "/v1/commonService/getValFromHBase"}
+ "getValidateCode": nullEndPoint.Init(), // "/v1/userService/getValidateCode"}
+ "getValidateCodeAtRegister": nullEndPoint.Init(), // "/v1/userService/getValidateCodeAtRegister"}
+ "getWeatherInfo": nullEndPoint.Init(), // "/v1/powerStationService/getWeatherInfo"}
+ "getWechatPushConfig": nullEndPoint.Init(), // "/v1/userService/getWechatPushConfig"}
+ "getWorkInfo": nullEndPoint.Init(), // "/v1/otherService/getWorkInfo"}
+ "groupStringCheck": nullEndPoint.Init(), // "/v1/devService/groupStringCheck"}
+ "handleDevByCommunicationSN": nullEndPoint.Init(), // "/devDataHandleService/handleDevByCommunicationSN"}
+ "householdResetPassBySN": nullEndPoint.Init(), // "/v1/userService/householdResetPassBySN"}
+ "immediatePayment": nullEndPoint.Init(), // "/onlinepay/immediatePayment"}
+ "importExcelData": nullEndPoint.Init(), // "/v1/devService/importExcelData"}
+ "incomeStatistics": nullEndPoint.Init(), // "/v1/powerStationService/incomeStatistics"}
+ "informPush": nullEndPoint.Init(), // "/v1/messageService/informPush"}
+ "insertEmgOrgInfo": nullEndPoint.Init(), // "/v1/otherService/insertEmgOrgInfo"}
+ "insightSynDeviceStructure2Cloud": nullEndPoint.Init(), // "/v1/powerStationService/insightSynDeviceStructure2Cloud"}
+ "intoDataToHbase": nullEndPoint.Init(), // "/v1/commonService/intoDataToHbase"}
+ "ipLocationQuery": nullEndPoint.Init(), // "/v1/commonService/ipLocationQuery"}
+ "isHave2GSn": nullEndPoint.Init(), // "/v1/devService/isHave2GSn"}
+ "judgeDevIsHasInitSetTemplate": nullEndPoint.Init(), // "/v1/devService/judgeDevIsHasInitSetTemplate"}
+ "judgeIsSettingMan": nullEndPoint.Init(), // "/v1/faultService/judgeIsSettingMan"}
+ "listOssFiles": nullEndPoint.Init(), // "/v1/commonService/listOssFiles"}
+ "loadAreaInfo": nullEndPoint.Init(), // "/v1/commonService/loadAreaInfo"}
+ "loadPowerStation": nullEndPoint.Init(), // "/v1/powerStationService/loadPowerStation"}
+ api.GetName(login.EndPoint{}): login.Init(),
+ "loginByToken": nullEndPoint.Init(), // "/v1/userService/loginByToken"}
+ "logout": nullEndPoint.Init(), // "/v1/userService/logout"}
+ "mobilePhoneHasBound": nullEndPoint.Init(), // "/v1/userService/mobilePhoneHasBound"}
+ "modifiedDeviceInfo": nullEndPoint.Init(), // "/v1/devService/modifiedDeviceInfo"}
+ "modifyEmgOrgStruc": nullEndPoint.Init(), // "/v1/otherService/modifyEmgOrgStruc"}
+ "modifyFaultPlan": nullEndPoint.Init(), // "/v1/faultService/modifyFaultPlan"}
+ "modifyOnDutyInfo": nullEndPoint.Init(), // "/v1/otherService/modifyOnDutyInfo"}
+ "modifyPassword": nullEndPoint.Init(), // "/v1/userService/modifyPassword"}
+ "modifyPersonalUnitList": nullEndPoint.Init(), // "/v1/userService/modifyPersonalUnitList"}
+ "modifyPsUser": nullEndPoint.Init(), // "/v1/userService/modifyPsUser"}
+ "moduleLogParamSet": nullEndPoint.Init(), // "/integrationService/moduleLogParamSet"}
+ "operateOssFile": nullEndPoint.Init(), // "/v1/commonService/operateOssFile"}
+ "operationPowerRobotSweepStrategy": nullEndPoint.Init(), // "/v1/devService/operationPowerRobotSweepStrategy"}
+ "orgPowerReport": nullEndPoint.Init(), // "/v1/orgService/orgPowerReport"}
+ "paramSetTryAgain": nullEndPoint.Init(), // "/v1/devService/paramSetTryAgain"}
+ "paramSetting": nullEndPoint.Init(), // "/v1/devService/paramSetting"}
+ "planPower": nullEndPoint.Init(), // "/v1/powerStationService/planPower"}
+ "powerDevicePointList": nullEndPoint.Init(), // "/v1/reportService/powerDevicePointList"}
+ "powerTrendChartData": nullEndPoint.Init(), // "/v1/powerStationService/powerTrendChartData"}
+ "psForcastInfo": nullEndPoint.Init(), // "/v1/powerStationService/psForcastInfo"}
+ "psHourPointsValue": nullEndPoint.Init(), // "/v1/powerStationService/psHourPointsValue"}
+ "queryAllPsIdAndName": nullEndPoint.Init(), // "/v1/powerStationService/queryAllPsIdAndName"}
+ "queryBatchCreatePsTaskList": nullEndPoint.Init(), // "/v1/powerStationService/queryBatchCreatePsTaskList"}
+ "queryBatchSpeedyAddPowerStationResult": nullEndPoint.Init(), // "/v1/powerStationService/queryBatchSpeedyAddPowerStationResult"}
+ "queryCardStatusCTCC": nullEndPoint.Init(), // "/v1/devService/queryCardStatusCTCC"}
+ "queryChildAccountList": nullEndPoint.Init(), // "/v1/userService/queryChildAccountList"}
+ "queryCompensationRecordData": nullEndPoint.Init(), // "/v1/powerStationService/queryCompensationRecordData"}
+ "queryCompensationRecordList": nullEndPoint.Init(), // "/v1/powerStationService/queryCompensationRecordList"}
+ "queryComponent": nullEndPoint.Init(), // "/v1/devService/queryComponent"}
+ "queryComponentTechnicalParam": nullEndPoint.Init(), // "/v1/devService/queryComponentTechnicalParam"}
+ "queryCountryGridAndRelation": nullEndPoint.Init(), // "/v1/devService/queryCountryGridAndRelation"}
+ "queryCountryList": nullEndPoint.Init(), // "/v1/commonService/queryCountryList"}
+ "queryCtrlTaskById": nullEndPoint.Init(), // "/v1/devService/queryCtrlTaskById"}
+ "queryDeviceInfo": nullEndPoint.Init(), // "/v1/devService/queryDeviceInfoForApp"}
+ "queryDeviceInfoForApp": nullEndPoint.Init(), // "/v1/devService/queryDeviceInfoForApp"}
+ "queryDeviceList": nullEndPoint.Init(), // "/v1/devService/queryDeviceList"}
+ "queryDeviceListByUserId": nullEndPoint.Init(), // "/v1/devService/queryDeviceListByUserId"}
+ "queryDeviceListForApp": nullEndPoint.Init(), // "/v1/devService/queryDeviceListForApp"}
+ "queryDeviceModelTechnical": nullEndPoint.Init(), // "/v1/devService/queryDeviceModelTechnical"}
+ "queryDevicePointDayMonthYearDataList": nullEndPoint.Init(), // "/v1/commonService/queryDevicePointDayMonthYearDataList"}
+ "queryDevicePointMinuteDataList": nullEndPoint.Init(), // "/v1/commonService/queryDevicePointMinuteDataList"}
+ "queryDevicePointsDayMonthYearDataList": nullEndPoint.Init(), // "/v1/commonService/queryDevicePointsDayMonthYearDataList"}
+ "queryDeviceRealTimeDataByPsKeys": nullEndPoint.Init(), // "/v1/devService/queryDeviceRealTimeDataByPsKeys"}
+ "queryDeviceRepairList": nullEndPoint.Init(), // "/v1/devService/queryDeviceRepairList"}
+ "queryDeviceTypeInfoList": nullEndPoint.Init(), // "/v1/devService/queryDeviceTypeInfoList"}
+ "queryEnvironmentList": nullEndPoint.Init(), // "/v1/devService/queryEnvironmentList"}
+ "queryFaultList": nullEndPoint.Init(), // "/v1/faultService/queryFaultList"}
+ "queryFaultPlanDetail": nullEndPoint.Init(), // "/v1/faultService/queryFaultPlanDetail"}
+ "queryFaultRepairSteps": nullEndPoint.Init(), // "/v1/faultService/queryFaultRepairSteps"}
+ "queryFaultTypeAndLevelByCode": nullEndPoint.Init(), // "/v1/faultService/queryFaultTypeAndLevelByCode"}
+ "queryFaultTypeByDevice": nullEndPoint.Init(), // "/v1/faultService/queryFaultTypeByDevice"}
+ "queryFaultTypeByDevicePage": nullEndPoint.Init(), // "/v1/faultService/queryFaultTypeByDevicePage"}
+ "queryFirmwareFilesPage": nullEndPoint.Init(), // "/v1/commonService/queryFirmwareFilesPage"}
+ "queryInfotoAlert": nullEndPoint.Init(), // "/v1/devService/queryInfotoAlert"}
+ "queryInverterModelList": nullEndPoint.Init(), // "/v1/devService/queryInverterModelList"}
+ "queryInverterVersionList": nullEndPoint.Init(), // "/v1/devService/queryInverterVersionList"}
+ "queryM2MCardInfoCMCC": nullEndPoint.Init(), // "/v1/devService/queryM2MCardInfoCMCC"}
+ "queryM2MCardTermInfoCMCC": nullEndPoint.Init(), // "/v1/devService/queryM2MCardTermInfoCMCC"}
+ "queryModelInfoByModelId": nullEndPoint.Init(), // "/v1/devService/queryModelInfoByModelId"}
+ "queryMutiPointDataList": nullEndPoint.Init(), // "/v1/commonService/queryMutiPointDataList"}
+ "queryNoticeList": nullEndPoint.Init(), // "/v1/otherService/queryNoticeList"}
+ "queryNumberOfRenewalReminders": nullEndPoint.Init(), // "/v1/devService/queryNumberOfRenewalReminders"}
+ "queryOperRules": nullEndPoint.Init(), // "/v1/faultService/queryOperRules"}
+ "queryOrderList": nullEndPoint.Init(), // "/v1/faultService/queryOrderList"}
+ "queryOrderStep": nullEndPoint.Init(), // "/v1/faultService/queryOrderStep"}
+ "queryOrgGenerationReport": nullEndPoint.Init(), // "/v1/orgService/queryOrgGenerationReport"}
+ "queryOrgInfoList": nullEndPoint.Init(), // "/v1/userService/queryOrgInfoList"}
+ "queryOrgPowerElecPercent": nullEndPoint.Init(), // "/v1/orgService/queryOrgPowerElecPercent"}
+ "queryOrgPsCompensationRecordList": nullEndPoint.Init(), // "/v1/powerStationService/queryOrgPsCompensationRecordList"}
+ "queryParamSettingTask": nullEndPoint.Init(), // "/v1/devService/queryParamSettingTask"}
+ "queryPersonalUnitList": nullEndPoint.Init(), // "/v1/userService/queryPersonalUnitList"}
+ "queryPointDataTopOne": nullEndPoint.Init(), // "/v1/devService/queryPointDataTopOne"}
+ "queryPowerStationInfo": nullEndPoint.Init(), // "/v1/powerStationService/queryPowerStationInfo"}
+ "queryPsAreaByUserIdAndAreaCode": nullEndPoint.Init(), // "/v1/powerStationService/queryPsAreaByUserIdAndAreaCode"}
+ "queryPsCompensationRecordList": nullEndPoint.Init(), // "/v1/powerStationService/queryPsCompensationRecordList"}
+ "queryPsDataByDate": nullEndPoint.Init(), // "/v1/powerStationService/queryPsDataByDate"}
+ "queryPsIdList": nullEndPoint.Init(), // "/v1/powerStationService/queryPsIdList"}
+ "queryPsListByUserIdAndAreaCode": nullEndPoint.Init(), // "/v1/powerStationService/queryPsListByUserIdAndAreaCode"}
+ "queryPsNameByPsId": nullEndPoint.Init(), // "/v1/devService/queryPsNameByPsId"}
+ "queryPsPrByDate": nullEndPoint.Init(), // "/v1/powerStationService/queryPsPrByDate"}
+ "queryPsProfit": nullEndPoint.Init(), // "/v1/powerStationService/queryPsProfit"}
+ "queryPsReportComparativeAnalysisOfPowerGeneration": nullEndPoint.Init(), // "/v1/powerStationService/queryPsReportComparativeAnalysisOfPowerGeneration"}
+ "queryPsStructureList": nullEndPoint.Init(), // "/v1/devService/queryPsStructureList"}
+ "queryPuuidsByCommandTotalId": nullEndPoint.Init(), // "/v1/devService/queryPuuidsByCommandTotalId"}
+ "queryPuuidsByCommandTotalId2": nullEndPoint.Init(), // "/v1/devService/queryPuuidsByCommandTotalId2"}
+ "queryRepairRuleList": nullEndPoint.Init(), // "/v1/devService/queryRepairRuleList"}
+ "queryReportListForManagementPage": nullEndPoint.Init(), // "/v1/reportService/queryReportListForManagementPage"}
+ "queryReportMsg": nullEndPoint.Init(), // "/v1/reportService/queryReportMsg"}
+ "querySharingPs": nullEndPoint.Init(), // "/v1/powerStationService/querySharingPs"}
+ "querySysAdvancedParam": nullEndPoint.Init(), // "/v1/devService/querySysAdvancedParam"}
+ "queryTimeBySN": nullEndPoint.Init(), // "/v1/devService/queryTimeBySN"}
+ "queryTrafficByDateCTCC": nullEndPoint.Init(), // "/v1/devService/queryTrafficByDateCTCC"}
+ "queryTrafficCTCC": nullEndPoint.Init(), // "/v1/devService/queryTrafficCTCC"}
+ "queryUnitList": nullEndPoint.Init(), // "/v1/userService/queryUnitList"}
+ "queryUnitUuidBytotalId": nullEndPoint.Init(), // "/v1/devService/queryUnitUuidBytotalId"}
+ "queryUserBtnPri": nullEndPoint.Init(), // "/v1/userService/queryUserBtnPri"}
+ "queryUserByUserIds": nullEndPoint.Init(), // "/v1/userService/queryUserByUserIds"}
+ "queryUserExtensionAttribute": nullEndPoint.Init(), // "/v1/userService/queryUserExtensionAttribute"}
+ "queryUserForStep": nullEndPoint.Init(), // "/v1/userService/queryUserForStep"}
+ "queryUserList": nullEndPoint.Init(), // "/v1/userService/queryUserList"}
+ "queryUserProcessPri": nullEndPoint.Init(), // "/v1/userService/queryUserProcessPri"}
+ "queryUserWechatBindRel": nullEndPoint.Init(), // "/v1/userService/queryUserWechatBindRel"}
+ "queryUuidByTotalIdAndUuid": nullEndPoint.Init(), // "/v1/devService/queryUuidByTotalIdAndUuid"}
+ "rechargeOrderSetMeal": nullEndPoint.Init(), // "/v1/devService/rechargeOrderSetMeal"}
+ "renewSendReportConfirmEmail": nullEndPoint.Init(), // "/v1/reportService/renewSendReportConfirmEmail"}
+ "reportList": nullEndPoint.Init(), // "/v1/powerStationService/reportList"}
+ "saveCustomerEmployee": nullEndPoint.Init(), // "/v1/devService/saveCustomerEmployee"}
+ "saveDevSimList": nullEndPoint.Init(), // "/v1/devService/saveDevSimList"}
+ "saveDeviceAccountBatchData": nullEndPoint.Init(), // "/v1/devService/saveDeviceAccountBatchData"}
+ "saveEnviromentIncomeInfos": nullEndPoint.Init(), // "/v1/powerStationService/saveEnviromentIncomeInfos"}
+ "saveEnvironmentCurve": nullEndPoint.Init(), // "/v1/devService/saveEnvironmentCurve"}
+ "saveFirmwareFile": nullEndPoint.Init(), // "/v1/commonService/saveFirmwareFile"}
+ "saveIncomeSettingInfos": nullEndPoint.Init(), // "/v1/powerStationService/saveIncomeSettingInfos"}
+ "saveOrUpdateGroupStringCheckRule": nullEndPoint.Init(), // "/v1/devService/saveOrUpdateGroupStringCheckRule"}
+ "saveParamModel": nullEndPoint.Init(), // "/v1/devService/saveParamModel"}
+ "savePowerCharges": nullEndPoint.Init(), // "/v1/powerStationService/savePowerCharges"}
+ "savePowerDevicePoint": nullEndPoint.Init(), // "/v1/reportService/savePowerDevicePoint"}
+ "savePowerRobotInfo": nullEndPoint.Init(), // "/v1/devService/savePowerRobotInfo"}
+ "savePowerRobotSweepAttr": nullEndPoint.Init(), // "/v1/devService/savePowerRobotSweepAttr"}
+ "savePowerSettingCharges": nullEndPoint.Init(), // "/v1/powerStationService/savePowerSettingCharges"}
+ "savePowerSettingInfo": nullEndPoint.Init(), // "/v1/powerStationService/savePowerSettingInfo"}
+ "saveProductionBatchData": nullEndPoint.Init(), // "/v1/devService/saveProductionBatchData"}
+ "saveRechargeOrderObj": nullEndPoint.Init(), // "/onlinepay/saveRechargeOrderObj"}
+ "saveRechargeOrderOtherInfo": nullEndPoint.Init(), // "/onlinepay/saveRechargeOrderOtherInfo"}
+ "saveRepair": nullEndPoint.Init(), // "/v1/faultService/saveRepair"}
+ "saveReportExportColumns": nullEndPoint.Init(), // "/v1/reportService/saveReportExportColumns"}
+ "saveSetParam": nullEndPoint.Init(), // "/v1/devService/saveSetParam"}
+ "saveSysUserMsg": nullEndPoint.Init(), // "/v1/otherService/saveSysUserMsg"}
+ "saveTemplate": nullEndPoint.Init(), // "/v1/devService/saveTemplate"}
+ "searchM2MMonthFlowCMCC": nullEndPoint.Init(), // "/v1/devService/searchM2MMonthFlowCMCC"}
+ "selectSysTranslationNames": nullEndPoint.Init(), // "/v1/reportService/selectSysTranslationNames"}
+ "sendPsTimeZoneInstruction": nullEndPoint.Init(), // "/devDataHandleService/sendPsTimeZoneInstruction"}
+ "setUpFormulaFaultAnalyse": nullEndPoint.Init(), // "/v1/powerStationService/setUpFormulaFaultAnalyse"}
+ "setUserGDPRAttrs": nullEndPoint.Init(), // "/v1/userService/setUserGDPRAttrs"}
+ "settingNotice": nullEndPoint.Init(), // "/v1/userService/settingNotice"}
+ "shareMyPs": nullEndPoint.Init(), // "/v1/powerStationService/shareMyPs"}
+ "sharePsBySN": nullEndPoint.Init(), // "/v1/powerStationService/sharePsBySN"}
+ "showInverterByUnit": nullEndPoint.Init(), // "/v1/devService/showInverterByUnit"}
+ "showOnlineUsers": nullEndPoint.Init(), // "/v1/userService/showOnlineUsers"}
+ "showWarning": nullEndPoint.Init(), // "/v1/userService/showWarning"}
+ "snIsExist": nullEndPoint.Init(), // "/v1/devService/snIsExist"}
+ "snsIsExist": nullEndPoint.Init(), // "/v1/devService/snsIsExist"}
+ "speedyAddPowerStation": nullEndPoint.Init(), // "/v1/powerStationService/speedyAddPowerStation"}
+ "stationDeviceHistoryDataList": nullEndPoint.Init(), // "/v1/powerStationService/stationDeviceHistoryDataList"}
+ "stationUnitsList": nullEndPoint.Init(), // "/v1/powerStationService/stationUnitsList"}
+ "stationsDiscreteData": nullEndPoint.Init(), // "/v1/devService/stationsDiscreteData"}
+ "stationsIncomeList": nullEndPoint.Init(), // "/v1/powerStationService/stationsIncomeList"}
+ "stationsPointReport": nullEndPoint.Init(), // "/v1/powerStationService/stationsPointReport"}
+ "stationsYearPlanReport": nullEndPoint.Init(), // "/v1/reportService/stationsYearPlanReport"}
+ "sureAndImportSelettlementData": nullEndPoint.Init(), // "/v1/otherService/sureAndImportSelettlementData"}
+ "sweepDevParamSet": nullEndPoint.Init(), // "/v1/devService/sweepDevParamSet"}
+ "sweepDevRunControl": nullEndPoint.Init(), // "/v1/devService/sweepDevRunControl"}
+ "sweepDevStrategyIssue": nullEndPoint.Init(), // "/v1/devService/sweepDevStrategyIssue"}
+ "sysTimeZoneList": nullEndPoint.Init(), // "/v1/commonService/sysTimeZoneList"}
+ "unLockUser": nullEndPoint.Init(), // "/v1/userService/unLockUser"}
+ "unlockChildAccount": nullEndPoint.Init(), // "/v1/userService/unlockChildAccount"}
+ "updateCommunicationModuleState": nullEndPoint.Init(), // "/v1/devService/updateCommunicationModuleState"}
+ "updateDevInstalledPower": nullEndPoint.Init(), // "/v1/devService/updateDevInstalledPower"}
+ "updateFault": nullEndPoint.Init(), // "/v1/faultService/updateFaultStatus"}
+ "updateFaultData": nullEndPoint.Init(), // "/v1/faultService/updateFaultData"}
+ "updateFaultMsgByFaultCode": nullEndPoint.Init(), // "/v1/faultService/updateFaultMsgByFaultCode"}
+ "updateFaultStatus": nullEndPoint.Init(), // "/v1/faultService/updateFaultStatus"}
+ "updateHouseholdWorkOrder": nullEndPoint.Init(), // "/v1/faultService/updateHouseholdWorkOrder"}
+ "updateInverterSn2ModuleSn": nullEndPoint.Init(), // "/devDataHandleService/updateInverterSn2ModuleSn"}
+ "updateOperateTicketAttachmentId": nullEndPoint.Init(), // "/v1/faultService/updateOperateTicketAttachmentId"}
+ "updateOrderDeviceByCustomerService": nullEndPoint.Init(), // "/onlinepay/updateOrderDeviceByCustomerService"}
+ "updateOwnerFaultConfig": nullEndPoint.Init(), // "/v1/faultService/updateOwnerFaultConfig"}
+ "updateParamSettingSysMsg": nullEndPoint.Init(), // "/v1/devService/updateParamSettingSysMsg"}
+ "updatePlatformLevelFaultLevel": nullEndPoint.Init(), // "/v1/faultService/updatePlatformLevelFaultLevel"}
+ "updatePowerDevicePoint": nullEndPoint.Init(), // "/v1/reportService/updatePowerDevicePoint"}
+ "updatePowerRobotInfo": nullEndPoint.Init(), // "/v1/devService/updatePowerRobotInfo"}
+ "updatePowerRobotSweepAttr": nullEndPoint.Init(), // "/v1/devService/updatePowerRobotSweepAttr"}
+ "updatePowerStationForHousehold": nullEndPoint.Init(), // "/v1/powerStationService/updatePowerStationForHousehold"}
+ "updatePowerStationInfo": nullEndPoint.Init(), // "/v1/powerStationService/updatePowerStationInfo"}
+ "updatePowerUserInfo": nullEndPoint.Init(), // "/v1/userService/updatePowerUserInfo"}
+ "updateReportConfigByEmailAddr": nullEndPoint.Init(), // "/v1/reportService/updateReportConfigByEmailAddr"}
+ "updateShareAttr": nullEndPoint.Init(), // "/v1/powerStationService/updateShareAttr"}
+ "updateSnIsSureFlag": nullEndPoint.Init(), // "/devDataHandleService/updateSnIsSureFlag"}
+ "updateStationPics": nullEndPoint.Init(), // "/v1/powerStationService/updateStationPics"}
+ "updateSysAdvancedParam": nullEndPoint.Init(), // "/v1/devService/updateSysAdvancedParam"}
+ "updateSysOrgNew": nullEndPoint.Init(), // "/v1/otherService/updateSysOrgNew"}
+ "updateTemplate": nullEndPoint.Init(), // "/v1/devService/updateDataCurveTemplate"}
+ "updateUinfoNetEaseUser": nullEndPoint.Init(), // "/v1/userService/updateUinfoNetEaseUser"}
+ "updateUserExtensionAttribute": nullEndPoint.Init(), // "/v1/userService/updateUserExtensionAttribute"}
+ "updateUserLanguage": nullEndPoint.Init(), // "/v1/userService/updateUserLanguage"}
+ "updateUserPosition": nullEndPoint.Init(), // "/v1/userService/updateUserPosition"}
+ "updateUserUpOrg": nullEndPoint.Init(), // "/v1/orgService/updateUserUpOrg"}
+ "upgrade": nullEndPoint.Init(), // "/v1/userService/upgrade"}
+ "upgrate": nullEndPoint.Init(), // "/v1/userService/upgrade"}
+ "uploadFileToOss": nullEndPoint.Init(), // "/v1/commonService/uploadFileToOss"}
+ "userAgreeGdprProtocol": nullEndPoint.Init(), // "/v1/userService/userAgreeGdprProtocol"}
+ "userInfoUniqueCheck": nullEndPoint.Init(), // "/v1/userService/userInfoUniqueCheck"}
+ "userMailHasBound": nullEndPoint.Init(), // "/v1/userService/userMailHasBound"}
+ "userRegister": nullEndPoint.Init(), // "/v1/userService/userRegister"}
+ },
+ }
+
+ fmt.Printf("area[%s]: %v\n", name, area)
+
+ return area
+}
+
+func (a Area) Init() api.AreaStruct {
+ panic("implement me")
+}
+
+func (a Area) GetAreaName() api.AreaName {
+ return a.Name
+}
+
+func (a Area) GetEndPoints() api.TypeEndPoints {
+ for _, endpoint := range a.EndPoints {
+ fmt.Printf("endpoint: %v\n", endpoint)
+ }
+ return a.EndPoints
+}
+
+func (a Area) Call(name api.EndPointName) api.Json {
+ panic("implement me")
+}
+
+func (a Area) SetRequest(name api.EndPointName, ref interface{}) error {
+ panic("implement me")
+}
+
+func (a Area) GetRequest(name api.EndPointName) api.Json {
+ panic("implement me")
+}
+
+func (a Area) GetResponse(name api.EndPointName) api.Json {
+ panic("implement me")
+}
+
+func (a Area) GetData(name api.EndPointName) api.Json {
+ panic("implement me")
+}
+
+func (a Area) IsValid(name api.EndPointName) error {
+ panic("implement me")
+}
+
+func (a Area) GetError(name api.EndPointName) error {
+ panic("implement me")
+}
diff --git a/iSolarCloud/MttvScreenService/init.go b/iSolarCloud/sungro/MttvScreenService/init.go
similarity index 98%
rename from iSolarCloud/MttvScreenService/init.go
rename to iSolarCloud/sungro/MttvScreenService/init.go
index 107c2d024..185a695d6 100644
--- a/iSolarCloud/MttvScreenService/init.go
+++ b/iSolarCloud/sungro/MttvScreenService/init.go
@@ -53,5 +53,5 @@ func init() {
p := ref.String()
s := ref.Name()
Area.Name = api.AreaName(strings.TrimSuffix(p, "." + s))
- Area.EndPoints = api.CreateEndPoints(endpoints)
+ // Area.EndPoints = api.CreateEndPoints(endpoints)
}
diff --git a/iSolarCloud/MttvScreenService/pkgreflect.go b/iSolarCloud/sungro/MttvScreenService/pkgreflect.go
similarity index 100%
rename from iSolarCloud/MttvScreenService/pkgreflect.go
rename to iSolarCloud/sungro/MttvScreenService/pkgreflect.go
diff --git a/iSolarCloud/PowerPointService/init.go b/iSolarCloud/sungro/PowerPointService/init.go
similarity index 91%
rename from iSolarCloud/PowerPointService/init.go
rename to iSolarCloud/sungro/PowerPointService/init.go
index 51e166155..324d29aa1 100644
--- a/iSolarCloud/PowerPointService/init.go
+++ b/iSolarCloud/sungro/PowerPointService/init.go
@@ -24,5 +24,5 @@ func init() {
p := ref.String()
s := ref.Name()
Area.Name = api.AreaName(strings.TrimSuffix(p, "." + s))
- Area.EndPoints = api.CreateEndPoints(endpoints)
+ // Area.EndPoints = api.CreateEndPoints(endpoints)
}
diff --git a/iSolarCloud/PowerPointService/pkgreflect.go b/iSolarCloud/sungro/PowerPointService/pkgreflect.go
similarity index 100%
rename from iSolarCloud/PowerPointService/pkgreflect.go
rename to iSolarCloud/sungro/PowerPointService/pkgreflect.go
diff --git a/iSolarCloud/WebAppService/init.go b/iSolarCloud/sungro/WebAppService/init.go
similarity index 99%
rename from iSolarCloud/WebAppService/init.go
rename to iSolarCloud/sungro/WebAppService/init.go
index 26a255d0e..a049fb146 100644
--- a/iSolarCloud/WebAppService/init.go
+++ b/iSolarCloud/sungro/WebAppService/init.go
@@ -212,5 +212,5 @@ func init() {
p := ref.String()
s := ref.Name()
Area.Name = api.AreaName(strings.TrimSuffix(p, "." + s))
- Area.EndPoints = api.CreateEndPoints(endpoints)
+ // Area.EndPoints = api.CreateEndPoints(endpoints)
}
diff --git a/iSolarCloud/WebAppService/pkgreflect.go b/iSolarCloud/sungro/WebAppService/pkgreflect.go
similarity index 100%
rename from iSolarCloud/WebAppService/pkgreflect.go
rename to iSolarCloud/sungro/WebAppService/pkgreflect.go
diff --git a/iSolarCloud/WebIscmAppService/init.go b/iSolarCloud/sungro/WebIscmAppService/init.go
similarity index 99%
rename from iSolarCloud/WebIscmAppService/init.go
rename to iSolarCloud/sungro/WebIscmAppService/init.go
index 14cbacf74..85cdf3f62 100644
--- a/iSolarCloud/WebIscmAppService/init.go
+++ b/iSolarCloud/sungro/WebIscmAppService/init.go
@@ -207,5 +207,5 @@ func init() {
p := ref.String()
s := ref.Name()
Area.Name = api.AreaName(strings.TrimSuffix(p, "." + s))
- Area.EndPoints = api.CreateEndPoints(endpoints)
+ // Area.EndPoints = api.CreateEndPoints(endpoints)
}
diff --git a/iSolarCloud/WebIscmAppService/pkgreflect.go b/iSolarCloud/sungro/WebIscmAppService/pkgreflect.go
similarity index 100%
rename from iSolarCloud/WebIscmAppService/pkgreflect.go
rename to iSolarCloud/sungro/WebIscmAppService/pkgreflect.go
diff --git a/iSolarCloud/sungro/struct.go b/iSolarCloud/sungro/struct.go
new file mode 100644
index 000000000..0e0018f9c
--- /dev/null
+++ b/iSolarCloud/sungro/struct.go
@@ -0,0 +1,88 @@
+package sungro
+
+import (
+ "GoSungro/iSolarCloud/api"
+ "GoSungro/iSolarCloud/sungro/web"
+)
+
+
+type SunGro struct {
+ Web web.Web
+ Error error
+ Areas api.Areas
+ // Areas api.Areas
+ // EndPoints api.TypeEndPoints
+ // OutputString string
+ // OutputArray [][]interface{}
+ // OutputType
+}
+
+
+func NewSunGro(url string) *SunGro {
+ var p SunGro
+
+ p.Error = p.Web.SetUrl(url)
+ // p.OutputType = TypeHuman
+
+ // p.Areas.Domain.Web = &p.Web
+
+ return &p
+}
+
+func (p *SunGro) SetAuth(auth web.SunGroAuth) error {
+ return p.Web.Login(&auth)
+}
+
+func (p *SunGro) GetToken() string {
+ return p.Web.GetToken()
+}
+
+func (p *SunGro) GetTokenExpiry() string {
+ return p.Web.GetTokenExpiry().Format(web.DateTimeFormat)
+}
+
+func (p *SunGro) GetDomain() string {
+ return p.Web.GetDomain()
+}
+func (p *SunGro) VerifyDomain(domain string) string {
+ return p.Web.VerifyDomain(domain)
+}
+
+func (p *SunGro) GetUser() string {
+ return p.Web.GetUser()
+}
+func (p *SunGro) VerifyUser(user string) string {
+ return p.Web.VerifyUser(user)
+}
+
+func (p *SunGro) GetUserMac() string {
+ return p.Web.GetUser()
+}
+func (p *SunGro) VerifyUserMac(user string) string {
+ return p.Web.VerifyUser(user)
+}
+
+func (p *SunGro) GetUsername() string {
+ return p.Web.GetUsername()
+}
+func (p *SunGro) VerifyUsername(user string) string {
+ return p.Web.VerifyUsername(user)
+}
+
+func (p *SunGro) GetUserEmail() string {
+ return p.Web.GetUserEmail()
+}
+func (p *SunGro) VerifyUserEmail(user string) string {
+ return p.Web.VerifyUserEmail(user)
+}
+
+func (p *SunGro) GetDisplayName() string {
+ return p.Web.GetDisplayName()
+}
+func (p *SunGro) VerifyDisplayName(user string) string {
+ return p.Web.VerifyDisplayName(user)
+}
+
+func (p *SunGro) HasTokenChanged() bool {
+ return p.Web.HasTokenChanged()
+}
diff --git a/iSolarCloud/sungro/sungro.go b/iSolarCloud/sungro/sungro.go
new file mode 100644
index 000000000..5b76c54c7
--- /dev/null
+++ b/iSolarCloud/sungro/sungro.go
@@ -0,0 +1,76 @@
+package sungro
+
+import (
+ "GoSungro/Only"
+ "GoSungro/iSolarCloud/api"
+ "GoSungro/iSolarCloud/sungro/AppService"
+ "errors"
+ "fmt"
+ "net/url"
+)
+
+
+func (p *SunGro) Init() error {
+ for range Only.Once {
+ p.Areas = make(api.Areas)
+
+ // p.Areas[AliSmsService.Area.Name] = AliSmsService.Area.EndPoints
+ p.Areas[api.GetArea(AppService.Area{})] = api.AreaStruct(AppService.Init())
+ // p.Areas[MttvScreenService.Area.Name] = MttvScreenService.Area.EndPoints
+ // p.Areas[PowerPointService.Area.Name] = PowerPointService.Area.EndPoints
+ // p.Areas[WebAppService.Area.Name] = WebAppService.Area.EndPoints
+ // p.Areas[WebIscmAppService.Area.Name] = WebIscmAppService.Area.EndPoints
+ }
+
+ return p.Error
+}
+
+func (p *SunGro) AppendUrl(endpoint string) *url.URL {
+ var ret *url.URL
+ for range Only.Once {
+ endpoint = fmt.Sprintf("%s%s", p.Web.Url.String(), endpoint)
+ ret, p.Error = url.Parse(endpoint)
+ if p.Error != nil {
+ break
+ }
+ }
+ return ret
+}
+
+
+func (p *SunGro) GetEndpoint(area string, endpoint string) api.EndPoint {
+ var ret api.EndPoint
+ for range Only.Once {
+ if area == "" {
+ p.Error = errors.New("empty area name")
+ break
+ }
+ if endpoint == "" {
+ p.Error = errors.New("empty endpoint name")
+ break
+ }
+
+ ret = p.Areas.GetEndPoint(api.AreaName(area), api.EndPointName(endpoint))
+ if ret != nil {
+ break
+ }
+
+ p.Error = errors.New("endpoint not found")
+ }
+ return ret
+}
+
+func (p *SunGro) ListEndpoints(area string) error {
+ return p.Areas.ListEndpoints(area)
+}
+
+func (p *SunGro) ListAreas() {
+ p.Areas.ListAreas()
+}
+
+func (p *SunGro) AreaExists(area string) bool {
+ return p.Areas.Exists(area)
+}
+func (p *SunGro) AreaNotExists(area string) bool {
+ return p.Areas.NotExists(area)
+}
diff --git a/iSolarCloud/web/get.go b/iSolarCloud/sungro/web/get.go
similarity index 67%
rename from iSolarCloud/web/get.go
rename to iSolarCloud/sungro/web/get.go
index 8ccd06c6c..5d8920f6b 100644
--- a/iSolarCloud/web/get.go
+++ b/iSolarCloud/sungro/web/get.go
@@ -5,7 +5,6 @@ import (
"encoding/json"
"errors"
"fmt"
- "io/ioutil"
"net/http"
"net/url"
"path/filepath"
@@ -36,191 +35,191 @@ func (w *Web) SetUrl(u string) error {
return w.Error
}
-func (w *Web) GetOLD(s interface{}, url string, args ...interface{}) error {
- for range Only.Once {
- if w.Url == nil {
- w.Error = errors.New("SUNGRO API URL is invalid")
- break
- }
+// func (w *Web) GetOLD(s interface{}, url string, args ...interface{}) error {
+// for range Only.Once {
+// if w.Url == nil {
+// w.Error = errors.New("SUNGRO API URL is invalid")
+// break
+// }
+//
+// url = fmt.Sprintf(w.Url.String()+url, args...)
+//
+// w.request, w.Error = http.NewRequest("GET", url, nil)
+// if w.Error != nil {
+// break
+// }
+//
+// w.request.Header.Set("Authorization", w.Token.GetAuthHeader())
+//
+// //w.response, w.Error = http.Get(url)
+// w.response, w.Error = w.client.Do(w.request)
+// if w.Error != nil {
+// break
+// }
+// //goland:noinspection GoUnhandledErrorResult
+// defer w.response.Body.Close()
+// if w.response.StatusCode != 200 {
+// w.Error = errors.New(fmt.Sprintf("API response is %s", w.response.Status))
+// break
+// }
+//
+// w.Body, w.Error = ioutil.ReadAll(w.response.Body)
+// if w.Error != nil {
+// break
+// }
+//
+// if len(w.Body) == 0 {
+// w.Error = errors.New("empty response")
+// break
+// }
+//
+// w.Error = json.Unmarshal(w.Body, &s)
+// if w.Error != nil {
+// fmt.Printf("ERROR: Body is:\n%s\n", w.Body)
+// break
+// }
+// }
+//
+// return w.Error
+// }
- url = fmt.Sprintf(w.Url.String()+url, args...)
+// func (w *Web) Get(action interface{}, query interface{}, response interface{}) error {
+// for range Only.Once {
+// if w.Url == nil {
+// w.Error = errors.New("SUNGRO API URL is invalid")
+// break
+// }
+//
+// w.Error = VerifyOptionsRequired(query)
+// if w.Error != nil {
+// break
+// }
+//
+// objectName, actionName := GetName(action)
+// //FindInStruct(action, "Request")
+// //FindInStruct(action, "Response")
+//
+// //objectName := GetStructName(object)
+// if objectName == "" {
+// w.Error = errors.New("invalid object name to structure")
+// break
+// }
+//
+// //actionName := GetStructName(action)
+// if objectName == "" {
+// w.Error = errors.New("invalid action name to structure")
+// break
+// }
+//
+// queryString := Query(query)
+// if objectName == "" {
+// w.Error = errors.New("invalid query string for structure")
+// break
+// }
+//
+// u := fmt.Sprintf("%s?format=json&object=%s&action=%s%s",
+// w.Url.String(),
+// objectName,
+// actionName,
+// queryString,
+// )
+// // "?format=json&object=subscriber&action=count"
+//
+// //fmt.Printf("Object: %s\n", objectName)
+// //fmt.Printf("Action: %s\n", actionName)
+// ////fmt.Printf("Action: %s\n", actionName)
+// //fmt.Printf("Query: %s\n", query)
+// //fmt.Printf("ApiUrl: %s\n", url)
+//
+// w.request, w.Error = http.NewRequest("GET", u, nil)
+// if w.Error != nil {
+// break
+// }
+//
+// w.request.Header.Set("Authorization", w.Token.GetAuthHeader())
+//
+// for range Only.Twice {
+// //w.response, w.Error = http.Get(url)
+// w.response, w.Error = w.client.Do(w.request)
+// if w.Error != nil {
+// break
+// }
+//
+// if strings.Contains(w.response.Status, "The access token provided is invalid") {
+// // 401 Unauthorized The access token provided is invalid.
+// // Will first attempt a refresh of the token OR re-login.
+// w.Error = w.Login(nil)
+// if w.Error != nil {
+// w.Error = errors.New(w.response.Status)
+// break
+// }
+// //w.Error = errors.New(fmt.Sprintf("API response is %s", w.response.Status))
+// continue
+// }
+//
+// if w.response.StatusCode == 401 {
+// w.Error = errors.New(w.response.Status)
+// break
+// }
+//
+// // All OK.
+// break
+// }
+// //goland:noinspection GoUnhandledErrorResult
+// defer w.response.Body.Close()
+// if w.Error != nil {
+// break
+// }
+//
+// if w.response.StatusCode != 200 {
+// w.Error = errors.New(fmt.Sprintf("API response is %s", w.response.Status))
+// break
+// }
+//
+// w.Body, w.Error = ioutil.ReadAll(w.response.Body)
+// if w.Error != nil {
+// break
+// }
+//
+// if len(w.Body) == 0 {
+// w.Error = errors.New("empty response")
+// break
+// }
+//
+// w.Error = json.Unmarshal(w.Body, &response)
+// if w.Error != nil {
+// fmt.Printf("ERROR: Body is:\n%s\n", w.Body)
+// break
+// }
+// }
+//
+// return w.Error
+// }
- w.request, w.Error = http.NewRequest("GET", url, nil)
- if w.Error != nil {
- break
- }
-
- w.request.Header.Set("Authorization", w.Token.GetAuthHeader())
-
- //w.response, w.Error = http.Get(url)
- w.response, w.Error = w.client.Do(w.request)
- if w.Error != nil {
- break
- }
- //goland:noinspection GoUnhandledErrorResult
- defer w.response.Body.Close()
- if w.response.StatusCode != 200 {
- w.Error = errors.New(fmt.Sprintf("API response is %s", w.response.Status))
- break
- }
-
- w.Body, w.Error = ioutil.ReadAll(w.response.Body)
- if w.Error != nil {
- break
- }
-
- if len(w.Body) == 0 {
- w.Error = errors.New("empty response")
- break
- }
-
- w.Error = json.Unmarshal(w.Body, &s)
- if w.Error != nil {
- fmt.Printf("ERROR: Body is:\n%s\n", w.Body)
- break
- }
- }
-
- return w.Error
-}
-
-func (w *Web) Get(action interface{}, query interface{}, response interface{}) error {
- for range Only.Once {
- if w.Url == nil {
- w.Error = errors.New("SUNGRO API URL is invalid")
- break
- }
-
- w.Error = VerifyOptionsRequired(query)
- if w.Error != nil {
- break
- }
-
- objectName, actionName := GetName(action)
- //FindInStruct(action, "Request")
- //FindInStruct(action, "Response")
-
- //objectName := GetStructName(object)
- if objectName == "" {
- w.Error = errors.New("invalid object name to structure")
- break
- }
-
- //actionName := GetStructName(action)
- if objectName == "" {
- w.Error = errors.New("invalid action name to structure")
- break
- }
-
- queryString := Query(query)
- if objectName == "" {
- w.Error = errors.New("invalid query string for structure")
- break
- }
-
- u := fmt.Sprintf("%s?format=json&object=%s&action=%s%s",
- w.Url.String(),
- objectName,
- actionName,
- queryString,
- )
- // "?format=json&object=subscriber&action=count"
-
- //fmt.Printf("Object: %s\n", objectName)
- //fmt.Printf("Action: %s\n", actionName)
- ////fmt.Printf("Action: %s\n", actionName)
- //fmt.Printf("Query: %s\n", query)
- //fmt.Printf("ApiUrl: %s\n", url)
-
- w.request, w.Error = http.NewRequest("GET", u, nil)
- if w.Error != nil {
- break
- }
-
- w.request.Header.Set("Authorization", w.Token.GetAuthHeader())
-
- for range Only.Twice {
- //w.response, w.Error = http.Get(url)
- w.response, w.Error = w.client.Do(w.request)
- if w.Error != nil {
- break
- }
-
- if strings.Contains(w.response.Status, "The access token provided is invalid") {
- // 401 Unauthorized The access token provided is invalid.
- // Will first attempt a refresh of the token OR re-login.
- w.Error = w.Login(nil)
- if w.Error != nil {
- w.Error = errors.New(w.response.Status)
- break
- }
- //w.Error = errors.New(fmt.Sprintf("API response is %s", w.response.Status))
- continue
- }
-
- if w.response.StatusCode == 401 {
- w.Error = errors.New(w.response.Status)
- break
- }
-
- // All OK.
- break
- }
- //goland:noinspection GoUnhandledErrorResult
- defer w.response.Body.Close()
- if w.Error != nil {
- break
- }
-
- if w.response.StatusCode != 200 {
- w.Error = errors.New(fmt.Sprintf("API response is %s", w.response.Status))
- break
- }
-
- w.Body, w.Error = ioutil.ReadAll(w.response.Body)
- if w.Error != nil {
- break
- }
-
- if len(w.Body) == 0 {
- w.Error = errors.New("empty response")
- break
- }
-
- w.Error = json.Unmarshal(w.Body, &response)
- if w.Error != nil {
- fmt.Printf("ERROR: Body is:\n%s\n", w.Body)
- break
- }
- }
-
- return w.Error
-}
-
-func Query(i interface{}) string {
- var ret string
-
- s := reflect.ValueOf(i) // .Elem()
- typeOf := s.Type()
- for id := 0; id < s.NumField(); id++ {
- value := fmt.Sprintf("%v", s.Field(id).Interface())
- if value == "" {
- continue
- }
- ret += fmt.Sprintf("&%s=%s",
- typeOf.Field(id).Tag.Get("json"),
- value,
- )
- //fmt.Printf("%d: %s %s = %v\n",
- // i,
- // typeOfT.Field(i).Name,
- // s.Field(i).Type(),
- // s.Field(i).Interface(),
- //)
- }
-
- return ret
-}
+// func Query(i interface{}) string {
+// var ret string
+//
+// s := reflect.ValueOf(i) // .Elem()
+// typeOf := s.Type()
+// for id := 0; id < s.NumField(); id++ {
+// value := fmt.Sprintf("%v", s.Field(id).Interface())
+// if value == "" {
+// continue
+// }
+// ret += fmt.Sprintf("&%s=%s",
+// typeOf.Field(id).Tag.Get("json"),
+// value,
+// )
+// //fmt.Printf("%d: %s %s = %v\n",
+// // i,
+// // typeOfT.Field(i).Name,
+// // s.Field(i).Type(),
+// // s.Field(i).Interface(),
+// //)
+// }
+//
+// return ret
+// }
func PrintHeader(i interface{}) string {
var ret string
diff --git a/iSolarCloud/web/token.go b/iSolarCloud/sungro/web/token.go
similarity index 96%
rename from iSolarCloud/web/token.go
rename to iSolarCloud/sungro/web/token.go
index dd853a890..5233a8398 100644
--- a/iSolarCloud/web/token.go
+++ b/iSolarCloud/sungro/web/token.go
@@ -14,6 +14,7 @@ import (
"time"
)
+
const (
DateTimeFormat = "2006-01-02T15:04:05"
DefaultAuthTokenFile = "SunGroAuthToken.json"
@@ -21,8 +22,8 @@ const (
var (
TokenRequestUrl = "/v1/userService/login"
- GrantPassword = "password"
- GrantRefresh = "refresh_token"
+ // GrantPassword = "password"
+ // GrantRefresh = "refresh_token"
)
type SunGroAuth struct {
@@ -349,23 +350,23 @@ func (t *Token) HasTokenChanged() bool {
return ok
}
-func (t *Token) GetAuthHeader() string {
- var ret string
-
- for range Only.Once {
- //if t.Response.TokenType == "" {
- // break
- //}
- //
- //if t.Response.AccessToken == "" {
- // break
- //}
- //
- //ret = t.Response.TokenType + " " + t.Response.AccessToken
- }
-
- return ret
-}
+// func (t *Token) GetAuthHeader() string {
+// var ret string
+//
+// for range Only.Once {
+// //if t.Response.TokenType == "" {
+// // break
+// //}
+// //
+// //if t.Response.AccessToken == "" {
+// // break
+// //}
+// //
+// //ret = t.Response.TokenType + " " + t.Response.AccessToken
+// }
+//
+// return ret
+// }
func (t *Token) GetToken() string {
//return fmt.Sprintf("%s %s", t.Response.TokenType, t.Response.AccessToken)
diff --git a/iSolarCloud/web/pkgreflect.go b/iSolarCloud/web/pkgreflect.go
deleted file mode 100644
index 543d5cca2..000000000
--- a/iSolarCloud/web/pkgreflect.go
+++ /dev/null
@@ -1,44 +0,0 @@
-// Code generated by github.com/ungerik/pkgreflect DO NOT EDIT.
-
-package web
-
-import "reflect"
-
-var Types = map[string]reflect.Type{
- "Required": reflect.TypeOf((*Required)(nil)).Elem(),
- "SunGroAuth": reflect.TypeOf((*SunGroAuth)(nil)).Elem(),
- "Token": reflect.TypeOf((*Token)(nil)).Elem(),
- "TokenRequest": reflect.TypeOf((*TokenRequest)(nil)).Elem(),
- "TokenResponse": reflect.TypeOf((*TokenResponse)(nil)).Elem(),
- "Web": reflect.TypeOf((*Web)(nil)).Elem(),
-}
-
-var Functions = map[string]reflect.Value{
- "AsArray": reflect.ValueOf(AsArray),
- "FindInStruct": reflect.ValueOf(FindInStruct),
- "GetCmdName2": reflect.ValueOf(GetCmdName2),
- "GetName": reflect.ValueOf(GetName),
- "GetOptionsRequired": reflect.ValueOf(GetOptionsRequired),
- "GetPackageName": reflect.ValueOf(GetPackageName),
- "GetStructName": reflect.ValueOf(GetStructName),
- "GetStructName2": reflect.ValueOf(GetStructName2),
- "HeaderAsArray": reflect.ValueOf(HeaderAsArray),
- "PrintAsJson": reflect.ValueOf(PrintAsJson),
- "PrintHeader": reflect.ValueOf(PrintHeader),
- "PrintValue": reflect.ValueOf(PrintValue),
- "Query": reflect.ValueOf(Query),
- "ReflectAsJson": reflect.ValueOf(ReflectAsJson),
- "VerifyOptionsRequired": reflect.ValueOf(VerifyOptionsRequired),
-}
-
-var Variables = map[string]reflect.Value{
- "GrantPassword": reflect.ValueOf(&GrantPassword),
- "GrantRefresh": reflect.ValueOf(&GrantRefresh),
- "TokenRequestUrl": reflect.ValueOf(&TokenRequestUrl),
-}
-
-var Consts = map[string]reflect.Value{
- "DateTimeFormat": reflect.ValueOf(DateTimeFormat),
- "DefaultAuthTokenFile": reflect.ValueOf(DefaultAuthTokenFile),
-}
-