123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344 |
- syntax = "proto3";
- // package声明符,用来防止不同的消息类型有命名冲突
- package v1;
- // 用于生成指定语言go的包名称
- option go_package = "smart-site-management-gateway/pb/v1";
- message LoginRequest {
- string user = 1;
- string password = 2;
- int64 project_id = 3;
- }
- message LoginReply {
- int64 uid = 1;
- bool project_user = 2;
- int64 project_id = 3;
- string user_name = 4;
- }
- message ProjectInfoItem {
- string name = 1;
- string chinese = 2;
- string value = 3;
- }
- message ProjectChangeRequest {
- int64 id = 1;
- repeated ProjectInfoItem list = 2;
- }
- message ProjectChangeReply {
- }
- message ProjectInfoForChangeRequest {
- int64 id = 1;
- }
- message ProjectInfoForChangeReply {
- repeated ProjectInfoItem list = 1;
- }
- message ProjectChangeInfoListRequest {
- int32 page = 1;
- int64 id = 2;
- }
- message ProjectChangeInfoItem {
- repeated ProjectInfoItem origin = 1;
- repeated ProjectInfoItem dst = 2;
- string name = 3;
- string safety_record_no = 4;
- string apply_time = 5;
- string approve_time = 6;
- int32 status = 7;
- string addr = 8;
- }
- message ProjectChangeInfoListReply {
- int64 total = 1;
- int32 page = 2;
- int32 page_size = 3;
- repeated ProjectChangeInfoItem list = 4;
- }
- message DeviceListRequest {
- int64 provider_id = 1;
- // 状态过滤 审核状态 0 待审核 1 项目通过 2 项目未通过
- repeated int32 status_filters = 2;
- int32 page = 3;
- int64 project_id = 4;
- string filter = 5;
- int32 type_code = 6;
- bool is_all = 7;
- bool can_del = 8;
- int64 page_size = 9;
- }
- message DeviceItem {
- int64 id = 1;
- string social_code = 2;
- // 设备类型编码
- int32 type_code = 3;
- string type_name = 4;
- // 申请时间
- string apply_time = 5;
- // 审批时间
- string approve_time = 6;
- // 0 待审核 1 项目通过 2 项目不通过
- int32 status = 7;
- string project_name = 8;
- // 安检备案号
- string safety_record_no = 9;
- // 0 离线 1 在线
- int32 state = 10;
- string sn = 11;
- string key = 12;
- string provider_name = 13;
- string name = 14;
- string channel_name = 15;
- string channel_no = 16;
- }
- message DeviceListReply {
- int64 total = 1;
- int32 page_size = 2;
- int32 page = 3;
- repeated DeviceItem list = 4;
- }
- message DeviceApproveRequest {
- int64 id = 1;
- // true 同意 false 不同意
- bool status = 2;
- string feedback = 3;
- }
- message DeviceApproveReply {
- }
- message ChangePasswdRequest {
- int64 uid = 1;
- string old = 2;
- string new = 3;
- }
- message ChangePasswdReply {
- }
- message ProjectInfoRequest{
- int64 project_id = 1;
- }
- message ProjectInfoReply {
- // 安监备案号
- string safety_record_no = 3;
- // 工程编号
- string project_no = 4;
- // 工程名
- string name = 5;
- // 工程名简称
- string short_name = 6;
- // 项目功能
- string project_function = 7;
- // 项目类型
- string project_type = 8;
- // 工程造价(单位万)
- double price = 9;
- // 工程介绍
- string desc = 10;
- // 项目负责人
- string project_leader = 11;
- // 建筑面积(单位面积)
- double covered_area = 12;
- // 项目负责人电话
- string phone = 13;
- // 总层数
- int32 total_level = 14;
- // 建筑层数 eg:主楼地上23层,地下2层;裙楼地上32层,地下3层
- string building_storey = 15;
- // 施工单位
- string construction = 16;
- // 建设单位
- string development = 17;
- // 监理单位
- string oversee = 18;
- // 设计单位
- string design = 19;
- // 勘察单位
- string exploration = 20;
- // 工程所在地
- string location = 21;
- // 经度
- double lon = 22;
- // 纬度
- double lat = 23;
- // 项目效果图
- string project_effect_pic = 24;
- // 项目平面图
- string project_plan = 25;
- string start_day = 26;
- string end_day = 27;
- }
- message ProjectDeviceStatisticsRequest{
- int64 project_id = 1;
- }
- message ProjectDeviceStatistics{
- // 设备类型
- string device_type = 1;
- // 总数
- int32 total = 2;
- // 在线数
- int32 online = 3;
- }
- message ProjectDeviceStatisticsReply{
- repeated ProjectDeviceStatistics list = 1;
- }
- message ProjectProgressRequest{
- int64 project_id = 1;
- }
- message ProjectProgress{
- // 阶段名
- string name = 1;
- // 预计开始时间
- string expect_start_time = 2;
- // 预计结束时间
- string expect_end_time = 3;
- // 状态 (0 未完工,1 已完成 ,2 进行中)
- int32 status = 4;
- // 阶段图片
- string image = 5;
- // 阶段id
- int64 id = 6;
- // 实际完工时间
- string reality_end_time = 7;
- string reality_start_time = 8;
- }
- message ProjectProgressReply{
- repeated ProjectProgress list = 1;
- // 开工天数
- int64 start_days = 2;
- // 总天数
- int64 total_days = 3;
- // 项目开始时间
- string start_day = 4;
- // 项目结束时间
- string end_day = 5;
- }
- message ProjectProgressAddRequest{
- int64 project_id = 1;
- // 阶段名
- string name = 2;
- // 预计开始时间
- int64 expect_start_time = 3;
- // 预计结束时间
- int64 expect_end_time = 4;
- }
- message ProjectProgressAddReply{
- int64 id = 1;
- }
- message ProjectProgressDelRequest {
- int64 id = 1;
- }
- message ProjectProgressDelReply {
- }
- message ProjectProgressSetRequest{
- // 阶段id
- int64 id = 1;
- // 阶段图片,非毕传
- string image = 2;
- int64 start = 3;
- int64 end = 4;
- }
- message ProjectProgressSetReply{
- }
- message DeviceVideoChannelRequest {
- int64 project_id = 1;
- string sn = 2;
- }
- message DeviceVideoChannelReply {
- string channel_no = 1;
- int64 id = 2;
- int32 state = 3;
- string name = 4;
- }
- message ProjectSetPicRequest {
- // 0 平面图 1 效果图
- int32 pic_type = 1;
- repeated string pic_url = 2;
- int64 project_id = 3;
- }
- message ProjectSetPicReply {
- }
- message ProjectUpdateRequest {
- string name = 1;
- string short_name = 2;
- string location = 3;
- int64 project_id = 4;
- }
- message ProjectUpdateReply {
- }
- message EmailUpdateRequest {
- int64 id = 1;
- string email = 2;
- }
- message EmailUpdateReply {
- }
- message EmailPrepareRequest {
- int64 id = 1;
- string password = 2;
- string email = 3;
- }
- message EmailPrepareReply {
- }
- message PhoneUpdateRequest {
- int64 id = 1;
- string phone = 2;
- }
- message PhoneUpdateReply {
- }
- message UserInfoRequest {
- int64 id = 1;
- }
- message UserInfoReply {
- string email = 1;
- string phone = 2;
- }
|