Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -3456,6 +3456,11 @@ export const useOrderEntryStore = defineStore('orderentry', {
|
|||||||
const headerId = this.header?.OrderHeaderID || crypto.randomUUID()
|
const headerId = this.header?.OrderHeaderID || crypto.randomUUID()
|
||||||
const docCurrency = safeStr(this.header?.DocCurrencyCode) || 'TRY'
|
const docCurrency = safeStr(this.header?.DocCurrencyCode) || 'TRY'
|
||||||
const exRate = toNum(this.header?.ExchangeRate) || 1
|
const exRate = toNum(this.header?.ExchangeRate) || 1
|
||||||
|
const boolOr = (value, fallback) => {
|
||||||
|
if (typeof value === 'boolean') return value
|
||||||
|
if (value && typeof value === 'object' && typeof value.Bool === 'boolean') return value.Bool
|
||||||
|
return fallback
|
||||||
|
}
|
||||||
|
|
||||||
const avgDueSource =
|
const avgDueSource =
|
||||||
this.header?.AverageDueDate ||
|
this.header?.AverageDueDate ||
|
||||||
@@ -3472,6 +3477,18 @@ export const useOrderEntryStore = defineStore('orderentry', {
|
|||||||
DocCurrencyCode: docCurrency,
|
DocCurrencyCode: docCurrency,
|
||||||
LocalCurrencyCode: safeStr(this.header?.LocalCurrencyCode) || 'TRY',
|
LocalCurrencyCode: safeStr(this.header?.LocalCurrencyCode) || 'TRY',
|
||||||
ExchangeRate: exRate,
|
ExchangeRate: exRate,
|
||||||
|
IsCancelOrder: boolOr(this.header?.IsCancelOrder, false),
|
||||||
|
IsInclutedVat: boolOr(this.header?.IsInclutedVat, false),
|
||||||
|
IsCreditSale: boolOr(this.header?.IsCreditSale, true),
|
||||||
|
IsCreditableConfirmed: boolOr(this.header?.IsCreditableConfirmed, false),
|
||||||
|
IsSalesViaInternet: boolOr(this.header?.IsSalesViaInternet, false),
|
||||||
|
IsSuspended: boolOr(this.header?.IsSuspended, false),
|
||||||
|
IsCompleted: boolOr(this.header?.IsCompleted, true),
|
||||||
|
IsPrinted: boolOr(this.header?.IsPrinted, false),
|
||||||
|
IsLocked: boolOr(this.header?.IsLocked, false),
|
||||||
|
UserLocked: boolOr(this.header?.UserLocked, false),
|
||||||
|
IsClosed: boolOr(this.header?.IsClosed, false),
|
||||||
|
IsProposalBased: boolOr(this.header?.IsProposalBased, false),
|
||||||
|
|
||||||
CreatedUserName:
|
CreatedUserName:
|
||||||
this.mode === 'edit'
|
this.mode === 'edit'
|
||||||
|
|||||||
Reference in New Issue
Block a user