mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
029513c8b7
10
.github/workflows/cache-clean-pr.yml
vendored
10
.github/workflows/cache-clean-pr.yml
vendored
|
|
@ -19,17 +19,17 @@ jobs:
|
|||
- name: Cleanup
|
||||
run: |
|
||||
gh extension install actions/gh-actions-cache
|
||||
REPO=${{ github.repository }}
|
||||
BRANCH=refs/pull/${{ github.event.pull_request.number }}/merge
|
||||
REPO="${{ github.repository }}"
|
||||
BRANCH="refs/pull/${{ github.event.pull_request.number }}/merge"
|
||||
echo "Fetching list of cache key"
|
||||
cacheKeysForPR=$(gh actions-cache list -R $REPO -B $BRANCH | cut -f 1 )
|
||||
cacheKeysForPR=$(gh actions-cache list -R "$REPO" -B "$BRANCH" | cut -f 1 )
|
||||
|
||||
## Setting this to not fail the workflow while deleting cache keys.
|
||||
## Setting this to not fail the workflow while deleting cache keys.
|
||||
set +e
|
||||
echo "Deleting caches..."
|
||||
for cacheKey in $cacheKeysForPR
|
||||
do
|
||||
gh actions-cache delete $cacheKey -R $REPO -B $BRANCH --confirm
|
||||
gh actions-cache delete "$cacheKey" -R "$REPO" -B "$BRANCH" --confirm
|
||||
done
|
||||
echo "Done"
|
||||
env:
|
||||
|
|
|
|||
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
|
|
@ -36,6 +36,6 @@ jobs:
|
|||
|
||||
|
||||
# Note (not tested, from https://github.com/orgs/community/discussions/38361)
|
||||
# To cancel jobs if one failes, the following action may help
|
||||
# To cancel jobs if one fails, the following action may help
|
||||
# - if: "failure()"
|
||||
# uses: "andymckay/cancel-action@0.3"
|
||||
|
|
|
|||
5
.github/workflows/exakat.yml
vendored
5
.github/workflows/exakat.yml
vendored
|
|
@ -4,10 +4,8 @@ name: "Exakat analysis"
|
|||
on:
|
||||
# execute once a month, the 1st
|
||||
schedule:
|
||||
- cron: "0 20 1 * *"
|
||||
- cron: "0 20 1 * *"
|
||||
workflow_dispatch:
|
||||
branches:
|
||||
- develop
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
|
@ -19,6 +17,7 @@ jobs:
|
|||
- uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 1
|
||||
ref: develop
|
||||
- name: Exakat
|
||||
uses: docker://exakat/exakat-ga
|
||||
with:
|
||||
|
|
|
|||
6
.github/workflows/phan.yml
vendored
6
.github/workflows/phan.yml
vendored
|
|
@ -17,8 +17,7 @@ concurrency:
|
|||
cancel-in-progress: true
|
||||
env:
|
||||
gh_event: ${{ inputs.gh_event || github.event_name }}
|
||||
PHAN_CONFIG: >
|
||||
${{ 'dev/tools/phan/config.php' }}
|
||||
PHAN_CONFIG: dev/tools/phan/config.php
|
||||
PHAN_BASELINE: dev/tools/phan/baseline.txt
|
||||
PHAN_MIN_PHP: 7.0
|
||||
PHAN_QUICK: ${{ github.event.schedule && '' || '--quick' }}
|
||||
|
|
@ -43,7 +42,8 @@ jobs:
|
|||
tools: cs2pr,phan
|
||||
- name: Run Phan analysis
|
||||
run: |
|
||||
phan $PHAN_QUICK -k $PHAN_CONFIG -B $PHAN_BASELINE --analyze-twice --minimum-target-php-version $PHAN_MIN_PHP --output-mode=checkstyle -o _phan.xml
|
||||
# shellcheck disable=2086
|
||||
phan $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=checkstyle -o _phan.xml
|
||||
- name: Add results to PR
|
||||
if: ${{ always() }}
|
||||
run: |
|
||||
|
|
|
|||
9
.github/workflows/pre-commit.yml
vendored
9
.github/workflows/pre-commit.yml
vendored
|
|
@ -67,7 +67,7 @@ jobs:
|
|||
run: |
|
||||
set -o pipefail
|
||||
pre-commit gc
|
||||
pre-commit run --show-diff-on-failure --color=always --all-files | tee ${RAW_LOG}
|
||||
pre-commit run --show-diff-on-failure --color=always --all-files | tee "${RAW_LOG}"
|
||||
|
||||
# The next uses git, which is slow for a bit repo.
|
||||
# - name: Get all changed php files (if PR)
|
||||
|
|
@ -105,7 +105,8 @@ jobs:
|
|||
ALL_CHANGED_FILES: ${{ steps.changed-php.outputs.all_changed_files }}
|
||||
run: |
|
||||
set -o pipefail
|
||||
pre-commit run php-cs --files ${ALL_CHANGED_FILES} | tee -a ${RAW_LOG}
|
||||
# shellcheck disable=2086
|
||||
pre-commit run php-cs --files ${ALL_CHANGED_FILES} | tee -a "${RAW_LOG}"
|
||||
|
||||
- name: Run some pre-commit hooks on all files on push to "main" branches
|
||||
if: |
|
||||
|
|
@ -117,8 +118,8 @@ jobs:
|
|||
run: |
|
||||
set -o pipefail
|
||||
ln -sf ~/.cache .cache # Absolute path in .pre-commit-config.yaml
|
||||
pre-commit run --hook-stage manual -a php-cs-with-cache | tee -a ${RAW_LOG}
|
||||
pre-commit run --hook-stage manual -a sqlfluff-lint | tee -a ${RAW_LOG}
|
||||
pre-commit run --hook-stage manual -a php-cs-with-cache | tee -a "${RAW_LOG}"
|
||||
pre-commit run --hook-stage manual -a sqlfluff-lint | tee -a "${RAW_LOG}"
|
||||
ls -l ~/.cache/pre-commit/
|
||||
|
||||
- name: Convert Raw Log to Annotations
|
||||
|
|
|
|||
15
.github/workflows/windows-ci.yml
vendored
15
.github/workflows/windows-ci.yml
vendored
|
|
@ -66,7 +66,7 @@ jobs:
|
|||
KEY_ROOT: ${{ matrix.os }}-${{ env.ckey }}-${{ matrix.php_version }}
|
||||
with:
|
||||
# See https://github.com/actions/cache/issues/1275#issuecomment-1925217178
|
||||
enableCrossOsArchive: true
|
||||
enableCrossOsArchive: true
|
||||
path: |
|
||||
./db_init.sql
|
||||
./db_init.sql.md5
|
||||
|
|
@ -114,6 +114,7 @@ jobs:
|
|||
# Note this is bash (MSYS) on Windows
|
||||
shell: bash
|
||||
run: |
|
||||
# shellcheck disable=SC2129
|
||||
ECHO "#[group]Directory contents to verify cache files, ..."
|
||||
ls -l
|
||||
ECHO "#[endgroup]"
|
||||
|
|
@ -128,10 +129,12 @@ jobs:
|
|||
ls -l
|
||||
ECHO "#[endgroup]"
|
||||
# Export some tool paths to reuse the from CMD shell.
|
||||
echo "TAIL=$(cygpath -w "$(which tail)")" >> "$GITHUB_ENV"
|
||||
echo "GREP=$(cygpath -w "$(which grep)")" >> "$GITHUB_ENV"
|
||||
echo "TEE=$(cygpath -w "$(which tee)")" >> "$GITHUB_ENV"
|
||||
echo "BASEDIR=$(realpath .)" >> "$GITHUB_ENV"
|
||||
{
|
||||
echo "TAIL=$(cygpath -w "$(which tail)")"
|
||||
echo "GREP=$(cygpath -w "$(which grep)")"
|
||||
echo "TEE=$(cygpath -w "$(which tee)")"
|
||||
echo "BASEDIR=$(realpath .)"
|
||||
} >> "$GITHUB_ENV"
|
||||
|
||||
- name: Run PHPUnit tests
|
||||
# continue-on-error: true
|
||||
|
|
@ -184,7 +187,7 @@ jobs:
|
|||
if: ${{ ! cancelled() }}
|
||||
with:
|
||||
# See https://github.com/actions/cache/issues/1275#issuecomment-1925217178
|
||||
enableCrossOsArchive: true
|
||||
enableCrossOsArchive: true
|
||||
key: ${{ steps.cache.outputs.cache-primary-key }}
|
||||
path: |
|
||||
./db_init.sql
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
---
|
||||
exclude: (?x)^( htdocs/includes/ckeditor/.*|(\.[^/]*/.*))$
|
||||
exclude: (?x)^( htdocs/includes/ckeditor/.*|(\.(?!github/workflows)[^/]*/.*))$
|
||||
repos:
|
||||
# Several miscellaneous checks and fix (on yaml files, end of files fix)
|
||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||
|
|
@ -64,6 +64,12 @@ repos:
|
|||
hooks:
|
||||
- id: gitleaks
|
||||
|
||||
# Check github actions
|
||||
- repo: https://github.com/rhysd/actionlint
|
||||
rev: v1.7.3
|
||||
hooks:
|
||||
- id: actionlint
|
||||
|
||||
# Beautify shell scripts
|
||||
- repo: https://github.com/lovesegfault/beautysh.git
|
||||
rev: v6.2.1
|
||||
|
|
|
|||
|
|
@ -19,12 +19,31 @@ dollibarr->dolibarr
|
|||
extrafeild->extrafield
|
||||
thoose->those
|
||||
# fiche->card
|
||||
nempty->an empty, empty, not empty,
|
||||
maringbottomonly->marginbottomonly
|
||||
maxwidthonsmartpone->maxwidthonsmartphone
|
||||
maxwidthonspartphone->maxwidthonsmartphone
|
||||
minwith100->minwidth100
|
||||
minwith200->minwidth200
|
||||
mot de passe->password
|
||||
multicurreny->multicurrency
|
||||
nempty->an empty, empty, not empty,
|
||||
nocellnopadding->nocellnopadd
|
||||
nodrap->nodrag, nodrop,
|
||||
not de passe->password
|
||||
nothtml->nohtml
|
||||
notoptoleftroright->notoptoleftnoright
|
||||
nowraponalls->nowraponall
|
||||
oddevene->oddeven
|
||||
oddseven->oddeven
|
||||
opacitymediuem->opacitymedium
|
||||
pictofiwedwidth->pictofixedwidth
|
||||
pictofixedwith->pictofixedwidth
|
||||
shippin->shipping
|
||||
tableau de bord->state board
|
||||
tagret->target
|
||||
tdoverflowmax100aaa->tdoverflowmax100
|
||||
tdoverlowmax200->tdoverflowmax200
|
||||
thridparty->thirdparty
|
||||
with100->width100
|
||||
with75->width75
|
||||
wysiwig->wysiwyg
|
||||
|
|
|
|||
|
|
@ -86,6 +86,10 @@ espace
|
|||
methode
|
||||
datee
|
||||
|
||||
# Translation keys
|
||||
addin
|
||||
amountin
|
||||
|
||||
# other
|
||||
blacklists
|
||||
confirmactionxxx
|
||||
|
|
|
|||
|
|
@ -9,22 +9,22 @@
|
|||
*/
|
||||
return [
|
||||
// # Issue statistics:
|
||||
// PhanPluginUnknownPropertyType : 1330+ occurrences
|
||||
// PhanPluginUnknownPropertyType : 1200+ occurrences
|
||||
// PhanUndeclaredProperty : 840+ occurrences
|
||||
// PhanPossiblyUndeclaredGlobalVariable : 690+ occurrences
|
||||
// PhanTypeMismatchArgumentProbablyReal : 630+ occurrences
|
||||
// PhanUndeclaredGlobalVariable : 440+ occurrences
|
||||
// PhanPossiblyUndeclaredGlobalVariable : 680+ occurrences
|
||||
// PhanTypeMismatchArgumentProbablyReal : 550+ occurrences
|
||||
// PhanUndeclaredGlobalVariable : 430+ occurrences
|
||||
// PhanPluginUnknownArrayMethodReturnType : 420+ occurrences
|
||||
// PhanPluginUnknownArrayMethodParamType : 340+ occurrences
|
||||
// PhanPossiblyUndeclaredVariable : 280+ occurrences
|
||||
// PhanTypeMismatchProperty : 190+ occurrences
|
||||
// PhanPluginUnknownArrayFunctionReturnType : 150+ occurrences
|
||||
// PhanPluginUnknownArrayMethodParamType : 310+ occurrences
|
||||
// PhanPossiblyUndeclaredVariable : 270+ occurrences
|
||||
// PhanTypeMismatchProperty : 180+ occurrences
|
||||
// PhanPluginUnknownArrayFunctionParamType : 140+ occurrences
|
||||
// PhanPluginUnknownObjectMethodCall : 130+ occurrences
|
||||
// PhanTypeMismatchArgumentNullableInternal : 80+ occurrences
|
||||
// PhanPluginUndeclaredVariableIsset : 70+ occurrences
|
||||
// PhanPluginUnknownArrayFunctionReturnType : 140+ occurrences
|
||||
// PhanTypeMismatchArgumentNullableInternal : 75+ occurrences
|
||||
// PhanPluginUnknownArrayPropertyType : 70+ occurrences
|
||||
// PhanPluginEmptyStatementIf : 55+ occurrences
|
||||
// PhanPluginUnknownObjectMethodCall : 70+ occurrences
|
||||
// PhanPluginUndeclaredVariableIsset : 65+ occurrences
|
||||
// PhanPluginEmptyStatementIf : 50+ occurrences
|
||||
// PhanRedefineFunction : 50+ occurrences
|
||||
// PhanTypeSuspiciousNonTraversableForeach : 50+ occurrences
|
||||
// PhanTypeInvalidDimOffset : 35+ occurrences
|
||||
|
|
@ -40,8 +40,8 @@ return [
|
|||
// PhanUndeclaredMethod : 10+ occurrences
|
||||
// PhanPluginBothLiteralsBinaryOp : 8 occurrences
|
||||
// PhanPluginDuplicateExpressionBinaryOp : 7 occurrences
|
||||
// PhanParamTooMany : 5 occurrences
|
||||
// PhanTypeExpectedObjectPropAccessButGotNull : 5 occurrences
|
||||
// PhanParamTooMany : 4 occurrences
|
||||
// PhanPluginDuplicateArrayKey : 4 occurrences
|
||||
// PhanEmptyFQSENInClasslike : 3 occurrences
|
||||
// PhanInvalidFQSENInClasslike : 3 occurrences
|
||||
|
|
@ -58,12 +58,11 @@ return [
|
|||
'htdocs/adherents/stats/index.php' => ['PhanTypeInvalidDimOffset'],
|
||||
'htdocs/admin/fckeditor.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/api/class/api_access.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/api/class/api_documents.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginDuplicateExpressionBinaryOp', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/api/class/api_documents.class.php' => ['PhanPluginDuplicateExpressionBinaryOp', 'PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/api/class/api_login.class.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/api/class/api_setup.class.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/api/class/api_status.class.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/asset/admin/setup.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/asset/card.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/asset/class/asset.class.php' => ['PhanPluginUndeclaredVariableIsset'],
|
||||
'htdocs/asset/class/assetaccountancycodes.class.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownArrayPropertyType'],
|
||||
'htdocs/asset/class/assetdepreciationoptions.class.php' => ['PhanPluginUnknownArrayPropertyType', 'PhanTypeInvalidDimOffset'],
|
||||
|
|
@ -79,14 +78,14 @@ return [
|
|||
'htdocs/barcode/printsheet.php' => ['PhanPluginDuplicateExpressionBinaryOp', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/blockedlog/ajax/block-info.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/blockedlog/class/blockedlog.class.php' => ['PhanTypeSuspiciousNonTraversableForeach'],
|
||||
'htdocs/bom/bom_card.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/bom/bom_card.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/bom/bom_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/bom/class/api_boms.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/bom/class/bom.class.php' => ['PhanPluginUnknownArrayMethodParamType'],
|
||||
'htdocs/bom/lib/bom.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/bom/tpl/objectline_edit.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/bom/tpl/objectline_view.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/bookcal/availabilities_card.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/bookcal/availabilities_card.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/bookcal/availabilities_list.php' => ['PhanPluginUndeclaredVariableIsset', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/bookcal/booking_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/bookcal/calendar_card.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
|
|
@ -117,7 +116,7 @@ return [
|
|||
'htdocs/comm/action/peruser.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanTypeComparisonFromArray'],
|
||||
'htdocs/comm/mailing/card.php' => ['PhanPluginSuspiciousParamPosition', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/comm/mailing/cibles.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredMethod', 'PhanUndeclaredProperty'],
|
||||
'htdocs/comm/mailing/class/advtargetemailing.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayPropertyType', 'PhanPluginUnknownPropertyType'],
|
||||
'htdocs/comm/mailing/class/advtargetemailing.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayPropertyType'],
|
||||
'htdocs/comm/mailing/class/html.formadvtargetemailing.class.php' => ['PhanPluginUnknownArrayMethodParamType'],
|
||||
'htdocs/comm/mailing/class/mailing.class.php' => ['PhanPluginUnknownArrayPropertyType'],
|
||||
'htdocs/comm/mailing/index.php' => ['PhanUndeclaredProperty'],
|
||||
|
|
@ -337,7 +336,6 @@ return [
|
|||
'htdocs/core/db/sqlite3.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeComparisonFromArray', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/extrafieldsinimport.inc.php' => ['PhanTypeMismatchArgumentNullableInternal'],
|
||||
'htdocs/core/filemanagerdol/connectors/php/connector.lib.php' => ['PhanPluginConstantVariableNull', 'PhanPluginUnknownArrayFunctionParamType', 'PhanTypeInvalidDimOffset'],
|
||||
'htdocs/core/get_info.php' => ['PhanPluginSuspiciousParamPosition'],
|
||||
'htdocs/core/lib/accounting.lib.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/admin.lib.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayFunctionReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/lib/agenda.lib.php' => ['PhanPluginConstantVariableNull', 'PhanPluginUnknownArrayFunctionReturnType', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
|
|
@ -354,7 +352,6 @@ return [
|
|||
'htdocs/core/lib/eventorganization.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/expedition.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/expensereport.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/fichinter.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType', 'PhanPluginUnknownObjectMethodCall'],
|
||||
'htdocs/core/lib/files.lib.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/lib/fourn.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/ftp.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentNullableInternal'],
|
||||
|
|
@ -380,19 +377,15 @@ return [
|
|||
'htdocs/core/lib/price.lib.php' => ['PhanPluginSuspiciousParamPosition', 'PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayFunctionReturnType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/lib/product.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/lib/project.lib.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/lib/propal.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType', 'PhanPluginUnknownObjectMethodCall'],
|
||||
'htdocs/core/lib/receiptprinter.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/reception.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/report.lib.php' => ['PhanPluginUnknownArrayFunctionParamType'],
|
||||
'htdocs/core/lib/resource.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/salaries.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/security.lib.php' => ['PhanPluginUnknownArrayFunctionParamType'],
|
||||
'htdocs/core/lib/security2.lib.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/lib/sendings.lib.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/lib/signature.lib.php' => ['PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/lib/socialnetwork.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/stock.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/supplier_proposal.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType', 'PhanPluginUnknownObjectMethodCall'],
|
||||
'htdocs/core/lib/takepos.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/core/lib/tax.lib.php' => ['PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/lib/ticket.lib.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayFunctionReturnType'],
|
||||
|
|
@ -406,7 +399,6 @@ return [
|
|||
'htdocs/core/modules/action/modules_action.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/core/modules/asset/doc/pdf_standard_asset.modules.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/asset/mod_asset_advanced.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/bank/doc/pdf_sepamandate.modules.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/barcode/doc/phpbarcode.modules.php' => ['PhanPossiblyNullTypeMismatchProperty', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/modules/barcode/mod_barcode_product_standard.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/core/modules/barcode/modules_barcode.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
|
|
@ -415,32 +407,26 @@ return [
|
|||
'htdocs/core/modules/cheque/modules_chequereceipts.php' => ['PhanUndeclaredMethod'],
|
||||
'htdocs/core/modules/commande/doc/pdf_einstein.modules.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/commande/doc/pdf_eratosthene.modules.php' => ['PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentNullableInternal', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/commande/mod_commande_saphir.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/commande/modules_commande.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/core/modules/contract/doc/pdf_strato.modules.php' => ['PhanTypeMismatchArgumentNullableInternal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/delivery/doc/pdf_storm.modules.php' => ['PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/delivery/doc/pdf_typhon.modules.php' => ['PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/delivery/mod_delivery_saphir.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/dons/modules_don.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/core/modules/expedition/doc/pdf_espadon.modules.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/expedition/doc/pdf_espadon.modules.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/expedition/doc/pdf_merou.modules.php' => ['PhanPluginUnknownPropertyType', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/expedition/doc/pdf_rouget.modules.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/expedition/doc/pdf_rouget.modules.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/expensereport/doc/pdf_standard_expensereport.modules.php' => ['PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/expensereport/mod_expensereport_sand.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/facture/doc/doc_generic_invoice_odt.modules.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/facture/doc/pdf_crabe.modules.php' => ['PhanPluginEmptyStatementIf', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/facture/doc/pdf_octopus.modules.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/facture/doc/pdf_sponge.modules.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/facture/mod_facture_mercure.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/facture/modules_facture.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/fichinter/mod_pacific.php' => ['PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/modules/hrm/doc/pdf_standard_evaluation.modules.php' => ['PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/hrm/mod_evaluation_advanced.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/hrm/mod_evaluation_advanced.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/import/import_csv.modules.php' => ['PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/core/modules/import/import_xlsx.modules.php' => ['PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/core/modules/import/modules_import.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownObjectMethodCall', 'PhanTypeMismatchDimFetch'],
|
||||
'htdocs/core/modules/mailings/advthirdparties.modules.php' => ['PhanPluginUnknownArrayMethodParamType'],
|
||||
'htdocs/core/modules/mailings/contacts1.modules.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/mailings/modules_mailings.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownArrayPropertyType'],
|
||||
'htdocs/core/modules/mailings/thirdparties.modules.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
|
|
@ -449,27 +435,21 @@ return [
|
|||
'htdocs/core/modules/member/modules_cards.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/core/modules/movement/doc/pdf_standard_movementstock.modules.php' => ['PhanPluginDuplicateExpressionBinaryOp', 'PhanPluginEmptyStatementIf', 'PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/modules/mrp/doc/pdf_vinci.modules.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/mrp/mod_mo_advanced.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/mrp/mod_mo_advanced.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/oauth/github_oauthcallback.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/modules/oauth/stripelive_oauthcallback.php' => ['PhanPluginUnknownObjectMethodCall'],
|
||||
'htdocs/core/modules/oauth/stripetest_oauthcallback.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/modules/printing/modules_printing.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/core/modules/printing/printgcp.modules.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownArrayPropertyType'],
|
||||
'htdocs/core/modules/printsheet/doc/pdf_standardlabel.class.php' => ['PhanPluginUnknownArrayMethodParamType'],
|
||||
'htdocs/core/modules/printsheet/doc/pdf_tcpdflabel.class.php' => ['PhanPluginUnknownArrayMethodParamType'],
|
||||
'htdocs/core/modules/printsheet/modules_labels.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownObjectMethodCall'],
|
||||
'htdocs/core/modules/printsheet/modules_labels.php' => ['PhanParamTooMany'],
|
||||
'htdocs/core/modules/product/doc/pdf_standard.modules.php' => ['PhanPluginEmptyStatementIf', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/modules/product_batch/mod_lot_advanced.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/product_batch/mod_sn_advanced.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/project/doc/pdf_baleine.modules.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/project/doc/pdf_beluga.modules.php' => ['PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/project/doc/pdf_timespent.modules.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/project/mod_project_universal.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/project/task/doc/doc_generic_task_odt.modules.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/propale/doc/pdf_azur.modules.php' => ['PhanPluginEmptyStatementIf', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/propale/doc/pdf_cyan.modules.php' => ['PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/propale/mod_propale_saphir.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/propale/modules_propale.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/core/modules/rapport/pdf_paiement.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/modules/reception/doc/pdf_squille.modules.php' => ['PhanTypeMismatchArgumentNullableInternal', 'PhanUndeclaredProperty'],
|
||||
|
|
@ -479,7 +459,7 @@ return [
|
|||
'htdocs/core/modules/stock/doc/pdf_standard_stock.modules.php' => ['PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/modules/stocktransfer/doc/pdf_eagle.modules.php' => ['PhanPossiblyUndeclaredVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/stocktransfer/doc/pdf_eagle_proforma.modules.php' => ['PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/stocktransfer/mod_stocktransfer_advanced.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/stocktransfer/mod_stocktransfer_advanced.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/supplier_invoice/doc/doc_generic_supplier_invoice_odt.modules.php' => ['PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/core/modules/supplier_invoice/doc/pdf_canelle.modules.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/supplier_order/doc/doc_generic_supplier_order_odt.modules.php' => ['PhanPossiblyUndeclaredVariable'],
|
||||
|
|
@ -492,18 +472,13 @@ return [
|
|||
'htdocs/core/modules/supplier_proposal/doc/pdf_zenith.modules.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/syslog/mod_syslog_file.php' => ['PhanPluginDuplicateArrayKey'],
|
||||
'htdocs/core/modules/syslog/mod_syslog_syslog.php' => ['PhanPluginConstantVariableNull', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/takepos/mod_takepos_ref_universal.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/ticket/doc/doc_generic_ticket_odt.modules.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeSuspiciousNonTraversableForeach'],
|
||||
'htdocs/core/modules/ticket/mod_ticket_universal.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/core/modules/user/doc/doc_generic_user_odt.modules.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeSuspiciousNonTraversableForeach'],
|
||||
'htdocs/core/modules/workstation/mod_workstation_advanced.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/modules/workstation/mod_workstation_advanced.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/search_page.php' => ['PhanEmptyForeach', 'PhanPluginBothLiteralsBinaryOp'],
|
||||
'htdocs/core/tpl/ajaxrow.tpl.php' => ['PhanPluginUndeclaredVariableIsset', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/bloc_comment.tpl.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/card_presend.tpl.php' => ['PhanPluginUndeclaredVariableIsset', 'PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentNullableInternal', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/tpl/commonfields_edit.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/tpl/commonfields_view.tpl.php' => ['PhanPossiblyUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/contacts.tpl.php' => ['PhanPluginUndeclaredVariableIsset', 'PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/document_actions_post_headers.tpl.php' => ['PhanPluginUndeclaredVariableIsset', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/extrafields_edit.tpl.php' => ['PhanPluginUndeclaredVariableIsset'],
|
||||
'htdocs/core/tpl/extrafields_list_search_title.tpl.php' => ['PhanPluginUndeclaredVariableIsset'],
|
||||
|
|
@ -523,9 +498,9 @@ return [
|
|||
'htdocs/core/tpl/passwordforgotten.tpl.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/passwordreset.tpl.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/resource_add.tpl.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/resource_view.tpl.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/core/tpl/resource_view.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/triggers/dolibarrtriggers.class.php' => ['PhanPluginUnknownArrayPropertyType'],
|
||||
'htdocs/core/triggers/interface_20_modWorkflow_WorkflowManager.class.php' => ['PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/triggers/interface_20_modWorkflow_WorkflowManager.class.php' => ['PhanPossiblyUndeclaredVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/triggers/interface_50_modAgenda_ActionsAuto.class.php' => ['PhanTypeComparisonFromArray', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/core/triggers/interface_50_modMailmanspip_Mailmanspipsynchro.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/core/triggers/interface_50_modNotification_Notification.class.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
|
|
@ -535,7 +510,6 @@ return [
|
|||
'htdocs/cron/card.php' => ['PhanPluginBothLiteralsBinaryOp'],
|
||||
'htdocs/cron/class/cronjob.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/cron/list.php' => ['PhanPossiblyUndeclaredGlobalVariable'],
|
||||
'htdocs/datapolicy/class/datapolicy.class.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType'],
|
||||
'htdocs/datapolicy/class/datapolicycron.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/datapolicy/lib/datapolicy.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/debugbar/class/DataCollector/DolConfigCollector.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
|
|
@ -551,7 +525,7 @@ return [
|
|||
'htdocs/delivery/class/delivery.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/delivery/tpl/linkedobjectblock.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/document.php' => ['PhanRedefineFunction'],
|
||||
'htdocs/don/admin/donation.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/don/admin/donation.php' => ['PhanUndeclaredMethod'],
|
||||
'htdocs/don/card.php' => ['PhanPluginUndeclaredVariableIsset', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/don/class/api_donations.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/don/class/don.class.php' => ['PhanParamTooMany', 'PhanPluginEmptyStatementIf', 'PhanPluginUnknownPropertyType'],
|
||||
|
|
@ -579,17 +553,17 @@ return [
|
|||
'htdocs/emailcollector/class/emailcollectorfilter.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/emailcollector/lib/emailcollector.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/eventorganization/class/conferenceorbooth.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/eventorganization/class/conferenceorboothattendee.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownPropertyType', 'PhanPossiblyNullTypeMismatchProperty', 'PhanUndeclaredMethod', 'PhanUndeclaredProperty'],
|
||||
'htdocs/eventorganization/conferenceorbooth_card.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/eventorganization/class/conferenceorboothattendee.class.php' => ['PhanPluginUnknownPropertyType', 'PhanPossiblyNullTypeMismatchProperty', 'PhanUndeclaredMethod', 'PhanUndeclaredProperty'],
|
||||
'htdocs/eventorganization/conferenceorbooth_card.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/eventorganization/conferenceorbooth_contact.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/eventorganization/conferenceorbooth_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/eventorganization/conferenceorboothattendee_card.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/eventorganization/conferenceorboothattendee_card.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/eventorganization/conferenceorboothattendee_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/eventorganization/core/actions_massactions_mail.inc.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentNullableInternal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/eventorganization/core/actions_massactions_mail.inc.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/eventorganization/lib/eventorganization_conferenceorbooth.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/expedition/card.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/expedition/card.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/expedition/class/api_shipments.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/expedition/class/expedition.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/expedition/class/expedition.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/expedition/class/expeditionlinebatch.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/expedition/class/expeditionstats.class.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/expedition/contact.php' => ['PhanPossiblyUndeclaredGlobalVariable'],
|
||||
|
|
@ -613,8 +587,7 @@ return [
|
|||
'htdocs/externalsite/frames.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/fichinter/card-rec.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fichinter/class/api_interventions.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fichinter/class/fichinter.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall'],
|
||||
'htdocs/fichinter/class/fichinterrec.class.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fichinter/class/fichinterrec.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/fichinter/class/fichinterstats.class.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownPropertyType'],
|
||||
'htdocs/fichinter/list.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/fichinter/tpl/linkedobjectblock.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
|
|
@ -625,7 +598,6 @@ return [
|
|||
'htdocs/fourn/class/fournisseur.class.php' => ['PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/fourn/class/fournisseur.commande.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentNullableInternal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/class/fournisseur.facture-rec.class.php' => ['PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/class/fournisseur.product.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/fourn/class/paiementfourn.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownPropertyType', 'PhanPossiblyNullTypeMismatchProperty', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/fourn/commande/card.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/commande/contact.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
|
|
@ -636,12 +608,12 @@ return [
|
|||
'htdocs/fourn/commande/note.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/fourn/commande/tpl/linkedobjectblock.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/contact.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/fourn/facture/card-rec.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/facture/card-rec.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/facture/card.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/fourn/facture/list-rec.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/fourn/facture/list.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/fourn/facture/paiement.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/fourn/facture/tpl/linkedobjectblock.tpl.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/facture/tpl/linkedobjectblock.tpl.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/fourn/paiement/card.php' => ['PhanPossiblyUndeclaredGlobalVariable'],
|
||||
'htdocs/fourn/paiement/document.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/fourn/product/list.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
|
|
@ -652,20 +624,19 @@ return [
|
|||
'htdocs/holiday/list.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/holiday/view_log.php' => ['PhanTypeMismatchDimFetch'],
|
||||
'htdocs/hrm/admin/admin_hrm.php' => ['PhanEmptyForeach', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/hrm/class/evaluation.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/evaluationdet.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/job.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanPossiblyNullTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/position.class.php' => ['PhanPluginEmptyStatementIf', 'PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanPossiblyNullTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/skill.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/skilldet.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/skillrank.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/evaluation.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/evaluationdet.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/job.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/position.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/skill.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/skilldet.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/class/skillrank.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/compare.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/hrm/core/tpl/objectline_view.tpl.php' => ['PhanPluginEmptyStatementIf', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/evaluation_card.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/hrm/evaluation_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/hrm/index.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/hrm/job_agenda.php' => ['PhanPossiblyUndeclaredGlobalVariable'],
|
||||
'htdocs/hrm/job_card.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/hrm/job_card.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/hrm/job_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/hrm/lib/hrm.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/hrm/lib/hrm_job.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
|
|
@ -673,11 +644,9 @@ return [
|
|||
'htdocs/hrm/lib/hrm_skill.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/hrm/lib/hrm_skilldet.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/hrm/lib/hrm_skillrank.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/hrm/position_card.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/hrm/position_list.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/hrm/skill_card.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanTypeExpectedObjectPropAccess', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/skill_card.php' => ['PhanTypeExpectedObjectPropAccess', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/hrm/skill_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/hrm/skill_tab.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/imports/class/import.class.php' => ['PhanPluginEmptyStatementIf'],
|
||||
'htdocs/imports/emptyexample.php' => ['PhanRedefineFunction', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/imports/import.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayFunctionReturnType', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentNullableInternal', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
|
|
@ -690,16 +659,13 @@ return [
|
|||
'htdocs/install/step2.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentNullableInternal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/install/step5.php' => ['PhanPluginUndeclaredVariableIsset'],
|
||||
'htdocs/install/upgrade.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentNullableInternal'],
|
||||
'htdocs/install/upgrade2.php' => ['PhanPluginEmptyStatementIf', 'PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentNullableInternal'],
|
||||
'htdocs/intracommreport/card.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/intracommreport/class/intracommreport.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownPropertyType', 'PhanPossiblyUndeclaredVariable'],
|
||||
'htdocs/intracommreport/lib/intracommreport.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/knowledgemanagement/class/api_knowledgemanagement.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/knowledgemanagement/class/knowledgerecord.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/knowledgemanagement/class/knowledgerecord.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/knowledgemanagement/knowledgerecord_card.php' => ['PhanPluginEmptyStatementIf', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/knowledgemanagement/knowledgerecord_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/knowledgemanagement/lib/knowledgemanagement.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/knowledgemanagement/lib/knowledgemanagement_knowledgerecord.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/loan/card.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentNullableInternal', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/loan/class/loan.class.php' => ['PhanPluginUnknownPropertyType', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/loan/class/loanschedule.class.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownPropertyType'],
|
||||
|
|
@ -715,7 +681,7 @@ return [
|
|||
'htdocs/margin/productMargins.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/master.inc.php' => ['PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/mrp/class/api_mos.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType'],
|
||||
'htdocs/mrp/class/mo.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/mrp/class/mo.class.php' => ['PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/mrp/lib/mrp.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/mrp/lib/mrp_mo.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/mrp/mo_card.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
|
|
@ -765,7 +731,7 @@ return [
|
|||
'htdocs/product/dynamic_price/class/price_global_variable_updater.class.php' => ['PhanPluginEmptyStatementIf', 'PhanPluginUnknownPropertyType'],
|
||||
'htdocs/product/dynamic_price/class/price_parser.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownPropertyType'],
|
||||
'htdocs/product/index.php' => ['PhanPluginUndeclaredVariableIsset'],
|
||||
'htdocs/product/inventory/card.php' => ['PhanPluginEmptyStatementIf', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/product/inventory/card.php' => ['PhanPluginEmptyStatementIf', 'PhanPossiblyUndeclaredGlobalVariable'],
|
||||
'htdocs/product/inventory/class/inventory.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/product/inventory/inventory.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/product/inventory/lib/inventory.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
|
|
@ -902,9 +868,9 @@ return [
|
|||
'htdocs/recruitment/recruitmentjobposition_document.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/recruitment/recruitmentjobposition_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/recruitment/recruitmentjobposition_note.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
|
||||
'htdocs/resource/class/dolresource.class.php' => ['PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownArrayPropertyType', 'PhanPluginUnknownPropertyType'],
|
||||
'htdocs/resource/class/dolresource.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/resource/class/html.formresource.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanTypeExpectedObjectPropAccess'],
|
||||
'htdocs/resource/element_resource.php' => ['PhanPluginUnknownObjectMethodCall', 'PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/resource/element_resource.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/salaries/admin/salaries.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/salaries/card.php' => ['PhanPossiblyUndeclaredGlobalVariable'],
|
||||
'htdocs/salaries/class/api_salaries.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType'],
|
||||
|
|
@ -982,7 +948,6 @@ return [
|
|||
'htdocs/user/class/api_users.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanTypeMismatchArgumentProbablyReal', 'PhanTypeMismatchProperty'],
|
||||
'htdocs/user/class/user.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownArrayPropertyType', 'PhanPluginUnknownObjectMethodCall', 'PhanPluginUnknownPropertyType', 'PhanPossiblyNullTypeMismatchProperty', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
|
||||
'htdocs/user/class/usergroup.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayMethodReturnType', 'PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/user/group/card.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/user/param_ihm.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/user/passwordforgotten.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/variants/ajax/get_attribute_values.php' => ['PhanTypeComparisonFromArray'],
|
||||
|
|
@ -998,16 +963,14 @@ return [
|
|||
'htdocs/webhook/lib/webhook_target.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/webhook/target_card.php' => ['PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredGlobalVariable'],
|
||||
'htdocs/webhook/target_list.php' => ['PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/webportal/class/context.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownArrayPropertyType', 'PhanPluginUnknownPropertyType', 'PhanTypeMismatchArgumentProbablyReal'],
|
||||
'htdocs/webportal/class/context.class.php' => ['PhanPluginUnknownArrayMethodParamType'],
|
||||
'htdocs/webportal/class/controller.class.php' => ['PhanPluginUnknownArrayMethodParamType'],
|
||||
'htdocs/webportal/class/html.formcardwebportal.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/webportal/class/html.formlistwebportal.class.php' => ['PhanPluginUnknownArrayPropertyType', 'PhanPossiblyUndeclaredVariable', 'PhanTypeMismatchArgumentProbablyReal', 'PhanUndeclaredProperty'],
|
||||
'htdocs/webportal/class/html.formwebportal.class.php' => ['PhanPluginUnknownArrayMethodParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanTypeInvalidDimOffset', 'PhanTypeMismatchDimFetch'],
|
||||
'htdocs/webportal/class/webPortalTheme.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/webportal/class/html.formwebportal.class.php' => ['PhanTypeInvalidDimOffset'],
|
||||
'htdocs/webportal/class/webportalinvoice.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/webportal/class/webportalmember.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/webportal/class/webportalorder.class.php' => ['PhanPluginUnknownPropertyType'],
|
||||
'htdocs/webportal/class/webportalpropal.class.php' => ['PhanPluginUnknownPropertyType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/webportal/class/webportalpropal.class.php' => ['PhanUndeclaredProperty'],
|
||||
'htdocs/webportal/lib/webportal.lib.php' => ['PhanPluginUnknownArrayFunctionReturnType'],
|
||||
'htdocs/webservices/server_actioncomm.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownArrayFunctionReturnType', 'PhanUndeclaredProperty'],
|
||||
'htdocs/webservices/server_category.php' => ['PhanPluginUnknownArrayFunctionParamType', 'PhanPluginUnknownObjectMethodCall', 'PhanUndeclaredProperty'],
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
* Copyright (C) 2017-2024 Alexandre Spangaro <aspangaro@easya.solutions>
|
||||
* Copyright (C) 2022 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -164,7 +165,7 @@ if (!empty($cat_id)) {
|
|||
}
|
||||
|
||||
if (is_array($accountingcategory->lines_cptbk) && count($accountingcategory->lines_cptbk) > 0) {
|
||||
print img_picto($langs->trans("AccountingAccount"), 'accounting_account', 'class="pictofixedwith"');
|
||||
print img_picto($langs->trans("AccountingAccount"), 'accounting_account', 'class="pictofixedwidth"');
|
||||
print $form->multiselectarray('cpt_bk', $arraykeyvalue, GETPOST('cpt_bk', 'array'), 0, 0, '', 0, "80%", '', '', $langs->transnoentitiesnoconv("AddAccountFromBookKeepingWithNoCategories"));
|
||||
print '<input type="submit" class="button button-add small" id="" class="action-delete" value="'.$langs->trans("Add").'"> ';
|
||||
}
|
||||
|
|
|
|||
|
|
@ -438,7 +438,7 @@ if ($id) {
|
|||
print '</tr>';
|
||||
|
||||
// Line to enter new values
|
||||
print '<tr class="oddeven nodrag nodrap nohover">';
|
||||
print '<tr class="oddeven nodrag nodrop nohover">';
|
||||
|
||||
$obj = new stdClass();
|
||||
// If data was already input, we define them in obj to populate input fields.
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
||||
* Copyright (C) 2006-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -311,7 +312,7 @@ foreach (array_keys($_Avery_Labels) as $codecards) {
|
|||
}
|
||||
asort($arrayoflabels);
|
||||
print $form->selectarray('model', $arrayoflabels, (GETPOST('model') ? GETPOST('model') : getDolGlobalString('ADHERENT_CARD_TYPE')), 1, 0, 0, '', 0, 0, 0, '', '', 1);
|
||||
print '<br>'.$langs->trans("Login").': <input class="with100" type="text" name="foruserlogin" value="'.GETPOST('foruserlogin').'">';
|
||||
print '<br>'.$langs->trans("Login").': <input class="width100" type="text" name="foruserlogin" value="'.GETPOST('foruserlogin').'">';
|
||||
print '<br><input type="submit" class="button small" value="'.$langs->trans("BuildDoc").'">';
|
||||
print '</form>';
|
||||
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ require_once DOL_DOCUMENT_ROOT.'/projet/class/api_projects.class.php';
|
|||
class Categories extends DolibarrApi
|
||||
{
|
||||
/**
|
||||
* @var array $FIELDS Mandatory fields, checked when create and update object
|
||||
* @var string[] $FIELDS Mandatory fields, checked when create and update object
|
||||
*/
|
||||
public static $FIELDS = array(
|
||||
'label',
|
||||
|
|
|
|||
|
|
@ -257,7 +257,7 @@ class PropaleLigne extends CommonObjectLine
|
|||
|
||||
/**
|
||||
* Product use lot
|
||||
* @var string
|
||||
* @var int
|
||||
*/
|
||||
public $product_tobatch;
|
||||
|
||||
|
|
@ -445,7 +445,7 @@ class PropaleLigne extends CommonObjectLine
|
|||
/**
|
||||
* Insert object line propal in database
|
||||
*
|
||||
* @param int $notrigger 1=Does not execute triggers, 0= execute triggers
|
||||
* @param int<0,1> $notrigger 1=Does not execute triggers, 0= execute triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function insert($notrigger = 0)
|
||||
|
|
|
|||
|
|
@ -328,14 +328,14 @@ if ($nb) {
|
|||
print '<option value="RCUR"'.($format == 'RCUR' ? ' selected="selected"' : '').'>'.$langs->trans('SEPARCUR').'</option>';
|
||||
print '</select>';
|
||||
}
|
||||
print '<input type="submit" class="butAction margintoponly maringbottomonly" value="'.$title.'"/>';
|
||||
print '<input type="submit" class="butAction margintoponly marginbottomonly" value="'.$title.'"/>';
|
||||
} else {
|
||||
$title = $langs->trans("CreateAll");
|
||||
if ($type == 'bank-transfer') {
|
||||
$title = $langs->trans("CreateFileForPaymentByBankTransfer");
|
||||
}
|
||||
print '<input type="hidden" name="format" value="ALL">'."\n";
|
||||
print '<input type="submit" class="butAction margintoponly maringbottomonly" value="'.$title.'">'."\n";
|
||||
print '<input type="submit" class="butAction margintoponly marginbottomonly" value="'.$title.'">'."\n";
|
||||
}
|
||||
} else {
|
||||
if ($mysoc->isInEEC()) {
|
||||
|
|
@ -343,18 +343,18 @@ if ($nb) {
|
|||
if ($type == 'bank-transfer') {
|
||||
$title = $langs->trans("CreateSepaFileForPaymentByBankTransfer");
|
||||
}
|
||||
print '<a class="butActionRefused classfortooltip margintoponly maringbottomonly" href="#" title="'.$langs->trans("AmountMustBePositive").'">'.$title."</a>\n";
|
||||
print '<a class="butActionRefused classfortooltip margintoponly marginbottomonly" href="#" title="'.$langs->trans("AmountMustBePositive").'">'.$title."</a>\n";
|
||||
|
||||
if ($type != 'bank-transfer') {
|
||||
$title = $langs->trans("CreateForSepaRCUR");
|
||||
print '<a class="butActionRefused classfortooltip margintoponly maringbottomonly" href="#" title="'.$langs->trans("AmountMustBePositive").'">'.$title."</a>\n";
|
||||
print '<a class="butActionRefused classfortooltip margintoponly marginbottomonly" href="#" title="'.$langs->trans("AmountMustBePositive").'">'.$title."</a>\n";
|
||||
}
|
||||
} else {
|
||||
$title = $langs->trans("CreateAll");
|
||||
if ($type == 'bank-transfer') {
|
||||
$title = $langs->trans("CreateFileForPaymentByBankTransfer");
|
||||
}
|
||||
print '<a class="butActionRefused classfortooltip margintoponly maringbottomonly" href="#">'.$title."</a>\n";
|
||||
print '<a class="butActionRefused classfortooltip margintoponly marginbottomonly" href="#">'.$title."</a>\n";
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
|
@ -364,7 +364,7 @@ if ($nb) {
|
|||
$titlefortab = $langs->transnoentitiesnoconv("PaymentByBankTransfers");
|
||||
$title = $langs->trans("CreateFileForPaymentByBankTransfer");
|
||||
}
|
||||
print '<a class="butActionRefused classfortooltip margintoponly maringbottomonly" href="#" title="'.dol_escape_htmltag($langs->transnoentitiesnoconv("NoInvoiceToWithdraw", $titlefortab, $titlefortab)).'">';
|
||||
print '<a class="butActionRefused classfortooltip margintoponly marginbottomonly" href="#" title="'.dol_escape_htmltag($langs->transnoentitiesnoconv("NoInvoiceToWithdraw", $titlefortab, $titlefortab)).'">';
|
||||
print $title;
|
||||
print "</a>\n";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2005-2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -172,7 +173,7 @@ if ($result) {
|
|||
$thirdpartystatic->id = $obj->socid;
|
||||
$thirdpartystatic->name = $obj->name;
|
||||
|
||||
print '<td class="tdoverlowmax200"><a href="'.DOL_URL_ROOT.'/comm/card.php?socid='.$obj->socid.'">'.$thirdpartystatic->getNomUrl(1)."</a></td>\n";
|
||||
print '<td class="tdoverflowmax200"><a href="'.DOL_URL_ROOT.'/comm/card.php?socid='.$obj->socid.'">'.$thirdpartystatic->getNomUrl(1)."</a></td>\n";
|
||||
}
|
||||
|
||||
print '<td>'.$rej->motifs[$obj->motif].'</td>';
|
||||
|
|
|
|||
|
|
@ -243,7 +243,7 @@ if (isModEnabled('tax') && $user->hasRight('tax', 'charges', 'lire')) {
|
|||
|
||||
// Date payment
|
||||
$datep = $db->jdate($obj->datep);
|
||||
print '<td class="center nowraponalls">' . dol_print_date($datep, 'day') . '</td>';
|
||||
print '<td class="center nowraponall">' . dol_print_date($datep, 'day') . '</td>';
|
||||
|
||||
// Type payment
|
||||
$labelpaymenttype = '';
|
||||
|
|
|
|||
|
|
@ -914,7 +914,7 @@ abstract class CommonDocGenerator
|
|||
$array_key.'_tracking_number' => $object->tracking_number,
|
||||
$array_key.'_tracking_url' => $object->tracking_url,
|
||||
$array_key.'_shipping_method' => $object->listmeths[0]['libelle'],
|
||||
$array_key.'_weight' => $object->trueWeight.' '.measuringUnitString(0, 'weight', $object->weight_units),
|
||||
$array_key.'_weight' => $object->trueWeight.' '.measuringUnitString(0, 'weight', (string) $object->weight_units),
|
||||
$array_key.'_width' => $object->trueWidth.' '.measuringUnitString(0, 'size', $object->width_units),
|
||||
$array_key.'_height' => $object->trueHeight.' '.measuringUnitString(0, 'size', $object->height_units),
|
||||
$array_key.'_depth' => $object->trueDepth.' '.measuringUnitString(0, 'size', $object->depth_units),
|
||||
|
|
|
|||
|
|
@ -162,7 +162,7 @@ abstract class CommonOrderLine extends CommonObjectLine
|
|||
|
||||
/**
|
||||
* Product use lot
|
||||
* @var string
|
||||
* @var int
|
||||
*/
|
||||
public $product_tobatch;
|
||||
|
||||
|
|
|
|||
|
|
@ -5808,7 +5808,7 @@ class Form
|
|||
$formconfirm .= "\n<!-- begin formconfirm page=" . dol_escape_htmltag($page) . " -->\n";
|
||||
|
||||
if (empty($disableformtag)) {
|
||||
$formconfirm .= '<form method="POST" action="' . $page . '" class="notoptoleftroright">' . "\n";
|
||||
$formconfirm .= '<form method="POST" action="' . $page . '" class="notoptoleftnoright">' . "\n";
|
||||
}
|
||||
|
||||
$formconfirm .= '<input type="hidden" name="action" value="' . $action . '">' . "\n";
|
||||
|
|
@ -9537,8 +9537,8 @@ class Form
|
|||
* Show block with links "to link to" other objects.
|
||||
*
|
||||
* @param CommonObject $object Object we want to show links to
|
||||
* @param string[] $restrictlinksto Restrict links to some elements, for example array('order') or array('supplier_order'). null or array() if no restriction.
|
||||
* @param string[] $excludelinksto Do not show links of this type, for example array('order') or array('supplier_order'). null or array() if no exclusion.
|
||||
* @param string[]|null $restrictlinksto Restrict links to some elements, for example array('order') or array('supplier_order'). null or array() if no restriction.
|
||||
* @param string[]|null $excludelinksto Do not show links of this type, for example array('order') or array('supplier_order'). null or array() if no exclusion.
|
||||
* @param int<0,1> $nooutput 1=Return array with content instead of printing it.
|
||||
* @return array{linktoelem:string,htmltoenteralink:string}|string HTML block
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -1407,7 +1407,7 @@ class FormFile
|
|||
|
||||
|
||||
// File name
|
||||
print '<td class="minwith200 tdoverflowmax500" title="'.dolPrintHTMLForAttribute($file['name']).'">';
|
||||
print '<td class="minwidth200 tdoverflowmax500" title="'.dolPrintHTMLForAttribute($file['name']).'">';
|
||||
|
||||
// Show file name with link to download
|
||||
//print "XX".$file['name']; //$file['name'] must be utf8
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
<?php
|
||||
/* Copyright (C) 2018 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This file is a modified version of datepicker.php from phpBSM to fix some
|
||||
* bugs, to add new features and to dramatically increase speed.
|
||||
|
|
@ -111,9 +112,9 @@ print '<div class="login_block_getinfo">'."\n";
|
|||
$toprightmenu .= '<div class="login_block_user">';
|
||||
|
||||
// Login name with photo and tooltip
|
||||
$mode = -1;
|
||||
$picto = -1;
|
||||
$toprightmenu .= '<div class="inline-block nowrap"><div class="inline-block login_block_elem login_block_elem_name" style="padding: 0px;">';
|
||||
$toprightmenu .= $user->getNomUrl($mode, '', -1, 0, 11, 0, ($user->firstname ? 'firstname' : -1), 'atoplogin');
|
||||
$toprightmenu .= $user->getNomUrl($picto, '', -1, 0, 11, 0, ($user->firstname ? 'firstname' : -1), 'atoplogin');
|
||||
$toprightmenu .= '</div></div>';
|
||||
|
||||
$toprightmenu .= '</div>'."\n";
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@
|
|||
/**
|
||||
* Prepare array with list of tabs
|
||||
*
|
||||
* @param Object $object Object related to tabs
|
||||
* @param CommonObject $object Object related to tabs
|
||||
* @return array<array{0:string,1:string,2:string}> Array of tabs to show
|
||||
*/
|
||||
function fichinter_prepare_head($object)
|
||||
|
|
@ -165,7 +165,7 @@ function fichinter_prepare_head($object)
|
|||
/**
|
||||
* Return array head with list of tabs to view object information.
|
||||
*
|
||||
* @return array head array with tabs
|
||||
* @return array<array{0:string,1:string,2:string}> head array with tabs
|
||||
*/
|
||||
function fichinter_admin_prepare_head()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -7614,7 +7614,7 @@ function get_default_tva(Societe $thirdparty_seller, Societe $thirdparty_buyer,
|
|||
* @param Societe $thirdparty_buyer Thirdparty buyer
|
||||
* @param int $idprod Id product
|
||||
* @param int $idprodfournprice Id supplier price for product
|
||||
* @return float 0 or 1
|
||||
* @return int<0,1> 0 or 1
|
||||
* @see get_default_tva(), get_default_localtax()
|
||||
*/
|
||||
function get_default_npr(Societe $thirdparty_seller, Societe $thirdparty_buyer, $idprod = 0, $idprodfournprice = 0)
|
||||
|
|
@ -13142,7 +13142,7 @@ function getElementProperties($elementType)
|
|||
* @param string $element_ref Element ref (Use this or element_id but not both. If id and ref are empty, object with no fetch is returned)
|
||||
* @param int<0,2> $useCache If you want to store object in cache or get it from cache 0 => no use cache , 1 use cache, 2 force reload cache
|
||||
* @param int $maxCacheByType Number of object in cache for this element type
|
||||
* @return int<-1,0>|object object || 0 || <0 if error
|
||||
* @return int<-1,0>|CommonObject object || 0 || <0 if error
|
||||
* @see getElementProperties()
|
||||
*/
|
||||
function fetchObjectByElement($element_id, $element_type, $element_ref = '', $useCache = 0, $maxCacheByType = 10)
|
||||
|
|
|
|||
|
|
@ -903,12 +903,12 @@ function array2table($data, $tableMarkup = 1, $tableoptions = '', $troptions = '
|
|||
* @param string $table Table containing field with counter
|
||||
* @param string $field Field containing already used values of counter
|
||||
* @param string $where To add a filter on selection (for example to filter on invoice types)
|
||||
* @param Societe|'' $objsoc The company that own the object we need a counter for
|
||||
* @param null|Societe|'' $objsoc The company that own the object we need a counter for
|
||||
* @param int|'' $date Date to use for the {y},{m},{d} tags. is timestamp or '' to use dol_now()
|
||||
* @param string $mode 'next' for next value or 'last' for last value
|
||||
* @param bool $bentityon Activate the entity filter. Default is true (for modules not compatible with multicompany)
|
||||
* @param User $objuser Object user we need data from.
|
||||
* @param string $forceentity Entity id to force, can be '0' or '1' or '1,2' etc
|
||||
* @param ?User $objuser Object user we need data from.
|
||||
* @param ?string $forceentity Entity id to force, can be '0' or '1' or '1,2' etc
|
||||
* @return string New value (numeric) or error message
|
||||
*/
|
||||
function get_next_value($db, $mask, $table, $field, $where = '', $objsoc = '', $date = '', $mode = 'next', $bentityon = true, $objuser = null, $forceentity = null)
|
||||
|
|
@ -916,7 +916,7 @@ function get_next_value($db, $mask, $table, $field, $where = '', $objsoc = '', $
|
|||
global $user;
|
||||
|
||||
if (!is_object($objsoc)) {
|
||||
$valueforccc = $objsoc;
|
||||
$valueforccc = (string) $objsoc;
|
||||
} elseif ($table == "commande_fournisseur" || $table == "facture_fourn" || $table == "paiementfourn") {
|
||||
$valueforccc = dol_string_unaccent($objsoc->code_fournisseur);
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -1008,7 +1008,7 @@ function pdf_bank(&$pdf, $outputlangs, $curx, $cury, $account, $onlynumber = 0,
|
|||
* @param TCPDF $pdf The PDF factory
|
||||
* @param Translate $outputlangs Object lang for output
|
||||
* @param string $paramfreetext Constant name of free text
|
||||
* @param Societe $fromcompany Object company
|
||||
* @param ?Societe $fromcompany Object company
|
||||
* @param int $marge_basse Margin bottom we use for the autobreak
|
||||
* @param int $marge_gauche Margin left (no more used)
|
||||
* @param int $page_hauteur Page height
|
||||
|
|
@ -1034,8 +1034,10 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_
|
|||
if (empty($hidefreetext) && getDolGlobalString($paramfreetext)) {
|
||||
$substitutionarray = pdf_getSubstitutionArray($outputlangs, null, $object);
|
||||
// More substitution keys
|
||||
$substitutionarray['__FROM_NAME__'] = $fromcompany->name;
|
||||
$substitutionarray['__FROM_EMAIL__'] = $fromcompany->email;
|
||||
if (is_object($fromcompany)) {
|
||||
$substitutionarray['__FROM_NAME__'] = $fromcompany->name;
|
||||
$substitutionarray['__FROM_EMAIL__'] = $fromcompany->email;
|
||||
}
|
||||
complete_substitutions_array($substitutionarray, $outputlangs, $object);
|
||||
$newfreetext = make_substitutions(getDolGlobalString($paramfreetext), $substitutionarray, $outputlangs);
|
||||
|
||||
|
|
@ -1054,7 +1056,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_
|
|||
$line3 = "";
|
||||
$line4 = "";
|
||||
|
||||
if ($showdetails == 1 || $showdetails == 3) {
|
||||
if (is_object($fromcompany) && in_array($showdetails, array(1, 3))) {
|
||||
// Company name
|
||||
if ($fromcompany->name) {
|
||||
$line1 .= ($line1 ? " - " : "").$outputlangs->transnoentities("RegisteredOffice").": ".$fromcompany->name;
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@
|
|||
/**
|
||||
* Prepare array with list of tabs
|
||||
*
|
||||
* @param object $object Object related to tabs
|
||||
* @param Propal $object Object related to tabs
|
||||
* @return array<array{0:string,1:string,2:string}> Array of tabs to show
|
||||
*/
|
||||
function propal_prepare_head($object)
|
||||
|
|
@ -154,7 +154,7 @@ function propal_prepare_head($object)
|
|||
/**
|
||||
* Return array head with list of tabs to view object information.
|
||||
*
|
||||
* @return array head array with tabs
|
||||
* @return array<array{0:string,1:string,2:string}> head array with tabs
|
||||
*/
|
||||
function propal_admin_prepare_head()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -48,12 +48,12 @@ function dol_getwebuser($mode)
|
|||
/**
|
||||
* Return a login if login/pass was successful
|
||||
*
|
||||
* @param string $usertotest Login value to test
|
||||
* @param string $passwordtotest Password value to test
|
||||
* @param string $entitytotest Instance of data we must check
|
||||
* @param array $authmode Array list of selected authentication mode array('http', 'dolibarr', 'xxx'...)
|
||||
* @param string $context Context checkLoginPassEntity was created for ('api', 'dav', 'ws', '')
|
||||
* @return string Login or '' or '--bad-login-validity--'
|
||||
* @param string $usertotest Login value to test
|
||||
* @param string $passwordtotest Password value to test
|
||||
* @param string $entitytotest Instance of data we must check
|
||||
* @param string[] $authmode Array list of selected authentication mode array('http', 'dolibarr', 'xxx'...)
|
||||
* @param 'api'|'dav'|'ws'|'' $context Context checkLoginPassEntity was created for ('api', 'dav', 'ws', '')
|
||||
* @return string Login or '' or '--bad-login-validity--'
|
||||
*/
|
||||
function checkLoginPassEntity($usertotest, $passwordtotest, $entitytotest, $authmode, $context = '')
|
||||
{
|
||||
|
|
@ -175,6 +175,7 @@ if (!function_exists('dol_loginfunction')) {
|
|||
*/
|
||||
|
||||
// Select templates dir
|
||||
$template_dir = '';
|
||||
if (!empty($conf->modules_parts['tpl'])) { // Using this feature slow down application
|
||||
$dirtpls = array_merge($conf->modules_parts['tpl'], array('/core/tpl/'));
|
||||
foreach ($dirtpls as $reldir) {
|
||||
|
|
@ -394,6 +395,7 @@ function encodedecode_dbpassconf($level = 0)
|
|||
$lineofpass = 0;
|
||||
|
||||
$reg = array();
|
||||
$mode = '';
|
||||
if (preg_match('/^[^#]*dolibarr_main_db_encrypted_pass[\s]*=[\s]*(.*)/i', $buffer, $reg)) { // Old way to save encrypted value
|
||||
$val = trim($reg[1]); // This also remove CR/LF
|
||||
$val = preg_replace('/^["\']/', '', $val);
|
||||
|
|
@ -479,8 +481,8 @@ function encodedecode_dbpassconf($level = 0)
|
|||
/**
|
||||
* Return a generated password using default module
|
||||
*
|
||||
* @param boolean $generic true=Create generic password (32 chars/numbers), false=Use the configured password generation module
|
||||
* @param array $replaceambiguouschars Discard ambiguous characters. For example array('I').
|
||||
* @param bool $generic true=Create generic password (32 chars/numbers), false=Use the configured password generation module
|
||||
* @param ?array<string> $replaceambiguouschars Discard ambiguous characters. For example array('I').
|
||||
* @param int $length Length of random string (Used only if $generic is true)
|
||||
* @return string New value for password
|
||||
* @see dol_hash(), dolJSToSetRandomPassword()
|
||||
|
|
@ -542,6 +544,7 @@ function getRandomPassword($generic = false, $replaceambiguouschars = null, $len
|
|||
//print DOL_DOCUMENT_ROOT."/core/modules/security/generate/".$nomclass;
|
||||
require_once DOL_DOCUMENT_ROOT."/core/modules/security/generate/".$nomfichier;
|
||||
$genhandler = new $nomclass($db, $conf, $langs, $user);
|
||||
'@phan-var-force ModeleGenPassword $genhandler';
|
||||
$generated_password = $genhandler->getNewGeneratedPassword();
|
||||
unset($genhandler);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ require_once DOL_DOCUMENT_ROOT.'/product/stock/class/entrepot.class.php';
|
|||
/**
|
||||
* Prepare array with list of tabs
|
||||
*
|
||||
* @param Object $object Object related to tabs
|
||||
* @param Expedition $object Object related to tabs
|
||||
* @return array<array{0:string,1:string,2:string}> Array of tabs to show
|
||||
*/
|
||||
function shipping_prepare_head($object)
|
||||
|
|
@ -320,6 +320,7 @@ function show_list_sending_receive($origin, $origin_id, $filter = '')
|
|||
// Define output language
|
||||
if (getDolGlobalInt('MAIN_MULTILANGS') && getDolGlobalString('PRODUIT_TEXTS_IN_THIRDPARTY_LANGUAGE')) {
|
||||
$object = new $origin($db);
|
||||
'@phan-var-force CommonObject $object';
|
||||
$object->fetch($origin_id);
|
||||
$object->fetch_thirdparty();
|
||||
|
||||
|
|
@ -356,7 +357,7 @@ function show_list_sending_receive($origin, $origin_id, $filter = '')
|
|||
$text = $product_static->getNomUrl(1);
|
||||
$text .= ' - '.$label;
|
||||
$description = (getDolGlobalInt('PRODUIT_DESC_IN_FORM_ACCORDING_TO_DEVICE') ? '' : dol_htmlentitiesbr($objp->description));
|
||||
print $form->textwithtooltip($text, $description, 3, '', '', $i);
|
||||
print $form->textwithtooltip($text, $description, 3, 0, '', $i);
|
||||
|
||||
// Show range
|
||||
print_date_range($objp->date_start, $objp->date_end);
|
||||
|
|
@ -377,7 +378,7 @@ function show_list_sending_receive($origin, $origin_id, $filter = '')
|
|||
|
||||
if (!empty($objp->label)) {
|
||||
$text .= ' <strong>'.$objp->label.'</strong>';
|
||||
print $form->textwithtooltip($text, $objp->description, 3, '', '', $i);
|
||||
print $form->textwithtooltip($text, $objp->description, 3, 0, '', $i);
|
||||
} else {
|
||||
print $text.' '.nl2br($objp->description);
|
||||
}
|
||||
|
|
@ -452,6 +453,7 @@ function show_list_sending_receive($origin, $origin_id, $filter = '')
|
|||
}
|
||||
|
||||
if (!empty($receiving)) {
|
||||
'@phan-var-force Delivery $receiving';
|
||||
// $expedition->fk_elementdet = id of det line of order
|
||||
// $receiving->fk_origin_line = id of det line of order
|
||||
// $receiving->origin may be 'shipping'
|
||||
|
|
|
|||
|
|
@ -20,15 +20,15 @@
|
|||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/core/lib/propal.lib.php
|
||||
* \brief Ensemble de functions de base pour le module propal
|
||||
* \ingroup propal
|
||||
* \file htdocs/core/lib/supplier_proposal.lib.php
|
||||
* \brief Ensemble de functions de base pour le module supplier_proposal
|
||||
* \ingroup supplier_proposal
|
||||
*/
|
||||
|
||||
/**
|
||||
* Prepare array with list of tabs
|
||||
*
|
||||
* @param object $object Object related to tabs
|
||||
* @param SupplierProposal $object Object related to tabs
|
||||
* @return array<array{0:string,1:string,2:string}> Array of tabs to show
|
||||
*/
|
||||
function supplier_proposal_prepare_head($object)
|
||||
|
|
@ -108,7 +108,7 @@ function supplier_proposal_prepare_head($object)
|
|||
/**
|
||||
* Return array head with list of tabs to view object information.
|
||||
*
|
||||
* @return array head array with tabs
|
||||
* @return array<array{0:string,1:string,2:string}> head array with tabs
|
||||
*/
|
||||
function supplier_proposal_admin_prepare_head()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -69,8 +69,17 @@ class pdf_espadon extends ModelePdfExpedition
|
|||
*/
|
||||
public $version = 'dolibarr';
|
||||
|
||||
/**
|
||||
* @var int|float
|
||||
*/
|
||||
public $posxweightvol;
|
||||
/**
|
||||
* @var int|float
|
||||
*/
|
||||
public $posxqtytoship;
|
||||
/**
|
||||
* @var int|float
|
||||
*/
|
||||
public $posxqtyordered;
|
||||
|
||||
|
||||
|
|
@ -865,7 +874,7 @@ class pdf_espadon extends ModelePdfExpedition
|
|||
$totalVolumetoshow = showDimensionInBestUnit($totalVolume, 0, "volume", $outputlangs, -1, 'no', 1);
|
||||
}
|
||||
if (!empty($object->trueWeight)) {
|
||||
$totalWeighttoshow = showDimensionInBestUnit($object->trueWeight, $object->weight_units, "weight", $outputlangs);
|
||||
$totalWeighttoshow = showDimensionInBestUnit($object->trueWeight, (int) $object->weight_units, "weight", $outputlangs);
|
||||
}
|
||||
if (!empty($object->trueVolume)) {
|
||||
if ($object->volume_units < 50) {
|
||||
|
|
@ -967,7 +976,7 @@ class pdf_espadon extends ModelePdfExpedition
|
|||
*
|
||||
* @param TCPDF $pdf Object PDF
|
||||
* @param Expedition $object Object to show
|
||||
* @param int $showaddress 0=no, 1=yes
|
||||
* @param int<0,1> $showaddress 0=no, 1=yes
|
||||
* @param Translate $outputlangs Object lang for output
|
||||
* @return float|int Return topshift value
|
||||
*/
|
||||
|
|
@ -1066,6 +1075,7 @@ class pdf_espadon extends ModelePdfExpedition
|
|||
|
||||
$classname = ucfirst($origin);
|
||||
$linkedobject = new $classname($this->db);
|
||||
'@phan-var-force Commande|Facture $linkedobject';
|
||||
$result = $linkedobject->fetch($origin_id);
|
||||
if ($result >= 0) {
|
||||
//$linkedobject->fetchObjectLinked() Get all linked object to the $linkedobject (commonly order) into $linkedobject->linkedObjects
|
||||
|
|
|
|||
|
|
@ -69,8 +69,17 @@ class pdf_rouget extends ModelePdfExpedition
|
|||
*/
|
||||
public $version = 'dolibarr';
|
||||
|
||||
/**
|
||||
* @var float|int
|
||||
*/
|
||||
public $posxweightvol;
|
||||
/**
|
||||
* @var float|int
|
||||
*/
|
||||
public $posxqtytoship;
|
||||
/**
|
||||
* @var float|int
|
||||
*/
|
||||
public $posxqtyordered;
|
||||
|
||||
|
||||
|
|
@ -757,7 +766,7 @@ class pdf_rouget extends ModelePdfExpedition
|
|||
$totalVolumetoshow = showDimensionInBestUnit($totalVolume, 0, "volume", $outputlangs, -1, 'no', 1);
|
||||
}
|
||||
if (!empty($object->trueWeight)) {
|
||||
$totalWeighttoshow = showDimensionInBestUnit($object->trueWeight, $object->weight_units, "weight", $outputlangs);
|
||||
$totalWeighttoshow = showDimensionInBestUnit($object->trueWeight, (int) $object->weight_units, "weight", $outputlangs);
|
||||
}
|
||||
if (!empty($object->trueVolume)) {
|
||||
$totalVolumetoshow = showDimensionInBestUnit($object->trueVolume, $object->volume_units, "volume", $outputlangs);
|
||||
|
|
@ -999,6 +1008,7 @@ class pdf_rouget extends ModelePdfExpedition
|
|||
|
||||
$classname = ucfirst($origin);
|
||||
$linkedobject = new $classname($this->db);
|
||||
'@phan-var-force Commande|Facture $linkedobject';
|
||||
$result = $linkedobject->fetch($origin_id);
|
||||
if ($result >= 0) {
|
||||
//$linkedobject->fetchObjectLinked() Get all linked object to the $linkedobject (commonly order) into $linkedobject->linkedObjects
|
||||
|
|
|
|||
|
|
@ -318,7 +318,7 @@ class doc_generic_invoice_odt extends ModelePDFFactures
|
|||
}
|
||||
|
||||
// Fetch info for linked propal
|
||||
$object->fetchObjectLinked('', '', '', '');
|
||||
$object->fetchObjectLinked(0, '', null, '');
|
||||
//print_r($object->linkedObjects['propal']); exit;
|
||||
|
||||
$propal_object = null;
|
||||
|
|
|
|||
|
|
@ -98,32 +98,32 @@ class ModeleImports
|
|||
|
||||
// Array of all drivers
|
||||
/**
|
||||
* @var string[]
|
||||
* @var array<string,string>
|
||||
*/
|
||||
public $driverlabel = array();
|
||||
|
||||
/**
|
||||
* @var string[]
|
||||
* @var array<string,string>
|
||||
*/
|
||||
public $driverdesc = array();
|
||||
|
||||
/**
|
||||
* @var string[]
|
||||
* @var array<string,string>
|
||||
*/
|
||||
public $driverversion = array();
|
||||
|
||||
/**
|
||||
* @var string[]
|
||||
* @var array<string,string>
|
||||
*/
|
||||
public $drivererror = array();
|
||||
|
||||
/**
|
||||
* @var string[]
|
||||
* @var array<string,string>
|
||||
*/
|
||||
public $liblabel = array();
|
||||
|
||||
/**
|
||||
* @var string[]
|
||||
* @var array<string,string>
|
||||
*/
|
||||
public $libversion = array();
|
||||
|
||||
|
|
@ -133,7 +133,7 @@ class ModeleImports
|
|||
public $charset;
|
||||
|
||||
/**
|
||||
* @var string picto
|
||||
* @var array<string,string>|string picto
|
||||
*/
|
||||
public $picto;
|
||||
|
||||
|
|
@ -158,7 +158,7 @@ class ModeleImports
|
|||
public $thirdpartyobject;
|
||||
|
||||
/**
|
||||
* @var array Element mapping from table name
|
||||
* @var array<string,string> Element mapping from table name
|
||||
*/
|
||||
public static $mapTableToElement = MODULE_MAPPING;
|
||||
|
||||
|
|
@ -256,8 +256,8 @@ class ModeleImports
|
|||
* Load into memory list of available import format
|
||||
*
|
||||
* @param DoliDB $db Database handler
|
||||
* @param integer $maxfilenamelength Max length of value to show
|
||||
* @return array List of templates
|
||||
* @param int $maxfilenamelength Max length of value to show
|
||||
* @return array<int,string> List of templates
|
||||
*/
|
||||
public function listOfAvailableImportFormat($db, $maxfilenamelength = 0)
|
||||
{
|
||||
|
|
@ -279,17 +279,18 @@ class ModeleImports
|
|||
|
||||
require_once $file;
|
||||
$module = new $classname($db, '');
|
||||
'@phan-var-force ModeleImports $module';
|
||||
|
||||
// Picto
|
||||
$this->picto[$module->id] = $module->picto;
|
||||
// Driver properties
|
||||
$this->driverlabel[$module->id] = $module->getDriverLabel('');
|
||||
$this->driverdesc[$module->id] = $module->getDriverDesc('');
|
||||
$this->driverversion[$module->id] = $module->getDriverVersion('');
|
||||
$this->driverlabel[$module->id] = $module->getDriverLabel();
|
||||
$this->driverdesc[$module->id] = $module->getDriverDesc();
|
||||
$this->driverversion[$module->id] = $module->getDriverVersion();
|
||||
$this->drivererror[$module->id] = $module->error ? $module->error : '';
|
||||
// If use an external lib
|
||||
$this->liblabel[$module->id] = ($module->error ? '<span class="error">'.$module->error.'</span>' : $module->getLibLabel(''));
|
||||
$this->libversion[$module->id] = $module->getLibVersion('');
|
||||
$this->liblabel[$module->id] = ($module->error ? '<span class="error">'.$module->error.'</span>' : $module->getLibLabel());
|
||||
$this->libversion[$module->id] = $module->getLibVersion();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,9 +57,9 @@ class mailing_advthirdparties extends MailingTargets
|
|||
* This is the main function that returns the array of emails
|
||||
*
|
||||
* @param int $mailing_id Id of mailing. No need to use it.
|
||||
* @param array $socid Array of id soc to add
|
||||
* @param int[] $socid Array of id soc to add
|
||||
* @param int $type_of_target Defined in advtargetemailing.class.php
|
||||
* @param array $contactid Array of contact id to add
|
||||
* @param int[] $contactid Array of contact id to add
|
||||
* @return int Return integer <0 if error, number of emails added if ok
|
||||
*/
|
||||
public function add_to_target_spec($mailing_id, $socid, $type_of_target, $contactid)
|
||||
|
|
@ -290,7 +290,7 @@ class mailing_advthirdparties extends MailingTargets
|
|||
* Can include an URL link on each record provided by selector shown on target page.
|
||||
*
|
||||
* @param int $id ID
|
||||
* @param string $type type
|
||||
* @param string $type type
|
||||
* @return string Url link
|
||||
*/
|
||||
public function url($id, $type)
|
||||
|
|
|
|||
|
|
@ -168,6 +168,7 @@ if (GETPOST('code')) { // We are coming from oauth provider page
|
|||
if ($apiService === null) {
|
||||
dol_syslog("No API Service", LOG_ERR);
|
||||
} else {
|
||||
'@phan-var-force OAuth\OAuth2\Service\AbstractService|OAuth\OAuth1\Service\AbstractService $apiService';
|
||||
$url = $apiService->getAuthorizationUri(array('state' => GETPOST('state')));
|
||||
}
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
/* Copyright (C) 2022 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2015 Frederic France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -50,9 +51,12 @@ $uriFactory = new \OAuth\Common\Http\Uri\UriFactory();
|
|||
//$currentUri->setQuery('');
|
||||
$currentUri = $uriFactory->createFromAbsolute($urlwithroot.'/core/modules/oauth/stripetest_oauthcallback.php');
|
||||
|
||||
$state = null;
|
||||
$apiService = null;
|
||||
|
||||
|
||||
/**
|
||||
* Load the credential for the service
|
||||
* Load the credentials for the service
|
||||
*/
|
||||
|
||||
/** @var \OAuth\ServiceFactory $serviceFactory An OAuth service factory. */
|
||||
|
|
@ -128,6 +132,7 @@ if (GETPOST('code')) { // We are coming from oauth provider page
|
|||
|
||||
// This was a callback request from service, get the token
|
||||
try {
|
||||
'@phan-var-force OAuth\OAuth2\Service\AbstractService|OAuth\OAuth1\Service\AbstractService $apiService';
|
||||
//var_dump($state);
|
||||
//var_dump($apiService); // OAuth\OAuth2\Service\Stripe
|
||||
|
||||
|
|
@ -157,7 +162,12 @@ if (GETPOST('code')) { // We are coming from oauth provider page
|
|||
// This may create record into oauth_state before the header redirect.
|
||||
// Creation of record with state in this tables depend on the Provider used (see its constructor).
|
||||
if (GETPOST('state')) {
|
||||
$url = $apiService->getAuthorizationUri(array('state'=>GETPOST('state')));
|
||||
if (is_object($apiService)) { // @phpstan-ignore-line
|
||||
'@phan-var-force OAuth\OAuth2\Service\AbstractService|OAuth\OAuth1\Service\AbstractService $apiService';
|
||||
$url = $apiService->getAuthorizationUri(array('state' => GETPOST('state')));
|
||||
} else {
|
||||
$url = null;
|
||||
}
|
||||
} else {
|
||||
//$url = $apiService->getAuthorizationUri(); // Parameter state will be randomly generated
|
||||
//https://connect.stripe.com/oauth/authorize?response_type=code&client_id=ca_AX27ut70tJ1j6eyFCV3ObEXhNOo2jY6V&scope=read_write
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ class ModelePDFLabels
|
|||
*
|
||||
* @param DoliDB $db Database handler
|
||||
* @param integer $maxfilenamelength Max length of value to show
|
||||
* @return array List of templates
|
||||
* @return string[]|int<-1,0> List of templates
|
||||
*/
|
||||
public function liste_modeles($db, $maxfilenamelength = 0)
|
||||
{
|
||||
|
|
@ -68,7 +68,7 @@ class ModelePDFLabels
|
|||
* Create a document onto disk according to template module.
|
||||
*
|
||||
* @param DoliDB $db Database handler
|
||||
* @param array $arrayofrecords Array of records
|
||||
* @param array{} $arrayofrecords Array of records
|
||||
* @param string $modele Force le modele a utiliser ('' to not force)
|
||||
* @param Translate $outputlangs Object lang a utiliser pour traduction
|
||||
* @param string $outputdir Output directory
|
||||
|
|
@ -143,6 +143,7 @@ function doc_label_pdf_create($db, $arrayofrecords, $modele, $outputlangs, $outp
|
|||
require_once $file;
|
||||
|
||||
$obj = new $classname($db);
|
||||
'@phan-var-force CommonStickerGenerator $obj';
|
||||
|
||||
// We save charset_output to restore it because write_file can change it if needed for
|
||||
// output format that does not support UTF8.
|
||||
|
|
|
|||
|
|
@ -31,6 +31,14 @@
|
|||
* $arrayoffamiliestoexclude=array('system', 'mycompany', 'object', 'objectamount', 'date', 'user', ...);
|
||||
* $file
|
||||
*/
|
||||
'
|
||||
@phan-var-force int<0,1> $diroutput
|
||||
@phan-var-force string $defaulttopic
|
||||
@phan-var-force string $defaulttopiclang
|
||||
@phan-var-force string[] $arrayoffamiliestoexclude
|
||||
@phan-var-force string $file
|
||||
@phan-var-force CommonObject $object
|
||||
';
|
||||
|
||||
// Protection to avoid direct call of template
|
||||
if (empty($conf) || !is_object($conf)) {
|
||||
|
|
@ -46,9 +54,6 @@ if ($action == 'presend') {
|
|||
$titreform = 'SendMail';
|
||||
|
||||
$object->fetch_projet();
|
||||
if (!isset($file)) {
|
||||
$file = null;
|
||||
}
|
||||
$ref = dol_sanitizeFileName($object->ref);
|
||||
if (!in_array($object->element, array('user', 'member'))) {
|
||||
//$fileparams['fullname'] can be filled from the card
|
||||
|
|
@ -198,22 +203,28 @@ if ($action == 'presend') {
|
|||
// Define $liste, a list of recipients with email inside <>.
|
||||
$liste = array();
|
||||
if ($object->element == 'expensereport') {
|
||||
'@phan-var-force ExpenseReport $object';
|
||||
$fuser = new User($db);
|
||||
$fuser->fetch($object->fk_user_author);
|
||||
$liste['thirdparty'] = $fuser->getFullName($outputlangs)." <".$fuser->email.">";
|
||||
} elseif ($object->element == 'partnership' && getDolGlobalString('PARTNERSHIP_IS_MANAGED_FOR') == 'member') {
|
||||
'@phan-var-force Partnership $object';
|
||||
$fadherent = new Adherent($db);
|
||||
$fadherent->fetch($object->fk_member);
|
||||
$liste['member'] = $fadherent->getFullName($outputlangs)." <".$fadherent->email.">";
|
||||
} elseif ($object->element == 'societe') {
|
||||
'@phan-var-force Societe $object';
|
||||
foreach ($object->thirdparty_and_contact_email_array(1) as $key => $value) {
|
||||
$liste[$key] = $value;
|
||||
}
|
||||
} elseif ($object->element == 'contact') {
|
||||
'@phan-var-force Contact $object';
|
||||
$liste['contact'] = $object->getFullName($outputlangs)." <".$object->email.">";
|
||||
} elseif ($object->element == 'user' || $object->element == 'member') {
|
||||
'@phan-var-force User|Adherent $object';
|
||||
$liste['thirdparty'] = $object->getFullName($outputlangs)." <".$object->email.">";
|
||||
} elseif ($object->element == 'salary') {
|
||||
'@phan-var-force Salary $object';
|
||||
$fuser = new User($db);
|
||||
$fuser->fetch($object->fk_user);
|
||||
$liste['thirdparty'] = $fuser->getFullName($outputlangs)." <".$fuser->email.">";
|
||||
|
|
@ -258,6 +269,7 @@ if ($action == 'presend') {
|
|||
}
|
||||
$substitutionarray = getCommonSubstitutionArray($outputlangs, 0, $arrayoffamiliestoexclude, $object);
|
||||
|
||||
$emailsendersignature = null;
|
||||
// Overwrite __SENDEREMAIL_SIGNATURE__ with value select into form
|
||||
if ($formmail->fromtype) {
|
||||
$reg = array();
|
||||
|
|
@ -282,6 +294,7 @@ if ($action == 'presend') {
|
|||
$substitutionarray['__CHECK_READ__'] = "";
|
||||
if (is_object($object) && is_object($object->thirdparty)) {
|
||||
$checkRead = '<img src="'.DOL_MAIN_URL_ROOT.'/public/emailing/mailing-read.php';
|
||||
// @phan-suppress-next-line PhanUndeclaredProperty;
|
||||
$checkRead .= '?tag='.(!empty($object->thirdparty->tag) ? urlencode($object->thirdparty->tag) : "");
|
||||
$checkRead .= '&securitykey='.(getDolGlobalString('MAILING_EMAIL_UNSUBSCRIBE_KEY') ? urlencode(getDolGlobalString('MAILING_EMAIL_UNSUBSCRIBE_KEY')) : "");
|
||||
$checkRead .= '" width="1" height="1" style="width:1px;height:1px" border="0"/>';
|
||||
|
|
@ -334,6 +347,7 @@ if ($action == 'presend') {
|
|||
dol_include_once('/'.$element.'/class/'.$subelement.'.class.php');
|
||||
$classname = ucfirst($origin);
|
||||
$objectsrc = new $classname($db);
|
||||
'@phan-var-force Commande|Facture $objectsrc';
|
||||
$objectsrc->fetch($origin_id);
|
||||
|
||||
$tmpobject = $objectsrc;
|
||||
|
|
|
|||
|
|
@ -95,6 +95,7 @@ foreach ($object->fields as $key => $val) {
|
|||
} elseif ($val['type'] == 'price') {
|
||||
$value = GETPOSTISSET($key) ? price2num(GETPOST($key)) : price2num($object->$key);
|
||||
} elseif ($key == 'lang') {
|
||||
// @phan-suppress-next-line PhanUndeclaredProperty
|
||||
$value = GETPOSTISSET($key) ? GETPOST($key, 'aZ09') : $object->lang;
|
||||
} else {
|
||||
$value = GETPOSTISSET($key) ? GETPOST($key, 'alpha') : $object->$key;
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
* Copyright (C) 2013-2015 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2015-2016 Charlie BENKE <charlie@patas-monkey.com>
|
||||
* Copyright (C) 2021 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -30,6 +31,12 @@ if (empty($object) || !is_object($object)) {
|
|||
exit(1);
|
||||
}
|
||||
|
||||
|
||||
'
|
||||
@phan-var-force ?CommonObject $object
|
||||
@phan-var-force ?CommonObject $objectsrc
|
||||
@phan-var-force ?string $permission
|
||||
';
|
||||
if (empty($preselectedtypeofcontact)) {
|
||||
$preselectedtypeofcontact = 0;
|
||||
}
|
||||
|
|
@ -40,7 +47,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php';
|
|||
$module = $object->element;
|
||||
|
||||
// Special cases
|
||||
if (isset($permissiontoadd) && ! isset($permission)) {
|
||||
if (isset($permissiontoadd) && !isset($permission)) {
|
||||
$permission = $permissiontoadd;
|
||||
}
|
||||
// TODO Remove this section. We already got $permissiontoadd.
|
||||
|
|
@ -114,7 +121,7 @@ if ($permission) {
|
|||
<div class="tagtd"><span class="paddingleft"><?php echo getDolGlobalString('MAIN_INFO_SOCIETE_NOM'); ?></span></div>
|
||||
<!-- <div class="nowrap tagtd"><?php echo img_object('', 'user').' '.$langs->trans("Users"); ?></div> -->
|
||||
<div class="tagtd maxwidthonsmartphone">
|
||||
<?php echo img_object('', 'user', 'class="pictofixedwidth"').$form->select_dolusers($user->id, 'userid', 1, (!empty($userAlreadySelected) ? $userAlreadySelected : null), 0, null, null, 0, 56, 0, '', 0, '', 'minwidth100imp widthcentpercentminusxx maxwidth400 userselectcontact');
|
||||
<?php echo img_object('', 'user', 'class="pictofixedwidth"').$form->select_dolusers($user->id, 'userid', 1, (!empty($userAlreadySelected) ? $userAlreadySelected : null), 0, '', '', 0, 56, 0, '', 0, '', 'minwidth100imp widthcentpercentminusxx maxwidth400 userselectcontact');
|
||||
if (empty($hideaddcontactforgroups) && $module == 'project') {
|
||||
print '<span> '.$langs->trans("or").' </span>';
|
||||
echo img_object('', 'group', 'class="pictofixedwidth"').$form->select_dolgroups(0, 'groupid', 1, '', 0, '', array(), '0', false, 'minwidth100imp widthcentpercentminusxx maxwidth400 groupselectcontact');
|
||||
|
|
@ -164,7 +171,7 @@ if ($permission) {
|
|||
<div class="tagtd nowrap noborderbottom">
|
||||
<?php
|
||||
$selectedCompany = GETPOSTISSET("newcompany") ? GETPOSTINT("newcompany") : (empty($object->socid) ? 0 : $object->socid);
|
||||
$selectedCompany = $formcompany->selectCompaniesForNewContact($object, 'id', $selectedCompany, 'newcompany', '', 0, '', 'minwidth300imp maxwidth400 widthcentpercentminusx'); // This also print the select component?>
|
||||
$selectedCompany = $formcompany->selectCompaniesForNewContact($object, 'id', $selectedCompany, 'newcompany', array(), 0, '', 'minwidth300imp maxwidth400 widthcentpercentminusx'); // This also print the select component?>
|
||||
</div>
|
||||
<div class="tagtd noborderbottom minwidth500imp">
|
||||
<?php
|
||||
|
|
@ -184,6 +191,7 @@ if ($permission) {
|
|||
<?php
|
||||
$tmpobject = $object;
|
||||
if (($object->element == 'shipping' || $object->element == 'reception') && is_object($objectsrc)) {
|
||||
'@phan-var-force Commande|Facture $objectsrc';
|
||||
$tmpobject = $objectsrc;
|
||||
}
|
||||
$formcompany->selectTypeContact($tmpobject, $preselectedtypeofcontact, 'typecontact', 'external', 'position', 0, 'minwidth150imp widthcentpercentminusx maxwidth200'); ?>
|
||||
|
|
@ -212,6 +220,7 @@ if ($permission) {
|
|||
$list = array();
|
||||
foreach (array('internal', 'external') as $source) {
|
||||
if (($object->element == 'shipping' || $object->element == 'reception') && is_object($objectsrc)) {
|
||||
'@phan-var-force Commande|Facture $objectsrc';
|
||||
$contactlist = $objectsrc->liste_contact(-1, $source);
|
||||
} else {
|
||||
$contactlist = $object->liste_contact(-1, $source);
|
||||
|
|
@ -289,13 +298,13 @@ if (!$sortorder) {
|
|||
$list = dol_sort_array($list, $sortfield, $sortorder, 1, 0, 1);
|
||||
|
||||
$arrayfields = array(
|
||||
'rowid' => array('label'=>$langs->trans("Id"), 'checked'=>1),
|
||||
'nature' => array('label'=>$langs->trans("NatureOfContact"), 'checked'=>1),
|
||||
'thirdparty' => array('label'=>$langs->trans("ThirdParty"), 'checked'=>1),
|
||||
'contact' => array('label'=>$langs->trans("Users").' | '.$langs->trans("Contacts"), 'checked'=>1),
|
||||
'type' => array('label'=>$langs->trans("ContactType"), 'checked'=>1),
|
||||
'status' => array('label'=>$langs->trans("Status"), 'checked'=>1),
|
||||
'link' => array('label'=>$langs->trans("Link"), 'checked'=>1),
|
||||
'rowid' => array('label' => $langs->trans("Id"), 'checked' => 1),
|
||||
'nature' => array('label' => $langs->trans("NatureOfContact"), 'checked' => 1),
|
||||
'thirdparty' => array('label' => $langs->trans("ThirdParty"), 'checked' => 1),
|
||||
'contact' => array('label' => $langs->trans("Users").' | '.$langs->trans("Contacts"), 'checked' => 1),
|
||||
'type' => array('label' => $langs->trans("ContactType"), 'checked' => 1),
|
||||
'status' => array('label' => $langs->trans("Status"), 'checked' => 1),
|
||||
'link' => array('label' => $langs->trans("Link"), 'checked' => 1),
|
||||
);
|
||||
|
||||
$param = 'id='.$object->id.'&mainmenu=home';
|
||||
|
|
|
|||
|
|
@ -1,11 +1,20 @@
|
|||
<!-- BEGIN TEMPLATE resource_view.tpl.php -->
|
||||
<?php
|
||||
/* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*/
|
||||
// Protection to avoid direct call of template
|
||||
if (empty($conf) || !is_object($conf)) {
|
||||
print "Error, template page can't be called as URL";
|
||||
exit(1);
|
||||
}
|
||||
|
||||
'
|
||||
@phan-var-force string $element
|
||||
@phan-var-force int $element_id
|
||||
@phan-var-force string $resource_type
|
||||
@phan-var-force array<array{rowid:int,resource_id:int,resource_type:string,busy:int<0,1>,mandatory:int<0,1>}> $linked_resources
|
||||
';
|
||||
|
||||
|
||||
$form = new Form($db);
|
||||
|
||||
|
|
|
|||
|
|
@ -135,7 +135,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
if ($action == 'ORDER_CLASSIFY_BILLED') {
|
||||
dol_syslog("Trigger '".$this->name."' for action '$action' launched by ".__FILE__.". id=".$object->id);
|
||||
if (isModEnabled("propal") && !empty($conf->workflow->enabled) && getDolGlobalString('WORKFLOW_ORDER_CLASSIFY_BILLED_PROPAL')) {
|
||||
$object->fetchObjectLinked('', 'propal', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'propal', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['propal'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['propal'] as $element) {
|
||||
|
|
@ -160,7 +160,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
|
||||
// First classify billed the order to allow the proposal classify process
|
||||
if (isModEnabled('order') && !empty($conf->workflow->enabled) && getDolGlobalString('WORKFLOW_INVOICE_AMOUNT_CLASSIFY_BILLED_ORDER')) {
|
||||
$object->fetchObjectLinked('', 'commande', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'commande', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['commande'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['commande'] as $element) {
|
||||
|
|
@ -179,7 +179,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
|
||||
// Second classify billed the proposal.
|
||||
if (isModEnabled("propal") && !empty($conf->workflow->enabled) && getDolGlobalString('WORKFLOW_INVOICE_CLASSIFY_BILLED_PROPAL')) {
|
||||
$object->fetchObjectLinked('', 'propal', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'propal', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['propal'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['propal'] as $element) {
|
||||
|
|
@ -198,7 +198,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
|
||||
// Set shipment to "Closed" if WORKFLOW_SHIPPING_CLASSIFY_CLOSED_INVOICE is set (deprecated, has been replaced with WORKFLOW_SHIPPING_CLASSIFY_BILLED_INVOICE instead))
|
||||
if (isModEnabled("shipping") && !empty($conf->workflow->enabled) && getDolGlobalString('WORKFLOW_SHIPPING_CLASSIFY_CLOSED_INVOICE')) {
|
||||
$object->fetchObjectLinked('', 'shipping', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'shipping', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['shipping'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['shipping'] as $element) {
|
||||
|
|
@ -219,7 +219,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
}
|
||||
|
||||
if (isModEnabled("shipping") && !empty($conf->workflow->enabled) && getDolGlobalString('WORKFLOW_SHIPPING_CLASSIFY_BILLED_INVOICE')) {
|
||||
$object->fetchObjectLinked('', 'shipping', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'shipping', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['shipping'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['shipping'] as $element) {
|
||||
|
|
@ -241,7 +241,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
|
||||
// First classify billed the order to allow the proposal classify process
|
||||
if (isModEnabled('order') && isModEnabled('workflow') && getDolGlobalString('WORKFLOW_SUM_INVOICES_AMOUNT_CLASSIFY_BILLED_ORDER')) {
|
||||
$object->fetchObjectLinked('', 'commande', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'commande', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['commande']) && count($object->linkedObjects['commande']) == 1) { // If the invoice has only 1 source order
|
||||
$orderLinked = reset($object->linkedObjects['commande']);
|
||||
$orderLinked->fetchObjectLinked($orderLinked->id, '', $orderLinked->element);
|
||||
|
|
@ -279,7 +279,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
// Firstly, we set to purchase order to "Billed" if WORKFLOW_INVOICE_AMOUNT_CLASSIFY_BILLED_SUPPLIER_ORDER is set.
|
||||
// After we will set proposals
|
||||
if ((isModEnabled("supplier_order") || isModEnabled("supplier_invoice")) && getDolGlobalString('WORKFLOW_INVOICE_AMOUNT_CLASSIFY_BILLED_SUPPLIER_ORDER')) {
|
||||
$object->fetchObjectLinked('', 'order_supplier', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'order_supplier', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['order_supplier'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['order_supplier'] as $element) {
|
||||
|
|
@ -301,7 +301,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
|
||||
// Secondly, we set to linked Proposal to "Billed" if WORKFLOW_INVOICE_CLASSIFY_BILLED_SUPPLIER_PROPOSAL is set.
|
||||
if (isModEnabled('supplier_proposal') && getDolGlobalString('WORKFLOW_INVOICE_CLASSIFY_BILLED_SUPPLIER_PROPOSAL')) {
|
||||
$object->fetchObjectLinked('', 'supplier_proposal', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'supplier_proposal', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['supplier_proposal'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['supplier_proposal'] as $element) {
|
||||
|
|
@ -347,7 +347,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
|
||||
// Then set reception to "Billed" if WORKFLOW_RECEPTION_CLASSIFY_BILLED_INVOICE is set
|
||||
if (isModEnabled("reception") && !empty($conf->workflow->enabled) && getDolGlobalString('WORKFLOW_RECEPTION_CLASSIFY_BILLED_INVOICE')) {
|
||||
$object->fetchObjectLinked('', 'reception', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'reception', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['reception'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['reception'] as $element) {
|
||||
|
|
@ -375,7 +375,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
dol_syslog("Trigger '".$this->name."' for action '$action' launched by ".__FILE__.". id=".$object->id);
|
||||
|
||||
if (isModEnabled('order') && getDolGlobalString('WORKFLOW_INVOICE_CLASSIFY_BILLED_ORDER')) {
|
||||
$object->fetchObjectLinked('', 'commande', $object->id, $object->element);
|
||||
$object->fetchObjectLinked(0, 'commande', $object->id, $object->element);
|
||||
if (!empty($object->linkedObjects['commande'])) {
|
||||
$totalonlinkedelements = 0;
|
||||
foreach ($object->linkedObjects['commande'] as $element) {
|
||||
|
|
@ -541,7 +541,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||
$diff_array = array_diff_assoc($qtyordred, $qtyshipped);
|
||||
if (count($diff_array) == 0) {
|
||||
//No diff => mean everything is received
|
||||
$ret = $order->setStatut(CommandeFournisseur::STATUS_RECEIVED_COMPLETELY, null, null, 'SUPPLIER_ORDER_CLOSE');
|
||||
$ret = $order->setStatut(CommandeFournisseur::STATUS_RECEIVED_COMPLETELY, null, '', 'SUPPLIER_ORDER_CLOSE');
|
||||
if ($ret < 0) {
|
||||
$this->setErrorsFromObject($order);
|
||||
return $ret;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
/* Copyright (C) 2018 Nicolas ZABOURI <info@inovea-conseil.com>
|
||||
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -37,6 +38,9 @@ class DataPolicy
|
|||
*/
|
||||
public $db;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $error;
|
||||
|
||||
|
||||
|
|
@ -165,7 +169,7 @@ class DataPolicy
|
|||
/**
|
||||
* sendMailDataPolicyContact
|
||||
*
|
||||
* @param mixed $contact Contact
|
||||
* @param Contact $contact Contact
|
||||
* @return void
|
||||
*/
|
||||
public static function sendMailDataPolicyContact($contact)
|
||||
|
|
|
|||
|
|
@ -68,6 +68,7 @@ if ($action == 'specimen') {
|
|||
|
||||
$classname = (string) $modele;
|
||||
$obj = new $classname($db);
|
||||
'@phan-var-force ModeleDon $obj';
|
||||
|
||||
if ($obj->write_file($don, $langs) > 0) {
|
||||
header("Location: ".DOL_URL_ROOT."/document.php?modulepart=donation&file=SPECIMEN.html");
|
||||
|
|
@ -231,6 +232,7 @@ if (is_resource($handle)) {
|
|||
|
||||
require_once $dir.'/'.$file;
|
||||
$module = new $classname($db);
|
||||
'@phan-var-force ModeleDon $module';
|
||||
|
||||
// Show modules according to features level
|
||||
if ($module->version == 'development' && getDolGlobalInt('MAIN_FEATURES_LEVEL') < 2) {
|
||||
|
|
@ -341,7 +343,7 @@ $label = $langs->trans("AccountAccounting");
|
|||
print '<label for="DONATION_ACCOUNTINGACCOUNT">'.$label.'</label></td>';
|
||||
print '<td class="center">';
|
||||
if (isModEnabled('accounting')) {
|
||||
print $formaccounting->select_account($conf->global->DONATION_ACCOUNTINGACCOUNT, 'DONATION_ACCOUNTINGACCOUNT', 1, '', 1, 1);
|
||||
print $formaccounting->select_account($conf->global->DONATION_ACCOUNTINGACCOUNT, 'DONATION_ACCOUNTINGACCOUNT', 1, array(), 1, 1);
|
||||
} else {
|
||||
print '<input type="text" size="10" id="DONATION_ACCOUNTINGACCOUNT" name="DONATION_ACCOUNTINGACCOUNT" value="' . getDolGlobalString('DONATION_ACCOUNTINGACCOUNT').'">';
|
||||
}
|
||||
|
|
|
|||
|
|
@ -398,10 +398,10 @@ class ConferenceOrBoothAttendee extends CommonObject
|
|||
* @param string $sortfield Sort field
|
||||
* @param int $limit limit
|
||||
* @param int $offset Offset
|
||||
* @param string|array $filter Filter as an Universal Search string.
|
||||
* Example: '((client:=:1) OR ((client:>=:2) AND (client:<=:3))) AND (client:!=:8) AND (nom:like:'a%')'
|
||||
* @param string|array<string,mixed> $filter Filter as an Universal Search string.
|
||||
* Example: '((client:=:1) OR ((client:>=:2) AND (client:<=:3))) AND (client:!=:8) AND (nom:like:'a%')'
|
||||
* @param string $filtermode No more used
|
||||
* @return array|int int <0 if KO, array of pages if OK
|
||||
* @return ConferenceOrBoothAttendee[]|int<-1,-1> int <0 if KO, array of pages if OK
|
||||
*/
|
||||
public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, $filter = '', $filtermode = 'AND')
|
||||
{
|
||||
|
|
@ -489,9 +489,9 @@ class ConferenceOrBoothAttendee extends CommonObject
|
|||
/**
|
||||
* Update object into database
|
||||
*
|
||||
* @param User $user User that modifies
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
* @param User $user User that modifies
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function update(User $user, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -501,9 +501,9 @@ class ConferenceOrBoothAttendee extends CommonObject
|
|||
/**
|
||||
* Delete object in database
|
||||
*
|
||||
* @param User $user User that deletes
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
* @param User $user User that deletes
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function delete(User $user, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -514,10 +514,10 @@ class ConferenceOrBoothAttendee extends CommonObject
|
|||
/**
|
||||
* Delete a line of object in database
|
||||
*
|
||||
* @param User $user User that delete
|
||||
* @param int $idline Id of line to delete
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int >0 if OK, <0 if KO
|
||||
* @param User $user User that delete
|
||||
* @param int $idline Id of line to delete
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int >0 if OK, <0 if KO
|
||||
*/
|
||||
public function deleteLine(User $user, $idline, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -533,9 +533,9 @@ class ConferenceOrBoothAttendee extends CommonObject
|
|||
/**
|
||||
* Validate object
|
||||
*
|
||||
* @param User $user User making status change
|
||||
* @param int $notrigger 1=Does not execute triggers, 0= execute triggers
|
||||
* @return int Return integer <=0 if OK, 0=Nothing done, >0 if KO
|
||||
* @param User $user User making status change
|
||||
* @param int<0,1> $notrigger 1=Does not execute triggers, 0= execute triggers
|
||||
* @return int Return integer <=0 if OK, 0=Nothing done, >0 if KO
|
||||
*/
|
||||
public function validate($user, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -1025,7 +1025,7 @@ class ConferenceOrBoothAttendee extends CommonObject
|
|||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
* Copyright (C) 2021 Florian Henry <florian.henry@scopen.fr>
|
||||
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
|
||||
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -150,7 +151,7 @@ if (empty($reshook)) {
|
|||
include DOL_DOCUMENT_ROOT.'/core/actions_builddoc.inc.php';
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
@ -173,7 +174,7 @@ $formfile = new FormFile($db);
|
|||
$formproject = new FormProjets($db);
|
||||
|
||||
$title = $langs->trans("ConferenceOrBooth");
|
||||
$help_url='EN:Module_Event_Organization';
|
||||
$help_url = 'EN:Module_Event_Organization';
|
||||
|
||||
llxHeader('', $title, $help_url, '', 0, 0, '', '', '', 'mod-eventorganization page-card');
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
/* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -180,7 +181,7 @@ if (empty($reshook)) {
|
|||
include DOL_DOCUMENT_ROOT.'/core/actions_builddoc.inc.php';
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
@ -205,7 +206,7 @@ $formfile = new FormFile($db);
|
|||
$formproject = new FormProjets($db);
|
||||
|
||||
$title = $langs->trans("ConferenceOrBoothAttendee");
|
||||
$help_url='EN:Module_Event_Organization';
|
||||
$help_url = 'EN:Module_Event_Organization';
|
||||
|
||||
llxHeader('', $title, $help_url, '', 0, 0, '', '', '', 'mod-eventorganization page-attendee-card');
|
||||
|
||||
|
|
|
|||
|
|
@ -43,6 +43,15 @@ if (empty($objectclass) || empty($uploaddir)) {
|
|||
exit;
|
||||
}
|
||||
|
||||
'
|
||||
@phan-var-force string $massaction
|
||||
@phan-var-force string $objectclass
|
||||
@phan-var-force ?string $diroutputmassaction
|
||||
@phan-var-force ?string $uploaddir
|
||||
@phan-var-force string[] $toselect
|
||||
@phan-var-force array<string,mixed> $parameters
|
||||
';
|
||||
|
||||
// Mass actions. Controls on number of lines checked.
|
||||
$maxformassaction = (!getDolGlobalString('MAIN_LIMIT_FOR_MASS_ACTIONS') ? 1000 : $conf->global->MAIN_LIMIT_FOR_MASS_ACTIONS);
|
||||
if (!empty($massaction) && is_array($toselect) && count($toselect) < 1) {
|
||||
|
|
@ -57,6 +66,7 @@ if (!$error && is_array($toselect) && count($toselect) > $maxformassaction) {
|
|||
if (!$error && $massaction == 'confirm_presend_attendees' && !GETPOST('sendmail')) { // If we do not choose button send (for example when we change template or limit), we must not send email, but keep on send email form
|
||||
$massaction = 'presend_attendees';
|
||||
}
|
||||
|
||||
if (!$error && $massaction == 'confirm_presend_attendees') {
|
||||
$resaction = '';
|
||||
$nbsent = 0;
|
||||
|
|
@ -69,12 +79,13 @@ if (!$error && $massaction == 'confirm_presend_attendees') {
|
|||
$listofobjectref = array();
|
||||
$oneemailperrecipient = (GETPOSTINT('oneemailperrecipient') ? 1 : 0);
|
||||
|
||||
$listofselectedid = array();
|
||||
$listofselectedref = array();
|
||||
if (!$error) {
|
||||
require_once DOL_DOCUMENT_ROOT . '/eventorganization/class/conferenceorboothattendee.class.php';
|
||||
$attendee = new ConferenceOrBoothAttendee($db);
|
||||
$listofselectedid = array();
|
||||
$listofselectedref = array();
|
||||
$objecttmp = new $objectclass($db);
|
||||
'@phan-var-force CommonObject $objecttmp';
|
||||
|
||||
foreach ($toselect as $toselectid) {
|
||||
$result = $objecttmp->fetch($toselectid);
|
||||
|
|
@ -93,6 +104,7 @@ if (!$error && $massaction == 'confirm_presend_attendees') {
|
|||
}
|
||||
}
|
||||
'@phan-var-force CommonObject $objecttmp';
|
||||
'@phan-var-force array<string,CommonObject> $listofselectedref';
|
||||
|
||||
// Check mandatory parameters
|
||||
if (GETPOST('fromtype', 'alpha') === 'user' && empty($user->email)) {
|
||||
|
|
@ -121,7 +133,7 @@ if (!$error && $massaction == 'confirm_presend_attendees') {
|
|||
$massaction = 'presend_attendees';
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
if (!$error && !empty($listofselectedid)) {
|
||||
$objecttmp->fetch_thirdparty();
|
||||
foreach ($listofselectedid as $email => $attendees) {
|
||||
$sendto = '';
|
||||
|
|
@ -182,6 +194,8 @@ if (!$error && $massaction == 'confirm_presend_attendees') {
|
|||
// $objecttmp is a real object or an empty object if we choose to send one email per thirdparty instead of one per object
|
||||
// Make substitution in email content
|
||||
$substitutionarray = getCommonSubstitutionArray($langs, 0, null, $attendees);
|
||||
$url_link = null;
|
||||
$html_link = null;
|
||||
|
||||
if (getDolGlobalString('MAIN_AGENDA_XCAL_EXPORTKEY')) {
|
||||
$urlwithouturlroot = preg_replace('/' . preg_quote(DOL_URL_ROOT, '/') . '$/i', '', trim($dolibarr_main_url_root));
|
||||
|
|
@ -269,7 +283,7 @@ if (!$error && $massaction == 'confirm_presend_attendees') {
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} // foreach ($listofselectedid as $email => $attendees)
|
||||
}
|
||||
$resaction .= ($resaction ? '<br>' : $resaction);
|
||||
$resaction .= '<strong>' . $langs->trans("ResultOfMailSending") . ':</strong><br>' . "\n";
|
||||
|
|
|
|||
|
|
@ -128,6 +128,10 @@ $result = restrictedArea($user, 'expedition', $object->id, '');
|
|||
$permissiondellink = $user->hasRight('expedition', 'delivery', 'creer'); // Used by the include of actions_dellink.inc.php
|
||||
$permissiontoadd = $user->hasRight('expedition', 'creer');
|
||||
|
||||
$editColspan = 0;
|
||||
$objectsrc = null;
|
||||
$typeobject = null;
|
||||
|
||||
|
||||
/*
|
||||
* Actions
|
||||
|
|
@ -249,6 +253,7 @@ if (empty($reshook)) {
|
|||
// We will loop on each line of the original document to complete the shipping object with various info and quantity to deliver
|
||||
$classname = ucfirst($object->origin);
|
||||
$objectsrc = new $classname($db);
|
||||
'@phan-var-force Facture|Commande $objectsrc';
|
||||
$objectsrc->fetch($object->origin_id);
|
||||
|
||||
$object->socid = $objectsrc->socid;
|
||||
|
|
@ -909,6 +914,8 @@ $formfile = new FormFile($db);
|
|||
$formproduct = new FormProduct($db);
|
||||
if (isModEnabled('project')) {
|
||||
$formproject = new FormProjets($db);
|
||||
} else {
|
||||
$formproject = null;
|
||||
}
|
||||
|
||||
$product_static = new Product($db);
|
||||
|
|
@ -938,6 +945,7 @@ if ($action == 'create') {
|
|||
$classname = ucfirst($origin);
|
||||
|
||||
$object = new $classname($db);
|
||||
'@phan-var-force Commande|Facture $object';
|
||||
if ($object->fetch($origin_id)) { // This include the fetch_lines
|
||||
$soc = new Societe($db);
|
||||
$soc->fetch($object->socid);
|
||||
|
|
@ -995,7 +1003,7 @@ if ($action == 'create') {
|
|||
print '</tr>';
|
||||
|
||||
// Project
|
||||
if (isModEnabled('project')) {
|
||||
if (isModEnabled('project') && is_object($formproject)) {
|
||||
$projectid = GETPOSTINT('projectid') ? GETPOSTINT('projectid') : 0;
|
||||
if (empty($projectid) && !empty($object->fk_project)) {
|
||||
$projectid = $object->fk_project;
|
||||
|
|
@ -1241,7 +1249,7 @@ if ($action == 'create') {
|
|||
$text .= ' - '.(!empty($line->label) ? $line->label : $line->product_label);
|
||||
$description = ($showdescinproductdesc ? '' : dol_htmlentitiesbr($line->desc));
|
||||
|
||||
print $form->textwithtooltip($text, $description, 3, '', '', $i);
|
||||
print $form->textwithtooltip($text, $description, 3, 0, '', $i);
|
||||
|
||||
// Show range
|
||||
print_date_range($db->jdate($line->date_start), $db->jdate($line->date_end));
|
||||
|
|
@ -1262,7 +1270,7 @@ if ($action == 'create') {
|
|||
|
||||
if (!empty($line->label)) {
|
||||
$text .= ' <strong>'.$line->label.'</strong>';
|
||||
print $form->textwithtooltip($text, $line->desc, 3, '', '', $i);
|
||||
print $form->textwithtooltip($text, $line->desc, 3, 0, '', $i);
|
||||
} else {
|
||||
print $text.' '.nl2br($line->desc);
|
||||
}
|
||||
|
|
@ -1350,7 +1358,7 @@ if ($action == 'create') {
|
|||
if (!getDolGlobalInt('STOCK_ALLOW_NEGATIVE_TRANSFER')) {
|
||||
$stockMin = 0;
|
||||
}
|
||||
print $formproduct->selectWarehouses($tmpentrepot_id, 'entl'.$indiceAsked, '', 1, 0, $line->fk_product, '', 1, 0, array(), 'minwidth200', '', 1, $stockMin, 'stock DESC, e.ref');
|
||||
print $formproduct->selectWarehouses($tmpentrepot_id, 'entl'.$indiceAsked, '', 1, 0, $line->fk_product, '', 1, 0, array(), 'minwidth200', array(), 1, $stockMin, 'stock DESC, e.ref');
|
||||
|
||||
if ($tmpentrepot_id > 0 && $tmpentrepot_id == $warehouse_id) {
|
||||
//print $stock.' '.$quantityToBeDelivered;
|
||||
|
|
@ -1435,7 +1443,9 @@ if ($action == 'create') {
|
|||
$deliverableQty = min($quantityToBeDelivered, $batchStock);
|
||||
}
|
||||
|
||||
if ($deliverableQty < 0) $deliverableQty = 0;
|
||||
if ($deliverableQty < 0) {
|
||||
$deliverableQty = 0;
|
||||
}
|
||||
|
||||
$inputName = 'qtyl'.$indiceAsked.'_'.$subj;
|
||||
if (GETPOSTISSET($inputName)) {
|
||||
|
|
@ -1824,6 +1834,7 @@ if ($action == 'create') {
|
|||
}
|
||||
}
|
||||
} elseif ($object->id > 0) {
|
||||
'@phan-var-force Expedition $object'; // Need to force it (type overridden earlier)
|
||||
/* *************************************************************************** */
|
||||
/* */
|
||||
/* Edit and view mode */
|
||||
|
|
@ -2386,7 +2397,7 @@ if ($action == 'create') {
|
|||
$text = $product_static->getNomUrl(1);
|
||||
$text .= ' - '.$label;
|
||||
$description = (getDolGlobalInt('PRODUIT_DESC_IN_FORM_ACCORDING_TO_DEVICE') ? '' : dol_htmlentitiesbr($lines[$i]->description));
|
||||
print $form->textwithtooltip($text, $description, 3, '', '', $i);
|
||||
print $form->textwithtooltip($text, $description, 3, 0, '', $i);
|
||||
print_date_range(!empty($lines[$i]->date_start) ? $lines[$i]->date_start : '', !empty($lines[$i]->date_end) ? $lines[$i]->date_end : '');
|
||||
if (getDolGlobalInt('PRODUIT_DESC_IN_FORM_ACCORDING_TO_DEVICE')) {
|
||||
print (!empty($lines[$i]->description) && $lines[$i]->description != $lines[$i]->product) ? '<br>'.dol_htmlentitiesbr($lines[$i]->description) : '';
|
||||
|
|
@ -2402,7 +2413,7 @@ if ($action == 'create') {
|
|||
|
||||
if (!empty($lines[$i]->label)) {
|
||||
$text .= ' <strong>'.$lines[$i]->label.'</strong>';
|
||||
print $form->textwithtooltip($text, $lines[$i]->description, 3, '', '', $i);
|
||||
print $form->textwithtooltip($text, $lines[$i]->description, 3, 0, '', $i);
|
||||
} else {
|
||||
print $text.' '.nl2br($lines[$i]->description);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -100,6 +100,9 @@ class Expedition extends CommonObject
|
|||
*/
|
||||
public $fk_user_author;
|
||||
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $socid;
|
||||
|
||||
/**
|
||||
|
|
@ -128,6 +131,9 @@ class Expedition extends CommonObject
|
|||
* @var string Tracking url
|
||||
*/
|
||||
public $tracking_url;
|
||||
/**
|
||||
* @var int<0,1>
|
||||
*/
|
||||
public $billed;
|
||||
|
||||
/**
|
||||
|
|
@ -135,32 +141,76 @@ class Expedition extends CommonObject
|
|||
*/
|
||||
public $model_pdf;
|
||||
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $trueWeight;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $weight_units;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $trueWidth;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $width_units;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $trueHeight;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $height_units;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $trueDepth;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $depth_units;
|
||||
// A denormalized value
|
||||
/**
|
||||
* @var string A denormalized value
|
||||
*/
|
||||
public $trueSize;
|
||||
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $livraison_id;
|
||||
|
||||
/**
|
||||
* @var double
|
||||
* @var float
|
||||
*/
|
||||
public $multicurrency_subprice;
|
||||
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $size_units;
|
||||
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $sizeH;
|
||||
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $sizeS;
|
||||
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $sizeW;
|
||||
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $weight;
|
||||
|
||||
/**
|
||||
|
|
@ -169,13 +219,15 @@ class Expedition extends CommonObject
|
|||
public $date_delivery;
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
* @var int|string
|
||||
* @deprecated Use $dateshipping
|
||||
* @see $date_shipping
|
||||
*/
|
||||
public $date;
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
* @var int|string
|
||||
* @deprecated Use $dateshipping
|
||||
* @see $date_shipping
|
||||
*/
|
||||
public $date_expedition;
|
||||
|
|
@ -191,7 +243,13 @@ class Expedition extends CommonObject
|
|||
*/
|
||||
public $date_valid;
|
||||
|
||||
/**
|
||||
* @var string[]
|
||||
*/
|
||||
public $meths;
|
||||
/**
|
||||
* @var array<array<string,string>>
|
||||
*/
|
||||
public $listmeths; // List of carriers
|
||||
|
||||
/**
|
||||
|
|
@ -219,9 +277,21 @@ class Expedition extends CommonObject
|
|||
* @var string multicurrency code
|
||||
*/
|
||||
public $multicurrency_code;
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
public $multicurrency_tx;
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
public $multicurrency_total_ht;
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
public $multicurrency_total_tva;
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
public $multicurrency_total_ttc;
|
||||
|
||||
/**
|
||||
|
|
@ -506,7 +576,7 @@ class Expedition extends CommonObject
|
|||
* @param int $origin_line_id Id of source line
|
||||
* @param float $qty Quantity
|
||||
* @param int $rang Rang
|
||||
* @param array $array_options extrafields array
|
||||
* @param array<string,mixed> $array_options extrafields array
|
||||
* @return int Return integer <0 if KO, line_id if OK
|
||||
*/
|
||||
public function create_line($entrepot_id, $origin_line_id, $qty, $rang = 0, $array_options = [])
|
||||
|
|
@ -534,8 +604,8 @@ class Expedition extends CommonObject
|
|||
/**
|
||||
* Create the detail of the expedition line. Create 1 record into expeditiondet for each warehouse and n record for each lot in this warehouse into expeditiondet_batch.
|
||||
*
|
||||
* @param object $line_ext Object with full information of line. $line_ext->detail_batch must be an array of ExpeditionLineBatch
|
||||
* @param array $array_options extrafields array
|
||||
* @param ExpeditionLigne $line_ext Object with full information of line. $line_ext->detail_batch must be an array of ExpeditionLineBatch
|
||||
* @param array<string,mixed> $array_options extrafields array
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function create_line_batch($line_ext, $array_options = [])
|
||||
|
|
@ -912,7 +982,7 @@ class Expedition extends CommonObject
|
|||
* @param int $entrepot_id Id of warehouse
|
||||
* @param int $id Id of source line (order line)
|
||||
* @param float $qty Quantity
|
||||
* @param array $array_options extrafields array
|
||||
* @param array<string,mixed> $array_options extrafields array
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function addline($entrepot_id, $id, $qty, $array_options = [])
|
||||
|
|
@ -995,8 +1065,8 @@ class Expedition extends CommonObject
|
|||
/**
|
||||
* Add a shipment line with batch record
|
||||
*
|
||||
* @param array $dbatch Array of value (key 'detail' -> Array, key 'qty' total quantity for line, key ix_l : original line index)
|
||||
* @param array $array_options extrafields array
|
||||
* @param array{detail:array<array{id_batch:int,q:int|float}>,qty:int|float,ix_l:int} $dbatch Array of value (key 'detail' -> Array, key 'qty' total quantity for line, key ix_l : original line index)
|
||||
* @param array<string,mixed> $array_options extrafields array
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function addline_batch($dbatch, $array_options = [])
|
||||
|
|
@ -1005,6 +1075,7 @@ class Expedition extends CommonObject
|
|||
global $conf, $langs;
|
||||
|
||||
$num = count($this->lines);
|
||||
$linebatch = null;
|
||||
if ($dbatch['qty'] > 0 || ($dbatch['qty'] == 0 && getDolGlobalString('SHIPMENT_GETS_ALL_ORDER_PRODUCTS'))) {
|
||||
$line = new ExpeditionLigne($this->db);
|
||||
$tab = array();
|
||||
|
|
@ -1043,7 +1114,9 @@ class Expedition extends CommonObject
|
|||
//var_dump($linebatch);
|
||||
}
|
||||
}
|
||||
$line->entrepot_id = $linebatch->entrepot_id;
|
||||
if (is_object($linebatch)) {
|
||||
$line->entrepot_id = $linebatch->entrepot_id;
|
||||
}
|
||||
$line->origin_line_id = $dbatch['ix_l']; // deprecated
|
||||
$line->fk_elementdet = $dbatch['ix_l'];
|
||||
$line->qty = $dbatch['qty'];
|
||||
|
|
@ -1064,9 +1137,9 @@ class Expedition extends CommonObject
|
|||
/**
|
||||
* Update database
|
||||
*
|
||||
* @param User $user User that modify
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
* @param User $user User that modifies the record
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function update($user = null, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -1090,7 +1163,8 @@ class Expedition extends CommonObject
|
|||
if (isset($this->fk_user_author)) {
|
||||
$this->fk_user_author = (int) $this->fk_user_author;
|
||||
}
|
||||
if (isset($this->fk_user_valid)) {
|
||||
if (isset($this->fk_user_valid)) { // @phan-ignore-current-line PhanUndeclaredProperty
|
||||
// If set, then accept @phan-ignore-next-line PhanUndeclaredProperty
|
||||
$this->fk_user_valid = (int) $this->fk_user_valid;
|
||||
}
|
||||
if (isset($this->fk_delivery_address)) {
|
||||
|
|
@ -1118,7 +1192,7 @@ class Expedition extends CommonObject
|
|||
$this->size_units = trim($this->size_units);
|
||||
}
|
||||
if (isset($this->weight_units)) {
|
||||
$this->weight_units = trim($this->weight_units);
|
||||
$this->weight_units = (int) $this->weight_units;
|
||||
}
|
||||
if (isset($this->trueWeight)) {
|
||||
$this->weight = trim((string) $this->trueWeight);
|
||||
|
|
@ -1332,12 +1406,14 @@ class Expedition extends CommonObject
|
|||
if ($this->db->query($sql)) {
|
||||
if (!empty($this->origin) && $this->origin_id > 0) {
|
||||
$this->fetch_origin();
|
||||
if ($this->origin_object->statut == Commande::STATUS_SHIPMENTONPROCESS) { // If order source of shipment is "shipment in progress"
|
||||
$origin_object = $this->origin_object;
|
||||
'@phan-var-force Facture|Commande $origin_object';
|
||||
if ($origin_object->statut == Commande::STATUS_SHIPMENTONPROCESS) { // If order source of shipment is "shipment in progress"
|
||||
// Check if there is no more shipment. If not, we can move back status of order to "validated" instead of "shipment in progress"
|
||||
$this->origin_object->loadExpeditions();
|
||||
$origin_object->loadExpeditions();
|
||||
//var_dump($this->$origin->expeditions);exit;
|
||||
if (count($this->origin_object->expeditions) <= 0) {
|
||||
$this->origin_object->setStatut(Commande::STATUS_VALIDATED);
|
||||
if (count($origin_object->expeditions) <= 0) {
|
||||
$origin_object->setStatut(Commande::STATUS_VALIDATED);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1533,12 +1609,14 @@ class Expedition extends CommonObject
|
|||
if ($this->db->query($sql)) {
|
||||
if (!empty($this->origin) && $this->origin_id > 0) {
|
||||
$this->fetch_origin();
|
||||
if ($this->origin_object->statut == Commande::STATUS_SHIPMENTONPROCESS) { // If order source of shipment is "shipment in progress"
|
||||
$origin_object = $this->origin_object;
|
||||
'@phan-var-force Facture|Commande $origin_object';
|
||||
if ($origin_object->statut == Commande::STATUS_SHIPMENTONPROCESS) { // If order source of shipment is "shipment in progress"
|
||||
// Check if there is no more shipment. If not, we can move back status of order to "validated" instead of "shipment in progress"
|
||||
$this->origin_object->loadExpeditions();
|
||||
$origin_object->loadExpeditions();
|
||||
//var_dump($this->$origin->expeditions);exit;
|
||||
if (count($this->origin_object->expeditions) <= 0) {
|
||||
$this->origin_object->setStatut(Commande::STATUS_VALIDATED);
|
||||
if (count($origin_object->expeditions) <= 0) {
|
||||
$origin_object->setStatut(Commande::STATUS_VALIDATED);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -2586,7 +2664,7 @@ class Expedition extends CommonObject
|
|||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
|
|||
|
|
@ -133,13 +133,13 @@ class ExpeditionLigne extends CommonObjectLine
|
|||
/**
|
||||
* Detail of lot and qty = array(id in llx_expeditiondet_batch, fk_expeditiondet, batch, qty, fk_origin_stock)
|
||||
* We can use this to know warehouse planned to be used for each lot.
|
||||
* @var stdClass|array{ExpeditionLineBatch}
|
||||
* @var stdClass|ExpeditionLineBatch[]
|
||||
*/
|
||||
public $detail_batch;
|
||||
|
||||
/** detail of warehouses and qty
|
||||
* We can use this to know warehouse when there is no lot.
|
||||
* @var array{stdClass}
|
||||
* @var stdClass[]
|
||||
*/
|
||||
public $details_entrepot;
|
||||
|
||||
|
|
|
|||
|
|
@ -1577,7 +1577,7 @@ while ($i < $imaxinloop) {
|
|||
print $form->textwithpicto('', $langs->trans('EstimatedWeight'), 1);
|
||||
} else {
|
||||
print $object->trueWeight;
|
||||
print ($object->trueWeight && $object->weight_units != '') ? ' '.measuringUnitString(0, "weight", $object->weight_units) : '';
|
||||
print ($object->trueWeight && $object->weight_units != '') ? ' '.measuringUnitString(0, "weight", (string) $object->weight_units) : '';
|
||||
}
|
||||
print '</td>';
|
||||
if (!$i) {
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
* Copyright (C) 2012-2015 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2018-2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2018-2022 Philippe Grand <philippe.grand@atoo-net.com>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -207,7 +208,7 @@ if (empty($reshook)) {
|
|||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->fetch($id);
|
||||
$object->setValueFrom('fk_soc', $socid, '', '', 'date', '', $user, 'ORDER_MODIFY');
|
||||
$object->setValueFrom('fk_soc', $socid, '', null, 'date', '', $user, 'ORDER_MODIFY');
|
||||
|
||||
header('Location: '.$_SERVER["PHP_SELF"].'?id='.$id);
|
||||
exit();
|
||||
|
|
|
|||
|
|
@ -1975,7 +1975,7 @@ if ($action == 'create') {
|
|||
$paymentexpensereportstatic->type_code = $objp->payment_code;
|
||||
$paymentexpensereportstatic->type_label = $objp->payment_type;
|
||||
|
||||
print '<tr class="oddseven">';
|
||||
print '<tr class="oddeven">';
|
||||
print '<td>';
|
||||
print $paymentexpensereportstatic->getNomUrl(1);
|
||||
print '</td>';
|
||||
|
|
|
|||
|
|
@ -606,7 +606,7 @@ if (!empty($arrayfields['d.ref']['checked'])) {
|
|||
// User
|
||||
if (!empty($arrayfields['user']['checked'])) {
|
||||
if ($user->hasRight('expensereport', 'readall') || $user->hasRight('expensereport', 'lire_tous')) {
|
||||
print '<td class="liste_titre maxwidthonspartphone" align="left">';
|
||||
print '<td class="liste_titre maxwidthonsmartphone" align="left">';
|
||||
print $form->select_dolusers($search_user, 'search_user', 1, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth200');
|
||||
print '</td>';
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -224,7 +224,7 @@ if ($action == 'add' && $permissiontoadd) {
|
|||
if ($newfichinterid > 0) {
|
||||
// Now we add line of details
|
||||
foreach ($object->lines as $line) {
|
||||
$newinter->addline($user, $newfichinterid, $line->desc, $line->datei, $line->duree, '');
|
||||
$newinter->addline($user, $newfichinterid, $line->desc, $line->datei, $line->duree, array());
|
||||
}
|
||||
|
||||
// on update le nombre d'inter crée à partir du modèle
|
||||
|
|
|
|||
|
|
@ -788,13 +788,13 @@ class Fichinter extends CommonObject
|
|||
/**
|
||||
* Create a document onto disk according to template module.
|
||||
*
|
||||
* @param string $modele Force model to use ('' to not force)
|
||||
* @param Translate $outputlangs Object langs to use for output
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
* @param string $modele Force model to use ('' to not force)
|
||||
* @param Translate $outputlangs Object langs to use for output
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
{
|
||||
|
|
@ -1384,9 +1384,9 @@ class Fichinter extends CommonObject
|
|||
* @param user $user User that do the action
|
||||
* @param int $fichinterid Id of intervention
|
||||
* @param string $desc Line description
|
||||
* @param integer $date_intervention Intervention date
|
||||
* @param int $date_intervention Intervention date
|
||||
* @param int $duration Intervention duration
|
||||
* @param array $array_options Array option
|
||||
* @param array<string,?mixed> $array_options Array option
|
||||
* @return int >0 if ok, <0 if ko
|
||||
*/
|
||||
public function addline($user, $fichinterid, $desc, $date_intervention, $duration, $array_options = [])
|
||||
|
|
@ -1615,6 +1615,7 @@ class Fichinter extends CommonObject
|
|||
}
|
||||
if (!empty($arraydata['thirdparty'])) {
|
||||
$tmpthirdparty = $arraydata['thirdparty'];
|
||||
'@phan-var-force Societe $tmpthirdparty';
|
||||
$return .= '<br><span class="info-box-label">'.$tmpthirdparty->getNomUrl(1).'</span>';
|
||||
}
|
||||
if (property_exists($this, 'duration')) {
|
||||
|
|
|
|||
|
|
@ -139,6 +139,9 @@ class ProductFournisseur extends Product
|
|||
*/
|
||||
public $fourn_remise;
|
||||
|
||||
/**
|
||||
* @var ?float
|
||||
*/
|
||||
public $fourn_charges; // when getDolGlobalString('PRODUCT_CHARGES') is set
|
||||
|
||||
/**
|
||||
|
|
@ -146,6 +149,9 @@ class ProductFournisseur extends Product
|
|||
*/
|
||||
public $product_fourn_id;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $product_fourn_entity;
|
||||
|
||||
/**
|
||||
|
|
@ -158,9 +164,21 @@ class ProductFournisseur extends Product
|
|||
*/
|
||||
public $fk_availability;
|
||||
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $fourn_unitprice;
|
||||
/**
|
||||
* @var float|int
|
||||
*/
|
||||
public $fourn_unitprice_with_discount; // not saved into database
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $fourn_tva_tx;
|
||||
/**
|
||||
* @var int<0,1>
|
||||
*/
|
||||
public $fourn_tva_npr;
|
||||
|
||||
/**
|
||||
|
|
@ -178,20 +196,33 @@ class ProductFournisseur extends Product
|
|||
*/
|
||||
public $reputations = array();
|
||||
|
||||
// Multicurreny
|
||||
// Multicurrency
|
||||
|
||||
/**
|
||||
* @var int ID of multicurrency
|
||||
*/
|
||||
public $fourn_multicurrency_id;
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $fourn_multicurrency_code;
|
||||
/**
|
||||
* @var int|float|string
|
||||
*/
|
||||
public $fourn_multicurrency_tx;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $fourn_multicurrency_price;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $fourn_multicurrency_unitprice;
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
* @var string
|
||||
* @deprecated Use $supplier_barcode
|
||||
* @see $supplier_barcode
|
||||
*/
|
||||
public $fourn_barcode;
|
||||
|
|
@ -202,7 +233,8 @@ class ProductFournisseur extends Product
|
|||
public $supplier_barcode;
|
||||
|
||||
/**
|
||||
* @deprecated
|
||||
* @var int
|
||||
* @deprecated Use $supplier_fk_barcode_type
|
||||
* @see $supplier_fk_barcode_type
|
||||
*/
|
||||
public $fourn_fk_barcode_type;
|
||||
|
|
@ -212,9 +244,18 @@ class ProductFournisseur extends Product
|
|||
*/
|
||||
public $supplier_fk_barcode_type;
|
||||
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
public $packaging;
|
||||
|
||||
/**
|
||||
* @var array<int,string>
|
||||
*/
|
||||
public $labelStatusShort;
|
||||
/**
|
||||
* @var array<int,string>
|
||||
*/
|
||||
public $labelStatus;
|
||||
|
||||
const STATUS_OPEN = 1;
|
||||
|
|
@ -332,7 +373,7 @@ class ProductFournisseur extends Product
|
|||
* @param int $newnpr Set NPR or not
|
||||
* @param int $delivery_time_days Delay in days for delivery (max). May be '' if not defined.
|
||||
* @param string $supplier_reputation Reputation with this product to the defined supplier (empty, FAVORITE, DONOTORDER)
|
||||
* @param array $localtaxes_array Array with localtaxes info array('0'=>type1,'1'=>rate1,'2'=>type2,'3'=>rate2) (loaded by getLocalTaxesFromRate(vatrate, 0, ...) function).
|
||||
* @param array{0:string,1:float|int,2:string,3:float|int}|array{} $localtaxes_array Array with localtaxes info array('0'=>type1,'1'=>rate1,'2'=>type2,'3'=>rate2) (loaded by getLocalTaxesFromRate(vatrate, 0, ...) function).
|
||||
* @param string $newdefaultvatcode Default vat code
|
||||
* @param float $multicurrency_buyprice Purchase price for the quantity min in currency
|
||||
* @param string $multicurrency_price_base_type HT or TTC in currency
|
||||
|
|
@ -341,7 +382,7 @@ class ProductFournisseur extends Product
|
|||
* @param string $desc_fourn Custom description for product_fourn_price
|
||||
* @param string $barcode Barcode
|
||||
* @param int $fk_barcode_type Barcode type
|
||||
* @param array $options Extrafields of product fourn price
|
||||
* @param array<string,mixed> $options Extrafields of product fourn price
|
||||
* @return int Return integer <0 if KO, >=0 if OK
|
||||
*/
|
||||
public function update_buyprice(
|
||||
|
|
@ -861,7 +902,8 @@ class ProductFournisseur extends Product
|
|||
$price_result = $priceparser->parseProductSupplier($prodfourn);
|
||||
if ($price_result >= 0) {
|
||||
$prodfourn->fourn_price = $price_result;
|
||||
$prodfourn->fourn_unitprice = null; //force recalculation of unitprice, as probably the price changed...
|
||||
// Set to null on purpose an will have non-null value before method return @phan-suppress-next-line PhanTypeMismatchPropertyProbablyReal
|
||||
$prodfourn->fourn_unitprice = null; //force recalculation of unitprice, as probably the price changed... @phpstan-ignore-line
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1000,6 +1042,7 @@ class ProductFournisseur extends Product
|
|||
$this->fourn_id = $record["fourn_id"]; // thirdparty id
|
||||
$this->fourn_name = $record["supplier_name"];
|
||||
$this->delivery_time_days = $record["delivery_time_days"];
|
||||
// False positive @phan-suppress-next-line PhanTypeMismatchProperty
|
||||
$this->fk_supplier_price_expression = $record["fk_supplier_price_expression"];
|
||||
$this->fourn_multicurrency_price = $record["multicurrency_price"];
|
||||
$this->fourn_multicurrency_unitprice = $record["multicurrency_unitprice"];
|
||||
|
|
@ -1074,12 +1117,12 @@ class ProductFournisseur extends Product
|
|||
/**
|
||||
* Display price of product
|
||||
*
|
||||
* @param int $showunitprice Show "Unit price" into output string
|
||||
* @param int $showsuptitle Show "Supplier" into output string
|
||||
* @param int $maxlen Max length of name
|
||||
* @param integer $notooltip 1=Disable tooltip
|
||||
* @param array $productFournList list of ProductFournisseur objects
|
||||
* to display in table format.
|
||||
* @param int<0,1> $showunitprice Show "Unit price" into output string
|
||||
* @param int<0,1> $showsuptitle Show "Supplier" into output string
|
||||
* @param int $maxlen Max length of name
|
||||
* @param int<0,1> $notooltip 1=Disable tooltip
|
||||
* @param ProductFournisseur[] $productFournList list of ProductFournisseur objects
|
||||
* to display in table format.
|
||||
* @return string String with supplier price
|
||||
*/
|
||||
public function display_price_product_fournisseur($showunitprice = 1, $showsuptitle = 1, $maxlen = 0, $notooltip = 0, $productFournList = array())
|
||||
|
|
@ -1152,7 +1195,7 @@ class ProductFournisseur extends Product
|
|||
* @param string $sortorder Sort order
|
||||
* @param int $limit Limit
|
||||
* @param int $offset Offset
|
||||
* @return array|int Array of Log prices
|
||||
* @return array<array{rowid:int,supplier_ref:int,datec:int,lastname:string,price:float,quantity:float,fk_multicurrency:int,multicurrency_code:string,multicurrency_tx:string,multicurrency_price:string,multicurrency_unitprice:string}>|int<-1,-1> Array of Log prices
|
||||
*/
|
||||
public function listProductFournisseurPriceLog($product_fourn_price_id, $sortfield = '', $sortorder = '', $limit = 0, $offset = 0)
|
||||
{
|
||||
|
|
@ -1208,8 +1251,8 @@ class ProductFournisseur extends Product
|
|||
/**
|
||||
* Display log price of product supplier price
|
||||
*
|
||||
* @param array $productFournLogList list of ProductFournisseur price log objects
|
||||
* to display in table format.
|
||||
* @param array<array{rowid:int,supplier_ref:int,datec:int,lastname:string,price:float,quantity:float,fk_multicurrency:int,multicurrency_code:string,multicurrency_tx:string,multicurrency_price:string,multicurrency_unitprice:string}>|int<-1,-1> $productFournLogList list of ProductFournisseur price log objects
|
||||
* to display in table format.
|
||||
* @return string HTML String with supplier price
|
||||
*/
|
||||
public function displayPriceProductFournisseurLog($productFournLogList = array())
|
||||
|
|
|
|||
|
|
@ -35,6 +35,10 @@ global $noMoreLinkedObjectBlockAfter;
|
|||
$langs = $GLOBALS['langs'];
|
||||
'@phan-var-force Translate $langs';
|
||||
$linkedObjectBlock = $GLOBALS['linkedObjectBlock'];
|
||||
'
|
||||
@phan-var-force array<string,CommonObject> $linkedObjectBlock
|
||||
';
|
||||
|
||||
|
||||
$langs->load("bills");
|
||||
|
||||
|
|
@ -68,6 +72,7 @@ foreach ($linkedObjectBlock as $key => $objectlink) {
|
|||
} ?></td>
|
||||
<td class="right"><?php
|
||||
if (method_exists($objectlink, 'getSommePaiement')) {
|
||||
// @phan-suppress-next-line PhanUnknownMethodCall
|
||||
echo $objectlink->getLibStatut(3, $objectlink->getSommePaiement());
|
||||
} else {
|
||||
echo $objectlink->getLibStatut(3);
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@
|
|||
* Copyright (C) 2019-2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 Benjamin Falière <benjamin.faliere@altairis.fr>
|
||||
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -815,7 +816,7 @@ $listhalfday = array('morning' => $langs->trans("Morning"), "afternoon" => $lang
|
|||
// If we ask a dedicated card and not allow to see it, we force on user.
|
||||
if ($id && !$user->hasRight('holiday', 'readall') && !in_array($id, $childids)) {
|
||||
$langs->load("errors");
|
||||
print '<tr class="oddeven opacitymediuem"><td colspan="10">'.$langs->trans("NotEnoughPermissions").'</td></tr>';
|
||||
print '<tr class="oddeven opacitymedium"><td colspan="10">'.$langs->trans("NotEnoughPermissions").'</td></tr>';
|
||||
$result = 0;
|
||||
} elseif ($num > 0 && !empty($mysoc->country_id)) {
|
||||
// Lines
|
||||
|
|
|
|||
|
|
@ -111,18 +111,57 @@ class Evaluation extends CommonObject
|
|||
'fk_user' => array('type' => 'integer:User:user/class/user.class.php:0', 'label' => 'Employee', 'enabled' => 1, 'position' => 504, 'notnull' => 1, 'visible' => 1, 'picto' => 'user', 'css' => 'maxwidth300 widthcentpercentminusxx', 'csslist' => 'tdoverflowmax150'),
|
||||
'fk_job' => array('type' => 'integer:Job:/hrm/class/job.class.php', 'label' => 'JobProfile', 'enabled' => 1, 'position' => 505, 'notnull' => 1, 'visible' => 1, 'picto' => 'jobprofile', 'css' => 'maxwidth300 widthcentpercentminusxx', 'csslist' => 'tdoverflowmax150'),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $ref;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $label;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $description;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $note_public;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $note_private;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $import_key;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $status;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $date_eval;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_job;
|
||||
// END MODULEBUILDER PROPERTIES
|
||||
|
||||
|
|
@ -681,8 +720,8 @@ class Evaluation extends CommonObject
|
|||
/**
|
||||
* Set back to validated status
|
||||
*
|
||||
* @param User $user Object user that modify
|
||||
* @param int $notrigger 1=Does not execute triggers, 0=Execute triggers
|
||||
* @param User $user Object user that modify
|
||||
* @param int<0,1> $notrigger 1=Does not execute triggers, 0=Execute triggers
|
||||
* @return int Return integer <0 if KO, 0=Nothing done, >0 if OK
|
||||
*/
|
||||
public function reopen($user, $notrigger = 0)
|
||||
|
|
@ -813,8 +852,8 @@ class Evaluation extends CommonObject
|
|||
/**
|
||||
* Return the label of the status
|
||||
*
|
||||
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
|
||||
* @return string Label of status
|
||||
* @param int<0,6> $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
|
||||
* @return string Label of status
|
||||
*/
|
||||
public function getLibStatut($mode = 0)
|
||||
{
|
||||
|
|
@ -825,9 +864,9 @@ class Evaluation extends CommonObject
|
|||
/**
|
||||
* Return the status
|
||||
*
|
||||
* @param int $status Id status
|
||||
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
|
||||
* @return string Label of status
|
||||
* @param int $status Id status
|
||||
* @param int<0,6> $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
|
||||
* @return string Label of status
|
||||
*/
|
||||
public function LibStatut($status, $mode = 0)
|
||||
{
|
||||
|
|
@ -901,7 +940,7 @@ class Evaluation extends CommonObject
|
|||
/**
|
||||
* Create an array of lines
|
||||
*
|
||||
* @return array|int array of lines if OK, <0 if KO
|
||||
* @return EvaluationLine[]|int array of lines if OK, <0 if KO
|
||||
*/
|
||||
public function getLinesArray()
|
||||
{
|
||||
|
|
@ -955,6 +994,7 @@ class Evaluation extends CommonObject
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefEvaluation $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -979,10 +1019,10 @@ class Evaluation extends CommonObject
|
|||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
|
|||
|
|
@ -115,13 +115,37 @@ class EvaluationLine extends CommonObjectLine
|
|||
'required_rank' => array('type' => 'integer', 'label' => 'requiredRank', 'enabled' => 1, 'position' => 5, 'notnull' => 1, 'visible' => 1,),
|
||||
'import_key' => array('type' => 'varchar(14)', 'label' => 'ImportId', 'enabled' => 1, 'position' => 1000, 'notnull' => -1, 'visible' => -2,),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_skill;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_evaluation;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_rank;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $required_rank;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $import_key;
|
||||
// END MODULEBUILDER PROPERTIES
|
||||
|
||||
|
|
@ -933,6 +957,7 @@ class EvaluationLine extends CommonObjectLine
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefEvaluation $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -955,13 +980,13 @@ class EvaluationLine extends CommonObjectLine
|
|||
/**
|
||||
* Create a document onto disk according to template module.
|
||||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -104,13 +104,33 @@ class Job extends CommonObject
|
|||
'fk_user_creat' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserAuthor', 'enabled' => 1, 'position' => 510, 'notnull' => 1, 'visible' => -2, 'foreignkey' => 'user.rowid',),
|
||||
'fk_user_modif' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserModif', 'enabled' => 1, 'position' => 511, 'notnull' => -1, 'visible' => -2,),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $ref;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $label;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $description;
|
||||
|
||||
/**
|
||||
* @var int<0,1>
|
||||
*/
|
||||
public $deplacement;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
// END MODULEBUILDER PROPERTIES
|
||||
|
||||
|
|
@ -963,6 +983,7 @@ class Job extends CommonObject
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefEvaluation $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -985,13 +1006,13 @@ class Job extends CommonObject
|
|||
/**
|
||||
* Create a document onto disk according to template module.
|
||||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -108,18 +108,57 @@ class Position extends CommonObject
|
|||
'fk_user_creat' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserAuthor', 'enabled' => 1, 'position' => 510, 'notnull' => 1, 'visible' => -2, 'foreignkey' => 'user.rowid',),
|
||||
'fk_user_modif' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserModif', 'enabled' => 1, 'position' => 511, 'notnull' => -1, 'visible' => -2,),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $ref;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $description;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_contrat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_job;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $date_start;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $date_end;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $abort_comment;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $note_public;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $note_private;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
|
||||
|
||||
|
|
@ -175,9 +214,9 @@ class Position extends CommonObject
|
|||
$this->ismultientitymanaged = 0;
|
||||
$this->isextrafieldmanaged = 0;
|
||||
|
||||
if (!getDolGlobalString('MAIN_SHOW_TECHNICAL_ID') && isset($this->fields['rowid'])) {
|
||||
//$this->fields['rowid']['visible'] = 0;
|
||||
}
|
||||
//if (!getDolGlobalString('MAIN_SHOW_TECHNICAL_ID') && isset($this->fields['rowid'])) {
|
||||
//$this->fields['rowid']['visible'] = 0;
|
||||
//}
|
||||
if (!isModEnabled('multicompany') && isset($this->fields['entity'])) {
|
||||
$this->fields['entity']['enabled'] = 0;
|
||||
}
|
||||
|
|
@ -879,7 +918,7 @@ class Position extends CommonObject
|
|||
* Return HTML string to show a field into a page
|
||||
* Code very similar with showOutputField of extra fields
|
||||
*
|
||||
* @param array $val Array of properties of field to show
|
||||
* @param array{type:string,label:string,enabled:int<0,2>|string,position:int,notnull?:int,visible:int,noteditable?:int,default?:string,index?:int,foreignkey?:string,searchall?:int,isameasure?:int,css?:string,csslist?:string,help?:string,showoncombobox?:int,disabled?:int,arrayofkeyval?:array<int,string>,comment?:string} $val Array of properties of field to show
|
||||
* @param string $key Key of attribute
|
||||
* @param string $value Preselected value to show (for date type it must be in timestamp format, for amount or price it must be a php numeric value)
|
||||
* @param string $moreparam To add more parameters on html input tag
|
||||
|
|
@ -1002,6 +1041,7 @@ class Position extends CommonObject
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefEvaluation $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -1039,13 +1079,13 @@ class Position extends CommonObject
|
|||
/**
|
||||
* Create a document onto disk according to template module.
|
||||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -112,14 +112,41 @@ class Skill extends CommonObject
|
|||
'note_public' => array('type' => 'html', 'label' => 'NotePublic', 'enabled' => 1, 'position' => 70, 'notnull' => 0, 'visible' => 0,),
|
||||
'note_private' => array('type' => 'html', 'label' => 'NotePrivate', 'enabled' => 1, 'position' => 71, 'notnull' => 0, 'visible' => 0,),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $label;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $description;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $required_level;
|
||||
public $date_validite;
|
||||
/**
|
||||
* @var int|string
|
||||
*/
|
||||
public $date_validite; // Note: misspelled!
|
||||
/**
|
||||
* @var float
|
||||
*/
|
||||
public $temps_theorique;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $skill_type;
|
||||
// END MODULEBUILDER PROPERTIES
|
||||
|
||||
|
|
@ -1003,6 +1030,7 @@ class Skill extends CommonObject
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefEvaluation $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -1027,10 +1055,10 @@ class Skill extends CommonObject
|
|||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
|
|||
|
|
@ -109,11 +109,29 @@ class Skilldet extends CommonObjectLine
|
|||
'fk_user_creat' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserAuthor', 'enabled' => 1, 'position' => 510, 'notnull' => 1, 'visible' => -2, 'foreignkey' => 'user.rowid',),
|
||||
'fk_user_modif' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserModif', 'enabled' => 1, 'position' => 511, 'notnull' => -1, 'visible' => 0,),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_skill;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rankorder;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $description;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
// END MODULEBUILDER PROPERTIES
|
||||
|
||||
|
|
@ -354,7 +372,7 @@ class Skilldet extends CommonObjectLine
|
|||
* @param string $filter Filter as an Universal Search string.
|
||||
* Example: '((client:=:1) OR ((client:>=:2) AND (client:<=:3))) AND (client:!=:8) AND (nom:like:'a%')'
|
||||
* @param string $filtermode No more used
|
||||
* @return array|int int <0 if KO, array of pages if OK
|
||||
* @return Skilldet[]|int int <0 if KO, array of pages if OK
|
||||
*/
|
||||
public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, $filter = '', $filtermode = 'AND')
|
||||
{
|
||||
|
|
@ -901,6 +919,7 @@ class Skilldet extends CommonObjectLine
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefEvaluation $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -925,10 +944,10 @@ class Skilldet extends CommonObjectLine
|
|||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
|
|||
|
|
@ -106,14 +106,38 @@ class SkillRank extends CommonObject
|
|||
'fk_user_modif' => array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserModif', 'enabled' => 1, 'position' => 511, 'notnull' => -1, 'visible' => -2,),
|
||||
'objecttype' => array('type' => 'varchar(128)', 'label' => 'objecttype', 'enabled' => 1, 'position' => 6, 'notnull' => 1, 'visible' => 0,),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_skill;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rank;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_object;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $objecttype;
|
||||
// END MODULEBUILDER PROPERTIES
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rankorder;
|
||||
|
||||
|
||||
|
|
@ -394,7 +418,7 @@ class SkillRank extends CommonObject
|
|||
* @param string $filter Filter as an Universal Search string.
|
||||
* Example: '((client:=:1) OR ((client:>=:2) AND (client:<=:3))) AND (client:!=:8) AND (nom:like:'a%')'
|
||||
* @param string $filtermode No more used
|
||||
* @return array|int int <0 if KO, array of pages if OK
|
||||
* @return SkillRank[]|int int <0 if KO, array of pages if OK
|
||||
*/
|
||||
public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, $filter = '', $filtermode = 'AND')
|
||||
{
|
||||
|
|
@ -966,6 +990,7 @@ class SkillRank extends CommonObject
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefEvaluation $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -990,10 +1015,10 @@ class SkillRank extends CommonObject
|
|||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
|
|||
|
|
@ -144,7 +144,7 @@ if (empty($reshook)) {
|
|||
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
@ -171,6 +171,7 @@ if (empty($reshook)) {
|
|||
// save evaldet lines to user;
|
||||
$sk = new SkillRank($db);
|
||||
$SkillrecordsForActiveUser = $sk->fetchAll('ASC', 'fk_skill', 0, 0, "(fk_object:=:".((int) $object->fk_user).") AND (objecttype:=:'".$db->escape(SkillRank::SKILLRANK_TYPE_USER)."')", 'AND');
|
||||
'@phan-var-force SkillRank[] $SkillrecordsForActiveUser';
|
||||
|
||||
$errors = 0;
|
||||
// we go through the evaldets of the eval
|
||||
|
|
@ -182,7 +183,7 @@ if (empty($reshook)) {
|
|||
|
||||
if ($resCreate <= 0) {
|
||||
$errors++;
|
||||
setEventMessage($langs->trans('ErrorCreateUserSkill'), $line->fk_skill);
|
||||
setEventMessage($langs->trans('ErrorCreateUserSkill', $line->fk_skill));
|
||||
}
|
||||
} else {
|
||||
//check if the skill is present to use it
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
* Copyright (C) 2021 Greg Rastklan <greg.rastklan@atm-consulting.fr>
|
||||
* Copyright (C) 2021 Jean-Pascal BOUDET <jean-pascal.boudet@atm-consulting.fr>
|
||||
* Copyright (C) 2021 Grégory BLEMAND <gregory.blemand@atm-consulting.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -142,7 +143,7 @@ if (empty($reshook)) {
|
|||
include DOL_DOCUMENT_ROOT . '/core/actions_builddoc.inc.php';
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
@ -375,7 +376,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||
$linkback = '<a href="' . dol_buildpath('/hrm/job_list.php', 1) . '?restore_lastsearch_values=1' . (!empty($socid) ? '&socid=' . $socid : '') . '">' . $langs->trans("BackToList") . '</a>';
|
||||
|
||||
$morehtmlref = '<div class="refid">';
|
||||
$morehtmlref.= $object->label;
|
||||
$morehtmlref .= $object->label;
|
||||
$morehtmlref .= '</div>';
|
||||
|
||||
|
||||
|
|
@ -391,7 +392,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||
//$keyforbreak='fieldkeytoswitchonsecondcolumn'; // We change column just before this field
|
||||
//unset($object->fields['fk_project']); // Hide field already shown in banner
|
||||
//unset($object->fields['fk_soc']); // Hide field already shown in banner
|
||||
$object->fields['label']['visible']=0; // Already in banner
|
||||
$object->fields['label']['visible'] = 0; // Already in banner
|
||||
include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_view.tpl.php';
|
||||
|
||||
// Other attributes. Fields from hook formObjectOptions and Extrafields.
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
* Copyright (C) 2021 Greg Rastklan <greg.rastklan@atm-consulting.fr>
|
||||
* Copyright (C) 2021 Jean-Pascal BOUDET <jean-pascal.boudet@atm-consulting.fr>
|
||||
* Copyright (C) 2021 Grégory BLEMAND <gregory.blemand@atm-consulting.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -164,7 +165,7 @@ if (empty($reshook)) {
|
|||
include DOL_DOCUMENT_ROOT . '/core/actions_builddoc.inc.php';
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
@ -308,8 +309,8 @@ function displayPositionCard(&$object)
|
|||
//$keyforbreak='fieldkeytoswitchonsecondcolumn'; // We change column just before this field
|
||||
//unset($object->fields['fk_project']); // Hide field already shown in banner
|
||||
//unset($object->fields['fk_soc']); // Hide field already shown in banner
|
||||
$object->fields['fk_user']['visible']=0; // Already in banner
|
||||
$object->fields['fk_job']['visible']=0; // Already in banner
|
||||
$object->fields['fk_user']['visible'] = 0; // Already in banner
|
||||
$object->fields['fk_job']['visible'] = 0; // Already in banner
|
||||
include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_view.tpl.php';
|
||||
|
||||
// Other attributes. Fields from hook formObjectOptions and Extrafields.
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
* Copyright (C) 2021 Jean-Pascal BOUDET <jean-pascal.boudet@atm-consulting.fr>
|
||||
* Copyright (C) 2021 Grégory BLEMAND <gregory.blemand@atm-consulting.fr>
|
||||
* Copyright (C) 2023-2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -139,6 +140,7 @@ if (empty($reshook)) {
|
|||
if (is_array($skilldetArray) && count($skilldetArray) > 0) {
|
||||
if ($action == 'add' && $permissiontoadd) {
|
||||
$arraySkill = $object->fetchLines();
|
||||
'@phan-var-force Skilldet[] $arraySkill';
|
||||
$index = 0;
|
||||
foreach ($arraySkill as $skilldet) {
|
||||
if (isset($skilldetArray[$index])) {
|
||||
|
|
@ -184,7 +186,7 @@ if (empty($reshook)) {
|
|||
include DOL_DOCUMENT_ROOT . '/core/actions_builddoc.inc.php';
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
@ -306,6 +308,7 @@ if (($id || $ref) && $action == 'edit') {
|
|||
|
||||
// SKILLDET
|
||||
$SkilldetRecords = $object->fetchLines();
|
||||
'@phan-var-force Skilldet[] $SkilldetRecords';
|
||||
|
||||
if (is_array($SkilldetRecords) && count($SkilldetRecords) == 0) {
|
||||
$object->createSkills(1);
|
||||
|
|
@ -364,7 +367,7 @@ if (($id || $ref) && $action == 'edit') {
|
|||
if (empty($skilldetArray)) {
|
||||
$value = GETPOSTISSET($key) ? GETPOST($key, $check) : $sk->$key;
|
||||
} else {
|
||||
$value=$skilldetArray[$sk->id];
|
||||
$value = $skilldetArray[$sk->id];
|
||||
}
|
||||
//
|
||||
// } elseif ($val['type'] == 'price') {
|
||||
|
|
@ -457,7 +460,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||
|
||||
|
||||
$morehtmlref = '<div class="refid">';
|
||||
$morehtmlref.= $object->label;
|
||||
$morehtmlref .= $object->label;
|
||||
$morehtmlref .= '</div>';
|
||||
dol_banner_tab($object, 'id', $linkback, 1, 'rowid', 'rowid', $morehtmlref);
|
||||
|
||||
|
|
@ -467,7 +470,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||
print '<div class="underbanner clearboth"></div>';
|
||||
print '<table class="border centpercent tableforfield">' . "\n";
|
||||
|
||||
$object->fields['label']['visible']=0; // Already in banner
|
||||
$object->fields['label']['visible'] = 0; // Already in banner
|
||||
include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_view.tpl.php';
|
||||
|
||||
// Other attributes. Fields from hook formObjectOptions and Extrafields.
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@
|
|||
* Copyright (C) 2021 Grégory BLEMAND <gregory.blemand@atm-consulting.fr>
|
||||
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -143,11 +144,13 @@ if (empty($reshook)) {
|
|||
$error++;
|
||||
}
|
||||
if (!$error) {
|
||||
$ret = -1;
|
||||
foreach ($TSkillsToAdd as $k => $v) {
|
||||
$skillAdded = new SkillRank($db);
|
||||
$skillAdded->fk_skill = $v;
|
||||
$skillAdded->fk_object = $id;
|
||||
$skillAdded->objecttype = $objecttype;
|
||||
// TODO: ensure handling of $ret is ok, now only fails when last is KO.
|
||||
$ret = $skillAdded->create($user);
|
||||
if ($ret < 0) {
|
||||
setEventMessages($skillAdded->error, null, 'errors');
|
||||
|
|
@ -162,6 +165,7 @@ if (empty($reshook)) {
|
|||
if (!empty($TNote)) {
|
||||
foreach ($TNote as $skillId => $rank) {
|
||||
$TSkills = $skill->fetchAll('ASC', 't.rowid', 0, 0, '(fk_object:=:'.((int) $id).") AND (objecttype:=:'".$db->escape($objecttype)."') AND (fk_skill:=:".((int) $skillId).')');
|
||||
'@phan-var-force SkillRank[] $tSkills';
|
||||
if (is_array($TSkills) && !empty($TSkills)) {
|
||||
foreach ($TSkills as $tmpObj) {
|
||||
$tmpObj->rankorder = $rank;
|
||||
|
|
@ -196,6 +200,7 @@ $title = $langs->trans("RequiredSkills");
|
|||
$help_url = '';
|
||||
llxHeader('', $title, $help_url);
|
||||
|
||||
$listLink = '';
|
||||
// Part to show record
|
||||
if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'create'))) {
|
||||
$res = $object->fetch_optionals();
|
||||
|
|
@ -251,7 +256,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||
$morehtmlref .= '</div>';
|
||||
|
||||
dol_banner_tab($object, 'id', $linkback, 1, 'rowid', 'rowid', $morehtmlref);
|
||||
} else {
|
||||
} elseif ($listLink !== null) {
|
||||
$linkback = '<a href="' . $listLink . '?restore_lastsearch_values=1' . (!empty($socid) ? '&socid=' . $socid : '') . '">' . $langs->trans("BackToList") . '</a>';
|
||||
|
||||
$morehtmlref = '<a href="'.DOL_URL_ROOT.'/user/vcard.php?id='.$object->id.'&output=file&file='.urlencode(dol_sanitizeFileName($object->getFullName($langs).'.vcf')).'" class="refid" rel="noopener">';
|
||||
|
|
@ -479,7 +484,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||
$sqlEval = "SELECT rowid FROM ".MAIN_DB_PREFIX."hrm_evaluation as e";
|
||||
$sqlEval .= " WHERE e.fk_user = ".((int) $id);
|
||||
$rslt = $db->query($sqlEval);
|
||||
$numEval = $db->num_rows($sqlEval);
|
||||
$numEval = $db->num_rows($rslt);
|
||||
|
||||
$page = 0;
|
||||
print_barre_liste($langs->trans("Evaluations"), $page, $_SERVER["PHP_SELF"], '', '', '', '', $numEval, $numEval, $evaltmp->picto, 0);
|
||||
|
|
|
|||
|
|
@ -2415,7 +2415,7 @@ function show_elem($fieldssource, $pos, $key)
|
|||
if (($pos && $pos > count($fieldssource)) && (!isset($fieldssource[$pos]["imported"]))) { // No fields
|
||||
/*
|
||||
print '<tr style="height:'.$height.'" class="trimport oddevenimport">';
|
||||
print '<td class="nocellnopadding" width="16" style="font-weight: normal">';
|
||||
print '<td class="nocellnopadd" width="16" style="font-weight: normal">';
|
||||
print '</td>';
|
||||
print '<td style="font-weight: normal">';
|
||||
print $langs->trans("NoFields");
|
||||
|
|
@ -2424,7 +2424,7 @@ function show_elem($fieldssource, $pos, $key)
|
|||
*/
|
||||
} elseif ($key == 'none') { // Empty line
|
||||
print '<tr style="height:'.$height.'" class="trimport oddevenimport">';
|
||||
print '<td class="nocellnopadding" width="16" style="font-weight: normal">';
|
||||
print '<td class="nocellnopadd" width="16" style="font-weight: normal">';
|
||||
print ' ';
|
||||
print '</td>';
|
||||
print '<td style="font-weight: normal">';
|
||||
|
|
@ -2434,10 +2434,10 @@ function show_elem($fieldssource, $pos, $key)
|
|||
} else {
|
||||
// Print field of source file
|
||||
print '<tr style="height:'.$height.'" class="trimport oddevenimport">';
|
||||
print '<td class="nocellnopadding" width="16" style="font-weight: normal">';
|
||||
print '<td class="nocellnopadd" width="16" style="font-weight: normal">';
|
||||
// The image must have the class 'boxhandle' because it's value used in DOM draggable objects to define the area used to catch the full object
|
||||
//print img_picto($langs->trans("MoveField", $pos), 'grip_title', 'class="boxhandle" style="cursor:move;"');
|
||||
print img_picto($langs->trans("Column").' '.num2Alpha($pos - 1), 'file', 'class="pictofixedwith"');
|
||||
print img_picto($langs->trans("Column").' '.num2Alpha($pos - 1), 'file', 'class="pictofixedwidth"');
|
||||
print '</td>';
|
||||
if (isset($fieldssource[$pos]['imported']) && $fieldssource[$pos]['imported'] == false) {
|
||||
print '<td class="nowraponall boxtdunused" style="font-weight: normal">';
|
||||
|
|
|
|||
|
|
@ -234,6 +234,9 @@ if (!GETPOST('action', 'aZ09') || preg_match('/upgrade/i', GETPOST('action', 'aZ
|
|||
}
|
||||
$conf->global->MAIN_ENABLE_LOG_TO_HTML = 1;
|
||||
|
||||
$versiontoarray = array();
|
||||
$versionranarray = array();
|
||||
|
||||
if (!$error) {
|
||||
if (count($listofentities) > 1) {
|
||||
print '<tr><td colspan="4">*** '.$langs->trans("Entity").' '.$entity.'</td></tr>'."\n";
|
||||
|
|
@ -354,9 +357,9 @@ if (!GETPOST('action', 'aZ09') || preg_match('/upgrade/i', GETPOST('action', 'aZ
|
|||
// Script for 3.0
|
||||
$afterversionarray = explode('.', '2.9.9');
|
||||
$beforeversionarray = explode('.', '3.0.9');
|
||||
if (versioncompare($versiontoarray, $afterversionarray) >= 0 && versioncompare($versiontoarray, $beforeversionarray) <= 0) {
|
||||
// No particular code
|
||||
}
|
||||
//if (versioncompare($versiontoarray, $afterversionarray) >= 0 && versioncompare($versiontoarray, $beforeversionarray) <= 0) {
|
||||
// No particular code
|
||||
//}
|
||||
|
||||
// Script for 3.1
|
||||
$afterversionarray = explode('.', '3.0.9');
|
||||
|
|
@ -398,9 +401,9 @@ if (!GETPOST('action', 'aZ09') || preg_match('/upgrade/i', GETPOST('action', 'aZ
|
|||
// Scripts for 3.9
|
||||
$afterversionarray = explode('.', '3.7.9');
|
||||
$beforeversionarray = explode('.', '3.8.9');
|
||||
if (versioncompare($versiontoarray, $afterversionarray) >= 0 && versioncompare($versiontoarray, $beforeversionarray) <= 0) {
|
||||
// No particular code
|
||||
}
|
||||
//if (versioncompare($versiontoarray, $afterversionarray) >= 0 && versioncompare($versiontoarray, $beforeversionarray) <= 0) {
|
||||
// No particular code
|
||||
//}
|
||||
|
||||
// Scripts for 4.0
|
||||
$afterversionarray = explode('.', '3.9.9');
|
||||
|
|
@ -458,9 +461,9 @@ if (!GETPOST('action', 'aZ09') || preg_match('/upgrade/i', GETPOST('action', 'aZ
|
|||
// Scripts for 9.0
|
||||
$afterversionarray = explode('.', '8.0.9');
|
||||
$beforeversionarray = explode('.', '9.0.9');
|
||||
if (versioncompare($versiontoarray, $afterversionarray) >= 0 && versioncompare($versiontoarray, $beforeversionarray) <= 0) {
|
||||
//migrate_user_photospath();
|
||||
}
|
||||
//if (versioncompare($versiontoarray, $afterversionarray) >= 0 && versioncompare($versiontoarray, $beforeversionarray) <= 0) {
|
||||
//migrate_user_photospath();
|
||||
//}
|
||||
|
||||
// Scripts for 11.0
|
||||
$afterversionarray = explode('.', '10.0.9');
|
||||
|
|
@ -768,11 +771,12 @@ function migrate_paiements($db, $langs, $conf)
|
|||
$sql .= " WHERE p.fk_facture > 0";
|
||||
|
||||
$resql = $db->query($sql);
|
||||
$row = array();
|
||||
$num = 0;
|
||||
|
||||
dolibarr_install_syslog("upgrade2::migrate_paiements");
|
||||
if ($resql) {
|
||||
$i = 0;
|
||||
$row = array();
|
||||
$num = $db->num_rows($resql);
|
||||
|
||||
while ($i < $num) {
|
||||
|
|
@ -788,8 +792,8 @@ function migrate_paiements($db, $langs, $conf)
|
|||
|
||||
if ($num) {
|
||||
print $langs->trans('MigrationPaymentsNumberToUpdate', $num)."<br>\n";
|
||||
$res = 0;
|
||||
if ($db->begin()) {
|
||||
$res = 0;
|
||||
$num = count($row);
|
||||
for ($i = 0; $i < $num; $i++) {
|
||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."paiement_facture (fk_facture, fk_paiement, amount)";
|
||||
|
|
@ -805,7 +809,7 @@ function migrate_paiements($db, $langs, $conf)
|
|||
}
|
||||
}
|
||||
|
||||
if ($res == (2 * count($row))) {
|
||||
if (is_array($row) && $res == (2 * count($row))) {
|
||||
$db->commit();
|
||||
print $langs->trans('MigrationSuccessfullUpdate')."<br>";
|
||||
} else {
|
||||
|
|
@ -4199,9 +4203,9 @@ function migrate_delete_old_dir($db, $langs, $conf)
|
|||
* @param DoliDB $db Database handler
|
||||
* @param Translate $langs Object langs
|
||||
* @param Conf $conf Object conf
|
||||
* @param array $listofmodule List of modules, like array('MODULE_KEY_NAME'=>$reloadmode, ...)
|
||||
* @param int $force 1=Reload module even if not already loaded
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
* @param array<string,'noboxes'|'newboxdefonly'|'forceactivate'> $listofmodule List of modules, like array('MODULE_KEY_NAME'=>$reloadmode, ...)
|
||||
* @param int<0,1> $force 1=Reload module even if not already loaded
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
function migrate_reload_modules($db, $langs, $conf, $listofmodule = array(), $force = 0)
|
||||
{
|
||||
|
|
@ -4292,6 +4296,7 @@ function migrate_reload_modules($db, $langs, $conf, $listofmodule = array(), $fo
|
|||
if ($res) {
|
||||
$classname = 'mod'.$moduletoreloadshort;
|
||||
$mod = new $classname($db);
|
||||
'@phan-var-force DolibarrModules $mod';
|
||||
|
||||
//$mod->remove('noboxes');
|
||||
$mod->delete_menus(); // We must delete to be sure it is inserted with new values
|
||||
|
|
@ -4303,6 +4308,7 @@ function migrate_reload_modules($db, $langs, $conf, $listofmodule = array(), $fo
|
|||
if ($res) {
|
||||
$classname = 'mod'.$moduletoreloadshort;
|
||||
$mod = new $classname($db);
|
||||
'@phan-var-force DolibarrModules $mod';
|
||||
$mod->init($reloadmode);
|
||||
} else {
|
||||
dolibarr_install_syslog('Failed to include '.strtolower($moduletoreloadshort).'/core/modules/mod'.$moduletoreloadshort.'.class.php', LOG_ERR);
|
||||
|
|
|
|||
|
|
@ -109,14 +109,41 @@ class KnowledgeRecord extends CommonObject
|
|||
'answer' => array('type' => 'html', 'label' => 'Solution', 'enabled' => 1, 'position' => 600, 'notnull' => 0, 'visible' => 3, 'searchall' => 1, 'csslist' => 'tdoverflowmax300', 'copytoclipboard' => 1, 'tdcss' => 'titlefieldcreate nowraponall'),
|
||||
'status' => array('type' => 'integer', 'label' => 'Status', 'enabled' => 1, 'position' => 1000, 'notnull' => 1, 'visible' => 5, 'default' => '0', 'index' => 1, 'arrayofkeyval' => array('0' => 'Draft', '1' => 'Validated', '9' => 'Obsolete'),),
|
||||
);
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $rowid;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $ref;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $entity;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $last_main_doc;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_creat;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $fk_user_valid;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $import_key;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $model_pdf;
|
||||
|
||||
/**
|
||||
|
|
@ -128,8 +155,17 @@ class KnowledgeRecord extends CommonObject
|
|||
* @var string answer to question
|
||||
*/
|
||||
public $answer;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $url;
|
||||
/**
|
||||
* @var int
|
||||
*/
|
||||
public $status;
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $lang;
|
||||
// END MODULEBUILDER PROPERTIES
|
||||
|
||||
|
|
@ -361,9 +397,9 @@ class KnowledgeRecord extends CommonObject
|
|||
* @param string $sortfield Sort field
|
||||
* @param int $limit Limit
|
||||
* @param int $offset Offset
|
||||
* @param string|array $filter Filter USF.
|
||||
* @param string $filtermode Filter mode (AND or OR)
|
||||
* @return array|int int <0 if KO, array of pages if OK
|
||||
* @param string|array<string,string> $filter Filter USF.
|
||||
* @param 'AND'|'OR' $filtermode Filter mode (AND or OR)
|
||||
* @return self[]|int int <0 if KO, array of pages if OK
|
||||
*/
|
||||
public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, $filter = '', $filtermode = 'AND')
|
||||
{
|
||||
|
|
@ -968,7 +1004,7 @@ class KnowledgeRecord extends CommonObject
|
|||
/**
|
||||
* Create an array of lines
|
||||
*
|
||||
* @return array|int array of lines if OK, <0 if KO
|
||||
* @return KnowledgeRecordLine[]|int array of lines if OK, <0 if KO
|
||||
*/
|
||||
public function getLinesArray()
|
||||
{
|
||||
|
|
@ -1023,6 +1059,7 @@ class KnowledgeRecord extends CommonObject
|
|||
|
||||
if (class_exists($classname)) {
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefKnowledgeRecord $obj';
|
||||
$numref = $obj->getNextValue($this);
|
||||
|
||||
if ($numref != '' && $numref != '-1') {
|
||||
|
|
@ -1047,10 +1084,10 @@ class KnowledgeRecord extends CommonObject
|
|||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
|
|||
|
|
@ -37,6 +37,9 @@ class mod_knowledgerecord_standard extends ModeleNumRefKnowledgeRecord
|
|||
*/
|
||||
public $version = 'dolibarr'; // 'development', 'experimental', 'dolibarr'
|
||||
|
||||
/**
|
||||
* @var string
|
||||
*/
|
||||
public $prefix = 'KM';
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
<?php
|
||||
/* Copyright (C) 2017-2021 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -139,7 +140,7 @@ if (empty($reshook)) {
|
|||
include DOL_DOCUMENT_ROOT.'/core/actions_builddoc.inc.php';
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
@ -425,7 +426,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
|||
print '<table class="border centpercent tableforfield">'."\n";
|
||||
|
||||
// Common attributes
|
||||
$keyforbreak='fk_c_ticket_category'; // We change column just before this field
|
||||
$keyforbreak = 'fk_c_ticket_category'; // We change column just before this field
|
||||
//unset($object->fields['fk_project']); // Hide field already shown in banner
|
||||
//unset($object->fields['fk_soc']); // Hide field already shown in banner
|
||||
$object->fields['answer']['enabled'] = 0;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
<?php
|
||||
/* Copyright (C) 2021 SuperAdmin
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -24,7 +25,7 @@
|
|||
/**
|
||||
* Prepare admin pages header
|
||||
*
|
||||
* @return array
|
||||
* @return array<array{0:string,1:string,2:string}>
|
||||
*/
|
||||
function knowledgemanagementAdminPrepareHead()
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
<?php
|
||||
/* Copyright (C) 2021 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -25,7 +26,7 @@
|
|||
* Prepare array of tabs for KnowledgeRecord
|
||||
*
|
||||
* @param KnowledgeRecord $object KnowledgeRecord
|
||||
* @return array Array of tabs
|
||||
* @return array<array{0:string,1:string,2:string}> Array of tabs
|
||||
*/
|
||||
function knowledgerecordPrepareHead($object)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
* Copyright (C) 2015 Frederic France <frederic.france@free.fr>
|
||||
* Copyright (C) 2017 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2020 Maxime DEMAREST <maxime@indelog.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -242,7 +243,7 @@ if (empty($reshook)) {
|
|||
|
||||
if ($action == 'setlabel' && $permissiontoadd) {
|
||||
$object->fetch($id);
|
||||
$result = $object->setValueFrom('label', GETPOST('label'), '', '', 'text', '', $user, 'LOAN_MODIFY');
|
||||
$result = $object->setValueFrom('label', GETPOST('label'), '', null, 'text', '', $user, 'LOAN_MODIFY');
|
||||
if ($result < 0) {
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
/* Copyright (C) 2012-2013 Christophe Battarel <christophe.battarel@altairis.fr>
|
||||
* Copyright (C) 2014 Ferran Marcet <fmarcet@2byte.es>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -153,7 +154,7 @@ foreach ($TRes as $prod) {
|
|||
}
|
||||
|
||||
print '<tr><td class="titlefield">'.$langs->trans('ProductOrService').'</td>';
|
||||
print '<td class="maxwidthonsmartpone" colspan="4">';
|
||||
print '<td class="maxwidthonsmartphone" colspan="4">';
|
||||
print img_picto('', 'product').$form->multiselectarray('products', $TProducts, $TSelectedProducts, 0, 0, 'minwidth500');
|
||||
print '</td></tr>';
|
||||
|
||||
|
|
|
|||
|
|
@ -266,7 +266,7 @@ class Mo extends CommonObject
|
|||
public $fk_parent_line;
|
||||
|
||||
/**
|
||||
* @var array<string,int|string> tpl
|
||||
@ var array{id:int,label:string,qty_bom:int|float,stock:float,seuil_stock_alerte:float,virtual_stock:float,qty:float,fk_unit:int,qty_frozen:float,disable_stock_change:int<0,1>,efficiency:float} tpl
|
||||
*/
|
||||
public $tpl = array();
|
||||
|
||||
|
|
@ -312,8 +312,8 @@ class Mo extends CommonObject
|
|||
/**
|
||||
* Create object into database
|
||||
*
|
||||
* @param User $user User that creates
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @param User $user User that creates
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <=0 if KO, Id of created object if OK
|
||||
*/
|
||||
public function create(User $user, $notrigger = 0)
|
||||
|
|
@ -512,7 +512,7 @@ class Mo extends CommonObject
|
|||
* @param int $offset Offset
|
||||
* @param string|array $filter Filter USF.
|
||||
* @param string $filtermode Filter mode (AND or OR)
|
||||
* @return array|int int <0 if KO, array of pages if OK
|
||||
* @return self[]|int int <0 if KO, array of pages if OK
|
||||
*/
|
||||
public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, $filter = '', $filtermode = 'AND')
|
||||
{
|
||||
|
|
@ -596,7 +596,7 @@ class Mo extends CommonObject
|
|||
*
|
||||
* @param string $role Get lines linked to current line with the selected role ('consumed', 'produced', ...)
|
||||
* @param int $lineid Id of production line to filter children
|
||||
* @return array Array of lines
|
||||
* @return array<array{rowid:int,date:int|string,qty:float,role:string,fk_product:int,fk_warehouse:int,batch:string,fk_stock_movement:int,fk_unit:int}> Array of lines
|
||||
*/
|
||||
public function fetchLinesLinked($role, $lineid = 0)
|
||||
{
|
||||
|
|
@ -681,9 +681,9 @@ class Mo extends CommonObject
|
|||
/**
|
||||
* Update object into database
|
||||
*
|
||||
* @param User $user User that modifies
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
* @param User $user User that modifies
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function update(User $user, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -715,9 +715,9 @@ class Mo extends CommonObject
|
|||
/**
|
||||
* Erase and update the line to consume and to produce.
|
||||
*
|
||||
* @param User $user User that modifies
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
* @param User $user User that modifies
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function createProduction(User $user, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -834,9 +834,9 @@ class Mo extends CommonObject
|
|||
/**
|
||||
* Update quantities in lines to consume and/or lines to produce.
|
||||
*
|
||||
* @param User $user User that modifies
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
* @param User $user User that modifies
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function updateProduction(User $user, $notrigger = 0)
|
||||
{
|
||||
|
|
@ -887,9 +887,9 @@ class Mo extends CommonObject
|
|||
/**
|
||||
* Delete object in database
|
||||
*
|
||||
* @param User $user User that deletes
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @param bool $also_cancel_consumed_and_produced_lines true if the consumed and produced lines will be deleted (and stocks incremented/decremented back) (false by default)
|
||||
* @param User $user User that deletes
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @param bool $also_cancel_consumed_and_produced_lines true if the consumed and produced lines will be deleted (and stocks incremented/decremented back) (false by default)
|
||||
* @return int Return integer <0 if KO, >0 if OK
|
||||
*/
|
||||
public function delete(User $user, $notrigger = 0, $also_cancel_consumed_and_produced_lines = false)
|
||||
|
|
@ -923,11 +923,11 @@ class Mo extends CommonObject
|
|||
/**
|
||||
* Delete a line of object in database
|
||||
*
|
||||
* @param User $user User that delete
|
||||
* @param int $idline Id of line to delete
|
||||
* @param int $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @param int $fk_movement Movement
|
||||
* @return int Return >0 if OK, <0 if KO
|
||||
* @param User $user User that delete
|
||||
* @param int $idline Id of line to delete
|
||||
* @param int<0,1> $notrigger 0=launch triggers after, 1=disable triggers
|
||||
* @param int $fk_movement Movement
|
||||
* @return int Return >0 if OK, <0 if KO
|
||||
*/
|
||||
public function deleteLine(User $user, $idline, $notrigger = 0, $fk_movement = 0)
|
||||
{
|
||||
|
|
@ -1061,6 +1061,7 @@ class Mo extends CommonObject
|
|||
}
|
||||
|
||||
$obj = new $classname();
|
||||
'@phan-var-force ModeleNumRefMos $obj';
|
||||
$numref = $obj->getNextValue($prod, $this);
|
||||
|
||||
if ($numref != "") {
|
||||
|
|
@ -1557,8 +1558,8 @@ class Mo extends CommonObject
|
|||
/**
|
||||
* Return the status
|
||||
*
|
||||
* @param int $status Id status
|
||||
* @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
|
||||
* @param int $status Id status
|
||||
* @param int<0,6> $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto
|
||||
* @return string Label of status
|
||||
*/
|
||||
public function LibStatut($status, $mode = 0)
|
||||
|
|
@ -1647,7 +1648,7 @@ class Mo extends CommonObject
|
|||
* Create an array of lines
|
||||
*
|
||||
* @param string $rolefilter string lines role filter
|
||||
* @return array|int array of lines if OK, <0 if KO
|
||||
* @return MoLine[]|int array of lines if OK, <0 if KO
|
||||
*/
|
||||
public function getLinesArray($rolefilter = '')
|
||||
{
|
||||
|
|
@ -1676,10 +1677,10 @@ class Mo extends CommonObject
|
|||
*
|
||||
* @param string $modele Force template to use ('' to not force)
|
||||
* @param Translate $outputlangs object lang a utiliser pour traduction
|
||||
* @param int $hidedetails Hide details of lines
|
||||
* @param int $hidedesc Hide description
|
||||
* @param int $hideref Hide ref
|
||||
* @param null|array $moreparams Array to provide more information
|
||||
* @param int<0,1> $hidedetails Hide details of lines
|
||||
* @param int<0,1> $hidedesc Hide description
|
||||
* @param int<0,1> $hideref Hide ref
|
||||
* @param ?array<string,mixed> $moreparams Array to provide more information
|
||||
* @return int 0 if KO, 1 if OK
|
||||
*/
|
||||
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null)
|
||||
|
|
@ -1714,8 +1715,8 @@ class Mo extends CommonObject
|
|||
* If lines are into a template, title must also be into a template
|
||||
* But for the moment we don't know if it's possible, so we keep the method available on overloaded objects.
|
||||
*
|
||||
* @param string $restrictlist ''=All lines, 'services'=Restrict to services only
|
||||
* @param array $selectedLines Array of lines id for selected lines
|
||||
* @param ''|'services' $restrictlist ''=All lines, 'services'=Restrict to services only
|
||||
* @param int[] $selectedLines Array of lines id for selected lines
|
||||
* @return void
|
||||
*/
|
||||
public function printOriginLinesList($restrictlist = '', $selectedLines = array())
|
||||
|
|
@ -1831,6 +1832,7 @@ class Mo extends CommonObject
|
|||
$this->tpl['disable_stock_change'] = $line->disable_stock_change;
|
||||
$this->tpl['efficiency'] = $line->efficiency;
|
||||
|
||||
|
||||
global $conf; // used into template
|
||||
$res = include DOL_DOCUMENT_ROOT.'/mrp/tpl/originproductline.tpl.php';
|
||||
}
|
||||
|
|
@ -1978,12 +1980,13 @@ class Mo extends CommonObject
|
|||
* Return clickable link of object (with eventually picto)
|
||||
*
|
||||
* @param string $option Where point the link (0=> main card, 1,2 => shipment, 'nolink'=>No link)
|
||||
* @param array{string,mixed} $arraydata Array of data
|
||||
* @param ?array{string,mixed} $arraydata Array of data
|
||||
* @return string HTML Code for Kanban thumb.
|
||||
*/
|
||||
public function getKanbanView($option = '', $arraydata = null)
|
||||
{
|
||||
global $langs;
|
||||
'@phan-var-force array{selected?:int<0,1>,bom?:Bom,product?:product} $arraydata';
|
||||
|
||||
$selected = (empty($arraydata['selected']) ? 0 : $arraydata['selected']);
|
||||
|
||||
|
|
|
|||
|
|
@ -274,9 +274,9 @@ class MoLine extends CommonObjectLine
|
|||
* @param string $sortfield Sort field
|
||||
* @param int $limit limit
|
||||
* @param int $offset Offset
|
||||
* @param string|array $filter Filter array. Example array('field'=>'valueforlike', 'customurl'=>...)
|
||||
* @param string|array<string,string> $filter Filter array. Example array('field'=>'valueforlike', 'customurl'=>...)
|
||||
* @param string $filtermode Filter mode (AND or OR)
|
||||
* @return array|int int <0 if KO, array of pages if OK
|
||||
* @return MoLine[]|int int <0 if KO, array of pages if OK
|
||||
*/
|
||||
public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, $filter = '', $filtermode = 'AND')
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
<?php
|
||||
/* Copyright (C) 2017-2020 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -270,7 +271,7 @@ if (empty($reshook)) {
|
|||
include DOL_DOCUMENT_ROOT.'/core/actions_builddoc.inc.php';
|
||||
|
||||
if ($action == 'set_thirdparty' && $permissiontoadd) {
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', '', 'date', '', $user, $triggermodname);
|
||||
$object->setValueFrom('fk_soc', GETPOSTINT('fk_soc'), '', null, 'date', '', $user, $triggermodname);
|
||||
}
|
||||
if ($action == 'classin' && $permissiontoadd) {
|
||||
$object->setProject(GETPOSTINT('projectid'));
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
/* Copyright (C) 2013-2015 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2014 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2018-2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -323,7 +324,7 @@ if ($object->fk_user_creat > 0) {
|
|||
print $userstatic->getLoginUrl(-1);
|
||||
} else {
|
||||
if ($action == 'edit') {
|
||||
print '<input type="text" name="nouvelleadresse" class="minwith200" value="'.$object->mail_admin.'">';
|
||||
print '<input type="text" name="nouvelleadresse" class="minwidth200" value="'.$object->mail_admin.'">';
|
||||
} else {
|
||||
print dol_print_email($object->mail_admin, 0, 0, 1, 0, 1, 1);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -497,7 +497,7 @@ print '</td></tr>';
|
|||
if (!$object->fk_user_creat) {
|
||||
print '<tr><td>'.$langs->trans("EMail").'</td><td>';
|
||||
if ($action == 'edit') {
|
||||
print '<input type="text" name="nouvelleadresse" class="minwith200" value="'.$object->mail_admin.'">';
|
||||
print '<input type="text" name="nouvelleadresse" class="minwidth200" value="'.$object->mail_admin.'">';
|
||||
} else {
|
||||
print dol_print_email($object->mail_admin, 0, 0, 1, 0, 1, 1);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -269,7 +269,7 @@ class Product extends CommonObject
|
|||
public $tva_tx;
|
||||
|
||||
/**
|
||||
* @var int French VAT NPR is used (0 or 1)
|
||||
* @var int<0,1> French VAT NPR is used (0 or 1)
|
||||
*/
|
||||
public $tva_npr = 0;
|
||||
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@inodbox.com>
|
||||
* Copyright (C) 2019 Nicolas ZABOURI <info@inovea-conseil.com>
|
||||
* Copyright (C) 2020 Tobias Sekan <tobias.sekan@startmail.com>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -68,7 +69,7 @@ if (getDolGlobalString('MAIN_SEARCH_FORM_ON_HOME_AREAS')) { // This may be u
|
|||
print '<table class="noborder nohover centpercent">';
|
||||
print "<tr class=\"liste_titre\">";
|
||||
print '<td colspan="3">'.$langs->trans("Search").'</td></tr>';
|
||||
print '<tr class="oddevene"><td>';
|
||||
print '<tr class="oddeven"><td>';
|
||||
print $langs->trans("Warehouse").':</td><td><input class="flat" type="text" size="18" name="sall"></td><td rowspan="2"><input type="submit" value="'.$langs->trans("Search").'" class="button"></td></tr>';
|
||||
print "</table></div></form><br>";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1081,7 +1081,7 @@ if ($resql) {
|
|||
}
|
||||
if (!empty($arrayfields['m.label']['checked'])) {
|
||||
// Label of movement
|
||||
print '<td class="tdoverflowmax100aaa">'.$objp->label.'</td>';
|
||||
print '<td class="tdoverflowmax100">'.$objp->label.'</td>';
|
||||
}
|
||||
if (!empty($arrayfields['m.type_mouvement']['checked'])) {
|
||||
// Type of movement
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@
|
|||
* Copyright (C) 2016 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2016 ATM Consulting <support@atm-consulting.fr>
|
||||
* Copyright (C) 2019-2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -410,7 +411,7 @@ if ($ext == 'csv') {
|
|||
print '<span class="fieldrequired">'.$langs->trans('Date').'</span> '.$form->selectDate(($date ? $date : -1), 'date');
|
||||
|
||||
print ' <span class="clearbothonsmartphone marginleftonly paddingleftonly marginrightonly paddingrightonly"> </span> ';
|
||||
print img_picto('', 'product', 'class="pictofiwedwidth"').' ';
|
||||
print img_picto('', 'product', 'class="pictofixedwidth"').' ';
|
||||
print '</span> ';
|
||||
print $form->select_produits($productid, 'productid', '', 0, 0, -1, 2, '', 0, array(), 0, $langs->trans('Product'), 0, 'maxwidth300', 0, '', null, 1);
|
||||
|
||||
|
|
|
|||
|
|
@ -531,7 +531,7 @@ if ($id > 0 || !empty($ref)) {
|
|||
|
||||
|
||||
print '<tr><td>'.$langs->trans("Budget").'</td>';
|
||||
print '<td><input class="with75" type="text" name="budget_amount" value="'.dol_escape_htmltag(GETPOSTISSET('budget_amount') ? GETPOST('budget_amount') : price2num($object->budget_amount)).'"></td>';
|
||||
print '<td><input class="width75" type="text" name="budget_amount" value="'.dol_escape_htmltag(GETPOSTISSET('budget_amount') ? GETPOST('budget_amount') : price2num($object->budget_amount)).'"></td>';
|
||||
print '</tr>';
|
||||
|
||||
// Other options
|
||||
|
|
|
|||
|
|
@ -124,7 +124,7 @@ class Dolresource extends CommonObject
|
|||
public $objelement;
|
||||
|
||||
/**
|
||||
* @var array Cache of type of resources. TODO Use $conf->cache['type_of_resources'] instead
|
||||
* @var array<int,array{code:string,label:string,active:int}> Cache of type of resources. TODO Use $conf->cache['type_of_resources'] instead
|
||||
*/
|
||||
public $cache_code_type_resource;
|
||||
|
||||
|
|
@ -602,7 +602,7 @@ class Dolresource extends CommonObject
|
|||
* @param string $sortfield Sort field
|
||||
* @param int $limit Limit page
|
||||
* @param int $offset Offset page
|
||||
* @param string|array $filter Filter USF.
|
||||
* @param string|array<string,mixed> $filter Filter USF.
|
||||
* @return int If KO: <0 || if OK number of lines loaded
|
||||
*/
|
||||
public function fetchAll(string $sortorder, string $sortfield, int $limit, int $offset, $filter = '')
|
||||
|
|
@ -793,7 +793,7 @@ class Dolresource extends CommonObject
|
|||
* @param string $element Element
|
||||
* @param int $element_id Id
|
||||
* @param string $resource_type Type
|
||||
* @return array Array of resources
|
||||
* @return array<array{rowid:int,resource_id:int,resource_type:string,busy:int<0,1>,mandatory:int<0,1>}> Array of resources
|
||||
*/
|
||||
public function getElementResources(string $element, int $element_id, string $resource_type = '')
|
||||
{
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
* Copyright (C) 2019 Josep Lluís Amador <joseplluis@lliuretic.cat>
|
||||
* Copyright (C) 2021-2024 Frédéric France <frederic.france@free.fr>
|
||||
* Copyright (C) 2023 William Mead <william.mead@manchenumerique.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -286,7 +287,7 @@ if (empty($reshook)) {
|
|||
}
|
||||
}
|
||||
|
||||
$parameters = array('resource_id'=>$resource_id);
|
||||
$parameters = array('resource_id' => $resource_id);
|
||||
$reshook = $hookmanager->executeHooks('getElementResources', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
|
||||
if ($reshook < 0) {
|
||||
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
||||
|
|
@ -331,6 +332,7 @@ if (!$ret) {
|
|||
|
||||
$act = fetchObjectByElement($element_id, $element, $element_ref);
|
||||
if (is_object($act)) {
|
||||
'@phan-var-force ActionComm $act';
|
||||
$head = actions_prepare_head($act);
|
||||
|
||||
print dol_get_fiche_head($head, 'resources', $langs->trans("Action"), -1, 'action');
|
||||
|
|
@ -459,7 +461,7 @@ if (!$ret) {
|
|||
$listofuserid = array();
|
||||
if (empty($donotclearsession)) {
|
||||
if ($act->userownerid > 0) {
|
||||
$listofuserid[$act->userownerid] = array('id'=>$act->userownerid, 'transparency'=>$act->transparency); // Owner first
|
||||
$listofuserid[$act->userownerid] = array('id' => $act->userownerid, 'transparency' => $act->transparency); // Owner first
|
||||
}
|
||||
if (!empty($act->userassigned)) { // Now concat assigned users
|
||||
// Restore array with key with same value than param 'id'
|
||||
|
|
@ -502,6 +504,7 @@ if (!$ret) {
|
|||
if (($element_id || $element_ref) && $element == 'societe') {
|
||||
$socstatic = fetchObjectByElement($element_id, $element, $element_ref);
|
||||
if (is_object($socstatic)) {
|
||||
'@phan-var-force Societe $socstatic';
|
||||
$savobject = $object;
|
||||
$object = $socstatic;
|
||||
|
||||
|
|
@ -554,8 +557,8 @@ if (!$ret) {
|
|||
// Ref customer
|
||||
//$morehtmlref.=$form->editfieldkey("RefCustomer", 'ref_client', $fichinter->ref_client, $fichinter, $user->rights->ficheinter->creer, 'string', '', 0, 1);
|
||||
//$morehtmlref.=$form->editfieldval("RefCustomer", 'ref_client', $fichinter->ref_client, $fichinter, $user->rights->ficheinter->creer, 'string', '', null, null, '', 1);
|
||||
$morehtmlref.=$form->editfieldkey("RefCustomer", 'ref_client', $fichinter->ref_client, $fichinter, 0, 'string', '', 0, 1);
|
||||
$morehtmlref.=$form->editfieldval("RefCustomer", 'ref_client', $fichinter->ref_client, $fichinter, 0, 'string', '', null, null, '', 1);
|
||||
$morehtmlref .= $form->editfieldkey("RefCustomer", 'ref_client', $fichinter->ref_client, $fichinter, 0, 'string', '', 0, 1);
|
||||
$morehtmlref .= $form->editfieldval("RefCustomer", 'ref_client', $fichinter->ref_client, $fichinter, 0, 'string', '', null, null, '', 1);
|
||||
// Thirdparty
|
||||
$morehtmlref .= '<br>'.$fichinter->thirdparty->getNomUrl(1, 'customer');
|
||||
// Project
|
||||
|
|
@ -613,7 +616,7 @@ if (!$ret) {
|
|||
|
||||
|
||||
// hook for other elements linked
|
||||
$parameters = array('element'=>$element, 'element_id'=>$element_id, 'element_ref'=>$element_ref);
|
||||
$parameters = array('element' => $element, 'element_id' => $element_id, 'element_ref' => $element_ref);
|
||||
$reshook = $hookmanager->executeHooks('printElementTab', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
|
||||
if ($reshook < 0) {
|
||||
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors');
|
||||
|
|
|
|||
|
|
@ -804,7 +804,7 @@ if (empty($reshook)) {
|
|||
$line['fk_fournprice'] = $pf->product_fourn_price_id;
|
||||
$line['pa_ht'] = $pf->fourn_unitprice_with_discount;
|
||||
if (getDolGlobalString('PRODUCT_CHARGES') && $pf->fourn_charges > 0) {
|
||||
$line['pa_ht'] += $pf->fourn_charges / $pf->fourn_qty;
|
||||
$line['pa_ht'] += (float) $pf->fourn_charges / $pf->fourn_qty;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
<?php
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2022 Open-Dsi <support@open-dsi.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
* Copyright (C) 2024 Benjamin Falière <benjamin.faliere@altairis.fr>
|
||||
/* Copyright (C) 2016 Marcos García <marcosgdf@gmail.com>
|
||||
* Copyright (C) 2022 Open-Dsi <support@open-dsi.fr>
|
||||
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
|
||||
* Copyright (C) 2024 Benjamin Falière <benjamin.faliere@altairis.fr>
|
||||
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
|
|
@ -527,7 +527,7 @@ print '<table id="tableattributes" class="tagtable nobottomiftotal liste'.($more
|
|||
|
||||
// Fields title search
|
||||
// --------------------------------------------------------------------
|
||||
print '<tr class="liste_titre_filter">';
|
||||
print '<tr class="liste_titre_filter nodrag nodrop">';
|
||||
// Action column
|
||||
if (getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')) {
|
||||
print '<td class="liste_titre center maxwidthsearch">';
|
||||
|
|
@ -605,7 +605,7 @@ $totalarray['nbfield'] = 0;
|
|||
|
||||
// Fields title label
|
||||
// --------------------------------------------------------------------
|
||||
print '<tr class="liste_titre">';
|
||||
print '<tr class="liste_titre nodrag nodrop">';
|
||||
// Action column
|
||||
if (getDolGlobalString('MAIN_CHECKBOX_LEFT_COLUMN')) {
|
||||
print getTitleFieldOfList($selectedfields, 0, $_SERVER["PHP_SELF"], '', '', '', '', $sortfield, $sortorder, 'center maxwidthsearch ')."\n";
|
||||
|
|
|
|||
|
|
@ -482,6 +482,7 @@ class FormCardWebPortal
|
|||
}
|
||||
$html .= '<div><strong>';
|
||||
if ($object->element == 'member') {
|
||||
'@phan-var-force Adherent $object';
|
||||
if ($object->morphy == 'mor' && !empty($object->societe)) {
|
||||
$html .= dol_htmlentities($object->societe);
|
||||
$html .= (!empty($fullname) && $object->societe != $fullname) ? ' (' . dol_htmlentities($fullname) . $addgendertxt . ')' : '';
|
||||
|
|
|
|||
|
|
@ -136,7 +136,7 @@ class FormWebPortal extends Form
|
|||
* Note: Do not apply langs->trans function on returned content, content may be entity encoded twice.
|
||||
*
|
||||
* @param string $htmlname Name of html select area.
|
||||
* @param array $array Array like array(key => value) or array(key=>array('label'=>..., 'data-...'=>..., 'disabled'=>..., 'css'=>...))
|
||||
* @param array<string,mixed> $array Array like array(key => value) or array(key=>array('label'=>..., 'data-...'=>..., 'disabled'=>..., 'css'=>...))
|
||||
* @param string|string[] $id Preselected key or preselected keys for multiselect. Use 'ifone' to autoselect record if there is only one record.
|
||||
* @param int|string $show_empty 0 no empty value allowed, 1 or string to add an empty value into list (If 1: key is -1 and value is '' or ' ', If placeholder string: key is -1 and value is the string), <0 to add an empty value with key that is this value.
|
||||
* @param int $key_in_label 1 to show key into label with format "[key] value"
|
||||
|
|
@ -253,7 +253,7 @@ class FormWebPortal extends Form
|
|||
* @param string $filedir Full path to directory to scan
|
||||
* @param string $filter Filter filenames on this regex string (Example: '\.pdf$')
|
||||
* @param string $morecss Add more css to the download picto
|
||||
* @param int $allfiles 0=Only generated docs, 1=All files
|
||||
* @param int<0,1> $allfiles 0=Only generated docs, 1=All files
|
||||
* @return string Output string with HTML link of documents (might be empty string). This also fill the array ->infofiles
|
||||
*/
|
||||
public function getDocumentsLink($modulepart, $modulesubdir, $filedir, $filter = '', $morecss = '', $allfiles = 0)
|
||||
|
|
@ -458,7 +458,7 @@ class FormWebPortal extends Form
|
|||
* @param int $disabled 1=Html component is disabled
|
||||
* @param string $sortfield Sort field
|
||||
* @param string $filter Add more filter (Universal Search Filter)
|
||||
* @return string|array Return HTML string
|
||||
* @return string|array<array{key:int,value:string,label:string}> Return HTML string
|
||||
* @see selectForForms()
|
||||
*/
|
||||
public function selectForFormsList($objecttmp, $htmlname, $preselectedvalue, $showempty = '', $searchkey = '', $placeholder = '', $morecss = '', $moreparams = '', $forcecombo = 0, $outputmode = 0, $disabled = 0, $sortfield = '', $filter = '')
|
||||
|
|
@ -626,9 +626,9 @@ class FormWebPortal extends Form
|
|||
* Return HTML string to put an input field into a page
|
||||
* Code very similar with showInputField for common object
|
||||
*
|
||||
* @param array|null $val Array of properties for field to show
|
||||
* @param array{type:string,label:string,enabled:int|string,position:int,notnull?:int,visible:int,noteditable?:int,default?:string,index?:int,foreignkey?:string,searchall?:int,isameasure?:int,css?:string,csslist?:string,help?:string,showoncombobox?:int,disabled?:int,arrayofkeyval?:array<int,string>,comment?:string} $val Array of properties for field to show
|
||||
* @param string $key Key of attribute
|
||||
* @param string|array $value Preselected value to show (for date type it must be in timestamp format, for amount or price it must be a php numeric value, for array type must be array)
|
||||
* @param string|mixed[] $value Preselected value to show (for date type it must be in timestamp format, for amount or price it must be a php numeric value, for array type must be array)
|
||||
* @param string $moreparam To add more parameters on html input tag
|
||||
* @param string $keysuffix Prefix string to add into name and id of field (can be used to avoid duplicate names)
|
||||
* @param string $keyprefix Suffix string to add into name and id of field (can be used to avoid duplicate names)
|
||||
|
|
@ -944,7 +944,7 @@ class FormWebPortal extends Form
|
|||
require_once DOL_DOCUMENT_ROOT . '/categories/class/categorie.class.php';
|
||||
$categorytype = $InfoFieldList[5];
|
||||
if (is_numeric($categorytype)) {
|
||||
$categorytype = Categorie::$MAP_ID_TO_CODE[$categorytype]; // For backward compatibility
|
||||
$categorytype = Categorie::$MAP_ID_TO_CODE[(int) $categorytype]; // For backward compatibility
|
||||
}
|
||||
$data = $this->select_all_categories($categorytype, '', 'parent', 64, $InfoFieldList[6], 1, 1);
|
||||
$out .= '<option value="0"> </option>';
|
||||
|
|
@ -979,7 +979,7 @@ class FormWebPortal extends Form
|
|||
* Return HTML string to show a field into a page
|
||||
*
|
||||
* @param CommonObject $object Common object
|
||||
* @param array $val Array of properties of field to show
|
||||
* @param array{type:string,label:string,enabled:int<0,2>|string,position:int,notnull?:int,visible:int,noteditable?:int,default?:string,index?:int,foreignkey?:string,searchall?:int,isameasure?:int,css?:string,csslist?:string,help?:string,showoncombobox?:int,disabled?:int,arrayofkeyval?:array<int,string>,comment?:string} $val Array of properties of field to show
|
||||
* @param string $key Key of attribute
|
||||
* @param string|string[] $value Preselected value to show (for date type it must be in timestamp format, for amount or price it must be a php numeric value)
|
||||
* @param string $moreparam To add more parameters on html input tag
|
||||
|
|
@ -1103,10 +1103,16 @@ class FormWebPortal extends Form
|
|||
include_once DOL_DOCUMENT_ROOT . '/core/lib/date.lib.php';
|
||||
if (!is_null($value) && $value !== '') {
|
||||
$value = convertSecondToTime((int) $value, 'allhourmin');
|
||||
} else {
|
||||
// Resulting type must be string
|
||||
$value = '';
|
||||
}
|
||||
} elseif ($type == 'double' || $type == 'real') {
|
||||
if (!is_null($value) && $value !== '') {
|
||||
$value = price($value);
|
||||
} else {
|
||||
// Resulting type must be string
|
||||
$value = '';
|
||||
}
|
||||
} elseif ($type == 'boolean') {
|
||||
$checked = '';
|
||||
|
|
@ -1125,6 +1131,9 @@ class FormWebPortal extends Form
|
|||
} elseif ($type == 'price') {
|
||||
if (!is_null($value) && $value !== '') {
|
||||
$value = price($value, 0, $langs, 0, 0, -1, $conf->currency);
|
||||
} else {
|
||||
// Resulting type must be string
|
||||
$value = '';
|
||||
}
|
||||
} elseif ($type == 'select') {
|
||||
$value = isset($param['options'][$value]) ? $param['options'][$value] : '';
|
||||
|
|
@ -1219,7 +1228,7 @@ class FormWebPortal extends Form
|
|||
dol_syslog(__METHOD__ . ' error ' . $this->db->lasterror(), LOG_WARNING);
|
||||
}
|
||||
} elseif ($type == 'radio') {
|
||||
$value = $param['options'][$value];
|
||||
$value = (string) $param['options'][$value];
|
||||
} elseif ($type == 'checkbox') {
|
||||
$value_arr = explode(',', $value);
|
||||
$value = '';
|
||||
|
|
@ -1335,15 +1344,16 @@ class FormWebPortal extends Form
|
|||
dol_include_once($InfoFieldList[1]);
|
||||
if ($classname && class_exists($classname)) {
|
||||
$object = new $classname($this->db);
|
||||
'@phan-var-force CommonObject $object';
|
||||
$result = $object->fetch($value);
|
||||
$value = '';
|
||||
if ($result > 0) {
|
||||
if (property_exists($object, 'label')) {
|
||||
$value = $object->label;
|
||||
$value = $object->label; // @phan-suppress-current-line PhanUndeclaredProperty
|
||||
} elseif (property_exists($object, 'libelle')) {
|
||||
$value = $object->libelle;
|
||||
$value = $object->libelle; // @phan-suppress-current-line PhanUndeclaredProperty
|
||||
} elseif (property_exists($object, 'nom')) {
|
||||
$value = $object->nom;
|
||||
$value = $object->nom; // @phan-suppress-current-line PhanUndeclaredProperty
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -99,7 +99,6 @@ parameters:
|
|||
- '# getCommonSubstitutionArray expects array#'
|
||||
- '# ldap_search expects array\|LDAP#'
|
||||
- '# ajax_combobox expects array#'
|
||||
- '# Context::setError\(\) expects array, string#'
|
||||
- '# FormWebPortal::selectForForms\(\) expects int, array#'
|
||||
- '# Lettering::getBankLinesFromFkDocAndDocType\(\) expects array#'
|
||||
- '# (Odf) constructor expects #'
|
||||
|
|
@ -112,8 +111,7 @@ parameters:
|
|||
- '# (?:pdf_(?:(?:eagle_proforma::drawTotalTable|muscadet::_tableau_tot)\(\))) expects Facture#'
|
||||
- '# (?:salaries_prepare_head) expects Paiement#'
|
||||
- '# (?:pg_(?:affected_rows|f(?:etch_(?:array|object|row)|ree_result)|num_rows)) expects PgSql\\Result#'
|
||||
- '# (?:Holiday::getNextNumRef\(\)|get_localtax|pdf_pagefoot) expects Societe#'
|
||||
- '# (?:get_next_value) expects ..\|Societe#'
|
||||
- '# (?:Holiday::getNextNumRef\(\)|get_localtax|pdf_pagefoot|societe_prepare_head) expects Societe#'
|
||||
- '# (?:Common(?:DocGenerator::get(?:(?:ExtrafieldsInHtml|_substitutionarray_lines)\(\))|Object::printO(?:(?:bject|rigin)Line\(\)))) expects CommonObjectLine#'
|
||||
- '#colorHexToHsl expects float\|false, true#'
|
||||
internalErrorsCountLimit: 50
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user