|
@@ -0,0 +1,36 @@
|
|
|
+Page({
|
|
|
+ data: {
|
|
|
+ washingandnursing: [{text:'洗衣服',id:'1',},{text:'熨烫衣服',id:'2',},{text:'晾晒收衣',id:'3',}],
|
|
|
+ cooking: [{text:'做早餐',id:'1'},{text:'做午餐',id:'2'},{text:'做晚餐',id:'3'}],
|
|
|
+ cleaningclass: [{text:'打扫全屋',id:'1'},{text:'打扫客厅',id:'2'},{text:'打扫卧室',id:'3'},{text:'打扫书房',id:'4'},{text:'打扫厨房',id:'5'},{text:'打扫卫生间',id:'6'},{text:'打扫院子',id:'7'}],
|
|
|
+ careolder:[{text:'照顾老人',id:'1'},{text:'为老人做饭',id:'2'},{text:'为老人做擦洗服务',id:'3'}],
|
|
|
+ children:[{text:'打扫全屋',id:'1'},{text:'打扫客厅',id:'2'},{text:'打扫卧室',id:'3'},{text:'打扫书房',id:'4'},{text:'打扫厨房',id:'5'},{text:'打扫卫生间',id:'6'},{text:'打扫院子',id:'7'}],
|
|
|
+ pets:[{text:'打扫全屋',id:'1'},{text:'打扫客厅',id:'2'},{text:'打扫卧室',id:'3'},{text:'打扫书房',id:'4'},{text:'打扫厨房',id:'5'},{text:'打扫卫生间',id:'6'},{text:'打扫院子',id:'7'}],
|
|
|
+ washingandnursinglist:[],
|
|
|
+ cookinglist:[],
|
|
|
+ cleaningclasslist:[],
|
|
|
+ careolderlist:[],
|
|
|
+ childrenlist:[],
|
|
|
+ petslist:[]
|
|
|
+ },
|
|
|
+ onLoad(options) {
|
|
|
+ console.log(options);
|
|
|
+ },
|
|
|
+ toggleWashinGandnursing(e){
|
|
|
+
|
|
|
+ let id=e.target.dataset.id;
|
|
|
+ if(this.data.washingandnursinglist.indexOf(id)==-1){
|
|
|
+ let newArr=this.data.washingandnursinglist;
|
|
|
+ newArr.push(id);
|
|
|
+ this.setData({
|
|
|
+ washingandnursinglist:newArr
|
|
|
+ })
|
|
|
+ }else{
|
|
|
+ let newArr=this.data.washingandnursinglist;
|
|
|
+ newArr.splice(newArr.indexOf(id),1);
|
|
|
+ this.setData({
|
|
|
+ washingandnursinglist:newArr
|
|
|
+ })
|
|
|
+ }
|
|
|
+ },
|
|
|
+});
|