물건정보 & 설계의뢰
This commit is contained in:
parent
451f742b0f
commit
32485efb93
@ -132,7 +132,7 @@ export default function Header(props) {
|
|||||||
onMouseLeave={(e) => ToggleonMouse(e, 'remove', 'nav > ul')}
|
onMouseLeave={(e) => ToggleonMouse(e, 'remove', 'nav > ul')}
|
||||||
>
|
>
|
||||||
{menu.children.length === 0 ? (
|
{menu.children.length === 0 ? (
|
||||||
<Link key={`${menu.id}`} href={menu.url}>
|
<Link key={`${menu.id}`} href={menu.url} scroll={false}>
|
||||||
{getMessage(menu.name)}
|
{getMessage(menu.name)}
|
||||||
</Link>
|
</Link>
|
||||||
) : (
|
) : (
|
||||||
@ -147,7 +147,9 @@ export default function Header(props) {
|
|||||||
onMouseEnter={(e) => ToggleonMouse(e, 'add', 'li > ul')}
|
onMouseEnter={(e) => ToggleonMouse(e, 'add', 'li > ul')}
|
||||||
onMouseLeave={(e) => ToggleonMouse(e, 'remove', 'li > ul')}
|
onMouseLeave={(e) => ToggleonMouse(e, 'remove', 'li > ul')}
|
||||||
>
|
>
|
||||||
<Link href={m.url}>{getMessage(m.name)}</Link>
|
<Link href={m.url} scroll={false}>
|
||||||
|
{getMessage(m.name)}
|
||||||
|
</Link>
|
||||||
</li>
|
</li>
|
||||||
)
|
)
|
||||||
})}
|
})}
|
||||||
|
|||||||
@ -79,7 +79,7 @@ export default function StuffDetail() {
|
|||||||
const [detailData, setDetailData] = useState({})
|
const [detailData, setDetailData] = useState({})
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
console.log('objectNo::', objectNo)
|
// console.log('objectNo::', objectNo)
|
||||||
|
|
||||||
if (objectNo) {
|
if (objectNo) {
|
||||||
console.log('수정화면')
|
console.log('수정화면')
|
||||||
@ -209,8 +209,11 @@ export default function StuffDetail() {
|
|||||||
form.setValue('zipNo', info.zipNo)
|
form.setValue('zipNo', info.zipNo)
|
||||||
}
|
}
|
||||||
|
|
||||||
//팝업에서 넘어온 설계의뢰 정보
|
//팝업에서 넘어온 설계의뢰 정보로 바꾸기
|
||||||
const setPlanReqInfo = (info) => {}
|
const setPlanReqInfo = (info) => {
|
||||||
|
console.log('팝업에서 넘어온 설계의뢰 정보::: ', info)
|
||||||
|
// form.setValue('dispCompanyName', info.planReqName)
|
||||||
|
}
|
||||||
|
|
||||||
//팝업에서 넘어온 바람정보
|
//팝업에서 넘어온 바람정보
|
||||||
const setWindSppedInfo = (info) => {
|
const setWindSppedInfo = (info) => {
|
||||||
@ -441,7 +444,7 @@ export default function StuffDetail() {
|
|||||||
let testobj = '10'
|
let testobj = '10'
|
||||||
|
|
||||||
del({ url: `/api/object/${testobj}` }).then((res) => {
|
del({ url: `/api/object/${testobj}` }).then((res) => {
|
||||||
// console.log('삭제 결과:::', res)
|
console.log('삭제 결과:::', res)
|
||||||
router.push('/management/stuff')
|
router.push('/management/stuff')
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
@ -819,7 +822,7 @@ export default function StuffDetail() {
|
|||||||
</th>
|
</th>
|
||||||
<td>
|
<td>
|
||||||
<div className="input-wrap" style={{ width: '500px' }}>
|
<div className="input-wrap" style={{ width: '500px' }}>
|
||||||
{/* <input type="text" className="input-light" {...form.register('dispCompanyName')} value={form.watch('dispCompanyName')} /> */}
|
<input type="text" className="input-light" {...form.register('dispCompanyName')} value={form.watch('dispCompanyName')} />
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
@ -871,7 +874,7 @@ export default function StuffDetail() {
|
|||||||
</th>
|
</th>
|
||||||
<td>
|
<td>
|
||||||
<div className="flx-box">
|
<div className="flx-box">
|
||||||
<div style={{ width: '567px', marginRight: '5px' }}>
|
<div className="select-wrap mr5" style={{ width: '567px' }}>
|
||||||
{/* <Select
|
{/* <Select
|
||||||
options={saleStoreList}
|
options={saleStoreList}
|
||||||
value={form.watch('saleStoreId')}
|
value={form.watch('saleStoreId')}
|
||||||
@ -896,14 +899,14 @@ export default function StuffDetail() {
|
|||||||
{objectNo.substring(0, 1) === 'R' ? (
|
{objectNo.substring(0, 1) === 'R' ? (
|
||||||
<>
|
<>
|
||||||
<Link href="/management/stuff">
|
<Link href="/management/stuff">
|
||||||
<button type="button" className="btn-origin grey">
|
<button type="button" className="btn-origin grey mr5">
|
||||||
R상세:물건목록
|
R상세:물건목록
|
||||||
</button>
|
</button>
|
||||||
</Link>
|
</Link>
|
||||||
<button type="submit" className="btn-origin navy mr5">
|
<button type="submit" className="btn-origin navy mr5">
|
||||||
R상세:저장
|
R상세:저장
|
||||||
</button>
|
</button>
|
||||||
<button type="submit" className="btn-origin navy mr5" onClick={onDelete}>
|
<button type="submit" className="btn-origin navy" onClick={onDelete}>
|
||||||
R상세:물건삭제
|
R상세:물건삭제
|
||||||
</button>
|
</button>
|
||||||
</>
|
</>
|
||||||
|
|||||||
@ -69,12 +69,6 @@ export default function StuffQGrid(props) {
|
|||||||
props.getCellDoubleClicked(event)
|
props.getCellDoubleClicked(event)
|
||||||
}, [])
|
}, [])
|
||||||
|
|
||||||
const autoSizeStrategy = useMemo(() => {
|
|
||||||
return {
|
|
||||||
type: 'fitCellContents',
|
|
||||||
}
|
|
||||||
}, [])
|
|
||||||
|
|
||||||
// Fetch data & update rowData state
|
// Fetch data & update rowData state
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
gridData ? setRowData(gridData) : ''
|
gridData ? setRowData(gridData) : ''
|
||||||
|
|||||||
@ -158,7 +158,7 @@ export default function StuffSearchCondition() {
|
|||||||
<h3>{getMessage('stuff.search.title')}</h3>
|
<h3>{getMessage('stuff.search.title')}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div className="left-unit-box">
|
<div className="left-unit-box">
|
||||||
<Link href="/management/stuff/tempdetail">
|
<Link href="/management/stuff/tempdetail" scroll={false}>
|
||||||
<button type="button" className="btn-origin navy mr5">
|
<button type="button" className="btn-origin navy mr5">
|
||||||
{getMessage('stuff.search.btn1')}
|
{getMessage('stuff.search.btn1')}
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
@ -79,7 +79,6 @@ export default function FindAddressPop(props) {
|
|||||||
}
|
}
|
||||||
// 주소적용 클릭
|
// 주소적용 클릭
|
||||||
const applyAddress = () => {
|
const applyAddress = () => {
|
||||||
// console.log('주소적용 클릭:::::::::', prefId, address1, address2, address3, zipNo)
|
|
||||||
if (prefId == null) {
|
if (prefId == null) {
|
||||||
alert(getMessage('stuff.addressPopup.error.message2'))
|
alert(getMessage('stuff.addressPopup.error.message2'))
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@ -24,6 +24,8 @@ export default function PlanRequestPop(props) {
|
|||||||
|
|
||||||
const globalLocaleState = useRecoilValue(globalLocaleStore)
|
const globalLocaleState = useRecoilValue(globalLocaleStore)
|
||||||
|
|
||||||
|
const [planReqObject, setPlanReqObject] = useState({})
|
||||||
|
|
||||||
const { get, promiseGet } = useAxios(globalLocaleState)
|
const { get, promiseGet } = useAxios(globalLocaleState)
|
||||||
|
|
||||||
const { getMessage } = useMessage()
|
const { getMessage } = useMessage()
|
||||||
@ -205,6 +207,26 @@ export default function PlanRequestPop(props) {
|
|||||||
],
|
],
|
||||||
})
|
})
|
||||||
|
|
||||||
|
//설계의뢰 그리드에서 선택한 설계의로 정보
|
||||||
|
const getSelectedRowdata = (data) => {
|
||||||
|
if (isNotEmptyArray(data)) {
|
||||||
|
setPlanReqObject(data[0])
|
||||||
|
} else {
|
||||||
|
setPlanReqObject({})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 설계의뢰 적용 클릭
|
||||||
|
const applyPlanReq = () => {
|
||||||
|
if (isObjectNotEmpty(planReqObject)) {
|
||||||
|
props.planReqInfo(planReqObject)
|
||||||
|
// 팝업닫기
|
||||||
|
props.setShowDesignRequestButtonValid(false)
|
||||||
|
} else {
|
||||||
|
alert(getMessage('stuff.planReqPopup.error.message1'))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const tempList = [
|
const tempList = [
|
||||||
{
|
{
|
||||||
label: '완료',
|
label: '완료',
|
||||||
@ -405,7 +427,7 @@ export default function PlanRequestPop(props) {
|
|||||||
</div>
|
</div>
|
||||||
<div className="design-request-grid">
|
<div className="design-request-grid">
|
||||||
<div className="design-request-grid-tit">Plan List</div>
|
<div className="design-request-grid-tit">Plan List</div>
|
||||||
<PlanRequestPopQGrid {...gridProps} />
|
<PlanRequestPopQGrid {...gridProps} getSelectedRowdata={getSelectedRowdata} />
|
||||||
<div className="pagination-wrap">
|
<div className="pagination-wrap">
|
||||||
<QPagination pageNo={pageNo} pageSize={pageSize} pagePerBlock={10} totalCount={totalCount} handleChangePage={handleChangePage} />
|
<QPagination pageNo={pageNo} pageSize={pageSize} pagePerBlock={10} totalCount={totalCount} handleChangePage={handleChangePage} />
|
||||||
</div>
|
</div>
|
||||||
@ -415,7 +437,9 @@ export default function PlanRequestPop(props) {
|
|||||||
<button className="btn-origin grey mr5" onClick={() => props.setShowDesignRequestButtonValid(false)}>
|
<button className="btn-origin grey mr5" onClick={() => props.setShowDesignRequestButtonValid(false)}>
|
||||||
{getMessage('stuff.planReqPopup.btn3')}
|
{getMessage('stuff.planReqPopup.btn3')}
|
||||||
</button>
|
</button>
|
||||||
<button className="btn-origin navy ">{getMessage('stuff.planReqPopup.btn4')}</button>
|
<button className="btn-origin navy" onClick={applyPlanReq}>
|
||||||
|
{getMessage('stuff.planReqPopup.btn4')}
|
||||||
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -39,8 +39,14 @@ export default function PlanRequestPopQGrid(props) {
|
|||||||
[gridData],
|
[gridData],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
//부모로 선택한 설계의뢰정보 보내기
|
||||||
|
const onSelectionChanged = () => {
|
||||||
|
const selectedData = gridApi.getSelectedRows()
|
||||||
|
props.getSelectedRowdata(selectedData)
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="ag-theme-quartz" style={{ height: 500 }}>
|
<div className="ag-theme-quartz" style={{ height: 350 }}>
|
||||||
<AgGridReact
|
<AgGridReact
|
||||||
onGridReady={onGridReady}
|
onGridReady={onGridReady}
|
||||||
rowBuffer={rowBuffer}
|
rowBuffer={rowBuffer}
|
||||||
@ -49,7 +55,7 @@ export default function PlanRequestPopQGrid(props) {
|
|||||||
defaultColDef={defaultColDef}
|
defaultColDef={defaultColDef}
|
||||||
rowSelection={'singleRow'}
|
rowSelection={'singleRow'}
|
||||||
pagination={isPageable}
|
pagination={isPageable}
|
||||||
// onSelectionChanged={onSelectionChanged}
|
onSelectionChanged={onSelectionChanged}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
|||||||
@ -502,6 +502,7 @@
|
|||||||
"stuff.planReqPopup.search.period": "期間検索",
|
"stuff.planReqPopup.search.period": "期間検索",
|
||||||
"stuff.planReqPopup.search.schDateGbnS": "提出日",
|
"stuff.planReqPopup.search.schDateGbnS": "提出日",
|
||||||
"stuff.planReqPopup.search.schDateGbnR": "受付日",
|
"stuff.planReqPopup.search.schDateGbnR": "受付日",
|
||||||
|
"stuff.planReqPopup.error.message1": "設計依頼を選択してください。",
|
||||||
"stuff.search.title": "物件状況",
|
"stuff.search.title": "物件状況",
|
||||||
"stuff.search.btn1": "物件登録",
|
"stuff.search.btn1": "物件登録",
|
||||||
"stuff.search.btn2": "照会",
|
"stuff.search.btn2": "照会",
|
||||||
|
|||||||
@ -507,6 +507,7 @@
|
|||||||
"stuff.planReqPopup.search.period": "기간검색",
|
"stuff.planReqPopup.search.period": "기간검색",
|
||||||
"stuff.planReqPopup.search.schDateGbnS": "제출일",
|
"stuff.planReqPopup.search.schDateGbnS": "제출일",
|
||||||
"stuff.planReqPopup.search.schDateGbnR": "접수일",
|
"stuff.planReqPopup.search.schDateGbnR": "접수일",
|
||||||
|
"stuff.planReqPopup.error.message1": "설계의뢰를 선택해주세요.",
|
||||||
"stuff.search.title": "물건현황",
|
"stuff.search.title": "물건현황",
|
||||||
"stuff.search.btn1": "신규등록",
|
"stuff.search.btn1": "신규등록",
|
||||||
"stuff.search.btn2": "조회",
|
"stuff.search.btn2": "조회",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user