2025-10-26 12:10:53 +08:00
|
|
|
|
syntax = "proto3";
|
|
|
|
|
|
package phase_server;
|
|
|
|
|
|
|
|
|
|
|
|
service PhaseService {
|
|
|
|
|
|
//获取异常路口
|
|
|
|
|
|
rpc ExceptionPhaseCross (EmptyRequest) returns (ExceptionPhaseCrossResponse);
|
|
|
|
|
|
//异常路口详情列表
|
|
|
|
|
|
rpc ExceptionPhaseCrossInfo (ExceptionPhaseCrossInfoRequest) returns (ExceptionPhaseCrossInfoResponse);
|
|
|
|
|
|
//根据路口ID返回异常配时
|
|
|
|
|
|
rpc ExceptionPhaseByCrossIDs (ExceptionPhaseByCrossIDsRequest) returns (ExceptionPhaseByCrossIDsResponse);
|
|
|
|
|
|
//根据路口ID返回路口配时方案详情
|
|
|
|
|
|
rpc GetCrossPhaseDetailByCrossIDs (GetCrossPhaseDetailByCrossIDsRequest) returns (GetCrossPhaseDetailByCrossIDsResponse);
|
|
|
|
|
|
//获取有配时方案路口列表
|
|
|
|
|
|
rpc GetPhaseCrossID (EmptyRequest) returns (GetPhaseCrossIDResponse);
|
|
|
|
|
|
//获取配时方案协调/非协调方向绿灯时长比
|
|
|
|
|
|
rpc PhaseGreenRatio (PhaseGreenRatioRequest) returns (PhaseGreenRatioResponse);
|
|
|
|
|
|
//获取配时方案协调/非协调方向绿灯时长比
|
|
|
|
|
|
rpc CrossList (CrossListRequest) returns (CrossListResponse);
|
|
|
|
|
|
//依据日期,时刻查询多路口配时方案与相对相位差
|
|
|
|
|
|
rpc QueryCrossPhaseRelativeOffset (QueryCrossPhaseRelativeOffsetRequest) returns (QueryCrossPhaseRelativeOffsetResponse);
|
|
|
|
|
|
//单条绿波配时方案时段与路口配时方案时段校验
|
|
|
|
|
|
rpc GreenWaveCrossPhaseTpCheck (GreenWaveCrossPhaseTpCheckRequest) returns (GreenWaveCrossPhaseTpCheckResponse);
|
|
|
|
|
|
//路口运行中的配时方案
|
|
|
|
|
|
rpc CrossRunningPhase (CrossRunningPhaseRequest) returns (CrossRunningPhaseResponse);
|
|
|
|
|
|
//路口配时方案诊断列表
|
|
|
|
|
|
rpc CrossPhaseDiagnosis (CrossPhaseDiagnosisRequest) returns (CrossPhaseDiagnosisResponse);
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message EmptyRequest {}
|
|
|
|
|
|
|
|
|
|
|
|
message ExceptionPhaseCrossResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
repeated List data = 4;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
int32 nodeid = 1;
|
|
|
|
|
|
string crossid = 2;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message ExceptionPhaseCrossInfoRequest {
|
|
|
|
|
|
repeated int32 citycode = 1;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message ExceptionPhaseCrossInfoResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
int32 total = 3;
|
|
|
|
|
|
int32 cross_total = 4;
|
|
|
|
|
|
repeated List data = 5;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
string crossid = 2;
|
|
|
|
|
|
int32 scheduleid = 3;
|
|
|
|
|
|
int32 planid = 4;
|
|
|
|
|
|
string plan_name = 5;
|
|
|
|
|
|
string tp_start = 6;
|
|
|
|
|
|
string days = 7;
|
|
|
|
|
|
string type = 8;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message ExceptionPhaseByCrossIDsRequest {
|
|
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
repeated string crossid = 2;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message ExceptionPhaseByCrossIDsResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
repeated List data = 5;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
string crossid = 2;
|
|
|
|
|
|
string cross_name = 3;
|
|
|
|
|
|
int32 scheduleid = 4;
|
|
|
|
|
|
int32 planid = 5;
|
|
|
|
|
|
string plan_name = 6;
|
|
|
|
|
|
string tp_start = 7;
|
|
|
|
|
|
string date = 8;
|
|
|
|
|
|
string week = 9;
|
|
|
|
|
|
string type = 10;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message GetCrossPhaseDetailByCrossIDsRequest {
|
|
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
repeated string crossids = 2;
|
|
|
|
|
|
string gw_src_dir = 3;
|
|
|
|
|
|
string tp_start = 4;
|
|
|
|
|
|
string tp_end = 5;
|
|
|
|
|
|
string week = 6;
|
|
|
|
|
|
string wave_id = 7;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message GetCrossPhaseDetailByCrossIDsResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
int32 cycle = 3; //公共周期
|
|
|
|
|
|
repeated List data = 4;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
string crossid = 1;
|
|
|
|
|
|
int32 green_forward = 2; //正向绿灯时长
|
|
|
|
|
|
int32 green_revers = 3; //逆向绿灯时长
|
|
|
|
|
|
int32 offset = 4; //正向相位差
|
|
|
|
|
|
int32 offset_r = 5; //正向相位差
|
|
|
|
|
|
int32 cycle = 6; //周期
|
|
|
|
|
|
int32 day = 7; //天
|
|
|
|
|
|
int32 month = 8; //月
|
|
|
|
|
|
int32 weekday = 9; //周
|
|
|
|
|
|
int32 scheduleid = 10; //计划号
|
|
|
|
|
|
int32 planid = 11; //方案号
|
|
|
|
|
|
string plan_name = 12; //方案名称
|
|
|
|
|
|
int32 coord_phaseid = 13; //协调相位号
|
|
|
|
|
|
string type = 14; //类型:weekday(周),date(特殊日),month(月)
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message GetPhaseCrossIDResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
repeated List data = 3;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
string crossid = 2;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message PhaseGreenRatioRequest {
|
|
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
repeated string crossids = 2;
|
|
|
|
|
|
string gw_src_dir = 3;
|
|
|
|
|
|
string tp_start = 4;
|
|
|
|
|
|
string tp_end = 5;
|
|
|
|
|
|
string week = 6; //周
|
|
|
|
|
|
string wave_id = 7;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message PhaseGreenRatioResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
repeated List data = 3;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
string crossid = 1;
|
|
|
|
|
|
float s2l = 2; //协直/协左
|
|
|
|
|
|
string s2l_remark = 3;
|
|
|
|
|
|
int32 s2l_s_green = 4;
|
|
|
|
|
|
int32 s2l_l_green = 5;
|
|
|
|
|
|
float s2unl = 6; //协直/非协左
|
|
|
|
|
|
string s2unl_remark = 7;
|
|
|
|
|
|
int32 s2unl_s_green = 8;
|
|
|
|
|
|
int32 s2unl_unl_green = 9;
|
|
|
|
|
|
float s2uns = 10; //协直/非协直
|
|
|
|
|
|
string s2uns_remark = 11;
|
|
|
|
|
|
int32 s2uns_s_green = 12;
|
|
|
|
|
|
int32 s2uns_uns_green = 13;
|
|
|
|
|
|
float fwd2rev = 14; //协直正/反
|
|
|
|
|
|
string fwd2rev_remark = 15;
|
|
|
|
|
|
int32 fwd2rev_fwd_green = 16;
|
|
|
|
|
|
int32 fwd2rev_rev_green = 17;
|
|
|
|
|
|
int32 planid = 18; //方案号
|
|
|
|
|
|
int32 day = 19; //天
|
|
|
|
|
|
int32 month = 20; //月
|
|
|
|
|
|
int32 weekday = 21; //周
|
|
|
|
|
|
int32 scheduleid = 22; //计划号
|
|
|
|
|
|
string plan_name = 23; //方案名称
|
|
|
|
|
|
string type = 24; //类型:weekday(周),date(特殊日),month(月)
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message CrossListRequest {
|
|
|
|
|
|
int32 nodeid = 1;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message CrossListResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
repeated List data = 3;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
string crossid = 1;
|
|
|
|
|
|
int32 type = 2;
|
|
|
|
|
|
string name = 3;
|
|
|
|
|
|
string location = 4;
|
|
|
|
|
|
repeated string src_dir = 5;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message QueryCrossPhaseRelativeOffsetRequest {
|
|
|
|
|
|
repeated string crossids = 1;
|
|
|
|
|
|
int32 citycode = 2;
|
|
|
|
|
|
string tp = 3;
|
|
|
|
|
|
string day = 4;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message QueryCrossPhaseRelativeOffsetResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
repeated List data = 3;
|
|
|
|
|
|
message List {
|
|
|
|
|
|
string crossid = 1;
|
|
|
|
|
|
int32 day = 2; //天
|
|
|
|
|
|
int32 month = 3; //月
|
|
|
|
|
|
int32 weekday = 4; //周
|
|
|
|
|
|
int32 scheduleid = 5;
|
|
|
|
|
|
string tp_start = 6;
|
|
|
|
|
|
string control_mode = 7;
|
|
|
|
|
|
int32 planid = 8;
|
|
|
|
|
|
string plan_name = 9;
|
|
|
|
|
|
int32 cycle = 10;
|
|
|
|
|
|
int32 offset = 11;
|
|
|
|
|
|
int32 relative_offset = 12;
|
|
|
|
|
|
string type = 13;
|
|
|
|
|
|
int32 coord_phaseid = 14;
|
|
|
|
|
|
repeated stage_data stages = 15;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message stage_data {
|
|
|
|
|
|
int32 stageid = 1;
|
|
|
|
|
|
string stage_name = 2;
|
|
|
|
|
|
int32 stage_duration = 3;
|
|
|
|
|
|
int32 green = 4;
|
|
|
|
|
|
int32 yellow = 5;
|
|
|
|
|
|
int32 allred = 6;
|
|
|
|
|
|
int32 redyellow = 7;
|
|
|
|
|
|
string phaseids = 8;
|
|
|
|
|
|
string phaseid_names = 9;
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message GreenWaveCrossPhaseTpCheckRequest {
|
|
|
|
|
|
string waveid = 1;
|
|
|
|
|
|
int32 citycode = 2;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message GreenWaveCrossPhaseTpCheckResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message CrossRunningPhaseRequest {
|
|
|
|
|
|
int32 citycode = 1;
|
2025-10-27 15:53:34 +08:00
|
|
|
|
repeated string date_list = 2;
|
|
|
|
|
|
string tp = 3;
|
|
|
|
|
|
repeated string crossids = 4;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message CrossRunningPhaseResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
2025-10-27 18:51:24 +08:00
|
|
|
|
repeated List data = 3;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
message List {
|
2025-10-27 18:51:24 +08:00
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
string crossid = 2;
|
|
|
|
|
|
string jj_crossid = 3;
|
|
|
|
|
|
int32 scheduleid = 4;
|
|
|
|
|
|
string schedule_week = 5;
|
|
|
|
|
|
string schedule_name = 6;
|
2025-10-27 15:53:34 +08:00
|
|
|
|
repeated tps_list tps = 7;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
2025-10-27 15:53:34 +08:00
|
|
|
|
message tps_list {
|
2025-10-27 18:51:24 +08:00
|
|
|
|
string tp_start = 1;
|
|
|
|
|
|
string tp_end = 2;
|
|
|
|
|
|
int32 planid = 3;
|
|
|
|
|
|
string plan_name = 4;
|
|
|
|
|
|
string control_mode = 5;
|
|
|
|
|
|
int32 cycle = 6;
|
|
|
|
|
|
int32 coord_phaseid = 7;
|
|
|
|
|
|
int32 offset = 8;
|
|
|
|
|
|
repeated stages stage_list = 9;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
|
|
|
|
|
message stages {
|
2025-10-27 18:51:24 +08:00
|
|
|
|
int32 stageid = 1;
|
|
|
|
|
|
int32 stage_duration = 2;
|
|
|
|
|
|
string stage_name = 3;
|
|
|
|
|
|
int32 green = 4;
|
|
|
|
|
|
int32 yellow = 5;
|
|
|
|
|
|
int32 allred = 6;
|
|
|
|
|
|
string phases = 7;
|
|
|
|
|
|
string phases_name = 8;
|
2025-10-27 15:53:34 +08:00
|
|
|
|
int32 min_green = 9;
|
|
|
|
|
|
int32 max_green = 10;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message CrossPhaseDiagnosisRequest {
|
|
|
|
|
|
int32 citycode = 1;
|
|
|
|
|
|
string crossid = 2;
|
2025-10-27 18:51:24 +08:00
|
|
|
|
string tp = 3;
|
|
|
|
|
|
repeated string date_list = 4;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message CrossPhaseDiagnosisResponse {
|
|
|
|
|
|
int32 code = 1;
|
|
|
|
|
|
string msg = 2;
|
2025-10-27 15:53:34 +08:00
|
|
|
|
List data = 3;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
message List {
|
|
|
|
|
|
string item = 1;
|
2025-10-27 15:53:34 +08:00
|
|
|
|
repeated details values = 2;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
2025-10-27 15:53:34 +08:00
|
|
|
|
|
2025-10-26 12:10:53 +08:00
|
|
|
|
message details {
|
2025-10-27 15:53:34 +08:00
|
|
|
|
string item = 1;
|
|
|
|
|
|
repeated item_detail detail = 2;
|
|
|
|
|
|
repeated item_suggestions suggestions = 3;
|
|
|
|
|
|
string reason = 4;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
2025-10-27 15:53:34 +08:00
|
|
|
|
|
2025-10-26 12:10:53 +08:00
|
|
|
|
message item_detail {
|
2025-10-27 20:08:57 +08:00
|
|
|
|
string src_dir = 1;
|
|
|
|
|
|
repeated detail_value child_detail = 2;
|
2025-10-27 15:53:34 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message item_suggestions {
|
2025-10-27 19:42:46 +08:00
|
|
|
|
repeated detail_value child_detail = 1;
|
2025-10-27 18:51:24 +08:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
message detail_value {
|
2025-10-27 15:53:34 +08:00
|
|
|
|
string text = 1;
|
2025-10-27 18:51:24 +08:00
|
|
|
|
string color = 2;
|
|
|
|
|
|
int32 scheduleid = 3;
|
|
|
|
|
|
string crossid = 4;
|
|
|
|
|
|
string tp_start = 5;
|
2025-10-26 12:10:53 +08:00
|
|
|
|
}
|
|
|
|
|
|
}
|