This commit is contained in:
Billy Chan 2022-12-16 16:48:16 +08:00
parent 596afd2081
commit ccca35ab1a
No known key found for this signature in database
GPG Key ID: A2D690CAC7DF3CC7
3 changed files with 6 additions and 6 deletions

View File

@ -202,8 +202,8 @@ impl EntityTransformer {
} }
Ok(EntityWriter { Ok(EntityWriter {
entities: entities entities: entities
.into_iter() .into_values()
.map(|(_, mut v)| { .map(|mut v| {
v.relations.sort_by(|a, b| a.ref_table.cmp(&b.ref_table)); v.relations.sort_by(|a, b| a.ref_table.cmp(&b.ref_table));
v v
}) })

View File

@ -225,8 +225,8 @@ impl EntityWriter {
lines.push("".to_owned()); lines.push("".to_owned());
let code_blocks = self let code_blocks = self
.enums .enums
.iter() .values()
.map(|(_, active_enum)| active_enum.impl_active_enum(with_serde, with_copy_enums)) .map(|active_enum| active_enum.impl_active_enum(with_serde, with_copy_enums))
.collect(); .collect();
Self::write(&mut lines, code_blocks); Self::write(&mut lines, code_blocks);
OutputFile { OutputFile {

View File

@ -45,8 +45,8 @@ where
let query = self let query = self
.query .query
.clone() .clone()
.limit(self.page_size as u64) .limit(self.page_size)
.offset((self.page_size * page) as u64) .offset(self.page_size * page)
.to_owned(); .to_owned();
let builder = self.db.get_database_backend(); let builder = self.db.get_database_backend();
let stmt = builder.build(&query); let stmt = builder.build(&query);