Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
f77e3b4b
Commit
f77e3b4b
authored
Dec 26, 2013
by
Qiang Xue
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes #1611: Added `BaseActiveRecord::markAttributeDirty()`
parent
3fff4e03
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
0 deletions
+12
-0
CHANGELOG.md
framework/CHANGELOG.md
+1
-0
BaseActiveRecord.php
framework/yii/db/BaseActiveRecord.php
+11
-0
No files found.
framework/CHANGELOG.md
View file @
f77e3b4b
...
...
@@ -29,6 +29,7 @@ Yii Framework 2 Change Log
-
Enh #1579: throw exception when the given AR relation name does not match in a case sensitive manner (qiangxue)
-
Enh #1581: Added
`ActiveQuery::joinWith()`
and
`ActiveQuery::innerJoinWith()`
to support joining with relations (qiangxue)
-
Enh #1601: Added support for tagName and encodeLabel parameters in ButtonDropdown (omnilight)
-
Enh #1611: Added
`BaseActiveRecord::markAttributeDirty()`
(qiangxue)
-
Enh: Added
`favicon.ico`
and
`robots.txt`
to defauly application templates (samdark)
-
Enh: Added
`Widget::autoIdPrefix`
to support prefixing automatically generated widget IDs (qiangxue)
-
Enh: Support for file aliases in console command 'message' (omnilight)
...
...
framework/yii/db/BaseActiveRecord.php
View file @
f77e3b4b
...
...
@@ -494,6 +494,17 @@ abstract class BaseActiveRecord extends Model implements ActiveRecordInterface
}
/**
* Marks an attribute dirty.
* This method may be called to force updating a record when calling [[update()]],
* even if there is no change being made to the record.
* @param string $name the attribute name
*/
public
function
markAttributeDirty
(
$name
)
{
unset
(
$this
->
_oldAttributes
[
$name
]);
}
/**
* Returns a value indicating whether the named attribute has been changed.
* @param string $name the name of the attribute
* @return boolean whether the attribute has been changed
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment