diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml deleted file mode 100644 index 97f218fce4d..00000000000 --- a/.github/workflows/test.yaml +++ /dev/null @@ -1,28 +0,0 @@ -name: Test github actions -on: - workflow_dispatch: - pull_request: - types: [opened, reopened, synchronize] - push: - -env: - ENVGHT: ${{ secrets.GITHUB_TOKEN }} - ENVGHU: ${{ github.token }} - TEST_ACCESS_KEY: ${{ secrets.TEST_ACCESS_KEY }} - TEST_VAR_REPO: ${{ vars.TEST_VAR_REPO }} - ENVLOCAL: "varenvlocal" - -jobs: - testjob: - runs-on: ubuntu-latest - steps: - - name: Log - run: | - echo "Run action by ${{ github.actor }}" - echo "github.token=${{ github.token }}" - echo "secrets.GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}" - echo "GITHUB_EVENT_PATH=$GITHUB_EVENT_PATH" - echo "repo-token: ${{secrets.GITHUB_TOKEN}}" - echo "secret repository TEST_ACCESS_KEY: ${{secrets.TEST_ACCESS_KEY}}" - echo "variable repository : ${{vars.TEST_VAR_REPO}}" - echo "ENVLOCAL: ${{env.ENVLOCAL}}" diff --git a/htdocs/compta/cashcontrol/class/cashcontrol.class.php b/htdocs/compta/cashcontrol/class/cashcontrol.class.php index f4f8970dc8d..f97955c0481 100644 --- a/htdocs/compta/cashcontrol/class/cashcontrol.class.php +++ b/htdocs/compta/cashcontrol/class/cashcontrol.class.php @@ -186,6 +186,7 @@ class CashControl extends CommonObject $sql .= ", cash"; $sql .= ", cheque"; $sql .= ", card"; + $sql .= ", fk_user_creat"; $sql .= ") VALUES ("; //$sql .= "'(PROV)', "; $sql .= ((int) $conf->entity); @@ -200,6 +201,7 @@ class CashControl extends CommonObject $sql .= ", ".price2num($this->cash, 'MT'); $sql .= ", ".price2num($this->cheque, 'MT'); $sql .= ", ".price2num($this->card, 'MT'); + $sql .= ", ".((int) $user->id); $sql .= ")"; $this->db->begin(); diff --git a/htdocs/compta/facture/card.php b/htdocs/compta/facture/card.php index 7da68f1734a..14ed1d3846b 100644 --- a/htdocs/compta/facture/card.php +++ b/htdocs/compta/facture/card.php @@ -1607,6 +1607,9 @@ if (empty($reshook)) { $amount_ttc_diff = 0.; foreach ($TTotalByTva as $tva => &$total) { + if (empty($amountdeposit[$tva])) { + $amountdeposit[$tva] = 0; + } $coef = $total / $srcobject->total_ttc; // Calc coef $am = $amount * $coef; $amount_ttc_diff += $am; @@ -1631,6 +1634,10 @@ if (empty($reshook)) { if ($qualified) { $totalamount += $lines[$i]->total_ht; // Fixme : is it not for the customer ? Shouldn't we take total_ttc ? $tva_tx = $lines[$i]->tva_tx; + + if (empty($amountdeposit[$tva_tx])) { + $amountdeposit[$tva_tx] = 0; + } $amountdeposit[$tva_tx] += ($lines[$i]->total_ht * (float) $valuedeposit) / 100; } } diff --git a/htdocs/holiday/month_report.php b/htdocs/holiday/month_report.php index b5e66d14f5f..b543563d854 100644 --- a/htdocs/holiday/month_report.php +++ b/htdocs/holiday/month_report.php @@ -157,7 +157,7 @@ $year_month = sprintf("%04d", $search_year).'-'.sprintf("%02d", $search_month); $sql = "SELECT cp.rowid, cp.ref, cp.fk_user, cp.date_debut, cp.date_fin, cp.fk_type, cp.description, cp.halfday, cp.statut as status"; $sql .= " FROM ".MAIN_DB_PREFIX."holiday cp"; $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."user u ON cp.fk_user = u.rowid"; -$sql .= " WHERE cp.rowid > 0"; +$sql .= " WHERE cp.entity IN (".getEntity('holiday').") AND cp.rowid > 0"; $sql .= " AND cp.statut = ".Holiday::STATUS_APPROVED; $sql .= " AND ("; $sql .= " (date_format(cp.date_debut, '%Y-%m') = '".$db->escape($year_month)."' OR date_format(cp.date_fin, '%Y-%m') = '".$db->escape($year_month)."')"; diff --git a/htdocs/install/mysql/tables/llx_actioncomm.sql b/htdocs/install/mysql/tables/llx_actioncomm.sql index eccb6f49fe8..b1ef5b919b0 100644 --- a/htdocs/install/mysql/tables/llx_actioncomm.sql +++ b/htdocs/install/mysql/tables/llx_actioncomm.sql @@ -79,14 +79,10 @@ create table llx_actioncomm fk_element integer DEFAULT NULL, -- For link to an element (proposal, invoice, order, ...) elementtype varchar(255) DEFAULT NULL, -- For link to an element (proposal, invoice, order, ...) - ip varchar(250), --ip used to create record (for public submission page) + ip varchar(250), -- ip used to create record (for public submission page) - fk_bookcal_calendar integer DEFAULT NULL, --fk_bookcal_calendar used to link booking to bookcal calendar + fk_bookcal_calendar integer DEFAULT NULL, -- fk_bookcal_calendar used to link booking to bookcal calendar import_key varchar(14), extraparams varchar(255) -- for other parameters with json format )ENGINE=innodb; - - - -