|
|
@@ -28,10 +28,10 @@
|
|
|
<el-form-item label="订单类型">
|
|
|
<el-select v-model="value" placeholder="请选择订单类型">
|
|
|
<el-option
|
|
|
- v-for="item in options"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value">
|
|
|
+ v-for="item in orderTypes"
|
|
|
+ :key="item.id"
|
|
|
+ :label="item.name"
|
|
|
+ :value="item.name">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
@@ -40,10 +40,10 @@
|
|
|
<el-form-item label="交易类型">
|
|
|
<el-select v-model="value" placeholder="请选择交易类型">
|
|
|
<el-option
|
|
|
- v-for="item in options"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value">
|
|
|
+ v-for="item in productTypes"
|
|
|
+ :key="item.id"
|
|
|
+ :label="item.name"
|
|
|
+ :value="item.name">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
@@ -69,10 +69,10 @@
|
|
|
<el-form-item label="收支类型">
|
|
|
<el-select v-model="value" placeholder="请选择支付方式">
|
|
|
<el-option
|
|
|
- v-for="item in options"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value">
|
|
|
+ v-for="item in channels"
|
|
|
+ :key="item.id"
|
|
|
+ :label="item. name"
|
|
|
+ :value="item.name">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
@@ -100,10 +100,10 @@
|
|
|
<el-form-item label="关联项目">
|
|
|
<el-select v-model="value" placeholder="请选择项目类型">
|
|
|
<el-option
|
|
|
- v-for="item in options"
|
|
|
- :key="item.value"
|
|
|
- :label="item.label"
|
|
|
- :value="item.value">
|
|
|
+ v-for="item in orderState"
|
|
|
+ :key="item.id"
|
|
|
+ :label="item.name"
|
|
|
+ :value="item.name">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
@@ -178,14 +178,36 @@ export default {
|
|
|
value: '选项5',
|
|
|
label: '北京烤鸭'
|
|
|
}],
|
|
|
+ orderTypes: [],
|
|
|
+ productTypes: [],
|
|
|
+ channels: [],
|
|
|
+ orderState: [],
|
|
|
value: '',
|
|
|
radio: '1'
|
|
|
}
|
|
|
- }
|
|
|
+ },
|
|
|
+ mounted() {
|
|
|
+ this.getAllChoice()
|
|
|
+ },
|
|
|
+ methods: {
|
|
|
+ async getAllChoice() {
|
|
|
+ let res = await this.$post('/api/admin/order/get_all_choice', {
|
|
|
+ action: 'create'
|
|
|
+ })
|
|
|
+ if (res) {
|
|
|
+ console.log(res)
|
|
|
+ const allChoice = res.data
|
|
|
+ this.orderTypes = allChoice.order_types
|
|
|
+ this.productTypes = allChoice.product_types
|
|
|
+ this.channels = allChoice.channels
|
|
|
+ this.orderState = allChoice.order_state
|
|
|
+ }
|
|
|
+ },
|
|
|
+ },
|
|
|
}
|
|
|
</script>
|
|
|
|
|
|
-<style lang="scss">
|
|
|
+<style lang="scss" scoped>
|
|
|
.box-card {
|
|
|
margin-bottom: 10px;
|
|
|
width: 100%;
|