Merge branch 'dev' of ssh://git.jetbrains.space/nalpari/q-cast-iii/qcast-front into dev

This commit is contained in:
김민식 2025-02-28 16:54:11 +09:00
commit 951a75d72a

View File

@ -437,7 +437,12 @@ export const useEstimateController = (planNo, flag) => {
type: 'alert',
icon: 'warning',
})
} else {
if (checkLength(copyReceiveUser.trim()) > 10) {
return swalFire({ text: getMessage('stuff.detail.tempSave.message2'), type: 'alert', icon: 'warning' })
}
}
const params = {
saleStoreId: session.storeId,
sapSalesStoreCd: session.custCd,
@ -469,6 +474,22 @@ export const useEstimateController = (planNo, flag) => {
})
}
const checkLength = (value) => {
let str = new String(value)
let _byte = 0
if (str.length !== 0) {
for (let i = 0; i < str.length; i++) {
let str2 = str.charAt(i)
if (encodeURIComponent(str2).length > 4) {
_byte += 2
} else {
_byte++
}
}
}
return _byte
}
return {
estimateContextState,
setEstimateContextState,