This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import $ from 'jquery'; | |
| import Swiper from 'swiper'; | |
| import 'swiper/dist/css/swiper.min.css'; | |
| $(function () { | |
| var mySwiper = null; | |
| // page load complete |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script> | |
| import emitter from 'element-ui/src/mixins/emitter'; | |
| export default { | |
| mixins: [emitter], | |
| props: { | |
| value: Number, | |
| max: { type: Number, default: 99999 }, | |
| min: { type: Number, default: 0 }, | |
| int: { type: Boolean, default: false }, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import axios from 'axios' | |
| import { Message } from 'element-ui' | |
| export const baseUrl = 'http://example.com/api'; | |
| const transformRequest = (data={}) => { | |
| if (typeof data === 'string') return data; | |
| if (!data.oauth) | |
| data.oauth = localStorage.getItem("token")? localStorage.getItem("token"): (sessionStorage.getItem("token") || ""); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template lang="pug"> | |
| el-table(:data="data" border) | |
| el-table-column(label="批次") | |
| template(scope="scope") | |
| el-autocomplete(v-model="scope.row.rowTempModel.batch" :maxlength="50" style="width:100%;" | |
| :fetch-suggestions="(queryString, cb) => {\ | |
| searchBatchOpt(scope.row, scope.$index).then(batchs => { \ | |
| let suggestions = batchs.map(batch => ({value: batch})); \ | |
| queryString ? cb(suggestions.filter(suggestion => suggestion.value.indexOf(queryString) > -1)) : cb(suggestions.slice(0,6))\ | |
| });\ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template lang="pug"> | |
| #date-grid | |
| table.date-grid | |
| thead | |
| th 班次\日期 | |
| th(v-for="num in colNum" :key="num.$index") {{ num }} | |
| tbody | |
| tr(v-for="(classTime, rowIndex) in classTimeList" :key="rowIndex") | |
| th {{ classTime.name }} | |
| template(v-for="(cell, colIndex) in cells[rowIndex]") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template> | |
| <div> | |
| <crud :data="data" :form="form" :rules="rules" :fields="mapItems" | |
| :editing="editing" @open="handleOpen" @close="handleClose" | |
| @create="handleCreate" @update="handleUpdate" @destroy="handleDestroy" @submit="handleSubmit"/> | |
| </div> | |
| </template> | |
| <script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template> | |
| <div> | |
| <el-pagination | |
| v-if="pagination.total > 10" | |
| @size-change="handleSizeChange" | |
| @current-change="handleCurrentChange" | |
| :current-page="pagination.current" | |
| :page-sizes="pagination.sizes" | |
| :page-size="pagination.size" | |
| layout="sizes, prev, pager, next" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { api } from './configure' | |
| export const Accessory = api('accessory') | |
| export const Supplier = api('supplier') | |
| export const Device = api('device') | |
| export const Dict = api('dict') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| watch: { | |
| 'form.amount'(val, oldVal) { | |
| if (!Number.isInteger(val)) { | |
| this.$nextTick(() => { | |
| this.form.amount = parseInt(val, 10) | |
| }) | |
| } | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <template> | |
| <div> | |
| <m-searcher :kw="kw" :fields="searchFields" :placeholders="placeholders" @search="loadData"> | |
| <el-select v-model="kw.moldsId" clearable size="small" @clear="loadData" class="search-box__input"> | |
| <el-option :key="index" v-for="(o, index) in molds" | |
| :label="o.code" :value="o.id"/> | |
| </el-select> | |
| </m-searcher> | |
| </div> | |
| </template> |
OlderNewer