PublishApply.vue 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878
  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. 采购数量(PCS):
  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. getMaterialKind: function (code, brand) {
  236. return this.$http.get('/productuser/match/getKind', {params: {cmpCode: code, brand: brand}})
  237. },
  238. startPublish: function (prodTitle) {
  239. let inquiry = {}
  240. let inquiryItem = {}
  241. if (this.user.data.enterprise) {
  242. inquiry.enUU = this.user.data.enterprise.uu
  243. }
  244. let date = new Date()
  245. let currency = this.applyObj.unitPrice ? this.applyObj.currency : null
  246. inquiry.recorderUU = this.user.data.userUU
  247. inquiry.code = 'MALL' + date.getTime()
  248. inquiry.date = date
  249. inquiry.recorder = this.user.data.userName
  250. inquiry.endDate = this.applyObj.deadline
  251. inquiry.sourceapp = 'MALL'
  252. inquiry.amount = 1
  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.trim().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 = prodTitle || this.applyObj.prodTitle || '其他'
  268. let inquiryItems = []
  269. inquiryItems.push(inquiryItem)
  270. inquiry.inquiryItems = inquiryItems
  271. inquiry.currency = this.applyObj.unitPrice ? this.applyObj.currency : null
  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. },
  284. goPublish: function () {
  285. if (this.user.logged) {
  286. if (this.checkAll()) {
  287. if (!this.applyObj.prodTitle || this.applyObj.prodTitle.length === 0) {
  288. this.getMaterialKind(this.applyObj.code, this.applyObj.brand).then(response => {
  289. this.startPublish(response.data && response.data.length ? response.data : '其他')
  290. })
  291. } else {
  292. this.startPublish()
  293. }
  294. } else {
  295. if (!this.validObj.deadline) {
  296. this.$message.error('截止日期不能为空')
  297. } else if (!this.validObj.amount) {
  298. this.$message.error('请输入正确的数值')
  299. }
  300. }
  301. } else {
  302. this.$router.push('/auth/login?returnUrl=' + window.location.href)
  303. }
  304. },
  305. getSimilarCode: function () {
  306. if (this.applyObj.code) {
  307. this.$http.get('/search/similarComponents', {params: {keyword: this.applyObj.code}})
  308. .then(response => {
  309. this.similarCode = response.data
  310. this.showSimilarCodeList = response.data.length > 0
  311. })
  312. } else {
  313. this.showSimilarCodeList = false
  314. }
  315. },
  316. getSimilarBrand: function () {
  317. if (this.applyObj.brand) {
  318. this.$http.get('/search/similarBrands', {params: {keyword: this.applyObj.brand}})
  319. .then(response => {
  320. this.similarBrand = response.data
  321. this.showSimilarBrandList = response.data.length > 0
  322. })
  323. } else {
  324. this.showSimilarBrandList = false
  325. }
  326. },
  327. checkCode: function () {
  328. let code = this.applyObj.code.trim()
  329. let nullStrFlag = checkNullStr(code)
  330. this.validObj.code = code && code !== '' && nullStrFlag
  331. if (!this.validObj.code) {
  332. if (!nullStrFlag) {
  333. this.$message.error('型号输入不合法')
  334. } else {
  335. this.$message.error('型号不能为空')
  336. }
  337. }
  338. return this.validObj.code
  339. },
  340. checkBrand: function () {
  341. let nullStrFlag = checkNullStr(this.applyObj.brand)
  342. this.validObj.brand = this.applyObj.brand && this.applyObj.brand !== '' && nullStrFlag
  343. if (!this.validObj.brand) {
  344. if (!nullStrFlag) {
  345. this.$message.error('品牌输入不合法')
  346. } else {
  347. this.$message.error('品牌不能为空')
  348. }
  349. }
  350. return this.validObj.brand
  351. },
  352. checkUnitPrice: function () {
  353. this.validObj.unitPrice = this.applyObj.unitPrice === '' ? true : this.applyObj.unitPrice > 0 && this.applyObj.unitPrice < 100000000
  354. if (!this.validObj.unitPrice && this.applyObj.unitPrice <= 0) {
  355. this.$message.error('单价必须是大于0的数字')
  356. }
  357. return this.validObj.unitPrice
  358. },
  359. checkSpec: function () {
  360. let nullStrFlag = checkNullStr(this.applyObj.spec)
  361. this.validObj.spec = nullStrFlag
  362. if (!nullStrFlag) {
  363. this.$message.error('规格输入不合法')
  364. }
  365. return this.validObj.spec
  366. },
  367. checkAmount: function () {
  368. this.validObj.amount = this.applyObj.amount === '' ? true : this.applyObj.amount > 0 && this.applyObj.amount < 1000000000
  369. return this.validObj.amount
  370. },
  371. checkAll: function () {
  372. return this.checkCode() && this.checkBrand() && this.checkDeadline() && this.checkUnitPrice() && this.checkAmount() && this.checkSpec()
  373. },
  374. checkDeadline: function () {
  375. this.validObj.deadline = Boolean(this.applyObj.deadline)
  376. return this.validObj.deadline
  377. },
  378. setDeadLineValid: function () {
  379. this.applyObj.deadline = formatDate(this.applyObj.deadline, 'yyyy-MM-dd hh:mm:ss')
  380. this.validObj.deadline = true
  381. },
  382. onUnitPriceInput: function () {
  383. let price = this.applyObj.unitPrice
  384. if (price >= 10000) {
  385. this.applyObj.unitPrice = price.substring(0, 4)
  386. } else if (price.indexOf('.') > -1) {
  387. let arr = price.split('.')
  388. if (arr[0].length > 4) {
  389. this.applyObj.unitPrice = Number(arr[0].substring(0, 4) + '.' + arr[1])
  390. } else if (arr[1].length > 6) {
  391. this.applyObj.unitPrice = Number(arr[0] + '.' + arr[1].substring(0, 6))
  392. }
  393. }
  394. },
  395. onProduceDateChange: function () {
  396. if (this.applyObj.produceDate && getRealLen(this.applyObj.produceDate) > 12) {
  397. this.applyObj.produceDate = cutOutString(this.applyObj.produceDate, 12)
  398. }
  399. },
  400. onEncapsulationChange: function () {
  401. if (this.applyObj.encapsulation && getRealLen(this.applyObj.encapsulation) > 20) {
  402. this.applyObj.encapsulation = cutOutString(this.applyObj.encapsulation, 20)
  403. }
  404. },
  405. onProdTitleInput: function () {
  406. if (this.applyObj.prodTitle && getRealLen(this.applyObj.prodTitle) > 40) {
  407. this.applyObj.prodTitle = cutOutString(this.applyObj.prodTitle, 40)
  408. }
  409. },
  410. onSpecInput: function () {
  411. if (this.applyObj.spec && getRealLen(this.applyObj.spec) > 100) {
  412. this.applyObj.spec = cutOutString(this.applyObj.spec, 100)
  413. }
  414. },
  415. onCodeChange: function () {
  416. if ((/[^\x00-\xff]/g).test(this.applyObj.code)) {
  417. let chineseIndex = -1
  418. for (let i = 0; i < this.applyObj.code.length; i++) {
  419. if ((/[^\x00-\xff]/g).test(this.applyObj.code.charAt(i))) {
  420. chineseIndex = i
  421. break
  422. }
  423. }
  424. this.applyObj.code = cutOutString(this.applyObj.code, chineseIndex)
  425. } else if (this.applyObj.code && getRealLen(this.applyObj.code) > 100) {
  426. this.applyObj.code = cutOutString(this.applyObj.code, 100)
  427. } else {
  428. this.getSimilarCode()
  429. }
  430. },
  431. onBrandChange: function () {
  432. this.applyObj.brand = this.applyObj.brand.trim()
  433. if ((/[^\x00-\xff]/g).test(this.applyObj.brand)) {
  434. let chineseIndex = -1
  435. for (let i = 0; i < this.applyObj.brand.length; i++) {
  436. if ((/[^\x00-\xff]/g).test(this.applyObj.brand.charAt(i)) && !(/[\u4e00-\u9fa5]/).test(this.applyObj.brand.charAt(i))) {
  437. chineseIndex = i
  438. break
  439. }
  440. }
  441. if (chineseIndex > -1) {
  442. this.applyObj.brand = this.applyObj.brand.substring(0, chineseIndex)
  443. }
  444. } else if (this.applyObj.brand && getRealLen(this.applyObj.brand) > 50) {
  445. this.applyObj.brand = cutOutString(this.applyObj.brand, 50)
  446. } else {
  447. this.getSimilarBrand()
  448. }
  449. },
  450. onAmountInput: function () {
  451. if (!(/^[0-9]*$/).test(this.applyObj.amount)) {
  452. let chineseIndex = -1
  453. for (let i = 0; i < this.applyObj.amount.length; i++) {
  454. if (!(/^[0-9]*$/).test(this.applyObj.amount.charAt(i))) {
  455. chineseIndex = i
  456. break
  457. }
  458. }
  459. this.applyObj.amount = cutOutString(this.applyObj.amount, chineseIndex)
  460. } else if (this.applyObj.amount.length > 9) {
  461. this.applyObj.amount = cutOutString(this.applyObj.amount, 9)
  462. }
  463. },
  464. onSuccess: function (data) {
  465. if (!this.user.logged) {
  466. this.$router.push('/auth/login?returnUrl=' + window.location.href)
  467. } else if (data.success) {
  468. window.location.href = '/applyPurchase/' + data.data
  469. } else {
  470. this.$message.error(data.message)
  471. }
  472. },
  473. onError: function () {
  474. if (!this.user.logged) {
  475. this.$router.push('/auth/login?returnUrl=' + window.location.href)
  476. } else {
  477. this.$message.error('上传失败, 系统错误')
  478. }
  479. },
  480. downloadTemplate: function () {
  481. window.location.href = '/seek/release/template'
  482. },
  483. setCode: function (code) {
  484. this.applyObj.code = code
  485. this.showSimilarCodeList = false
  486. },
  487. setBrand: function (brand) {
  488. this.applyObj.brand = brand
  489. this.showSimilarBrandList = false
  490. }
  491. // upload: function (e) {
  492. // let file = e.target.files[0]
  493. // let param = new FormData()
  494. // param.append('file', file, file.name)
  495. // let config = {
  496. // headers: {'Content-Type': file.type}
  497. // }
  498. // this.$http.post('/seek/importBom', param, config).then(response => {
  499. // if (response.data.success) {
  500. // window.open('/applyPurchase/' + response.data.data)
  501. // } else {
  502. // this.$message.error('上传失败')
  503. // }
  504. // }, err => {
  505. // console.log(err)
  506. // this.$message.error('系统错误')
  507. // })
  508. // }
  509. }
  510. }
  511. </script>
  512. <style lang="scss">
  513. .publish-apply {
  514. background: url('/images/applyPurchase/banner.png') center center/cover no-repeat;
  515. height: 583px;
  516. padding-top: 290px;
  517. width: 1190px;
  518. margin: 0 auto;
  519. padding-left: 44px;
  520. >div {
  521. display: inline-block;
  522. border: 1px solid #3975f4;
  523. height: 267px;
  524. margin-right: 6px;
  525. vertical-align: middle;
  526. background: #fff;
  527. float: left;
  528. text-align: center;
  529. }
  530. .good-purchaser {
  531. width: 225px;
  532. .good-purchaser-title {
  533. height: 55px;
  534. line-height: 55px;
  535. background: #3975f4;
  536. margin: 0;
  537. }
  538. ul {
  539. padding: 0 22px 0 10px;
  540. li {
  541. line-height: 42px;
  542. span {
  543. float: right;
  544. display: inline-block;
  545. width: 152px;
  546. overflow: hidden;
  547. text-overflow: ellipsis;
  548. white-space: nowrap;
  549. text-align: left;
  550. }
  551. i {
  552. display: inline-block;
  553. float: left;
  554. width: 25px;
  555. color: #fff;
  556. font-size: 16px;
  557. font-style: normal;
  558. }
  559. }
  560. }
  561. }
  562. .publish-area {
  563. width: 549px;
  564. text-align: center;
  565. .publish-form-area {
  566. width: 243px;
  567. float: left;
  568. height: 100%;
  569. p {
  570. padding-top: 8px;
  571. font-size: 22px;
  572. color: #3975f4;
  573. margin-bottom: 4px;
  574. }
  575. >div {
  576. text-align: left;
  577. margin-left: 3px;
  578. .form-item {
  579. margin-bottom: 14px;
  580. position: relative;
  581. span {
  582. width: 109px;
  583. text-align: right;
  584. display: inline-block;
  585. i {
  586. position: relative;
  587. top: 2px;
  588. right: 3px;
  589. color: #e41515;
  590. }
  591. }
  592. ul {
  593. line-height: normal;
  594. position: absolute;
  595. top: 19px;
  596. left: 108px;
  597. background: #fff;
  598. border: 1px solid #b5b5b5;
  599. z-index: 1;
  600. max-height: 120px;
  601. overflow-y: auto;
  602. overflow-x: hidden;
  603. border-radius: 3px;
  604. width: 114px;
  605. font-size: 12px;
  606. li {
  607. height: 24px;
  608. line-height: 24px;
  609. cursor: pointer;
  610. overflow: hidden;
  611. text-overflow: ellipsis;
  612. white-space: nowrap;
  613. padding: 0 5px;
  614. &:hover {
  615. background: #ddd;
  616. }
  617. }
  618. }
  619. select {
  620. width: 32px;
  621. position: absolute;
  622. height: 20px;
  623. background: url('/images/applyPurchase/select.png')no-repeat right;
  624. background-position-x: 15px;
  625. padding: 0 0 0 3px;
  626. border-radius: 0;
  627. & + input {
  628. padding-left: 34px;
  629. }
  630. }
  631. .el-input {
  632. width: 111px;
  633. .el-input__inner {
  634. }
  635. }
  636. input {
  637. font-size: 12px;
  638. width: 111px;
  639. height: 18px;
  640. line-height: 18px;
  641. border-radius: 2px;
  642. padding: 0 3px;
  643. box-shadow: none;
  644. -webkit-box-shadow: none;
  645. -moz-box-shadow: none;
  646. &.error {
  647. border-color: #f4645f!important;
  648. }
  649. }
  650. }
  651. }
  652. >a {
  653. width: 90px;
  654. height: 25px;
  655. line-height: 25px;
  656. background: #3975f4;
  657. color: #fefefe;
  658. font-size: 16px;
  659. display: block;
  660. margin: 0 auto;
  661. border-radius: 3px;
  662. cursor: pointer;
  663. }
  664. }
  665. .publish-upload {
  666. background: url('/images/applyPurchase/publish-apply-bg.png')no-repeat;
  667. background-size: cover;
  668. width: 304px;
  669. height: 100%;
  670. padding-left: 22px;
  671. float: right;
  672. color: #fff;
  673. position: relative;
  674. h1 {
  675. font-size: 22px;
  676. margin: 11px 0 0 0;
  677. }
  678. h2 {
  679. font-size: 16px;
  680. margin: 10px 0 23px 0;
  681. }
  682. h3 {
  683. font-size: 16px;
  684. margin: 20px 0 13px 0;
  685. }
  686. label {
  687. position: relative;
  688. /*input {
  689. display: none;
  690. }*/
  691. > div {
  692. position: absolute;
  693. .el-upload {
  694. input {
  695. display: none;
  696. }
  697. .el-upload-dragger {
  698. width: 247px;
  699. height: 216px;
  700. position: absolute;
  701. bottom: -37px;
  702. right: -166px;
  703. opacity: 0;
  704. }
  705. }
  706. }
  707. }
  708. .download-line {
  709. cursor: pointer;
  710. color: #b47200;
  711. }
  712. .apply-logo {
  713. position: absolute;
  714. left: -20px;
  715. top: 86px;
  716. }
  717. }
  718. }
  719. .apply-rank {
  720. width: 317px;
  721. margin-right: 0;
  722. background: url('/images/applyPurchase/rank-title.png') no-repeat;
  723. background-color: #fff;
  724. background-size: 319px 74px;
  725. background-position: -3px -2px;
  726. table {
  727. margin: 76px auto 0;
  728. width: 98%;
  729. thead {
  730. background: #e0e0e0;
  731. height: 26px;
  732. line-height: 26px;
  733. border-radius: 3px;
  734. tr {
  735. th {
  736. font-size: 16px;
  737. font-weight: bold;
  738. text-align: center;
  739. }
  740. }
  741. }
  742. tbody {
  743. tr {
  744. height: 25px;
  745. line-height: 25px;
  746. &:first-child {
  747. td {
  748. padding-top: 10px;
  749. }
  750. }
  751. td {
  752. color: #666;
  753. &:nth-child(1) {
  754. color: #f6682f;
  755. font-size: 12px;
  756. >div {
  757. width: 62px;
  758. span {
  759. font-size: 16px;
  760. }
  761. }
  762. }
  763. &:nth-child(2) {
  764. >div {
  765. width: 160px;
  766. }
  767. }
  768. &:nth-child(3) {
  769. >div {
  770. width: 92px;
  771. }
  772. }
  773. >div {
  774. overflow: hidden;
  775. text-overflow: ellipsis;
  776. white-space: nowrap;
  777. padding: 0 8px;
  778. position: relative;
  779. height: 30px;
  780. i {
  781. font-style: normal;
  782. float: right;
  783. color: #8b8b8b;
  784. font-size: 14px;
  785. position: absolute;
  786. right: 0;
  787. }
  788. }
  789. }
  790. }
  791. }
  792. }
  793. }
  794. .apply-del-box{
  795. position: fixed;
  796. z-index: 1000;
  797. height: auto;
  798. opacity: 1;
  799. background-color: white;
  800. width: 310px;
  801. -webkit-box-shadow: 0 5px 15px rgba(0,0,0,.5);
  802. -moz-box-shadow: 0 5px 15px rgba(0,0,0,.5);
  803. -o-box-shadow: 0 5px 15px rgba(0,0,0,.5);
  804. box-shadow: 0 5px 15px rgba(0,0,0,.5);
  805. margin: -155px 0 0 -75px;
  806. top: 55%;
  807. left: 43%;
  808. .title{
  809. height: 24px;
  810. background-color: #007aff;
  811. text-align: right;
  812. padding-right: 15px;
  813. line-height: 24px;
  814. a{
  815. color: white;
  816. font-size: 12px;
  817. }
  818. }
  819. .content{
  820. width: 100%;
  821. text-align: center;
  822. margin: 0 auto;
  823. p{
  824. padding: 12px 31px;
  825. margin: 0;
  826. i{
  827. color: #5078cb;
  828. font-size: 16px;
  829. margin-right: 10px;
  830. }
  831. span {
  832. color: #007aff;
  833. }
  834. &:last-child {
  835. font-size: 12px;
  836. }
  837. }
  838. div{
  839. width: 100%;
  840. text-align: center;
  841. margin: 0 auto 20px;
  842. a{
  843. padding: 0 19px;
  844. height: 26px;
  845. line-height: 26px;
  846. display: inline-block;
  847. text-align: center;
  848. font-size: 14px;
  849. color: #fff;
  850. &:first-child{
  851. background: #c8c6c6;
  852. margin-right: 10px;
  853. }
  854. &:last-child{
  855. background: #007aff;
  856. }
  857. }
  858. }
  859. }
  860. }
  861. }
  862. .el-date-editor--date{
  863. width: 110px;
  864. &.error {
  865. input {
  866. border: 1px solid #f4645f !important;
  867. }
  868. }
  869. }
  870. .el-icon-date {
  871. display: none;
  872. }
  873. .el-input__inner {
  874. height: 20px;
  875. border-radius: 0;
  876. border: 1px solid #c9c9c9;
  877. }
  878. </style>