분류 전체보기 338

Node_99번 부서 중복insert/update/delete/Table

async function getInsert(req, res){ oracledb.autoCommit = true; //기본 false let connection; try { connection = oracledb.getConnection({ user: dbconfig.user, //DB 아이디 password: dbconfig.password, //DB 비밀번호 connectString: dbconfig.xid, //localhost: 1521/xe }) const result = (await connection).execute("insert into dept(deptno, dname, loc) values (:deptno, :dname, :loc)", [99, "개발", "제주"], function(e..

Node_10번 부서 출력 + insert

app.get("/selectById", function(req, res){ getSelecteById(req, res); }) app.get("/insert", function(req, res){ getInsert(req, res); }) //3. 브라우저에서 불러오기 위한 코드 async function getSelection(req, res){ let connection; try { connection = oracledb.getConnection({ user: dbconfig.user, //DB 아이디 password: dbconfig.password, //DB 비밀번호 connectString: dbconfig.xid, //localhost: 1521/xe }) const result = (awa..

스프링 팀플) 20240223_JSTL태그, EL태그, Spring식 코드로 전환

이전 단계에서는 java 이클립스에서 만든 코드를 Spring에 넣었으니 이번 단계에서는 코드를 Spring 답게 만드는 단계이다. 회원 가입 이력 없음 회원 정보가 없습니다. 입력하신 정보를 다시 한번 확인해주세요. 로그인 회원정보 찾기 - 이 페이지는 특별히 3가지 방법으로 데이터를 출력했다. - 1. 기존 jsp코드: 로그인 - 2. EL태그: 회원정보 찾기 - 3. jstl태그: href=""> //멤버 리스트 찾기 @RequestMapping(value = "/memberList", method = RequestMethod.GET) public ModelAndView memberList() { ModelAndView mav = new ModelAndView(); List list = serv.s..

Node_서버 가동 및 html파일 연결

Node 버전 확인 node –v npm –npm npm init : yes 나올 때까지 엔터 -> Pakage.json 생성 Exit로 종료 폴더에서 js파일 생성 https://www.npmjs.com/ express검색 /* NodeJS는 자바스크릅티를 브라우저 밖에서 사용하게 해주는 프로그램 express는 서버를 개발하고자 하는 개발자를 위해 서버를 쉽게 구성할 수 있게 만든 프레임 워크 npm install express --save로 설치 !!서버 가동된 상태에서는 코드를 수정해도 반영되지 않음!! -> 서버 껐다가 다시 킬 것 */ const express = require("express"); const app = express(); const server = app.listen(3000..

React_Styled_자식으로 색상 넘기기

import Button from "./Button"; import styled from "styled-components"; const StyledH1 = styled.h1` color: red; `; export default function App(){ const text_color="purple"; return( App A B ) } import styled from "styled-components" //1. html태그에 스타일 적용 ==> styled.태그명 ``형식 const StyledButton = styled.button` color: ${(props) => props.button_color || "blue"}; background-color: yellow; font-size: 16p..

React_css(내부파일 / 외부파일 / styled-components)

내부파일 import "./App.css"; export default function App(){ //css설정, json, camel표기법 const btnStyle = { color: "while", backgroundColor: "teal", border: "1px solid teal", fontSize: "16px", } return( App Inline ) } 외부파일 import "./App.css"; import "./Button.css" export default function App(){ //css설정, json, camel표기법 return( App Inline ) } .btn{ color: "while"; background-color: "teal"; border: "1px sol..