123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- <template>
- <div class="order-wrapper">
- <!-- <breadcrumb :item-name="['订单管理', '订单列表']"></breadcrumb> -->
- <el-card >
- <div class="wrap">
- <el-form :model="form" style="width: 500px;">
- <el-form-item label="新交易密码" :label-width="formLabelWidth">
- <el-input v-model="form.newpassword" type="password" maxlength="30" minlength="6" placeholder="请输入新交易密码(6~30位任意字符)" width="300px"></el-input>
- </el-form-item>
- <el-form-item label="旧交易密码" :label-width="formLabelWidth">
- <el-input v-model="form.oldpassword" type="password" maxlength="30" minlength="6" placeholder="请输入旧交易密码(如无则不需要填写)"></el-input>
- </el-form-item>
- </el-form>
- <div class="dialog-footer">
- <el-button @click="dialogTableVisible = false">取 消</el-button>
- <el-button type="primary" @click="goBuy">确 定</el-button>
- </div>
- </div>
-
-
- </el-card>
- </div>
- </template>
- <script>
- import { setTransaction } from '@/request/agent.js'
- export default {
- name: 'Order',
- data() {
- return {
- formLabelWidth: '120px',
- form: {
- newpassword: '',
- oldpassword: ''
- },
- dialogTableVisible: false,
- queryInfo: {
- keyword: '',
- page: 1,
- limit: 10
- },
- list: [],
- total: 0,
- loading: false,
- }
- },
- created() {
- },
- methods: {
- openBuy() {
- this.dialogTableVisible = true
- },
- goBuy() {
- let that = this
- if(!that.form.newpassword) {
- return that.$msg.error('请输入新交易密码')
- }
- // if(!that.transaction) {
- // return that.$msg.error('请输入交易密码')
- // }
- setTransaction(that.form).then(res => {
- console.log(res);
- return that.$msg.success('交易密码设置成功')
- })
- },
- getList() {
- let that = this
- if (that.loading) {
- return
- }
- that.loading = true
- },
- handleSizeChange(newPageSize) {
- this.queryInfo.limit = newPageSize
- this.getList()
- },
- handleCurrentChange(newPageNum) {
- this.queryInfo.page = newPageNum
- this.getList()
- },
- },
- }
- </script>
- <style scoped>
- .dialog-footer {
- display: flex;
- justify-content: flex-end;
- width: 500px;
- }
- /deep/ .el-card__body {
- display: flex;
- justify-content: center;
- align-items: center;
- }
- </style>
|