Merge branch 'dev' into feature/yj-layoutSetup
This commit is contained in:
commit
c0cbcd18a2
@ -504,6 +504,7 @@ export default function Estimate({}) {
|
|||||||
saleStoreId: estimateContextState.sapSaleStoreId,
|
saleStoreId: estimateContextState.sapSaleStoreId,
|
||||||
sapSalesStoreCd: estimateContextState.sapSalesStoreCd,
|
sapSalesStoreCd: estimateContextState.sapSalesStoreCd,
|
||||||
docTpCd: estimateContextState.estimateType,
|
docTpCd: estimateContextState.estimateType,
|
||||||
|
secSapSalesStoreCd:(estimateContextState.secSapSalesStoreCd?.length > 0 && showPriceCd === 'QSP_PRICE')? estimateContextState.secSapSalesStoreCd :'',
|
||||||
priceCd: showPriceCd,
|
priceCd: showPriceCd,
|
||||||
itemIdList: estimateContextState.itemList.filter((item) => item.delFlg === '0' && item.paDispOrder === null),
|
itemIdList: estimateContextState.itemList.filter((item) => item.delFlg === '0' && item.paDispOrder === null),
|
||||||
}
|
}
|
||||||
@ -1216,6 +1217,23 @@ export default function Estimate({}) {
|
|||||||
}
|
}
|
||||||
}, [estimateContextState?.itemList, cableItemList])
|
}, [estimateContextState?.itemList, cableItemList])
|
||||||
|
|
||||||
|
const [agencyCustList, setAgencyCustList] = useState([])
|
||||||
|
useEffect(() => {
|
||||||
|
// 952 - 2차점 특가 sapSalesStoreCd
|
||||||
|
if(estimateContextState?.sapSalesStoreCd && session?.storeLvl === '1') {
|
||||||
|
const param = {
|
||||||
|
sapSalesStoreCd: estimateContextState.sapSalesStoreCd,
|
||||||
|
}
|
||||||
|
const apiUrl = `api/estimate/agency-cust-list?${queryStringFormatter(param)}`
|
||||||
|
get({ url: apiUrl }).then((res) => {
|
||||||
|
if (isNotEmptyArray(res?.data)) {
|
||||||
|
setAgencyCustList(res?.data);
|
||||||
|
}
|
||||||
|
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
}, [estimateContextState?.sapSalesStoreCd])
|
||||||
return (
|
return (
|
||||||
<div className="sub-content estimate">
|
<div className="sub-content estimate">
|
||||||
<div className="sub-content-inner">
|
<div className="sub-content-inner">
|
||||||
@ -1360,41 +1378,72 @@ export default function Estimate({}) {
|
|||||||
{getMessage('estimate.detail.estimateType')} <span className="important">*</span>
|
{getMessage('estimate.detail.estimateType')} <span className="important">*</span>
|
||||||
</th>
|
</th>
|
||||||
<td colSpan={3}>
|
<td colSpan={3}>
|
||||||
<div className="radio-wrap">
|
<div className="form-flex-wrap">
|
||||||
{/*pkgRank is null, empty 인 경우 : 사용불가, 이전에 등록된 경우 사용가능, style로 제어*/}
|
<div className="radio-wrap">
|
||||||
<div className="d-check-radio light mr10" style={{display:
|
{/*pkgRank is null, empty 인 경우 : 사용불가, 이전에 등록된 경우 사용가능, style로 제어*/}
|
||||||
(isNotEmptyArray(storePriceList) > 0
|
<div className="d-check-radio light mr10" style={{display:
|
||||||
&& storePriceList[0].pkgRank !== null
|
(isNotEmptyArray(storePriceList) > 0
|
||||||
&& storePriceList[0].pkgRank !== ''
|
&& storePriceList[0].pkgRank !== null
|
||||||
|| estimateContextState?.estimateType === 'YJSS') ? "" : "none"}}>
|
&& storePriceList[0].pkgRank !== ''
|
||||||
<input
|
|| estimateContextState?.estimateType === 'YJSS') ? "" : "none"}}>
|
||||||
type="radio"
|
<input
|
||||||
name="estimateType"
|
type="radio"
|
||||||
id="YJSS"
|
name="estimateType"
|
||||||
value={'YJSS'}
|
id="YJSS"
|
||||||
checked={estimateContextState?.estimateType === 'YJSS' ? true : false}
|
value={'YJSS'}
|
||||||
onChange={(e) => {
|
checked={estimateContextState?.estimateType === 'YJSS' ? true : false}
|
||||||
//주문분류
|
onChange={(e) => {
|
||||||
setHandlePricingFlag(true)
|
//주문분류
|
||||||
setEstimateContextState({ estimateType: e.target.value })
|
setHandlePricingFlag(true)
|
||||||
}}
|
setEstimateContextState({ estimateType: e.target.value })
|
||||||
/>
|
}}
|
||||||
<label htmlFor="YJSS">{getMessage('estimate.detail.estimateType.yjss')}</label>
|
/>
|
||||||
|
<label htmlFor="YJSS">{getMessage('estimate.detail.estimateType.yjss')}</label>
|
||||||
|
</div>
|
||||||
|
<div className="d-check-radio light">
|
||||||
|
<input
|
||||||
|
type="radio"
|
||||||
|
name="estimateType"
|
||||||
|
id="YJOD"
|
||||||
|
value={'YJOD'}
|
||||||
|
checked={estimateContextState?.estimateType === 'YJOD' ? true : false}
|
||||||
|
onChange={(e) => {
|
||||||
|
setHandlePricingFlag(true)
|
||||||
|
setEstimateContextState({ estimateType: e.target.value })
|
||||||
|
}}
|
||||||
|
/>
|
||||||
|
<label htmlFor="YJOD">{getMessage('estimate.detail.estimateType.yjod')}</label>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="d-check-radio light">
|
{ (session?.storeLvl === '1' && agencyCustList.length > 0 )? (
|
||||||
<input
|
<div className="form-flex-select ml10">
|
||||||
type="radio"
|
<label htmlFor="">{getMessage('estimate.detail.agency')}</label>
|
||||||
name="estimateType"
|
<div className="select-wrap" style={{ width: '400px' }}>
|
||||||
id="YJOD"
|
<Select
|
||||||
value={'YJOD'}
|
id="agencyName"
|
||||||
checked={estimateContextState?.estimateType === 'YJOD' ? true : false}
|
instanceId="agencyName"
|
||||||
|
className="react-select-custom"
|
||||||
|
classNamePrefix="custom"
|
||||||
|
placeholder="Select"
|
||||||
|
options={agencyCustList}
|
||||||
onChange={(e) => {
|
onChange={(e) => {
|
||||||
setHandlePricingFlag(true)
|
if (isObjectNotEmpty(e)) {
|
||||||
setEstimateContextState({ estimateType: e.target.value })
|
setEstimateContextState({ secSapSalesStoreCd: e.sapSalesStoreCd })
|
||||||
|
} else {
|
||||||
|
setEstimateContextState({ secSapSalesStoreCd: '' })
|
||||||
|
}
|
||||||
}}
|
}}
|
||||||
|
getOptionLabel={(x) => x.sapSalesStoreNm}
|
||||||
|
getOptionValue={(x) => x.sapSalesStoreCd}
|
||||||
|
isClearable={true}
|
||||||
|
isSearchable={true}
|
||||||
|
value={agencyCustList.filter(function (option) {
|
||||||
|
return option.sapSalesStoreCd === estimateContextState.secSapSalesStoreCd
|
||||||
|
})}
|
||||||
/>
|
/>
|
||||||
<label htmlFor="YJOD">{getMessage('estimate.detail.estimateType.yjod')}</label>
|
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
) : ('')}
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|||||||
@ -905,6 +905,7 @@
|
|||||||
"estimate.detail.estimateType": "注文分類",
|
"estimate.detail.estimateType": "注文分類",
|
||||||
"estimate.detail.estimateType.yjss": "住宅PKG",
|
"estimate.detail.estimateType.yjss": "住宅PKG",
|
||||||
"estimate.detail.estimateType.yjod": "積上げ(YJOD)",
|
"estimate.detail.estimateType.yjod": "積上げ(YJOD)",
|
||||||
|
"estimate.detail.agency": "2次店名",
|
||||||
"estimate.detail.roofCns": "屋根材・施工区分",
|
"estimate.detail.roofCns": "屋根材・施工区分",
|
||||||
"estimate.detail.remarks": "備考",
|
"estimate.detail.remarks": "備考",
|
||||||
"estimate.detail.fileFlg": "後日資料提出",
|
"estimate.detail.fileFlg": "後日資料提出",
|
||||||
|
|||||||
@ -906,6 +906,7 @@
|
|||||||
"estimate.detail.estimateType": "주문분류",
|
"estimate.detail.estimateType": "주문분류",
|
||||||
"estimate.detail.estimateType.yjss": "住宅PKG",
|
"estimate.detail.estimateType.yjss": "住宅PKG",
|
||||||
"estimate.detail.estimateType.yjod": "積上げ( YJOD )",
|
"estimate.detail.estimateType.yjod": "積上げ( YJOD )",
|
||||||
|
"estimate.detail.agency": "2차점명",
|
||||||
"estimate.detail.roofCns": "지붕재・사양시공",
|
"estimate.detail.roofCns": "지붕재・사양시공",
|
||||||
"estimate.detail.remarks": "비고",
|
"estimate.detail.remarks": "비고",
|
||||||
"estimate.detail.fileFlg": "후일자료제출",
|
"estimate.detail.fileFlg": "후일자료제출",
|
||||||
|
|||||||
@ -47,6 +47,16 @@ table{
|
|||||||
}
|
}
|
||||||
.form-flex-wrap{
|
.form-flex-wrap{
|
||||||
@include flexbox;
|
@include flexbox;
|
||||||
|
.form-flex-select{
|
||||||
|
@include flexbox;
|
||||||
|
label{
|
||||||
|
flex: none;
|
||||||
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
.form-select{
|
||||||
|
min-width: 300px;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.date-picker-wrap{
|
.date-picker-wrap{
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user