table.proto 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. syntax = "proto3";
  2. // required和optional都不再支持,默认optional;
  3. // 用户表;
  4. message tb_customer{
  5. string customer_id = 1; // id;
  6. string customer_name = 2; // 昵称;
  7. bool customer_gender = 3; // 性别;
  8. string customer_phone = 4; // 手机;
  9. string customer_password = 5; // 登录密码;
  10. string customer_old_phone = 6; // 旧手机;
  11. string customer_vcode = 7; // 验证码;
  12. string customer_vcode_expiry_time = 8; // 验证码有效期;
  13. bool customer_enable = 9; // 是否启用;
  14. string customer_gen_time = 10; // 生成日期;
  15. }
  16. // 回复类型表;
  17. message tb_type{
  18. string customer_id = 1; // 用户id;
  19. string type_id = 2; // 类型id;
  20. string type_name = 3; // 类型名称;
  21. string type_gen_time = 4; // 生成日期;
  22. }
  23. // 回复详情表;
  24. message tb_reply{
  25. string type_id = 1; // 类型id;
  26. string reply_name = 2; // 回复名称;
  27. string reply_content = 3; // 回复内容;
  28. string reply_gen_time = 4; // 生成日期;
  29. }
  30. // 用户表记录
  31. message rec_customer{
  32. repeated tb_customer customers = 1;
  33. }
  34. // 类型表记录;
  35. message rec_type{
  36. repeated tb_type types = 1;
  37. }
  38. // 回复详情记录;
  39. message rec_reply {
  40. repeated tb_reply replys = 1;
  41. }
  42. // 顾客全部数据;
  43. message view{
  44. tb_customer customer = 1;
  45. rec_type types = 2;
  46. rec_reply replys = 3;
  47. }