Merge remote-tracking branch 'origin/main'

new
JiilingLee 1 year ago
commit 9cca34a28c

@ -27,6 +27,7 @@ CREATE TABLE `lyr-one`.`archives_accounting_book` (
SELECT `id` INTO @menuId FROM system_menu WHERE `name` = ''; SELECT `id` INTO @menuId FROM system_menu WHERE `name` = '';
-- 簿
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('簿', '', 2, 1, @menuId, 'book', 'education', 'accounting/book/index', 'Book', 0, b'1', b'1', b'1', '', '2023-09-20 15:09:58', '', '2023-09-20 15:09:58', b'0'); INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('簿', '', 2, 1, @menuId, 'book', 'education', 'accounting/book/index', 'Book', 0, b'1', b'1', b'1', '', '2023-09-20 15:09:58', '', '2023-09-20 15:09:58', b'0');
SET @menuId2 = LAST_INSERT_ID(); SET @menuId2 = LAST_INSERT_ID();
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('簿', 'archives:accounting-book:create', 3, 1, @menuId2 , '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-22 11:20:21', '', '2023-09-22 11:20:21', b'0'); INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('簿', 'archives:accounting-book:create', 3, 1, @menuId2 , '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-22 11:20:21', '', '2023-09-22 11:20:21', b'0');

@ -24,17 +24,17 @@ CREATE TABLE `lyr-one`.`archives_borrow_apply` (
PRIMARY KEY (`id`) USING BTREE PRIMARY KEY (`id`) USING BTREE
) ENGINE = MyISAM AUTO_INCREMENT = 2 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '' ROW_FORMAT = DYNAMIC; ) ENGINE = MyISAM AUTO_INCREMENT = 2 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '' ROW_FORMAT = DYNAMIC;
INSERT INTO `lyr-one`.`system_menu` (`name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', '', 1, 0, 0, '/borrow', 'component', NULL, NULL, 0, b'1', b'1', b'1', '', '2023-09-13 15:27:06', '', '2023-09-13 15:27:16', b'0'); -- INSERT INTO `lyr-one`.`system_menu` (`name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', '', 1, 0, 0, '/borrow', 'component', NULL, NULL, 0, b'1', b'1', b'1', '', '2023-09-13 15:27:06', '', '2023-09-13 15:27:16', b'0');
SET @menuId = LAST_INSERT_ID(); -- SET @menuId = LAST_INSERT_ID();
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'borrow:apply:list', 2, 1, @menuId, 'apply', 'education', 'borrow/apply/index', 'apply', 0, b'1', b'1', b'1', '', '2023-09-13 15:29:48', '', '2023-09-13 15:29:48', b'0'); -- INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'borrow:apply:list', 2, 1, @menuId, 'apply', 'education', 'borrow/apply/index', 'apply', 0, b'1', b'1', b'1', '', '2023-09-13 15:29:48', '', '2023-09-13 15:29:48', b'0');
SET @menuId2 = LAST_INSERT_ID(); -- SET @menuId2 = LAST_INSERT_ID();
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:create', 3, 1, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:36:56', '', '2023-09-13 15:36:56', b'0'); -- INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:create', 3, 1, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:36:56', '', '2023-09-13 15:36:56', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:export', 3, 2, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:37:31', '', '2023-09-13 15:37:31', b'0'); -- INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:export', 3, 2, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:37:31', '', '2023-09-13 15:37:31', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:update', 3, 3, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:39:24', '', '2023-09-13 15:39:24', b'0'); -- INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:update', 3, 3, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:39:24', '', '2023-09-13 15:39:24', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('', 'archives:borrowAapply:delete', 3, 4, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:39:53', '', '2023-09-13 16:08:02', b'1'); -- INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('', 'archives:borrowAapply:delete', 3, 4, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:39:53', '', '2023-09-13 16:08:02', b'1');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:delete', 3, 4, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 16:08:23', '', '2023-09-13 16:08:23', b'0'); -- INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:delete', 3, 4, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 16:08:23', '', '2023-09-13 16:08:23', b'0');
--
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'borrow:record:list', 2, 2, @menuId, 'record', 'table', 'borrow/record/index', 'record', 0, b'1', b'1', b'1', '', '2023-09-13 16:09:53', '', '2023-09-13 16:12:09', b'0'); -- INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'borrow:record:list', 2, 2, @menuId, 'record', 'table', 'borrow/record/index', 'record', 0, b'1', b'1', b'1', '', '2023-09-13 16:09:53', '', '2023-09-13 16:12:09', b'0');
-- --

@ -0,0 +1,62 @@
--
SELECT `id` INTO @menuId FROM system_menu WHERE `name` = '';
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'borrow:apply:list', 2, 1, @menuId, 'apply', 'education', 'borrow/apply/index', 'apply', 0, b'1', b'1', b'1', '', '2023-09-13 15:29:48', '', '2023-09-13 15:29:48', b'0');
SET @menuId2 = LAST_INSERT_ID();
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:create', 3, 1, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:36:56', '', '2023-09-13 15:36:56', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:export', 3, 2, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:37:31', '', '2023-09-13 15:37:31', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:update', 3, 3, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:39:24', '', '2023-09-13 15:39:24', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('', 'archives:borrowAapply:delete', 3, 4, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 15:39:53', '', '2023-09-13 16:08:02', b'1');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:borrowAapply:delete', 3, 4, @menuId2, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-09-13 16:08:23', '', '2023-09-13 16:08:23', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'borrow:record:list', 2, 2, @menuId, 'record', 'table', 'borrow/record/index', 'record', 0, b'1', b'1', b'1', '', '2023-09-13 16:09:53', '', '2023-09-13 16:12:09', b'0');
-- 簿 password
ALTER TABLE archives_accounting_book ADD COLUMN `password` varchar(64) NULL DEFAULT NULL COMMENT '';
-- password
ALTER TABLE archives_accounting_report ADD COLUMN `password` varchar(64) NULL DEFAULT NULL COMMENT '';
-- --
CREATE TABLE `lyr-one`.`archives_flow` (
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT 'Id',
`flow_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT 'OA/ERP',
`voucher_id` bigint(20) NULL DEFAULT NULL COMMENT 'id',
`voucher_num` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`business_id` bigint(20) NULL DEFAULT NULL COMMENT 'id',
`business_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`creator` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`create_time` datetime NULL DEFAULT NULL COMMENT '',
`updater` datetime NULL DEFAULT NULL COMMENT '',
`update_time` datetime NULL DEFAULT NULL COMMENT '',
`deleted` bit(1) NULL DEFAULT b'0' COMMENT '',
`company_id` bigint(20) NULL DEFAULT NULL COMMENT 'id',
`company` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`del_status` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`suffix` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`file_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`file_ap` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`flow_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`note` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`dept_id` bigint(20) NULL DEFAULT NULL COMMENT 'id',
`dept_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`archive_id` bigint(20) NULL DEFAULT NULL COMMENT 'id',
`archive_state` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '',
`tenant_id` bigint(20) NULL DEFAULT NULL COMMENT '',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = MyISAM AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '' ROW_FORMAT = Dynamic;
--
SELECT `id` INTO @menuId5 FROM system_menu WHERE `name` = '';
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', '', 2, 5, @menuId5, 'flow', 'order', 'accounting/flow/index', 'flow', 0, b'1', b'1', b'1', '', '2023-09-25 14:51:39', '', '2023-09-25 14:51:39', b'0');
SET @menuId6 = LAST_INSERT_ID();
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:flow:create', 3, 1, @menuId6, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-10-07 16:48:22', '', '2023-10-07 16:48:22', b'0');
INSERT INTO `lyr-one`.`system_menu` (`name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('', 'archives:flow:update', 3, 2, @menuId6, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-10-07 16:48:40', '', '2023-10-07 16:52:39', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('', 'archives:flow:delete', 3, 3, @menuId6, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-10-07 16:48:57', '', '2023-10-07 16:48:57', b'0');
INSERT INTO `lyr-one`.`system_menu` ( `name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ( '', 'archives:flow:query', 3, 4, @menuId6, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-10-07 16:49:23', '', '2023-10-07 16:49:23', b'0');
INSERT INTO `lyr-one`.`system_menu` (`name`, `permission`, `type`, `sort`, `parent_id`, `path`, `icon`, `component`, `component_name`, `status`, `visible`, `keep_alive`, `always_show`, `creator`, `create_time`, `updater`, `update_time`, `deleted`) VALUES ('', 'archives:flow:export', 3, 5, @menuId6, '', '', '', '', 0, b'1', b'1', b'1', '', '2023-10-07 16:49:46', '', '2023-10-07 16:49:46', b'0');

@ -6,10 +6,16 @@ import cn.iocoder.yudao.framework.common.util.validation.ValidationUtils;
import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClient; import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClient;
import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClientConfig; import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClientConfig;
import cn.iocoder.yudao.module.accounting.controller.admin.accountingbook.vo.*; import cn.iocoder.yudao.module.accounting.controller.admin.accountingbook.vo.*;
import cn.iocoder.yudao.module.accounting.controller.admin.invoices.vo.InvoicesPageReqVO;
import cn.iocoder.yudao.module.accounting.controller.admin.invoices.vo.InvoicesRespVO;
import cn.iocoder.yudao.module.accounting.convert.accountingbook.AccountingBookConvert; import cn.iocoder.yudao.module.accounting.convert.accountingbook.AccountingBookConvert;
import cn.iocoder.yudao.module.accounting.convert.invoices.InvoicesConvert;
import cn.iocoder.yudao.module.accounting.dal.dataobject.accountingbook.AccountingBookDO; import cn.iocoder.yudao.module.accounting.dal.dataobject.accountingbook.AccountingBookDO;
import cn.iocoder.yudao.module.accounting.dal.dataobject.invoices.InvoicesDO;
import cn.iocoder.yudao.module.accounting.service.accountingbook.AccountingBookService; import cn.iocoder.yudao.module.accounting.service.accountingbook.AccountingBookService;
import cn.iocoder.yudao.module.infra.service.file.FileService; import cn.iocoder.yudao.module.infra.service.file.FileService;
import cn.iocoder.yudao.module.setting.service.passwords.PasswordsService;
import com.alibaba.fastjson.JSONObject;
import org.springframework.data.redis.core.RedisTemplate; import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource; import javax.annotation.Resource;
@ -52,6 +58,9 @@ public class AccountingBookController {
@Resource @Resource
private RedisTemplate redisTemplate; private RedisTemplate redisTemplate;
@Resource
private PasswordsService passwordsService;
@PostMapping("/create") @PostMapping("/create")
@Operation(summary = "创建会计账簿") @Operation(summary = "创建会计账簿")
@ -106,6 +115,16 @@ public class AccountingBookController {
} }
@PutMapping("/downloadXml")
@Operation(summary = "获得分页Xml")
@PreAuthorize("@ss.hasPermission('archives:accounting-book:query')")
public void downloadXml(@Valid AccountingBookPageReqVO pageVO, HttpServletResponse response) throws IOException {
PageResult<AccountingBookDO> pageResult = accountingBookService.getAccountingBookPage(pageVO);
PageResult<AccountingBookRespVO> voPageResult = AccountingBookConvert.INSTANCE.convertPage(pageResult);
String jsonString = JSONObject.toJSONString(voPageResult);
passwordsService.jsonToXmlConverter(response,pageVO.getInputPassword(),jsonString);
}
@PutMapping("/update") @PutMapping("/update")
@Operation(summary = "更新会计账簿") @Operation(summary = "更新会计账簿")
@PreAuthorize("@ss.hasPermission('archives:accounting-book:update')") @PreAuthorize("@ss.hasPermission('archives:accounting-book:update')")

@ -50,4 +50,7 @@ public class AccountingBookBaseVO {
@Schema(description = "所属部门", example = "张三") @Schema(description = "所属部门", example = "张三")
private String deptName; private String deptName;
@Schema(description = "密码区")
private String password;
} }

@ -59,4 +59,7 @@ public class AccountingBookExcelVO {
@ExcelProperty("所属部门") @ExcelProperty("所属部门")
private String deptName; private String deptName;
@Schema(description = "密码区")
private String password;
} }

@ -61,4 +61,7 @@ public class AccountingBookPageReqVO extends PageParam {
@Schema(description = "所属部门", example = "张三") @Schema(description = "所属部门", example = "张三")
private String deptName; private String deptName;
@Schema(description = "密码")
String inputPassword;
} }

@ -4,10 +4,16 @@ import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.common.util.validation.ValidationUtils; import cn.iocoder.yudao.framework.common.util.validation.ValidationUtils;
import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClient; import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClient;
import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClientConfig; import cn.iocoder.yudao.framework.file.core.client.s3.S3FileClientConfig;
import cn.iocoder.yudao.module.accounting.controller.admin.accountingbook.vo.AccountingBookPageReqVO;
import cn.iocoder.yudao.module.accounting.controller.admin.accountingbook.vo.AccountingBookRespVO;
import cn.iocoder.yudao.module.accounting.controller.admin.accountingreport.vo.*; import cn.iocoder.yudao.module.accounting.controller.admin.accountingreport.vo.*;
import cn.iocoder.yudao.module.accounting.convert.accountingbook.AccountingBookConvert;
import cn.iocoder.yudao.module.accounting.convert.accountingreport.AccountingReportConvert; import cn.iocoder.yudao.module.accounting.convert.accountingreport.AccountingReportConvert;
import cn.iocoder.yudao.module.accounting.dal.dataobject.accountingbook.AccountingBookDO;
import cn.iocoder.yudao.module.accounting.dal.dataobject.accountingreport.AccountingReportDO; import cn.iocoder.yudao.module.accounting.dal.dataobject.accountingreport.AccountingReportDO;
import cn.iocoder.yudao.module.accounting.service.accountingreport.AccountingReportService; import cn.iocoder.yudao.module.accounting.service.accountingreport.AccountingReportService;
import cn.iocoder.yudao.module.setting.service.passwords.PasswordsService;
import com.alibaba.fastjson.JSONObject;
import org.springframework.data.redis.core.RedisTemplate; import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource; import javax.annotation.Resource;
@ -43,6 +49,9 @@ public class AccountingReportController {
@Resource @Resource
private RedisTemplate redisTemplate; private RedisTemplate redisTemplate;
@Resource
private PasswordsService passwordsService;
@PostMapping("/create") @PostMapping("/create")
@Operation(summary = "创建会计报表") @Operation(summary = "创建会计报表")
@PreAuthorize("@ss.hasPermission('archives:accounting-report:create')") @PreAuthorize("@ss.hasPermission('archives:accounting-report:create')")
@ -138,6 +147,16 @@ public class AccountingReportController {
return success(AccountingReportConvert.INSTANCE.convertPage(pageResult)); return success(AccountingReportConvert.INSTANCE.convertPage(pageResult));
} }
@GetMapping("/downloadXml")
@Operation(summary = "获得会计报表分页")
@PreAuthorize("@ss.hasPermission('archives:accounting-report:query')")
public void getAccountingReportPage(@Valid AccountingReportPageReqVO pageVO, HttpServletResponse response) throws IOException {
PageResult<AccountingReportDO> pageResult = accountingReportService.getAccountingReportPage(pageVO);
PageResult<AccountingReportRespVO> voPageResult = AccountingReportConvert.INSTANCE.convertPage(pageResult);
String jsonString = JSONObject.toJSONString(voPageResult);
passwordsService.jsonToXmlConverter(response,pageVO.getInputPassword(),jsonString);
}
@GetMapping("/export-excel") @GetMapping("/export-excel")
@Operation(summary = "导出会计报表 Excel") @Operation(summary = "导出会计报表 Excel")
@PreAuthorize("@ss.hasPermission('archives:accounting-report:export')") @PreAuthorize("@ss.hasPermission('archives:accounting-report:export')")

@ -54,4 +54,7 @@ public class AccountingReportBaseVO {
@Schema(description = "所属部门", example = "赵六") @Schema(description = "所属部门", example = "赵六")
private String deptName; private String deptName;
@Schema(description = "密码")
private String password;
} }

@ -62,4 +62,7 @@ public class AccountingReportExcelVO {
@ExcelProperty("所属部门") @ExcelProperty("所属部门")
private String deptName; private String deptName;
@ExcelProperty("密码")
private String password;
} }

@ -58,4 +58,7 @@ public class AccountingReportPageReqVO extends PageParam {
@Schema(description = "所属部门", example = "赵六") @Schema(description = "所属部门", example = "赵六")
private String deptName; private String deptName;
@Schema(description = "密码")
String inputPassword;
} }

@ -1,5 +1,6 @@
package cn.iocoder.yudao.module.accounting.dal.dataobject.accountingbook; package cn.iocoder.yudao.module.accounting.dal.dataobject.accountingbook;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*; import lombok.*;
import java.util.*; import java.util.*;
import java.time.LocalDateTime; import java.time.LocalDateTime;
@ -88,4 +89,9 @@ public class AccountingBookDO extends BaseDO {
*/ */
private String deptName; private String deptName;
/**
*
*/
private String password;
} }

@ -81,4 +81,10 @@ public class AccountingReportDO extends BaseDO {
*/ */
private String deptName; private String deptName;
/**
*
*/
private String password;
} }

Loading…
Cancel
Save