本文整理汇总了PHP中CRMEntity::save方法的典型用法代码示例。如果您正苦于以下问题:PHP CRMEntity::save方法的具体用法?PHP CRMEntity::save怎么用?PHP CRMEntity::save使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CRMEntity
的用法示例。
在下文中一共展示了CRMEntity::save方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: save
function save($module)
{
global $app_strings;
global $product_seqprefix;
if ($this->column_fields['productcode'] == $app_strings["AUTO_GEN_CODE"] || $this->column_fields['productcode'] == '') {
$this->column_fields['productcode'] = $product_seqprefix . $this->get_next_id();
}
if (isset($_SESSION['import_overwrite2']) && $_SESSION['import_overwrite2'] == 1) {
if (!empty($this->column_fields['productcode'])) {
$where_clause = " and ec_products.productcode='" . trim($this->column_fields['productcode']) . "' ";
$query = "SELECT ec_products.productid FROM ec_products where ec_products.deleted=0 {$where_clause}";
$result =& $this->db->query($query, false, "Retrieving record {$where_clause}");
if ($this->db->getRowCount($result) >= 1) {
/*$productid = $this->db->query_result($result,0,"productid");
$this->id = $productid;
$this->mode = 'edit';
CRMEntity::save($module);*/
} else {
$this->id = "";
$this->mode = '';
CRMEntity::save($module);
}
}
} else {
$this->id = "";
$this->mode = '';
CRMEntity::save($module);
}
$this->ClearColumnFields();
}
示例2: save
function save($module)
{
$this->id = "";
$this->mode = '';
CRMEntity::save($module);
}
示例3: save
function save($module)
{
global $adb;
if ($this->mode == 'edit') {
$rs = $adb->pquery('select sales_stage from vtiger_potential where potentialid = ?', array($this->id));
$this->sales_stage = $adb->query_result($rs, 0, 'sales_stage');
}
parent::save($module);
}