Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TNO-2056 Update report edit story #1469

Merged
merged 1 commit into from
Jan 31, 2024
Merged

TNO-2056 Update report edit story #1469

merged 1 commit into from
Jan 31, 2024

Conversation

Fosol
Copy link
Collaborator

@Fosol Fosol commented Jan 31, 2024

Subscriber reports now use a column approach when editing content. There is still more work to do on this functionality, but the basic workflow is coming together.

TODO

  • Resolve WYSIWYG issue
  • Hide form when moving to another tab
  • Add Previous/Next buttons on form to move through content quickly
  • Highlight the active row
  • Update styling to match Bobbi's UI

Summary

  • Published tno-core:0.1.23
  • Updated Subscriber app

Edit Report (Existing Content)

image

Edit Report (Add Content)

image

@Fosol Fosol added enhancement New feature or request subscriber PR contains changes towards the subscriber application, tno-core update Indicates that there have been changes to our tno-core package, which can pose concurrency issues. labels Jan 31, 2024
@Fosol Fosol self-assigned this Jan 31, 2024
Publish tno-core:0.1.23
@@ -229,12 +230,15 @@ public async Task<IActionResult> UpdateAsync(ContentModel model)
content.Summary = model.Summary;
content.Body = model.Body;
content.Versions = model.Versions;
content.TonePoolsManyToMany.ForEach(tp =>
foreach (var tonePool in model.TonePools)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not necessary, but was debugging a bug that I thought was occurring here.

<FaRegMeh className="tone-icon" color="#FFC107" title={title} />
</Show>
<Show visible={value !== undefined && value > 0}>
<FaRegSmile className="tone-icon" color="#20C997" title={title} />
</Show>
{showValue && <span>{value}</span>}
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can now show the value

@@ -147,7 +147,20 @@ public override ReportInstance Update(ReportInstance entity)
if (ric.Content != null)
{
// TODO: Small security issue as the JSON could lie about this data.
if (ric.Content.IsPrivate)
if (ric.Content.IsPrivate &&
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only update content that has changed

* @param param0 Component properties.
* @returns Component.
*/
export const SentimentPicker = <T extends object>({
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New basic component without Formik

@Fosol Fosol merged commit 40137de into bcgov:dev Jan 31, 2024
3 checks passed
@Fosol Fosol deleted the tno-2056 branch January 31, 2024 01:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request subscriber PR contains changes towards the subscriber application, tno-core update Indicates that there have been changes to our tno-core package, which can pose concurrency issues.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant