community-pop.js 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. import {formTypes} from "../../../../model/enum";
  2. import {toast} from "../../../../utils/utils";
  3. import Route from "../../../../model/route";
  4. Component({
  5. properties: {
  6. show: Boolean
  7. },
  8. data: {},
  9. methods: {
  10. toPublishNeeds(e) {
  11. Route.toCommunityForm(formTypes.NEEDS, "", "", "", {
  12. publish: (res) => {
  13. this.triggerEvent("publish", res)
  14. }
  15. })
  16. },
  17. toPublishHot(e) {
  18. Route.toCommunityForm(formTypes.HOT, "", "", "", {
  19. publish: (res) => {
  20. this.triggerEvent("publish", res)
  21. }
  22. })
  23. },
  24. toPublishCommunity(e) {
  25. toast('正在建设中...')
  26. },
  27. toPublishTypical(e) {
  28. Route.toCommunityForm(formTypes.TYPICAL, "", "", "", {
  29. publish: (res) => {
  30. this.triggerEvent("publish", res)
  31. }
  32. })
  33. },
  34. onClickHide(e) {
  35. this.triggerEvent('close')
  36. },
  37. }
  38. })