From a2b4e57b8d0777f076690bfa1daed7dac60eba91 Mon Sep 17 00:00:00 2001 From: CRM8000 Date: Wed, 23 Oct 2024 07:55:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=87=AD=E8=AF=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controller/VoucherController.class.php | 25 +++++++++++++++++++ .../SLN0002/DAO/VoucherDAO.class.php | 13 ++++++++++ .../SLN0002/Service/VoucherService.class.php | 13 ++++++++++ 3 files changed, 51 insertions(+) diff --git a/web/Application/SLN0002/Controller/VoucherController.class.php b/web/Application/SLN0002/Controller/VoucherController.class.php index 95cbe391..d585075e 100644 --- a/web/Application/SLN0002/Controller/VoucherController.class.php +++ b/web/Application/SLN0002/Controller/VoucherController.class.php @@ -99,4 +99,29 @@ class VoucherController extends PSIBaseController $this->ajaxReturn($service->voucherList($params)); } } + + /** + * 查询凭证字列表 + * + * JS: web\Public\Scripts\PSI\SLN0002\Voucher\EditForm.js + */ + function queryVoucherWord() + { + if (IS_POST) { + $us = new UserService(); + + $hasPermission = $us->hasPermission(FIdConst::VOUCHER_ADD) || + $us->hasPermission(FIdConst::VOUCHER_EDIT); + if (!$hasPermission) { + die("没有权限"); + } + + $params = [ + "orgId" => I("post.orgId"), + ]; + + $service = new VoucherService(); + $this->ajaxReturn($service->queryVoucherWord($params)); + } + } } diff --git a/web/Application/SLN0002/DAO/VoucherDAO.class.php b/web/Application/SLN0002/DAO/VoucherDAO.class.php index aa028496..2396d4d4 100644 --- a/web/Application/SLN0002/DAO/VoucherDAO.class.php +++ b/web/Application/SLN0002/DAO/VoucherDAO.class.php @@ -33,4 +33,17 @@ class VoucherDAO extends PSIBaseExDAO "totalCount" => 0, ]; } + + /** + * 查询凭证字列表 + */ + function queryVoucherWord($params) + { + $db = $this->db; + + $orgId = $params["orgId"]; + + // TODO + return $this->emptyResult(); + } } diff --git a/web/Application/SLN0002/Service/VoucherService.class.php b/web/Application/SLN0002/Service/VoucherService.class.php index 362203d5..8618220d 100644 --- a/web/Application/SLN0002/Service/VoucherService.class.php +++ b/web/Application/SLN0002/Service/VoucherService.class.php @@ -54,4 +54,17 @@ class VoucherService extends PSIBaseExService $dao = new VoucherDAO($this->db()); return $dao->voucherList($params); } + + /** + * 查询凭证字列表 + */ + function queryVoucherWord($params) + { + if ($this->isNotOnline()) { + return $this->emptyResult(); + } + + $dao = new VoucherDAO($this->db()); + return $dao->queryVoucherWord($params); + } }