fairwic / mongo-orm
build in fastmongo.mongo orm
1.0.2
2024-06-03 06:11 UTC
Requires
- php: ^8.1
- ext-mongodb: *
- ext-redis: *
- hyperf/elasticsearch: ^3.0
- hyperf/gotask: v3.0.1
- hyperf/redis: ~3.0.0
- reasno/fastmongo: dev-master
This package is auto-updated.
Last update: 2025-03-31 08:01:10 UTC
README
基于reasno/fastmongo 实现的协程化 MongoDB客户端ORM
<?php declare(strict_types=1); namespace App\Mongo; use App\Constants\GroupConstans; use App\Es\Group\GroupEs; use App\Exception\TransactionsException; use App\Model\Base\Group; use App\Model\Customercare\CustomercareModel; use App\Model\UserModel; use App\Services\Group\GroupMemberService; use App\Services\Group\GroupService; use App\Utils\GlobalContext; use Carbon\Carbon; use DateTime; use DateTimeZone; use fairwic\MongoOrm\DocumentArr; use fairwic\MongoOrm\Elasticsearch\EsInstanceInterface; use fairwic\MongoOrm\MongoBasic; use fairwic\MongoOrm\MongoCollection; use fairwic\MongoOrm\MongoModel; use Hyperf\Context\ApplicationContext; use Hyperf\Database\Model\Builder; use Hyperf\Database\Model\Collection; use Hyperf\GoTask\MongoClient\Type\InsertManyResult; use Hyperf\Stringable\Str; use Hyperf\Utils\HigherOrderTapProxy; use Psr\Container\ContainerExceptionInterface; use Psr\Container\NotFoundExceptionInterface; class GroupMongo extends MongoModel implements EsInstanceInterface { protected string $database_name = "pxb7_im"; /** * mongo document name * @var string */ protected string $document_name = "im_group"; /** * es index name * @var string */ protected string $index_name = "group"; protected bool $isSoftDelete = true;