PublishApply.vue 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866
  1. <template>
  2. <div class="publish-apply">
  3. <div class="good-purchaser">
  4. <p class="good-purchaser-title">
  5. <img src="/images/applyPurchase/good-purchaser-title.png" alt="">
  6. </p>
  7. <ul>
  8. <li v-for="(goodMan, index) in goodPurchaseMan.content">
  9. <i v-text="index + 1" :style="'background: url(/images/applyPurchase/level-' + getRankBg(index) + '.png) center no-repeat;'"></i>
  10. <span v-text="goodMan.name"></span>
  11. </li>
  12. </ul>
  13. </div>
  14. <div class="publish-area">
  15. <div class="publish-form-area">
  16. <p>单个求购</p>
  17. <div>
  18. <div class="form-item">
  19. <span>
  20. <i>*</i>型号:
  21. </span>
  22. <input type="text" class="form-control" :class="{'error': !validObj.code}" v-model="applyObj.code" @blur="checkCode" @input="onCodeChange" placeholder="请勿填中文符号"/>
  23. <ul v-show="showSimilarCodeList && applyObj.code">
  24. <li v-for="sCode in similarCode" @click="setCode(sCode.code)">{{sCode.code}}</li>
  25. </ul>
  26. </div>
  27. <div class="form-item">
  28. <span>
  29. <i>*</i>品牌:
  30. </span>
  31. <input type="text" class="form-control" :class="{'error': !validObj.brand}" v-model="applyObj.brand" @blur="checkBrand" @input="onBrandChange" placeholder="请勿填中文符号" />
  32. <ul class="brand-similar-list" v-show="showSimilarBrandList && applyObj.brand">
  33. <li v-for="sBrand in similarBrand" @click="setBrand(sBrand.nameEn)">{{sBrand.nameEn}}</li>
  34. </ul>
  35. </div>
  36. <div class="form-item">
  37. <span>
  38. <i>*</i>截止日期:
  39. </span>
  40. <!--<input type="text" class="form-control" readonly :class="{'error': !validObj.deadline}" v-model="applyObj.deadline" @blur="checkDeadline" />-->
  41. <el-date-picker
  42. v-model="applyObj.deadline"
  43. type="date"
  44. :picker-options="pickerOptions"
  45. :class="{'error': !validObj.deadline}"
  46. @change="setDeadLineValid"
  47. :editable="false"
  48. :clearable="true"
  49. size="mini">
  50. </el-date-picker>
  51. </div>
  52. <div class="form-item">
  53. <span>
  54. 单价预算:
  55. </span>
  56. <select v-model="applyObj.currency" class="form-control">
  57. <option value="RMB">¥</option>
  58. <option value="USD">$</option>
  59. </select>
  60. <input type="number" class="form-control" :class="{'error': !validObj.unitPrice}" v-model="applyObj.unitPrice" @blur="checkUnitPrice" @input="onUnitPriceInput" />
  61. </div>
  62. <div class="form-item">
  63. <span>
  64. 类目:
  65. </span>
  66. <input type="text" class="form-control" v-model="applyObj.prodTitle" @input="onProdTitleInput"/>
  67. </div>
  68. <div class="form-item">
  69. <span>
  70. 规格:
  71. </span>
  72. <input type="text" class="form-control" :class="{'error': !validObj.spec}" v-model="applyObj.spec" @blur="checkSpec" @input="onSpecInput"/>
  73. </div>
  74. <div class="form-item">
  75. <span>
  76. 封装:
  77. </span>
  78. <input type="text" class="form-control" v-model="applyObj.encapsulation" @input="onEncapsulationChange" />
  79. </div>
  80. <div class="form-item">
  81. <span>
  82. 采购数量:
  83. </span>
  84. <input type="text" class="form-control" :class="{'error': !validObj.amount}" v-model="applyObj.amount" @blur="checkAmount" @input="onAmountInput" />
  85. </div>
  86. <div class="form-item">
  87. <span>
  88. 生产日期:
  89. </span>
  90. <input type="text" class="form-control" v-model="applyObj.produceDate" @input="onProduceDateChange" />
  91. </div>
  92. </div>
  93. <a @click="goPublish()">发布求购</a>
  94. </div>
  95. <div class="publish-upload">
  96. <h1>批量求购</h1>
  97. <h2>3秒一键配单采购</h2>
  98. <label>
  99. <img src="/images/applyPurchase/upload.png" alt="" />
  100. <!--<input type="file" accept="*.xls, *.xlsx" @change="upload">-->
  101. <el-upload
  102. drag
  103. action="/seek/importBom"
  104. accept="*.xls, *.xlsx"
  105. :show-file-list="false"
  106. :on-success="onSuccess"
  107. :on-error="onError">
  108. </el-upload>
  109. </label>
  110. <h3>把Excel格式的BOM拖放到框中</h3>
  111. <img @click="downloadTemplate()" class="download-line" src="/images/applyPurchase/download.png" alt="">
  112. <img class="apply-logo" src="/images/applyPurchase/publish-apply.png" alt="">
  113. </div>
  114. </div>
  115. <div class="apply-rank">
  116. <table>
  117. <thead>
  118. <tr>
  119. <th width="62">排名</th>
  120. <th width="160">型号</th>
  121. <th width="92">求购次数</th>
  122. </tr>
  123. </thead>
  124. <tbody>
  125. <tr v-for="(rank, index) in purchaseRank">
  126. <td><div>NO.<span>{{index + 1}}</span><i>|</i></div></td>
  127. <td>
  128. <div>
  129. <span v-if="rank.id_cmpcode" :title="rank.id_cmpcode">{{rank.id_cmpcode}}</span>
  130. <span v-if="!rank.id_cmpcode">-</span>
  131. <i>|</i>
  132. </div>
  133. </td>
  134. <td><div>{{rank.seekAmount || 0}}</div></td>
  135. </tr>
  136. </tbody>
  137. </table>
  138. </div>
  139. <!--提示框-->
  140. <div class="apply-del-box" v-if="showRemindBox">
  141. <div class="title">
  142. <a @click="showRemindBox = false"><i class="fa fa-close fa-lg"></i></a>
  143. </div>
  144. <div class="content">
  145. <!--<p style="line-height: 20px;margin-top: 10px;padding:0 10px">非常抱歉,目前暂无此品牌!<br>若直接前往“品牌申请”,我们将为您先开通寄售功能,待申请通过后再提交开店申请。</p>-->
  146. <!--<p style="line-height: 20px;">前往<a @click="goBrandApply()" target="_blank" style="color: #5078CB">品牌申请&nbsp;<i class="fa fa-arrow-right"></i></a></p>-->
  147. <p><img src="/images/applyPurchase/check.png" alt="">发布成功</p>
  148. <p>其中 <span>100</span>个求购型号有现货在售,您可前往“<span>买家中心-我的求购</span>”查询并直接购买</p>
  149. <div>
  150. <a @click="showRemindBox = false">我知道了</a>
  151. <a href="/user#/seekPurchase">前往我的求购</a>
  152. </div>
  153. </div>
  154. </div>
  155. </div>
  156. </template>
  157. <script>
  158. import { getRealLen, cutOutString, formatDate, checkNullStr } from '~utils/baseUtils'
  159. export default {
  160. data () {
  161. return {
  162. applyObj: {
  163. code: '',
  164. brand: '',
  165. unitPrice: '',
  166. currency: 'RMB',
  167. prodTitle: '',
  168. spec: '',
  169. encapsulation: '',
  170. produceDate: '',
  171. amount: '',
  172. deadline: ''
  173. },
  174. validObj: {
  175. code: true,
  176. brand: true,
  177. unitPrice: true,
  178. // encapsulation: true,
  179. // produceDate: true,
  180. amount: true,
  181. deadline: true,
  182. spec: true
  183. },
  184. pickerOptions: {
  185. disabledDate (time) {
  186. // 大于等于今天 小于三个月后
  187. return time.getTime() < Date.now() - 1000 * 60 * 60 * 24 || time.getTime() > Date.now() + 1000 * 60 * 60 * 24 * 30 * 3
  188. }
  189. },
  190. showRemindBox: false,
  191. showSimilarCodeList: false,
  192. showSimilarBrandList: false,
  193. similarCode: [],
  194. similarBrand: []
  195. }
  196. },
  197. computed: {
  198. goodPurchaseMan () {
  199. return this.$store.state.applyPurchase.goodPurchaseMan.goodPurchaseMan.data
  200. },
  201. purchaseRank () {
  202. return this.$store.state.applyPurchase.purchaseApplyRank.purchaseApplyRank.data
  203. },
  204. user () {
  205. return this.$store.state.option.user
  206. }
  207. },
  208. filters: {
  209. enterpriseFilter (str) {
  210. return str.length > 4 ? str.substring(0, 2) + '**' + str.substring(str.length - 2, str.length) : str
  211. },
  212. userNameFilter (str) {
  213. return str.substring(0, 1) + '**'
  214. }
  215. },
  216. mounted () {
  217. document.getElementsByClassName('el-upload-dragger')[0].onclick = function (event) {
  218. event.stopPropagation()
  219. }
  220. let _this = this
  221. document.body.onclick = function () {
  222. _this.showSimilarCodeList = false
  223. _this.showSimilarBrandList = false
  224. }
  225. },
  226. methods: {
  227. emptyForm: function () {
  228. for (let attr in this.applyObj) {
  229. this.applyObj[attr] = attr === 'currency' ? 'RMB' : ''
  230. }
  231. },
  232. getRankBg: function (index) {
  233. return index === 0 ? 1 : index < 3 ? 2 : 3
  234. },
  235. goPublish: function () {
  236. if (this.user.logged) {
  237. if (this.checkAll()) {
  238. let inquiry = {}
  239. let inquiryItem = {}
  240. if (this.user.data.enterprise) {
  241. inquiry.enUU = this.user.data.enterprise.uu
  242. }
  243. let date = new Date()
  244. let currency = this.applyObj.currency === '不限' ? null : this.applyObj.currency
  245. inquiry.recorderUU = this.user.data.userUU
  246. inquiry.code = 'MALL' + date.getTime()
  247. inquiry.date = date
  248. inquiry.recorder = this.user.data.userName
  249. inquiry.endDate = this.applyObj.deadline
  250. inquiry.sourceapp = 'MALL'
  251. inquiry.amount = 1
  252. inquiryItem.prodTitle = this.applyObj.code
  253. inquiryItem.userUU = this.user.data.userUU
  254. inquiryItem.source = 'MALL'
  255. inquiryItem.userName = this.user.data.userName
  256. inquiryItem.userTel = this.user.data.userTel
  257. inquiryItem.needquantity = this.applyObj.amount
  258. inquiryItem.inbrand = this.applyObj.brand
  259. inquiryItem.currency = currency
  260. inquiryItem.cmpCode = (this.applyObj.code).toUpperCase()
  261. inquiryItem.unitPrice = this.applyObj.unitPrice
  262. inquiryItem.produceDate = this.applyObj.produceDate
  263. inquiryItem.date = date
  264. inquiryItem.endDate = this.applyObj.deadline
  265. inquiryItem.encapsulation = this.applyObj.encapsulation
  266. inquiryItem.spec = this.applyObj.spec
  267. inquiryItem.prodTitle = this.applyObj.prodTitle
  268. let inquiryItems = []
  269. inquiryItems.push(inquiryItem)
  270. inquiry.inquiryItems = inquiryItems
  271. inquiry.currency = currency
  272. this.$http.post('/inquiry/buyer/save', inquiry)
  273. .then(response => {
  274. this.$message.success('发布成功')
  275. // this.showRemindBox = true
  276. this.emptyForm()
  277. // this.validObj.deadline = true
  278. this.$store.dispatch('applyPurchase/loadPurchaseManList', {pageNumber: 1, pageSize: 10, enUU: this.user.data.enterprise ? this.user.data.enterprise.uu : null})
  279. }, error => {
  280. console.log(error)
  281. this.$message.error('发布失败')
  282. })
  283. } else {
  284. if (!this.validObj.deadline) {
  285. this.$message.error('截止日期不能为空')
  286. } else if (!this.validObj.amount) {
  287. this.$message.error('请输入正确的数值')
  288. }
  289. }
  290. } else {
  291. this.$router.push('/auth/login?returnUrl=' + window.location.href)
  292. }
  293. },
  294. getSimilarCode: function () {
  295. if (this.applyObj.code) {
  296. this.$http.get('/search/similarComponents', {params: {keyword: this.applyObj.code}})
  297. .then(response => {
  298. this.similarCode = response.data
  299. this.showSimilarCodeList = response.data.length > 0
  300. })
  301. } else {
  302. this.showSimilarCodeList = false
  303. }
  304. },
  305. getSimilarBrand: function () {
  306. if (this.applyObj.brand) {
  307. this.$http.get('/search/similarBrands', {params: {keyword: this.applyObj.brand}})
  308. .then(response => {
  309. this.similarBrand = response.data
  310. this.showSimilarBrandList = response.data.length > 0
  311. })
  312. } else {
  313. this.showSimilarBrandList = false
  314. }
  315. },
  316. checkCode: function () {
  317. let nullStrFlag = checkNullStr(this.applyObj.code)
  318. this.validObj.code = this.applyObj.code && this.applyObj.code !== '' && nullStrFlag
  319. if (!this.validObj.code) {
  320. if (!nullStrFlag) {
  321. this.$message.error('型号输入不合法')
  322. } else {
  323. this.$message.error('型号不能为空')
  324. }
  325. }
  326. return this.validObj.code
  327. },
  328. checkBrand: function () {
  329. let nullStrFlag = checkNullStr(this.applyObj.brand)
  330. this.validObj.brand = this.applyObj.brand && this.applyObj.brand !== '' && nullStrFlag
  331. if (!this.validObj.brand) {
  332. if (!nullStrFlag) {
  333. this.$message.error('品牌输入不合法')
  334. } else {
  335. this.$message.error('品牌不能为空')
  336. }
  337. }
  338. return this.validObj.brand
  339. },
  340. checkUnitPrice: function () {
  341. this.validObj.unitPrice = this.applyObj.unitPrice === '' ? true : this.applyObj.unitPrice > 0 && this.applyObj.unitPrice < 100000000
  342. if (!this.validObj.unitPrice && this.applyObj.unitPrice <= 0) {
  343. this.$message.error('单价必须是大于0的数字')
  344. }
  345. return this.validObj.unitPrice
  346. },
  347. checkSpec: function () {
  348. let nullStrFlag = checkNullStr(this.applyObj.spec)
  349. this.validObj.spec = nullStrFlag
  350. if (!nullStrFlag) {
  351. this.$message.error('规格输入不合法')
  352. }
  353. return this.validObj.spec
  354. },
  355. checkAmount: function () {
  356. this.validObj.amount = this.applyObj.amount === '' ? true : this.applyObj.amount > 0 && this.applyObj.amount < 1000000000
  357. return this.validObj.amount
  358. },
  359. checkAll: function () {
  360. return this.checkCode() && this.checkBrand() && this.checkDeadline() && this.checkUnitPrice() && this.checkAmount() && this.checkSpec()
  361. },
  362. checkDeadline: function () {
  363. this.validObj.deadline = Boolean(this.applyObj.deadline)
  364. return this.validObj.deadline
  365. },
  366. setDeadLineValid: function () {
  367. this.applyObj.deadline = formatDate(this.applyObj.deadline, 'yyyy-MM-dd hh:mm:ss')
  368. this.validObj.deadline = true
  369. },
  370. onUnitPriceInput: function () {
  371. let price = this.applyObj.unitPrice
  372. if (price >= 10000) {
  373. this.applyObj.unitPrice = price.substring(0, 4)
  374. } else if (price.indexOf('.') > -1) {
  375. let arr = price.split('.')
  376. if (arr[0].length > 4) {
  377. this.applyObj.unitPrice = Number(arr[0].substring(0, 4) + '.' + arr[1])
  378. } else if (arr[1].length > 6) {
  379. this.applyObj.unitPrice = Number(arr[0] + '.' + arr[1].substring(0, 6))
  380. }
  381. }
  382. },
  383. onProduceDateChange: function () {
  384. if (this.applyObj.produceDate && getRealLen(this.applyObj.produceDate) > 12) {
  385. this.applyObj.produceDate = cutOutString(this.applyObj.produceDate, 12)
  386. }
  387. },
  388. onEncapsulationChange: function () {
  389. if (this.applyObj.encapsulation && getRealLen(this.applyObj.encapsulation) > 20) {
  390. this.applyObj.encapsulation = cutOutString(this.applyObj.encapsulation, 20)
  391. }
  392. },
  393. onProdTitleInput: function () {
  394. if (this.applyObj.prodTitle && getRealLen(this.applyObj.prodTitle) > 40) {
  395. this.applyObj.prodTitle = cutOutString(this.applyObj.prodTitle, 40)
  396. }
  397. },
  398. onSpecInput: function () {
  399. if (this.applyObj.spec && getRealLen(this.applyObj.spec) > 100) {
  400. this.applyObj.spec = cutOutString(this.applyObj.spec, 100)
  401. }
  402. },
  403. onCodeChange: function () {
  404. this.applyObj.code = this.applyObj.code.trim()
  405. if ((/[^\x00-\xff]/g).test(this.applyObj.code)) {
  406. let chineseIndex = -1
  407. for (let i = 0; i < this.applyObj.code.length; i++) {
  408. if ((/[^\x00-\xff]/g).test(this.applyObj.code.charAt(i))) {
  409. chineseIndex = i
  410. break
  411. }
  412. }
  413. this.applyObj.code = cutOutString(this.applyObj.code, chineseIndex)
  414. } else if (this.applyObj.code && getRealLen(this.applyObj.code) > 100) {
  415. this.applyObj.code = cutOutString(this.applyObj.code, 100)
  416. } else {
  417. this.getSimilarCode()
  418. }
  419. },
  420. onBrandChange: function () {
  421. this.applyObj.brand = this.applyObj.brand.trim()
  422. if ((/[^\x00-\xff]/g).test(this.applyObj.brand)) {
  423. let chineseIndex = -1
  424. for (let i = 0; i < this.applyObj.brand.length; i++) {
  425. if ((/[^\x00-\xff]/g).test(this.applyObj.brand.charAt(i)) && !(/[\u4e00-\u9fa5]/).test(this.applyObj.brand.charAt(i))) {
  426. chineseIndex = i
  427. break
  428. }
  429. }
  430. if (chineseIndex > -1) {
  431. this.applyObj.brand = this.applyObj.brand.substring(0, chineseIndex)
  432. }
  433. } else if (this.applyObj.brand && getRealLen(this.applyObj.brand) > 50) {
  434. this.applyObj.brand = cutOutString(this.applyObj.brand, 50)
  435. }
  436. this.getSimilarBrand()
  437. },
  438. onAmountInput: function () {
  439. if (!(/^[0-9]*$/).test(this.applyObj.amount)) {
  440. let chineseIndex = -1
  441. for (let i = 0; i < this.applyObj.amount.length; i++) {
  442. if (!(/^[0-9]*$/).test(this.applyObj.amount.charAt(i))) {
  443. chineseIndex = i
  444. break
  445. }
  446. }
  447. this.applyObj.amount = cutOutString(this.applyObj.amount, chineseIndex)
  448. } else if (this.applyObj.amount.length > 9) {
  449. this.applyObj.amount = cutOutString(this.applyObj.amount, 9)
  450. }
  451. },
  452. onSuccess: function (data) {
  453. if (!this.user.logged) {
  454. this.$router.push('/auth/login?returnUrl=' + window.location.href)
  455. } else if (data.success) {
  456. window.location.href = '/applyPurchase/' + data.data
  457. } else {
  458. this.$message.error(data.message)
  459. }
  460. },
  461. onError: function () {
  462. if (!this.user.logged) {
  463. this.$router.push('/auth/login?returnUrl=' + window.location.href)
  464. } else {
  465. this.$message.error('上传失败, 系统错误')
  466. }
  467. },
  468. downloadTemplate: function () {
  469. window.location.href = '/seek/release/template'
  470. },
  471. setCode: function (code) {
  472. this.applyObj.code = code
  473. this.showSimilarCodeList = false
  474. },
  475. setBrand: function (brand) {
  476. this.applyObj.brand = brand
  477. this.showSimilarBrandList = false
  478. }
  479. // upload: function (e) {
  480. // let file = e.target.files[0]
  481. // let param = new FormData()
  482. // param.append('file', file, file.name)
  483. // let config = {
  484. // headers: {'Content-Type': file.type}
  485. // }
  486. // this.$http.post('/seek/importBom', param, config).then(response => {
  487. // if (response.data.success) {
  488. // window.open('/applyPurchase/' + response.data.data)
  489. // } else {
  490. // this.$message.error('上传失败')
  491. // }
  492. // }, err => {
  493. // console.log(err)
  494. // this.$message.error('系统错误')
  495. // })
  496. // }
  497. }
  498. }
  499. </script>
  500. <style lang="scss">
  501. .publish-apply {
  502. background: url('/images/applyPurchase/banner.png') center center/cover no-repeat;
  503. height: 583px;
  504. padding-top: 290px;
  505. width: 1190px;
  506. margin: 0 auto;
  507. padding-left: 44px;
  508. >div {
  509. display: inline-block;
  510. border: 1px solid #3975f4;
  511. height: 267px;
  512. margin-right: 6px;
  513. vertical-align: middle;
  514. background: #fff;
  515. float: left;
  516. text-align: center;
  517. }
  518. .good-purchaser {
  519. width: 225px;
  520. .good-purchaser-title {
  521. height: 55px;
  522. line-height: 55px;
  523. background: #3975f4;
  524. margin: 0;
  525. }
  526. ul {
  527. padding: 0 22px 0 10px;
  528. li {
  529. line-height: 42px;
  530. span {
  531. float: right;
  532. display: inline-block;
  533. width: 152px;
  534. overflow: hidden;
  535. text-overflow: ellipsis;
  536. white-space: nowrap;
  537. text-align: left;
  538. }
  539. i {
  540. display: inline-block;
  541. float: left;
  542. width: 25px;
  543. color: #fff;
  544. font-size: 16px;
  545. font-style: normal;
  546. }
  547. }
  548. }
  549. }
  550. .publish-area {
  551. width: 549px;
  552. text-align: center;
  553. .publish-form-area {
  554. width: 243px;
  555. float: left;
  556. height: 100%;
  557. p {
  558. padding-top: 8px;
  559. font-size: 22px;
  560. color: #3975f4;
  561. margin-bottom: 4px;
  562. }
  563. >div {
  564. text-align: left;
  565. margin-left: 14px;
  566. .form-item {
  567. margin-bottom: 4px;
  568. position: relative;
  569. span {
  570. width: 80px;
  571. text-align: right;
  572. display: inline-block;
  573. i {
  574. position: relative;
  575. top: 2px;
  576. right: 3px;
  577. color: #e41515;
  578. }
  579. }
  580. ul {
  581. line-height: normal;
  582. position: absolute;
  583. top: 19px;
  584. left: 79px;
  585. background: #fff;
  586. border: 1px solid #b5b5b5;
  587. z-index: 1;
  588. max-height: 120px;
  589. overflow-y: auto;
  590. overflow-x: hidden;
  591. border-radius: 3px;
  592. width: 114px;
  593. font-size: 12px;
  594. li {
  595. height: 24px;
  596. line-height: 24px;
  597. cursor: pointer;
  598. overflow: hidden;
  599. text-overflow: ellipsis;
  600. white-space: nowrap;
  601. padding: 0 5px;
  602. &:hover {
  603. background: #ddd;
  604. }
  605. }
  606. }
  607. select {
  608. width: 32px;
  609. position: absolute;
  610. height: 20px;
  611. background: url('/images/applyPurchase/select.png')no-repeat right;
  612. background-position-x: 15px;
  613. padding: 0 0 0 3px;
  614. border-radius: 0;
  615. & + input {
  616. padding-left: 34px;
  617. }
  618. }
  619. .el-input {
  620. width: 111px;
  621. .el-input__inner {
  622. }
  623. }
  624. input {
  625. font-size: 12px;
  626. width: 111px;
  627. height: 18px;
  628. line-height: 18px;
  629. border-radius: 2px;
  630. padding: 0 3px;
  631. box-shadow: none;
  632. -webkit-box-shadow: none;
  633. -moz-box-shadow: none;
  634. &.error {
  635. border-color: #f4645f!important;
  636. }
  637. }
  638. }
  639. }
  640. >a {
  641. width: 90px;
  642. height: 25px;
  643. line-height: 25px;
  644. background: #3975f4;
  645. color: #fefefe;
  646. font-size: 16px;
  647. display: block;
  648. margin: 0 auto;
  649. border-radius: 3px;
  650. cursor: pointer;
  651. }
  652. }
  653. .publish-upload {
  654. background: url('/images/applyPurchase/publish-apply-bg.png')no-repeat;
  655. background-size: cover;
  656. width: 304px;
  657. height: 100%;
  658. padding-left: 22px;
  659. float: right;
  660. color: #fff;
  661. position: relative;
  662. h1 {
  663. font-size: 22px;
  664. margin: 11px 0 0 0;
  665. }
  666. h2 {
  667. font-size: 16px;
  668. margin: 10px 0 23px 0;
  669. }
  670. h3 {
  671. font-size: 16px;
  672. margin: 20px 0 13px 0;
  673. }
  674. label {
  675. position: relative;
  676. /*input {
  677. display: none;
  678. }*/
  679. > div {
  680. position: absolute;
  681. .el-upload {
  682. input {
  683. display: none;
  684. }
  685. .el-upload-dragger {
  686. width: 247px;
  687. height: 216px;
  688. position: absolute;
  689. bottom: -37px;
  690. right: -166px;
  691. opacity: 0;
  692. }
  693. }
  694. }
  695. }
  696. .download-line {
  697. cursor: pointer;
  698. color: #b47200;
  699. }
  700. .apply-logo {
  701. position: absolute;
  702. left: -20px;
  703. top: 86px;
  704. }
  705. }
  706. }
  707. .apply-rank {
  708. width: 317px;
  709. margin-right: 0;
  710. background: url('/images/applyPurchase/rank-title.png') no-repeat;
  711. background-color: #fff;
  712. background-size: 319px 74px;
  713. background-position: -3px -2px;
  714. table {
  715. margin: 76px auto 0;
  716. width: 98%;
  717. thead {
  718. background: #e0e0e0;
  719. height: 26px;
  720. line-height: 26px;
  721. border-radius: 3px;
  722. tr {
  723. th {
  724. font-size: 16px;
  725. font-weight: bold;
  726. text-align: center;
  727. }
  728. }
  729. }
  730. tbody {
  731. tr {
  732. height: 25px;
  733. line-height: 25px;
  734. &:first-child {
  735. td {
  736. padding-top: 10px;
  737. }
  738. }
  739. td {
  740. color: #666;
  741. &:nth-child(1) {
  742. color: #f6682f;
  743. font-size: 12px;
  744. >div {
  745. width: 62px;
  746. span {
  747. font-size: 16px;
  748. }
  749. }
  750. }
  751. &:nth-child(2) {
  752. >div {
  753. width: 160px;
  754. }
  755. }
  756. &:nth-child(3) {
  757. >div {
  758. width: 92px;
  759. }
  760. }
  761. >div {
  762. overflow: hidden;
  763. text-overflow: ellipsis;
  764. white-space: nowrap;
  765. padding: 0 8px;
  766. position: relative;
  767. height: 30px;
  768. i {
  769. font-style: normal;
  770. float: right;
  771. color: #8b8b8b;
  772. font-size: 14px;
  773. position: absolute;
  774. right: 0;
  775. }
  776. }
  777. }
  778. }
  779. }
  780. }
  781. }
  782. .apply-del-box{
  783. position: fixed;
  784. z-index: 1000;
  785. height: auto;
  786. opacity: 1;
  787. background-color: white;
  788. width: 310px;
  789. -webkit-box-shadow: 0 5px 15px rgba(0,0,0,.5);
  790. -moz-box-shadow: 0 5px 15px rgba(0,0,0,.5);
  791. -o-box-shadow: 0 5px 15px rgba(0,0,0,.5);
  792. box-shadow: 0 5px 15px rgba(0,0,0,.5);
  793. margin: -155px 0 0 -75px;
  794. top: 55%;
  795. left: 43%;
  796. .title{
  797. height: 24px;
  798. background-color: #007aff;
  799. text-align: right;
  800. padding-right: 15px;
  801. line-height: 24px;
  802. a{
  803. color: white;
  804. font-size: 12px;
  805. }
  806. }
  807. .content{
  808. width: 100%;
  809. text-align: center;
  810. margin: 0 auto;
  811. p{
  812. padding: 12px 31px;
  813. margin: 0;
  814. i{
  815. color: #5078cb;
  816. font-size: 16px;
  817. margin-right: 10px;
  818. }
  819. span {
  820. color: #007aff;
  821. }
  822. &:last-child {
  823. font-size: 12px;
  824. }
  825. }
  826. div{
  827. width: 100%;
  828. text-align: center;
  829. margin: 0 auto 20px;
  830. a{
  831. padding: 0 19px;
  832. height: 26px;
  833. line-height: 26px;
  834. display: inline-block;
  835. text-align: center;
  836. font-size: 14px;
  837. color: #fff;
  838. &:first-child{
  839. background: #c8c6c6;
  840. margin-right: 10px;
  841. }
  842. &:last-child{
  843. background: #007aff;
  844. }
  845. }
  846. }
  847. }
  848. }
  849. }
  850. .el-date-editor--date{
  851. width: 110px;
  852. &.error {
  853. input {
  854. border: 1px solid #f4645f !important;
  855. }
  856. }
  857. }
  858. .el-icon-date {
  859. display: none;
  860. }
  861. .el-input__inner {
  862. height: 20px;
  863. border-radius: 0;
  864. border: 1px solid #c9c9c9;
  865. }
  866. </style>