| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- Component({
- properties: {
- list: {
- type: Array
- },
- getResult: {
- type: Function
- },
- result: {
- type: Array
- }
- },
- options: {
- addGlobalClass: true
- },
- data: {
- show: false
- },
- lifetimes: {
- attached: function () {
- getApp().globalData.Language.getLanguagePackage(this)
- }
- },
- methods: {
- onChange({
- detail
- }) {
- this.setData({
- result: detail
- })
- },
- onClose() {
- this.setData({
- show: false
- })
- },
- handleReturn() {
- if (!this.data.result.length) return;
- this.triggerEvent("getResult", this.data.result)
- this.setData({
- show: false,
- result: []
- })
- }
- }
- })
|