models

package
v0.0.0-...-c107b7b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 8, 2016 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AD_TYPE         string = "ad_type"
	CAMPAIGN_TYPE   string = "campaign_type"
	ACCURATE_TYPE   string = "accurate_type"
	PRICING_TYPE    string = "pricing_type"
	STRATEGY_TYPE   string = "strategy_type"
	BUDGET_TYPE     string = "budget_type"
	CAMPAIGN_STATUS string = "campaign_status"
	GENDER          string = "gender"
	TEMPRETURE      string = "tempreture"
	HUMIDITY        string = "humidity"
	WIND            string = "wind"
	WEATHER         string = "weather"
	OCCUPATION      string = "occupation"
	OPERATOR        string = "operator"
	PLATEFORM       string = "plateform"
	PHONE_BRAND     string = "phone_brand"
	INTERNET        string = "internet"
	CITY            string = "CITY"
	PROVINCE        string = "PROVINCE"
)

Variables

This section is empty.

Functions

func AddFinBorrower

func AddFinBorrower(m *FinBorrower) (id int64, err error)

AddFinBorrower insert a new FinBorrower into database and returns last inserted Id on success.

func AddFinBorrowerDetail

func AddFinBorrowerDetail(m *FinBorrowerDetail) (id int64, err error)

AddFinBorrowerDetail insert a new FinBorrowerDetail into database and returns last inserted Id on success.

func AddFinLoanDeal

func AddFinLoanDeal(m *FinLoanDeal) (id int64, err error)

AddFinLoanDeal insert a new FinLoanDeal into database and returns last inserted Id on success.

func AddFinLoanRequest

func AddFinLoanRequest(m *FinLoanRequest) (id int64, err error)

AddFinLoanRequest insert a new FinLoanRequest into database and returns last inserted Id on success.

func AddFinLov

func AddFinLov(m *FinLov) (id int64, err error)

AddFinLov insert a new FinLov into database and returns last inserted Id on success.

func AddFinOrg

func AddFinOrg(m *FinOrg) (id int64, err error)

AddFinOrg insert a new FinOrg into database and returns last inserted Id on success.

func AddFinOrgMember

func AddFinOrgMember(m *FinOrgMember) (id int64, err error)

AddFinOrgMember insert a new FinOrgMember into database and returns last inserted Id on success.

func AddLtvApp

func AddLtvApp(m *LtvApp) (id int64, err error)

AddLtvApp insert a new LtvApp into database and returns last inserted Id on success.

func AddLtvFlight

func AddLtvFlight(m *LtvFlight) (id int64, err error)

AddLtvFlight insert a new LtvFlight into database and returns last inserted Id on success.

func AddLtvFlightGroup

func AddLtvFlightGroup(m *LtvFlightGroup) (id int64, err error)

AddLtvFlightGroup insert a new LtvFlightGroup into database and returns last inserted Id on success.

func AddPmpAdspace

func AddPmpAdspace(m *PmpAdspace) (id int64, err error)

AddPmpAdspace insert a new PmpAdspace into database and returns last inserted Id on success.

func AddPmpAdspaceAndMapDemand

func AddPmpAdspaceAndMapDemand(v *AdspaceVo) (id int64, err error)

add a new PmpAdspace and create the adsapce and demand mapping at the sametime

func AddPmpAdspaceMatrix

func AddPmpAdspaceMatrix(m *PmpAdspaceMatrix) (id int64, err error)

AddPmpAdspaceMatrix insert a new PmpAdspaceMatrix into database and returns last inserted Id on success.

func AddPmpCampaign

func AddPmpCampaign(m *PmpCampaign) (id int64, err error)

AddPmpCampaign insert a new PmpCampaign into database and returns last inserted Id on success.

func AddPmpCampaignCreative

func AddPmpCampaignCreative(v *PmpCampaignCreative) (err error)

func AddPmpCampaignMatrix

func AddPmpCampaignMatrix(m *PmpCampaignMatrix) (id int64, err error)

AddPmpCampaignMatrix insert a new PmpCampaignMatrix into database and returns last inserted Id on success.

func AddPmpDailyAllocation

func AddPmpDailyAllocation(m *PmpDailyAllocation) (id int64, err error)

AddPmpDailyAllocation insert a new PmpDailyAllocation into database and returns last inserted Id on success.

func AddPmpDailyAllocationDetail

func AddPmpDailyAllocationDetail(m *PmpDailyAllocationDetail) (id int64, err error)

AddPmpDailyAllocationDetail insert a new PmpDailyAllocationDetail into database and returns last inserted Id on success.

func AddPmpDailyReport

func AddPmpDailyReport(m *PmpDailyReport) (id int64, err error)

AddPmpDailyReport insert a new PmpDailyReport into database and returns last inserted Id on success.

func AddPmpDailyRequestReport

func AddPmpDailyRequestReport(m *PmpDailyRequestReport) (id int64, err error)

AddPmpDailyRequestReport insert a new PmpDailyRequestReport into database and returns last inserted Id on success.

func AddPmpDemandAdspace

func AddPmpDemandAdspace(m *DemandAdspaceVo) (id int64, err error)

AddPmpDemandAdspace insert a new PmpDemandAdspace into database and returns last inserted Id on success.

func AddPmpDemandDailyReport

func AddPmpDemandDailyReport(m *PmpDemandDailyReport) (id int64, err error)

AddPmpDemandDailyReport insert a new PmpDemandDailyReport into database and returns last inserted Id on success.

func AddPmpDemandPlatformDesk

func AddPmpDemandPlatformDesk(m *PmpDemandPlatformDesk) (id int64, err error)

AddPmpDemandPlatformDesk insert a new PmpDemandPlatformDesk into database and returns last inserted Id on success.

func AddPmpMedia

func AddPmpMedia(m *PmpMedia) (id int64, err error)

AddPmpMedia insert a new PmpMedia into database and returns last inserted Id on success.

func DeleteFinBorrower

func DeleteFinBorrower(id int) (err error)

DeleteFinBorrower deletes FinBorrower by Id and returns error if the record to be deleted doesn't exist

func DeleteFinBorrowerDetail

func DeleteFinBorrowerDetail(id int) (err error)

DeleteFinBorrowerDetail deletes FinBorrowerDetail by Id and returns error if the record to be deleted doesn't exist

func DeleteFinLoanDeal

func DeleteFinLoanDeal(id int) (err error)

DeleteFinLoanDeal deletes FinLoanDeal by Id and returns error if the record to be deleted doesn't exist

func DeleteFinLoanRequest

func DeleteFinLoanRequest(id int) (err error)

DeleteFinLoanRequest deletes FinLoanRequest by Id and returns error if the record to be deleted doesn't exist

func DeleteFinLov

func DeleteFinLov(id int) (err error)

DeleteFinLov deletes FinLov by Id and returns error if the record to be deleted doesn't exist

func DeleteFinOrg

func DeleteFinOrg(id int) (err error)

DeleteFinOrg deletes FinOrg by Id and returns error if the record to be deleted doesn't exist

func DeleteFinOrgMember

func DeleteFinOrgMember(id int) (err error)

DeleteFinOrgMember deletes FinOrgMember by Id and returns error if the record to be deleted doesn't exist

func DeleteLtvApp

func DeleteLtvApp(id int) (err error)

DeleteLtvApp deletes LtvApp by Id and returns error if the record to be deleted doesn't exist

func DeleteLtvFlight

func DeleteLtvFlight(id int) (err error)

DeleteLtvFlight deletes LtvFlight by Id and returns error if the record to be deleted doesn't exist

func DeleteLtvFlightGroup

func DeleteLtvFlightGroup(id int) (err error)

DeleteLtvFlightGroup deletes LtvFlightGroup by Id and returns error if the record to be deleted doesn't exist

func DeletePmpAdspace

func DeletePmpAdspace(id int) (err error)

DeletePmpAdspace deletes PmpAdspace by Id and returns error if the record to be deleted doesn't exist

func DeletePmpAdspaceMatrix

func DeletePmpAdspaceMatrix(id int) (err error)

DeletePmpAdspaceMatrix deletes PmpAdspaceMatrix by Id and returns error if the record to be deleted doesn't exist

func DeletePmpAdspaceMatrixByAdspaceIdAndDemandId

func DeletePmpAdspaceMatrixByAdspaceIdAndDemandId(demandid int, adspaceid int) (err error)

delete demand adspace mapping information by adspace id and demand id

func DeletePmpCampaignMatrix

func DeletePmpCampaignMatrix(id int) (err error)

DeletePmpCampaignMatrix deletes PmpCampaignMatrix by Id and returns error if the record to be deleted doesn't exist

func DeletePmpDailyAllocation

func DeletePmpDailyAllocation(id int) (err error)

DeletePmpDailyAllocation deletes PmpDailyAllocation by Id and returns error if the record to be deleted doesn't exist

func DeletePmpDailyAllocationDetail

func DeletePmpDailyAllocationDetail(id int) (err error)

DeletePmpDailyAllocationDetail deletes PmpDailyAllocationDetail by Id and returns error if the record to be deleted doesn't exist

func DeletePmpDailyReport

func DeletePmpDailyReport(id int) (err error)

DeletePmpDailyReport deletes PmpDailyReport by Id and returns error if the record to be deleted doesn't exist

func DeletePmpDailyRequestReport

func DeletePmpDailyRequestReport(id int) (err error)

DeletePmpDailyRequestReport deletes PmpDailyRequestReport by Id and returns error if the record to be deleted doesn't exist

func DeletePmpDemandAdspace

func DeletePmpDemandAdspace(id int) (err error)

DeletePmpDemandAdspace deletes PmpDemandAdspace by Id and returns error if the record to be deleted doesn't exist

func DeletePmpDemandDailyReport

func DeletePmpDemandDailyReport(id int) (err error)

DeletePmpDemandDailyReport deletes PmpDemandDailyReport by Id and returns error if the record to be deleted doesn't exist

func DeletePmpDemandPlatformDesk

func DeletePmpDemandPlatformDesk(id int) (err error)

DeletePmpDemandPlatformDesk deletes PmpDemandPlatformDesk by Id and returns error if the record to be deleted doesn't exist

func DeletePmpMedia

func DeletePmpMedia(id int) (err error)

DeletePmpMedia deletes PmpMedia by Id and returns error if the record to be deleted doesn't exist

func GetAllCampaignGroup

func GetAllCampaignGroup() []vo.PmpCampaignGroupVO

func GetAllFinBorrower

func GetAllFinBorrower(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllFinBorrower retrieves all FinBorrower matches certain condition. Returns empty list if no records exist

func GetAllFinBorrowerDetail

func GetAllFinBorrowerDetail(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllFinBorrowerDetail retrieves all FinBorrowerDetail matches certain condition. Returns empty list if no records exist

func GetAllFinLoanDeal

func GetAllFinLoanDeal(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllFinLoanDeal retrieves all FinLoanDeal matches certain condition. Returns empty list if no records exist

func GetAllFinLoanRequest

func GetAllFinLoanRequest(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllFinLoanRequest retrieves all FinLoanRequest matches certain condition. Returns empty list if no records exist

func GetAllFinLov

func GetAllFinLov(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllFinLov retrieves all FinLov matches certain condition. Returns empty list if no records exist

func GetAllFinOrg

func GetAllFinOrg(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllFinOrg retrieves all FinOrg matches certain condition. Returns empty list if no records exist

func GetAllFinOrgMember

func GetAllFinOrgMember(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllFinOrgMember retrieves all FinOrgMember matches certain condition. Returns empty list if no records exist

func GetAllLtvApp

func GetAllLtvApp(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllLtvApp retrieves all LtvApp matches certain condition. Returns empty list if no records exist

func GetAllLtvFlight

func GetAllLtvFlight(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllLtvFlight retrieves all LtvFlight matches certain condition. Returns empty list if no records exist

func GetAllLtvFlightGroup

func GetAllLtvFlightGroup(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllLtvFlightGroup retrieves all LtvFlightGroup matches certain condition. Returns empty list if no records exist

func GetAllPmpAdspace

func GetAllPmpAdspace(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpAdspace retrieves all PmpAdspace matches certain condition. Returns empty list if no records exist

func GetAllPmpAdspaceMatrix

func GetAllPmpAdspaceMatrix(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpAdspaceMatrix retrieves all PmpAdspaceMatrix matches certain condition. Returns empty list if no records exist

func GetAllPmpCampaignMatrix

func GetAllPmpCampaignMatrix(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpCampaignMatrix retrieves all PmpCampaignMatrix matches certain condition. Returns empty list if no records exist

func GetAllPmpDailyAllocation

func GetAllPmpDailyAllocation(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, count int64, err error)

GetAllPmpDailyAllocation retrieves all PmpDailyAllocation matches certain condition. Returns empty list if no records exist

func GetAllPmpDailyAllocationDetail

func GetAllPmpDailyAllocationDetail(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpDailyAllocationDetail retrieves all PmpDailyAllocationDetail matches certain condition. Returns empty list if no records exist

func GetAllPmpDailyReport

func GetAllPmpDailyReport(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpDailyReport retrieves all PmpDailyReport matches certain condition. Returns empty list if no records exist

func GetAllPmpDailyRequestReport

func GetAllPmpDailyRequestReport(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, count int64, err error)

GetAllPmpDailyRequestReport retrieves all PmpDailyRequestReport matches certain condition. Returns empty list if no records exist

func GetAllPmpDemandAdspace

func GetAllPmpDemandAdspace(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpDemandAdspace retrieves all PmpDemandAdspace matches certain condition. Returns empty list if no records exist

func GetAllPmpDemandDailyReport

func GetAllPmpDemandDailyReport(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpDemandDailyReport retrieves all PmpDemandDailyReport matches certain condition. Returns empty list if no records exist

func GetAllPmpDemandPlatformDesk

func GetAllPmpDemandPlatformDesk(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpDemandPlatformDesk retrieves all PmpDemandPlatformDesk matches certain condition. Returns empty list if no records exist

func GetAllPmpMedia

func GetAllPmpMedia(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpMedia retrieves all PmpMedia matches certain condition. Returns empty list if no records exist

func GetAllPmpProvince

func GetAllPmpProvince(query map[string]string, fields []string, sortby []string, order []string,
	offset int64, limit int64) (ml []interface{}, err error)

GetAllPmpProvince retrieves all PmpProvince matches certain condition. Returns empty list if no records exist

func GetFlightGroupSummaryList

func GetFlightGroupSummaryList(advertiserId string, flightGroupId string, sortby string, order string,
	offset int, limit int) (result []vo.LtvFlightGroupVO, count int, err error)

######## below are newly added functions

func GetPmpCampaignById

func GetPmpCampaignById(id int) (v vo.PmpCampaignVO)

GetPmpCampaignById retrieves PmpCampaign by Id.

func SaveOrCreateCampaign

func SaveOrCreateCampaign(campaignPageVo vo.CampaingnPageVO) (err error)

update or create a new campaign

func UpdateAdspaceMatrix

func UpdateAdspaceMatrix(v []DemandMappingVo) (err error)

update demand & adspace maps

func UpdateFinBorrowerById

func UpdateFinBorrowerById(m *FinBorrower) (err error)

UpdateFinBorrower updates FinBorrower by Id and returns error if the record to be updated doesn't exist

func UpdateFinBorrowerDetailById

func UpdateFinBorrowerDetailById(m *FinBorrowerDetail) (err error)

UpdateFinBorrowerDetail updates FinBorrowerDetail by Id and returns error if the record to be updated doesn't exist

func UpdateFinLoanDealById

func UpdateFinLoanDealById(m *FinLoanDeal) (err error)

UpdateFinLoanDeal updates FinLoanDeal by Id and returns error if the record to be updated doesn't exist

func UpdateFinLoanRequestById

func UpdateFinLoanRequestById(m *FinLoanRequest) (err error)

UpdateFinLoanRequest updates FinLoanRequest by Id and returns error if the record to be updated doesn't exist

func UpdateFinLovById

func UpdateFinLovById(m *FinLov) (err error)

UpdateFinLov updates FinLov by Id and returns error if the record to be updated doesn't exist

func UpdateFinOrgById

func UpdateFinOrgById(m *FinOrg) (err error)

UpdateFinOrg updates FinOrg by Id and returns error if the record to be updated doesn't exist

func UpdateFinOrgMemberById

func UpdateFinOrgMemberById(m *FinOrgMember) (err error)

UpdateFinOrgMember updates FinOrgMember by Id and returns error if the record to be updated doesn't exist

func UpdateImpByDemandAdpaceIdAndAdDate

func UpdateImpByDemandAdpaceIdAndAdDate(demandadspaceid int, proportion int, datestrs []string, imps []int, adspaceid int) (int64, error)

Update Imp by DemandAdspaceId and AdDate

func UpdateLtvAppById

func UpdateLtvAppById(m *LtvApp) (err error)

UpdateLtvApp updates LtvApp by Id and returns error if the record to be updated doesn't exist

func UpdateLtvFlightById

func UpdateLtvFlightById(m *LtvFlight) (err error)

UpdateLtvFlight updates LtvFlight by Id and returns error if the record to be updated doesn't exist

func UpdateLtvFlightGroupById

func UpdateLtvFlightGroupById(m *LtvFlightGroup) (err error)

UpdateLtvFlightGroup updates LtvFlightGroup by Id and returns error if the record to be updated doesn't exist

func UpdatePmpAdspace

func UpdatePmpAdspace(m *PmpAdspace) (err error)

only update mediaid, name and description

func UpdatePmpAdspaceAndMatrix

func UpdatePmpAdspaceAndMatrix(v *AdspaceVo) (err error)

update PmpAdspace

func UpdatePmpAdspaceById

func UpdatePmpAdspaceById(m *PmpAdspace) (err error)

UpdatePmpAdspace updates PmpAdspace by Id and returns error if the record to be updated doesn't exist

func UpdatePmpAdspaceMatrixById

func UpdatePmpAdspaceMatrixById(m *PmpAdspaceMatrix) (err error)

UpdatePmpAdspaceMatrix updates PmpAdspaceMatrix by Id and returns error if the record to be updated doesn't exist

func UpdatePmpCampaignById

func UpdatePmpCampaignById(m *PmpCampaign) (err error)

UpdatePmpCampaign updates PmpCampaign by Id and returns error if the record to be updated doesn't exist

func UpdatePmpCampaignMatrixById

func UpdatePmpCampaignMatrixById(m *PmpCampaignMatrix) (err error)

UpdatePmpCampaignMatrix updates PmpCampaignMatrix by Id and returns error if the record to be updated doesn't exist

func UpdatePmpDailyAllocationByDemandAdpaceId

func UpdatePmpDailyAllocationByDemandAdpaceId(demandadspaceid int, addate time.Time, imp int, clk int, ctr float32) (int64, error)

Update daily allocation

func UpdatePmpDailyAllocationById

func UpdatePmpDailyAllocationById(m *PmpDailyAllocation) (err error)

UpdatePmpDailyAllocation updates PmpDailyAllocation by Id and returns error if the record to be updated doesn't exist

func UpdatePmpDailyAllocationDetailById

func UpdatePmpDailyAllocationDetailById(m *PmpDailyAllocationDetail) (err error)

UpdatePmpDailyAllocationDetail updates PmpDailyAllocationDetail by Id and returns error if the record to be updated doesn't exist

func UpdatePmpDailyReportById

func UpdatePmpDailyReportById(m *PmpDailyReport) (err error)

UpdatePmpDailyReport updates PmpDailyReport by Id and returns error if the record to be updated doesn't exist

func UpdatePmpDailyRequestReportById

func UpdatePmpDailyRequestReportById(m *PmpDailyRequestReport) (err error)

UpdatePmpDailyRequestReport updates PmpDailyRequestReport by Id and returns error if the record to be updated doesn't exist

func UpdatePmpDemandAdspace

func UpdatePmpDemandAdspace(m *DemandAdspaceVo) (err error)

update pmp_demand_adspace by DemandAdspaceVo

func UpdatePmpDemandAdspaceById

func UpdatePmpDemandAdspaceById(m *PmpDemandAdspace) (err error)

UpdatePmpDemandAdspace updates PmpDemandAdspace by Id and returns error if the record to be updated doesn't exist

func UpdatePmpDemandDailyReportById

func UpdatePmpDemandDailyReportById(m *PmpDemandDailyReport) (err error)

UpdatePmpDemandDailyReport updates PmpDemandDailyReport by Id and returns error if the record to be updated doesn't exist

func UpdatePmpDemandPlatformDeskById

func UpdatePmpDemandPlatformDeskById(m *PmpDemandPlatformDesk) (err error)

UpdatePmpDemandPlatformDesk updates PmpDemandPlatformDesk by Id and returns error if the record to be updated doesn't exist

func UpdatePmpMediaById

func UpdatePmpMediaById(m *PmpMedia) (err error)

UpdatePmpMedia updates PmpMedia by Id and returns error if the record to be updated doesn't exist

Types

type AdspaceVo

type AdspaceVo struct {
	Id            int
	Name          string
	MediaName     string
	EstDaily      string
	DemandName    string
	DemandId      int
	MediaId       int
	SecretKey     string
	PmpAdspaceKey string
	Description   string
}

only contains the columns that need to be displayed in client

func GetAdspaceList

func GetAdspaceList(page int64, page_size int64, sort string, mediaid int, adspacename string) (adspaceVos []AdspaceVo, count int64)

get adspace list, may filtered by adspace name

type DemandAdspaceVo

type DemandAdspaceVo struct {
	Id             int
	Name           string
	DemandName     string
	DemandId       int
	SecretKey      string
	RealAdspaceKey string
}

only contains the columns that need to be displayed in client

func GetDemandAdspaceListByDemandId

func GetDemandAdspaceListByDemandId(page int64, page_size int64, sort string, demandid int, adspacename string) (adspaceVos []DemandAdspaceVo, count int64)

get demand adspace list by demand id , may filtered by adspace name

type DemandMappingVo

type DemandMappingVo struct {
	Id                int
	Name              string
	MappedAdspaceId   int
	MappedAdspaceName string
	Ck                int
	DemandName        string
	DemandId          int
}

func GetDemandsMappingInfo

func GetDemandsMappingInfo(page int64, page_size int64, sort string, name string, adspaceid int, demandid int) (v []DemandMappingVo, err error)

get the all the demands information to map to a specified adspace

type FinBorrower

type FinBorrower struct {
	Id           int    `orm:"column(id);auto"`
	SupplyOrgId  int    `orm:"column(supply_org_id);null"`
	Name         string `orm:"column(name);size(20);null"`
	IdNumber     string `orm:"column(id_number);size(20);null"`
	MobileNumber string `orm:"column(mobile_number);size(20);null"`
	Qq           string `orm:"column(qq);size(45);null"`
	LovGender    int8   `orm:"column(lov_gender);null"`
	DetailId     int    `orm:"column(detail_id);null"`
}

func GetFinBorrowerById

func GetFinBorrowerById(id int) (v *FinBorrower, err error)

GetFinBorrowerById retrieves FinBorrower by Id. Returns error if Id doesn't exist

type FinBorrowerDetail

type FinBorrowerDetail struct {
	Id                         int     `orm:"column(id);auto"`
	LovBorrowerIdentity        int8    `orm:"column(lov_borrower_identity)"`
	Age                        int     `orm:"column(age)"`
	BaseCityId                 int     `orm:"column(base_city_id)"`
	LovUnitType                int8    `orm:"column(lov_unit_type);null"`
	WorkDuration               int     `orm:"column(work_duration);null"`
	OperationDuration          int     `orm:"column(operation_duration);null"`
	BankMonthlyIncome          float32 `orm:"column(bank_monthly_income);null"`
	CashMonthlyIncome          float32 `orm:"column(cash_monthly_income);null"`
	BankMonthlyLiquity         float32 `orm:"column(bank_monthly_liquity);null"`
	SocialSecurityFundDuration int     `orm:"column(social_security_fund_duration);null"`
	HouseFundDuration          int     `orm:"column(house_fund_duration);null"`
	LovHouseType               int8    `orm:"column(lov_house_type)"`
	LovVehicleType             int8    `orm:"column(lov_vehicle_type)"`
	IsWorkInBaseCity           int8    `orm:"column(is_work_in_base_city)"`
	IsLiveInBaseCity           int8    `orm:"column(is_live_in_base_city)"`
	HasHouseCertificate        int8    `orm:"column(has_house_certificate);null"`
	PersonsOnHouseCertificate  int     `orm:"column(persons_on_house_certificate);null"`
	LovsHouseOwners            string  `orm:"column(lovs_house_owners);size(45);null"`
	LovHouseMortgageStatus     int8    `orm:"column(lov_house_mortgage_status);null"`
	HouseArea                  int     `orm:"column(house_area);null"`
	HousePrice                 int     `orm:"column(house_price);null"`
	BackupHouseNumber          int     `orm:"column(backup_house_number);null"`
	LovCarOwnerType            int8    `orm:"column(lov_car_owner_type);null"`
	LovCarMortgageType         int8    `orm:"column(lov_car_mortgage_type);null"`
	IsVehicleLicenseInBaseCity int8    `orm:"column(is_vehicle_license_in_base_city);null"`
	VehicleAge                 int     `orm:"column(vehicle_age);null"`
	VehiclePrice               float32 `orm:"column(vehicle_price);null"`
	LovCreditRecordType        int8    `orm:"column(lov_credit_record_type)"`
	IdCardPhotoFrontUrl        string  `orm:"column(id_card_photo_front_url);size(200);null"`
	IdCardPhotoBackUrl         string  `orm:"column(id_card_photo_back_url);size(200);null"`
	HouseCertificatePhotoUrl   string  `orm:"column(house_certificate_photo_url);size(200);null"`
	VehicleCertificatePhotoUrl string  `orm:"column(vehicle_certificate_photo_url);size(200);null"`
}

func GetFinBorrowerDetailById

func GetFinBorrowerDetailById(id int) (v *FinBorrowerDetail, err error)

GetFinBorrowerDetailById retrieves FinBorrowerDetail by Id. Returns error if Id doesn't exist

type FinLoanDeal

type FinLoanDeal struct {
	Id              int       `orm:"column(id);auto"`
	BorrowerId      int       `orm:"column(borrower_id)"`
	SupplyOrgId     int       `orm:"column(supply_org_id)"`
	DemandOrgId     int       `orm:"column(demand_org_id)"`
	LovDealStatus   int8      `orm:"column(lov_deal_status)"`
	LoanAmount      float32   `orm:"column(loan_amount);null"`
	LovDurationType int8      `orm:"column(lov_duration_type);null"`
	Duration        int       `orm:"column(duration);null"`
	LovReturnMethod int8      `orm:"column(lov_return_method);null"`
	FirstDueDate    time.Time `orm:"column(first_due_date);type(date);null"`
	LastDueDate     time.Time `orm:"column(last_due_date);type(date);null"`
	Remark          string    `orm:"column(remark);size(500);null"`
	LovLoanType     int8      `orm:"column(lov_loan_type);null"`
}

func GetFinLoanDealById

func GetFinLoanDealById(id int) (v *FinLoanDeal, err error)

GetFinLoanDealById retrieves FinLoanDeal by Id. Returns error if Id doesn't exist

type FinLoanRequest

type FinLoanRequest struct {
	Id                   int     `orm:"column(id);auto"`
	SupplyOrgId          int     `orm:"column(supply_org_id)"`
	SupplyOrgMemberId    int     `orm:"column(supply_org_member_id);null"`
	BorrowerId           int     `orm:"column(borrower_id)"`
	RequestLoanAmount    float32 `orm:"column(request_loan_amount)"`
	LovDurationType      int8    `orm:"column(lov_duration_type)"`
	Duration             int     `orm:"column(duration)"`
	LovLoanUsage         int8    `orm:"column(lov_loan_usage)"`
	IsHouseMortageable   int8    `orm:"column(is_house_mortageable)"`
	IsVehicleMortageable int8    `orm:"column(is_vehicle_mortageable)"`
	LovAuditStatus       int8    `orm:"column(lov_audit_status)"`
	Remartk              string  `orm:"column(remartk);size(500);null"`
}

func GetFinLoanRequestById

func GetFinLoanRequestById(id int) (v *FinLoanRequest, err error)

GetFinLoanRequestById retrieves FinLoanRequest by Id. Returns error if Id doesn't exist

type FinLov

type FinLov struct {
	Id        int    `orm:"column(id);auto"`
	LovKey    string `orm:"column(lov_key);size(20)"`
	LovId     int8   `orm:"column(lov_id)"`
	LovValue  string `orm:"column(lov_value);size(45);null"`
	DispOrder int    `orm:"column(disp_order);null"`
}

func GetFinLovById

func GetFinLovById(id int) (v *FinLov, err error)

GetFinLovById retrieves FinLov by Id. Returns error if Id doesn't exist

type FinOrg

type FinOrg struct {
	Id                  int    `orm:"column(id);auto"`
	Name                string `orm:"column(name);size(100)"`
	LovOrgType          int8   `orm:"column(lov_org_type)"`
	Address             string `orm:"column(address);size(200);null"`
	OrgPhoneNumber      string `orm:"column(org_phone_number);size(20);null"`
	ContactName         string `orm:"column(contact_name);size(20);null"`
	ContactMobileNumber string `orm:"column(contact_mobile_number);size(20);null"`
	BaseCityId          int    `orm:"column(base_city_id);null"`
	OrgLicenseNumber    string `orm:"column(org_license_number);size(45);null"`
	OrgLicensePhotoUrl  string `orm:"column(org_license_photo_url);size(200);null"`
}

func GetFinOrgById

func GetFinOrgById(id int) (v *FinOrg, err error)

GetFinOrgById retrieves FinOrg by Id. Returns error if Id doesn't exist

type FinOrgMember

type FinOrgMember struct {
	Id           int    `orm:"column(id);auto"`
	OrgId        int    `orm:"column(org_id)"`
	DisplayName  string `orm:"column(display_name);size(45)"`
	MobileNumber string `orm:"column(mobile_number);size(20);null"`
	IdNumber     string `orm:"column(id_number);size(20);null"`
	UserId       int    `orm:"column(user_id);null"`
}

func GetFinOrgMemberById

func GetFinOrgMemberById(id int) (v *FinOrgMember, err error)

GetFinOrgMemberById retrieves FinOrgMember by Id. Returns error if Id doesn't exist

type LtvApp

type LtvApp struct {
	Id          int    `orm:"column(id);auto"`
	Name        string `orm:"column(name);size(45)"`
	Pkgname     string `orm:"column(pkgname);size(100);null"`
	AppKey      string `orm:"column(app_key);size(45);null"`
	SecurityKey string `orm:"column(security_key);size(45);null"`
}

func GetLtvAppById

func GetLtvAppById(id int) (v *LtvApp, err error)

GetLtvAppById retrieves LtvApp by Id. Returns error if Id doesn't exist

func (*LtvApp) TableName

func (t *LtvApp) TableName() string

type LtvFlight

type LtvFlight struct {
	Id              int     `orm:"column(id);auto"`
	GroupId         int     `orm:"column(group_id)"`
	Name            string  `orm:"column(name);size(45)"`
	Budget          float32 `orm:"column(budget);null"`
	Spending        float32 `orm:"column(spending);null"`
	Cost            float32 `orm:"column(cost);null"`
	Imp             int     `orm:"column(imp);null"`
	Clk             int     `orm:"column(clk);null"`
	Install         int     `orm:"column(install);null"`
	PostbackInstall int     `orm:"column(postback_install);null"`
	Register        int     `orm:"column(register);null"`
	Submit          int     `orm:"column(submit);null"`
	Conversion      int     `orm:"column(conversion);null"`
	Revenue         float32 `orm:"column(revenue);null"`
	ECPA            float32 `orm:"column(eCPA);null"`
	DelFlg          int8    `orm:"column(del_flg)"`
	SpreadUrl       string  `orm:"column(spread_url);size(500);null"`
	SpreadName      string  `orm:"column(spread_name);size(45);null"`

	LtvApp *LtvApp `orm:"rel(fk);"`
}

func GetLtvFlightById

func GetLtvFlightById(id int) (v *LtvFlight, err error)

GetLtvFlightById retrieves LtvFlight by Id. Returns error if Id doesn't exist

func (*LtvFlight) TableName

func (t *LtvFlight) TableName() string

type LtvFlightGroup

type LtvFlightGroup struct {
	Id     int     `orm:"column(id);auto"`
	Name   string  `orm:"column(name);size(45)"`
	Budget float32 `orm:"column(budget)"`
}

func GetLtvFlightGroupById

func GetLtvFlightGroupById(id int) (v *LtvFlightGroup, err error)

GetLtvFlightGroupById retrieves LtvFlightGroup by Id. Returns error if Id doesn't exist

func (*LtvFlightGroup) TableName

func (t *LtvFlightGroup) TableName() string

type PdbDemandReportVo

type PdbDemandReportVo struct {
	AdDate            time.Time `orm:"column(ad_date);type(datetime);"`
	DemandId          string    `orm:"column(demand_id);"`
	DemandName        string    `orm:"column(demand_name);"`
	DemandAdSpaceId   string    `orm:"column(demand_adspace_id);"`
	DemandAdSpaceName string    `orm:"column(demand_adspace_name);"`
	PdbMediaId        string    `orm:"column(pmp_media_id);"`
	PdbMediaName      string    `orm:"column(pmp_media_name);"`
	PdbAdSpaceId      string    `orm:"column(pmp_adspace_id);"`
	PdbAdSpaceName    string    `orm:"column(pmp_adspace_id);"`
	ReqSuccess        int       `orm:"column(req_success);"`
	ReqError          int       `orm:"column(req_error);"`
	ReqTimeout        int       `orm:"column(req_timeout);"`
	ReqNoad           int       `orm:"column(req_noad);"`
	Imp               int       `orm:"column(imp);"`
	Clk               int       `orm:"column(clk);"`

	Ctr float32 `orm:"-"`

	ReqAll   int     `orm:"-"`
	FillRate float32 `orm:"-"`
}

func GetGroupedPmpDemandDailyReport

func GetGroupedPmpDemandDailyReport(groupFields []string, medias []string, startDate time.Time, endDate time.Time, sortby string, order string,
	offset int, limit int) (ml []PdbDemandReportVo, count int, err error)

*

groupFields might be:
1. nil,
2. ["0"]
3. ["1"]
4 ["0", "1"]

0 表示 PDB广告位
1 表示 日期

type PdbMediaReportVo

type PdbMediaReportVo struct {
	PmpAdSpaceId   string    `orm:"column(pmp_adspace_id);"`
	PdbAdSpaceName string    `orm:"column(pmp_adspace_name);"`
	AdDate         time.Time `orm:"column(ad_date);type(datetime);"`
	PmpMediaId     string    `orm:"column(pmp_media_id);"`
	PdbMediaName   string    `orm:"column(pmp_media_name);"`
	ReqSuccess     int       `orm:"column(req_success);"`
	ReqNoad        int       `orm:"column(req_noad);"`
	ReqError       int       `orm:"column(req_error);"`

	ReqAll   int     `orm:"-"`
	FillRate float32 `orm:"-"`
}

func GetGroupedPmpDailyRequestReport

func GetGroupedPmpDailyRequestReport(groupFields []string, medias []string, startDate time.Time, endDate time.Time, sortby string, order string,
	offset int, limit int) (ml []PdbMediaReportVo, count int, err error)

*

groupFields might be:
1. nil,
2. ["0"]
3. ["1"]
4 ["0", "1"]

0 表示 PDB广告位
1 表示 日期

type PmpAdCategory

type PmpAdCategory struct {
	Id       int    `orm:"column(id);auto"`
	Name     string `orm:"column(name);size(45)"`
	ParentId int    `orm:"column(parent_id);null"`
}

func GetPmpAdCategoryByParentId

func GetPmpAdCategoryByParentId(parentId int) (categorys []*PmpAdCategory, count int64)

Get the categorys by id of parent category

func GetPmpAdCategoryOne

func GetPmpAdCategoryOne() (categorys []*PmpAdCategory, count int64)

Get the categorys in first level

func (*PmpAdCategory) TableName

func (t *PmpAdCategory) TableName() string

type PmpAdspace

type PmpAdspace struct {
	Id            int       `orm:"column(id);auto"`
	Name          string    `orm:"column(name);size(255)"`
	Description   string    `orm:"column(description);size(500);null"`
	DelFlg        int8      `orm:"column(del_flg);default(0)"`
	CreateUser    int       `orm:"column(create_user);null"`
	CreateTime    time.Time `orm:"column(create_time);type(timestamp);null"`
	UpdateUser    int       `orm:"column(update_user);null"`
	UpdateTime    time.Time `orm:"column(update_time);type(timestamp);null"`
	PmpAdspaceKey string    `orm:"column(pmp_adspace_key);size(50);null"`
	SecretKey     string    `orm:"column(secret_key);size(50);null"`
	MediaId       int       `orm:"column(media_id);null"`
	EstDailyImp   int       `orm:"column(est_daily_imp);null"`
	EstDailyClk   int       `orm:"column(est_daily_clk);null"`
	EstDailyCtr   float32   `orm:"column(est_daily_ctr);null"`
	Status        int       `orm:"default(1)" form:"Status" valid:"Range(1,2)"`
	CreativeType  int       `orm:"default(1)" form:"CreativeType" valid:"Range(1,2)"`
	TplName       string    `orm:"column(tpl_name);size(20);null"`
	ForeverFlg    int       `orm:"column(forever_flg);null"`
	Cpm           float32   `orm:"column(cpm);null"`
	Cpc           float32   `orm:"column(cpc);null"`
	PricingType   int       `orm:"column(pricing_type);null"`
}

func GetPmpAdspaceById

func GetPmpAdspaceById(id int) (v *PmpAdspace, err error)

GetPmpAdspaceById retrieves PmpAdspace by Id. Returns error if Id doesn't exist

func (*PmpAdspace) TableName

func (t *PmpAdspace) TableName() string

type PmpAdspaceMatrix

type PmpAdspaceMatrix struct {
	Id              int `orm:"column(id);auto"`
	PmpAdspaceId    int `orm:"column(pmp_adspace_id)"`
	DemandId        int `orm:"column(demand_id);null"`
	DemandAdspaceId int `orm:"column(demand_adspace_id);null"`
	Priority        int `orm:"column(priority);null"`
}

func GetPmpAdspaceMatrixByDemandIdAndAdspaceId

func GetPmpAdspaceMatrixByDemandIdAndAdspaceId(demandid int, adspaceid int) (v *PmpAdspaceMatrix, err error)

Get PmpAdspaceMatrix by demand id and adspace id

func GetPmpAdspaceMatrixByDemandSpaceId

func GetPmpAdspaceMatrixByDemandSpaceId(pmpDemandSpaceId int) (v *PmpAdspaceMatrix, err error)

Retrieves PmpAdspaceMatrix by PmpDemandSpaceId. Returns error if pmpDemandSpaceId doesn't exist

func GetPmpAdspaceMatrixById

func GetPmpAdspaceMatrixById(id int) (v *PmpAdspaceMatrix, err error)

GetPmpAdspaceMatrixById retrieves PmpAdspaceMatrix by Id. Returns error if Id doesn't exist

func (*PmpAdspaceMatrix) TableName

func (t *PmpAdspaceMatrix) TableName() string

type PmpCampaign

type PmpCampaign struct {
	Id              int       `orm:"column(id);auto"`
	GroupId         int       `orm:"column(group_id)"`
	Name            string    `orm:"column(name);size(45)"`
	StartDate       time.Time `orm:"column(start_date);type(date);null"`
	EndDate         time.Time `orm:"column(end_date);type(date);null"`
	CampaignStatus  int       `orm:"column(campaign_status)"`
	DemandAdspaceId int       `orm:"column(demand_adspace_id)"`
	ImpTrackingUrl  string    `orm:"column(imp_tracking_url);size(1000);null"`
	ClkTrackingUrl  string    `orm:"column(clk_tracking_url);size(1000);null"`
	LandingUrl      string    `orm:"column(landing_url);size(1000);null"`
	AdType          int       `orm:"column(ad_type);null"`
	CampaignType    int       `orm:"column(campaign_type);null"`
	AccurateType    int       `orm:"column(accurate_type);null"`
	PricingType     int       `orm:"column(pricing_type);null"`
	StrategyType    int       `orm:"column(strategy_type);null"`
	BudgetType      int       `orm:"column(budget_type);null"`
	Budget          int       `orm:"column(budget);null"`
	BidPrice        float32   `orm:"column(bid_price);null"`
	AdCategory      int       `orm:"column(ad_category);null"`
}

func (*PmpCampaign) ParseDate

func (this *PmpCampaign) ParseDate(datestr string) (date time.Time, err error)

func (*PmpCampaign) TableName

func (t *PmpCampaign) TableName() string

type PmpCampaignCreative

type PmpCampaignCreative struct {
	Id             int    `orm:"column(id);auto"`
	CampaignId     int    `orm:"column(campaign_id)"`
	Name           string `orm:"column(name);size(45);null"`
	Width          int    `orm:"column(width);null"`
	Height         int    `orm:"column(height);null"`
	CreativeUrl    string `orm:"column(creative_url);size(255);null"`
	CreativeStatus int    `orm:"column(creative_status);null"`
	LandingUrl     string `orm:"column(landing_url);size(500);null"`
	ImpTrackingUrl string `orm:"column(imp_tracking_url);size(1000);null"`
	ClkTrackingUrl string `orm:"column(clk_tracking_url);size(1000)"`
	DisplayTitle   string `orm:"column(display_title);size(200);null"`
	DisplayText    string `orm:"column(display_text);size(1000);null"`
}

func (*PmpCampaignCreative) TableName

func (t *PmpCampaignCreative) TableName() string

type PmpCampaignDailyConfig

type PmpCampaignDailyConfig struct {
	Id          int    `orm:"column(id);auto"`
	CampaignId  int    `orm:"column(campaign_id)"`
	WeekDay     int    `orm:"column(week_day)"`
	TargetHours string `orm:"column(target_hours);size(100);null"`
}

func (*PmpCampaignDailyConfig) TableName

func (t *PmpCampaignDailyConfig) TableName() string

type PmpCampaignDailyReportVo

type PmpCampaignDailyReportVo struct {
	AdDate    time.Time `orm:"column(ad_date);type(datetime);"`
	Name      string    `orm:"column(name)"`
	GroupName string    `orm:"column(group_name)"`
	Imp       int       `orm:"column(imp);null"`
	Clk       int       `orm:"column(clk);null"`
	Ctr       float32   `orm:"column(ctr);null"`
	Ecpm      float32   `orm:"column(ecpm);null"`
	Ecpc      float32   `orm:"column(ecpc);null"`
	Spending  float32   `orm:"column(spending);null"`
	Cost      float32   `orm:"column(cost);null"`
}

func GetPmpCampaignDailyReport

func GetPmpCampaignDailyReport(groupField string, medias []string, startDate time.Time, endDate time.Time, sortby string, order string,
	offset int, limit int) (ml []PmpCampaignDailyReportVo, count int, err error)

*

groupFields might be:
1. nil,
2. ["0"]
3. ["1"]
4 ["0", "1"]

0 表示 PDB广告位
1 表示 日期

type PmpCampaignGroup

type PmpCampaignGroup struct {
	Id           int    `orm:"column(id);auto"`
	AdvertiserId int    `orm:"column(advertiser_Id)"`
	Name         string `orm:"column(name);size(50)"`
	Budget       int    `orm:"column(budget)"`
}

func (*PmpCampaignGroup) TableName

func (t *PmpCampaignGroup) TableName() string

type PmpCampaignMatrix

type PmpCampaignMatrix struct {
	Id            int `orm:"column(id);auto"`
	PmpCampaignId int `orm:"column(pmp_campaign_id);null"`
	PmpAdspaceId  int `orm:"column(pmp_adspace_id);null"`
}

func GetPmpCampaignMatrixById

func GetPmpCampaignMatrixById(id int) (v *PmpCampaignMatrix, err error)

GetPmpCampaignMatrixById retrieves PmpCampaignMatrix by Id. Returns error if Id doesn't exist

func (*PmpCampaignMatrix) TableName

func (t *PmpCampaignMatrix) TableName() string

type PmpCampaignTargeting

type PmpCampaignTargeting struct {
	Id            int    `orm:"column(id);auto"`
	CampaignId    int    `orm:"column(campaign_id)"`
	TargetingType string `orm:"column(targeting_type);size(45);null"`
	TargetingId   int    `orm:"column(targeting_id);null"`
}

func (*PmpCampaignTargeting) TableName

func (t *PmpCampaignTargeting) TableName() string

type PmpCity

type PmpCity struct {
	Id         int    `orm:"column(city_id);pk"`
	CityName   string `orm:"column(city_name);size(50);null"`
	Zipcode    string `orm:"column(zipcode);size(50);null"`
	ProvinceId int64  `orm:"column(province_id);null"`
}

func (*PmpCity) TableName

func (t *PmpCity) TableName() string

type PmpDailyAllocation

type PmpDailyAllocation struct {
	Id              int       `orm:"column(id);auto"`
	AdDate          time.Time `orm:"column(ad_date);type(date);null"`
	DemandAdspaceId int       `orm:"column(demand_adspace_id);null"`
	Imp             int       `orm:"column(imp);null"`
	Clk             int       `orm:"column(clk);null"`
	Ctr             float32   `orm:"column(ctr);null"`
	PmpAdspaceId    int       `orm:"column(pmp_adspace_id)"`
}

func GetPmpDailyAllocationById

func GetPmpDailyAllocationById(id int) (v *PmpDailyAllocation, err error)

GetPmpDailyAllocationById retrieves PmpDailyAllocation by Id. Returns error if Id doesn't exist

func (*PmpDailyAllocation) TableName

func (t *PmpDailyAllocation) TableName() string

type PmpDailyAllocationDetail

type PmpDailyAllocationDetail struct {
	Id           int     `orm:"column(id);auto"`
	AllocationId int     `orm:"column(allocation_id);null"`
	ProvinceCode string  `orm:"column(province_code);size(20);null"`
	Imp          int     `orm:"column(imp);null"`
	Clk          int     `orm:"column(clk);null"`
	Ctr          float32 `orm:"column(ctr);null"`
}

func GetPmpDailyAllocationDetailById

func GetPmpDailyAllocationDetailById(id int) (v *PmpDailyAllocationDetail, err error)

GetPmpDailyAllocationDetailById retrieves PmpDailyAllocationDetail by Id. Returns error if Id doesn't exist

func (*PmpDailyAllocationDetail) TableName

func (t *PmpDailyAllocationDetail) TableName() string

type PmpDailyAllocationVo

type PmpDailyAllocationVo struct {
	Name              string
	DemandAdspaceId   int
	AdDate            time.Time
	Imp               int
	Clk               int
	Ctr               float32
	Priority          int
	DemandAdspaceName string
}

func GetPmpDailyAllocationByAdspaceIdAndAdDate

func GetPmpDailyAllocationByAdspaceIdAndAdDate(adspaceid int, startdate string, enddate string) []PmpDailyAllocationVo

Query PmpDailyAllocation

type PmpDailyReport

type PmpDailyReport struct {
	Id              int       `orm:"column(id);auto"`
	PmpAdspaceId    int       `orm:"column(pmp_adspace_id);null"`
	DemandAdspaceId int       `orm:"column(demand_adspace_id);null"`
	AdDate          time.Time `orm:"column(ad_date);type(date);null"`
	Imp             int       `orm:"column(imp);null"`
	Clk             int       `orm:"column(clk);null"`
	Ctr             float32   `orm:"column(ctr);null"`
	CreateUser      int       `orm:"column(createUser);null"`
	CreateTime      time.Time `orm:"column(createTime);type(timestamp);null"`
	UpdateUser      int       `orm:"column(updateUser);null"`
	UpdateTime      time.Time `orm:"column(updateTime);type(timestamp);null;auto_now"`
}

func GetPmpDailyReportById

func GetPmpDailyReportById(id int) (v *PmpDailyReport, err error)

GetPmpDailyReportById retrieves PmpDailyReport by Id. Returns error if Id doesn't exist

func (*PmpDailyReport) TableName

func (t *PmpDailyReport) TableName() string

type PmpDailyRequestReport

type PmpDailyRequestReport struct {
	Id           int       `orm:"column(id);auto"`
	AdDate       time.Time `orm:"column(ad_date);type(date);null"`
	PmpAdspaceId int       `orm:"column(pmp_adspace_id);null"`
	ReqSuccess   int       `orm:"column(req_success);null"`
	ReqNoad      int       `orm:"column(req_noad);null"`
	ReqError     int       `orm:"column(req_error);null"`
	FillRate     float32   `orm:"column(fill_rate);null"`
}

func GetPmpDailyRequestReportById

func GetPmpDailyRequestReportById(id int) (v *PmpDailyRequestReport, err error)

GetPmpDailyRequestReportById retrieves PmpDailyRequestReport by Id. Returns error if Id doesn't exist

func (*PmpDailyRequestReport) TableName

func (t *PmpDailyRequestReport) TableName() string

type PmpDemandAdspace

type PmpDemandAdspace struct {
	Id               int       `orm:"column(id);auto"`
	Name             string    `orm:"column(name);size(255)"`
	DelFlg           int8      `orm:"column(del_flg);default(0)"`
	CreateUser       int       `orm:"column(create_user);null"`
	CreateTime       time.Time `orm:"column(create_time);type(timestamp);null"`
	UpdateUser       int       `orm:"column(update_user);null"`
	UpdateTime       time.Time `orm:"column(update_time);type(timestamp);null"`
	SecretKey        string    `orm:"column(secret_key);size(50);null"`
	RealAdspaceKey   string    `orm:"column(real_adspace_key);size(50);not null"`
	DemandAdspaceKey string    `orm:"column(demand_adspace_key);size(50);not null;unique"`
	DemandId         int       `orm:"column(demand_id)"`
	AppId            int       `orm:"column(app_id);null"`
	AdspaceType      int       `orm:"column(adspace_type);null"`
	Cpm              float32   `orm:"column(cpm);null"`
	Cpc              float32   `orm:"column(cpc);null"`
	PricingType      int       `orm:"column(pricing_type)";null`
}

func GetPmpDemandAdspaceById

func GetPmpDemandAdspaceById(id int) (v *PmpDemandAdspace, err error)

GetPmpDemandAdspaceById retrieves PmpDemandAdspace by Id. Returns error if Id doesn't exist

func (*PmpDemandAdspace) TableName

func (t *PmpDemandAdspace) TableName() string

type PmpDemandDailyReport

type PmpDemandDailyReport struct {
	Id              int       `orm:"column(id);auto"`
	DemandAdspaceId int       `orm:"column(demand_adspace_id);null"`
	AdDate          time.Time `orm:"column(ad_date);type(date);null"`
	ReqSuccess      int       `orm:"column(req_success);null"`
	ReqTimeout      int       `orm:"column(req_timeout);null"`
	ReqNoad         int       `orm:"column(req_noad);null"`
	ReqError        int       `orm:"column(req_error);null"`
}

func GetPmpDemandDailyReportById

func GetPmpDemandDailyReportById(id int) (v *PmpDemandDailyReport, err error)

GetPmpDemandDailyReportById retrieves PmpDemandDailyReport by Id. Returns error if Id doesn't exist

func (*PmpDemandDailyReport) TableName

func (t *PmpDemandDailyReport) TableName() string

type PmpDemandPlatformDesk

type PmpDemandPlatformDesk struct {
	Id                 int       `orm:"column(id);auto"`
	Name               string    `orm:"column(name);size(255)"`
	RequestUrlTemplate string    `orm:"column(request_url_template);size(500);null"`
	DelFlg             int8      `orm:"column(del_flg);null"`
	CreateUser         int       `orm:"column(create_user);null"`
	CreateTime         time.Time `orm:"column(create_time);type(timestamp);null"`
	UpdateUser         int       `orm:"column(update_user);null"`
	UpdateTime         time.Time `orm:"column(update_time);type(timestamp);null"`
	Timeout            int       `orm:"column(timeout)"`
	InvokeFuncName     string    `orm:"column(invoke_func_name);size(20)"`
}

func GetDemandList

func GetDemandList(page int64, page_size int64, sort string, name string) (demands []PmpDemandPlatformDesk, count int64)

Get demand list

func GetPmpDemandPlatformDeskById

func GetPmpDemandPlatformDeskById(id int) (v *PmpDemandPlatformDesk, err error)

GetPmpDemandPlatformDeskById retrieves PmpDemandPlatformDesk by Id. Returns error if Id doesn't exist

func (*PmpDemandPlatformDesk) TableName

func (t *PmpDemandPlatformDesk) TableName() string

type PmpLov

type PmpLov struct {
	Id        int    `orm:"column(id);auto"`
	LovCode   string `orm:"column(lov_code);size(45)"`
	LovKey    int    `orm:"column(lov_key)"`
	LovValue  string `orm:"column(lov_value);size(45)"`
	DispOrder int    `orm:"column(disp_order);null"`
}

func GetAllPmpLov

func GetAllPmpLov() (lovs []PmpLov, err error)

get all the lov key-value maps

func GetPmpLovByCode

func GetPmpLovByCode(code string) (lovs []*PmpLov, err error)

get all the lov key-value maps, filtered by lov code

func (*PmpLov) TableName

func (t *PmpLov) TableName() string

type PmpMedia

type PmpMedia struct {
	Id          int       `orm:"column(id);auto"`
	Name        string    `orm:"column(name);size(255)"`
	Description string    `orm:"column(description);size(500);null"`
	DelFlg      int8      `orm:"column(del_flg);null"`
	CreateUser  int       `orm:"column(create_user);null"`
	CreateTime  time.Time `orm:"column(create_time);type(timestamp);null"`
	UpdateUser  int       `orm:"column(update_user);null"`
	UpdateTime  time.Time `orm:"column(update_time);type(timestamp);null"`
}

func GetMediaList

func GetMediaList(page int64, page_size int64, sort string, name string) (medias []PmpMedia, count int64)

Get media list

func GetPmpMediaById

func GetPmpMediaById(id int) (v *PmpMedia, err error)

GetPmpMediaById retrieves PmpMedia by Id. Returns error if Id doesn't exist

func (*PmpMedia) TableName

func (t *PmpMedia) TableName() string

type PmpProvince

type PmpProvince struct {
	Id           int    `orm:"column(province_id);pk"`
	ProvinceName string `orm:"column(province_name);size(50);null"`
}

func (*PmpProvince) TableName

func (t *PmpProvince) TableName() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL