package chart_info_future_good_profit

import "hongze/hongze_yb/global"

// GetItemById 主键获取
func (m *ChartInfoFutureGoodProfit) GetItemById(primaryId int) (err error) {
	err = global.MYSQL["data"].Model(m).
		Where("chart_info_id = ?", primaryId).
		First(&m).Error
	return
}

func (m *ChartInfoFutureGoodProfit) Update(updateCols []string) (err error) {
	err = global.MYSQL["data"].Model(m).Select(updateCols).Updates(*m).Error
	return
}
