Skip to content

Commit

Permalink
Fix/新增文件名/文件类型排序/新增文件类别筛选 (#145)
Browse files Browse the repository at this point in the history
  • Loading branch information
Love-YeLin authored Mar 25, 2024
1 parent e6734f0 commit 81e1341
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
5 changes: 5 additions & 0 deletions cloudmind/content/common.proto
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ enum SortOptions{
SortOptions_createAtAsc = 2; // 创建时间排序
SortOptions_updateAtDesc = 3; // 修改时间排序
SortOptions_updateAtAsc = 4; // 修改时间排序
SortOptions_NameDesc = 5; // 文件名逆序
SortOptions_NameAsc = 6; // 文件名升序
SortOptions_TypeDesc = 7; // 文件类型逆序
SortOptions_TypeAsc = 8; // 文件类型升序
}

enum Deletion {
Expand Down Expand Up @@ -75,6 +79,7 @@ message File {
string subZone = 11;
string description = 12;
repeated string labels = 13;
int64 category = 14;
}

message FileParameter {
Expand Down
15 changes: 8 additions & 7 deletions cloudmind/core_api/content.proto
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ message GetPublicFileResp{

message GetPrivateFilesReq{
optional string allFieldsKey = 1;
optional string name = 2;
optional string name = 2[(http.vd) = "len($) >= 1 && len($) <= 100"];
optional string id = 3;
optional int64 sortType = 4;
optional string onlyFatherId = 5;
Expand All @@ -65,7 +65,7 @@ message GetPrivateFilesReq{
optional string lastToken = 8;
optional bool backward = 9;
optional int64 offset = 10;
optional int64 onlyCategory = 11;
optional int64 onlyCategory = 11[(http.vd) = "$ >= 1 && $ <= 4"];
}

message GetPrivateFilesResp{
Expand All @@ -78,7 +78,7 @@ message GetPrivateFilesResp{

message GetPublicFilesReq{
optional string allFieldsKey = 1;
optional string name = 2;
optional string name = 2[(http.vd) = "len($) >= 1 && len($) <= 100"];
optional string id = 3;
optional string description = 4;
optional int64 sortType = 5;
Expand Down Expand Up @@ -135,11 +135,12 @@ message GetFileBySharingCodeResp{
}

message CreateFileReq{
string name = 1;
string name = 1[(http.vd) = "len($) >= 1 && len($) <= 100"];
string type = 2;
string fatherId = 3;
optional int64 spaceSize = 4;
string md5 = 5;
int64 category = 6;
}

message CreateFileResp{
Expand All @@ -149,7 +150,7 @@ message CreateFileResp{

message UpdateFileReq{
string fileId = 1;
string name = 2;
string name = 2[(http.vd) = "len($) >= 1 && len($) <= 100"];
}

message UpdateFileResp{
Expand Down Expand Up @@ -263,7 +264,7 @@ message DeleteZoneResp {
}

message CreateShareCodeReq {
string name = 1;
string name = 1[(http.vd) = "len($) >= 1 && len($) <= 100"];
int64 effectiveTime = 2;
repeated string fileList = 3;
}
Expand Down Expand Up @@ -311,7 +312,7 @@ message ParsingShareCodeResp {
}

message AskUploadFileReq {
string name = 1;
string name = 1[(http.vd) = "len($) >= 1 && len($) <= 100"];
int64 fileSize = 2;
}

Expand Down

0 comments on commit 81e1341

Please sign in to comment.