Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
138
Merge Requests
138
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
nexedi
erp5
Commits
ed8a7503
Commit
ed8a7503
authored
Jul 18, 2018
by
Tristan Cavelier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_core/erp5_web_renderjs_ui] jIO Release 3.31.0
parent
49b9a3fe
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
68 additions
and
74 deletions
+68
-74
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_jio_js.js
...enderjs_ui/PathTemplateItem/web_page_module/rjs_jio_js.js
+33
-36
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_jio_js.xml
...nderjs_ui/PathTemplateItem/web_page_module/rjs_jio_js.xml
+2
-2
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/jio.js.js
...p5_core/SkinTemplateItem/portal_skins/erp5_core/jio.js.js
+33
-36
No files found.
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_jio_js.js
View file @
ed8a7503
...
...
@@ -6060,9 +6060,9 @@ var arrayExtend = function () {
if
(
query
.
operator
===
"
NOT
"
)
{
return
query
.
query_list
[
0
];
}
return
{
"
type
"
:
"
complex
"
,
"
operator
"
:
"
NOT
"
,
"
query_list
"
:
[
query
]};
return
{
"
type
"
:
"
complex
"
,
"
key
"
:
""
,
"
operator
"
:
"
NOT
"
,
"
query_list
"
:
[
query
]};
},
mkComplexQuery
=
function
(
operator
,
query_list
)
{
},
mkComplexQuery
=
function
(
key
,
operator
,
query_list
)
{
var
i
,
query_list2
=
[];
for
(
i
=
0
;
i
<
query_list
.
length
;
i
+=
1
)
{
if
(
query_list
[
i
].
operator
===
operator
)
{
...
...
@@ -6071,17 +6071,10 @@ var arrayExtend = function () {
query_list2
.
push
(
query_list
[
i
]);
}
}
return
{
type
:
"
complex
"
,
operator
:
operator
,
query_list
:
query_list2
};
return
{
type
:
"
complex
"
,
key
:
key
,
operator
:
operator
,
query_list
:
query_list2
};
},
simpleQuerySetKey
=
function
(
query
,
key
)
{
var
i
;
if
(
query
.
type
===
"
complex
"
)
{
for
(
i
=
0
;
i
<
query
.
query_list
.
length
;
++
i
)
{
simpleQuerySetKey
(
query
.
query_list
[
i
],
key
);
}
return
true
;
}
if
(
query
.
type
===
"
simple
"
&&
!
query
.
key
)
{
},
querySetKey
=
function
(
query
,
key
)
{
if
(({
simple
:
1
,
complex
:
1
})[
query
.
type
]
&&
!
query
.
key
)
{
query
.
key
=
key
;
return
true
;
}
...
...
@@ -6183,13 +6176,13 @@ case 5: case 8: case 11: case 14: case 16:
this
.
$
=
$$
[
$0
];
break
;
case
6
:
this
.
$
=
mkComplexQuery
(
'
AND
'
,
[
$$
[
$0
-
1
],
$$
[
$0
]]);
this
.
$
=
mkComplexQuery
(
'
'
,
'
AND
'
,
[
$$
[
$0
-
1
],
$$
[
$0
]]);
break
;
case
7
:
this
.
$
=
mkComplexQuery
(
'
OR
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
this
.
$
=
mkComplexQuery
(
'
'
,
'
OR
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
break
;
case
9
:
this
.
$
=
mkComplexQuery
(
'
AND
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
this
.
$
=
mkComplexQuery
(
'
'
,
'
AND
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
break
;
case
10
:
this
.
$
=
mkNotQuery
(
$$
[
$0
]);
...
...
@@ -6198,7 +6191,7 @@ case 12:
this
.
$
=
$$
[
$0
-
1
];
break
;
case
13
:
simpleQ
uerySetKey
(
$$
[
$0
],
$$
[
$0
-
2
]);
this
.
$
=
$$
[
$0
];
q
uerySetKey
(
$$
[
$0
],
$$
[
$0
-
2
]);
this
.
$
=
$$
[
$0
];
break
;
case
15
:
$$
[
$0
].
operator
=
$$
[
$0
-
1
]
;
this
.
$
=
$$
[
$0
];
...
...
@@ -7254,6 +7247,8 @@ return new Parser;
*/
this
.
operator
=
spec
.
operator
;
this
.
key
=
spec
.
key
||
this
.
key
;
/**
* The sub Query list which are used to query an item.
*
...
...
@@ -7273,6 +7268,7 @@ return new Parser;
ComplexQuery
.
prototype
.
operator
=
"
AND
"
;
ComplexQuery
.
prototype
.
type
=
"
complex
"
;
ComplexQuery
.
prototype
.
key
=
""
;
/**
* #crossLink "Query/match:method"
...
...
@@ -7289,21 +7285,8 @@ return new Parser;
* #crossLink "Query/toString:method"
*/
ComplexQuery
.
prototype
.
toString
=
function
()
{
var
str_list
=
[],
this_operator
=
this
.
operator
;
if
(
this
.
operator
===
"
NOT
"
)
{
str_list
.
push
(
"
NOT (
"
);
str_list
.
push
(
this
.
query_list
[
0
].
toString
());
str_list
.
push
(
"
)
"
);
return
str_list
.
join
(
"
"
);
}
this
.
query_list
.
forEach
(
function
(
query
)
{
str_list
.
push
(
"
(
"
);
str_list
.
push
(
query
.
toString
());
str_list
.
push
(
"
)
"
);
str_list
.
push
(
this_operator
);
});
str_list
.
length
-=
1
;
return
str_list
.
join
(
"
"
);
/*global objectToSearchText */
return
objectToSearchText
(
this
.
toJSON
());
};
/**
...
...
@@ -7313,6 +7296,7 @@ return new Parser;
var
s
=
{
"
type
"
:
"
complex
"
,
"
operator
"
:
this
.
operator
,
"
key
"
:
this
.
key
,
"
query_list
"
:
[]
};
this
.
query_list
.
forEach
(
function
(
query
)
{
...
...
@@ -7402,12 +7386,26 @@ return new Parser;
};
function
objectToSearchText
(
query
)
{
var
str_list
=
[];
var
str_list
=
[]
,
operator
=
""
,
query_list
=
null
;
if
(
query
.
type
===
"
complex
"
)
{
query_list
=
query
.
query_list
||
[];
if
(
query_list
.
length
===
0
)
{
return
""
;
}
operator
=
query
.
operator
;
if
(
operator
===
"
NOT
"
)
{
str_list
.
push
(
"
NOT
"
);
// fallback to AND operator if several queries are given
// i.e. `NOT ( a AND b )`
operator
=
"
AND
"
;
}
if
(
query
.
key
)
{
str_list
.
push
(
query
.
key
+
"
:
"
);
}
str_list
.
push
(
"
(
"
);
(
query
.
query_list
||
[])
.
forEach
(
function
(
sub_query
)
{
query_list
.
forEach
(
function
(
sub_query
)
{
str_list
.
push
(
objectToSearchText
(
sub_query
));
str_list
.
push
(
query
.
operator
);
str_list
.
push
(
operator
);
});
str_list
.
length
-=
1
;
str_list
.
push
(
"
)
"
);
...
...
@@ -7584,8 +7582,7 @@ return new Parser;
* #crossLink "Query/toString:method"
*/
SimpleQuery
.
prototype
.
toString
=
function
()
{
return
(
this
.
key
?
this
.
key
+
"
:
"
:
""
)
+
(
this
.
operator
?
"
"
+
this
.
operator
:
""
)
+
'
"
'
+
this
.
value
+
'
"
'
;
return
objectToSearchText
(
this
.
toJSON
());
};
/**
...
...
bt5/erp5_web_renderjs_ui/PathTemplateItem/web_page_module/rjs_jio_js.xml
View file @
ed8a7503
...
...
@@ -236,7 +236,7 @@
</item>
<item>
<key>
<string>
serial
</string>
</key>
<value>
<string>
968.
19732.55192.30190
</string>
</value>
<value>
<string>
968.
29995.27806.12578
</string>
</value>
</item>
<item>
<key>
<string>
state
</string>
</key>
...
...
@@ -254,7 +254,7 @@
</tuple>
<state>
<tuple>
<float>
15
29590411.53
</float>
<float>
15
31901693.19
</float>
<string>
UTC
</string>
</tuple>
</state>
...
...
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/jio.js.js
View file @
ed8a7503
...
...
@@ -6060,9 +6060,9 @@ var arrayExtend = function () {
if
(
query
.
operator
===
"
NOT
"
)
{
return
query
.
query_list
[
0
];
}
return
{
"
type
"
:
"
complex
"
,
"
operator
"
:
"
NOT
"
,
"
query_list
"
:
[
query
]};
return
{
"
type
"
:
"
complex
"
,
"
key
"
:
""
,
"
operator
"
:
"
NOT
"
,
"
query_list
"
:
[
query
]};
},
mkComplexQuery
=
function
(
operator
,
query_list
)
{
},
mkComplexQuery
=
function
(
key
,
operator
,
query_list
)
{
var
i
,
query_list2
=
[];
for
(
i
=
0
;
i
<
query_list
.
length
;
i
+=
1
)
{
if
(
query_list
[
i
].
operator
===
operator
)
{
...
...
@@ -6071,17 +6071,10 @@ var arrayExtend = function () {
query_list2
.
push
(
query_list
[
i
]);
}
}
return
{
type
:
"
complex
"
,
operator
:
operator
,
query_list
:
query_list2
};
return
{
type
:
"
complex
"
,
key
:
key
,
operator
:
operator
,
query_list
:
query_list2
};
},
simpleQuerySetKey
=
function
(
query
,
key
)
{
var
i
;
if
(
query
.
type
===
"
complex
"
)
{
for
(
i
=
0
;
i
<
query
.
query_list
.
length
;
++
i
)
{
simpleQuerySetKey
(
query
.
query_list
[
i
],
key
);
}
return
true
;
}
if
(
query
.
type
===
"
simple
"
&&
!
query
.
key
)
{
},
querySetKey
=
function
(
query
,
key
)
{
if
(({
simple
:
1
,
complex
:
1
})[
query
.
type
]
&&
!
query
.
key
)
{
query
.
key
=
key
;
return
true
;
}
...
...
@@ -6183,13 +6176,13 @@ case 5: case 8: case 11: case 14: case 16:
this
.
$
=
$$
[
$0
];
break
;
case
6
:
this
.
$
=
mkComplexQuery
(
'
AND
'
,
[
$$
[
$0
-
1
],
$$
[
$0
]]);
this
.
$
=
mkComplexQuery
(
'
'
,
'
AND
'
,
[
$$
[
$0
-
1
],
$$
[
$0
]]);
break
;
case
7
:
this
.
$
=
mkComplexQuery
(
'
OR
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
this
.
$
=
mkComplexQuery
(
'
'
,
'
OR
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
break
;
case
9
:
this
.
$
=
mkComplexQuery
(
'
AND
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
this
.
$
=
mkComplexQuery
(
'
'
,
'
AND
'
,
[
$$
[
$0
-
2
],
$$
[
$0
]]);
break
;
case
10
:
this
.
$
=
mkNotQuery
(
$$
[
$0
]);
...
...
@@ -6198,7 +6191,7 @@ case 12:
this
.
$
=
$$
[
$0
-
1
];
break
;
case
13
:
simpleQ
uerySetKey
(
$$
[
$0
],
$$
[
$0
-
2
]);
this
.
$
=
$$
[
$0
];
q
uerySetKey
(
$$
[
$0
],
$$
[
$0
-
2
]);
this
.
$
=
$$
[
$0
];
break
;
case
15
:
$$
[
$0
].
operator
=
$$
[
$0
-
1
]
;
this
.
$
=
$$
[
$0
];
...
...
@@ -7254,6 +7247,8 @@ return new Parser;
*/
this
.
operator
=
spec
.
operator
;
this
.
key
=
spec
.
key
||
this
.
key
;
/**
* The sub Query list which are used to query an item.
*
...
...
@@ -7273,6 +7268,7 @@ return new Parser;
ComplexQuery
.
prototype
.
operator
=
"
AND
"
;
ComplexQuery
.
prototype
.
type
=
"
complex
"
;
ComplexQuery
.
prototype
.
key
=
""
;
/**
* #crossLink "Query/match:method"
...
...
@@ -7289,21 +7285,8 @@ return new Parser;
* #crossLink "Query/toString:method"
*/
ComplexQuery
.
prototype
.
toString
=
function
()
{
var
str_list
=
[],
this_operator
=
this
.
operator
;
if
(
this
.
operator
===
"
NOT
"
)
{
str_list
.
push
(
"
NOT (
"
);
str_list
.
push
(
this
.
query_list
[
0
].
toString
());
str_list
.
push
(
"
)
"
);
return
str_list
.
join
(
"
"
);
}
this
.
query_list
.
forEach
(
function
(
query
)
{
str_list
.
push
(
"
(
"
);
str_list
.
push
(
query
.
toString
());
str_list
.
push
(
"
)
"
);
str_list
.
push
(
this_operator
);
});
str_list
.
length
-=
1
;
return
str_list
.
join
(
"
"
);
/*global objectToSearchText */
return
objectToSearchText
(
this
.
toJSON
());
};
/**
...
...
@@ -7313,6 +7296,7 @@ return new Parser;
var
s
=
{
"
type
"
:
"
complex
"
,
"
operator
"
:
this
.
operator
,
"
key
"
:
this
.
key
,
"
query_list
"
:
[]
};
this
.
query_list
.
forEach
(
function
(
query
)
{
...
...
@@ -7402,12 +7386,26 @@ return new Parser;
};
function
objectToSearchText
(
query
)
{
var
str_list
=
[];
var
str_list
=
[]
,
operator
=
""
,
query_list
=
null
;
if
(
query
.
type
===
"
complex
"
)
{
query_list
=
query
.
query_list
||
[];
if
(
query_list
.
length
===
0
)
{
return
""
;
}
operator
=
query
.
operator
;
if
(
operator
===
"
NOT
"
)
{
str_list
.
push
(
"
NOT
"
);
// fallback to AND operator if several queries are given
// i.e. `NOT ( a AND b )`
operator
=
"
AND
"
;
}
if
(
query
.
key
)
{
str_list
.
push
(
query
.
key
+
"
:
"
);
}
str_list
.
push
(
"
(
"
);
(
query
.
query_list
||
[])
.
forEach
(
function
(
sub_query
)
{
query_list
.
forEach
(
function
(
sub_query
)
{
str_list
.
push
(
objectToSearchText
(
sub_query
));
str_list
.
push
(
query
.
operator
);
str_list
.
push
(
operator
);
});
str_list
.
length
-=
1
;
str_list
.
push
(
"
)
"
);
...
...
@@ -7584,8 +7582,7 @@ return new Parser;
* #crossLink "Query/toString:method"
*/
SimpleQuery
.
prototype
.
toString
=
function
()
{
return
(
this
.
key
?
this
.
key
+
"
:
"
:
""
)
+
(
this
.
operator
?
"
"
+
this
.
operator
:
""
)
+
'
"
'
+
this
.
value
+
'
"
'
;
return
objectToSearchText
(
this
.
toJSON
());
};
/**
...
...
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