index.vue 9.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281
  1. <template>
  2. <div>
  3. <div style="width: 80%;background-color: #545c64;margin: 0 auto;display: flex;justify-content:space-around;">
  4. <el-menu
  5. :default-active="activeIndex2"
  6. class="el-menu-demo"
  7. mode="horizontal"
  8. @select="handleSelect"
  9. background-color="#545c64"
  10. text-color="#fff"
  11. active-text-color="#ffd04b">
  12. <el-menu-item index="1">门到门</el-menu-item>
  13. <el-menu-item index="2">门到港</el-menu-item>
  14. <el-menu-item index="3">港到门</el-menu-item>
  15. <el-menu-item index="4">港到港</el-menu-item>
  16. </el-menu>
  17. </div>
  18. <div class="outermost">
  19. <div v-if="selection === '1'">
  20. <el-input placeholder="请输入发货地址">
  21. <template slot="prepend">发货地址</template>
  22. <el-button slot="append" icon="el-icon-d-caret" @click="whether = !whether">{{whether === false?'指定港口':'取消指定港口'}}</el-button>
  23. </el-input>
  24. <el-input placeholder="请输入货物名称">
  25. <template slot="prepend">货物名称</template>
  26. </el-input>
  27. <el-input placeholder="请输入收货地址">
  28. <template slot="prepend">收货地址</template>
  29. </el-input>
  30. <el-input placeholder="请输入预计装货时间">
  31. <template slot="prepend">预计装货时间</template>
  32. </el-input>
  33. <el-input placeholder="请输入起运港口" v-if="whether === true">
  34. <template slot="prepend">起运港口</template>
  35. </el-input>
  36. <el-input placeholder="请输入目的港口" v-if="whether === true">
  37. <template slot="prepend">目的港口</template>
  38. </el-input>
  39. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  40. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  41. </div>
  42. <div v-if="selection === '2'">
  43. <el-input placeholder="请输入发货地址">
  44. <template slot="prepend">发货地址</template>
  45. <el-button slot="append" icon="el-icon-d-caret" @click="whether = !whether">{{whether === false?'指定港口':'取消指定港口'}}</el-button>
  46. </el-input>
  47. <el-input placeholder="请输入货物名称">
  48. <template slot="prepend">货物名称</template>
  49. </el-input>
  50. <el-input placeholder="请输入预计装货时间">
  51. <template slot="prepend">预计装货时间</template>
  52. </el-input>
  53. <el-input placeholder="请输入起运港口" v-if="whether === true">
  54. <template slot="prepend">起运港口</template>
  55. </el-input>
  56. <el-input placeholder="请输入目的港口" v-if="whether === true">
  57. <template slot="prepend">目的港口</template>
  58. </el-input>
  59. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  60. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  61. </div>
  62. <div v-if="selection === '3'">
  63. <el-input placeholder="请输入起运港口">
  64. <template slot="prepend">起运港口</template>
  65. </el-input>
  66. <el-input placeholder="请输入目的港口" v-if="whether === true">
  67. <template slot="prepend">目的港口</template>
  68. </el-input>
  69. <el-input placeholder="请输入货物名称">
  70. <template slot="prepend">货物名称</template>
  71. </el-input>
  72. <el-input placeholder="请输入收货地址">
  73. <template slot="prepend">收货地址</template>
  74. <el-button slot="append" icon="el-icon-d-caret" @click="whether = !whether">{{whether === false?'指定港口':'取消指定港口'}}</el-button>
  75. </el-input>
  76. <el-input placeholder="请输入预计装货时间">
  77. <template slot="prepend">预计装货时间</template>
  78. </el-input>
  79. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  80. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  81. </div>
  82. <div v-if="selection === '4'">
  83. <el-input placeholder="请输入起运港口">
  84. <template slot="prepend">起运港口</template>
  85. </el-input>
  86. <el-input placeholder="请输入目的港口">
  87. <template slot="prepend">目的港口</template>
  88. </el-input>
  89. <el-input placeholder="请输入货物名称">
  90. <template slot="prepend">货物名称</template>
  91. </el-input>
  92. <el-input placeholder="请输入预计装货时间">
  93. <template slot="prepend">预计装货时间</template>
  94. </el-input>
  95. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  96. <button style="width: 400px;height: 0;border: none;padding: 0;"></button>
  97. </div>
  98. <div>
  99. <el-button type="primary">船期查询</el-button>
  100. </div>
  101. <el-divider>查询船期</el-divider>
  102. <div style="width: 100%;padding: 10px;display: flex;justify-content: space-around;border: 1px solid #E8E8E8;box-shadow: 0 2px 7px 0 rgb(71 71 71 / 20%);">
  103. <div style="width: 50%;line-height: 40px;">
  104. <div style="background-color: #f10724;width: 80px;margin-top: 15px;margin-right: 5px;margin-left: 5px;height: 30px;line-height: 30px;border-radius: 20px;color: #ffffff;float: left">
  105. 丹东
  106. </div>
  107. <div style="width: 40px;height: 60px;float: left">
  108. <div style="width: 100%;height: 30px;">
  109. <img style="width: 50%;" src="./ship.png" alt="">
  110. </div>
  111. <div style="width: 100%;height: 30px;line-height: 30px;border-top: 1px solid #f33434">
  112. </div>
  113. </div>
  114. </div>
  115. <div style="width: 25%;margin: 0 auto;display: flex;align-items: center;justify-content: center;border-left: 1px solid #E8E8E8">
  116. <div>
  117. <span style="color: #999999">全程运输时长:</span>
  118. <span style="font-weight:bold">9天</span>
  119. <br>
  120. <span style="color: #999999">单证有效时间:</span>
  121. <span style="font-weight:bold">6天</span>
  122. </div>
  123. </div>
  124. <div style="width: 30%;border-left: 1px solid #E8E8E8;display:flex;justify-content: space-around">
  125. <div>
  126. <div>20GP</div>
  127. <div style="color:#bc1920 ">
  128. <span>¥</span>
  129. <span style="font-size: 20px;">2590</span>
  130. <span>起</span>
  131. </div>
  132. </div>
  133. <div>
  134. <div>40HC</div>
  135. <div style="color:#bc1920 ">
  136. <span>¥</span>
  137. <span style="font-size: 20px;">2590</span>
  138. <span>起</span>
  139. </div>
  140. </div>
  141. <div>
  142. <div>40RH</div>
  143. <div>
  144. <span>-</span>
  145. <span>-</span>
  146. <span>-</span>
  147. </div>
  148. </div>
  149. </div>
  150. <div style="width: 15%;margin: 0 auto;display: flex;align-items: center;justify-content: center;border-left: 1px solid #E8E8E8">
  151. <el-button type="primary">查看船期</el-button>
  152. </div>
  153. </div>
  154. <div style="width: 98%;background-color: #99a9bf;margin: 0 auto">
  155. <div style="float: left;padding: 5px;color:#ffffff;">
  156. <span>天津</span>
  157. <span>青岛</span>
  158. </div>
  159. <div style="border: 1px solid #EBEEF5">
  160. <el-table
  161. :data="tableData"
  162. style="width: 100%">
  163. <el-table-column
  164. prop="date"
  165. label="预计开航"
  166. width="180">
  167. <template slot-scope="scope">
  168. {{scope.row.date}}
  169. </template>
  170. </el-table-column>
  171. <el-table-column
  172. prop="name"
  173. label="预计抵港"
  174. width="180">
  175. </el-table-column>
  176. <el-table-column
  177. prop="address"
  178. label="重箱回场截止时间">
  179. </el-table-column>
  180. <el-table-column
  181. prop="address"
  182. label="船名航次">
  183. </el-table-column>
  184. <el-table-column
  185. prop="address"
  186. label="20GP">
  187. </el-table-column>
  188. <el-table-column
  189. prop="address"
  190. label="40HC">
  191. </el-table-column>
  192. <el-table-column
  193. prop="address"
  194. label="40RH">
  195. </el-table-column>
  196. </el-table>
  197. </div>
  198. </div>
  199. </div>
  200. </div>
  201. </template>
  202. <script>
  203. export default {
  204. name: 'inquiryAndOrder',
  205. data() {
  206. return {
  207. value1: '',
  208. selection: '1',
  209. whether:false,
  210. activeIndex: '1',
  211. activeIndex2: '1',
  212. labelPosition: 'right',
  213. formLabelAlign: {
  214. name: '',
  215. region: '',
  216. type: ''
  217. },
  218. tableData: [{
  219. date: '测试数据',
  220. name: '测试数据',
  221. address: '测试数据',
  222. }, {
  223. date: '测试数据',
  224. name: '测试数据',
  225. address: '测试数据'
  226. }, {
  227. date: '测试数据',
  228. name: '测试数据',
  229. address: '测试数据',
  230. }, {
  231. date: '测试数据',
  232. name: '测试数据',
  233. address: '测试数据'
  234. }]
  235. };
  236. },
  237. methods: {
  238. handleSelect(key, keyPath) {
  239. this.whether = false
  240. console.log(key, keyPath);
  241. this.selection = key;
  242. },
  243. }
  244. };
  245. </script>
  246. <style scoped lang="scss">
  247. .outermost {
  248. width: 80%;
  249. margin: auto auto 100px auto;
  250. padding-top: 20px;
  251. display: flex;
  252. justify-content: space-between;
  253. flex-wrap: wrap;
  254. }
  255. .outermost > div:nth-child(1) {
  256. width: 80%;
  257. display: flex;
  258. display: -webkit-flex;
  259. justify-content: space-around;
  260. flex-direction: row;
  261. flex-wrap: wrap;
  262. }
  263. .outermost > div:nth-child(2) {
  264. width: 20%;
  265. margin: 0 auto;
  266. display: flex;
  267. align-items: center;
  268. justify-content: center
  269. }
  270. .outermost > div:nth-child(1) > .el-input {
  271. width: 400px;
  272. margin-top: 5px;
  273. margin-bottom: 5px;
  274. }
  275. </style>