Compare commits

..

2 Commits

Author SHA1 Message Date
yangsh
de9b295e1c 비밀번호 변경시기 체크 추가
Some checks failed
Close Pull Request / main (pull_request_target) Has been cancelled
2025-12-31 15:12:07 +09:00
yangsh
04a06f1781 공통데이터 관리 수정 2025-12-31 15:11:40 +09:00
36 changed files with 1351 additions and 139 deletions

View File

@@ -25,6 +25,9 @@ $routes->get('/home/getHomeFaxCount', to: 'Home\Home::getHomeFaxCount'); // 팩
$routes->group('common', ['namespace' => 'App\Controllers\Common'], function ($routes) {
$routes->get('common/getVrfcCode', 'Common::getVrfcCode');
$routes->post('common/changeUserPass', 'Common::changeUserPass'); // 비밀번호변경
});
/**
@@ -58,6 +61,7 @@ $routes->group('', ['namespace' => 'App\Controllers\V2'], static function ($rout
*/
$routes->group('m701', static function ($routes) {
$routes->get('m701a/lists', 'M701::lists');
$routes->get('m701a/detail/(:num)', 'M701::detail/$1');
/**
* 확인매물현황 - API

View File

@@ -25,13 +25,13 @@ class Apt extends BaseController
$team = $this->aptModel->getTeamList(); // 팀
$user = $this->aptModel->getUserList(); // 유저
return view("pages/article/lists", [
'codes' => $codes,
'sido' => $sido,
'bonbu' => $bonbu,
'team' => $team,
'user' => $user,
]);
$this->data['codes'] = $codes;
$this->data['sido'] = $sido;
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['user'] = $user;
return view("pages/article/lists", $this->data);
}
// 아파트단지목록 조회
@@ -411,22 +411,20 @@ class Apt extends BaseController
}
}
// return print_r($image);
$this->data['apt'] = $apt;
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['user'] = $user;
$this->data['code1'] = $code1;
$this->data['code2'] = $code2;
$this->data['video'] = $video;
$this->data['image'] = $image;
$this->data['vdo'] = $vdo;
$this->data['history'] = $history;
$this->data['cateInfo'] = $cateInfo;
$this->data['cntAllPho'] = $cntAllPho;
return view("pages/article/detail", [
'apt' => $apt,
'bonbu' => $bonbu,
'team' => $team,
'user' => $user,
'code1' => $code1,
'code2' => $code2,
'video' => $video,
'image' => $image,
'vdo' => $vdo,
'history' => $history,
'cateInfo' => $cateInfo,
'cntAllPho' => $cntAllPho
]);
return view("pages/article/detail", $this->data);
}
public function cateJson()

View File

@@ -19,7 +19,7 @@ class DelChgApt extends BaseController
public function lists(): string
{
return view("pages/article/delChgView");
return view("pages/article/delChgView", $this->data);
}

View File

@@ -31,13 +31,13 @@ class Ground extends BaseController
$team = $this->model->getTeamList(); // 팀
$user = $this->model->getUserList(); // 유저
return view("pages/article/lists2", [
'codes' => $codes,
'sido' => $sido,
'bonbu' => $bonbu,
'team' => $team,
'user' => $user,
]);
$this->data['codes'] = $codes;
$this->data['sido'] = $sido;
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['user'] = $user;
return view("pages/article/lists2", $this->data);
}
// 아파트단지목록 조회
@@ -281,14 +281,14 @@ class Ground extends BaseController
// 변경이력
$history = $this->model->getHistory($rcpt_no);
return view("pages/article/detail2", [
'bonbu' => $bonbu,
'team' => $team,
'user' => $user,
'apt' => $apt,
'rdata' => $rdata,
'history' => $history,
]);
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['user'] = $user;
$this->data['apt'] = $apt;
$this->data['rdata'] = $rdata;
$this->data['history'] = $history;
return view("pages/article/detail2", $this->data);
}
// 메모저장

View File

@@ -3,6 +3,7 @@
namespace App\Controllers;
use App\Models\common\MenuModel;
use App\Models\manage\UserModel;
use CodeIgniter\Controller;
abstract class BaseController extends Controller
@@ -23,5 +24,20 @@ abstract class BaseController extends Controller
$menuModel = new MenuModel();
$menus = $menuModel->getMenuList(session('usr_level'));
$this->data['menus'] = $menus["mainMenu"];
if (!empty(session('usr_id'))) {
// 비밀번호 변경일 체크
$userModel = new UserModel();
$usr_id = session('usr_id');
$diff = $userModel->chkChgPwDiff($usr_id);
if ($diff >= 180) {
$this->data['pwExpire'] = true;
} else {
$this->data['pwExpire'] = false;
}
}
}
}

View File

@@ -16,7 +16,7 @@ class Notice extends BaseController
public function notice(): string
{
return view('pages/board/notice');
return view('pages/board/notice', $this->data);
}
@@ -61,7 +61,7 @@ class Notice extends BaseController
throw \CodeIgniter\Exceptions\PageNotFoundException::forPageNotFound();
}
return view('pages/board/noticeDetail', $data);
return view('pages/board/noticeDetail', array_merge($this->data, $data));
}
// 첨부파일 다운로드
@@ -103,7 +103,7 @@ class Notice extends BaseController
// 공지사항 작성 화면
public function write(): string
{
return view('pages/board/noticeWrite');
return view('pages/board/noticeWrite', $this->data);
}
// 공지사항 작성
@@ -228,7 +228,7 @@ class Notice extends BaseController
}
return view('pages/board/noticeModify', $data);
return view('pages/board/noticeModify', array_merge($this->data, $data));
}

View File

@@ -3,14 +3,17 @@ namespace App\Controllers\Common;
use App\Controllers\BaseController;
use App\Models\common\CommonModel;
use App\Models\manage\UserModel;
class Common extends BaseController
{
private $model;
private $userModel;
public function __construct()
{
$this->model = new CommonModel();
$this->userModel = new UserModel();
}
public function getVrfcCode()
@@ -24,4 +27,95 @@ class Common extends BaseController
return $this->response->setJSON($data);
}
// 비밀번호 변경
public function changeUserPass()
{
$usr_id = session('usr_id');
try {
$usr_pass = $this->request->getPost('usr_pass');
$new_pass = $this->request->getPost('new_pass');
$new_pass2 = $this->request->getPost('new_pass2');
if (empty($usr_pass)) {
return $this->response->setJSON([
'code' => '9',
'msg' => '기존 비밀번호 누락',
]);
}
if (empty($new_pass)) {
return $this->response->setJSON([
'code' => '9',
'msg' => '비밀번호 누락',
]);
} else {
if (strlen($new_pass) < 8) {
return $this->response->setJSON([
'code' => '9',
'msg' => '비밀번호 최소 길이는 8자 입니다.',
]);
}
}
if (empty($new_pass2)) {
return $this->response->setJSON([
'code' => '9',
'msg' => '비밀번호 확인 누락',
]);
} else {
if ($new_pass !== $new_pass2) {
return $this->response->setJSON([
'code' => '9',
'msg' => '신규 비밀번호 불일치',
]);
}
}
// 문자조합 유효성 검사
if (!checkPasswordTypes($new_pass, 2)) {
return $this->response->setJSON([
'code' => '9',
'msg' => '비밀번호는 영문 대/소문자, 숫자, 특수문자 중 최소 2종류 이상을 조합해야 합니다.',
]);
}
if ($usr_pass === $new_pass) {
return $this->response->setJSON([
'code' => '9',
'msg' => '기존 비밀번호와 다르게 설정하세요.',
]);
}
// 기존 비밀번호 일치 확인
$usrExist = $this->userModel->chkUserExist($usr_id, $usr_pass);
if ($usrExist === 0) {
return $this->response->setJSON([
'code' => '9',
'msg' => '기존 비밀번호 불일치',
]);
} else {
// UPDATE users
$this->userModel->changeUsrPass($usr_id, $usr_pass, $new_pass);
return $this->response->setJSON([
'code' => '0',
'msg' => 'success'
]);
}
} catch (\Exception $e) {
// log_message('PASSWORD_CHG_ERROR', 'usr_id : ' . $usr_id . ', msg : ' . $e->getMessage());
return $this->response->setJSON([
'code' => '9',
'msg' => $e->getMessage(),
]);
}
}
}

View File

@@ -31,12 +31,11 @@ class Home extends BaseController
$notice = $this->homeModel->getNoticeList();
$statistics = $this->homeModel->getHomeStatistics($this->sdate, $this->edate);
$this->data['menus'] = $this->data;
$this->data['notice'] = $notice;
$this->data['statistics'] = $statistics;
return view('pages/home/dashboard', [
'menus' => $this->data,
'notice' => $notice,
'statistics' => $statistics,
]);
return view('pages/home/dashboard', $this->data);
}
// 실적조회

View File

@@ -33,12 +33,12 @@ class Areas extends BaseController
$team = $this->areaModel->getTeamList();
$user = $this->areaModel->getUserList();
return view("pages/manage/areas/lists", [
'sido' => $sido,
'bonbu' => $bonbu,
'team' => $team,
'user' => $user,
]);
$this->data['sido'] = $sido;
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['user'] = $user;
return view("pages/manage/areas/lists", $this->data);
}

View File

@@ -17,13 +17,13 @@ class Dept extends BaseController
public function dept(): string
{
return view("pages/manage/dept/lists");
return view("pages/manage/dept/lists", $this->data);
}
// 총괄팀장 페이지
public function getchkuser(): string
{
return view("pages/manage/dept/users");
return view("pages/manage/dept/users", $this->data);
}
public function getDeptList()

View File

@@ -16,7 +16,7 @@ class LoginLog extends BaseController
public function lists()
{
return view("pages/manage/log/lists");
return view("pages/manage/log/lists", $this->data);
}
public function getLogList()

View File

@@ -15,7 +15,7 @@ class Menu extends BaseController
public function lists(): string
{
return view("pages/manage/menu/lists");
return view("pages/manage/menu/lists", $this->data);
}

View File

@@ -18,9 +18,9 @@ class Permit extends BaseController
{
$usrLevel = $this->permitModel->getUsrLevel();
return view("pages/manage/permit/lists", [
'usrLevel' => $usrLevel,
]);
$this->data['usrLevel'] = $usrLevel;
return view("pages/manage/permit/lists", $this->data);
}

View File

@@ -19,7 +19,9 @@ class Phone extends BaseController
{
$codes = $this->phoneModel->getCodes();
return view("pages/manage/phone/lists", ['code' => $codes]);
$this->data['code'] = $codes;
return view("pages/manage/phone/lists", $this->data);
}
// 전화확인 목록조회

View File

@@ -17,7 +17,9 @@ class Scomplex extends BaseController
{
$codes = $this->model->getCodeList();
return view("pages/manage/scomplex/lists", ['code' => $codes,]);
$this->data['code'] = $codes;
return view("pages/manage/scomplex/lists", $this->data);
}

View File

@@ -14,7 +14,7 @@ class Sms extends BaseController
public function lists(): string
{
return view("pages/manage/sms/lists");
return view("pages/manage/sms/lists", $this->data);
}
@@ -62,7 +62,7 @@ class Sms extends BaseController
// sms 발송 - 화면
public function smsSendView(): string
{
return view("pages/manage/sms/smsSendView");
return view("pages/manage/sms/smsSendView", $this->data);
}

View File

@@ -21,12 +21,12 @@ class User extends BaseController
$teamList = $this->userModel->getTeamList();
$deptCode = $this->userModel->getDeptCode();
return view("pages/manage/user/lists", [
'userLevel' => $userLevel,
'bonbuList' => $bonbuList,
'teamList' => $teamList,
'deptCode' => $deptCode,
]);
$this->data['userLevel'] = $userLevel;
$this->data['bonbuList'] = $bonbuList;
$this->data['teamList'] = $teamList;
$this->data['deptCode'] = $deptCode;
return view("pages/manage/user/lists", $this->data);
}

View File

@@ -19,12 +19,12 @@ class Assign extends BaseController
$team = $this->assignModel->getTeamList();
$sido = $this->assignModel->getAreaList();
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['sido'] = $sido;
return view("pages/results/assign/stats_a01", [
'bonbu' => $bonbu,
'team' => $team,
'sido' => $sido,
]);
return view("pages/results/assign/stats_a01", $this->data);
}
public function getUserList()

View File

@@ -65,16 +65,16 @@ class Dept extends BaseController
$res = $this->deptModel->st_d01($data);
return view("pages/results/dept/stats_d01", [
'pBonbu' => $this->bonbu,
'pDeptSq' => $this->dept_sq,
'schDateGb' => $this->schDateGb,
'sdate' => $this->sdate,
'edate' => $this->edate,
'bonbu' => $bonbu,
'team' => $team,
'st_list' => $res,
]);
$this->data['pBonbu'] = $this->bonbu;
$this->data['pDeptSq'] = $this->dept_sq;
$this->data['schDateGb'] = $this->schDateGb;
$this->data['sdate'] = $this->sdate;
$this->data['edate'] = $this->edate;
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['st_list'] = $res;
return view("pages/results/dept/stats_d01", $this->data);
}
// 엑셀 다운로드

View File

@@ -21,10 +21,10 @@ class M409 extends BaseController
$CODE_VRFCREQ_WAY = convertArrayToHashTable($codes['VRFCREQ_WAY'], 'cd', 'cd_nm', []);
$CODE_CP_ID = convertArrayToHashTable($codes['CP_ID'], 'cd', 'cd_nm', []);
return view("pages/results/m409/stats", [
'code_vrfcreq_way' => $CODE_VRFCREQ_WAY,
'code_cp_id' => $CODE_CP_ID,
]);
$this->data['code_vrfcreq_way'] = $CODE_VRFCREQ_WAY;
$this->data['code_cp_id'] = $CODE_CP_ID;
return view("pages/results/m409/stats", $this->data);
}
public function getResultList()

View File

@@ -21,11 +21,11 @@ class M410 extends BaseController
$CODE_CP_ID = convertArrayToHashTable($codes['CP_ID'], 'cd', 'cd_nm', []);
$department = $this->model->getDepart();
return view("pages/results/m410/stats", [
'code_vrfcreq_way' => $CODE_VRFCREQ_WAY,
'code_cp_id' => $CODE_CP_ID,
'department' => $department,
]);
$this->data['code_vrfcreq_way'] = $CODE_VRFCREQ_WAY;
$this->data['code_cp_id'] = $CODE_CP_ID;
$this->data['department'] = $department;
return view("pages/results/m410/stats", $this->data);
}
public function getResultList()

View File

@@ -15,8 +15,7 @@ class M411 extends BaseController
public function stats(): string
{
return view("pages/results/m411/stats", [
]);
return view("pages/results/m411/stats", $this->data);
}
public function getResultList()

View File

@@ -28,14 +28,15 @@ class M412 extends BaseController
$sendJ = $this->model->get_send_yn('J');
$sendO = $this->model->get_send_yn('O');
return view("pages/results/m412/stats", [
'sendH' => $sendH,
'sendD' => $sendD,
'sendT' => $sendT,
'sendN' => $sendN,
'sendJ' => $sendJ,
'sendO' => $sendO,
]);
$this->data['sendH'] = $sendH;
$this->data['sendD'] = $sendD;
$this->data['sendT'] = $sendT;
$this->data['sendN'] = $sendN;
$this->data['sendJ'] = $sendJ;
$this->data['sendO'] = $sendO;
return view("pages/results/m412/stats", $this->data);
}
public function getResultList()

View File

@@ -14,8 +14,7 @@ class M415 extends BaseController
public function stats(): string
{
return view("pages/results/m415/stats", [
]);
return view("pages/results/m415/stats", $this->data);
}

View File

@@ -19,11 +19,11 @@ class M416 extends BaseController
$team = $this->model->getTeamList();
$sido = $this->model->getAreaList();
return view("pages/results/m416/stats", [
'bonbu' => $bonbu,
'team' => $team,
'sido' => $sido,
]);
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['sido'] = $sido;
return view("pages/results/m416/stats", $this->data);
}

View File

@@ -18,9 +18,9 @@ class M417 extends BaseController
{
$department = $this->model->getDepart();
return view("pages/results/m417/stats", [
'department' => $department,
]);
$this->data['department'] = $department;
return view("pages/results/m417/stats", $this->data);
}

View File

@@ -22,11 +22,11 @@ class Person extends BaseController
$team = $this->personModel->getTeamList();
$sido = $this->personModel->getAreaList();
return view("pages/results/person/stats_p01", [
'bonbu' => $bonbu,
'team' => $team,
'sido' => $sido,
]);
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['sido'] = $sido;
return view("pages/results/person/stats_p01", $this->data);
}
public function getUserList()

View File

@@ -87,13 +87,13 @@ class Summary extends BaseController
}
}
return view("pages/results/summary/stats_s01", [
'schDateGb' => $this->schDateGb,
'sdate' => $this->sdate,
'edate' => $this->edate,
'st_list' => $res,
'st_agent' => $res2,
'totalAmount' => $totalAmount,
]);
$this->data['schDateGb'] = $this->schDateGb;
$this->data['sdate'] = $this->sdate;
$this->data['edate'] = $this->edate;
$this->data['st_list'] = $res;
$this->data['st_agent'] = $res2;
$this->data['totalAmount'] = $totalAmount;
return view("pages/results/summary/stats_s01", $this->data);
}
}

View File

@@ -24,13 +24,13 @@ class M701 extends BaseController
$team = $this->model->getTeamList();
$user = $this->model->getUserList();
return view("pages/v2/m701/lists", [
"sido" => $sido,
"bonbu" => $bonbu,
"team" => $team,
"user" => $user,
"codes" => $codes,
]);
$this->data['sido'] = $sido;
$this->data['bonbu'] = $bonbu;
$this->data['team'] = $team;
$this->data['user'] = $user;
$this->data['codes'] = $codes;
return view("pages/v2/m701/lists", $this->data);
}
public function getResultList()
@@ -114,6 +114,31 @@ class M701 extends BaseController
$e->getPrevious()->getTraceAsString();
}
}
// 상세화면
public function detail($id = null)
{
$id = (int) $id;
if ($id <= 0) {
throw \CodeIgniter\Exceptions\PageNotFoundException::forPageNotFound();
}
$codes = $this->codeModel->getCodeLists(['VRFCREQ_WAY', 'CONFIRM_RESULT_D11', 'CONFIRM_RESULT_T11', 'CONSULTANT_COMMENT', 'STEP_VERIFICATION', 'TEL_FAIL_CAUSE']); // 코드조회
$data = $this->model->getDetail($id);
$history = $this->model->getHistory($id);
$this->data['codes'] = $codes;
$this->data['data'] = $data;
$this->data['history'] = $history;
return view("pages/v2/m701/detail", $this->data);
}
}

View File

@@ -237,3 +237,33 @@ function han($s)
}
// function to_han ($str) { return preg_replace('/(\\\u[a-f0-9]+)+/e','han("$0")',$str); }
/**
* 비밀번호 문자 조합 검사
* - 영문 대문자 / 소문자 / 숫자 / 특수문자 중 최소 $minTypes 종류 이상
*/
function checkPasswordTypes(string $password, int $minTypes = 2): bool
{
$types = 0;
// 대문자
if (preg_match('/[A-Z]/', $password)) {
$types++;
}
// 소문자
if (preg_match('/[a-z]/', $password)) {
$types++;
}
// 숫자
if (preg_match('/[0-9]/', $password)) {
$types++;
}
// 특수문자 (공백 제외)
if (preg_match('/[^A-Za-z0-9]/', $password)) {
$types++;
}
return $types >= $minTypes;
}

View File

@@ -461,5 +461,59 @@ class UserModel extends Model
return $query->getResultArray();
}
// 최근 비밀번호 변경일 확인
public function chkChgPwDiff($usr_id)
{
$sql = "SELECT DATEDIFF( NOW() , ifnull( last_usr_pw_tm , '2024-01-01 00:00:00') ) as diff FROM users WHERE usr_id = ?";
$query = $this->db->query($sql, [$usr_id]);
return $query->getRow()->diff;
}
// 기존 비밀번호 일치 확인
public function chkUserExist($usr_id, $usr_pass)
{
$sql = "SELECT COUNT(*) AS cnt FROM users WHERE usr_id = ? AND usr_pw = SHA2(?, 256)";
$query = $this->db->query($sql, [$usr_id, $usr_pass]);
return $query->getRow()->cnt;
}
// 비밀번호 변경
public function changeUsrPass($usr_id, $usr_pass, $new_pass)
{
$sql = "UPDATE users SET usr_pw = SHA2(?, 256), last_usr_pw_tm = NOW() WHERE usr_id = ? AND usr_pw = SHA2(?, 256) ";
if ($this->db->query($sql, [$new_pass, $usr_id, $usr_pass]) === false) {
return [
'success' => false,
'msg' => '비밀번호 변경 실패',
];
}
$this->addUserChgHistory(session('usr_sq'), session('usr_sq'), "개인 비밀번호 변경", $new_pass);
// 성공
return [
'success' => true,
];
}
// 변경이력저장
public function addUserChgHistory($usr_sq, $update_user, $memo, $pwd = null)
{
$sql = "INSERT INTO user_chg_history(usr_sq,update_user,memo,update_dttm )" .
" VALUES(?,?,?,now() )";
$data = [
$usr_sq,
$update_user,
$memo
];
$this->db->query($sql, $data);
}
}

View File

@@ -681,4 +681,175 @@ class M701Model extends Model
return $query->getResultArray();
}
// 상세화면
public function getDetail($id)
{
$sql = "SELECT
a.vr_sq,
a.dong_ho_chk,
a.hscplqry_lv,
b.tel_fail_cause,
a.reg_charger,
i2.usr_nm as reg_charger_nm,
a.atcl_no,
b.try_cnt,
a.cpid,
a.cp_atcl_id,
a.rlet_type_cd,
a.address1,
a.sise,
a.rdate,
a.seller_tel_no,
a.seller_nm,
a.realtor_nm,
a.realtor_tel_no,
a.charger,
a.ownerNm,
a.ownerTelNo,
b.owner_verifiable,
b.insert_tm,
b.stat_cd,
c.bild_nm,
b.vrfc_type as vrfc_type_cd,
b.memo,
c.rm_no,
c.floor,
c.floor2,
c.address_code,
c.address2,
c1.address2a,
c1.address2b,
c1.vrfcMthdTpCd,
c1.registerBookUniqueNo,
c1.ownerTypeCode,
c.address3,
c.address4,
c.trade_type as trade_type_cd,
c.deal_amt,
c.wrrnt_amt,
c.lease_amt,
c.isale_amt,
c.prem_amt,
c.sply_spc,
c.excls_spc,
c.tot_spc,
c.grnd_spc,
c.bldg_spc,
c.hscp_no,
c.ptp_no,
d.insert_tm as update_res_tm,
e.insert_tm as result_tm,
f.region_nm,
g.cd_nm as pre_stat,
g.cd as pre_stat_cd,
h.cd_nm as vrfc_type,
i.usr_nm,
j.cd_nm as trade_type,
c.hscp_nm,
c.ptp_nm,
l.success,
k.cd_nm as atcl_nm,
m.code as result_d11,
m.comment,
n.code as fax_conf_yn_2,
o.code as fax_conf_yn_3,
p.code as fax_conf_yn_4,
n.comment as fax_conf_yn_info_2,
o.comment as fax_conf_yn_info_3,
p.comment as fax_conf_yn_info_4,
v.success AS tel_suc,
r.code AS tel_agree,
s.code AS tel_conf_yn_2,
t.code AS tel_conf_yn_3,
u.code AS tel_conf_yn_4,
z.code AS tel_conf_yn_5,
s.comment AS tel_conf_yn_info_2,
t.comment AS tel_conf_yn_info_3,
u.comment AS tel_conf_yn_info_4,
w.success AS reg_conf_yn_1,
x.code AS reg_conf_yn_2,
y.code AS reg_conf_yn_3,
x.comment AS reg_conf_yn_info_2,
y.comment AS reg_conf_yn_info_3,
b.rgbk_confirm,
a.confirm_doc_img_url,
a.cert_register,
a.cert_register_save_yn,
a.confirm_doc_img_url_save_yn,
a.reference_file_url,
a.reference_file_url_save_yn,
a.reference_file_url_yn,
IF(b.insert_tm <= DATE_ADD(CURDATE(), INTERVAL -2 MONTH),'Y','N') after60,
c1.vir_addr_yn,
c1.noRgbkVrfcReqYn,
c1.areaByBdbkVrfcReqYn,
sm.sm_apporval_date ,
sm.sm_end_date,
sm.sm_seq,
registerBookUniqueNumber
FROM
v2_article_info a
JOIN v2_vrfc_req b ON a.vr_sq = b.vr_sq
JOIN v2_modify_info c ON a.vr_sq = c.vr_sq
LEFT JOIN v2_article_info_etc c1 ON c1.vr_sq = a.vr_sq
LEFT JOIN region_codes f ON a.address_code = f.region_cd
LEFT JOIN v2_chg_stat d ON a.vr_sq = d.vr_sq AND d.stat_cd = '35'
LEFT JOIN v2_chg_stat e ON a.vr_sq = e.vr_sq AND d.stat_cd = '60'
LEFT JOIN codes g ON b.stat_cd = g.cd AND g.category = 'STEP_VERIFICATION'
LEFT JOIN codes h ON b.stat_cd = h.cd AND g.category = 'VRFCREQ_WAY'
LEFT JOIN codes j ON b.stat_cd = h.cd AND j.category = 'TRADE_TYPE'
LEFT JOIN codes k ON b.stat_cd = k.cd AND j.category = 'ARTICLE_TYPE'
LEFT JOIN v2_confirm l ON a.vr_sq = l.vr_sq AND l.vrfc_type = 'D'
LEFT JOIN v2_check_list m ON a.vr_sq = m.vr_sq AND m.type = 'D11'
LEFT JOIN v2_check_list n ON a.vr_sq = n.vr_sq AND m.type = 'D12'
LEFT JOIN v2_check_list o ON a.vr_sq = o.vr_sq AND m.type = 'D13'
LEFT JOIN v2_check_list p ON a.vr_sq = p.vr_sq AND m.type = 'D14'
LEFT JOIN v2_confirm v ON a.vr_sq = v.vr_sq AND v.vrfc_type = 'T'
LEFT JOIN v2_check_list r ON a.vr_sq = r.vr_sq AND r.type = 'T11'
LEFT JOIN v2_check_list s ON a.vr_sq = s.vr_sq AND r.type = 'T12'
LEFT JOIN v2_check_list t ON a.vr_sq = t.vr_sq AND r.type = 'T13'
LEFT JOIN v2_check_list u ON a.vr_sq = u.vr_sq AND r.type = 'T14'
LEFT JOIN v2_check_list z ON a.vr_sq = z.vr_sq AND r.type = 'T15'
LEFT JOIN v2_confirm w ON a.vr_sq = w.vr_sq AND w.vrfc_type = 'R'
LEFT JOIN v2_check_list x ON a.vr_sq = x.vr_sq AND x.type = '21'
LEFT JOIN v2_check_list y ON a.vr_sq = y.vr_sq AND x.type = '22'
LEFT JOIN users i ON a.charger = i.usr_id
LEFT JOIN users i2 ON a.reg_charger = i2.usr_id
LEFT JOIN scomplex_manage sm ON a.hscp_no = sm.sm_code
WHERE a.vr_sq = ? ";
$query = $this->db->query($sql, [$id]);
return $query->getRowArray();
}
// 변경이력 조회
public function getHistory($id)
{
$sql = "SELECT
a.seq,
a.vr_sq,
a.stat_cd,
a.chg_type,
a.insert_id,
a.insert_tm,
a.memo,
b.cd_nm as stat_cd_nm,
c.cd_nm as chg_type
FROM
v2_chg_history a
LEFT JOIN codes b ON a.stat_cd = b.cd AND b.category = 'STEP_VERIFICATION'
LEFT JOIN codes c ON a.chg_type = c.cd AND b.category = 'CHANGED_TYPE'
WHERE
a.vr_sq = ?
ORDER BY a.seq DESC ";
$query = $this->db->query($sql, [$id]);
return $query->getResultArray();
}
}

View File

@@ -28,6 +28,10 @@
<?= $this->renderSection('modals') ?>
<?php if ($pwExpire): ?>
<?= $this->include('layouts/widget/pwModal') ?>
<?php endif; ?>
<script type="text/javascript">
const tpl = document.querySelector('.my-loader-template')
const usrLevel = <?= session('usr_level') != null ? session('usr_level') : '' ?>

View File

@@ -0,0 +1,218 @@
<style>
.swal2-cancel {
background-color: #ff0000 !important;
color: #fff !important;
}
</style>
<!-- 비밀번호 변경 모달 -->
<div class="modal fade" id="pwChangeModal" tabindex="-1" aria-hidden="true" aria-labelledby="pwChangeModalLabel">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<!-- header -->
<div class="modal-header">
<h5 class="modal-title fw-bold" id="pwChangeModalLabel">비밀번호변경</h5>
<button type="button" class="btn-close layer_popup_close" data-bs-dismiss="modal"
aria-label="닫기"></button>
</div>
<!-- body -->
<div class="modal-body">
<!-- 규칙 박스 -->
<div class="border rounded-3 p-3 mb-3 bg-light">
<fieldset class="mb-0">
<legend class="fs-6 fw-semibold mb-2">컨펌스 시스템 비밀번호 작성규칙</legend>
<ul class="mb-0 ps-3">
<li class="mb-2">
<div class="fw-semibold">- 최소길이</div>
<div class="text-muted small">
최소 8자리 이상 : 영어 대문자, 소문자, 숫자, 특수문자 최소 2종류 조합
</div>
</li>
<li class="mb-2">
<div class="fw-semibold">- 추측하기 어려운 비밀번호</div>
<div class="text-muted small">
일련번호, 전화번호 쉬운 문자열이 포함되지 않도록 <br>
알려진 단어, 키보드 상에서 나란히 있는 문자열이 포함되지 않도록
</div>
</li>
<li class="mb-2">
<div class="fw-semibold">- 주기적 변경</div>
<div class="text-muted small">비밀번호에 유효기간 설정하고 최소 6개월마다 변경</div>
</li>
<li>
<div class="fw-semibold">- 동일 비밀번호 사용 제한</div>
<div class="text-muted small">2개의 비밀번호를 교대로 사용하지 않음</div>
</li>
</ul>
</fieldset>
</div>
<!-- 안내 문구 -->
<div class="alert alert-warning py-2 mb-3">
<div class="small mb-0">* 비밀번호가 <b>180</b> 지나 변경 하셔야 합니다.</div>
</div>
<!-- 입력 -->
<form id="frm_pw_change" onsubmit="return false;">
<div class="row g-3">
<div class="col-12 col-md-4">
<label for="usr_pass" class="form-label">기존비밀번호</label>
<input type="password" id="usr_pass" name="usr_pass" class="form-control" required />
</div>
<div class="col-12 col-md-4">
<label for="new_pass" class="form-label">비밀번호</label>
<input type="password" id="new_pass" name="new_pass" class="form-control" required />
</div>
<div class="col-12 col-md-4">
<label for="new_pass2" class="form-label">비밀번호확인</label>
<input type="password" id="new_pass2" name="new_pass2" class="form-control" required />
</div>
</div>
</form>
<!-- 오늘하루 보지않기 -->
<div class="mt-3 text-end">
<a href="javascript:void(0)" class="small text-decoration-none layer_popup_today_close">
오늘하루 보지않기
</a>
</div>
</div>
<!-- footer -->
<div class="modal-footer d-flex gap-1">
<button type="button" class="btn btn-outline-secondary layer_popup_close" data-bs-dismiss="modal">
닫기
</button>
<button type="button" class="btn btn-primary layer_popup_ok" onclick="chageUserPass();">
확인
</button>
</div>
</div>
</div>
</div>
<script type="text/javascript">
$(function () {
if (shouldShowPwModal()) {
const el = document.getElementById('pwChangeModal');
if (el) {
const modal = new bootstrap.Modal(el, {
backdrop: 'static', // 바깥 클릭 닫기 막기(원하면 false로)
keyboard: false // ESC 닫기 막기(원하면 true)
});
modal.show();
}
}
// 하루동안 열지 않기
$(".layer_popup_today_close").on('click', function () {
const key = 'pwChangeModalHideDate';
const today = new Date().toISOString().slice(0, 10);
localStorage.setItem(key, today);
const el = document.getElementById('pwChangeModal');
bootstrap.Modal.getInstance(el)?.hide();
});
});
// 하루동안 열지 않기 체크
function shouldShowPwModal() {
const key = 'pwChangeModalHideDate';
const today = new Date().toISOString().slice(0, 10);
return localStorage.getItem(key) !== today;
}
function chageUserPass() {
const form = document.getElementById('frm_pw_change');
let isValid = true;
// Bootstrap5 기본 validation 적용
if (!form.checkValidity()) {
isValid = false;
}
if (!isValid) {
form.classList.add('was-validated');
return;
}
swal.fire({
text: "저장 하시겠습니까?",
type: "warning",
showCancelButton: true,
confirmButtonText: "",
cancelButtonText: "아니오",
closeOnConfirm: false,
closeOnCancel: true,
confirmButtonColor: "#3085d6",
cancelButtonColor: "#d33",
}).then((result) => {
if (result.isConfirmed) {
$.ajax({
url: '/common/common/changeUserPass',
contentType: 'application/x-www-form-urlencoded;charset=UTF-8',
method: 'POST',
data: $("#frm_pw_change").serialize(),
beforeSend: function () {
blockUI.blockPage({
message: tpl
})
},
complete: function () {
blockUI.unblockPage()
},
error: function (xhr, error, thrown) {
blockUI.unblockPage()
var msg = "";
if (xhr.responseText != null) {
msg = xhr.responseText
} else {
msg = "잠시후 다시 시도해 주세요."
}
Swal.fire({
title: msg,
icon: "error"
})
},
success: function (result) {
if (result.code == '0') {
Swal.fire({
title: '정상 처리되었습니다.',
icon: "success"
})
} else {
Swal.fire({
title: result.msg,
icon: "error"
})
}
}
});
}
});
}
</script>

View File

@@ -0,0 +1,599 @@
<?= $this->extend('layouts/main') ?>
<?= $this->section('content') ?>
<style>
.tbl_basic2 th {
padding: 0 10px;
height: 27px;
border: solid 1px #d8d9de;
background-color: #eff0f4;
letter-spacing: -1px;
font-weight: normal;
color: #5a5f69;
text-align: left;
}
.blockUI {
z-index: 1500 !important;
}
.ellipsis {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
max-width: 180px;
}
.card-header {
display: flex !important;
align-items: center;
}
.card-header-tab {
justify-content: flex-start !important;
}
.table-scroll {
max-height: 300px;
overflow-y: scroll;
}
.swal2-cancel {
background-color: #ff0000 !important;
color: #fff !important;
}
.num {
color: #b68556;
font-size: 19px;
}
</style>
<h1>확인매물 상세 내용</h1>
<div class="col-md-12 col-xl-12">
<div class="col-lg-12">
<div class="main-card mb-3 card">
<div class="card-header" style="width:100%; max-width:100%; min-width:600px; padding:0; border:0;">
<p class="left">
</p>
<table style="width:100%; min-width:600px; padding:0; border:0;" cellpadding="0" cellspacing="0"
border="0" width="100%">
<tbody>
<tr>
<td style="width: 50%;padding-left: 20px"><span class="tit">매물ID :</span> <span
class="num"><?= $data['atcl_no'] ?></span>
</td>
<td style="width: 20%;"><span class="tit">CP ID :</span> <span
class="num"><?= $data['cpid'] ?></span></td>
<td style="width: 30%; text-align: right;padding-right: 20px"><span class="tit">현재 상태
:</span> <span class="num"><?= $data['pre_stat'] ?></span></td>
</tr>
<tr>
<td height="15"></td>
<td></td>
<td></td>
</tr>
</tbody>
</table>
<p></p>
</div>
<div class="card-body">
<h5 class="card-title">공인 중개사 정보</h5>
<table class="table table-bordered table-sm tbl_basic2 apt-info-table">
<colgroup>
<col width="15%" />
<col width="35%" />
<col width="15%" />
<col width="35%" />
</colgroup>
<tr>
<th>중개사명</th>
<td><?= $data['realtor_nm'] ?></td>
<th>대표전화</th>
<td><?= $data['realtor_tel_no'] ?></td>
</tr>
</table>
</div>
</div>
<div class="main-card mb-3 card">
<div class="card-body">
<h5 class="card-title">단지 정보</h5>
<div class="table-responsive">
<table class="table table-bordered table-sm align-middle mb-0 apt-info-table">
<colgroup>
<col style="width:120px">
<col style="width:320px">
<col style="width:120px">
<col style="width:320px">
</colgroup>
<tbody>
<tr>
<th class="bg-light">등록일</th>
<td><?= $data['rdate'] ?></td>
<th class="bg-light">전화/서류 완료일시</th>
<td>
<select class="form-select form-select-sm" name="atcl_vrtc_way" id="atcl_vrtc_way"
disabled>
<option value="">-선택-</option>
<?php foreach ($codes as $c): ?>
<?php if ($c['category'] === "VRFCREQ_WAY"): ?>
<option value="<?= $c['cd'] ?>" <?= ($c['cd'] === $data['vrfc_type_cd']) ? 'selected' : '' ?>>
<?= $c['cd_nm'] ?>
</option>
<?php endif; ?>
<?php endforeach; ?>
</select>
</td>
</tr>
<tr>
<th class="bg-light">등기부등본 확인완료</th>
<td><?= $data['result_tm'] ?></td>
<th class="bg-light">의뢰인(매도자)</th>
<td>
<?php if (in_array($data['stat_cd'], ['19', '60', '69'])): ?>
***
<?php else: ?>
<?= $data['seller_nm'] ?>
<?php endif; ?>
</td>
</tr>
<tr>
<th class="bg-light">매물구분</th>
<td><?= $data['atcl_nm'] ?></td>
<th class="bg-light">거래구분</th>
<td>
<div class="d-flex flex-wrap gap-3">
<div class="form-check">
<input class="form-check-input" type="radio" name="trade_type_cd"
id="trade_type_1" value="B1" <?= ($data['trade_type_cd'] === 'B1') ? 'checked' : '' ?> disabled>
<label class="form-check-label" for="trade_type_1">전세</label>
</div>
<div class="form-check">
<input class="form-check-input" type="radio" name="trade_type_cd"
id="trade_type_2" value="B2" <?= ($data['trade_type_cd'] === 'B2') ? 'checked' : '' ?> disabled>
<label class="form-check-label" for="trade_type_2">월세</label>
</div>
<div class="form-check">
<input class="form-check-input" type="radio" name="trade_type_cd"
id="trade_type_4" value="B3" <?= ($data['trade_type_cd'] === 'B3') ? 'checked' : '' ?> disabled>
<label class="form-check-label" for="trade_type_4">단기임대</label>
</div>
<div class="form-check">
<input class="form-check-input" type="radio" name="trade_type_cd"
id="trade_type_3" value="A1" <?= ($data['trade_type_cd'] === 'A1') ? 'checked' : '' ?> disabled>
<label class="form-check-label" for="trade_type_3">매매</label>
</div>
</div>
</td>
</tr>
<tr>
<th class="bg-light" rowspan="3">지역구분</th>
<td rowspan="3"><?= $data['region_nm'] ?></td>
<th class="bg-light">리 주소</th>
<td>
<input type="text" class="form-control form-control-sm"
value="<?= $data['address2a'] ?>" disabled>
</td>
</tr>
<tr>
<th class="bg-light">상세주소</th>
<td>
<?php if (empty($data['address2b'])): ?>
<input type="text" class="form-control form-control-sm mb-2"
value="<?= $data['address2'] ?>" disabled>
<input type="hidden" name="atcl_addr1b" id="atcl_addr1b" value=" ">
<?php else: ?>
<input type="hidden" name="atcl_addr1" id="atcl_addr1" value=" ">
<input type="text" class="form-control form-control-sm mb-2"
value="<?= $data['address2b'] ?>" disabled>
<?php endif; ?>
<input type="text" class="form-control form-control-sm"
value="<?= $data['address3'] ?>" disabled>
</td>
</tr>
<tr>
<th class="bg-light">기타주소</th>
<td>
<input type="text" class="form-control form-control-sm"
value="<?= $data['address4'] ?>" disabled>
</td>
</tr>
<tr>
<th class="bg-light">단지명</th>
<td>
<input type="hidden" name="atcl_hscp_nm" id="atcl_hscp_nm"
value="<?= $data['hscp_nm'] ?>" />
<?php
/*
$js = 'id="atcl_hscp_no" onchange="ajax_code_ptpList(this.value)" disabled="disabled"';
echo form_dropdown('atcl_hscp_no', $complexList, $data['hscp_no'], $js);
*/
?>
<?php if ($data['sm_seq'] !== null): ?>
<span style='color:#FF0000'>※ 특이단지</span>
<?php endif; ?>
</td>
<th class="bg-light">가격</th>
<td>
<div class="d-flex align-items-center gap-2">
<div class="input-group input-group-sm" style="max-width: 220px;">
<input type="text" class="form-control" name="atcl_amt1" id="atcl_amt1"
value="200000" disabled>
<span class="input-group-text">만원</span>
</div>
<div class="form-check mb-0">
<input class="form-check-input" type="checkbox" id="price_ignore1">
<label class="form-check-label" for="price_ignore1">가격무시</label>
</div>
</div>
</td>
</tr>
<tr>
<th class="bg-light">평형</th>
<td>
<input type="hidden" name="atcl_ptp_nm" id="atcl_ptp_nm" value="">
<select class="form-select form-select-sm" name="atcl_ptp_no" id="atcl_ptp_no"
disabled>
<option value="">-평형-</option>
</select>
</td>
<th class="bg-light">층 / 총층</th>
<td>
<div class="d-flex align-items-center gap-2">
<input type="text" class="form-control form-control-sm" style="max-width:80px;"
name="atcl_floor" id="atcl_floor" value="8" disabled>
<span class="text-muted">/</span>
<input type="text" class="form-control form-control-sm" style="max-width:80px;"
name="atcl_floor2" id="atcl_floor2" value="0" disabled>
</div>
</td>
</tr>
<tr>
<th class="bg-light">가주소 여부</th>
<td><span>N</span></td>
<th class="bg-light">검증참고란</th>
<td><span></span></td>
</tr>
<tr>
<th class="bg-light">소유자 구분</th>
<td><span></span></td>
<th class="bg-light">미등기 검증요청</th>
<td><span>N</span></td>
</tr>
<tr>
<th class="bg-light">건축물대장 면적 검증요청</th>
<td><span>N</span></td>
<th class="bg-light">등기부 고유번호</th>
<td><span></span></td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="card-footer d-flex justify-content-end gap-1">
<button class="mb-2 me-2 btn-transition btn btn-outline-secondary" onclick="">수정</button>
<button class="mb-2 me-2 btn btn-primary" id="btnSave">저장</button>
</div>
</div>
</div>
<div class="main-card mb-3 card">
<div class="card-body ">
<h5 class="card-title">단지 정보</h5>
<table class="table table-bordered table-sm tbl_basic2 apt-info-table">
<tr>
<th>단지명</th>
<td></td>
<th>소재주소</th>
<td></td>
<th>상세주소</th>
<td></td>
<th>사용승인일</th>
<td></td>
<th>단지 총 동수</th>
<td></td>
</tr>
</table>
</div>
</div>
<div class="main-card mb-3 card">
<div class="card-body ">
<h5 class="card-title">상태변경</h5>
<?php foreach ($codes as $c): ?>
<?php if ($c['category'] === "STEP_VERIFICATION"): ?>
<button class="mb-2 me-2 btn btn-light" data-step="<?= $c['cd'] ?>"><?= $c['cd_nm'] ?></button>
<?php endif; ?>
<?php endforeach; ?>
</div>
</div>
<div class="main-card mb-3 card">
<div class="card-body">
<h5 class="card-title">서류확인 정보</h5>
<table class="table table-bordered table-sm tbl_basic2 apt-info-table">
<colgroup>
<col width="60%">
<col>
</colgroup>
<tbody>
<tr>
<!-- 좌측 : 이미지 -->
<td>
<div id="douc_img_dis" class="py-2">
<a href="#" rel="lightbox[gallery]">
<img id="photo-display" src="/plugin/img/photo.gif" alt="Image"
style="width:100%; max-width:945px; border:0;">
</a>
</div>
<div id="div_fild_upload" class="text-end">
<!-- <span id="btnFileUpload1" class="position-relative d-inline-block">
<input type="file" id="docu_file" name="docu_file"
class="position-absolute top-0 start-0 opacity-0"
style="width:95px; cursor:pointer;" onchange="myfile_onchange(event)">
<img src="/img/btn/file_upload.gif" alt="파일업로드">
</span> -->
<button class="btn btn-sm btn-primary">
업로드
</button>
</div>
</td>
<!-- 우측 : 정보 -->
<td valign="top" class="pt-2">
<table class="tbl_basic4 w-100">
<colgroup>
<col width="30%">
<col>
</colgroup>
<tbody>
<tr>
<th>확인담당자</th>
<td>관리자</td>
</tr>
<tr>
<th>확인여부</th>
<td>
<select class="form-select" id="fax_conf_res_d11" name="fax_conf_res_d11">
<option value="">-선택-</option>
<option value="10000">확인완료</option>
<option value="20011">매물정보 오작성</option>
<option value="20012">중개업소정보 오작성</option>
<option value="20013">중개업소 요청에 의한 취소</option>
</select>
</td>
</tr>
<tr>
<th>홍보확인서<br>미확인여부상세</th>
<td>
<table class="w-100">
<tbody>
<tr>
<td><input type="checkbox" disabled> 소재지</td>
<td><input type="checkbox" disabled> 거래유형</td>
</tr>
<tr>
<td><input type="checkbox" disabled> 가격</td>
<td><input type="checkbox" disabled> 등기부상 소유자명</td>
</tr>
<tr>
<td><input type="checkbox" disabled> 소유자와의 관계</td>
<td><input type="checkbox" disabled> 의뢰인</td>
</tr>
<tr>
<td><input type="checkbox" disabled> 서명</td>
<td><input type="checkbox" disabled> 중개업소요청</td>
</tr>
<tr>
<td><input type="checkbox" disabled> 증빙서류</td>
<td><input type="checkbox" disabled> 기타</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<th>확인 내용</th>
<td>
<select class="form-select" id="fax_conf_yn_1">
<option value="">-선택-</option>
<option value="1">전체일치</option>
<option value="2">전체불일치</option>
</select>
</td>
</tr>
<tr>
<th>매물주소</th>
<td class="d-flex gap-2">
<select class="form-select" id="fax_conf_yn_2">
<option value="">-선택-</option>
<option value="10000">일치</option>
<option value="20000">불일치</option>
</select>
<input type="text" class="form-control" id="fax_conf_yn_info_2">
</td>
</tr>
<tr>
<th>가격 거래구분</th>
<td class="d-flex gap-2">
<select class="form-select" id="fax_conf_yn_3">
<option value="">-선택-</option>
<option value="10000">일치</option>
<option value="20000">불일치</option>
</select>
<input type="text" class="form-control" id="fax_conf_yn_info_3">
</td>
</tr>
<tr>
<th>의뢰인정보</th>
<td class="d-flex gap-2">
<select class="form-select" id="fax_conf_yn_4">
<option value="">-선택-</option>
<option value="10000">일치</option>
<option value="20000">불일치</option>
</select>
<input type="text" class="form-control" id="fax_conf_yn_info_4">
</td>
</tr>
<tr>
<th>메모</th>
<td class="d-flex align-items-end gap-1">
<textarea class="form-control" id="memo_fax" rows="2"
style="resize: none;"></textarea>
<button type="button" class="btn btn-sm btn-outline-secondary"
onclick="saveFaxMemo();" style="white-space: nowrap;">
저장
</button>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
<div class="card-footer d-flex justify-content-end gap-1">
<button type="button" class="btn btn-success btn-sm" onclick="saveDocu();">
저장
</button>
</div>
</div>
<!-- 동영상 업로드 팝업 -->
<?= $this->section('modals') ?>
<div class="modal fade" id="uploadModal" tabindex="-1">
<div class="modal-dialog modal-xl">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">파일 업로드</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body p-0">
<form id="frm_file_info" method="post" enctype="multipart/form-data" onsubmit="return false;">
<input type="hidden" name="rcpt_no" value="">
<input type="hidden" name="upload_type" value="photo">
<!-- 버튼 툴바 -->
<div class="d-flex justify-content-end gap-2 mb-3" style="padding: 16px 10px 0 0;">
<button type="button" class="btn btn-primary" id="uploadPick">
<i class="pe-7s-up-arrow"></i> 파일선택
</button>
<button type="button" class="btn btn-success" id="btnUpload">
<i class="pe-7s-up-arrow"></i> 파일업로드
</button>
<button type="button" class="btn btn-danger" id="btnRemove">
<i class="pe-7s-less"></i> 업로드취소
</button>
</div>
<!-- Dropzone 영역 -->
<div id="myDropzone" class="dropzone border rounded-3 p-4"
style="max-height: 400px;overflow-y: scroll;">
<div class="dz-message dz-message-fixed needsclick text-center">
<i class="pe-7s-upload mb-2" style="font-size:42px;"></i><br>
<strong class="fs-6">파일을 드래그하거나 클릭해서 추가하세요</strong><br>
<small class="text-muted">
사진 여러 장 가능 / 동영상은 1개만
</small>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
<div class="modal" id="mapModal" tabindex="-1">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">지도 보기</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body p-0">
<div id="modalMap" style="width:100%; height:70vh; min-height:500px;"></div>
</div>
</div>
</div>
</div>
<div class="modal" id="previewModal" tabindex="-1">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">미리보기</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal"></button>
</div>
<div class="modal-body p-0">
<img id="imgPreview" src="" alt="미리보기" width="100%" height="500px">
<video id="vdoPreview" controls playsinline preload="metadata"
style="display: none;height: 500px;width: 100%;">
<source id="videoSource" src="" type="video/mp4">
브라우저가 video 태그를 지원하지 않습니다.
</video>
</div>
</div>
</div>
</div>
<?= $this->endSection() ?>
<style>
#tbl-align-left {
text-align: left;
}
</style>
<script src="https://unpkg.com/dropzone@6.0.0-beta.1/dist/dropzone-min.js"></script>
<link href="https://unpkg.com/dropzone@6.0.0-beta.1/dist/dropzone.css" rel="stylesheet" type="text/css" />
<script type="text/javascript">
</script>
<?= $this->endSection() ?>

View File

@@ -556,11 +556,8 @@
const rowData = table.row(this).data();
if (!rowData) return;
return;
// const rcpt_no = rowData.rcpt_no;
// const hscp_no = rowData.hscp_no;
// location.href = "<?= site_url('article/apt/ground/detail') ?>/" + rcpt_no + "/" + hscp_no;
const vr_sq = rowData.vr_sq;
location.href = "<?= site_url('m701/m701a/detail') ?>/" + vr_sq;
});
$('#btnSearch').on('click', function () {