wekan_cli/command_result/
lists.rs1use serde::Serialize;
2use serde_json::Number;
3
4#[derive(Clone, Debug, Eq, PartialEq, Serialize)]
5pub struct ListSummary {
6 pub list_id: String,
7 pub title: String,
8 pub modified_at: Option<String>,
9 pub cards_modified_at: Option<String>,
10}
11
12#[derive(Debug, Eq, PartialEq, Serialize)]
13pub struct ListCollectionSuccess {
14 pub board_id: String,
15 pub lists: Vec<ListSummary>,
16}
17
18#[derive(Clone, Debug, Eq, PartialEq, Serialize)]
19pub struct ListWipLimitDetail {
20 pub value: Number,
21 pub enabled: bool,
22 pub soft: bool,
23}
24
25#[derive(Clone, Debug, Eq, PartialEq, Serialize)]
26pub struct ListDetail {
27 pub list_id: String,
28 pub title: String,
29 pub watchers: Option<Vec<String>>,
30 pub starred: Option<bool>,
31 pub archived: bool,
32 pub archived_at: Option<String>,
33 pub deleted_at: Option<String>,
34 pub deleted_by: Option<String>,
35 pub delete_batch_id: Option<String>,
36 pub board_id: String,
37 pub swimlane_id: Option<String>,
38 pub created_at: String,
39 pub sort: Option<Number>,
40 pub updated_at: Option<String>,
41 pub modified_at: String,
42 pub position_updated_at: Option<String>,
43 pub wip_limit: Option<ListWipLimitDetail>,
44 pub color: Option<String>,
45 pub list_type: String,
46 pub width: Option<Number>,
47}
48
49#[derive(Debug, Eq, PartialEq, Serialize)]
50pub struct ListCreateSuccess {
51 pub board_id: String,
52 pub list_id: String,
53}
54
55#[derive(Clone, Copy, Debug, Eq, PartialEq, Serialize)]
56#[serde(rename_all = "snake_case")]
57pub enum ListUpdatedField {
58 Title,
59 Color,
60 Starred,
61 WipLimit,
62}
63
64#[derive(Debug, Eq, PartialEq, Serialize)]
65pub struct ListUpdateSuccess {
66 pub board_id: String,
67 pub list_id: String,
68 pub updated_fields: Vec<ListUpdatedField>,
69}
70
71#[derive(Clone, Copy, Debug, Eq, PartialEq, Serialize)]
72#[serde(rename_all = "snake_case")]
73pub enum ListDeleteMode {
74 Soft,
75}
76
77#[derive(Debug, Eq, PartialEq, Serialize)]
78pub struct ListDeleteSuccess {
79 pub board_id: String,
80 pub list_id: String,
81 pub deletion_requested: bool,
82 pub delete_mode: ListDeleteMode,
83}
84
85#[derive(Debug, Eq, PartialEq, Serialize)]
86pub struct ListTransferSuccess {
87 pub source_board_id: String,
88 pub source_list_id: String,
89 pub target_board_id: String,
90 pub target_swimlane_id: Option<String>,
91 pub returned_list_id: String,
92}