info.vue 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. <template>
  2. <view class="container">
  3. <u-cell-group>
  4. <u-cell title="商户名称" :value="company.name"></u-cell>
  5. <u-cell title="商户性质" :value="company.property_name"></u-cell>
  6. <u-cell title="营业状态" :value="company.operate_status_name"></u-cell>
  7. <!-- <u-cell title="法人代码" :value="company.xinyong_code"></u-cell>
  8. <u-cell title="法人代表" :value="company.corporation_name"></u-cell> -->
  9. <u-cell title="商户地址" :value="company.address"></u-cell>
  10. <u-cell title="灶头数" :value="company.stove_num"></u-cell>
  11. <u-cell title="排口数" :value="company.outlet_num"></u-cell>
  12. <u-cell title="类型" :value="company.type_name"></u-cell>
  13. <u-cell title="规模" :value="company.catering_scale_name"></u-cell>
  14. <u-cell title="菜系" :value="company.catering_style_name"></u-cell>
  15. <u-cell title="区域" :value="company.org_name"></u-cell>
  16. <u-cell title="经度" :value="company.longitude"></u-cell>
  17. <u-cell title="纬度" :value="company.latitude"></u-cell>
  18. <u-cell title="人数" :value="company.people"></u-cell>
  19. <u-cell title="面积" :value="company.acreage"></u-cell>
  20. </u-cell-group>
  21. <u-gap height="10" bgColor="rgb(41, 121, 255)"></u-gap>
  22. <u-cell-group><u-cell v-for="(item, index) in monitors" :title="item.name" :label="item.volume + ' m3/h'" :value="item.online_name"></u-cell></u-cell-group>
  23. </view>
  24. </template>
  25. <script>
  26. import api from "@/common/api.js";
  27. export default {
  28. data() {
  29. return {
  30. company: {},
  31. monitors: [],
  32. };
  33. },
  34. props: {
  35. companyId: {
  36. type: String,
  37. required: true,
  38. },
  39. },
  40. mounted() {
  41. this.getInfo();
  42. },
  43. methods: {
  44. getInfo() {
  45. api.getRecord(`10_${this.companyId}`).then(({ data }) => {
  46. this.company = data.company;
  47. this.monitors = data.monitors;
  48. console.log(data);
  49. });
  50. },
  51. },
  52. };
  53. </script>
  54. <style lang="scss">
  55. .container {
  56. padding: 20px;
  57. font-size: 14px;
  58. line-height: 24px;
  59. }
  60. /deep/ .u-cell {
  61. &__title {
  62. font-weight: 600;
  63. }
  64. &__value {
  65. color: $uni-color-primary;
  66. }
  67. }
  68. </style>