Added loading of documents thumbnails
This commit is contained in:
@@ -1,18 +1,11 @@
|
||||
import Dinero from "dinero.js";
|
||||
import {
|
||||
Card,
|
||||
CardItem,
|
||||
H3,
|
||||
Text,
|
||||
View,
|
||||
Container,
|
||||
Content,
|
||||
} from "native-base";
|
||||
import { Card, CardItem, H3, Text } from "native-base";
|
||||
import React from "react";
|
||||
import { StyleSheet, RefreshControl, FlatList } from "react-native";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import { FlatList, RefreshControl } from "react-native";
|
||||
import JobNotesItem from "../job-notes-item/job-notes-item.component";
|
||||
|
||||
export default function JobNotes({ job, loading, refetch }) {
|
||||
const { t } = useTranslation();
|
||||
if (!!!job) {
|
||||
<Card>
|
||||
<Text>Job is not defined.</Text>
|
||||
@@ -22,6 +15,14 @@ export default function JobNotes({ job, loading, refetch }) {
|
||||
const onRefresh = async () => {
|
||||
return refetch();
|
||||
};
|
||||
if (job.notes.length === 0)
|
||||
return (
|
||||
<Card>
|
||||
<CardItem>
|
||||
<H3>{t("jobdetail.labels.nojobnotes")}</H3>
|
||||
</CardItem>
|
||||
</Card>
|
||||
);
|
||||
|
||||
return (
|
||||
<FlatList
|
||||
|
||||
Reference in New Issue
Block a user