fix: estimates bugs (#785)

* fix: dashboard workspace activity mutation

* fix: minor bugs
This commit is contained in:
Aaryan Khandelwal 2023-04-11 18:17:47 +05:30 committed by GitHub
parent 61b9e7a161
commit f1f716e8f6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 9 deletions

View File

@ -337,7 +337,7 @@ export const EstimatePointsModal: React.FC<Props> = ({ isOpen, data, estimate, o
<div className="mt-5 flex justify-end gap-2">
<SecondaryButton onClick={() => handleClose()}>Cancel</SecondaryButton>
<PrimaryButton type="submit" loading={isSubmitting}>
{data
{data && data.length > 0
? isSubmitting
? "Updating Points..."
: "Update Points"

View File

@ -107,14 +107,16 @@ export const SingleEstimate: React.FC<Props> = ({
</p>
</div>
<CustomMenu ellipsis>
{projectDetails?.estimate !== estimate.id && (
<CustomMenu.MenuItem onClick={handleUseEstimate}>
<div className="flex items-center justify-start gap-2">
<SquaresPlusIcon className="h-3.5 w-3.5" />
<span>Use estimate</span>
</div>
</CustomMenu.MenuItem>
)}
{projectDetails?.estimate !== estimate.id &&
estimatePoints &&
estimatePoints.length > 0 && (
<CustomMenu.MenuItem onClick={handleUseEstimate}>
<div className="flex items-center justify-start gap-2">
<SquaresPlusIcon className="h-3.5 w-3.5" />
<span>Use estimate</span>
</div>
</CustomMenu.MenuItem>
)}
<CustomMenu.MenuItem onClick={() => setIsEstimatePointsModalOpen(true)}>
<div className="flex items-center justify-start gap-2">
<ListBulletIcon className="h-3.5 w-3.5" />