upoff-material.vue 28 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728
  1. <template>
  2. <div class="upoff-material-wrapper" v-if="showUpoff">
  3. <div class="mobile-nav">
  4. <div class="mobile-header mobile-center-header">
  5. <a @click="hide"><i class="iconfont icon-fanhui"></i></a>
  6. <p>编辑上下架</p>
  7. <p class="en-name">
  8. <img :src="`/images/mobile/center/${user.data.enterprise && user.data.enterprise.uu ? 'en' : 'self'}.png`" alt="">{{currentEnName}}
  9. </p>
  10. </div>
  11. </div>
  12. <div class="upoff-materiel-wrapper" @click="clearInfo()">
  13. <div ref="scroll" style="height: 100%;overflow-y:scroll">
  14. <div>
  15. <div style="background: #fff;border: 1px solid #dcdcdc;padding:0 0.2rem 0.5rem">
  16. <div class="opoff-title clearfix">
  17. <!-- :class="item.standard ? 'standed' : 'istanded'"-->
  18. <div class="icon" :class="chooseItem.standard === 1 ? 'standed' : 'istanded'"></div>
  19. <div class="opoff-title-text pull-left">{{chooseItem.pcmpcode || '-'}}</div>
  20. </div>
  21. <div class="off-content">
  22. <div class="clearfix">
  23. <span class="name">品牌:</span>
  24. <span class="con">{{chooseItem.pbranden || chooseItem.pbrand || '-'}}</span>
  25. </div>
  26. <div class="clearfix">
  27. <span class="name">物料名称:</span>
  28. <span class="con">{{chooseItem.kind || chooseItem.kinden || '-'}}</span>
  29. </div>
  30. <div class="clearfix">
  31. <span class="name">规格:</span>
  32. <span class="con">{{chooseItem.spec || '-'}}</span>
  33. </div>
  34. <div class="clearfix">
  35. <span class="name">库存(PCS):</span>
  36. <span class="con">{{chooseItem.erpReserve || '-'}}</span>
  37. </div>
  38. <div class="clearfix">
  39. <span class="name">平均成本:</span>
  40. <span class="con">{{chooseItem.price || '-'}}</span>
  41. </div>
  42. </div>
  43. <div class="off-info clearfix">
  44. <div class="minBuyqty pull-left">
  45. <span>最小起订量:</span>
  46. <input type="number" maxlength="10" @blur="minBuyQtyBlur()" v-model="chooseItem.goods.minBuyQty" placeholder="请输入最小起订量" />
  47. </div>
  48. <div class="pull-left" style="margin-left:0.2rem">
  49. <span>可拆卖:</span>
  50. <div class="progress-wrapper" :class="{active: chooseItem.goods.breakUp}" @click="changeBreakUp()">
  51. <div class="progress-btn"></div>
  52. </div>
  53. </div>
  54. <div class="pull-left">
  55. <span>上架:</span>
  56. <div class="progress-wrapper" :class="{active: chooseItem.goods.autoPublish}" @click="changeautoPublish()">
  57. <div class="progress-btn"></div>
  58. </div>
  59. </div>
  60. </div>
  61. <div class="off-info clearfix">
  62. <div class="pull-left">
  63. <span class="name">销售方式:</span>
  64. <div class="selectInput" @click.stop="showdropmenu()">
  65. <span v-if="chooseItem.storeInfoOms">{{chooseItem.storeInfoOms}}</span>
  66. <span v-else>{{chooseItem.goods.storeid === '33069557578d44e69bd91ad12d28a8d4' ? '寄售' : '自营'}}</span>
  67. <img src="/images/mobile/product/drop_icon.png" v-if="!ShowShopshelfOff"/>
  68. <ul :class="{active : showDrop }" v-if="!ShowShopshelfOff">
  69. <li v-for="item in storeObj" @click.stop="chooseStore(item)">{{item}}</li>
  70. </ul>
  71. </div>
  72. </div>
  73. <div class="pull-left" style="margin-left: 0.2rem">
  74. <span class="name">交期:</span>
  75. <input type="tel" placeholder="天数" v-model="chooseItem.goods.minDelivery" class="input startInput" maxlength="3" @blur="minDeliveryBlur(chooseItem.goods.minDelivery)" />
  76. -
  77. <input type="tel" placeholder="天数" v-model="chooseItem.goods.maxDelivery" class="input endInput" maxlength="3" @blur="minDeliveryBlur(chooseItem.goods.maxDelivery)"/>
  78. </div>
  79. </div>
  80. <div class="off-info clearfix">
  81. <div class="pscList-top clearfix">
  82. <div class="pull-left">梯度/pcs</div>
  83. <div class="pull-right">单价</div>
  84. </div>
  85. <ul class="prices">
  86. <li v-for="(item, index) in chooseItem.goods.prices" v-bind:key="index">
  87. <div class="clearfix">
  88. <div class="pull-left">
  89. <input v-if="index > 0" oninput="if(value.length>5)value=value.slice(0,9)"
  90. type="tel" placeholder="数量" class="otherNumber"
  91. :class="{firstNumber: index === 0}"
  92. v-model.lazy.trim="item.start"
  93. :disabled="index === 0" :readonly="index === 0"
  94. @blur="startpriceBlur(item, index)" maxlength="9"
  95. />
  96. <input v-else oninput="if(value.length>5)value=value.slice(0,9)"
  97. type="tel" placeholder="数量" class="otherNumber"
  98. :class="{firstNumber: index === 0}"
  99. v-model.lazy.trim="chooseItem.goods.minBuyQty"
  100. :disabled="index === 0" :readonly="index === 0"
  101. @blur="startpriceBlur(item, index)" maxlength="9"
  102. />
  103. <!--<label v-if="index !== chooseItem.goods.prices.length - 1">-</label>-->
  104. <label v-if="index !== chooseItem.goods.prices.length - 1">以上</label>
  105. <label v-if="index === chooseItem.goods.prices.length - 1">以上</label>
  106. <!--<input oninput="if(value.length>5)value=value.slice(0,9)"-->
  107. <!--type="tel" placeholder="数量" class="otherNumber"-->
  108. <!--v-model.lazy.trim="item.end"-->
  109. <!--v-if="index !== chooseItem.goods.prices.length - 1"-->
  110. <!--@blur="endpriceBlur(item, index)"-->
  111. <!--maxlength="9"/>-->
  112. </div>
  113. <div class="pull-right">
  114. <input v-show="chooseItem.currencyName === 'RMB'"
  115. class="priceM" type="text"
  116. placeholder="单价(¥)"
  117. v-model.lazy="item.rMBPrice"
  118. @blur="rMBPriceBlur(item)"/>
  119. <input v-show="chooseItem.currencyName !== 'RMB'"
  120. class="priceM" type="text"
  121. placeholder="单价($)"
  122. v-model.lazy="item.rMBPrice"
  123. @blur="rMBPriceBlur(item)"/>
  124. <span @click="miuPrice(index)" class="clearfix"><img class="pull-left" src="/images/mobile/product/mui_icon.png"/></span>
  125. <span @click="addPrice()" class="clearfix"><img class="pull-left"src="/images/mobile/product/add_icon.png"/></span>
  126. </div>
  127. </div>
  128. </li>
  129. </ul>
  130. </div>
  131. </div>
  132. <div class="update-materiel-wrapper-controll clearfix">
  133. <div class="pull-left" @click.stop="saveMateriel()">保存</div>
  134. <div class="pull-right" @click.stop="hide('cancel')">取消</div>
  135. </div>
  136. </div>
  137. </div>
  138. </div>
  139. <remind-box :title="collectResult" :timeoutCount="timeoutCount"></remind-box>
  140. </div>
  141. </template>
  142. <script>
  143. import { RemindBox } from '~components/mobile/common'
  144. export default {
  145. props: {
  146. chooseItem: {
  147. type: Object,
  148. default: {}
  149. }
  150. },
  151. computed: {
  152. storeInfoStore() {
  153. return this.$store.state.option.storeStatus.data
  154. }
  155. },
  156. data() {
  157. return {
  158. collectResult: '',
  159. timeoutCount: 0,
  160. ShowShopshelfOff: false,
  161. showDrop: false,
  162. storeObj: ['寄售', '自营'],
  163. showUpoff: false
  164. }
  165. },
  166. methods: {
  167. clearInfo() {},
  168. changeBreakUp() {
  169. this.chooseItem.goods.breakUp = !this.chooseItem.goods.breakUp
  170. this.minBuyQtyBlur()
  171. },
  172. saveMateriel() {
  173. if (!/^\d{1,6}$/.test(this.chooseItem.goods.minBuyQty)) {
  174. this.timeoutCount++
  175. this.collectResult = '最小起订量只能输入数字'
  176. return false
  177. } else if (this.chooseItem.goods.minBuyQty && !toString(this.chooseItem.goods.minBuyQty).trim()) {
  178. this.timeoutCount++
  179. this.collectResult = '最小起订量不能为空'
  180. return false
  181. } else if (!this.chooseItem.goods.minDelivery && !toString(this.chooseItem.goods.minDelivery).trim()) {
  182. this.timeoutCount++
  183. this.collectResult = '请填写最小交期时间'
  184. return false
  185. } else if (!this.chooseItem.goods.maxDelivery && !toString(this.chooseItem.goods.maxDelivery).trim()) {
  186. this.timeoutCount++
  187. this.collectResult = '请填写最大交期时间'
  188. return false
  189. } else if (!this.chooseItem.goods.minDelivery || !this.chooseItem.goods.maxDelivery) {
  190. this.timeoutCount++
  191. this.collectResult = '交期不能为空'
  192. return false
  193. } else if (!/^\d{1,3}$/.test(this.chooseItem.goods.minDelivery) || !/^\d{1,3}$/.test(this.chooseItem.goods.maxDelivery)) {
  194. this.timeoutCount++
  195. this.collectResult = '交期只能输入数字'
  196. return false
  197. } else {
  198. let isHas = false
  199. for (let i = 0; i < this.chooseItem.goods.prices.length; i++) {
  200. if (!this.chooseItem.goods.prices[i].start) {
  201. this.timeoutCount++
  202. this.collectResult = '分段数量必须填写'
  203. isHas = true
  204. break
  205. } else if (Math.abs(this.chooseItem.goods.prices[i].rMBPrice) <= 0) {
  206. this.timeoutCount++
  207. this.collectResult = '单价必须是大于0的数字'
  208. isHas = true
  209. break
  210. } else if (!/^\d+$/.test(this.chooseItem.goods.prices[i].start) || (this.chooseItem.goods.prices[i].end !== '' && !/^\d+$/.test(this.chooseItem.goods.prices[i].end))) {
  211. this.timeoutCount++
  212. this.collectResult = '分段数量必须是正整数'
  213. isHas = true
  214. break
  215. } else if (!/^[0-9]+([.]{1}[0-9]{1,6})?$/.test(this.chooseItem.goods.prices[i].rMBPrice)) {
  216. this.timeoutCount++
  217. this.collectResult = '单价只能输入数字'
  218. isHas = true
  219. break
  220. }
  221. }
  222. if (isHas === true) {
  223. return false
  224. }
  225. }
  226. this.chooseItem.goods.selfSale = this.storeInfoStore.uuid ? 1 : 2
  227. if (!this.chooseItem.storeInfoOms) {
  228. this.chooseItem.storeInfoOms = this.chooseItem.goods.storeid === '33069557578d44e69bd91ad12d28a8d4' ? '寄售' : '自营'
  229. }
  230. if (this.storeInfoStore.uuid) {
  231. if (this.chooseItem.storeInfoOms === '寄售') {
  232. this.chooseItem.goods.selfSale = 2
  233. } else if (this.chooseItem.storeInfoOms === '自营') {
  234. this.chooseItem.goods.selfSale = 1
  235. }
  236. }
  237. this.chooseItem.goods.prices[this.chooseItem.goods.prices.length - 1].end = '9999999999'
  238. this.$http.put('/trade/goods', this.chooseItem.goods).then(res => {
  239. if (res.data.success) {
  240. this.timeoutCount++
  241. this.collectResult = '保存成功'
  242. setTimeout(() => {
  243. this.hide()
  244. }, 300)
  245. } else {
  246. this.timeoutCount++
  247. this.collectResult = res.data.message
  248. }
  249. }, err => {
  250. this.timeoutCount++
  251. this.collectResult = err.response.data
  252. })
  253. },
  254. // 最低起订量失去焦点操作
  255. minBuyQtyBlur() {
  256. if (Math.abs(this.chooseItem.minPackQty) <= 0) {
  257. this.timeoutCount++
  258. this.collectResult = '包装数必须是大于0的整数'
  259. this.chooseItem.minPackQty = 1
  260. } else if (Math.abs(this.chooseItem.goods.minBuyQty) <= 0) {
  261. this.timeoutCount++
  262. this.collectResult = '起订量必须是大于0的整数'
  263. this.chooseItem.goods.minBuyQty = 1
  264. } else if ((!this.chooseItem.breakUp && this.chooseItem.goods.minBuyQty) && this.chooseItem.goods.minBuyQty % this.chooseItem.minPackQty !== 0) {
  265. this.timeoutCount++
  266. this.collectResult = '不可拆卖时,起订量必须是包装数量的倍数'
  267. if (!this.chooseItem.minPackQty) {
  268. this.chooseItem.minPackQty = 1
  269. } else {
  270. if (this.chooseItem.minPackQty > this.chooseItem.goods.minBuyQty) {
  271. this.chooseItem.goods.minBuyQty = this.chooseItem.minPackQty
  272. } else {
  273. this.chooseItem.goods.minBuyQty = this.chooseItem.goods.minBuyQty - this.chooseItem.goods.minBuyQty % this.chooseItem.minPackQty
  274. }
  275. }
  276. }
  277. this.chooseItem.goods.prices[0].start = this.chooseItem.goods.minBuyQty
  278. },
  279. changeautoPublish() {
  280. this.chooseItem.goods.autoPublish = !this.chooseItem.goods.autoPublish
  281. },
  282. showdropmenu() {
  283. this.showDrop = !this.showDrop
  284. },
  285. // 选择销售方式
  286. chooseStore(item) {
  287. this.chooseItem.storeInfoOms = item
  288. this.showdropmenu()
  289. },
  290. minDeliveryBlur(str) {
  291. if (Math.abs(this.chooseItem.goods.minDelivery) === 0) {
  292. this.timeoutCount++
  293. this.collectResult = `交期天数不能为0`
  294. this.chooseItem.goods.minDelivery = ''
  295. return false
  296. } else if (Math.abs(this.chooseItem.goods.minDelivery) === 0) {
  297. this.timeoutCount++
  298. this.collectResult = `交期天数不能为0`
  299. this.chooseItem.goods.minDelivery = ''
  300. return false
  301. }
  302. if (Math.abs(this.chooseItem.goods.minDelivery) > Math.abs(this.chooseItem.goods.minDelivery)) {
  303. this.timeoutCount++
  304. this.collectResult = `最短交期应小于等于最长交期`
  305. this.chooseItem.goods.minDelivery = ''
  306. }
  307. },
  308. show() {
  309. this.showUpoff = true
  310. },
  311. hide(type) {
  312. this.showUpoff = false
  313. this.$emit('upoffMaterial', type, this.chooseItem)
  314. },
  315. // 开始价格阶段失去焦点
  316. startpriceBlur(item, index) {
  317. if (index > 0) {
  318. if (item.start === '' || toString(item.start).trim() === '') {
  319. return false
  320. } else if (this.chooseItem.goods.prices[index].start <= this.chooseItem.goods.prices[index - 1].start){
  321. this.timeoutCount++
  322. this.collectResult = '输入值会导致梯度重叠,请重新修改'
  323. item.start = ''
  324. }
  325. this.chooseItem.goods.prices[index - 1].end = item.start - 1
  326. }
  327. },
  328. // 单价失去焦点
  329. rMBPriceBlur(item) {
  330. if (item.rMBPrice === '' || !item.rMBPrice) { return false }
  331. if (!/^[0-9]+([.]{1}[0-9]{1,6})?$/.test(item.rMBPrice)) {
  332. this.timeoutCount++
  333. this.collectResult = '单价只能输入数字带6位小数'
  334. } else if (Math.abs(item.rMBPrice) === 0) {
  335. return false
  336. } else if (Math.abs(item.rMBPrice) >= 10000) {
  337. this.timeoutCount++
  338. item.rMBPrice = 9999
  339. this.collectResult = '单价不能高于10000'
  340. return false
  341. }
  342. item.rMBPrice = item.rMBPrice.toString()
  343. let splits = item.rMBPrice.split('.')
  344. if (splits[0].length >= 4) {
  345. splits[0] = splits[0].substr(0, 4)
  346. item.rMBPrice = splits[0]
  347. }
  348. if (splits[1]) {
  349. item.rMBPrice = splits[0] + '.' + splits[1]
  350. }
  351. if (splits[1] && splits[1].length > 6) {
  352. splits[1] = splits[1].substr(0, 7)
  353. let str = splits[1].substr(0, 6)
  354. if (splits[1][splits[1].length - 1] >= 5) {
  355. str = splits[1].substr(0, 6)
  356. str = Math.abs(str) + 1
  357. }
  358. item.rMBPrice = splits[0] + '.' + Math.ceil(str)
  359. }
  360. },
  361. addPrice() {
  362. if (this.chooseItem.goods.prices.length === 3) {
  363. this.timeoutCount++
  364. this.collectResult = '价格梯度最多只能有三个分段'
  365. return false
  366. }
  367. let copy = Object.assign({}, this.chooseItem.goods.prices[this.chooseItem.goods.prices.length - 1], {
  368. end: ''
  369. })
  370. this.chooseItem.goods.prices[this.chooseItem.goods.prices.length - 1] = copy
  371. this.chooseItem.goods.prices.push({
  372. end: '',
  373. rMBNTPrice: '',
  374. rMBPrice: '',
  375. start: ''
  376. })
  377. },
  378. miuPrice(index) {
  379. if (index === 0) {
  380. if (this.chooseItem.goods.prices.length === 3) {
  381. this.chooseItem.goods.prices[0].rMBPrice = this.chooseItem.goods.prices[1].rMBPrice
  382. this.chooseItem.goods.prices[0].end = this.chooseItem.goods.prices[1].end
  383. this.chooseItem.goods.prices[1].start = this.chooseItem.goods.prices[2].start
  384. this.chooseItem.goods.prices[1].rMBPrice = this.chooseItem.goods.prices[2].rMBPrice
  385. this.chooseItem.goods.prices[1].end = '9999999999'
  386. this.chooseItem.goods.prices.splice(2, 1)
  387. } else {
  388. index++
  389. if (this.chooseItem.goods.prices.length === 1) return
  390. this.chooseItem.goods.prices[0].rMBPrice = this.chooseItem.goods.prices[1].rMBPrice
  391. this.chooseItem.goods.prices[0].end = '9999999999'
  392. this.chooseItem.goods.prices.splice(index, 1)
  393. }
  394. } else if (index === 1) {
  395. if (this.chooseItem.prices.goods.length === 3) {
  396. this.chooseItem.goods.prices[1].rMBPrice = this.chooseItem.goods.prices[2].rMBPrice
  397. this.chooseItem.goods.prices[1].end = '9999999999'
  398. this.chooseItem.goods.prices.splice(2, 1)
  399. } else {
  400. this.chooseItem.goods.prices[0].end = '9999999999'
  401. this.chooseItem.goods.prices.splice(index, 1)
  402. }
  403. } else {
  404. this.chooseItem.goods.prices[1].end = '9999999999'
  405. this.chooseItem.goods.prices.splice(index, 1)
  406. }
  407. console.log(this.chooseItem.goods.prices)
  408. },
  409. // 结束价格阶段失去焦点
  410. endpriceBlur(item, index) {
  411. if (item.end === '') {
  412. return false
  413. } else if (Math.abs(item.end) + 1 <= Math.abs(item.start)) {
  414. this.timeoutCount++
  415. this.collectResult = `输入值不能小于${item.start}`
  416. item.end = ''
  417. return false
  418. } else if (this.chooseItem.goods.prices[index + 1].start !== '' && toString(this.chooseItem.goods.prices[index + 1].start).trim() !== '' && Math.abs(item.end) + 1 > Math.abs(this.chooseItem.goods.prices[index + 1].start)) {
  419. this.timeoutCount++
  420. this.collectResult = `输入值不能大于${this.chooseItem.goods.prices[index + 1].start - 1}`
  421. item.end = ''
  422. return false
  423. } else if (this.chooseItem.goods.prices[index + 1].end !== '' && toString(this.chooseItem.goods.prices[index + 1].end).trim() !== '' && Math.abs(item.end) + 1 > Math.abs(this.chooseItem.goods.prices[index + 1].end)) {
  424. this.timeoutCount++
  425. this.collectResult = `输入值不能大于${this.chooseItem.goods.prices[index + 1].end}`
  426. item.end = ''
  427. return false
  428. }
  429. this.chooseItem.goods.prices[index + 1].start = Math.abs(item.end) + 1
  430. console.log(this.chooseItem.goods.prices)
  431. }
  432. },
  433. components: {
  434. RemindBox
  435. }
  436. }
  437. </script>
  438. <style scoped lang='scss'>
  439. @mixin overFlowHidden {
  440. overflow: hidden;
  441. text-overflow: ellipsis;
  442. white-space: nowrap;
  443. }
  444. @mixin lineHeight($value) {
  445. height: $value;
  446. line-height: $value;
  447. }
  448. .upoff-material-wrapper {
  449. position: fixed;
  450. z-index: 1000;
  451. background: #f1f3f6;
  452. /*background: red;*/
  453. top: 0;
  454. left: 0;
  455. bottom: 0;
  456. right: 0;
  457. .mobile-header{
  458. position: fixed;
  459. top: 0;
  460. z-index: 100;
  461. width:100%;
  462. height: 1.26rem;
  463. line-height: 1.26rem;
  464. /*border-bottom:.01rem solid #ccc;*/
  465. background: #3e82f5;
  466. padding:0 .2rem 0 .1rem;
  467. color:#fff;
  468. }
  469. .mobile-header p{
  470. overflow: hidden;
  471. text-overflow: ellipsis;
  472. white-space: nowrap;
  473. font-size:.36rem;
  474. text-align: center;
  475. width: 6rem;
  476. padding-left: 1rem;
  477. }
  478. .mobile-center-header p.en-name {
  479. font-size: .3rem;
  480. }
  481. .mobile-header a{
  482. font-size:.28rem;
  483. color:#fff;
  484. position: absolute;
  485. }
  486. .mobile-header a i{
  487. font-size: .48rem;
  488. margin-right: -.1rem;
  489. }
  490. .upoff-materiel-wrapper {
  491. border-radius: 0.07rem;
  492. position: fixed;
  493. overflow: hidden;
  494. bottom: 0;
  495. top: 1.46rem;
  496. left: 0.2rem;
  497. right: 0.2rem;
  498. /*padding: 0 0.25rem;*/
  499. /*background: #fff;*/
  500. .opoff-title {
  501. border-bottom: 1px solid #dcdcdc;
  502. padding: 0.25rem 0;
  503. .opoff-title-text {
  504. font-size: 0.28rem;
  505. color: #3f84f6;
  506. @include overFlowHidden();
  507. width: 5.81rem;
  508. }
  509. .icon {
  510. width: 0.6rem;
  511. height: 0.36rem;
  512. line-height: 0.36rem;
  513. float: left;
  514. background-size: 100%;
  515. background-repeat: no-repeat;
  516. margin-right: 0.12rem;
  517. text-align: center;
  518. &.istanded {
  519. background-image: url('/images/mobile/@2x/istanded.png')
  520. }
  521. &.standed {
  522. background-image: url('/images/mobile/@2x/standed.png')
  523. }
  524. }
  525. }
  526. .off-content {
  527. padding: 0.42rem 0;
  528. border-bottom: 1px solid #dcdcdc;
  529. .clearfix {
  530. margin-bottom: 0.25rem;
  531. &:nth-last-of-type(1) {
  532. margin-bottom: 0;
  533. }
  534. @include overFlowHidden();
  535. }
  536. .name {
  537. color: #666;
  538. font-size:0.28rem;
  539. }
  540. .con{
  541. color: #333;
  542. font-size:0.28rem;
  543. }
  544. }
  545. .off-info {
  546. margin-top: 0.3rem;
  547. line-height: 0.5rem;
  548. span {
  549. color: #666;
  550. font-size: 0.28rem;
  551. }
  552. .minBuyqty {
  553. input {
  554. border: 1px solid #d2d2d2;
  555. border-radius: 2px;
  556. text-indent: .12rem;
  557. width: 1.5rem;
  558. font-size: 0.24rem;
  559. color: #333;
  560. }
  561. }
  562. .progress-wrapper {
  563. width: .68rem;
  564. height: .32rem;
  565. border-radius: 0.32rem;
  566. position: relative;
  567. display: inline-block;
  568. vertical-align: top;
  569. margin-left: 0.15rem;
  570. margin-top: 0.12rem;
  571. background: #c4c5c6;
  572. .progress-btn {
  573. position: absolute;
  574. height: 0.28rem;
  575. width: 0.28rem;
  576. border-radius: 50%;
  577. left: 0.01rem;
  578. top: 0.01rem;
  579. background: #fff;
  580. box-shadow: 0 0 5px #000;
  581. }
  582. &.active {
  583. background: #22ac38;
  584. .progress-btn {
  585. left: 0.37rem;
  586. }
  587. }
  588. }
  589. .selectInput {
  590. display: inline-block;
  591. position: relative;
  592. vertical-align: top;
  593. height: 0.5rem;
  594. line-height: 0.5rem;
  595. border: 1px solid #d2d2d2;
  596. border-radius: 2px;
  597. width: 1.78rem;
  598. text-indent: 0.12rem;
  599. img {
  600. position: absolute;
  601. width: 0.17rem;
  602. height: 0.11rem;
  603. right:0.1rem;
  604. top: 0.17rem;
  605. }
  606. &.selectInput2 {
  607. width: 1.56rem;
  608. }
  609. span {
  610. height: 0.5rem;
  611. line-height: 0.5rem;
  612. display: block;
  613. }
  614. ul {
  615. position: absolute;
  616. left: 0;
  617. top: .5rem;
  618. z-index: 12;
  619. width: 100%;
  620. max-height: 3rem;
  621. overflow-y: auto;
  622. display: none;
  623. li {
  624. text-indent: 0px;
  625. width: 100%;
  626. background: #666;
  627. color: rgba(255, 255, 255, 0.89);
  628. text-align: center;
  629. font-size: .3rem;
  630. }
  631. &.active {
  632. display: block;
  633. }
  634. }
  635. }
  636. .startInput, .endInput {
  637. text-indent: 0;
  638. text-align: center;
  639. width: 1rem;
  640. height: 0.5rem;
  641. line-height: 0.5rem;
  642. border: 1px solid #d2d2d2;
  643. border-radius: 2px;
  644. }
  645. .pscList-top {
  646. height: 0.5rem;
  647. line-height: 0.5rem;
  648. background: #e5e5e5;
  649. font-size: 0.28rem;
  650. color: #666;
  651. border-radius: 3px;
  652. .pull-left {
  653. margin-left: 0.2rem
  654. }
  655. .pull-right {
  656. margin-right: 0.2rem
  657. }
  658. }
  659. ul.prices{
  660. margin: 0.2rem 0 0;
  661. padding-bottom: 0.2rem;
  662. .clearfix {
  663. margin-bottom: 0.14rem;
  664. font-size: 0.24rem;
  665. color: #666;
  666. .priceM {
  667. width: 1.6rem;
  668. height: 0.5rem;
  669. border: 1px solid #d2d2d2;
  670. text-align: center;
  671. line-height: 0.5rem;
  672. border-radius: 3px;
  673. }
  674. span {
  675. width: 0.34rem;
  676. height: 0.34rem;
  677. margin-top: 0.08rem;
  678. display: inline-block;
  679. vertical-align: top;
  680. &:nth-of-type(1){
  681. margin: 0.08rem 0.2rem 0;
  682. }
  683. img {
  684. width: 100%;
  685. }
  686. }
  687. .firstNumber {
  688. width: 0.4rem;
  689. background: #eeeeee !important;
  690. height: 0.5rem;
  691. border:1px solid #d2d2d2;
  692. border-radius: 3px;
  693. line-height: 0.5rem;
  694. text-align: center;
  695. font-size: 0.24rem;
  696. }
  697. .otherNumber {
  698. width: 1.6rem;
  699. background: #fff;
  700. height: 0.5rem;
  701. border:1px solid #d2d2d2;
  702. border-radius: 3px;
  703. line-height: 0.5rem;
  704. text-align: center;
  705. font-size: 0.24rem;
  706. }
  707. }
  708. }
  709. }
  710. }
  711. .update-materiel-wrapper-controll {
  712. margin: 0.4rem 0.2rem 0;
  713. div {
  714. width: 48%;
  715. background: #b5b5b5;
  716. font-size: 0.3rem;
  717. color: #fafbfc;
  718. text-align: center;
  719. @include lineHeight(0.62rem);
  720. border-radius: 0.07rem;
  721. &:first-child {
  722. background: #3f84f6;
  723. }
  724. }
  725. }
  726. }
  727. </style>