Commit f700a77c60401a0be5de6579450fdc49ecab1d79

Authored by 王家文
1 parent 37a3595d
Exists in master

【工具】GM工具

Showing 1 changed file with 31 additions and 1 deletions   Show diff stats
src/components/PlayerEdit.vue
... ... @@ -152,6 +152,13 @@
152 152 </div>
153 153 <div class="col-3">
154 154 <div class="card">
  155 + <el-form ref="form" :model="formTempQuery" label-width="80px" size="default">
  156 + <el-form-item label="查询结果">
  157 + <el-input type="textarea" :rows="3" v-model="formTempQuery.id"></el-input>
  158 + </el-form-item>
  159 + </el-form>
  160 + <button type="button" class="btn btn-success btn-block" v-for="(text, index) of this.listTempQuery"
  161 + :value=text @click="onTempQuery($event)">{{ text }}</button>
155 162 </div>
156 163 </div>
157 164 <div class="col-3">
... ... @@ -209,6 +216,7 @@ export default {
209 216 listPayTypes: ["模拟支付", "支付补单"],
210 217 listEditBoard: ["删除棋盘物件", "删除仓库物件", "删除暂存区物件"],
211 218 listPlayerData: ["存档玩家", "高级号", "复制其他玩家数据"],
  219 + listTempQuery: ["获取猜谜正确序列"],
212 220  
213 221 listActUid: [
214 222 { text: '新手礼包', v: '20001' },
... ... @@ -265,15 +273,30 @@ export default {
265 273 formClearActFlag: {
266 274 id: 20001,
267 275 },
  276 + formTempQuery: {
  277 + id: '',
  278 + },
268 279  
269 280 }
270 281 },
271 282 methods: {
  283 + OnPop(body, title) {
  284 + this.$alert(body, title, {
  285 + confirmButtonText: '确定',
  286 + });
  287 + },
272 288 onGmPost: function (data) {
273 289 data.Uid = this.puid
274 290 axios.post(this.serversDict[this.serverselected], data)
275   - .then(function (response) {
  291 + .then((response) => {
276 292 console.log(response);
  293 + let rsp = response.data;
  294 + if (rsp.Action == "获取猜谜正确序列") {
  295 + this.OnPop(rsp.Result, "猜谜正确序列")
  296 + }
  297 + if (rsp.Action == "模拟支付" || rsp.Action == "支付补单") {
  298 + this.OnPop(rsp.Result, rsp.Result)
  299 + }
277 300 })
278 301 .catch(function (error) {
279 302 console.log(error);
... ... @@ -348,6 +371,13 @@ export default {
348 371 Args: [v, this.formPlayerData.id.toString()]
349 372 })
350 373 },
  374 + onTempQuery(event) {
  375 + let v = event.srcElement.value
  376 + this.onGmPost({
  377 + Action: '玩家数据修改',
  378 + Args: [v]
  379 + })
  380 + },
351 381 }
352 382 }
353 383 </script>
... ...