@uxda/appkit 4.2.80 → 4.2.82

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -104,7 +104,7 @@ const getSdkConfig = (appCode, url) => {
104
104
  return new Promise((resolve, reject) => {
105
105
  const $http = useHttp$2();
106
106
  $http.get("/wecom/config/getConfig", {
107
- appCode: appCode || "loankitMp",
107
+ appCode: appCode || "cloudkitProMp",
108
108
  callbackUrl: url || encodeURIComponent(location.href.split("#")[0])
109
109
  }).then((response) => {
110
110
  resolve(response);
@@ -135,7 +135,6 @@ function requestWxH5Pay(options) {
135
135
  timeStamp: options.timeStamp
136
136
  },
137
137
  function(res) {
138
- console.log(res, "-------res");
139
138
  if (res.err_msg == "get_brand_wcpay_request:ok") {
140
139
  resolve(true);
141
140
  } else {
@@ -335,10 +334,8 @@ const transformFields = (row) => {
335
334
  };
336
335
  const useUpload = (config) => {
337
336
  const appkitOptions = useAppKitOptions();
338
- console.log("===config", config);
339
337
  const upload = (url, file) => {
340
338
  return new Promise((resolve, reject) => {
341
- console.log(file, "----file");
342
339
  uploadFile({
343
340
  url: config.baseUrl + url,
344
341
  filePath: file.path,
@@ -352,7 +349,6 @@ const useUpload = (config) => {
352
349
  },
353
350
  success: (rsp) => {
354
351
  const { data } = rsp;
355
- console.log("===data", data);
356
352
  try {
357
353
  const response = JSON.parse(data);
358
354
  console.log("===response", response);
@@ -1401,11 +1397,14 @@ var HttpMethod = /* @__PURE__ */ ((HttpMethod2) => {
1401
1397
  const request = (config) => {
1402
1398
  const c = {
1403
1399
  ...clientConfig,
1404
- ...config
1400
+ ...config,
1401
+ headers: {
1402
+ ...clientConfig.headers,
1403
+ ...config.headers
1404
+ }
1405
1405
  };
1406
1406
  return new Promise((resolve, reject) => {
1407
1407
  const data = config.data && clientConfig.translates && clientConfig.translates[c.url] ? clientConfig.translates[c.url](c.data || {}) : c.data;
1408
- console.log(`[][][][][]HTTP.${c.method}, ${c.baseUrl}${c.url}`, data);
1409
1408
  clientConfig.vendor && clientConfig.vendor.request({
1410
1409
  url: `${c.baseUrl}${c.url}`,
1411
1410
  data,
@@ -1834,7 +1833,7 @@ var script$D = /* @__PURE__ */ defineComponent({
1834
1833
  }
1835
1834
  requestBrandWCPay({
1836
1835
  amount: amounts.value[state.selected].amount,
1837
- app: "loankitMp",
1836
+ app: "cloudkitProMp",
1838
1837
  tenant: props.tenant,
1839
1838
  accountAuthFlag: false,
1840
1839
  channelCode: "centergzh",
@@ -2217,7 +2216,7 @@ var script$z = /* @__PURE__ */ defineComponent({
2217
2216
  requestBrandWCPayByBean({
2218
2217
  caseConfigId: amounts.value[state.selected].id,
2219
2218
  amount: amounts.value[state.selected].paymentAmount,
2220
- app: "loankitMp",
2219
+ app: "cloudkitProMp",
2221
2220
  tenant: props.tenant,
2222
2221
  accountAuthFlag: false,
2223
2222
  channelCode: "centergzh",
@@ -6735,7 +6734,6 @@ var script$a = /* @__PURE__ */ defineComponent({
6735
6734
  function onAuth() {
6736
6735
  const $http = useHttp();
6737
6736
  $http.post("/cas/sysAccount/verify", { verifyCode: authState.code }).then((res) => {
6738
- console.log(res, "res");
6739
6737
  if (typeof res !== "boolean") return;
6740
6738
  showToast({ title: "\u8EAB\u4EFD\u8BA4\u8BC1\u6210\u529F", icon: "success" });
6741
6739
  current.value++;
@@ -7988,7 +7986,6 @@ var script$6 = /* @__PURE__ */ defineComponent({
7988
7986
  mediaType: ["mix"],
7989
7987
  maxDuration: 60,
7990
7988
  success: async (res) => {
7991
- console.log(res.tempFiles, "res.tempFiles");
7992
7989
  for (const item of res.tempFiles) {
7993
7990
  if (item.fileType === "video") {
7994
7991
  if (item.size > 1024 * 1024 * 50) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uxda/appkit",
3
- "version": "4.2.80",
3
+ "version": "4.2.82",
4
4
  "description": "小程序应用开发包",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.ts",
@@ -105,7 +105,7 @@ const onPayClick = () => {
105
105
  }
106
106
  requestBrandWCPay({
107
107
  amount: amounts.value[state.selected].amount,
108
- app: 'loankitMp',
108
+ app: 'cloudkitProMp',
109
109
  tenant: props.tenant,
110
110
  accountAuthFlag: false,
111
111
  channelCode: 'centergzh',
@@ -176,7 +176,7 @@ const onPayClick = () => {
176
176
  requestBrandWCPayByBean({
177
177
  caseConfigId: amounts.value[state.selected].id,
178
178
  amount: amounts.value[state.selected].paymentAmount,
179
- app: 'loankitMp',
179
+ app: 'cloudkitProMp',
180
180
  tenant: props.tenant,
181
181
  accountAuthFlag: false,
182
182
  channelCode: 'centergzh',
@@ -26,11 +26,9 @@ type UploadFunction = (url: string, file: Media) => Promise<Media>
26
26
 
27
27
  export const useUpload = (config: UploadConfig) => {
28
28
  const appkitOptions = useAppKitOptions()
29
- console.log('===config', config)
30
29
 
31
30
  const upload: UploadFunction = (url: string, file: Media) => {
32
31
  return new Promise<Media>((resolve, reject) => {
33
- console.log(file, '----file')
34
32
  uploadFile({
35
33
  url: config.baseUrl + url,
36
34
  filePath: file.path!,
@@ -44,7 +42,6 @@ export const useUpload = (config: UploadConfig) => {
44
42
  },
45
43
  success: (rsp: any) => {
46
44
  const { data } = rsp
47
- console.log('===data', data)
48
45
  try {
49
46
  const response = JSON.parse(data)
50
47
  console.log('===response', response)
@@ -29,13 +29,17 @@ const request: HttpInstance['request'] = <T>(config: HttpRequestConfig) => {
29
29
  const c = {
30
30
  ...clientConfig,
31
31
  ...config,
32
+ headers: {
33
+ ...clientConfig.headers,
34
+ ...config.headers,
35
+ },
32
36
  }
33
37
  return new Promise<T>((resolve, reject) => {
34
38
  const data =
35
39
  config.data && clientConfig.translates && clientConfig.translates[c.url]
36
40
  ? (clientConfig.translates[c.url] as HttpTranslate)(c.data || {})
37
41
  : c.data
38
- console.log(`[][][][][]HTTP.${c.method}, ${c.baseUrl}${c.url}`, data)
42
+ // console.log(`[][][][][]HTTP.${c.method}, ${c.baseUrl}${c.url}`, data)
39
43
 
40
44
  clientConfig.vendor &&
41
45
  clientConfig.vendor
@@ -29,7 +29,7 @@ const getSdkConfig = (appCode?: string, url?: string): Promise<JssdkConfig> => {
29
29
 
30
30
  $http
31
31
  .get('/wecom/config/getConfig', {
32
- appCode: appCode || 'loankitMp',
32
+ appCode: appCode || 'cloudkitProMp',
33
33
  callbackUrl: url || encodeURIComponent(location.href.split('#')[0]),
34
34
  })
35
35
  .then((response: JssdkConfig) => {
@@ -67,7 +67,6 @@ function requestWxH5Pay(options: PrePayOptions) {
67
67
  timeStamp: options.timeStamp,
68
68
  },
69
69
  function (res) {
70
- console.log(res, '-------res')
71
70
  if (res.err_msg == 'get_brand_wcpay_request:ok') {
72
71
  //res.err_msg将在用户支付成功后返回ok,但并不保证它绝对可靠,商户需进一步调用后端查单确认支付结果。
73
72
  resolve(true)
@@ -86,7 +86,6 @@ function onAuth() {
86
86
 
87
87
  // 向当前用户的手机中发送短信验证码
88
88
  $http.post('/cas/sysAccount/verify', { verifyCode: authState.code }).then((res) => {
89
- console.log(res, 'res')
90
89
  if (typeof res !== 'boolean') return
91
90
 
92
91
  showToast({ title: '身份认证成功', icon: 'success' })
@@ -112,7 +112,6 @@ function toUpload() {
112
112
  mediaType: ['mix'],
113
113
  maxDuration: 60,
114
114
  success: async (res) => {
115
- console.log(res.tempFiles, 'res.tempFiles')
116
115
  for (const item of res.tempFiles) {
117
116
  if (item.fileType === 'video') {
118
117
  if (item.size > 1024 * 1024 * 50) {