From 240c5bb3115e7428ec1a1fd7e92c41f4234b5c08 Mon Sep 17 00:00:00 2001 From: HENRY Florian Date: Thu, 21 Nov 2024 23:00:41 +0100 Subject: [PATCH 1/4] fix: buyer and sellers in supplier invoice and supplier order list are not corectly defined (#32028) * fix: buyer and sellers in supplier invoice and supplier order list are not corectly defined * chore: revert bad changes --- htdocs/fourn/commande/list.php | 1 + 1 file changed, 1 insertion(+) diff --git a/htdocs/fourn/commande/list.php b/htdocs/fourn/commande/list.php index 60518e789fb91..33c59ea03303c 100644 --- a/htdocs/fourn/commande/list.php +++ b/htdocs/fourn/commande/list.php @@ -391,6 +391,7 @@ $societe = new Societe($db); $societe->fetch($cmd->socid); $objecttmp->vat_reverse_charge = $societe->vat_reverse_charge; + $objecttmp->thirdparty = $societe; } $objecttmp->socid = $cmd->socid; $objecttmp->type = $objecttmp::TYPE_STANDARD; From ec93f508631ab4c2a0d21df645af1c97f679aae3 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 22 Nov 2024 00:15:14 +0100 Subject: [PATCH 2/4] Test --- .github/workflows/pr-18.yaml | 33 +++++++++++++++++++++------------ 1 file changed, 21 insertions(+), 12 deletions(-) diff --git a/.github/workflows/pr-18.yaml b/.github/workflows/pr-18.yaml index 376bf29454f0a..11188dc974d42 100644 --- a/.github/workflows/pr-18.yaml +++ b/.github/workflows/pr-18.yaml @@ -1,20 +1,29 @@ on: pull_request: - types: - - opened + types: [opened, reopened] branches: - "18.0" jobs: run: - runs-on: ubuntu-22.04 - permissions: - pull-requests: write + runs-on: ubuntu-latest steps: - - name: Create PR review request - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - url: ${{ github.event.pull_request.html_url }} - run: | - gh pr edit "$url" --add-assignee lvessiller-opendsi,rycks --add-reviewer lvessiller-opendsi,rycks - gh pr merge "$url" --merge --auto + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Install GitHub CLI + run: | + sudo apt update + sudo apt install gh -y + + - name: Authenticate GitHub CLI + env: + GH_TOKEN: ${{ secrets.GH_TOKEN }} + run: gh auth login --with-token <<< "$GH_TOKEN" + + - name: Assign reviewer + env: + REVIEWER: "eldy,lvessiller-opendsi,rycks" # Remplacez par le nom d'utilisateur GitHub du reviewer + run: | + pr_number=$(jq --raw-output .number < $GITHUB_EVENT_PATH) + gh pr edit $pr_number --add-reviewer "$REVIEWER" From c2a037842d502b79ebada741434b284a1b3b859b Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 22 Nov 2024 00:22:26 +0100 Subject: [PATCH 3/4] Add test --- .github/workflows/test.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .github/workflows/test.yaml diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml new file mode 100644 index 0000000000000..f49494c55223e --- /dev/null +++ b/.github/workflows/test.yaml @@ -0,0 +1,18 @@ +on: + workflow_dispatch: +jobs: + demo_app_authentication: + runs-on: ubuntu-latest + steps: + - name: Generate a token + id: generate-token + uses: actions/create-github-app-token@v1 + with: + app-id: ${{ vars.CIAPPID }} + private-key: ${{ secrets.CIAPPPRIKEY }} + + - name: Use the token + env: + GH_TOKEN: ${{ steps.generate-token.outputs.token }} + run: | + gh api dolibarr From 53ffe42f9235cce3d3287b87fbbd911a82adcd61 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 22 Nov 2024 00:27:58 +0100 Subject: [PATCH 4/4] Test CI --- .github/workflows/test.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index f49494c55223e..1fb89b8cb96a8 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -4,6 +4,9 @@ jobs: demo_app_authentication: runs-on: ubuntu-latest steps: + - name: Log + run: echo "CIAPPID ${{ vars.CIAPPID }}" + - name: Generate a token id: generate-token uses: actions/create-github-app-token@v1