Monthly Archive: July 2018

在 Postman 中 POST 请求,http://api.github-shuijingwan-yii2-app-advanced.localhost/v1/users ,输入格式:application/json 0

Based on yiisoft/yii2-app-advanced, create a new repository yii2-app-advanced on github, and create a new interface application (implement RESTful-style web service services. API), application/x-www-form-urlencoded and multipart/form-data input formats, default support, new application/json input format support

Post Views: 29 1. The API can distinguish application/x-www-form-urlencoded and multipart/form-data input formats by default, and view \api\config\main.php, request Configuration of application components 2. POST request in Postman,http://api.github-shuijingwan-yii2-app-advanced.localhost/v1/users, the input format: application/x-www-form-urlencoded, as shown...

当升级时,缺少 PCS_API_CFG_CPU_PARAMS_SOURCE=chinamcloud_pcs // CP上传的参数的系统来源标识,则启动容器失败 0

There is a lack of environment variables during the upgrade of Rancher, which causes the solution to fail to upgrade (when an environment variable does not exist, it will not be replaced)

Post Views: 13 1, \build\c_files\config\init\config0.sh, replace the shell script of environment variables 2. When upgrading, the system source ID of the parameters uploaded by the CP upload is missing, and the boot container fails,...

在公有云中,系统要同时服务于多个租户,多个租户共用一个数据库,因此,需要实现多租户的逻辑隔离,即在数据库的每张表中皆存在租户ID字段 0

Under Yii 2, realize the logical isolation of multi-tenant, that is, there is a tenant ID field in each table of the database, customize the active query class, and add the query conditions of the tenant ID by default in each query.

Post Views: 11 1. Dynamic configuration of database connection in Yii 2 Starter Kit, the configuration attribute comes from the multi-tenant system,https://www.shuijingwanwq.com/2018/01/18/2328/, multi-tenant physical isolation implementation 2. In the public cloud, the system should...

POST http://api.pcs-api.localhost/v1/config-columns?login_id=e56db1b43546a110431ac38409ed8e9e&login_tid=ccffd87b68171e8cb6c19f4bb8ccd775 ,422响应 0

Under Yii 2,[[yii\validators\UniqueValidator|unique(唯一性)]], uniqueness of the combined field, customizing the error message in the common model logic layer

Post Views: 15 1. The model class file in the /common/models directory is only allowed to be generated by the GII tool, which is the common model data layer, \common\models\configcolumn.php, the relevant verification rules...

浏览 user 表数据,status、updated_at 已经更新 0

Based on yiisoft/yii2-app-advanced, create a new repository yii2-app-advanced on github, and create a new interface application (implement RESTful-style web service services. API), realize the soft deletion of ActiveRecord, generate ActiveQuery, and customize the query class

Post Views: 32 1. Based on yii2tech\ar\SoftDelete\SoftDeleteBehavior, the soft deletion of ActiveRecord is realized, and the URL is opened:https://github.com/yiisoft/yii2/blob/master/docs/guide-zh-CN/concept-behaviors.md, as shown in Figure 1 2. Install the ActiveRecord extension of Yii2, use the self-update...