CFE-18 Merge branch 'feature/CFE-18_description_call_history' into 'develop'
This commit is contained in:
@@ -262,7 +262,8 @@
|
|||||||
"call_history_not_found": "تاریخچه ای برای تماس دریافتی یافت نشد",
|
"call_history_not_found": "تاریخچه ای برای تماس دریافتی یافت نشد",
|
||||||
"call_history_error_fetching": "خطا در دریافت تاریخچه تماس دریافتی",
|
"call_history_error_fetching": "خطا در دریافت تاریخچه تماس دریافتی",
|
||||||
"show_more": "نمایش موارد بیشتر",
|
"show_more": "نمایش موارد بیشتر",
|
||||||
"no_data_exist": "اطلاعاتی موجود نیست"
|
"no_data_exist": "اطلاعاتی موجود نیست",
|
||||||
|
"description": "توضیحات"
|
||||||
},
|
},
|
||||||
"CallAction": {
|
"CallAction": {
|
||||||
"call_history_of": "عملیات های مربوط به تماس",
|
"call_history_of": "عملیات های مربوط به تماس",
|
||||||
|
|||||||
@@ -6,7 +6,8 @@ describe("Topics Component From call history", () => {
|
|||||||
describe("Rendering", () => {
|
describe("Rendering", () => {
|
||||||
const historyItem = {
|
const historyItem = {
|
||||||
category_name: "test category",
|
category_name: "test category",
|
||||||
subcategory_name: "test sub category"
|
subcategory_name: "test sub category",
|
||||||
|
description: "test desc"
|
||||||
}
|
}
|
||||||
it("operator name rendered", () => {
|
it("operator name rendered", () => {
|
||||||
render(<MockAppWithProviders><Topics historyItem={historyItem}/></MockAppWithProviders>);
|
render(<MockAppWithProviders><Topics historyItem={historyItem}/></MockAppWithProviders>);
|
||||||
@@ -18,5 +19,10 @@ describe("Topics Component From call history", () => {
|
|||||||
const operatorAnswerDate = screen.queryByText("test sub category");
|
const operatorAnswerDate = screen.queryByText("test sub category");
|
||||||
expect(operatorAnswerDate).toBeInTheDocument();
|
expect(operatorAnswerDate).toBeInTheDocument();
|
||||||
});
|
});
|
||||||
|
it("operator description rendered", () => {
|
||||||
|
render(<MockAppWithProviders><Topics historyItem={historyItem}/></MockAppWithProviders>);
|
||||||
|
const operatorAnswerDate = screen.queryByText("test desc");
|
||||||
|
expect(operatorAnswerDate).toBeInTheDocument();
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@@ -36,6 +36,19 @@ const Topics = ({historyItem}) => {
|
|||||||
</Box>
|
</Box>
|
||||||
</ListItem>
|
</ListItem>
|
||||||
</List>
|
</List>
|
||||||
|
{historyItem.description ? <List component="div" disablePadding>
|
||||||
|
<ListItem sx={{px: 4}}>
|
||||||
|
<Box sx={{width: "100%", display: "flex", flexDirection: "column"}}>
|
||||||
|
<Typography variant="subtitle2" sx={{color: "#837e7e"}}>
|
||||||
|
{t("CallHistory.description")}:
|
||||||
|
</Typography>
|
||||||
|
<Typography variant="subtitle2" sx={{color: "#837e7e", px: 2}}>
|
||||||
|
{historyItem.description}
|
||||||
|
</Typography>
|
||||||
|
</Box>
|
||||||
|
</ListItem>
|
||||||
|
</List> : ""}
|
||||||
|
|
||||||
</Box>
|
</Box>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user