# OOD myjobs app: safe to rearrange elements within index.html.erb?

**URL:** <https://discourse.openondemand.org/t/ood-myjobs-app-safe-to-rearrange-elements-within-index-html-erb/738>\
**Category:** Get Help\
**Created:** [February 19, 2020, 11:03pm UTC](https://discourse.openondemand.org/t/ood-myjobs-app-safe-to-rearrange-elements-within-index-html-erb/738 "2020-02-19T23:03:39Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![jasonbuechler](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jasonbuechler/32/302_2.png) [@jasonbuechler](https://discourse.openondemand.org/u/jasonbuechler)\
**Post date:** [February 19, 2020, 11:03pm UTC](https://discourse.openondemand.org/t/ood-myjobs-app-safe-to-rearrange-elements-within-index-html-erb/738/1 "2020-02-19T23:03:39Z")

</div>

In our dev machine’s `myjobs/app/views/workflows/index.html.erb`, I’ve swapped the positioning of [the “Submit Script” block](https://github.com/OSC/ondemand/blob/master/apps/myjobs/app/views/workflows/index.html.erb#L148-L162) (the one with the “Open Editor” button) and the “Job Details” block so that the “Open Editor” button is more readily apparent to our novice users, and we all really like this layout change…  
Q1: _is there any drawback in doing this?_

(The only thing I can think of is a javascript using `nth-child` or something instead of targeting by `div#script-details-panel` and `div#job-details-panel`, but it’s probably safer to ask!)

Q2: Assuming that modification is safe, could you remind me if a yum-update would wipe out that change or not?

Q3: Just out of curiosity, why is the “Job Details” section above the “Submit Script” block? In my admittedly naive opinion, it seems like the vast majority of user interaction would take place with SubmitScript and there’s very few reasons to even glance at JobDetails.

As a quick reference, here’s the javascript to rearrange the two “live”, for anyone who’d like to see how it’d look:

```javascript
document.querySelector('#job-details-container').insertBefore(document.querySelector('#script-details-panel'),document.querySelector('#job-details-panel'))

```

…just paste that into Chrome’s console, or type it into the url-bar after typing a `javascript:` prefix.  
_(note: Chrome won’t allow you to paste in a full `javascript:.....` line, because security.)_

---

<div class="post-metadata">

**Author:** ![jeff.ohrstrom](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jeff.ohrstrom/32/136_2.png) [@jeff.ohrstrom](https://discourse.openondemand.org/u/jeff.ohrstrom)\
**Post date:** [February 20, 2020, 3:25pm UTC](https://discourse.openondemand.org/t/ood-myjobs-app-safe-to-rearrange-elements-within-index-html-erb/738/2 "2020-02-20T15:25:06Z")

</div>

1. I’d have to look at it more deeply to be sure.
2. A yum update will wipe it.
3. (I think) The script can be arbitrary length, so putting something below it (if it’s 1000 lines long) would be easy to miss. That’s my off the top, out of thin air guess.

Yea the UX of that app is not straight forward, but I think you’re on the right track; that the details pane should to be moved to give the script pane prominence. But I don’t think swapping them is enough. Maybe hide it and be able to expand it like how we do in active jobs to get more details on that job? So it gets moved the to the table in the middle-left of the screen?

---

<div class="post-metadata">

**Author:** ![jasonbuechler](https://sea1.discourse-cdn.com/flex015/user_avatar/discourse.openondemand.org/jasonbuechler/32/302_2.png) [@jasonbuechler](https://discourse.openondemand.org/u/jasonbuechler)\
**Post date:** [February 20, 2020, 3:56pm UTC](https://discourse.openondemand.org/t/ood-myjobs-app-safe-to-rearrange-elements-within-index-html-erb/738/3 "2020-02-20T15:56:48Z")

</div>

Ahh, thank you for that! The arbitrary length thing does indeed make a sensible origin story.

I 100% agree with your brainstorming on that, too! I’ll ask around here and get some new users’ perspectives and report back here if it seems worthwhile.

Thanks again!

---

<div class="post-metadata">

**Author:** ![westburg.2](https://avatars.discourse-cdn.com/v4/letter/w/0ea827/32.png) [@westburg.2](https://discourse.openondemand.org/u/westburg.2)\
**Post date:** [May 26, 2022, 3:34pm UTC](https://discourse.openondemand.org/t/ood-myjobs-app-safe-to-rearrange-elements-within-index-html-erb/738/4 "2022-05-26T15:34:48Z")

</div>

Closed on May 26, 2022, 3:34pm UTC


