Pārlūkot izejas kodu

test: ✅ 修复已知bug

zhangtao 5 dienas atpakaļ
vecāks
revīzija
de2d78a654

+ 13 - 10
src/config/index.ts

@@ -4,12 +4,14 @@ const mapEnvVersion = {
    */
   // develop: "http://192.168.1.166:8080/jeecg-boot",
   // develop: "http://192.168.0.217:8080/jeecg-boot",
+  // develop: "https://api.qlapp.cn/jeecgboot",
   develop: "http://192.168.0.11:8080/jeecg-boot",
   /**
    * 	体验版
    */
   // trial: "http://192.168.1.166:8080/jeecg-boot",
-  trial: "http://192.168.0.11:8080/jeecg-boot",
+  // trial: "http://192.168.0.11:8080/jeecg-boot",
+  trial: "https://api.qlapp.cn/jeecgboot",
   /**
    * 正式版
    */
@@ -25,37 +27,38 @@ export const BASE_URL =
 // export const BASE_UPLOADURL = "http://192.168.0.11:8080/jeecg-boot/upload";
 // export const BASE_UPLOADURL =
 // "http://192.168.1.166:8080/jeecg-boot/sys/common/upload";
+// export const BASE_UPLOADURL =
+//   "http://192.168.0.11:8080/jeecg-boot/sys/common/upload";
 export const BASE_UPLOADURL =
-  "http://192.168.0.11:8080/jeecg-boot/sys/common/upload";
-
+  "https://api.qlapp.cn/jeecgboot/sys/common/upload";
 //1-学校 2-包场 3-无固定场 4-个人赛 5-团队赛 6-课程 7-保险
 export enum GoodsType {
   /**
    * 学校
    */
-  school = 1,
+  school = 0,
   /**
    * 包场
    */
-  package = 2,
+  package = 1,
   /**
    * 无固定场
    */
-  noFixed = 3,
+  noFixed = 2,
   /**
    * 个人赛
    */
-  personal = 4,
+  personal = 3,
   /**
    * 团队赛
    */
-  team = 5,
+  team = 4,
   /**
    * 课程
    */
-  course = 6,
+  course = 5,
   /**
    *  保险
    */
-  insurance = 7,
+  insurance = 6,
 }

+ 1 - 1
src/subPack/Camera/index.vue

@@ -91,7 +91,7 @@ function takePhoto() {
   isShow.value = true;
   uni.showLoading({ mask: true });
   ctx.takePhoto({
-    quality: "high",
+    quality: "low",
     success: async (res) => {
       if (res.tempImagePath) {
         const img = await addWatermarkToImage(res.tempImagePath);

+ 4 - 4
src/subPack/EmployeeList/index.vue

@@ -58,7 +58,7 @@ function handleAdd(type: number, id: string) {
   });
 }
 async function getData() {
-  await getList();
+  await reload();
 }
 
 onShow(() => getData());
@@ -70,7 +70,7 @@ const {
   pageCount,
   total,
   isLastPage,
-  refresh,
+  reload,
   send: getList,
 } = usePagination(
   (page: number, pageSize: number) =>
@@ -115,7 +115,7 @@ onReachBottom(() => {
 });
 async function handleChange(e: SwitchBeforeChangeOption, id: string) {
   await uploadStatus(Number(e.value), id);
-  refresh();
+  reload();
 }
 async function handleDelete(item: { realname: string; id: string }) {
   msg
@@ -125,7 +125,7 @@ async function handleDelete(item: { realname: string; id: string }) {
     })
     .then(async () => {
       await del(item.id);
-      refresh();
+      reload();
     });
 }
 function handleEdit(item: { id: string }) {

+ 9 - 1
src/subPack/EmployeeListAdd/index.vue

@@ -415,11 +415,19 @@ function handleClickLeft() {
 }
 async function handleSubmit() {
   const val = await form.value?.validate();
+  console.log(typeof formData.honor);
+
   if (val?.valid) {
     const obj = convertEmptyToNull({
       ...formData,
-      selecteddeparts: formData.selecteddeparts.join(","),
+      selecteddeparts: formData.selecteddeparts.includes(",")
+        ? formData.selecteddeparts.join(",")
+        : formData.selecteddeparts,
       trainingPrograms: formData.trainingPrograms.join(",") || null,
+      honor:
+        typeof formData.honor == "object"
+          ? formData.honor.join(",")
+          : formData.honor,
     });
     console.log(obj, "提交表单");
     type.value == 0

+ 5 - 2
src/subPack/writeOff/index.vue

@@ -120,11 +120,11 @@
       <view>核销前请与顾客确认核销券数</view>
     </view>
   </view>
-
   <fixdbtn
     block
     size="large"
     :disabled="!checkedAll.length"
+    v-if="data"
     @click="handleSubmit"
     >确认核销({{ checkedAll.length }})</fixdbtn
   >
@@ -147,7 +147,10 @@ const { data, send: getOrder } = useRequest(
   {
     immediate: false,
   },
-);
+).onError((err) => {
+  console.log(err, "asdasdsad");
+  router.replace({ name: "error" });
+});
 const { send: submit } = useRequest(
   (orderProInfoIds: string[]) =>
     Apis.app.scanCodeVerification({