marc0l92 / obsidian-jira-issue

This plugin allows you to track the progress of Atlassian Jira issues from your Obsidian notes.
https://marc0l92.github.io/obsidian-jira-issue/
GNU Affero General Public License v3.0
234 stars 36 forks source link

js integration #20

Closed MicheleDeZen closed 1 year ago

MicheleDeZen commented 2 years ago

First of all thanks for the awesome work!!

I am wondering if there is a way to interact with the plugin from for example a "dataviewjs" code block or from some "customjs" file to integrate it to my current setup

thanks

marc0l92 commented 2 years ago

At the moment there is nothing like that. What would you like to do in javascript with the data of this plugin?

MicheleDeZen commented 2 years ago

i have a couple of custom javascript files that pulls in some other informations and it would be nice to be able to integrate that

marc0l92 commented 2 years ago

I use some custom script files with templater but I never use them with dataviewjs. Can you describe an example of script you would like to do with the data of this plugin?

What kind of data would you use? How would you transform them? How would you display them?

gmkado commented 1 year ago

@marc0l92 can you share how you use templater with this plugin? I would like to be able to fill out a template page with jira data when using the "add note" feature of jira-search

marc0l92 commented 1 year ago

At the moment it is not possible, but It is an interesting feature. I will ping you when it is ready.

marc0l92 commented 1 year ago

@gmkado do you know any plugin that allows to share data with templater plugin? I would like to read how they do in order to create something similar

marc0l92 commented 1 year ago

I checked how MetaEdit plugin is doing this and it seems feasible to implement.

Do you have any specific feature that you would like JiraIssue plugin to expose?

gmkado commented 1 year ago

Awesome!
For my use case, it would be great to point the plugin to a template to use when creating notes from the jira-search table, and then reference any of the standard fields from the selected issue inside the template.

amykhar commented 1 year ago

@marc0l92 - I'm not sure if this will help you at all, but I was working on making the Day Planner plugin work with templates. I got it all working, but need to address some review comments if I ever get time. You may be able to find examples of hooking templater in.

https://github.com/amykhar/obsidian-day-planner-with-templates

jmkhael commented 1 year ago

first things first. amazing plugin, thank you for the hard work. we can imagine several use cases where we need to integrate both. I personally have several motivation to integrating dataviewjs. I'll try to be brief:

I present what we call epics (standard jira issues) aggregating features (epic parent of feature). I currently visualize them as cards, using the minimal theme and inject in them the jira issues

Note creation

  1. when I create a note, I need to inject some values from the jira issue within templater. e.g. I would love to use quick add and just give it a {{VALUE: Jira ID}} and from that be able to query using jira-issue for other fields and enhance the experience and workflow.

Easier forecast/planning

  1. e.g. When we are forecast the upcoming quarter, we usually need to e.g. to sum the estimations across a given team and see if it is within their previous velocities (imagine each team has a value stored in their note for this, tracked per sprint, quarterly). but each jira issue has an estimation.

In the cards, using dataviewjs, I inject the jira search to collect the jira-issues for that epic for the given quarter, which is a dataview metadata set in a given note used to plan the quarter...

e.g.

dv.table(["Epic", "why", "status", "previous", "decisions", "tldr", "needs", "details"],
   group.rows
.map(k => [k.file.link + k.jira, 
`\`\`\`jira-search
    type: TABLE
    query: ` + k.quarter + `
    limit: 15
    columns: KEY, SUMMARY, $Job size, Labels, STATUS
\`\`\``
...

image

crossing the world of jira-issue with dataviewjs will unleash this and many other ideas!

marc0l92 commented 1 year ago

I published the first APIs of this plugin in the version 1.42.0

I'm now working on the documentation

marc0l92 commented 1 year ago

You will be able to see the documentation here: https://marc0l92.github.io/obsidian-jira-issue/docs/api/api-introduction

marc0l92 commented 1 year ago

I created few API that should give you access to most of the Jira functionalities. I'm working on some API to visualize charts that may be useful to most of the people but I suspect my use cases are different from any body else.

You should be able to access those api from dataviewjs and templater. If you have any other community plugin in mind that can interface with this one let me know.

Let me know if you need additional apis.

jmkhael commented 1 year ago

great work! thank you @marc0l92! I started playing with the APIs and integrating in dataviewjs, everything is working well till now. I will let you know if any API is needed. cheers!