TASK:企业、教育版library元素共享、作品广场作品发布到公共gallery

This commit is contained in:
2025-05-19 14:02:42 +08:00
parent bf92edb267
commit aeb372bc17
22 changed files with 389 additions and 8 deletions

View File

@@ -0,0 +1,42 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ai.da.mapper.primary.LibraryMapper">
<select id="selectCommonLib" resultType="com.ai.da.mapper.primary.entity.Library">
SELECT l.*
FROM `t_enterprise_library` e
LEFT JOIN t_library l on e.library_id = l.id
WHERE e.enterprise_id = #{organizationId}
ORDER BY id ${sort == 'DESC' ? 'DESC' : 'ASC'}
LIMIT ${limit} OFFSET ${offset}
</select>
<select id="selectCommonLibCount" resultType="java.lang.Long">
SELECT COUNT(l.id)
FROM `t_enterprise_library` e
LEFT JOIN t_library l on e.library_id = l.id
WHERE e.enterprise_id = #{organizationId}
</select>
<select id="selectAllSubAccLib" resultType="com.ai.da.mapper.primary.entity.Library">
SELECT *
FROM t_library
WHERE account_id IN (
SELECT id
FROM t_account
WHERE organization_id = #{organizationId}
)
ORDER BY id ${sort == 'DESC' ? 'DESC' : 'ASC'}
LIMIT ${limit} OFFSET ${offset}
</select>
<select id="selectAllSubAccLibCount" resultType="java.lang.Long">
SELECT COUNT(*)
FROM t_library
WHERE account_id IN (
SELECT id
FROM t_account
WHERE organization_id = #{organizationId}
)
</select>
</mapper>

View File

@@ -156,6 +156,8 @@ model.path.cannot.be.empty=Model path cannot be empty.
this.promotion.code.has.expired=This promotion code has expired.
this.promotion.code.is.invalid=This promotion code is invalid.
one.time.limit.per.customer=This code has already been redeemed. Promo codes are limited to one-time use per customer.
element.already.exists=This element already exists in the public library
have.no.permission=Sorry, you don't have permission
# 可能会报异常
# Informative:

View File

@@ -152,6 +152,8 @@ model.path.cannot.be.empty=模特路径不能为空
this.promotion.code.has.expired=该促销码已过期。
this.promotion.code.is.invalid=该促销码无效。
one.time.limit.per.customer=该码已兑换。每个促销码每位用户仅限使用一次。
element.already.exists=元素已存在于公共库中
have.no.permission=您没有权限
# 可能会报异常
# Informative: