Merge pull request '[1423] 2차 user 판매점 select 항상 enable + 設計依頼 매핑 실패 시 본인 초기화' (#858) from dev into dev-deploy

Reviewed-on: #858
This commit is contained in:
ysCha 2026-05-15 11:10:13 +09:00
commit cbcf70d034

View File

@ -1036,6 +1036,18 @@ export default function StuffDetail() {
form.setValue('saleStoreName', info.saleStoreName) form.setValue('saleStoreName', info.saleStoreName)
form.setValue('saleStoreLevel', info.saleStoreLevel) form.setValue('saleStoreLevel', info.saleStoreLevel)
} else { } else {
// [PLANREQ-MATCH 2026-05-15] 2 user: planReqNo + store 2 select disable
if (session?.storeLvl === '2') {
const matched = otherSaleStoreList.some((o) => o.saleStoreId === info.saleStoreId)
if (!matched) {
form.setValue('planReqNo', '')
setOtherSelOptions(session?.storeId)
form.setValue('otherSaleStoreId', session?.storeId)
form.setValue('otherSaleStoreName', '')
form.setValue('otherSaleStoreLevel', session?.storeLvl)
return
}
}
setOtherSelOptions(info.saleStoreId) setOtherSelOptions(info.saleStoreId)
form.setValue('otherSaleStoreId', info.saleStoreId) form.setValue('otherSaleStoreId', info.saleStoreId)
form.setValue('otherSaleStoreName', info.saleStoreName) form.setValue('otherSaleStoreName', info.saleStoreName)
@ -2034,12 +2046,11 @@ export default function StuffDetail() {
getOptionLabel={(x) => x.saleStoreName} getOptionLabel={(x) => x.saleStoreName}
getOptionValue={(x) => x.saleStoreId} getOptionValue={(x) => x.saleStoreId}
isDisabled={ isDisabled={
// [PLANREQ-MATCH 2026-05-15] 2 user store enable
session?.storeLvl === '1' session?.storeLvl === '1'
? otherSaleStoreList.length > 0 ? otherSaleStoreList.length > 0
? false ? false
: true : true
: otherSaleStoreList.length === 1
? true
: false : false
} }
isClearable={true} isClearable={true}
@ -2633,14 +2644,13 @@ export default function StuffDetail() {
getOptionLabel={(x) => x.saleStoreName} getOptionLabel={(x) => x.saleStoreName}
getOptionValue={(x) => x.saleStoreId} getOptionValue={(x) => x.saleStoreId}
isDisabled={ isDisabled={
// [PLANREQ-MATCH 2026-05-15] 2 user store enable (tempFlg='0' )
managementState?.tempFlg === '0' managementState?.tempFlg === '0'
? true ? true
: session?.storeLvl === '1' : session?.storeLvl === '1'
? otherSaleStoreList.length > 0 ? otherSaleStoreList.length > 0
? false ? false
: true : true
: otherSaleStoreList.length === 1
? true
: false : false
} }
isClearable={managementState?.tempFlg === '0' ? false : true} isClearable={managementState?.tempFlg === '0' ? false : true}