随笔分类 - fastadmin
摘要:按钮 { field: 'buttons', width: "120px", title: __('按钮组'), table: table, events: Table.api.events.operate, buttons: [ { name: 'fahuo', text: __('发货'), t
阅读全文
posted @ 2020-11-13 11:40
bufeetu
摘要:api注意事项 去除空白参数$req=array_filter($req); 只增加数据表有字段的值 $res=ScheduleModel::allowField(true)->insertGetId($req);
阅读全文
posted @ 2020-10-27 13:24
bufeetu
摘要:下拉框数据生成 模型里选择数据 public static function getTypeList() { $list=self::where(true)->select(); $res=[]; foreach ($list as $k=>$v){ $res[$v['id']]=$v['name'
阅读全文
posted @ 2020-10-26 15:04
bufeetu
摘要:增加数据allowfield 如果需要过滤非数据表字段的数据,可以使用: $user = new User($_POST); // 过滤post数组中的非数据表字段数据 $user->allowField(true)->save(); 如果你通过外部提交赋值给模型,并且希望指定某些字段写入,可以使用
阅读全文
posted @ 2020-10-26 12:06
bufeetu
摘要:同数据库配置文件,复制一个databasenewchat.php 填写数据库信息 config导入配置文件,并且导出名称 $db_newchat=require_once ('databasenewchat.php'); return [ 'db_newchat' => $db_newchat, '
阅读全文
posted @ 2020-10-26 11:48
bufeetu
摘要:data-source 根据user/user/index搜索,根据username搜索返回的是主键 <div class="form-group"> <label class="control-label col-xs-12 col-sm-2">{:__('Userid')}:</label>
阅读全文
posted @ 2020-10-09 10:37
bufeetu
摘要:自定义按钮 { field: 'buttons', width: "120px", title: __('按钮组'), table: table, events: Table.api.events.operate, buttons: [ { name: 'tongguo', text: '通过',
阅读全文
posted @ 2020-09-11 17:22
bufeetu

浙公网安备 33010602011771号