-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Closed
Labels
Awaiting PaymentAuto-added when associated PR is deployed to productionAuto-added when associated PR is deployed to productionDailyKSv2KSv2ExternalAdded to denote the issue can be worked on by a contributorAdded to denote the issue can be worked on by a contributorNewFeatureSomething to build that is a new item.Something to build that is a new item.
Description
Relevant Background - High-level
Notes for completeness:
Notetype violations are largely “informational ” and arise from “Receipt Audit” (e.g. we scan the receipt, whether or not the employee does).Notetype violations do not generate an RBR in the LHN for admins or members, because notes are informational and there is nothing for either admin or member to fix. However, we will do the following:- Update the dot separator sub-state for the request preview with
Review required- Note: Once the report moves to either an
approvedorreimbursedstate, whichever comes first, theReview requiredis removed as a sub-state. This is because while the informational note remains, there is never anything in particular to resolve or dismiss, like other violations.
- Note: Once the report moves to either an
- Update the dot separator sub-state for the request preview with
- If a receipt exists on a request and workspace where Receipt Auditing scans the receipt information in the background, Receipt Audit will appear immediately below the receipt image.
- Receipt Audit is shown in the “supporting text” color, along with a summary of how many (or no) issues were found
- If one or more issues exist, an icon of a paper/magnifying glass appear to the left of the text:
Receipt Audit * %numIssues% issues found(note: “issue” is singular if only one issue). - If no issues exist, an icon of a paper overlaid with a check mark appear to the left of the text:
Receipt Audit * no issues found
- If one or more issues exist, an icon of a paper/magnifying glass appear to the left of the text:
Detailed (Note: This is outdated and proposals should note suggested updates)
We’ll update src/components/ReportActionItem/MoneyRequestView.js with a similar approach we took for showing inline violations
- Under
{hasReceipt && ( <View style={styles.moneyRequestViewImage}> - We’ll add a new component ReceiptAudit and pass a prop
noteswith the value transactionVioltions.notice - That value will be an array with the notices for the transaction.
- If the array is empty, we’ll show the green we’ll show
Receipt Verified No issues found - Otherwise, we’ll show 🔎
Receipt Audit N issues found, and the copy of the notices in red below <ReceiptAudit notice={transactionViolation.notice} />- Here’s a POC version of that component
- Note: we need to add translations for “X issues found” and “No Issues found”
import Icon from './Icon';
import PropTypes from 'prop-types';
const propTypes = {
notice: PropTypes.arrayOf(PropTypes.string).required
};
const defaultProps = {
notice: [],
};
function ReceiptAudit(notice) {
debugger;
return (
<>
<Icon width={32} height={32} src={notice.length > 0 ? Expensicons.Receipt : Expensicons.Checkmark} />
<Text>
Receipt Audit • {notice.length > 0 ? `${notice.length} Issue(s) Found` : 'No issues Found'}
</Text>
</>
);
}```
<details><summary>Upwork Automation - Do Not Edit</summary>
<ul>
<li>Upwork Job URL: https://www.upwork.com/jobs/~019f84ef0521d4c9c9</li>
<li>Upwork Job ID: 1756094841883127808</li>
<li>Last Price Increase: 2024-02-23</li>
<li>Automatic offers: </li>
<ul>
<li>Krishna2323 | Contributor | 0</li>
</ul></li>
</ul>
</details>
<details><summary>Issue Owner</summary>Current Issue Owner: @JmillsExpensify</details>
Metadata
Metadata
Labels
Awaiting PaymentAuto-added when associated PR is deployed to productionAuto-added when associated PR is deployed to productionDailyKSv2KSv2ExternalAdded to denote the issue can be worked on by a contributorAdded to denote the issue can be worked on by a contributorNewFeatureSomething to build that is a new item.Something to build that is a new item.
Type
Projects
Status
Done
