-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
统一版本接口 #200
base: master
Are you sure you want to change the base?
统一版本接口 #200
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
先看一点,之后抽时间再看
persistence/models/mongo-models/src/ceobe/operation/version/models/modify_state.rs
Outdated
Show resolved
Hide resolved
persistence/models/mongo-models/src/ceobe/operation/version/models/platform.rs
Show resolved
Hide resolved
persistence/dao/ceobe-operate/src/mongo/release_version/create.rs
Outdated
Show resolved
Hide resolved
persistence/models/mongo-models/src/ceobe/operation/version/models/conv.rs
Show resolved
Hide resolved
persistence/models/mongo-models/src/ceobe/operation/version/models/conv.rs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
然后缺少后台的统一的create update read delete的http接口
pub async fn released_version_num( | ||
db: MongoDatabaseOperate, | ||
MapReject(filter): MapRejecter<Json<Option<QueryVersionFilter>>>, | ||
) -> Result<usize> { | ||
let filter = filter.unwrap_or_default(); | ||
let ret = db | ||
.ceobe() | ||
.operation() | ||
.release_version() | ||
.retrieve() | ||
.total_num(filter.platform, filter.yanked) | ||
.await?; | ||
Ok(ret) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
为什么分页总数是单独接口
@@ -0,0 +1,97 @@ | |||
use serde::{Deserialize, Deserializer, Serialize, Serializer}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
包装这个文件是做什么的
#![allow(clippy::manual_unwrap_or_default)] | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这是为啥要加这个
@@ -8,7 +8,7 @@ use sub_model::SubModel; | |||
use typed_builder::TypedBuilder; | |||
|
|||
use crate::{RecordUnit, RecordUnitUpdater, SetRecordUnit}; | |||
|
|||
#[allow(clippy::duplicated_attributes)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这边是什么attribute重复要加这个
@@ -20,5 +22,6 @@ pub(super) fn operation_router() -> ServerRoute { | |||
.nest("/video", video_router()) | |||
.nest("/announcement", announcement_router()) | |||
.nest("/resource", resource_router()) | |||
.nest_controller(ReleaseVersionController, CDN) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
有一说一,感觉这个加法还挺奇怪,是不是应该怎么样标记过这整个router是CDN的,然后把ReleaseVersionController加进来的时候就默认用的是CDN的
统一版本接口