Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
million
Project
Project
Details
Activity
Releases
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
viitto
million
Commits
c997b6dc
Commit
c997b6dc
authored
Nov 22, 2024
by
吴春
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
349d07d1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
80 deletions
+10
-80
kkday.vue
src/components/searchProductdata/kkday.vue
+10
-80
No files found.
src/components/searchProductdata/kkday.vue
View file @
c997b6dc
...
...
@@ -35,12 +35,12 @@
<q-card
flat
class=
"rounded-borders q-py-md"
>
<div
class=
"text-subtitle1 text-weight-bold q-mx-md"
>
篩選目的地
</div>
<q-input
v-model=
"
searchAdd.name
"
v-model=
"
msg.searchKey
"
type=
"text"
standout
placeholder=
"蒐索關鍵字"
class=
"q-ma-md"
@
input
=
"changeAddrSearchHandler"
@
blur
=
"changeAddrSearchHandler"
/>
<!--
<q-tree
ref=
"area"
...
...
@@ -134,26 +134,13 @@
<
q
-
card
flat
class
=
"rounded-borders q-py-md"
>
<
div
class
=
"text-subtitle1 text-weight-bold q-mx-md"
>
篩選目的地
<
/div
>
<
q
-
input
v
-
model
=
"
searchAdd.name
"
v
-
model
=
"
msg.searchKey
"
type
=
"text"
standout
placeholder
=
"蒐索關鍵字"
class
=
"q-ma-md"
@
input
=
"changeAddrSearchHandler
"
@
blur
=
"handleSearchKey
"
/>
<!--
<
q
-
tree
ref
=
"area"
:
nodes
=
"areaList"
no
-
connectors
node
-
key
=
"Id"
label
-
key
=
"Name"
tick
-
strategy
=
"leaf"
@
update
:
ticked
=
"handleAreaTicked"
:
ticked
=
"areaTicked"
text
-
color
=
"#666"
no
-
nodes
-
label
=
" "
no
-
results
-
label
=
" "
/>
-->
<
/q-card
>
<
q
-
card
flat
class
=
"rounded-borders q-py-md q-mt-lg"
>
<
div
class
=
"text-subtitle1 text-weight-bold q-mx-md"
>
所有類別
<
/div
>
...
...
@@ -519,7 +506,7 @@ export default {
created() {
this.msg = this.qMsg;
// this.msg.teamType = [];
this.initAreaList();
//
this.initAreaList();
this.initGoods();
this.msg.priceRange = {
min: 1,
...
...
@@ -577,48 +564,16 @@ export default {
this.ticked = target;
this.goSearchHandler();
}
,
handleSearchKey(target) {
this.msg.pageIndex = 1;
this.goSearchHandler();
}
,
handleAreaTicked(target) {
this.msg.pageIndex = 1;
this.msg.placeIds = this.getChoseAddressCity().join("
,
");
this.goSearchHandler();
}
,
initAreaList() {
let jObj = JSON.parse(window.localStorage.getItem("
baseifo
"));
let arr = [];
jObj.AreaList.forEach((x) => {
x.children = x.SubList;
x.children.forEach((y) => {
y.checked = false;
y.explsed = false;
y.isShow = true;
if (y.Id === this.msg.areaId) {
arr.push(y.Id);
}
if (y.SubList) {
y.children = y.SubList;
y.children.forEach((z) => {
z.checked = false;
z.explsed = false;
z.isShow = true;
if (z.Id === this.msg.areaId) {
arr.push(z.Id);
}
if (y.Id === this.msg.areaId) {
arr.push(z.Id);
}
}
);
}
}
);
this.areaList = jObj.AreaList;
this.areaListJSON = JSON.parse(JSON.stringify(this.areaList));
}
);
if (this.msg.areaId) {
this.$nextTick(() => {
this.$refs.area?.setTicked([...new Set(arr)], true);
}
);
}
}
,
changeExplesdHandler(x) {
x.explsed = !x.explsed;
if (x.SubList) {
...
...
@@ -764,31 +719,6 @@ export default {
}
;
return walkAndCopy(tree);
}
,
changeAddrSearchHandler(v) {
this.areaListJSONTMP = JSON.parse(JSON.stringify(this.areaListJSON));
let tree = this.dfs(
{ Name: "", children: this.areaListJSONTMP
}
,
(name, depth) => {
}
,
({ Name
}
) => {
return Name.indexOf(v) !== -1;
}
);
tree = this.dfs(
tree,
(name, depth) => {
}
,
({ Name
}
) => {
return Name.indexOf(v) !== -1;
}
);
tree = this.dfs(
tree,
(name, depth) => {
}
,
({ Name
}
) => {
return Name.indexOf(v) !== -1;
}
);
this.areaList = tree.children;
}
,
goSearchHandler() {
this.$q.loading.show();
this.DataList = [];
...
...
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