| 1234567891011121314151617181920212223242526272829303132333435363738 |
- import i18 from '@/utils/i18.js'
- const showModal = (title, content, cb) => {
- title = i18(title);
- content = i18(content);
- uni.showModal({
- title,
- content,
- showCancel: false,
- complete: () => {
- if (cb) cb();
- }
- });
- };
- const showLoading = (title) => {
- title = i18(title);
- uni.showLoading({
- title,
- mask:true,
- });
- };
- const hideLoading = () => {
- uni.hideLoading();
- };
- // #ifdef APP
- export default {
- showModal,
- showLoading,
- hideLoading
- };
- // #endif
- // #ifdef MP
- module.exports = {
- showModal,
- showLoading,
- hideLoading
- };
- // #endif
|