src/DdvUtil/Laravel/Model.php
public function toUnderline($isConversionOriginal = false){
        if ($isConversionOriginal){
            $this->original = Conversion::humpToUnderlineByIndexArray($this->original);
        }
        if (!empty($this->relations)){
            if (is_array($this->relations)||is_object($this->relations)){
                foreach ($this->relations as $key => $item){
                    if ((!empty($item))&&is_object($item)&&method_exists($item, 'toUnderline')){
                        $this->relations[$key] = $item->toUnderline();
                    }
                }
            }
        }
        $this->ddvSnakeAttributes = true;
        $this->attributes = Conversion::humpToUnderlineByIndexArray($this->attributes);
        return $this;
    }
public function toUnderline($isConversionOriginal = false){
        if ($isConversionOriginal){
            $this->original = Conversion::humpToUnderlineByIndexArray($this->original);
        }
        if (!empty($this->relations)){
            if (is_array($this->relations)||is_object($this->relations)){
                foreach ($this->relations as $key => $item){
                    if ((!empty($item))&&is_object($item)&&method_exists($item, 'toUnderline')){
                        $this->relations[$key] = $item->toUnderline();
                    }
                }
            }
        }
        $this->ddvSnakeAttributes = true;
        $this->attributes = Conversion::humpToUnderlineByIndexArray($this->attributes);
        return $this;
    }
下滑杠转小写驼峰
@param true|false $isConversionOriginal [是否强制转换源]
@return Model $this [请求对象]