zoukankan      html  css  js  c++  java
  • fastadmin常用一键创建curd


    //生成fa_test表的CRUD且一键生成菜单
    php think crud -t test -u 1


    //删除fa_test表生成的CRUD
    php think crud -t test -d 1


    //生成fa_test表的CRUD且生成关联模型category,外链为category_id,关联表主键为id
    php think crud -t test -r category -k category_id -p id


    //生成fa_test表的CRUD且所有以list或data结尾的字段都生成复选框
    php think crud -t test --setcheckboxsuffix=list --setcheckboxsuffix=data


    //生成fa_test表的CRUD且所有以image和img结尾的字段都生成图片上传组件
    php think crud -t test --imagefield=image --imagefield=img


    //关联多个表,参数传递时请按顺序依次传递,支持以下几个参数relation/relationmodel/relationforeignkey/relationprimarykey/relationfields/relationmode
    php think crud -t test --relation=category --relation=admin --relationforeignkey=category_id --relationforeignkey=admin_id






    ------------创建curd 并且关联多表 且后缀img的生成上传图
    php think crud -t fa_project  -u 1  --imagefield=img --relation=fa_project_cat --relation=fa_country --relationforeignkey=category_id --relationforeignkey=country_id

  • 相关阅读:
    学习git之路--1
    No input file specified. phpStudy nginx报错解决方案
    nginx隐藏tp路由index.php
    tp5命令行
    生成器
    php 解密小程序获取unionid
    根据GUID获取实例
    用SQL将数字转换为中文数字
    TFS无法确定工作区解决方案
    利用SQL语句产生分组序号
  • 原文地址:https://www.cnblogs.com/gyrgyr/p/15737261.html
Copyright © 2011-2022 走看看