[fix] in_standard_filter should be in docfield, not doctype
This commit is contained in:
parent
f124354250
commit
8f6d3d9a11
5 changed files with 13 additions and 5 deletions
|
|
@ -47,6 +47,7 @@ CREATE TABLE `tabDocField` (
|
|||
`description` text,
|
||||
`in_filter` int(1) NOT NULL DEFAULT 0,
|
||||
`in_list_view` int(1) NOT NULL DEFAULT 0,
|
||||
`in_standard_filter` int(1) NOT NULL DEFAULT 0,
|
||||
`read_only` int(1) NOT NULL DEFAULT 0,
|
||||
`precision` varchar(255) DEFAULT NULL,
|
||||
`length` int(11) NOT NULL DEFAULT 0,
|
||||
|
|
@ -152,7 +153,6 @@ CREATE TABLE `tabDocType` (
|
|||
`_user_tags` varchar(255) DEFAULT NULL,
|
||||
`custom` int(1) NOT NULL DEFAULT 0,
|
||||
`beta` int(1) NOT NULL DEFAULT 0,
|
||||
`in_standard_filter` int(1) NOT NULL DEFAULT 0,
|
||||
`image_view` int(1) NOT NULL DEFAULT 0,
|
||||
PRIMARY KEY (`name`),
|
||||
KEY `parent` (`parent`)
|
||||
|
|
|
|||
|
|
@ -191,9 +191,9 @@ class BaseDocument(object):
|
|||
if df:
|
||||
if df.fieldtype=="Check":
|
||||
if d[fieldname]==None:
|
||||
d[fieldname] = df.get('default') or 0
|
||||
d[fieldname] = 0
|
||||
|
||||
if (not isinstance(d[fieldname], int) or d[fieldname] > 1):
|
||||
elif (not isinstance(d[fieldname], int) or d[fieldname] > 1):
|
||||
d[fieldname] = 1 if cint(d[fieldname]) else 0
|
||||
|
||||
elif df.fieldtype=="Int" and not isinstance(d[fieldname], int):
|
||||
|
|
@ -285,6 +285,7 @@ class BaseDocument(object):
|
|||
self.created_by = self.modifield_by = frappe.session.user
|
||||
|
||||
d = self.get_valid_dict()
|
||||
|
||||
columns = d.keys()
|
||||
try:
|
||||
frappe.db.sql("""insert into `tab{doctype}`
|
||||
|
|
|
|||
|
|
@ -28,6 +28,9 @@
|
|||
.filter-header .sort-dropdown {
|
||||
margin-top: -20px;
|
||||
}
|
||||
.filter-header .dropdown-menu {
|
||||
min-width: 150px !important;
|
||||
}
|
||||
.filter-label {
|
||||
margin: 0px;
|
||||
padding: 5px;
|
||||
|
|
|
|||
|
|
@ -6,9 +6,9 @@
|
|||
style="margin-right: 25px;">
|
||||
<i class="dropdown-toggle octicon octicon-search text-muted"
|
||||
data-toggle="dropdown"></i>
|
||||
<div class="dropdown-menu" style="min-width: 120px !important;">
|
||||
<div class="dropdown-menu">
|
||||
<form >
|
||||
<input class="search-dashboard" type="text" autocomplete="off" class="input-with-feedback form-control" style="min-width: 120px;" />
|
||||
<input class="search-dashboard" type="text" autocomplete="off" class="input-with-feedback form-control" style="min-width: 150px;" />
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -35,6 +35,10 @@
|
|||
.sort-dropdown {
|
||||
margin-top: -20px;
|
||||
}
|
||||
|
||||
.dropdown-menu {
|
||||
min-width: 150px !important;
|
||||
}
|
||||
}
|
||||
|
||||
.filter-label {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue