Merge branch 'master' of https://github.com/larshp/abapGit into Test_local_proxy

This commit is contained in:
Christian Günter 2017-10-25 18:58:19 +02:00
commit 7133d456a5
9 changed files with 98 additions and 35 deletions

View File

@ -13,6 +13,7 @@
<item>/package.json</item> <item>/package.json</item>
<item>/changelog.txt</item> <item>/changelog.txt</item>
<item>/.gitignore</item> <item>/.gitignore</item>
<item>/CODE_OF_CONDUCT.md</item>
</IGNORE> </IGNORE>
</DATA> </DATA>
</asx:values> </asx:values>

46
CODE_OF_CONDUCT.md Normal file
View File

@ -0,0 +1,46 @@
# Contributor Covenant Code of Conduct
## Our Pledge
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
## Our Standards
Examples of behavior that contributes to creating a positive environment include:
* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
Examples of unacceptable behavior by participants include:
* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting
## Our Responsibilities
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
## Scope
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at https://abapgit-slackinviter.herokuapp.com/. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/

View File

@ -8,6 +8,11 @@ Legend
+ : added + : added
- : removed - : removed
2017-10-22 v1.47.0
------------------
* fix FUGR include diffs
+ filter by username on staging page
2017-10-15 v1.46.0 2017-10-15 v1.46.0
------------------ ------------------
+ IAMU supported + IAMU supported

View File

@ -1,4 +1,4 @@
title: abapGit Docs title: abapGit documentation
keep_files: [explore.html, repos.json] keep_files: [explore.html, repos.json]
highlighter: rouge highlighter: rouge
defaults: defaults:

View File

@ -4,4 +4,6 @@
<link rel="stylesheet" href="main.css"> <link rel="stylesheet" href="main.css">
<link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/octicons/4.4.0/font/octicons.min.css"> <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/octicons/4.4.0/font/octicons.min.css">
<title>{% if page.title %}{{ site.title }} - {{ page.title }}{% else %}{{ site.title }}{% endif %}</title> <title>{% if page.title %}{{ site.title }} - {{ page.title }}{% else %}{{ site.title }}{% endif %}</title>
<meta name="description" content="{% if page.title %}{{ site.title }} - {{ page.title }}{% else %}{{ site.title }} - Home{% endif %}" />
<meta name="keywords" content="abapGit,abapGit documentation" />
</head> </head>

View File

@ -1,5 +1,6 @@
<div class="page-head"> <div class="page-head">
<div class="wrap"> <div class="wrap">
<a href="./"><img class="head-logo" src="img/logo.svg" height="40" alt="abapGit"></a><span class="head-title">abapGit documentation</span> <a href="./"><img class="head-logo" src="img/logo.svg" height="40" alt="abapGit"></a>
<span class="head-title"> &#x25BA; documentation</span>
</div> </div>
</div> </div>

View File

@ -55,5 +55,5 @@ SAUG National Summit 2017, September 5th
SAP Teched Las Vegas SAP Teched Las Vegas
-Graham Robinson -Graham Robinson
abapGit, [IT Conference on SAP Technologies](http://www.itconferencesap.com/), Cluj [abapGit](https://larshp.github.io/Presentations/itsapcluj2017/abapgit/), [IT Conference on SAP Technologies](http://www.itconferencesap.com/), Cluj
-Lars Hvam -Lars Hvam

View File

@ -139,7 +139,8 @@ function StageHelper(params) {
}; };
// Table columns (autodetection) // Table columns (autodetection)
this.col = this.detectColumns(); this.colIndex = this.detectColumns();
this.filterTargets = ["name", "user"];
// Constants // Constants
this.HIGHLIGHT_STYLE = "highlight"; this.HIGHLIGHT_STYLE = "highlight";
@ -173,13 +174,13 @@ StageHelper.prototype.setHooks = function() {
// Detect column index // Detect column index
StageHelper.prototype.detectColumns = function() { StageHelper.prototype.detectColumns = function() {
var dataRow = this.dom.stageTab.tBodies[0].rows[0]; var dataRow = this.dom.stageTab.tBodies[0].rows[0];
var cols = {}; var colIndex = {};
for (var i = dataRow.cells.length - 1; i >= 0; i--) { for (var i = dataRow.cells.length - 1; i >= 0; i--) {
if (dataRow.cells[i].className) cols[dataRow.cells[i].className] = i; if (dataRow.cells[i].className) colIndex[dataRow.cells[i].className] = i;
} }
return cols; return colIndex;
} }
// Store table state on leaving the page // Store table state on leaving the page
@ -195,7 +196,7 @@ StageHelper.prototype.onPageLoad = function() {
var data = window.sessionStorage && JSON.parse(window.sessionStorage.getItem(this.pageSeed)); var data = window.sessionStorage && JSON.parse(window.sessionStorage.getItem(this.pageSeed));
this.iterateStageTab(true, function (row) { this.iterateStageTab(true, function (row) {
var status = data && data[row.cells[this.col.name].innerText]; var status = data && data[row.cells[this.colIndex["name"]].innerText];
this.updateRow(row, status || this.STATUS.reset); this.updateRow(row, status || this.STATUS.reset);
}); });
@ -250,22 +251,33 @@ StageHelper.prototype.onSearch = function (e) {
// Apply filter to a single stage line - hide or show // Apply filter to a single stage line - hide or show
StageHelper.prototype.applyFilterToRow = function (row, filter) { StageHelper.prototype.applyFilterToRow = function (row, filter) {
var td = row.cells[this.col.name]; // Collect data cells
var origTxt = td.innerText; // without tags var targets = this.filterTargets.map(function(attr) {
var newTxt = ""; var elem = row.cells[this.colIndex[attr]];
if (elem.firstChild && elem.firstChild.tagName === "A") elem = elem.firstChild;
return {
elem: elem,
plainText: elem.innerText, // without tags
curHtml: elem.innerHTML
};
}, this);
if (filter) { var isVisible = false;
newTxt = origTxt.replace(filter, "<mark>"+filter+"</mark>");
row.style.display = (newTxt !== origTxt) ? "" : "none"; // Apply filter to cells, mark filtered text
} else { // No filter -> just reset the value for (var i = targets.length - 1; i >= 0; i--) {
newTxt = origTxt; var target = targets[i];
row.style.display = ""; // default, visible target.newHtml = (filter)
? target.plainText.replace(filter, "<mark>"+filter+"</mark>")
: target.plainText;
target.isChanged = target.newHtml !== target.curHtml;
isVisible = isVisible || !filter || target.newHtml !== target.plainText;
} }
if (td.firstChild.tagName === "A") { // Update DOM
td.firstChild.innerHTML = newTxt; row.style.display = isVisible ? "" : "none";
} else { for (var i = targets.length - 1; i >= 0; i--) {
td.innerHTML = newTxt; if (targets[i].isChanged) targets[i].elem.innerHTML = targets[i].newHtml;
} }
} }
@ -282,12 +294,12 @@ StageHelper.prototype.getStatusImpact = function (status) {
// Update table line // Update table line
StageHelper.prototype.updateRow = function (row, newStatus) { StageHelper.prototype.updateRow = function (row, newStatus) {
var oldStatus = row.cells[this.col.status].innerText; var oldStatus = row.cells[this.colIndex["status"]].innerText;
if (oldStatus !== newStatus) { if (oldStatus !== newStatus) {
this.updateRowStatus(row, newStatus); this.updateRowStatus(row, newStatus);
this.updateRowCommand(row, newStatus); this.updateRowCommand(row, newStatus);
} else if (!row.cells[this.col.cmd].children.length) { } else if (!row.cells[this.colIndex["cmd"]].children.length) {
this.updateRowCommand(row, newStatus); // For initial run this.updateRowCommand(row, newStatus); // For initial run
} }
@ -296,17 +308,17 @@ StageHelper.prototype.updateRow = function (row, newStatus) {
// Update Status cell (render set of commands) // Update Status cell (render set of commands)
StageHelper.prototype.updateRowStatus = function (row, status) { StageHelper.prototype.updateRowStatus = function (row, status) {
row.cells[this.col.status].innerText = status; row.cells[this.colIndex["status"]].innerText = status;
if (status === this.STATUS.reset) { if (status === this.STATUS.reset) {
row.cells[this.col.status].classList.remove(this.HIGHLIGHT_STYLE); row.cells[this.colIndex["status"]].classList.remove(this.HIGHLIGHT_STYLE);
} else { } else {
row.cells[this.col.status].classList.add(this.HIGHLIGHT_STYLE); row.cells[this.colIndex["status"]].classList.add(this.HIGHLIGHT_STYLE);
} }
} }
// Update Command cell (render set of commands) // Update Command cell (render set of commands)
StageHelper.prototype.updateRowCommand = function (row, status) { StageHelper.prototype.updateRowCommand = function (row, status) {
var cell = row.cells[this.col.cmd]; var cell = row.cells[this.colIndex["cmd"]];
if (status === this.STATUS.reset) { if (status === this.STATUS.reset) {
cell.innerHTML = (row.className == "local") cell.innerHTML = (row.className == "local")
? this.TEMPLATES.cmdLocal ? this.TEMPLATES.cmdLocal
@ -318,7 +330,7 @@ StageHelper.prototype.updateRowCommand = function (row, status) {
// Update menu items visibility // Update menu items visibility
StageHelper.prototype.updateMenu = function () { StageHelper.prototype.updateMenu = function () {
this.dom.commitBtn.style.display = (this.choiseCount > 0) ? "" : "none"; this.dom.commitBtn.style.display = (this.choiseCount > 0) ? "" : "none";
this.dom.commitAllBtn.style.display = (this.choiseCount > 0) ? "none" : ""; this.dom.commitAllBtn.style.display = (this.choiseCount > 0) ? "none" : "";
this.dom.fileCounter.innerHTML = this.choiseCount.toString(); this.dom.fileCounter.innerHTML = this.choiseCount.toString();
} }
@ -332,22 +344,19 @@ StageHelper.prototype.submit = function () {
StageHelper.prototype.collectData = function () { StageHelper.prototype.collectData = function () {
var data = {}; var data = {};
this.iterateStageTab(false, function (row) { this.iterateStageTab(false, function (row) {
data[row.cells[this.col.name].innerText] = row.cells[this.col.status].innerText; data[row.cells[this.colIndex["name"]].innerText] = row.cells[this.colIndex["status"]].innerText;
}); });
return data; return data;
} }
// Table iteration helper // Table iteration helper
StageHelper.prototype.iterateStageTab = function (changeMode, cb /*, ...*/) { StageHelper.prototype.iterateStageTab = function (changeMode, cb /*, ...*/) {
var restArgs = Array.prototype.slice.call(arguments, 2); var restArgs = Array.prototype.slice.call(arguments, 2);
var table = this.dom.stageTab; var table = this.dom.stageTab;
if (changeMode) { if (changeMode) {
var scrollOffset = window.pageYOffset; var scrollOffset = window.pageYOffset;
this.dom.stageTab.style.display = "none"; this.dom.stageTab.style.display = "none";
// var stageTabParent = this.dom.stageTab.parentNode;
// table = stageTabParent.removeChild(this.dom.stageTab);
} }
for (var b = 0, bN = table.tBodies.length; b < bN; b++) { for (var b = 0, bN = table.tBodies.length; b < bN; b++) {
@ -360,7 +369,6 @@ StageHelper.prototype.iterateStageTab = function (changeMode, cb /*, ...*/) {
if (changeMode) { if (changeMode) {
this.dom.stageTab.style.display = ""; this.dom.stageTab.style.display = "";
// stageTabParent.appendChild(table);
window.scrollTo(0, scrollOffset); window.scrollTo(0, scrollOffset);
} }
} }

View File

@ -2,7 +2,7 @@ INTERFACE zif_abapgit_definitions
PUBLIC . PUBLIC .
CONSTANTS gc_xml_version TYPE string VALUE 'v1.0.0' ##NO_TEXT. CONSTANTS gc_xml_version TYPE string VALUE 'v1.0.0' ##NO_TEXT.
CONSTANTS gc_abap_version TYPE string VALUE 'v1.46.0' ##NO_TEXT. CONSTANTS gc_abap_version TYPE string VALUE 'v1.47.0' ##NO_TEXT.
TYPES: TYPES:
ty_type TYPE c LENGTH 6 . ty_type TYPE c LENGTH 6 .