7 Star 46 Fork 1

CACode / Aestate Framework

Create your Gitee Account
Explore and code with more than 6 million developers,Free private repositories !:)
Sign up
Clone or download
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README.md

Aestate —— 多样化数据库查询

Documentation License: Apache-2.0

介绍

当前仅MySql8.0以上测试通过

Aestate Framework 是一款基于Python语言开发的ORM框架,你可以使用多种方式去实现基于对象方式的查询.

比如使用类似django的模式去使用:modelClass.orm.filter(*args, **kwargs)

或者sqlalchemy的方式:find().where(**kwargs).group_by(*args)

或者像javahibernate一样:

@SelectAbst()
def find_all_F_where_id_in_and_name_like_order_by_id(self, **kwargs) -> list: ...


@Select("SELECT * FROM demo WHERE id=${id} AND name=${name}")
def find_all_where_id(self, id, name): ...

或者像javamybatis使用xml

<?xml version="1.0"?>
<aestate
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="aestate  https://gitee.com/cacode_cctvadmin/aestate-xml/blob/main/v1/tags.xsd"
        xmlns="aestate">
    <namespace id="demo_table" from="example.tables.demoModels.DemoTable"/>
    <import file="./db.xml" id="database" target="demoDatabase"/>
    <template id="templateField">
        id,name,password,create_time,update_time
        <description>测试模板</description>
    </template>

    <item id="findAllById">
        <select>
            <include from="templateField"/>
        </select>
    </item>

    <description>测试描述</description>
</aestate>

先决条件

python >=3.6 (其他版本没试过)
教程文档地址:http://doc.cacode.ren

更全面的教程和文档

安装

pip 命令:pip install aestate
anaconda 安装:conda install aestate
qq群:909044439

依赖包

pip install aestate-json

谁在使用 Aestate Framework 开发网站

CACode: https://cacode.ren
CocoZao 爬虫:https://ccz.cacode.ren

开源示例项目:gitee/aestate-example

CACode Development Team

Last edit time:2021/05/26 02:03 Asia/Shanghai
👉 Go to canotf`s homepage on Gitee 👈

Comments ( 1 )

Sign in for post a comment

About

为Python提供数据库多样化操作的ORM工具包 spread retract
Python and 2 more languages
Apache-2.0
Cancel

Releases (11)

All

Aestate Framework

Contributors

All

Activities

load more
can not load any more
Python
1
https://gitee.com/cacode_cctvadmin/aestate.git
git@gitee.com:cacode_cctvadmin/aestate.git
cacode_cctvadmin
aestate
Aestate Framework
main

Search

102255 3a0e046c 1850385 102255 7aaa926c 1850385